-
Notifications
You must be signed in to change notification settings - Fork 13.7k
[BOLT] Drop high discrepancy profiles in matching #95156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
shawbyoung
merged 17 commits into
users/shawbyoung/spr/main.bolt-drop-high-discrepancy-profiles-in-matching-1
from
users/shawbyoung/spr/bolt-drop-high-discrepancy-profiles-in-matching-1
Jun 17, 2024
Merged
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
c886112
[𝘀𝗽𝗿] initial version
shawbyoung aa441dc
Summary: Functions with little exact matching
shawbyoung 46fa37a
Update SampleProfileInference.h
shawbyoung d532514
Update StaleProfileMatching.cpp
shawbyoung 3fc6d72
spr amend
shawbyoung 1ae7f02
spr amend
shawbyoung c5a1625
spr amend
shawbyoung 544b2eb
spr amend
shawbyoung 72feffe
spr amend
shawbyoung a4c4c39
spr amend
shawbyoung 77a48e7
spr amend
shawbyoung a5e2c0e
spr amend
shawbyoung c536128
spr amend
shawbyoung 2398e96
spr amend
shawbyoung cb0efe0
spr ameand
shawbyoung 8550bc3
Update bolt/lib/Profile/StaleProfileMatching.cpp
shawbyoung de97604
Update StaleProfileMatching.cpp
shawbyoung File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
57 changes: 57 additions & 0 deletions
57
bolt/test/X86/Inputs/blarge_profile_stale_low_matched_blocks.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- | ||
header: | ||
profile-version: 1 | ||
binary-name: 'reader-yaml.test.tmp.exe' | ||
binary-build-id: '<unknown>' | ||
profile-flags: [ lbr ] | ||
profile-origin: branch profile reader | ||
profile-events: '' | ||
dfs-order: false | ||
hash-func: xxh3 | ||
functions: | ||
- name: SolveCubic | ||
fid: 6 | ||
hash: 0x0000000000000000 | ||
exec: 151 | ||
nblocks: 18 | ||
blocks: | ||
- bid: 0 | ||
insns: 43 | ||
hash: 0x4600940a609c0000 | ||
exec: 151 | ||
succ: [ { bid: 1, cnt: 151, mis: 2 }, { bid: 7, cnt: 0 } ] | ||
- bid: 1 | ||
insns: 7 | ||
hash: 0x167a1f084f130088 | ||
succ: [ { bid: 13, cnt: 151 }, { bid: 2, cnt: 0 } ] | ||
- bid: 13 | ||
insns: 26 | ||
hash: 0xa8d50000f81902a7 | ||
succ: [ { bid: 3, cnt: 89 }, { bid: 2, cnt: 10 } ] | ||
- bid: 3 | ||
insns: 9 | ||
hash: 0xc516000073dc00a0 | ||
succ: [ { bid: 5, cnt: 151 } ] | ||
- bid: 5 | ||
insns: 9 | ||
hash: 0x6446e1ea500111 | ||
- name: usqrt | ||
fid: 7 | ||
hash: 0x0000000000000000 | ||
exec: 20 | ||
nblocks: 6 | ||
blocks: | ||
- bid: 0 | ||
insns: 4 | ||
hash: 0x0000000000000001 | ||
exec: 20 | ||
succ: [ { bid: 1, cnt: 0 } ] | ||
- bid: 1 | ||
insns: 9 | ||
hash: 0x0000000000000001 | ||
succ: [ { bid: 3, cnt: 320, mis: 171 }, { bid: 2, cnt: 0 } ] | ||
- bid: 3 | ||
insns: 2 | ||
hash: 0x0000000000000001 | ||
succ: [ { bid: 1, cnt: 300, mis: 33 }, { bid: 4, cnt: 20 } ] | ||
... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
## This script checks the stale-matching-min-matched-block flag. | ||
|
||
RUN: yaml2obj %p/Inputs/blarge.yaml &> %t.exe | ||
|
||
## Testing "usqrt" | ||
RUN: llvm-bolt %t.exe -o %t.null --b %p/Inputs/blarge_profile_stale_low_matched_blocks.yaml \ | ||
RUN: --infer-stale-profile=1 --stale-matching-min-matched-block=75 \ | ||
RUN: --profile-ignore-hash=1 --debug-only=bolt-prof 2>&1 | FileCheck %s | ||
|
||
CHECK: BOLT-INFO: inferred profile for 1 (50.00% of profiled, 50.00% of stale) functions responsible for 46.31% samples (552 out of 1192) |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.