2016-05-22 06:55:45 +08:00
|
|
|
// RUN: %clang_profgen -O2 -mllvm -enable-value-profiling=true -mllvm -vp-static-alloc=true -mllvm -vp-counters-per-site=10 -o %t %S/Inputs/instrprof-value-prof-evict.c
|
2016-05-20 05:35:34 +08:00
|
|
|
// RUN: env LLVM_PROFILE_FILE=%t.profraw %run %t
|
|
|
|
// RUN: llvm-profdata merge -o %t.profdata %t.profraw
|
|
|
|
// RUN: llvm-profdata show --all-functions -ic-targets %t.profdata | FileCheck %S/Inputs/instrprof-value-prof-evict.c
|
|
|
|
|
|
|
|
// IR level instrumentation
|
2016-07-20 06:12:00 +08:00
|
|
|
// RUN: %clang_pgogen -O2 -mllvm -disable-vp=false -mllvm -vp-static-alloc=true -mllvm -vp-counters-per-site=10 -o %t.ir %S/Inputs/instrprof-value-prof-evict.c
|
2016-05-20 05:35:34 +08:00
|
|
|
// RUN: env LLVM_PROFILE_FILE=%t.ir.profraw %run %t.ir
|
|
|
|
// RUN: llvm-profdata merge -o %t.ir.profdata %t.ir.profraw
|
|
|
|
// RUN: llvm-profdata show --all-functions -ic-targets %t.ir.profdata | FileCheck %S/Inputs/instrprof-value-prof-evict.c
|
2016-05-22 06:55:45 +08:00
|
|
|
|
|
|
|
// IR level instrumentation, dynamic allocation
|
2016-07-20 06:12:00 +08:00
|
|
|
// RUN: %clang_pgogen -O2 -mllvm -disable-vp=false -mllvm -vp-static-alloc=false -o %t.ir.dyn %S/Inputs/instrprof-value-prof-evict.c
|
2016-05-22 06:55:45 +08:00
|
|
|
// RUN: env LLVM_PROFILE_FILE=%t.ir.dyn.profraw %run %t.ir.dyn
|
|
|
|
// RUN: llvm-profdata merge -o %t.ir.dyn.profdata %t.ir.dyn.profraw
|
|
|
|
// RUN: llvm-profdata show --all-functions -ic-targets %t.ir.dyn.profdata | FileCheck %S/Inputs/instrprof-value-prof-evict.c
|