This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [commit+7.8] [read_frame_arg patch] Handle partially optimized out values similarly to unavailable values
- From: Doug Evans <dje at google dot com>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org
- Date: Tue, 5 Aug 2014 10:16:17 -0700
- Subject: Re: [commit+7.8] [read_frame_arg patch] Handle partially optimized out values similarly to unavailable values
- Authentication-results: sourceware.org; auth=none
- References: <20140709103312 dot GA27884 at host2 dot jankratochvil dot net> <53BD2CE0 dot 1000308 at redhat dot com> <20140709153121 dot GA7989 at host2 dot jankratochvil dot net> <53C41D5D dot 9030109 at redhat dot com> <20140716215838 dot GA29855 at host2 dot jankratochvil dot net> <53C7C02A dot 2090107 at redhat dot com> <20140720150727 dot GA18488 at host2 dot jankratochvil dot net> <53CEB93A dot 4020709 at redhat dot com> <20140722202004 dot GA14408 at host2 dot jankratochvil dot net>
Jan Kratochvil writes:
> On Tue, 22 Jul 2014 21:19:22 +0200, Pedro Alves wrote:
> > OK, I've pushed the reversion (without the #if 0 bit) to both master
> > and 7.8.
>
> Therefore pushed in the fix of read_frame_arg together with the testcase.
> e214cf6c2e05bcfc85dc6f335d8ffdc3629cf0cf
> and also for 7.8:
> 0f9e1204f3de3cbe46a2b9e54049c1df9a5df305
>
>
> Jan
> commit e214cf6c2e05bcfc85dc6f335d8ffdc3629cf0cf
> Author: Jan Kratochvil <jan.kratochvil@redhat.com>
> Date: Tue Jul 22 22:09:35 2014 +0200
>
> Fix read_frame_arg for optimized-out entry values.
>
> gdb/
> 2014-07-22 Jan Kratochvil <jan.kratochvil@redhat.com>
>
> * stack.c (read_frame_arg): Verify value_optimized_out before calling
> value_available_contents_eq.
>
> gdb/testsuite/
> 2014-07-22 Jan Kratochvil <jan.kratochvil@redhat.com>
>
> * gdb.arch/amd64-entry-value-paramref.S: New file.
> * gdb.arch/amd64-entry-value-paramref.cc: New file.
> * gdb.arch/amd64-entry-value-paramref.exp: New file.
> * gdb.arch/amd64-optimout-repeat.S: New file.
> * gdb.arch/amd64-optimout-repeat.c: New file.
> * gdb.arch/amd64-optimout-repeat.exp: New file.
>
> Message-ID: <20140720150727.GA18488@host2.jankratochvil.net>
> Message-ID: <20140711153757.GA452@host2.jankratochvil.net>
Hi.
In trunk I'm seeing amd64-entry-value-paramref.exp fail with a
gdb internal error. I can debug this further if you need me to.
(gdb) file testsuite/gdb.arch/amd64-entry-value-paramref
[...]
(top-gdb) bt
#0 internal_error (file=0xa249e8 "../../entry-value/gdb/dwarf2read.c", line=15776, string=0xa28050 "could not find partial DIE 0x%x in cache [from module %s]\n") at ../../entry-value/gdb/utils.c:823
#1 0x00000000006a89cb in find_partial_die (offset=..., offset_in_dwz=0, cu=0x1029370) at ../../entry-value/gdb/dwarf2read.c:15776
#2 0x00000000006a8c9d in fixup_partial_die (part_die=0x103a6f0, cu=0x1029370) at ../../entry-value/gdb/dwarf2read.c:15855
#3 0x0000000000692b49 in scan_partial_symbols (first_die=0x103a690, lowpc=0x7fffffffdb78, highpc=0x7fffffffdb70, need_pc=0, cu=0x1029370) at ../../entry-value/gdb/dwarf2read.c:6567
#4 0x000000000069132a in process_psymtab_comp_unit_reader (reader=0x7fffffffdcc0, info_ptr=0xf6c78c "\002bar", comp_unit_die=0x103a480, has_children=1, data=0x7fffffffdd90) at ../../entry-value/gdb/dwarf2read.c:5913
#5 0x0000000000690662 in init_cutu_and_read_dies (this_cu=0xf5d770, abbrev_table=0x0, use_existing_cu=0, keep=0, die_reader_func=0x690fe2 <process_psymtab_comp_unit_reader>, data=0x7fffffffdd90) at ../../entry-value/gdb/dwarf2read.c:5529
#6 0x00000000006917d0 in process_psymtab_comp_unit (this_cu=0xf5d770, want_partial_unit=0, pretend_language=language_minimal) at ../../entry-value/gdb/dwarf2read.c:5998
#7 0x0000000000692456 in dwarf2_build_psymtabs_hard (objfile=0x101eab0) at ../../entry-value/gdb/dwarf2read.c:6397
#8 0x000000000068d225 in dwarf2_build_psymtabs (objfile=0x101eab0) at ../../entry-value/gdb/dwarf2read.c:4173
#9 0x0000000000554e9d in read_psyms (objfile=0x101eab0) at ../../entry-value/gdb/elfread.c:1363
[...]