[Bug target/50588] gcc produce bad inlined code with -march=athlon -O2

mikpe at it dot uu.se gcc-bugzilla@gcc.gnu.org
Sun Dec 18 14:12:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50588

--- Comment #15 from Mikael Pettersson <mikpe at it dot uu.se> 2011-12-18 13:54:42 UTC ---
The problem appears to occur in rtx_addr_can_trap_p_1, case REG.  It returns
false for any address formed by the frame or stack pointer plus an offset,
regardless of the value of the offset.  In the test case it allows offsets in
the half GB range, which is bogus.  If I force it to return true for offsets
larger than, say, +/- 4KB, then the test case is unbroken.

Could rtx_addr_can_trap_p_1 find out what the ranges of safe offsets from the
stack and frame pointers are?



More information about the Gcc-bugs mailing list