aboutsummaryrefslogtreecommitdiff
path: root/riscv/sim.cc
diff options
context:
space:
mode:
authorTim Newsome <tim@sifive.com>2018-02-01 14:32:00 -0800
committerTim Newsome <tim@sifive.com>2018-02-01 14:32:00 -0800
commitb2672e5d5271b346a71ec33ab42c88437b9b60d1 (patch)
tree33b6e163c6e3d5c45bdbacb0fbda86f3a7b51abc /riscv/sim.cc
parentd3d3681f3468c633bc93a727a35bc07348245440 (diff)
downloadspike-b2672e5d5271b346a71ec33ab42c88437b9b60d1.zip
spike-b2672e5d5271b346a71ec33ab42c88437b9b60d1.tar.gz
spike-b2672e5d5271b346a71ec33ab42c88437b9b60d1.tar.bz2
Add --debug-sba option
This lets the user control whether the system bus access implements bus mastering.
Diffstat (limited to 'riscv/sim.cc')
-rw-r--r--riscv/sim.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/riscv/sim.cc b/riscv/sim.cc
index 97697e4..009bb98 100644
--- a/riscv/sim.cc
+++ b/riscv/sim.cc
@@ -26,10 +26,11 @@ static void handle_signal(int sig)
sim_t::sim_t(const char* isa, size_t nprocs, bool halted, reg_t start_pc,
std::vector<std::pair<reg_t, mem_t*>> mems,
const std::vector<std::string>& args,
- std::vector<int> const hartids, unsigned progsize)
+ std::vector<int> const hartids, unsigned progsize,
+ unsigned max_bus_master_bits)
: htif_t(args), mems(mems), procs(std::max(nprocs, size_t(1))),
start_pc(start_pc), current_step(0), current_proc(0), debug(false),
- remote_bitbang(NULL), debug_module(this, progsize)
+ remote_bitbang(NULL), debug_module(this, progsize, max_bus_master_bits)
{
signal(SIGINT, &handle_signal);