diff options
author | Jerry Zhao <jerryz123@berkeley.edu> | 2023-12-07 14:20:00 -0800 |
---|---|---|
committer | Jerry Zhao <jerryz123@berkeley.edu> | 2023-12-08 18:05:28 -0800 |
commit | ae889cb8493a1e31fcbbcb303cf6a7df05fad537 (patch) | |
tree | 251b04f6c84f0f36632759695818b60f24aa15ef /riscv/debug_module.cc | |
parent | e04f5f321c1ddf2c734d4d52019be3f0ed210d98 (diff) | |
download | riscv-isa-sim-ae889cb8493a1e31fcbbcb303cf6a7df05fad537.zip riscv-isa-sim-ae889cb8493a1e31fcbbcb303cf6a7df05fad537.tar.gz riscv-isa-sim-ae889cb8493a1e31fcbbcb303cf6a7df05fad537.tar.bz2 |
Remove cfg_arg_t from cfg_t
Argument parsing should be scoped to the code which constucts cfg_t
Diffstat (limited to 'riscv/debug_module.cc')
-rw-r--r-- | riscv/debug_module.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/riscv/debug_module.cc b/riscv/debug_module.cc index 07723c5..5d49605 100644 --- a/riscv/debug_module.cc +++ b/riscv/debug_module.cc @@ -514,7 +514,7 @@ bool debug_module_t::dmi_read(unsigned address, uint32_t *value) unsigned base = hawindowsel * 32; for (unsigned i = 0; i < 32; i++) { unsigned n = base + i; - if (n < sim->get_cfg().nprocs() && hart_array_mask[sim->get_cfg().hartids()[n]]) { + if (n < sim->get_cfg().nprocs() && hart_array_mask[sim->get_cfg().hartids[n]]) { result |= 1 << i; } } @@ -916,7 +916,7 @@ bool debug_module_t::dmi_write(unsigned address, uint32_t value) for (unsigned i = 0; i < 32; i++) { unsigned n = base + i; if (n < sim->get_cfg().nprocs()) { - hart_array_mask[sim->get_cfg().hartids()[n]] = (value >> i) & 1; + hart_array_mask[sim->get_cfg().hartids[n]] = (value >> i) & 1; } } } @@ -1030,5 +1030,5 @@ hart_debug_state_t& debug_module_t::selected_hart_state() size_t debug_module_t::selected_hart_id() const { - return sim->get_cfg().hartids().at(dmcontrol.hartsel); + return sim->get_cfg().hartids.at(dmcontrol.hartsel); } |