3 To update the inputs used below run Inputs/update_memprof_inputs.sh /path/to/updated/clang
4 RUN: llvm-readelf --notes %p/Inputs/buildid.memprofexe > %t1.txt
5 RUN: llvm-profdata show --memory %p/Inputs/buildid.memprofraw --profiled-binary %p/Inputs/buildid.memprofexe -o - > %t2.txt
6 RUN: cat %t1.txt %t2.txt | FileCheck %s
8 Test that we print out the profile build ids when --profiled-binary is empty.
9 RUN: not llvm-profdata show --memory %p/Inputs/buildid.memprofraw -o - 2> %t3.txt
10 RUN: cat %t1.txt %t3.txt | FileCheck %s
12 COM: First extract the id from the llvm-readelf output.
13 CHECK: Build ID: [[ID:[[:xdigit:]]+]]
15 COM: Then match it with the profdata output.
16 CHECK-COUNT-1: BuildId: {{.*}}[[ID]]