diff options
author | Jerry Zhao <jerryz123@berkeley.edu> | 2023-03-29 00:48:48 -0700 |
---|---|---|
committer | Jerry Zhao <jerryz123@berkeley.edu> | 2023-03-29 00:49:23 -0700 |
commit | 41934578a4b58861e75c3cfa17a600349dce5a7d (patch) | |
tree | cc3d61c0d5604862a85a76976a6b05d8f1380ee0 /riscv | |
parent | f9c78b8e05b0a87eb45d37f44559963ecadead34 (diff) | |
download | riscv-isa-sim-41934578a4b58861e75c3cfa17a600349dce5a7d.zip riscv-isa-sim-41934578a4b58861e75c3cfa17a600349dce5a7d.tar.gz riscv-isa-sim-41934578a4b58861e75c3cfa17a600349dce5a7d.tar.bz2 |
Support zihpm && !zicntr
Diffstat (limited to 'riscv')
-rw-r--r-- | riscv/processor.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/riscv/processor.cc b/riscv/processor.cc index a00d13d..153ff9d 100644 --- a/riscv/processor.cc +++ b/riscv/processor.cc @@ -247,7 +247,7 @@ void state_t::reset(processor_t* const proc, reg_t max_isa) auto mcounter = std::make_shared<const_csr_t>(proc, which_mcounter, 0); csrmap[which_mcounter] = mcounter; - if (proc->extension_enabled_const(EXT_ZICNTR) && proc->extension_enabled_const(EXT_ZIHPM)) { + if (proc->extension_enabled_const(EXT_ZIHPM)) { auto counter = std::make_shared<counter_proxy_csr_t>(proc, which_counter, mcounter); csrmap[which_counter] = counter; } @@ -255,7 +255,7 @@ void state_t::reset(processor_t* const proc, reg_t max_isa) csrmap[which_mevent] = std::make_shared<rv32_low_csr_t>(proc, which_mevent, mevent[i - 3]);; auto mcounterh = std::make_shared<const_csr_t>(proc, which_mcounterh, 0); csrmap[which_mcounterh] = mcounterh; - if (proc->extension_enabled_const(EXT_ZICNTR) && proc->extension_enabled_const(EXT_ZIHPM)) { + if (proc->extension_enabled_const(EXT_ZIHPM)) { auto counterh = std::make_shared<counter_proxy_csr_t>(proc, which_counterh, mcounterh); csrmap[which_counterh] = counterh; } |