Skip to content
Snippets Groups Projects
Commit 480ef558 authored by Hans-Peter Deifel's avatar Hans-Peter Deifel
Browse files

C: Trigger interrupts more than once per callsite

The interrupt triggering loop is left if no interrupt has been
triggered in this loop iteration. That ensures that we trigger
interrupts in random order and possibly more than once.

Unfortunately the previous code didn't correctly record if any
interrupt had been triggered and would thus leave the loop after at
most one iteration.
parent 6ca92f40
No related branches found
No related tags found
No related merge requests found
...@@ -112,6 +112,7 @@ triggerInterrupts (Just ints) = do ...@@ -112,6 +112,7 @@ triggerInterrupts (Just ints) = do
" if (_decisionMaker("<> T.pack (show decision) <> ")) {\n" " if (_decisionMaker("<> T.pack (show decision) <> ")) {\n"
<> " _print_os_state(\"IRQ" <> T.pack (show int) <> "\", __func__);\n" <> " _print_os_state(\"IRQ" <> T.pack (show int) <> "\", __func__);\n"
<> " Machine::trigger_interrupt_from_user(" <> T.pack (show int) <> ");\n" <> " Machine::trigger_interrupt_from_user(" <> T.pack (show int) <> ");\n"
<> " _triggeredSomeInterrupt = 1;\n"
<> " }\n" <> " }\n"
instrsToC :: Maybe IntSet -> FunctionKind -> [Instr] -> DecisionM Text instrsToC :: Maybe IntSet -> FunctionKind -> [Instr] -> DecisionM Text
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment