This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/7871] [3.3/3.4 regression] ICE on legal code, global register variables problems
- From: "rz at linux-m68k dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 11 Jan 2004 17:54:07 -0000
- Subject: [Bug optimization/7871] [3.3/3.4 regression] ICE on legal code, global register variables problems
- References: <20020909143600.7871.rz@linux-m68k.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From rz at linux-m68k dot org 2004-01-11 17:54 -------
Subject: Re: [3.3/3.4 regression] ICE on legal code, global register variables problems
would be pitty to remove it considering that there are some patches
so I tried the patches again.
Surprise, my original patch now works even better than it used to
work with 3.1/3.2.
Namely it does now work correctly with R. Henderson's little testcase
- I am wondering if it is just lucky coincidence?
Jim's patch also works with Richard Henderson's testcase, however it
completely breaks my test app - much worse than it did in 3.2 It appears
that this approach looses some important dependency information and
assembler instructions get reordered where they should not.
Admitedly my patch is rather hackish, but it works perfectly with
my app that does really heavilly stress global register variables.
Here is my patch again:
--- gcc-3.4-20031210/gcc/flow.c.rz 2003-12-09 04:34:06.000000000 +0100
+++ gcc-3.4-20031210/gcc/flow.c 2003-12-25 20:16:12.000000000 +0100
@@ -1797,7 +1797,10 @@
so they are made live. */
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
if (global_regs[i])
- mark_used_reg (pbi, regno_reg_rtx[i], cond, insn);
+ {
+ SET_REGNO_REG_SET (pbi->reg_live, i);
+ mark_used_reg (pbi, regno_reg_rtx[i], cond, insn);
+ }
}
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7871