Recommit "rL366894: [yaml2obj] - Allow custom fields for the SHT_UNDEF sections."
[llvm-complete.git] / test / tools / llvm-profdata / invalid-profdata.test
blobb6391b03464a55cff64070a37c85c01a7fdc8e79
1 RUN: echo ":ir"                     > %t.input
2 RUN: echo "_ZN6Thread5StartEv"      >> %t.input
3 RUN: echo "# Func Hash:"            >> %t.input
4 RUN: echo "288793635542036872"      >> %t.input
5 RUN: echo "# Num Counters:"         >> %t.input
6 RUN: echo "3"                       >> %t.input
7 RUN: echo "# Counter Values:"       >> %t.input
8 RUN: echo "0"                       >> %t.input
9 RUN: echo "12"                      >> %t.input
10 RUN: echo "12"                      >> %t.input
11 RUN: echo "# Num Value Kinds:"      >> %t.input
12 RUN: echo "1"                       >> %t.input
13 RUN: echo "# ValueKind = IPVK_IndirectCallTarget:"       >> %t.input
14 RUN: echo "0"                                            >> %t.input
15 RUN: echo "# NumValueSites:"                             >> %t.input
16 RUN: echo "2"                                            >> %t.input
17 RUN: echo "2"                                            >> %t.input
18 RUN: echo "f1:10"                                        >> %t.input
19 RUN: echo "f2:0"                                         >> %t.input
20 RUN: echo "1"                                            >> %t.input
21 RUN: echo ":10"                                          >> %t.input
23 RUN: not llvm-profdata merge %t.input -text -output=/dev/null 2>&1  | FileCheck %s --check-prefix=BROKEN
24 BROKEN: Malformed instrumentation profile data
26 RUN: echo ":ir"                     > %t.input
27 RUN: echo "_ZN6Thread5StartEv"      >> %t.input
28 RUN: echo "# Func Hash:"            >> %t.input
29 RUN: echo "288793635542036872"      >> %t.input
30 RUN: echo "# Num Counters:"         >> %t.input
31 RUN: echo "3"                       >> %t.input
32 RUN: echo "# Counter Values:"       >> %t.input
33 RUN: echo "0"                       >> %t.input
34 RUN: echo "12"                      >> %t.input
35 RUN: echo "12"                      >> %t.input
36 RUN: echo "# Num Value Kinds:"      >> %t.input
37 RUN: echo "1"                       >> %t.input
38 RUN: echo "# ValueKind = IPVK_IndirectCallTarget:"       >> %t.input
39 RUN: echo "0"                                            >> %t.input
40 RUN: echo "# NumValueSites:"                             >> %t.input
41 RUN: echo "2"                                            >> %t.input
42 RUN: echo "2"                                            >> %t.input
43 RUN: echo "f1:10"                                        >> %t.input
44 RUN: echo "f2:0"                                         >> %t.input
45 RUN: echo "1"                                            >> %t.input
46 RUN: echo "** External Symbol **:10"             >> %t.input
48 # RUN: llvm-profdata merge %t.input -text -output=%t.out && cat %t.out | FileCheck %s
50 CHECK: ** External Symbol **:10