Changeset 539 for branches/RWT/modules/vci_mem_cache/caba/source
- Timestamp:
- Oct 2, 2013, 4:26:12 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/RWT/modules/vci_mem_cache/caba/source/src/vci_mem_cache.cpp
r526 r539 304 304 "ALLOC_TRT_XRAM_RSP", 305 305 "ALLOC_TRT_IXR_RSP", 306 "ALLOC_TRT_CLEANUP" 306 "ALLOC_TRT_CLEANUP", 307 307 "ALLOC_TRT_IXR_CMD", 308 308 "ALLOC_TRT_CONFIG" … … 4505 4505 4506 4506 r_xram_rsp_victim_copy = victim.owner.srcid; 4507 4508 #if L1_MULTI_CACHE4509 r_xram_rsp_victim_copy_cache= victim.owner.cache_id;4510 #endif4511 4507 r_xram_rsp_victim_coherent = victim.cache_coherent; 4512 4508 r_xram_rsp_victim_copy_inst = victim.owner.inst; … … 4529 4525 << " way = " << std::dec << way 4530 4526 << " / set = " << set 4527 << "/ count = " << victim.count 4531 4528 << " / inval_required = " << inval << std::endl; 4532 4529 #endif … … 4694 4691 << " / owner_ins = " << std::dec << entry.owner.inst 4695 4692 << " / count = " << entry.count 4693 << " / nline = " << r_xram_rsp_trt_buf.nline 4696 4694 << " / is_cnt = " << entry.is_cnt << std::endl; 4697 4695 if(r_xram_rsp_victim_inval.read()) … … 8590 8588 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8591 8589 8590 else if( r_config_fsm.read() == CONFIG_TRT_LOCK ) 8591 r_alloc_trt_fsm = ALLOC_TRT_CONFIG; 8592 8592 8593 else if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) 8593 8594 r_alloc_trt_fsm = ALLOC_TRT_CLEANUP; 8594 8595 else if( r_config_fsm.read() == CONFIG_TRT_LOCK )8596 r_alloc_trt_fsm = ALLOC_TRT_CONFIG;8597 8595 8598 8596 else if(r_read_fsm.read() == READ_TRT_LOCK) … … 8628 8626 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8629 8627 8628 else if( r_config_fsm.read() == CONFIG_TRT_LOCK ) 8629 r_alloc_trt_fsm = ALLOC_TRT_CONFIG; 8630 8630 8631 else if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) 8631 8632 r_alloc_trt_fsm = ALLOC_TRT_CLEANUP; 8632 8633 8633 else if( r_config_fsm.read() == CONFIG_TRT_LOCK )8634 r_alloc_trt_fsm = ALLOC_TRT_CONFIG;8635 8636 8634 else if(r_read_fsm.read() == READ_TRT_LOCK) 8637 8635 r_alloc_trt_fsm = ALLOC_TRT_READ; … … 8664 8662 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8665 8663 8664 else if( r_config_fsm.read() == CONFIG_TRT_LOCK ) 8665 r_alloc_trt_fsm = ALLOC_TRT_CONFIG; 8666 8666 8667 else if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) 8667 8668 r_alloc_trt_fsm = ALLOC_TRT_CLEANUP; 8668 8669 8670 else if( r_config_fsm.read() == CONFIG_TRT_LOCK )8671 r_alloc_trt_fsm = ALLOC_TRT_CONFIG;8672 8669 8673 8670 else if(r_read_fsm.read() == READ_TRT_LOCK) … … 8695 8692 (r_ixr_rsp_fsm.read() == IXR_RSP_TRT_READ)) 8696 8693 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8694 8695 else if( r_config_fsm.read() == CONFIG_TRT_LOCK ) 8696 r_alloc_trt_fsm = ALLOC_TRT_CONFIG; 8697 8697 8698 8698 else if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) … … 8710 8710 r_alloc_trt_fsm = ALLOC_TRT_CAS; 8711 8711 8712 else if( r_config_fsm.read() == CONFIG_TRT_LOCK )8713 r_alloc_trt_fsm = ALLOC_TRT_CONFIG;8714 8715 8712 else if((r_ixr_cmd_fsm.read() == IXR_CMD_READ_TRT) or 8716 8713 (r_ixr_cmd_fsm.read() == IXR_CMD_WRITE_TRT) or … … 8769 8766 break; 8770 8767 8771 //////////////////////// 8768 ////////////////////// 8769 case ALLOC_TRT_CONFIG: 8770 if((r_config_fsm.read() != CONFIG_TRT_LOCK) and 8771 (r_config_fsm.read() != CONFIG_TRT_SET)) 8772 { 8773 if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) 8774 r_alloc_trt_fsm = ALLOC_TRT_CLEANUP; 8775 8776 else if(r_read_fsm.read() == READ_TRT_LOCK) 8777 r_alloc_trt_fsm = ALLOC_TRT_READ; 8778 8779 else if((r_write_fsm.read() == WRITE_MISS_TRT_LOCK) or 8780 (r_write_fsm.read() == WRITE_BC_TRT_LOCK)) 8781 r_alloc_trt_fsm = ALLOC_TRT_WRITE; 8782 8783 else if((r_cas_fsm.read() == CAS_MISS_TRT_LOCK) or 8784 (r_cas_fsm.read() == CAS_BC_TRT_LOCK)) 8785 r_alloc_trt_fsm = ALLOC_TRT_CAS; 8786 8787 else if((r_ixr_cmd_fsm.read() == IXR_CMD_READ_TRT) or 8788 (r_ixr_cmd_fsm.read() == IXR_CMD_WRITE_TRT) or 8789 (r_ixr_cmd_fsm.read() == IXR_CMD_CAS_TRT) or 8790 (r_ixr_cmd_fsm.read() == IXR_CMD_XRAM_TRT) or 8791 (r_ixr_cmd_fsm.read() == IXR_CMD_CLEANUP_TRT) or 8792 (r_ixr_cmd_fsm.read() == IXR_CMD_CONFIG_TRT) ) 8793 r_alloc_trt_fsm = ALLOC_TRT_IXR_CMD; 8794 8795 else if((r_xram_rsp_fsm.read() == XRAM_RSP_DIR_LOCK) and 8796 (r_alloc_dir_fsm.read() == ALLOC_DIR_XRAM_RSP)) 8797 r_alloc_trt_fsm = ALLOC_TRT_XRAM_RSP; 8798 8799 else if((r_ixr_rsp_fsm.read() == IXR_RSP_TRT_ERASE) or 8800 (r_ixr_rsp_fsm.read() == IXR_RSP_TRT_READ)) 8801 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8802 } 8803 break; 8804 8805 //////////////////////// 8772 8806 case ALLOC_TRT_CLEANUP: 8773 8807 /*ODCCP*///std::cout << "TRT ALLOCATED TO CLEANUP" << std::endl; … … 8784 8818 (r_cas_fsm.read() == CAS_BC_TRT_LOCK)) 8785 8819 r_alloc_trt_fsm = ALLOC_TRT_CAS; 8786 8787 else if((r_xram_rsp_fsm.read() == XRAM_RSP_DIR_LOCK) and8788 (r_alloc_dir_fsm.read() == ALLOC_DIR_XRAM_RSP))8789 r_alloc_trt_fsm = ALLOC_TRT_XRAM_RSP;8790 8791 else if((r_ixr_rsp_fsm.read() == IXR_RSP_TRT_ERASE) ||8792 (r_ixr_rsp_fsm.read() == IXR_RSP_TRT_READ))8793 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP;8794 8795 else if( r_config_fsm.read() == CONFIG_TRT_LOCK )8796 r_alloc_trt_fsm = ALLOC_TRT_CONFIG;8797 8820 8798 8821 else if((r_ixr_cmd_fsm.read() == IXR_CMD_READ_TRT) or … … 8803 8826 (r_ixr_cmd_fsm.read() == IXR_CMD_CONFIG_TRT) ) 8804 8827 r_alloc_trt_fsm = ALLOC_TRT_IXR_CMD; 8805 } 8806 break; 8807 ////////////////////// 8808 case ALLOC_TRT_CONFIG: 8809 if((r_config_fsm.read() != CONFIG_TRT_LOCK) and 8810 (r_config_fsm.read() != CONFIG_TRT_SET)) 8811 { 8812 if(r_read_fsm.read() == READ_TRT_LOCK) 8813 r_alloc_trt_fsm = ALLOC_TRT_READ; 8814 8815 else if((r_write_fsm.read() == WRITE_MISS_TRT_LOCK) or 8816 (r_write_fsm.read() == WRITE_BC_TRT_LOCK)) 8817 r_alloc_trt_fsm = ALLOC_TRT_WRITE; 8818 8819 else if((r_cas_fsm.read() == CAS_MISS_TRT_LOCK) or 8820 (r_cas_fsm.read() == CAS_BC_TRT_LOCK)) 8821 r_alloc_trt_fsm = ALLOC_TRT_CAS; 8822 8823 else if((r_ixr_cmd_fsm.read() == IXR_CMD_READ_TRT) or 8824 (r_ixr_cmd_fsm.read() == IXR_CMD_WRITE_TRT) or 8825 (r_ixr_cmd_fsm.read() == IXR_CMD_CAS_TRT) or 8826 (r_ixr_cmd_fsm.read() == IXR_CMD_XRAM_TRT) or 8827 (r_ixr_cmd_fsm.read() == IXR_CMD_CLEANUP_TRT) or 8828 (r_ixr_cmd_fsm.read() == IXR_CMD_CONFIG_TRT) ) 8829 r_alloc_trt_fsm = ALLOC_TRT_IXR_CMD; 8830 8831 else if((r_xram_rsp_fsm.read() == XRAM_RSP_DIR_LOCK) and 8832 (r_alloc_dir_fsm.read() == ALLOC_DIR_XRAM_RSP)) 8833 r_alloc_trt_fsm = ALLOC_TRT_XRAM_RSP; 8834 8835 else if (r_cleanup_fsm.read() == CLEANUP_IXR_REQ) 8836 r_alloc_trt_fsm = ALLOC_TRT_CLEANUP; 8837 8838 else if((r_ixr_rsp_fsm.read() == IXR_RSP_TRT_ERASE) or 8839 (r_ixr_rsp_fsm.read() == IXR_RSP_TRT_READ)) 8840 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8841 } 8842 break; 8828 8829 else if((r_xram_rsp_fsm.read() == XRAM_RSP_DIR_LOCK) and 8830 (r_alloc_dir_fsm.read() == ALLOC_DIR_XRAM_RSP)) 8831 r_alloc_trt_fsm = ALLOC_TRT_XRAM_RSP; 8832 8833 else if((r_ixr_rsp_fsm.read() == IXR_RSP_TRT_ERASE) || 8834 (r_ixr_rsp_fsm.read() == IXR_RSP_TRT_READ)) 8835 r_alloc_trt_fsm = ALLOC_TRT_IXR_RSP; 8836 8837 else if( r_config_fsm.read() == CONFIG_TRT_LOCK ) 8838 r_alloc_trt_fsm = ALLOC_TRT_CONFIG; 8839 } 8840 break; 8843 8841 8844 8842
Note: See TracChangeset
for help on using the changeset viewer.