Skip to content

Commit 173ee3a

Browse files
committed
Write to temporary file and redirect that to FileCheck (actually
calling FileCheck this time).
1 parent bd22baa commit 173ee3a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

compiler-rt/test/profile/Linux/binary-id-offset.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@
99
// REDEFINE: %{cflags} = -no-pie
1010
// RUN: %clang_profgen -fuse-ld=lld -Wl,--build-id -o %t %s %{cflags}
1111
// RUN: env LLVM_PROFILE_FILE=%t.profraw %run %t
12-
// RUN: llvm-readelf --notes %t && llvm-profdata show --binary-ids %t.profraw > FileCheck
12+
// RUN: llvm-readelf --notes %t > %t2 && llvm-profdata show --binary-ids %t.profraw >> %t2 && FileCheck %s < %t2
1313

1414
// REDEFINE: %{cflags} = -pie -fPIE
1515
// RUN: %clang_profgen -fuse-ld=lld -Wl,--build-id -o %t %s %{cflags}
1616
// RUN: env LLVM_PROFILE_FILE=%t.profraw %run %t
17-
// RUN: llvm-readelf --notes %t && llvm-profdata show --binary-ids %t.profraw > FileCheck
17+
// RUN: llvm-readelf --notes %t > %t2 && llvm-profdata show --binary-ids %t.profraw >> %t2 && FileCheck %s < %t2
1818

1919
// Moving the note after .bss also gives it extra LOAD segment padding,
2020
// making its memory offset different than its file offset.
@@ -23,12 +23,12 @@
2323
// REDEFINE: %{cflags} = -no-pie -Wl,--script=%t.script
2424
// RUN: %clang_profgen -fuse-ld=lld -Wl,--build-id -o %t %s %{cflags}
2525
// RUN: env LLVM_PROFILE_FILE=%t.profraw %run %t
26-
// RUN: llvm-readelf --notes %t && llvm-profdata show --binary-ids %t.profraw > FileCheck
26+
// RUN: llvm-readelf --notes %t > %t2 && llvm-profdata show --binary-ids %t.profraw >> %t2 && FileCheck %s < %t2
2727

2828
// REDEFINE: %{cflags} = -pie -fPIE -Wl,--script=%t.script
2929
// RUN: %clang_profgen -fuse-ld=lld -Wl,--build-id -o %t %s %{cflags}
3030
// RUN: env LLVM_PROFILE_FILE=%t.profraw %run %t
31-
// RUN: llvm-readelf --notes %t && llvm-profdata show --binary-ids %t.profraw > FileCheck
31+
// RUN: llvm-readelf --notes %t > %t2 && llvm-profdata show --binary-ids %t.profraw >> %t2 && FileCheck %s < %t2
3232

3333
// CHECK-LABEL{LITERAL}: .note.gnu.build-id
3434
// CHECK: Build ID: [[ID:[0-9a-f]+]]

0 commit comments

Comments
 (0)