Feature request: .section$key

Jason Merrill jason@redhat.com
Mon Aug 28 14:33:00 GMT 2000


>>>>> Ulrich Drepper <drepper@redhat.com> writes:

 > Jason Merrill <jason@redhat.com> writes:
 >> The PE format has what seems like a useful feature, such that sections
 >> starting with .foo$ are collapsed at link time into the .foo section.

 > What is it exactly you want to achieve with this?  If this is done
 > only at link time the only difference to the current behavior is that
 > the binary will not contain the information about the sections which
 > is a bit more compact.

For, say, .ctors and .debug_info, it is required for correctness.

 > What I really don't like at all about this is magic with names.  Yes,
 > BFD does it today but it is a horrible idea.  If this behavior is needed
 > then there should be a way to describe this in ELF and not in names.

I wouldn't object to turning the linkonce property into an ELF flag (or
just implementing the COMDAT groups feature), but when the key you want to
control section matching is already a symbol name, it makes sense to put it
in the section name.

Jason


More information about the Binutils mailing list