> -----Original Message----- > From: Jakub Jelinek [mailto:ja...@redhat.com] > Sent: Wednesday, October 24, 2018 6:16 AM > To: Rafik Zurob > Cc: Robinson, Paul; dwarf-discuss@lists.dwarfstd.org > Subject: Re: [Dwarf-Discuss] Alternate entry points > > On Wed, Oct 24, 2018 at 01:00:26AM -0400, Rafik Zurob via Dwarf-Discuss > wrote: > > > I dug up gfortran 5.4, which does not emit DW_TAG_entry_point with my > > > simple example program. Does anybody actually use it? > > > > IBM XL Fortran generates it. > > > > $ cat entry.f > > subroutine foo(a) > > integer a > > real b > > > > a = 5 > > return > > entry bar(b) > > b = 3.0 > > return > > end subroutine > > $ > > > > Gets the following DWARF: > > That is kind of weird, because foo only has dummy argument a > and entry bar only has b, there is nothing that tells the debug info > consumer that the subprogram doesn't have (a, b) arguments. > > > <1><42>: Abbrev Number: 2 (DW_TAG_base_type) > > <43> DW_AT_name : INTEGER > > <4b> DW_AT_byte_size : 4 > > <4c> DW_AT_encoding : 5 (signed) > > <1><51>: Abbrev Number: 2 (DW_TAG_base_type) > > <52> DW_AT_name : REAL > > <57> DW_AT_byte_size : 4 > > <58> DW_AT_encoding : 4 (float) > > <1><59>: Abbrev Number: 4 (DW_TAG_subprogram) > > <5a> DW_AT_name : foo > > <5e> DW_AT_low_pc : 0x0 > > <66> DW_AT_high_pc : 128 > > <67> DW_AT_decl_file : 1 > > <68> DW_AT_decl_line : 1 > > <69> DW_AT_external : 1 > > <6a> DW_AT_frame_base : 0x0 (location list) > > <2><72>: Abbrev Number: 5 (DW_TAG_formal_parameter) > > <73> DW_AT_location : 3 byte block: 91 20 6 (DW_OP_fbreg: > 32; > > DW_OP_deref) > > <77> DW_AT_name : a > > <79> DW_AT_type : 0x42 > > <2><81>: Abbrev Number: 5 (DW_TAG_formal_parameter) > > <82> DW_AT_location : 3 byte block: 91 28 6 (DW_OP_fbreg: > 40; > > DW_OP_deref) > > <86> DW_AT_name : b > > <88> DW_AT_type : 0x51 > > <2><90>: Abbrev Number: 6 (DW_TAG_entry_point) > > <91> DW_AT_name : bar > > <95> DW_AT_low_pc : 0x28 > > <9d> DW_AT_decl_file : 1 > > <9e> DW_AT_decl_line : 7 > > <9f> DW_AT_frame_base : 1 byte block: 6e (DW_OP_reg30 > > (r30)) If the entry for 'bar' has a formal_parameter child describing 'b' then this is behaving according to my intuition. Thanks, --paulr > > Jakub _______________________________________________ Dwarf-Discuss mailing list Dwarf-Discuss@lists.dwarfstd.org http://lists.dwarfstd.org/listinfo.cgi/dwarf-discuss-dwarfstd.org
Re: [Dwarf-Discuss] Alternate entry points
Paul Robinson via Dwarf-Discuss Wed, 24 Oct 2018 08:45:16 -0700
- [Dwarf-Discuss] Alternate entry points Paul Robinson via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alternate entry ... Paul Robinson via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alternate en... Rafik Zurob via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alternat... Ron Brender via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alternat... Jakub Jelinek via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alte... Paul Robinson via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alte... Michael Eager via Dwarf-Discuss
- Re: [Dwarf-Discuss] Alternate entry ... Bishop, John E via Dwarf-Discuss