brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.5 KiB · 83adf6d Raw
44 lines · plain
1Tests for overflow when merging sampled profiles.2 31- Merge profile having maximum counts with itself and verify overflow detected4RUN: llvm-profdata merge -sample %p/Inputs/overflow-sample.proftext %p/Inputs/overflow-sample.proftext -o %t.out 2>&1 | FileCheck %s -check-prefix=MERGE_OVERFLOW5RUN: llvm-profdata show -sample %t.out | FileCheck %s --check-prefix=SHOW_OVERFLOW6MERGE_OVERFLOW: {{.*}}: main: Counter overflow7SHOW_OVERFLOW-DAG: Function: main: 2000, 0, 2 sampled lines8SHOW_OVERFLOW-DAG: Samples collected in the function's body {9SHOW_OVERFLOW-DAG:   1: 1000, calls: _Z3bari:1844674407370955161510SHOW_OVERFLOW-DAG:   2: 1000, calls: _Z3fooi:1844674407370955161511SHOW_OVERFLOW-DAG: }12SHOW_OVERFLOW-DAG: No inlined callsites in this function13SHOW_OVERFLOW-DAG: Function: _Z3fooi: 18446744073709551615, 2000, 1 sampled lines14SHOW_OVERFLOW-DAG: Samples collected in the function's body {15SHOW_OVERFLOW-DAG:   1: 1844674407370955161516SHOW_OVERFLOW-DAG: }17SHOW_OVERFLOW-DAG: No inlined callsites in this function18SHOW_OVERFLOW-DAG: Function: _Z3bari: 18446744073709551615, 2000, 1 sampled lines19SHOW_OVERFLOW-DAG: Samples collected in the function's body {20SHOW_OVERFLOW-DAG:   1: 1844674407370955161521SHOW_OVERFLOW-DAG: }22SHOW_OVERFLOW-DAG: No inlined callsites in this function23 242- Merge profile having maximum counts by itself and verify no overflow25RUN: llvm-profdata merge -sample %p/Inputs/overflow-sample.proftext -o %t.out 2>&1 | FileCheck %s -allow-empty -check-prefix=MERGE_NO_OVERFLOW26RUN: llvm-profdata show -sample %t.out | FileCheck %s --check-prefix=SHOW_NO_OVERFLOW27MERGE_NO_OVERFLOW-NOT: {{.*}}: main: Counter overflow28SHOW_NO_OVERFLOW-DAG: Function: main: 1000, 0, 2 sampled lines29SHOW_NO_OVERFLOW-DAG: Samples collected in the function's body {30SHOW_NO_OVERFLOW-DAG:   1: 500, calls: _Z3bari:1844674407370955161531SHOW_NO_OVERFLOW-DAG:   2: 500, calls: _Z3fooi:1844674407370955161532SHOW_NO_OVERFLOW-DAG: }33SHOW_NO_OVERFLOW-DAG: No inlined callsites in this function34SHOW_NO_OVERFLOW-DAG: Function: _Z3fooi: 18446744073709551615, 1000, 1 sampled lines35SHOW_NO_OVERFLOW-DAG: Samples collected in the function's body {36SHOW_NO_OVERFLOW-DAG:   1: 1844674407370955161537SHOW_NO_OVERFLOW-DAG: }38SHOW_NO_OVERFLOW-DAG: No inlined callsites in this function39SHOW_NO_OVERFLOW-DAG: Function: _Z3bari: 18446744073709551615, 1000, 1 sampled lines40SHOW_NO_OVERFLOW-DAG: Samples collected in the function's body {41SHOW_NO_OVERFLOW-DAG:   1: 1844674407370955161542SHOW_NO_OVERFLOW-DAG: }43SHOW_NO_OVERFLOW-DAG: No inlined callsites in this function44