mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 12:12:47 +01:00
fd411b2b5d
This fixes support for merging profiles which broke as a consequence of e50a38840dc3db5813f74b1cd2e10e6d984d0e67. The issue was missing adjustment in merge logic to account for the binary IDs which are now included in the raw profile just after header. In addition, this change also: * Includes the version in module signature that's used for merging to avoid accidental attempts to merge incompatible profiles. * Moves the binary IDs size field after version field in the header as was suggested in the review. Differential Revision: https://reviews.llvm.org/D107143 (cherry picked from commit 83302c84890e5e6cb74c7d6c9f8eaaa56db0077c)
51 lines
1.5 KiB
Plaintext
51 lines
1.5 KiB
Plaintext
RUN: printf '\377lprofR\201' > %t
|
|
RUN: printf '\0\0\0\0\0\0\0\7' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\2' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\3' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\20' >> %t
|
|
RUN: printf '\0\0\0\0\1\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0\2\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
|
|
RUN: printf '\134\370\302\114\333\030\275\254' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\1' >> %t
|
|
RUN: printf '\1\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\1' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
|
|
RUN: printf '\344\023\165\112\031\035\265\067' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\2' >> %t
|
|
RUN: printf '\1\0\0\10' >> %t
|
|
RUN: printf '\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\0' >> %t
|
|
RUN: printf '\0\0\0\2' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\0' >> %t
|
|
|
|
RUN: printf '\0\0\0\0\0\0\0\023' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\067' >> %t
|
|
RUN: printf '\0\0\0\0\0\0\0\101' >> %t
|
|
RUN: printf '\7\0foo\1bar\0\0\0\0\0\0\0' >> %t
|
|
|
|
RUN: llvm-profdata show %t -all-functions -counts | FileCheck %s
|
|
|
|
CHECK: Counters:
|
|
CHECK: foo:
|
|
CHECK: Hash: 0x0000000000000001
|
|
CHECK: Counters: 1
|
|
CHECK: Function count: 19
|
|
CHECK: Block counts: []
|
|
CHECK: bar:
|
|
CHECK: Hash: 0x0000000000000002
|
|
CHECK: Counters: 2
|
|
CHECK: Function count: 55
|
|
CHECK: Block counts: [65]
|
|
CHECK: Functions shown: 2
|
|
CHECK: Total functions: 2
|
|
CHECK: Maximum function count: 55
|
|
CHECK: Maximum internal block count: 65
|