[gdb/symtab] Support DW_AT_main_subprogram with -readnow.
authorTom de Vries <tdevries@suse.de>
Mon, 10 Jun 2019 07:28:30 +0000 (09:28 +0200)
committerTom de Vries <tdevries@suse.de>
Mon, 10 Jun 2019 07:28:30 +0000 (09:28 +0200)
commit81873cc81effbd657efe5f525d369e430ce77d7a
tree3e304c67f2d93ae9475427cad6d1fd9115807e20
parenta72f8c4ce397a0bbe98281d4151982330ad16f15
[gdb/symtab] Support DW_AT_main_subprogram with -readnow.

DW_AT_main_subprogram is supported in normal mode in read_partial_die, but not
in -readnow mode.

Fix this by adding support for DW_AT_main_subprogram in read_func_scope.

Tested on x86_64-linux with native and RFC target board readnow (
https://sourceware.org/ml/gdb-patches/2019-05/msg00073.html ).

gdb/ChangeLog:

2019-06-10  Tom de Vries  <tdevries@suse.de>

PR symtab/16264
PR symtab/24517
* dwarf2read.c (read_func_scope): Handle DW_AT_main_subprogram.
gdb/ChangeLog
gdb/dwarf2read.c