-
Notifications
You must be signed in to change notification settings - Fork 100
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
Extend basic block without aggressive memory copy #121
Merged
Conversation
This file contains 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
jserv
reviewed
Apr 4, 2023
jserv
changed the title
Extend basic block with low cost
Extend basic block with lower memory consumption
Apr 4, 2023
jserv
reviewed
Apr 4, 2023
jserv
reviewed
Apr 4, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Improve git commit message. Always mention "IR" in capitalized form. You shall show explicit numbers about memory consumption and potential benefits.
jserv
reviewed
Apr 4, 2023
jserv
changed the title
Extend basic block with lower memory consumption
Extend basic block without aggressive memory copy
Apr 4, 2023
qwe661234
force-pushed
the
wip/low_cost_EBB
branch
from
April 4, 2023 17:02
8e980c6
to
06d960e
Compare
jserv
reviewed
Apr 4, 2023
jserv
reviewed
Apr 4, 2023
jserv
reviewed
Apr 4, 2023
qwe661234
force-pushed
the
wip/low_cost_EBB
branch
from
April 4, 2023 17:22
06d960e
to
33be315
Compare
jserv
reviewed
Apr 4, 2023
jserv
reviewed
Apr 4, 2023
Due to the significant overhead associated with using aggressive memory copy, we opted to use a pointer to the begin of IR array of the basic block we intend to merge, rather than copying whole IR array to the basic block we wish to extend. The performance results obtained from running CoreMark using different implementation strategies for EBB are presented below. As we can see, aggressive memory copy substantially degrades performance. |Test| aggressive memcpy|Compiler | Iterations / Sec |Speedup| |----+------------------+---------+------------------+-------| | BB | |clang-15 | 971.951 | | |----+------------------+---------+------------------+-------| | BB | | gcc-12 | 963.336 | | |----+------------------+---------+------------------+-------| | EBB| O |clang-15 | 1013.070 | +4.2% | |----+------------------+---------+------------------+-------| | EBB| O | gcc-12 | 1020.391 | +6% | |----+------------------+---------+------------------+-------| | EBB| X |clang-15 | 1160.894 | +19.4%| |----+------------------+---------+------------------+-------| | EBB| X | gcc-12 | 1167.938 | +21.2%|
qwe661234
force-pushed
the
wip/low_cost_EBB
branch
from
April 4, 2023 17:47
33be315
to
9b81f4d
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Due to the significant overhead associated with using aggressive memory copy, we opted to use a pointer to the IR of the basic block we intend to merge, rather than copying the IR to the basic block we wish to extend.
The performance results obtained from running CoreMark using different implementation strategies for EBB are presented below. As we can see, aggressive memory copy substantially degrades performance.