This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug debug/48220] DW_OP_GNU_entry_value/DW_TAG_GNU_call_site_parameter vs. register window targets
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Mar 2011 20:31:04 -0000
- Subject: [Bug debug/48220] DW_OP_GNU_entry_value/DW_TAG_GNU_call_site_parameter vs. register window targets
- Auto-submitted: auto-generated
- References: <bug-48220-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48220
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-03-23 20:30:53 UTC ---
(In reply to comment #4)
> Yes, end of the prologue. I was under the impression that, with your alternate
> scheme, the opposite situation would arise, i.e. it wouldn't be possible to use
> DW_OP_GNU_entry_value after the end of the prologue. Given how GDB works, this
> sounded far less appealing than the current scheme. Sorry if I misunderstood.
If say reference to first parameter's original value is
DW_OP_GNU_entry_value 1 <DW_OP_reg8> (i.e. %o0), then it will work just fine
anywhere in the function. The debugger either looks up matching entry
for %o0 in DW_TAG_GNU_call_site, or a debugger could put a breakpoint on the
first insn in a function and remember the %o0 value there, then just use the
remembered value anywhere where DW_OP_GNU_entry_value appears.
And for SPARC, using %o0 is also much easier for the debugger, it doesn't have
to translate anything.
On IA-64 things are different because there it is mainly the call insn which
moves the register window, not some insn executed somewhere in function's
prologue.