mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-25 00:46:05 +00:00

When using debug info correlation, value profiling needs to be switched off. So, we are only merging counter sections. In that case the existance of data section is just used to provide an extra check in case of corrupted profile. This patch performs counter merging by iterating the counter section by counter size and add them together. Reviewed By: ellis, MaskRay Differential Revision: https://reviews.llvm.org/D157632
10 lines
408 B
C
10 lines
408 B
C
// RUN: rm -rf %t; mkdir %t
|
|
|
|
// RUN: %clang_pgogen -o %t/timeprof -mllvm -pgo-temporal-instrumentation %s
|
|
// RUN: env LLVM_PROFILE_FILE=%t/timeprof_%m.profdata %run %t/timeprof 2>&1 | count 0
|
|
// RUN: env LLVM_PROFILE_FILE=%t/timeprof_%m.profdata %run %t/timeprof 2>&1 | FileCheck %s --check-prefix=TIMEPROF
|
|
|
|
// TIMEPROF: Temporal profiles do not support profile merging at runtime.
|
|
|
|
int main() { return 0; }
|