aboutsummaryrefslogtreecommitdiffstats
path: root/cfrontend/Cshmgen.v
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>2015-06-30 14:48:17 +0200
committerXavier Leroy <xavier.leroy@inria.fr>2015-06-30 14:48:17 +0200
commitbdbf444704c031a37039d4aeb2f19d05550afbd6 (patch)
treeec101477946f1be805aa0e200bb5b7d82a45b1f3 /cfrontend/Cshmgen.v
parentff62587774f6ca437c887cc3ff5d079895c5e214 (diff)
downloadcompcert-kvx-bdbf444704c031a37039d4aeb2f19d05550afbd6.tar.gz
compcert-kvx-bdbf444704c031a37039d4aeb2f19d05550afbd6.zip
Signedness issue in specification of subtraction between two pointers.
Diffstat (limited to 'cfrontend/Cshmgen.v')
-rw-r--r--cfrontend/Cshmgen.v2
1 files changed, 1 insertions, 1 deletions
diff --git a/cfrontend/Cshmgen.v b/cfrontend/Cshmgen.v
index cb83731a..a80f4c15 100644
--- a/cfrontend/Cshmgen.v
+++ b/cfrontend/Cshmgen.v
@@ -260,7 +260,7 @@ Definition make_sub (ce: composite_env) (e1: expr) (ty1: type) (e2: expr) (ty2:
OK (Ebinop Osub e1 (Ebinop Omul n e2))
| sub_case_pp ty =>
let n := make_intconst (Int.repr (Ctypes.sizeof ce ty)) in
- OK (Ebinop Odivu (Ebinop Osub e1 e2) n)
+ OK (Ebinop Odiv (Ebinop Osub e1 e2) n)
| sub_case_pl ty =>
let n := make_intconst (Int.repr (Ctypes.sizeof ce ty)) in
OK (Ebinop Osub e1 (Ebinop Omul n (Eunop Ointoflong e2)))