-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rustc_codegen_llvm: Add a new 'pc' option to branch-protection #132259
Conversation
r? @Nadrieril rustbot has assigned @Nadrieril. Use |
Some changes occurred in src/doc/unstable-book/src/compiler-flags/branch-protection.md cc @rust-lang/project-exploit-mitigations, @rcvalle This PR modifies cc @jieyouxu |
This comment has been minimized.
This comment has been minimized.
e107afd
to
45c2aa0
Compare
Thank you for your time and for working on this, @mrkajetanp! Much appreciated. I've a few questions:
|
I know nothing of codegen r? compiler |
This comment was marked as resolved.
This comment was marked as resolved.
The way it's currently implemented in LLVM is that adding the
As explained above, the The merge conflicts are due to some refactoring from what I can see, I'll rebase once this is approved or once some changes are requested? |
Thank you for all the information, @mrkajetanp! LGTM (FYI, @cuviper). |
Add a new 'pc' option to -Z branch-protection for aarch64 that enables the use of PC as a diversifier in PAC branch protection code. When the pauth-lr target feature is enabled in combination with -Z branch-protection=pac-ret,pc, the new 9.5-a instructions (pacibsppc, retaasppc, etc) will be generated.
45c2aa0
to
10edeea
Compare
r? compiler |
@mrkajetanp is a colleague of mine so hadn't assigned myself to review and approve previously, but given that @rcvalle has also reviewed, I'm happy to approve it. r? @davidtwco |
…-lr, r=davidtwco rustc_codegen_llvm: Add a new 'pc' option to branch-protection Add a new 'pc' option to -Z branch-protection for aarch64 that enables the use of PC as a diversifier in PAC branch protection code. When the pauth-lr target feature is enabled in combination with -Z branch-protection=pac-ret,pc, the new 9.5-a instructions (pacibsppc, retaasppc, etc) will be generated.
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#132259 (rustc_codegen_llvm: Add a new 'pc' option to branch-protection) - rust-lang#132409 (CI: switch 7 linux jobs to free runners) - rust-lang#132498 (Suggest fixing typos and let bindings at the same time) - rust-lang#132524 (chore(style): sync submodule exclusion list between tidy and rustfmt) - rust-lang#132567 (Properly suggest `E::assoc` when we encounter `E::Variant::assoc`) - rust-lang#132571 (add const_eval_select macro to reduce redundancy) - rust-lang#132637 (Do not filter empty lint passes & re-do CTFE pass) - rust-lang#132642 (Add documentation on `ast::Attribute`) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#132259 - mrkajetanp:branch-protection-pauth-lr, r=davidtwco rustc_codegen_llvm: Add a new 'pc' option to branch-protection Add a new 'pc' option to -Z branch-protection for aarch64 that enables the use of PC as a diversifier in PAC branch protection code. When the pauth-lr target feature is enabled in combination with -Z branch-protection=pac-ret,pc, the new 9.5-a instructions (pacibsppc, retaasppc, etc) will be generated.
Add a new 'pc' option to -Z branch-protection for aarch64 that enables the use of PC as a diversifier in PAC branch protection code.
When the pauth-lr target feature is enabled in combination with -Z branch-protection=pac-ret,pc, the new 9.5-a instructions (pacibsppc, retaasppc, etc) will be generated.