aboutsummaryrefslogtreecommitdiffhomepage
path: root/x86_64/isel.c
diff options
context:
space:
mode:
authorlemon <lsof@mailbox.org>2026-03-08 19:03:41 +0100
committerlemon <lsof@mailbox.org>2026-03-08 19:03:59 +0100
commitd943de389796a44e40be39ef46aa5be01013a166 (patch)
tree80ecad7f06727f94737653ca6c89655ae9f3afd9 /x86_64/isel.c
parent77f78e58c94812d1ec40b57df86d2a87e6f32b41 (diff)
fix some more cases of signed integer overflow
Diffstat (limited to 'x86_64/isel.c')
-rw-r--r--x86_64/isel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/x86_64/isel.c b/x86_64/isel.c
index 65c3e4d..3a753e6 100644
--- a/x86_64/isel.c
+++ b/x86_64/isel.c
@@ -447,7 +447,7 @@ sel(struct function *fn, struct instr *ins, struct block *blk, int *curi)
goto ALU;
} else if (kisint(ins->cls) && isintcon(ins->r)) {
ins->op = op = Oadd;
- ins->r = mkintcon(concls(ins->r), -intconval(ins->r));
+ ins->r = mkintcon(concls(ins->r), -(uvlong)intconval(ins->r));
} else {
goto ALU;
}