Skip to content

Calculate fn ptr type discriminator from FnAbi#3

Draft
jchlanda wants to merge 19 commits into
jakub/pac_ty_discfrom
jakub/pac_ty_disc_no_FnAbi
Draft

Calculate fn ptr type discriminator from FnAbi#3
jchlanda wants to merge 19 commits into
jakub/pac_ty_discfrom
jakub/pac_ty_disc_no_FnAbi

Conversation

@jchlanda

Copy link
Copy Markdown
Owner

Note: This is an experiment, we harness the fact that FnAbi contains type information for both return and arguments (alongside, lowered, ABI info).

jchlanda added 19 commits July 14, 2026 09:28
Alongside Rust implementation of LLVM's SipHash-2-4.
This is only to be used when emitting an operand bundle, which might not
have access to an Instance of the function, but for which FnAbi is
guaranteed to be correct.
Start moving away from global schema, by cloning it into users.
Helpers for fn ptr type discrimination status and value of the key.
This is a move away from a blind bitcast between the types. Now, when
dealing with function pointers, transmute will detect a domain change
(change of fn ptr type) and issue resigning.
As the libc changes was merged in to the main we do not need to patch
it. cc-rs still needs to be patched as compiler/rustc_llvm/Cargo.toml
still pins to an old version: cc = "=1.2.16"
Note: This is an experiment, we harness the fact that FnAbi contains
type information for both return and arguments (alongside, lowered, ABI
info).
@jchlanda
jchlanda force-pushed the jakub/pac_ty_disc branch 2 times, most recently from c224581 to cff5996 Compare July 17, 2026 06:56
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.

1 participant