This is the mail archive of the gdb-testers@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] garbage collect debug sections when no alloc sections are kept


*** TEST RESULTS FOR COMMIT eb026f09eb6fcb96a5de1e655cdde041ba44affb ***

Author: Alan Modra <amodra@gmail.com>
Branch: master
Commit: eb026f09eb6fcb96a5de1e655cdde041ba44affb

garbage collect debug sections when no alloc sections are kept

The pr20882 testcase fails on a number of targets that add attribute
or note sections to object files, and the default linker script says
those sections should be kept.  This patch changes --gc-sections to
drop debug and special sections like .comment when no SEC_ALLOC
section in an object file is kept.  The assumption is that debug
sections are describing code and data that will become part of the
final image in memory.

	* elflink.c (_bfd_elf_gc_mark_extra_sections): Don't keep
	debug and special sections when no non-note alloc sections in an
	object are kept.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]