llvm-project/clang/test/CodeGen/xray-function-index.c
Fangrui Song 63bd6d9e64 [Driver] Default to -fxray-function-index
As explained by commit 849f1dd15e92fda2b83dbb6144e6b28b2cb946e0,
-fxray-function-index was the original default but was accidentally flipped by
commit d8a8e5d6240a1db809cd95106910358e69bbf299. Restore the previous behavior.

Originally reported by Oleksii Lozovskyi in D145848.
2023-06-11 15:38:13 -07:00

9 lines
399 B
C

// REQUIRES: x86-registered-target
// RUN: %clang_cc1 -S -triple x86_64 -fxray-instrument -fxray-instruction-threshold=1 %s -o - | FileCheck %s
// RUN: %clang_cc1 -S -triple x86_64 -fxray-instrument -fxray-instruction-threshold=1 -fno-xray-function-index %s -o - | FileCheck %s --check-prefix=NO
// CHECK: .section xray_fn_idx,"awo",@progbits,foo
// NO-NOT: .section xray_fn_idx
void foo(void) {}