On Thu, Jul 22, 2021 at 9:02 AM Bin.Cheng via Gcc-patches
<gcc-patches@gcc.gnu.org> wrote:
>
> Gentle ping.  Any suggestions would be appreciated.

So just to say something - does the existing code mean that any use of
the alias info on prologue/epilogue insns is wrong?  We have

  /* The prologue/epilogue insns are not threaded onto the
     insn chain until after reload has completed.  Thus,
     there is no sense wasting time checking if INSN is in
     the prologue/epilogue until after reload has completed.  */
  bool could_be_prologue_epilogue = ((targetm.have_prologue ()
                                      || targetm.have_epilogue ())
                                     && reload_completed);

so when !could_be_prologue_epilogue then passes shouldn't run into
them if the comment is correct.  But else even epilogue stmts could appear
anywhere (like scheduled around)?  So why's skipping those OK?

Are passes supposed to check whether they are dealing with pro/epilogue
insns and not touch them?  CCing people that might know.

Richard.

> Thanks,
> bin
>
> On Wed, Jul 14, 2021 at 5:15 PM bin.cheng via Gcc-patches
> <gcc-patches@gcc.gnu.org> wrote:
> >
> > Hi,
> > I ran into a wrong code bug in code with deep template instantiation when 
> > working on sdx::simd.
> > The root cause as described in commit summary is we skip prologue insns in 
> > init_alias_analysis.
> > This simple patch fixes the issue, however, it's hard to reduce a case 
> > because of heavy use of
> > templates.
> > Bootstrap and test on x86_64, is it OK?
> >
> > Thanks,
> > bin

Reply via email to