History

arm: fix conversion from float/double to signed integer with VFP

The signed flag was not encoded in the instruction.

Daniel Glöckner committed 13 years ago

Commit f7f60251 parent 50619371 file · +1 −1Browse files

Unified · Split

arm-gen.c+1−1
@@ -1926,7 +1926,7 @@ void gen_cvt_ftoi(int t) · 1925 unmodified lines
19261926 #ifdef TCC_ARM_VFP
19271927 r=vfpr(gv(RC_FLOAT));
19281928 u=u?0:0x10000;
1929− o(0xEEBC0A40|(r<<12)|r|T2CPR(r2)); /* ftoXiY */
1929+ o(0xEEBC0A40|(r<<12)|r|T2CPR(r2)|u); /* ftoXiY */
19301930 r2=intr(vtop->r=get_reg(RC_INT));
19311931 o(0xEE100A10|(r<<16)|(r2<<12));
19321932 return;