rust/compiler/rustc_codegen_ssa/src/traits
bors db8086eb60 Auto merge of #95548 - rcvalle:rust-cfi-2, r=nagisa
Add fine-grained LLVM CFI support to the Rust compiler

This PR improves the LLVM Control Flow Integrity (CFI) support in the Rust compiler by providing forward-edge control flow protection for Rust-compiled code only by aggregating function pointers in groups identified by their return and parameter types.

Forward-edge control flow protection for C or C++ and Rust -compiled code "mixed binaries" (i.e., for when C or C++ and Rust -compiled code share the same virtual address space) will be provided in later work as part of this project by identifying C char and integer type uses at the time types are encoded (see Type metadata in the design document in the tracking issue https://github.com/rust-lang/rust/issues/89653).

LLVM CFI can be enabled with -Zsanitizer=cfi and requires LTO (i.e., -Clto).

Thank you again, `@eddyb,` `@nagisa,` `@pcc,` and `@tmiasko` for all the help!
2022-07-24 01:22:36 +00:00
..
abi.rs Feat: make cg_ssa get_param borrow the builder mutable 2021-11-23 22:30:20 -05:00
asm.rs Add codegen for global_asm! sym operands 2022-04-15 14:36:30 +01:00
backend.rs Keep unstable target features for asm feature checking 2022-07-11 14:26:58 +01:00
builder.rs Auto merge of #95548 - rcvalle:rust-cfi-2, r=nagisa 2022-07-24 01:22:36 +00:00
consts.rs don't allow ZST in ScalarInt 2022-07-09 07:27:29 -04:00
coverageinfo.rs Stabilize -Z instrument-coverage as -C instrument-coverage 2022-01-01 15:57:35 -08:00
debuginfo.rs debuginfo: Refactor debuginfo generation for types -- Rename DebugInfoMethods::create_vtable_metadata() to DebugInfoMethods::create_vtable_debuginfo() 2022-03-14 17:25:24 +01:00
declare.rs Remove DeclareMethods 2020-09-18 13:11:59 +02:00
intrinsic.rs Add llvm.type.checked.load intrinsic 2022-06-14 14:50:52 +02:00
misc.rs Always use llvm.used for coverage symbols 2021-08-21 10:08:05 +02:00
mod.rs Add fine-grained LLVM CFI support to the Rust compiler 2022-07-23 10:51:34 -07:00
statics.rs Only compile #[used] as llvm.compiler.used for ELF targets 2022-05-11 01:29:56 -07:00
type_.rs Add fine-grained LLVM CFI support to the Rust compiler 2022-07-23 10:51:34 -07:00
write.rs Remove config parameter of optimize_fat and avoid interior mutability for module 2022-04-30 20:58:42 +02:00