Skip to content

Conversation

@drexin
Copy link
Contributor

@drexin drexin commented Dec 12, 2025

…ly forwarders

rdar://163631865

Under certain circumstances the same symbol can be used for different implementations of the forwarders. The forwarders themselves are already emitted with "internal" LLVM linkage, but some particularities in the mapping from SILLinkage to LLVM linkage caused async function pointers to partial apply forwarders to be emitted with linkonce_odr instead, which caused the wrong forwarder to be called at runtime, causing unexpected behavior and crashes.

…ly forwarders

rdar://163631865

Under certain circumstances the same symbol can be used for different implementations of the forwarders.
The forwarders themselves are already emitted with "internal" LLVM linkage, but some particularities in
the mapping from SILLinkage to LLVM linkage caused async function pointers to partial apply forwarders
to be emitted with linkonce_odr instead, which caused the wrong forwarder to be called at runtime, causing
unexpected behavior and crashes.
@drexin drexin requested a review from a team as a code owner December 12, 2025 21:20
@drexin
Copy link
Contributor Author

drexin commented Dec 12, 2025

@swift-ci test

@drexin drexin changed the title [IRGen] Use proper linkage for async function pointers to partial app… [6.2][IRGen] Use proper linkage for async function pointers to partial app… Dec 12, 2025
@drexin drexin added 🍒 release cherry pick Flag: Release branch cherry picks swift 6.2 labels Dec 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🍒 release cherry pick Flag: Release branch cherry picks swift 6.2

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant