This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [tree-ssa] Removing redundant loads


In message <1054265433.21692.117.camel@frodo.toronto.redhat.com>, Diego Novillo
 writes:
 >
 >--=-htuCgp94Pphoe8rbAqd2
 >Content-Type: text/plain
 >Content-Transfer-Encoding: 7bit
 >
 >On Thu, 2003-05-29 at 21:59, Diego Novillo wrote:
 >
 >> If it also fails, I'll send it your way.
 >>
 >Same failure on a pristine copy of the branch.  You'll see this:
 >
 > stage1/cc1 -fpreprocessed rs6000.i -quiet -dumpbase rs6000.c -auxbase-strip 
 >rs6000.o -g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-protot
 >ypes -pedantic -Wno-long-long -Werror -Wno-error -version -fno-common -o rs60
 >00.s
 >GNU C version 3.5-tree-ssa 20030530 (merged 20030511) (powerpc-unknown-linux-
 >gnu)
 >        compiled by GNU C version 2.95.3 20010111 (prerelease/franzo/20010111
 >).
 >GGC heuristics: --param ggc-min-expand=38 --param ggc-min-heapsize=15555
 >/home/dnovillo/clean-tree-ssa/src.ppc/gcc/config/rs6000/rs6000.c: In function
 > `rs6000_emit_prologue':
 >/home/dnovillo/clean-tree-ssa/src.ppc/gcc/config/rs6000/rs6000.c:11108: inter
 >nal compiler error: in assign_vars, at tree-ssa.c:1530
 >Please submit a full bug report,
 >with preprocessed source if appropriate.
 >See <URL:http://gcc.gnu.org/bugs.html> for instructions.
It looks like a failure during rewriting.  If you look at the .ssa dump for
the simplified testcase you'll see something like this:

rs6000_emit_prologue (i, info)
{       
  int T.1;
  int T.2;
  char T.3;
  extern  gen_rtx_REG;
        
  T.1_4 = info_2->first_gp_reg_save;
  T.2_6 = T.1_4 + i_5;
  T.3_7 = regs_ever_live[T.2_6];
  if (T.3_7 != 0)
    {
      goto <UL5f00>;
    };  
  (void)0;
  T.2_8 = i_5 + T.1_4;
  if (T.2_8 != 0)
    {
      goto <UL5f00>;
    }   
  else
    {
      goto <UL5f80>;
    };
  <UL5f00>:;;
  (void)0;
  (void)0;
  gen_rtx_REG (T.2_6);
  <UL5f80>:;
}


Note how we have two versions of T.2 live at the same time.  What's odd
is T.2_8 should have been totally unnecessary as T.2_6 already has the
value we care about.  

I know Jason recently worked on this -- I guess there's a case missing
somewhere/somehow.  

I'll dive further into it.

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]