
Adds KCFI arity indicator support to the Rust compiler (see rust-lang/rust#138311, https://github.com/llvm/llvm-project/pull/121070, and https://lore.kernel.org/lkml/CANiq72=3ghFxy8E=AU9p+0imFxKr5iU3sd0hVUXed5BA+KjdNQ@mail.gmail.com/).
11 lines
386 B
Rust
11 lines
386 B
Rust
// Verifies that `-Zsanitizer-kcfi-arity` requires LLVM 21.0.0 or later.
|
|
//
|
|
//@ needs-sanitizer-kcfi
|
|
//@ compile-flags: -Cno-prepopulate-passes -Ctarget-feature=-crt-static -Cpanic=abort -Zsanitizer=kcfi -Zsanitizer-kcfi-arity
|
|
//@ build-fail
|
|
//@ max-llvm-major-version: 20
|
|
|
|
//~? ERROR `-Zsanitizer-kcfi-arity` requires LLVM 21.0.0 or later.
|
|
#![feature(no_core)]
|
|
#![no_core]
|
|
#![no_main]
|