llvm-project/llvm/test/tools/llvm-profdata/Inputs
Hongtao Yu ad2a59f584 [CSSPGO] Introducing dangling pseudo probes.
Dangling probes are the probes associated to an empty block. This usually happens when all real instructions are optimized away from the block. There is a problem with dangling probes during the offline counts processing. The way the sample profiler works is that samples collected on the first physical instruction following a probe will be counted towards the probe. This logically equals to treating the instruction next to a probe as if it is from the same block of the probe. In the dangling probe case, the real instruction following a dangling probe actually starts a new block, and samples collected on the new block may cause issues when counted towards the empty block.

To mitigate this issue, we first try to move around a dangling probe inside its owning block. If there are still native instructions preceding the probe in the same block, we can then use them as a place holder to collect samples for the probe. A pass is added to walk each block backwards looking for probes not followed by any real instruction and moving them before the first real instruction. This is done right before the object emission.

If we are unlucky to find such in-block preceding instructions for a probe, the solution we are taking is to tag such probe as dangling so that the samples reported for them will not be trusted by the compiler. We leave it up to the counts inference algorithm to get such probes a reasonable count. The number `UINT64_MAX` is used to mark sample count as collected for a dangling probe.

Reviewed By: wmi

Differential Revision: https://reviews.llvm.org/D95962
2021-03-03 22:44:41 -08:00
..
CSIR_profile.proftext
IR_profile.proftext
bad-hash.proftext
bar3-1.proftext
basic.proftext
c-general.profraw [profile] Add a mode to continuously sync counter updates to a file 2019-10-31 16:04:09 -07:00
clang_profile.proftext
compat-sample.profdata
compat.profdata.v1
compat.profdata.v2
compat.profdata.v4
compressed.profraw [profile] Fourth fix for toolchains without zlib after D68351 2019-10-31 16:46:22 -07:00
counter-mismatch-1.proftext
counter-mismatch-2.proftext
counter-mismatch-3.proftext
counter-mismatch-4.proftext
cs-sample.proftext [CSSPGO] Support of CS profiles in extended binary format. 2021-01-27 21:29:46 -08:00
cs.proftext
cutoff.proftext
empty.proftext
extra-word.proftext
foo3-1.proftext
foo3-2.proftext
foo3bar3-1.proftext
gcc-sample-profile.gcov
header-directives-1.proftext [PGO] Supporting code for always instrumenting entry block 2020-07-22 15:01:53 -07:00
header-directives-2.proftext [PGO] Supporting code for always instrumenting entry block 2020-07-22 15:01:53 -07:00
header-directives-3.proftext [PGO] Supporting code for always instrumenting entry block 2020-07-22 15:01:53 -07:00
inline-samples.afdo
instr-remap.expected
instr-remap.proftext
instr-remap.remap
invalid-count-later.proftext
mix_instr.proftext Supplement instr profile with sample profile. 2020-07-27 20:17:40 -07:00
mix_sample.proftext Supplement instr profile with sample profile. 2020-07-27 20:17:40 -07:00
multiple-profdata-merge.proftext
no-counts.proftext
noncs.proftext
overflow-instr.proftext
overflow-sample.proftext
overlap_1.proftext
overlap_1_cs.proftext
overlap_1_vp.proftext
overlap_2.proftext
overlap_2_cs.proftext
overlap_2_vp.proftext
profile-symbol-list-1.text [SampleFDO] Add profile symbol list section to discriminate function being 2019-08-31 02:27:26 +00:00
profile-symbol-list-2.text [SampleFDO] Add profile symbol list section to discriminate function being 2019-08-31 02:27:26 +00:00
profile-symbol-list.expected [SampleFDO] Add profile symbol list section to discriminate function being 2019-08-31 02:27:26 +00:00
pseudo-probe-profile.proftext [CSSPGO] Introducing dangling pseudo probes. 2021-03-03 22:44:41 -08:00
same-name-1.proftext
same-name-2.proftext
same-name-3.proftext
same-name-4.proftext
sample-hot-func-list.proftext Add --hot-func-list to llvm-profdata show for sample profiles 2020-06-24 12:49:46 -07:00
sample-overlap-0.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-overlap-1.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-overlap-2.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-overlap-3.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-overlap-4.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-overlap-5.proftext [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
sample-profile.proftext [AutoFDO] Make call targets order deterministic for sample profile 2019-08-20 20:52:00 +00:00
sample-remap.expected
sample-remap.proftext
sample-remap.remap
text-format-errors.text.bin
vp-malform.proftext
vp-malform2.proftext
vp-truncate.proftext
weight-instr-bar.profdata
weight-instr-foo.profdata
weight-sample-bar.proftext
weight-sample-foo.proftext