aboutsummaryrefslogtreecommitdiff
path: root/riscv/execute.cc
diff options
context:
space:
mode:
Diffstat (limited to 'riscv/execute.cc')
-rw-r--r--riscv/execute.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/riscv/execute.cc b/riscv/execute.cc
index ea03922..d244419 100644
--- a/riscv/execute.cc
+++ b/riscv/execute.cc
@@ -262,6 +262,14 @@ void processor_t::step(size_t n)
state.single_step = state.STEP_STEPPED;
}
+ if (!state.serialized) {
+ auto match = TM.detect_icount_match();
+ if (match.has_value()) {
+ assert(match->timing == triggers::TIMING_BEFORE);
+ throw triggers::matched_t((triggers::operation_t)0, 0, match->action);
+ }
+ }
+
// debug mode wfis must nop
if (unlikely(in_wfi && !state.debug_mode)) {
throw wait_for_interrupt_t();