This is the mail archive of the gcc-bugs@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]

Re: Code gen error on PowerPC


Am Tue, 02 Mar 1999 schrieb Jeffrey A Law:
>In message <4.2.0.25.19990302025929.0370ae50@mail.lauterbach.com>you write:
>  > Hmm, I think this giv is setup by this hunk of code in find_mem_givs:
>  > 
>  >     case MEM:
>  >       {
>  >         rtx src_reg;
>  >         rtx add_val;
>  >         rtx mult_val;
>  >         int benefit;
>  > 
>  >         benefit = general_induction_var (XEXP (x, 0),
>  >                                          &src_reg, &add_val, &mult_val);
>  > 
>  >         /* Don't make a DEST_ADDR giv with mult_val == 1 && add_val == 0.
>  >            Such a giv isn't useful.  */
>  >         if (benefit > 0 && (mult_val != const1_rtx || add_val != const0_rtx
>  > ))
>  >           {
>  >             /* Found one; record it.  */
>  >             struct induction *v
>  >               = (struct induction *) oballoc (sizeof (struct induction));
>  > 
>  >             record_giv (v, insn, src_reg, addr_placeholder, mult_val,
>  >                         add_val, benefit, DEST_ADDR, not_every_iteration,
>  >                         &XEXP (x, 0), loop_start, loop_end);
>  > 
>  >             v->mem_mode = GET_MODE (x);
>  >           }
>  >       }
>  >       return;
>  > 
>  > But it's too late now and I'm not sure about anything :-) I'll continue 
>  > debugging tomorrow or wednesday.
>Could be.  There's a call to general_induction_var, so it is a likely
>candidate.

It took me a little bit longer to get back to this problem, and I have a little
question now. I looked at the .loop file and noticed the following:

Insn 71: dest address src reg 81 benefit 7 used 1 lifetime 1 replaceable mult
8 add (plus:SI (plus:SI (reg:SI 88)         (const_int -8))
    (const_int 4))

Is this valid at this point? Shouldn't there be a single (plus:SI (reg:SI 88)
(const_int -4))?

This bug turns out to be quite hard to debug for me, as I can't see what's
going wrong yet.

Franz.


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