gc-sections removing required sections of elf
Alan Modra
amodra@gmail.com
Wed Feb 26 11:40:00 GMT 2014
On Mon, Feb 24, 2014 at 04:53:50PM +0530, Nagaraju Mekala wrote:
> Thanks Alan for the reply.
>
> On Fri, Feb 21, 2014 at 5:47 AM, Alan Modra <amodra@gmail.com> wrote:
> > On Thu, Feb 20, 2014 at 11:11:19PM +0530, Nagaraju Mekala wrote:
> >> Can anyone please let me know how can we tell the garbage collector
> >> to not to delete .debug information of _exit function.
> >
> > Have a look at what is happening inside _bfd_elf_gc_mark_extra_sections.
> I looked at the _bfd_elf_gc_mark_extra_sections and tried modifying it
> with the basic knowlege I had.
I wasn't suggesting that you modify _bfd_elf_gc_mark_extra_sections.
It should work as is. What I was suggesting is to run the failing
link under gdb and step through _bfd_elf_gc_mark_extra_sections paying
attention to the object file (ibfd) that defines _exit. Is that file
seen as ELF? Do you see some_kept set true for that file? If so, are
the debug sections in that file marked with gc_mark?
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list