aboutsummaryrefslogtreecommitdiffhomepage
path: root/kernel
diff options
context:
space:
mode:
authorGravatar Catalin Hritcu <catalin.hritcu@gmail.com>2015-09-05 22:11:43 -0700
committerGravatar Maxime Dénès <mail@maximedenes.fr>2015-09-06 20:33:34 +0200
commita5e04d9dd178b2870b79776e1fbf1a858cdac49d (patch)
tree0c183bf6c65f167f0528aca767b8c4e5d9cc636b /kernel
parent5080991902a05ee720ab1d6fa1c9d592d3ffd36c (diff)
Fixed critical bug in 31 bit arithmetic of VM
ADDMULDIVINT31 was missing pops in some cases
Diffstat (limited to 'kernel')
-rw-r--r--kernel/byterun/coq_interp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/byterun/coq_interp.c b/kernel/byterun/coq_interp.c
index 0a121dc32..4937af77f 100644
--- a/kernel/byterun/coq_interp.c
+++ b/kernel/byterun/coq_interp.c
@@ -1252,10 +1252,11 @@ value coq_interprete
shiftby = uint32_of_value(accu);
if (shiftby > 31) {
if (shiftby < 62) {
- *sp++;
+ sp++;
accu = (value)((((*sp++)^1) << (shiftby - 31)) | 1);
}
else {
+ sp+=2;
accu = (value)(1);
}
}