diff options
| author | Alejandro Soto <alejandro@34project.org> | 2022-10-18 04:00:03 -0600 |
|---|---|---|
| committer | Alejandro Soto <alejandro@34project.org> | 2022-10-18 04:00:03 -0600 |
| commit | 2a83b7a7119abd4c63acb5ea7d6849305e313aba (patch) | |
| tree | 1821870437038cdc747814dfbbe567f0c88fc2c8 /tb | |
| parent | ec44613770f3eb6ec7a978a56861b712c02987b6 (diff) | |
Support program counter in --dump-regs
Diffstat (limited to '')
| -rw-r--r-- | tb/top/conspiracion.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tb/top/conspiracion.cpp b/tb/top/conspiracion.cpp index 851aaa2..fb65209 100644 --- a/tb/top/conspiracion.cpp +++ b/tb/top/conspiracion.cpp @@ -12,6 +12,7 @@ #include "Vconspiracion_arm810.h" #include "Vconspiracion_conspiracion.h" #include "Vconspiracion_platform.h" +#include "Vconspiracion_core_control.h" #include "Vconspiracion_core_regs.h" #include "Vconspiracion_core_reg_file.h" @@ -232,13 +233,16 @@ int main(int argc, char **argv) { std::puts("=== dump-regs ==="); - const auto ®file = top.conspiracion->core->regs->a->file; + const auto &core = *top.conspiracion->core; + const auto ®file = core.regs->a->file; int i = 0; for(const auto *name : gp_regs) { std::printf("%08x %s\n", regfile[i++], name); } + + std::printf("%08x pc\n", core.control->pc << 2); } const auto &dumps = *dump_mem; |
