From 61204637be41f75cfa67997b30f4820871c956b5 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sat, 25 Mar 2017 00:21:32 -0700 Subject: Prevent blowing past our native translated instruction size of 255 bytes when translating movem with a large register list. Fixes bug in which Fantastic Dizzy was completely broken on 32-bit builds --- gen_x86.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'gen_x86.c') diff --git a/gen_x86.c b/gen_x86.c index a0cbc19..2da8055 100644 --- a/gen_x86.c +++ b/gen_x86.c @@ -1999,9 +1999,10 @@ void call_noalign(code_info *code, code_ptr fun) code->cur = out; } - +volatile int foo; void call(code_info *code, code_ptr fun) { + foo = *fun; code->stack_off += sizeof(void *); int32_t adjust = 0; if (code->stack_off & 0xF) { @@ -2064,6 +2065,11 @@ void retn(code_info *code) code->cur = out; } +void rts(code_info *code) +{ + retn(code); +} + void cdq(code_info *code) { check_alloc_code(code, 1); -- cgit v1.2.3