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]
Other format: [Raw text]

Re: [PATCH] RFA: Another purge_addressof_1 patch


On Tue, 2003-11-11 at 15:05, Richard Henderson wrote:
> On Sun, Nov 09, 2003 at 07:31:04PM -0800, Eric Christopher wrote:
> > +  /* Is this a libcall?  */
> > +  if (!insn)
> > +    libcall = REG_NOTE_KIND (*loc) == REG_RETVAL;
> 
> Surely this isn't right?  Isn't the return value always just
> a register, and it's the REG_EQUAL note that carries the addressof?

Not quite sure what you mean. I'm seeing this:

(insn_list:REG_RETVAL xx (expr_list:REG_EQUAL (.... (addressof (reg)))

for the note. The original insn was, of course:

(set (reg xx)
     (reg yy))

So, yes, the return value is a register and the REG_EQUAL note carries
the addressof. I was under the impression that the paradoxical subreg
was only valid in the notes for the return value, not across the entire
libcall? Otherwise I'll need to check for entry into the libcall and
keep state across invocations. Fairly easy, but I didn't think it was
necessary since the only time we don't just remove the note is for
REG_RETVAL if we fail to replace.

-eric

-- 
Eric Christopher <echristo@redhat.com>


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