From ab97fd0dccd4f1761b209ca7ed8e6f9f9a2763b1 Mon Sep 17 00:00:00 2001 From: Luc Maranget Date: Mon, 2 Oct 2000 14:18:05 +0000 Subject: or-pat avec variables et compil du switch git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@3304 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02 --- byterun/fix_code.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'byterun/fix_code.c') diff --git a/byterun/fix_code.c b/byterun/fix_code.c index 6496ee4db..5da63c62a 100644 --- a/byterun/fix_code.c +++ b/byterun/fix_code.c @@ -108,8 +108,9 @@ void thread_code (code_t code, asize_t len) /* Instructions with two operands */ l[APPTERM] = l[CLOSURE] = l[PUSHGETGLOBALFIELD] = - l[GETGLOBALFIELD] = l[MAKEBLOCK] = l[C_CALLN] = 2; - + l[GETGLOBALFIELD] = l[MAKEBLOCK] = l[C_CALLN] = + l[BEQ] = l[BNEQ] = l[BLTINT] = l[BLEINT] = l[BGTINT] = l[BGEINT] = + l[BULTINT] = l[BUGEINT] = 2; len /= sizeof(opcode_t); for (p = code; p < code + len; /*nothing*/) { opcode_t instr = *p; @@ -117,6 +118,7 @@ void thread_code (code_t code, asize_t len) fatal_error_arg ("Fatal error in fix_code: bad opcode (%lx)\n", (char *)(long)instr); } + *p++ = (opcode_t)(instr_table[instr] - instr_base); if (instr == SWITCH) { uint32 sizes = *p++; -- cgit v1.2.3-70-g09d2