-
Notifications
You must be signed in to change notification settings - Fork 396
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
Replace shifts and rotations of constant 0 with constant 0 #7398
Replace shifts and rotations of constant 0 with constant 0 #7398
Conversation
Since applying a shift or rotation to 0 simply produces 0 again, the optimizer can replace any shift or rotation for which the first child is a constant 0 with that constant 0 Signed-off-by: Dylan Tuttle <jdylantuttle@gmail.com>
@hzongaro Could I get a review on this (hopefully) fixed version? |
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.
I think your changes look good. Thanks!
Jenkins build all |
@dylanjtuttle, have you run further internal testing of your changes just to make sure everything is exercised fully? If so, may I ask you to post a link to the internal build? |
I have not, let me start one and get back to you when it finishes! |
An internal build with these changes passes |
Yes, thank you - although the problems that we saw with an earlier iteration seemed to occur most frequently with OpenJ9 JDK 21. It could be that changes in the class libraries presented more opportunities for this optimization. May I ask you to rerun that internal build for JDK 21 on a few different platforms? |
After dealing with some flakiness, I got the results I was hoping for: original first rebuild second rebuild |
Thank you! Merging. |
Since applying a shift or rotation to 0 simply produces 0 again, the optimizer can replace any shift or rotation for which the first child is a constant 0 with that constant 0.