commit d79b2aecbf58052262871265e42c78df6d0e8f4c
parent 9126afa2da0e1635d78429075cc44ca576f68169
Author: Quentin Carbonneaux <quentin@c9x.me>
Date: Mon, 12 Dec 2022 13:57:28 +0100
zero msbs of 32-bit constants
Some noisy assemblers complain
when asked to do it themselves.
Diffstat:
1 file changed, 2 insertions(+), 0 deletions(-)
diff --git a/fold.c b/fold.c
@@ -525,6 +525,8 @@ opfold(int op, int cls, Con *cl, Con *cr, Fn *fn)
return Bot;
} else
foldflt(&c, op, cls == Kd, cl, cr);
+ if (!KWIDE(cls))
+ c.bits.i &= 0xffffffff;
r = newcon(&c, fn);
assert(!(cls == Ks || cls == Kd) || c.flt);
return r.val;