public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Heads up re: shared register rtx in regno_reg_rtx
@ 2004-03-18 14:43 Dave Korn
  0 siblings, 0 replies; only message in thread
From: Dave Korn @ 2004-03-18 14:43 UTC (permalink / raw)
  To: gcc


  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....

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-03-18 14:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-03-18 14:43 Heads up re: shared register rtx in regno_reg_rtx Dave Korn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).