Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork3.1k
[mypyc] Simplify comparison of tuple elements#19396
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
JukkaL left a comment
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.
Nice perf win!
f9fe331 intopython:masterUh oh!
There was an error while loading.Please reload this page.
JukkaL commentedJul 8, 2025
I measured the impact to mypy self check runtime using |
JukkaL commentedJul 8, 2025
I did another measurement and it appears to be random noise, unfortunately. |
Got rid of unnecessary operations when comparing tuple elements returns a bit primitive.
Example code:
IR before:
IR after:
Tested using the following benchmark:
Execution time goes from ~315ms to ~150ms on my machine.