Skip to content

Drop the .llvm_addrsig section from rewritten objects#169

Open
MisterDA wants to merge 1 commit into
ocaml:masterfrom
MisterDA:ignore-llvm-addrsig
Open

Drop the .llvm_addrsig section from rewritten objects#169
MisterDA wants to merge 1 commit into
ocaml:masterfrom
MisterDA:ignore-llvm-addrsig

Conversation

@MisterDA

Copy link
Copy Markdown
Contributor

The address-significance table emitted by Clang holds symbol table indices, which become stale when flexlink rewrites an object's symbol table to add the relocation table. lld-link rejects objects with an invalid .llvm_addrsig section. The section is an optional hint for the linker's identical-code-folding pass and can safely be dropped.

It is also possible to tell Clang not to emit this section with -fno-addrsig.

Proper handling of this section could come later, for now it's easy to silently ignore it.

See also:

Comment thread CHANGES Outdated
Comment thread reloc.ml Outdated
The address-significance table emitted by clang holds symbol table
indices, which become stale when flexlink rewrites an object's symbol
table to add the relocation table. lld-link rejects objects with an
invalid `.llvm_addrsig` section. The section is an optional hint for
the linker's identical-code-folding pass and can safely be dropped.
@MisterDA MisterDA force-pushed the ignore-llvm-addrsig branch from 7c9c521 to 0ce9af9 Compare June 18, 2026 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants