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] Fix debug info with crtl->stack_realign_tried (PR debug/40596)


On 07/02/2009 04:29 AM, Jakub Jelinek wrote:
I've bootstrapped/regtested this patch on x86_64-linux and i686-linux with
the second patch on top of it and the assert never triggered, so I'm
assuming if crtl->stack_realign_tried is true, cfa.reg in the middle of
function is always HARD_FRAME_POINTER_REGNUM (if stack is dynamically
realigned, I think frame pointer is always forced)

This is correct, see ira.c:1413, where frame_pointer_needed is set.


(Incidentally, stack_realign_tried should be removed.  It's set once,
a copy of stack_realign_needed, and tested once there in dwarf2out.c.)

and cfa.indirect is true iff fde->drap_reg is not invalid.

Not true. Or at least not easily provable; there are two places in dwarf2out that set indirect=1 without any checking of drap_reg. The one in get_cfa_from_loc_descriptor I'm not worried about -- I don't think that can ever trigger. However, there is an instance at line 2572 where I can't immediately figure out what's going on.

That said, I suspect the change in your third patch more accurately
describes what the comment intends than the existing check vs
indirect.

Third patch approved.


r~



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