For single stepping through a method we should continue _after_ the interrupt check or otherwise the interrupt check will _always_ trigger. This makes the DebugTools continue a bit.
2013-12-23 Holger Hans Peter Freyther <[email protected]> * xlat.c: Change emitted code in emit_interrupt_check. --- libgst/ChangeLog | 4 ++++ libgst/xlat.c | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/libgst/ChangeLog b/libgst/ChangeLog index c7bfdec..c4dc93c 100644 --- a/libgst/ChangeLog +++ b/libgst/ChangeLog @@ -1,5 +1,9 @@ 2013-12-23 Holger Hans Peter Freyther <[email protected]> + * xlat.c: Change emitted code in emit_interrupt_check. + +2013-12-23 Holger Hans Peter Freyther <[email protected]> + * xlat.c: Add ipOffset parameter to emit_interrupt_check. 2013-12-22 Holger Hans Peter Freyther <[email protected]> diff --git a/libgst/xlat.c b/libgst/xlat.c index fbae8f7..9f45b33 100644 --- a/libgst/xlat.c +++ b/libgst/xlat.c @@ -2500,10 +2500,9 @@ emit_deferred_sends (deferred_send *ds) void emit_interrupt_check (int restartReg, int ipOffset) { - jit_insn *jmp, *begin; + jit_insn *jmp, *restart = NULL; jit_align (2); - begin = jit_get_label (); jit_ldi_i (JIT_R2, &_gst_except_flag); jmp = jit_beqi_i (jit_forward (), JIT_R2, 0); @@ -2517,11 +2516,13 @@ emit_interrupt_check (int restartReg, int ipOffset) /* Where to restart?*/ if (restartReg == JIT_NOREG) - jit_movi_p (JIT_RET, begin); + restart = jit_movi_p (JIT_RET, jit_forward()); else jit_movr_p (JIT_RET, restartReg); jit_ret (); + if (restart) + jit_patch_movi (restart, jit_get_label()); jit_patch (jmp); } -- 1.8.5.1 _______________________________________________ help-smalltalk mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-smalltalk
