public inbox for gnu-gabi@sourceware.org
 help / color / mirror / Atom feed
* Using section flags to indicate stripable or persistent sections
@ 2022-11-07 11:22 Nick Clifton
  2022-11-07 13:33 ` Michael Matz
  0 siblings, 1 reply; 5+ messages in thread
From: Nick Clifton @ 2022-11-07 11:22 UTC (permalink / raw)
  To: gnu-gabi; +Cc: Guillermo E. Martinez

Hi Guys,

     We would like to suggest an extension the ELF section flags which can be
     used to indicate sections that should, or should not, be stripped when
     removing debug information.

     The problem we are trying to address is that different stripping tools
     (strip, eu-strip, llvm-strip) have different heuristics for deciding
     which sections should be removed when stripping debug information.  In
     order to fix this we are proposing two new section flags:

       GNU_SHF_CAN_BE_STRIPPED
       GNU_SHF_DO_NOT_STRIP

     These would be set by the assembler and/or linker to indicate sections
     that should be removed when stripping and sections which must not be
     removed when stripping.  It would be an error if both flags were present
     on a given section, and if neither flag is present then the stripping
     tool would fall back on its built in heuristics.

     In addition we need new flags for the assembler's .section directive
     (suggestion: 'D': can be stripped, 'K' do not strip).
     This email is to ask if you think that this idea has merit, and if so,
     are there any guidelines for writing and submitting a formal specification ?

  Cheers
     Nick


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-11-09 11:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-07 11:22 Using section flags to indicate stripable or persistent sections Nick Clifton
2022-11-07 13:33 ` Michael Matz
2022-11-07 18:51   ` Fangrui Song
2022-11-07 23:07     ` Alan Modra
2022-11-09 11:09       ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).