This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Heads up re: shared register rtx in regno_reg_rtx
- From: "Dave Korn" <dk at artimi dot com>
- To: <gcc at gcc dot gnu dot org>
- Date: Thu, 18 Mar 2004 14:39:56 -0000
- Subject: Heads up re: shared register rtx in regno_reg_rtx
If anyone ever decides to re-enable this bit of code from
emit-rtl.c/gen_rtx_REG (...),
-----snip-----
#if 0
/* If the per-function register table has been set up, try to re-use
an existing entry in that table to avoid useless generation of RTL.
This code is disabled for now until we can fix the various backends
which depend on having non-shared hard registers in some cases. Long
term we want to re-enable this code as it can significantly cut down
on the amount of useless RTL that gets generated.
We'll also need to fix some code that runs after reload that wants to
set ORIGINAL_REGNO. */
if (cfun
&& cfun->emit
&& regno_reg_rtx
&& regno < FIRST_PSEUDO_REGISTER
&& reg_raw_mode[regno] == mode)
return regno_reg_rtx[regno];
#endif
-----snip-----
you'll have to do something to make it play nicely with this bit of code
from postreload.c/reload_cse_regs_1
-----snip-----
static void
reload_cse_regs_1 (first)
rtx first;
{
rtx insn;
rtx testreg = gen_rtx_REG (VOIDmode, -1);
-----snip-----
Heh. If the rtx-sharing code hadn't been disabled within a couple of days
of it's first having been checked in, someone would have noticed this
earlier. I couldn't even get through the libgcc stage of the x-build
without running into SEGVs caused by it.
cheers,
DaveK
--
Can't think of a witty .sigline today....