This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/36998] [4.3/4.4 regression] Ada bootstrap broken on i586-*-*
- From: "kkojima at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Aug 2008 15:02:35 -0000
- Subject: [Bug rtl-optimization/36998] [4.3/4.4 regression] Ada bootstrap broken on i586-*-*
- References: <bug-36998-226@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from kkojima at gcc dot gnu dot org 2008-08-02 15:02 -------
I've tested the 2nd patch on sh4, but it doesn't fix the ICE
on sh4. Perhaps the problem is slightly different from that
for i586. Here is a reduced test case for the sh-elf compiler
with the option '-m4 -O -fasynchronous-unwind-tables':
union double_union
{
double d;
unsigned int i[2];
};
char *foo (double _d, char *s, char **rve)
{
union double_union d;
d.d = _d;
if ((d.i[1]) & 0x80000000UL)
(d.i[1]) &= ~0x80000000UL;
if (((d.i[1]) & 0x7ff00000UL) == 0x7ff00000UL)
return s;
if (!d.d)
{
s = "0";
if (rve) *rve = s + 1;
return s;
}
}
I've tried to see what is going on in the above test case
with stepping from the top of compute_barrier_args_size_1.
It seems that that function scans insns and updates
cur_args_size as follows:
(insn/f 95 ... (set (reg/f:SI 14 r14) (reg/f:SI 15 r15))...)
...
(insn 91 ... (set (mem/c:SF (pre_dec:SI (reg/f:SI 15 r15))) (reg:SF 68
fr4))...)
cur_args_size is updated to 4.
(insn 92 ... (set (mem/c:SF (pre_dec:SI (reg/f:SI 15 r15))) (reg:SF 69
fr5))...)
cur_args_size is updated to 8.
...
(jump_insn 22 ... (label_ref 77) ...)
...
(insn 86 ... (set (mem/c:DF (pre_dec:SI (reg/f:SI 15 r15))) (reg:DF 6 r6)))
cur_args_size is updated to 16.
...
(jump_insn 33 ... (label_ref 77) ...)
...
;; Exit block
(code_label 77 ...)
...
(insn 102 ... (set (reg/f:SI 15 r15) (reg/f:SI 14 r14)) ...)
Thus label 77 is reachable from (jump_insn 22 ...) where arg_size
is 8 and from (jump_insn 33 ...) where arg_size is 16.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36998