[PATCH v2 2/3] sframe: additonal check in _bfd_x86_elf_link_setup_gnu_properties

Jan Beulich jbeulich@suse.com
Fri Jan 16 09:37:12 GMT 2026


On 14.01.2026 11:34, Jens Remus wrote:
> On 1/14/2026 11:05 AM, claudiu.zissulescu-ianculescu@oracle.com wrote:
>> From: Indu Bhagat <indu.bhagat@oracle.com>
>>
>> GNU ld creates SFrame stack trace info for the .plt* sections.  These
>> linker created sections are created in
>> _bfd_x86_elf_link_setup_gnu_properties (), but data is emitted into
>> them a bit later in _bfd_x86_elf_late_size_sections ().
>>
>> With SFrame sections now marked KEEP in scripttempl/elf.sc, and the
>> presence of these linker created SFrame sections cause emission of an
>> empty .sframe for all ELF targets (IIUC), even when all input bfd's
>> have no .sframe section.
>>
>> This patch is an attempt to avoid creation of empty .sframe in linked
>> objects on x86_64 and s390x, when none of the inputs had SFrame sections.
> 
> Thanks for taking care of s390x!  _bfd_elf_sframe_present_input_bfds is
> also a neat improvement.

And Arm64 doesn't need a similar adjustment?

Jan


More information about the Binutils mailing list