This is the mail archive of the 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: regmove patch

  In message <>you write:
  > > The patch is pretty simple, we update REG_LIVE_LENGTH and REG_N_CALLS_CROSSED
  > > when we make a successful substitution.
  > You have removed the adjustment of REG_N_REFS for dregno.
Thanks for the catch.  I'll fix that.

Note that REG_N_REFS is recomputed after regmove, so missing it should
not cause problems -- one of the things I'd like to do post-1.1 is
remove the code to try and keep REG_N_REFS up-to-date in regmove.c
since the code is basically useless.

  > Otherwise, it seems OK.

  > However, I thionk we would better code if we undo the initial substitution
  > if we can't make a proper replacement.  If we made validate_replace_rtx_1
  > non-static, or created another interface function for it that doesn't
  > call apply_change_group, that should be pretty straingtforward, and actually
  > make optimize_reg_copy_1 simpler.
I would expect the number of cases where we later find that we can't
make a proper replacement to be small.  This particular case happens
because we have a volatile memory reference.

But if you want to investigate and do this in the mainline sources
feel free.


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