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]

Re: PATCH: if -fpic then don't consider PIC_OFFSET_TABLE_REGNUM updates dead


On Mar 15, 2001, Richard Henderson <rth@redhat.com> wrote:

> On Thu, Mar 15, 2001 at 02:18:38AM -0800, Toshi Morita wrote:
>> If -fpic is specified, then updates to the PIC_OFFSET_TABLE_REGNUM
>> should never be considered dead.

> After reload, all uses of the pic register should be visible.  If not,
> something's wrong elsewhere.  Quite possibly in the port, since this
> is an area where we have been traditionally sloppy.

Actually, I've taken a lot of care to avoid emitting the PIC reg load
when it's not necessary, and flagging it as necessary whenever it
actually is.  However, there still are cases in which some
optimizations remove the only active use of the PIC reg, and then flow
complains.

At some point, I had a patch that would mark the PIC reg load as
MAYBE_DEAD, but someone advised against it, and, after some further
improvements, I hadn't met the problem any more.  But it used to be
just a warning.  Only recently did it become a hard error, so it may
have gone unnoticed.  I still think marking it as MAYBE_DEAD is the
right way to fix the problem.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me


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