Changeset 18
- Timestamp:
- Apr 12, 2010, 12:41:25 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/modules/vci_cc_vcache_wrapper2_multi/caba/source/src/vci_cc_vcache_wrapper2_multi.cpp
r4 r18 1073 1073 r_itlb_read_dcache_req = true; 1074 1074 r_icache_vaddr_req = ireq.addr; 1075 r_itlb_k_read_dcache = true; 1075 1076 r_icache_fsm = ICACHE_TLB2_READ; 1076 1077 m_cpt_ins_tlb_miss++; … … 1675 1676 if ( r_tgt_icache_req ) 1676 1677 { 1677 r_tgt_icache_req = false; 1678 r_icache_fsm = ICACHE_CC_INVAL; 1679 r_icache_fsm_save = r_icache_fsm; 1680 m_cost_ins_waste_wait_frz++; 1681 break; 1678 1682 } 1679 1683 … … 1735 1739 { 1736 1740 if ( ireq.valid ) m_cost_ins_waste_wait_frz++; 1741 // external cache invalidate request 1742 if ( r_tgt_icache_req ) 1743 { 1744 r_icache_fsm = ICACHE_CC_INVAL; 1745 r_icache_fsm_save = r_icache_fsm; 1746 m_cost_ins_waste_wait_frz++; 1747 break; 1748 } 1737 1749 1738 1750 paddr_t ipaddr = 0; … … 1764 1776 case ICACHE_CACHE_INVAL_PA: 1765 1777 { 1778 // external cache invalidate request 1779 if ( r_tgt_icache_req ) 1780 { 1781 r_icache_fsm = ICACHE_CC_INVAL; 1782 r_icache_fsm_save = r_icache_fsm; 1783 m_cost_ins_waste_wait_frz++; 1784 break; 1785 } 1786 1766 1787 paddr_t ipaddr = (paddr_t)r_mmu_word_hi.read() << 32 | r_mmu_word_lo.read(); 1767 1788 … … 2172 2193 2173 2194 bool itlb_hit_dcache = r_dcache.read(r_icache_paddr_save, &rsp_itlb_miss); 2174 if ( (r_icache_fsm == ICACHE_TLB2_READ)&& itlb_hit_dcache )2195 if ( r_itlb_k_read_dcache && itlb_hit_dcache ) 2175 2196 { 2197 r_itlb_k_read_dcache = false; 2176 2198 bool itlb_hit_ppn = r_dcache.read(r_icache_paddr_save.read()+4, &rsp_itlb_ppn); 2177 2199 assert(itlb_hit_ppn && "Address of pte[64-32] and pte[31-0] should be successive"); … … 3995 4017 if ( r_tgt_dcache_req ) 3996 4018 { 3997 r_tgt_dcache_req = false; 4019 r_dcache_fsm = DCACHE_CC_CHECK; 4020 r_dcache_fsm_save = r_dcache_fsm; 4021 m_cost_data_waste_wait_frz++; 4022 break; 3998 4023 } 3999 4024 … … 4063 4088 case DCACHE_DCACHE_INVAL: 4064 4089 { 4090 // external cache invalidate request 4091 if ( r_tgt_dcache_req ) 4092 { 4093 r_dcache_fsm = DCACHE_CC_CHECK; 4094 r_dcache_fsm_save = r_dcache_fsm; 4095 m_cost_data_waste_wait_frz++; 4096 break; 4097 } 4098 4065 4099 m_cpt_dcache_dir_read += m_dcache_ways; 4066 4100 vaddr_t invadr = dreq.wdata; … … 4111 4145 case DCACHE_DCACHE_INVAL_PA: 4112 4146 { 4147 // external cache invalidate request 4148 if ( r_tgt_dcache_req ) 4149 { 4150 r_dcache_fsm = DCACHE_CC_CHECK; 4151 r_dcache_fsm_save = r_dcache_fsm; 4152 m_cost_data_waste_wait_frz++; 4153 break; 4154 } 4113 4155 m_cpt_dcache_dir_read += m_dcache_ways; 4114 4156 paddr_t dpaddr = (paddr_t)r_mmu_word_hi.read() << 32 | r_mmu_word_lo.read(); … … 4305 4347 if ( r_dcache_inval_tlb_rsp ) // Miss read response and tlb invalidation 4306 4348 { 4307 r_dcache_fsm = DCACHE_IDLE;4308 4349 r_dcache_inval_tlb_rsp = false; 4309 break;4310 4350 } 4311 4351 … … 4812 4852 } 4813 4853 4814 r_dtlb_translation_valid = false;4815 r_dcache_ptba_ok = false;4816 4854 if ( !r_dcache_cc_check ) 4817 4855 { … … 4823 4861 r_dcache_cc_check = false; 4824 4862 } 4863 r_dtlb_translation_valid = false; 4864 r_dcache_ptba_ok = false; 4825 4865 break; 4826 4866 }
Note: See TracChangeset
for help on using the changeset viewer.