This is the mail archive of the gcc@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: Latent bug in update_equiv_regs?


Jeff Law <law@redhat.com> writes:

> Somehow I can't help but think I'm missing something here...
>
> Given:
>
>   (set (reg X) (mem Y))
>
>   (...)
>
>   (set (mem Y) (reg Z))
>
>   (...)
>
>   (use  (reg X))
>
>
>
> update_equiv_regs can set an equivalence between (reg X) and (mem Y)
> which is clearly wrong as (mem Y) is set to (reg Z).

My understanding is that that scenario is supposed to not happen because
update_equiv_regs is only supposed to equate a register and a memory
location in the specific cases where that is OK.  It's not no_equiv that
is supposed to fix this, the equivalence should only be created when it
will always be OK.

So I think you need to explain more about why the equivalence was
created.

Ian


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