diff options
Diffstat (limited to '')
-rw-r--r-- | tests/codegen/sanitizer-no-sanitize.rs | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/tests/codegen/sanitizer-no-sanitize.rs b/tests/codegen/sanitizer-no-sanitize.rs deleted file mode 100644 index fb9d249da..000000000 --- a/tests/codegen/sanitizer-no-sanitize.rs +++ /dev/null @@ -1,29 +0,0 @@ -// Verifies that no_sanitize attribute can be used to -// selectively disable sanitizer instrumentation. -// -// needs-sanitizer-address -// compile-flags: -Zsanitizer=address - -#![crate_type="lib"] -#![feature(no_sanitize)] - -// CHECK-LABEL: ; sanitizer_no_sanitize::unsanitized -// CHECK-NEXT: ; Function Attrs: -// CHECK-NOT: sanitize_address -// CHECK: start: -// CHECK-NOT: call void @__asan_report_load -// CHECK: } -#[no_sanitize(address)] -pub fn unsanitized(b: &mut u8) -> u8 { - *b -} - -// CHECK-LABEL: ; sanitizer_no_sanitize::sanitized -// CHECK-NEXT: ; Function Attrs: -// CHECK: sanitize_address -// CHECK: start: -// CHECK: call void @__asan_report_load -// CHECK: } -pub fn sanitized(b: &mut u8) -> u8 { - *b -} |