Changeset 674 for branches/MESI/modules/vci_cc_vcache_wrapper/caba/source
- Timestamp:
- Apr 9, 2014, 9:47:15 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/MESI/modules/vci_cc_vcache_wrapper/caba/source/src/vci_cc_vcache_wrapper.cpp
r672 r674 1295 1295 r_icache_fsm = ICACHE_MISS_SELECT; 1296 1296 #if DEBUG_ICACHE 1297 if ( m_debug_activated )1297 if ( m_debug_activated or m_ireq.addr == 0x11020 ) 1298 1298 std::cout << " <PROC " << name() << " ICACHE_IDLE> READ MISS in icache" 1299 1299 << " : PADDR = " << std::hex << paddr << std::endl; … … 2100 2100 2101 2101 // coherence request completed 2102 r_icache_cc_send_req = true; 2103 r_icache_cc_send_nline = r_cc_receive_icache_nline.read(); 2104 r_icache_cc_send_way = r_icache_cc_way.read(); 2105 r_icache_cc_send_type = CC_TYPE_CLEANUP; 2106 2107 r_icache_fsm = r_icache_fsm_save.read(); 2102 r_icache_cc_send_req = true; 2103 r_icache_cc_send_nline = r_cc_receive_icache_nline.read(); 2104 r_icache_cc_send_way = r_icache_cc_way.read(); 2105 r_icache_cc_send_type = CC_TYPE_CLEANUP; 2106 2107 r_icache_fsm = r_icache_fsm_save.read(); 2108 r_cc_receive_icache_req = false; 2108 2109 2109 2110 #if DEBUG_ICACHE … … 2821 2822 m_drsp.rdata = cache_rdata; 2822 2823 #if DEBUG_DCACHE 2823 if ( m_debug_activated )2824 if ( m_debug_activated or m_drsp.rdata == 0x11020) 2824 2825 std::cout << " <PROC " << name() << " DCACHE_IDLE>" 2825 2826 << " READ HIT in dcache" … … 2967 2968 } 2968 2969 #if DEBUG_DCACHE 2969 if ( m_debug_activated )2970 if ( m_debug_activated or m_dreq.wdata == 0x11020) 2970 2971 std::cout << " <PROC " << name() << " DCACHE_IDLE>" 2971 2972 << " WRITE REQ " … … 5620 5621 } 5621 5622 } // end switch r_dcache_fsm 5622 if(r_dcache_miss_updt.read()) 5623 std::cout << " <PROC " << name() 5624 << " miss updt " << r_dcache_miss_updt.read() << std::endl; 5623 5624 //if(r_dcache_miss_updt.read()) 5625 //std::cout << " <PROC " << name() 5626 // << " miss updt " << r_dcache_miss_updt.read() << std::endl; 5625 5627 5626 5628 //std::cout << " <PROC " << name() … … 6265 6267 r_cc_receive_dcache_srcid = DspinDhccpParam::dspin_get(receive_data, 6266 6268 DspinDhccpParam::BROADCAST_SRCID); 6267 }6268 r_cc_receive_fsm = CC_RECEIVE_BRDCAST_NLINE;6269 r_cc_receive_fsm = CC_RECEIVE_BRDCAST_NLINE; 6270 } 6269 6271 break; 6270 6272 } … … 6278 6280 // not to actually post a request to an available cache => need a 6279 6281 // flip_flop to check that ? 6280 if (not (r_cc_receive_icache_req.read()) and 6281 not (r_cc_receive_dcache_req.read()) and 6282 (p_dspin_m2p.write.read())) 6282 if (r_cc_receive_icache_req.read() or r_cc_receive_dcache_req.read()) 6283 { 6284 std::cout << "illege flags for handling brdcast request" << std::endl; 6285 exit(0); 6286 } 6287 if(p_dspin_m2p.write.read()) 6283 6288 { 6284 6289 // request dcache to handle the BROADCAST … … 6296 6301 break; 6297 6302 } 6303 6298 6304 // keep waiting for the caches to accept the request 6299 6305 break; … … 6846 6852 case CC_RECEIVE_BRDCAST_HEADER: 6847 6853 { 6848 p_dspin_m2p.read = true;6849 break;6850 }6851 //////////////////////////////6852 case CC_RECEIVE_BRDCAST_NLINE:6853 {6854 // TODO maybe we need to wait for both only to leave the state, but6855 // not to actually post a request to an available cache => need a6856 // flip_flop to check that ?6857 6854 if (not (r_cc_receive_icache_req.read()) and not (r_cc_receive_dcache_req.read())) 6858 6855 p_dspin_m2p.read = true; … … 6860 6857 p_dspin_m2p.read = false; 6861 6858 break; 6859 } 6860 ////////////////////////////// 6861 case CC_RECEIVE_BRDCAST_NLINE: 6862 { 6863 // TODO maybe we need to wait for both only to leave the state, but 6864 // not to actually post a request to an available cache => need a 6865 // flip_flop to check that ? 6866 p_dspin_m2p.read = true; 6867 break; 6868 6862 6869 } 6863 6870 /////////////////////////////
Note: See TracChangeset
for help on using the changeset viewer.