This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix debug info with crtl->stack_realign_tried (PR debug/40596)
- From: Richard Henderson <rth at redhat dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: Jason Merrill <jason at redhat dot com>, hjl dot tools at gmail dot com, gcc-patches at gcc dot gnu dot org
- Date: Thu, 02 Jul 2009 10:49:34 -0700
- Subject: Re: [PATCH] Fix debug info with crtl->stack_realign_tried (PR debug/40596)
- References: <20090702112941.GO4462@tyan-ft48-01.lab.bos.redhat.com>
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~