Landing: d77630b6d6e9
Project / Subsystem
binutils / bfd
Date
2026-08-17
Author
Alan Modra <amodra@gmail.com>
Commit
d77630b6d6e9fae8cf74e32816cb52e7b2ffcbcb
Source
public_inbox
Perf win
No
Breaking
No
All attributes
- project
- binutils
- subsystem
- bfd
- patch_id
- —
- commit_hash
- d77630b6d6e9fae8cf74e32816cb52e7b2ffcbcb
- source_type
- public_inbox
- headline
- Extract input object compatibility checks into a new function
- tldr
- Introduces ``compatible_format`` function to centralize input object compatibility checks in elflink.c.
- author
- Alan Modra <amodra@gmail.com>
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • linker
- • elf
- • refactoring
- • code-reuse
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-08-17T00:00:00.000Z
This change introduces a new function, compatible_format, in elflink.c to consolidate various checks that determine if an input object file is compatible with the linker’s output. This function is then used in several places, including _bfd_elf_link_create_dynstrtab and _bfd_elf_link_iterate_on_relocs, to ensure consistency and reduce code duplication.