This is the mail archive of the gcc@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]

return_address_pointer_rtx (more Itanium and perhaps other breakage)


I'm seeing another problem in flow.c on Itanium on the trunk. 

It looks to me like there's some confusion about what
return_address_pointer_rtx is supposed to represent.

gen_rtx_REG returns return_address_pointer_rtx when it's asked to construct
an RTL expression for RETURN_ADDRESS_POINTER_REGNUM.  This implies that
return_address_pointer_rtx represents the hardware return address register,
if there is one, i.e. b0 on Itanium.  If I read the code to process calls in
propagate_one_insn in flow.c correctly, that relies critically on the fact
the it does represent the hardware register.  In particular,
return_address_pointer_rtx is viewed as dead before the call.

In fact, ia64.c changes the register number associated with
return_address_pointer_rtx to point to the save location for the return
address.  The net result appears to be that the return address save location
is marked dead before the call, with unfortunate, but not surprising,
results.

It looks like Itanium is the only platform for which
return_address_pointer_rtx is changed.  Is it safe to conclude that this is
a bug in ia64.c?

None of the relevant code looks like it was modified recently.  Is this in
fact a long-standing bug that was exposed by some higher-level changes?  Or
am I misinterpreting something?

Hans


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