This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/11753] %o7 register being used immediately in the delay slot before a call with -O2
- From: "ebotcazou at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 Sep 2003 11:38:21 -0000
- Subject: [Bug optimization/11753] %o7 register being used immediately in the delay slot before a call with -O2
- References: <20030731185137.11753.warren_baird@cimmetry.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11753
------- Additional Comments From ebotcazou at gcc dot gnu dot org 2003-09-06 11:38 -------
The optimization gets triggered because the compiler thinks that the target
address is within the range of an immediate operand, that is it internally
calculates the difference of addresses as being representable by a 13-bit signed
integer because it underestimates the size of several insns, in this case by
8192 - 3904 - 4096 = 192 bytes
which represents 48 insns.
This suggests that the problem affects a widely-used insn or a group of insns.
I've identified such a problem and attached a patch (against the 3.2.x branch)
that cures it. Could you try it with your original testcase?