Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
gh-104635: Expand optimization for dead store elimination#106571
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
corona10 commentedJul 9, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Interesting crash; this crash was not triggered at my local machine. I will take a look. -> Done |
corona10 commentedJul 9, 2023
@carljm Please take a look :) |
corona10 commentedJul 10, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
|
corona10 commentedJul 10, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@carljm Ready to review, I wanted the linear time complexity for the first time, but it will require more. |
corona10 commentedJul 10, 2023
Found more edge case, I will close the PR. We may need some kinds of use-def analysis |
markshannon commentedJul 10, 2023
I'm still unconvinced that this can do anything that a superoptimizer could not do.
If you are only looking at linear sequences of instructions that are on a single line then, almost by definition, a superoptimizer will do at least as well. |
corona10 commentedJul 10, 2023
Yeah, I agree if the super-optimizer is added, I expect that most of the cases will be covered, but I just tried it because the super-optimizer infra does not exist at this moment. More digging will be more expensive than I expect, so I am not going to cover those cases at this moment. (At least, we may need to add use-def analysis, but it should be compared to adding a super-optimizer process) |
Uh oh!
There was an error while loading.Please reload this page.
Explain
This PR is motivated by@carljm 's comment from#105040 (comment)
The limitation of#105320 is that the optimization only covers the next redundant opcode, but with this patch, the optimization can be applied to more than one instruction ahead for another write to the same location.
Benchmark
TODO (Done)