[Bug target/86222] ICE in final_scan_insn_1 calling strncmp() with a bound of PTRDIFF_MAX + 1
acsawdey at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Jun 21 19:36:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86222
--- Comment #4 from acsawdey at gcc dot gnu.org ---
Well when compiling this with -m32 -mcpu=power[6789] I get this for the rtx of
the length argument:
(const_int -2147483648 [0xffffffff80000000])
So when I am doing UINTVAL (bytes_rtx) I get 0xffffffff80000000 and things go
awry.
In the tree optimized dump I am seeing this, as Martin did:
_2 = strncmpD.898 (&aD.2760, &bD.2761, 2147483648); [tail call]
So somewhere in between something appears to be gratuitously sign extending
this.
More information about the Gcc-bugs
mailing list