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: x86 PIC regressions



> > And isn't the only way we get these references via the handling of
> > REG_EQUIV stuff?

> I think so.  And if that's the case, there's no need to invent 
> any new construct-this-constant-by-parts-on-the-stack sort of
> solution.  If we can't reload the constant directly, we ignore
> the REG_EQUIV and spill the register in question.

I draw your attention to

extern int foo;
int something() { 
  asm ("" : "r"(&foo));
}

which causes reload to pass (mem (symbol_ref "foo")) to mov*.

This is the stumbling block I hit when trying to get reload to stop
generating symbol_refs, to fix the ppc -fpic problem.  Everything else
worked.

Fortunately, asm of the above form doesn't actually occur on my
system, so that's OK then :-).

-- 
Geoff Keating <Geoff.Keating@anu.edu.au>


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