Changeset 119 for trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Ifetch_unit/Ifetch_queue/src
- Timestamp:
- May 25, 2009, 7:40:26 PM (15 years ago)
- Location:
- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Ifetch_unit/Ifetch_queue/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Ifetch_unit/Ifetch_queue/src/Ifetch_queue_genMoore.cpp
r88 r119 26 26 // =====[ ADDRESS ]========================================== 27 27 // ========================================================== 28 internal_ADDRESS_ACK = (_queue[reg_PTR_WRITE]->_state == IFETCH_QUEUE_STATE_EMPTY); 29 30 PORT_WRITE(out_ADDRESS_ACK , internal_ADDRESS_ACK); 31 if (_param->_have_port_ifetch_queue_ptr) 32 PORT_WRITE(out_ADDRESS_IFETCH_QUEUE_ID, reg_PTR_WRITE); 28 { 29 internal_ADDRESS_ACK = (_queue[reg_PTR_WRITE]->_state == IFETCH_QUEUE_STATE_EMPTY); 30 31 PORT_WRITE(out_ADDRESS_ACK , internal_ADDRESS_ACK); 32 if (_param->_have_port_ifetch_queue_ptr) 33 PORT_WRITE(out_ADDRESS_IFETCH_QUEUE_ID, reg_PTR_WRITE); 34 } 33 35 34 36 // ========================================================== 35 37 // =====[ DECOD ]============================================ 36 38 // ========================================================== 37 bool ack = (_queue[reg_PTR_READ]->_state == IFETCH_QUEUE_STATE_HAVE_RSP); 38 39 for (uint32_t i=0; i<_param->_nb_instruction; i++) 40 { 41 internal_DECOD_VAL [i] = ack and _queue[reg_PTR_READ]->_instruction_enable [i]; 42 PORT_WRITE(out_DECOD_VAL [i], internal_DECOD_VAL [i]); 43 PORT_WRITE(out_DECOD_INSTRUCTION [i], _queue[reg_PTR_READ]->_instruction [i]); 44 } 45 46 PORT_WRITE(out_DECOD_ADDRESS , _queue[reg_PTR_READ]->_address ); 47 if (_param->_have_port_inst_ifetch_ptr) 48 PORT_WRITE(out_DECOD_INST_IFETCH_PTR , _queue[reg_PTR_READ]->_inst_ifetch_ptr ); 49 PORT_WRITE(out_DECOD_BRANCH_STATE , _queue[reg_PTR_READ]->_branch_state ); 50 if (_param->_have_port_depth) 51 PORT_WRITE(out_DECOD_BRANCH_UPDATE_PREDICTION_ID, _queue[reg_PTR_READ]->_branch_update_prediction_id); 52 PORT_WRITE(out_DECOD_EXCEPTION , _queue[reg_PTR_READ]->_exception ); 39 { 40 bool ack = (_queue[reg_PTR_READ]->_state == IFETCH_QUEUE_STATE_HAVE_RSP); 41 42 for (uint32_t i=0; i<_param->_nb_instruction; i++) 43 { 44 internal_DECOD_VAL [i] = ack and _queue[reg_PTR_READ]->_instruction_enable [i]; 45 PORT_WRITE(out_DECOD_VAL [i], internal_DECOD_VAL [i]); 46 PORT_WRITE(out_DECOD_INSTRUCTION [i], _queue[reg_PTR_READ]->_instruction [i]); 47 } 48 49 PORT_WRITE(out_DECOD_ADDRESS , _queue[reg_PTR_READ]->_address ); 50 if (_param->_have_port_inst_ifetch_ptr) 51 PORT_WRITE(out_DECOD_INST_IFETCH_PTR , _queue[reg_PTR_READ]->_inst_ifetch_ptr ); 52 PORT_WRITE(out_DECOD_BRANCH_STATE , _queue[reg_PTR_READ]->_branch_state ); 53 if (_param->_have_port_depth) 54 PORT_WRITE(out_DECOD_BRANCH_UPDATE_PREDICTION_ID, _queue[reg_PTR_READ]->_branch_update_prediction_id); 55 PORT_WRITE(out_DECOD_EXCEPTION , _queue[reg_PTR_READ]->_exception ); 56 } 53 57 54 58 log_printf(FUNC,Ifetch_queue,FUNCTION,"End"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Ifetch_unit/Ifetch_queue/src/Ifetch_queue_transition.cpp
r101 r119 23 23 { 24 24 log_begin(Ifetch_queue,FUNCTION); 25 log_function(Ifetch_queue,FUNCTION,_name.c_str()); 25 26 26 27 if (PORT_READ(in_NRESET) == 0) … … 39 40 if (PORT_READ(in_ADDRESS_VAL) and internal_ADDRESS_ACK) 40 41 { 42 log_printf(TRACE,Ifetch_queue,FUNCTION," * ADDRESS : Transaction"); 43 log_printf(TRACE,Ifetch_queue,FUNCTION," * reg_PTR_WRITE : %d",reg_PTR_WRITE); 44 log_printf(TRACE,Ifetch_queue,FUNCTION," * ADDRESS : 0x%x",PORT_READ(in_ADDRESS_INSTRUCTION_ADDRESS)); 45 41 46 // New slot in ifetch_queue is allocated 42 47 … … 75 80 if (internal_DECOD_VAL [i] and PORT_READ(in_DECOD_ACK[i])) 76 81 { 82 log_printf(TRACE,Ifetch_queue,FUNCTION," * DECOD [%d] : Transaction",i); 83 77 84 have_instruction_decod = true; 78 85 _queue[reg_PTR_READ]->_instruction_enable [i] = false; … … 94 101 if (PORT_READ(in_ICACHE_RSP_VAL) and internal_ICACHE_RSP_ACK) 95 102 { 103 log_printf(TRACE,Ifetch_queue,FUNCTION," * ICACHE_RSP : Transaction"); 104 96 105 Tpacket_t ptr = (_param->_have_port_ifetch_queue_ptr)?PORT_READ(in_ICACHE_RSP_PACKET_ID):0; 97 106 … … 119 128 if (PORT_READ(in_EVENT_RESET_VAL) and internal_EVENT_RESET_ACK) 120 129 { 130 log_printf(TRACE,Ifetch_queue,FUNCTION," * EVENT_RESET : Transaction"); 131 121 132 // Scan all entry of queue and test the status 122 133 for (uint32_t i=0; i<_param->_size_queue; i++)
Note: See TracChangeset
for help on using the changeset viewer.