-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[mypyc] Generate faster code for bool comparisons and arithmetic (#14489
) Generate specialized, efficient IR for various operations on bools. These are covered: * Bool comparisons * Mixed bool/integer comparisons * Bool arithmetic (binary and unary) * Mixed bool/integer arithmetic and bitwise ops Mixed operations where the left operand is a `bool` and the right operand is a native int still have some unnecessary conversions between native int and `int`. This would be a bit trickier to fix and is seems rare, so it doesn't seem urgent to fix this. Fixes mypyc/mypyc#968.
- Loading branch information
Showing
6 changed files
with
533 additions
and
26 deletions.
There are no files selected for viewing
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
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
Oops, something went wrong.