summaryrefslogtreecommitdiffstats
path: root/byterun/fix_code.c
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>1995-06-18 14:44:56 +0000
committerXavier Leroy <xavier.leroy@inria.fr>1995-06-18 14:44:56 +0000
commite0f3c043e5dd7ad4dbec7feb15b9c7a23ebecb2d (patch)
tree1a849245370f2b163150bc021a8577ba10ef3a41 /byterun/fix_code.c
parent170fb62ccd2509eb7b5cd0da9cb3fc4a9d2f1edc (diff)
Changement representation des constructeurs constants.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@40 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'byterun/fix_code.c')
-rw-r--r--byterun/fix_code.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/byterun/fix_code.c b/byterun/fix_code.c
index 9c24de180..7cdff8e05 100644
--- a/byterun/fix_code.c
+++ b/byterun/fix_code.c
@@ -56,7 +56,13 @@ void thread_code(code, len, instr_table)
case GETGLOBALFIELD: case MAKEBLOCK: case C_CALLN:
p += 2; break;
/* Instructions with N+1 operands */
- case SWITCH: case TRANSLATE:
+ case SWITCH:
+ { uint32 sizes = *p++;
+ uint32 const_size = sizes & 0xFFFF;
+ uint32 block_size = sizes >> 16;
+ p += const_size + block_size;
+ break; }
+ case TRANSLATE:
p += *p + 1; break;
}
}