Skip to content

Commit 6582785

Browse files
authored
Add CHECK-LABEL to avoid source tree path sensitivity in test (llvm#112461)
The test `clang/test/CodeGen/2004-02-20-Builtins.c` will erroneously fail if "builtin" is in the path to your source tree. This change adds a `CHECK-LABEL !llvm.ident` after the `CHECK-NOT` to avoid searching into the metadata containing the path.
1 parent e4e9fea commit 6582785

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

clang/test/CodeGen/2004-02-20-Builtins.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ double sqrt(double x);
33

44
// CHECK-LABEL: @zsqrtxxx
55
// CHECK-NOT: builtin
6+
// Don't search into metadata definitions. !llvm.ident can contain the
7+
// substring "builtin" if it's in the source tree path.
8+
// CHECK-LABEL: !llvm.ident
69
void zsqrtxxx(float num) {
710
num = sqrt(num);
811
}

0 commit comments

Comments
 (0)