-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Bytecode parity #7475
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
Merged
youknowone
merged 34 commits into
RustPython:main
from
youknowone:bytecode-parity-phase1
Mar 23, 2026
Merged
Bytecode parity #7475
Changes from 1 commit
Commits
Show all changes
34 commits
Select commit
Hold shift + click to select a range
40cbc39
Emit TO_BOOL before conditional jumps, fix class/module prologue
youknowone f52276e
Emit MAKE_CELL and COPY_FREE_VARS before RESUME
youknowone 7a9c29d
Emit __static_attributes__ at end of class bodies
youknowone f8f7fbf
Remove expectedFailure from DictProxyTests iter tests
youknowone e3fa83e
Use 1-based stack indexing for LIST_EXTEND, SET_UPDATE, etc.
youknowone 18c23e5
Use plain LOAD_ATTR + PUSH_NULL for calls on imported names
youknowone b2995bc
Duplicate return-None epilogue for fall-through blocks
youknowone 35ac45d
Run cargo fmt on ir.rs
youknowone 1092110
Remove expectedFailure from test_intrinsic_1 in test_dis
youknowone cc23051
Emit TO_BOOL before conditional jumps for all expressions including C…
youknowone 643861b
Add __classdict__ cell for classes with function definitions
youknowone a4753e8
Emit __classdictcell__ store in class body epilogue
youknowone 50eaae4
Always run DCE to remove dead code after terminal instructions
youknowone fdcccad
Restrict LOAD_ATTR plain mode to module/class scope imports
youknowone 83a548e
Eliminate unreachable blocks after jump normalization
youknowone 6a592dd
Fold BUILD_TUPLE 0 into LOAD_CONST empty tuple
youknowone 1d83df2
Handle __classcell__ and __classdictcell__ in type.__new__
youknowone e1bf8d1
Revert __classdict__ cell and __classdictcell__ changes
youknowone add881c
Fix unreachable block elimination with fixpoint reachability
youknowone 3181725
Check enclosing scopes for IMPORTED flag in LOAD_ATTR mode
youknowone c345999
Add __classdict__ cell for classes with function definitions
youknowone 11b4b18
Store __classdictcell__ in class body epilogue
youknowone 0793cb2
Fix clippy collapsible_if warnings and cargo fmt
youknowone d29b2a9
Revert __classdict__ and __classdictcell__ changes (cause import fail…
youknowone d5afad9
Revert type.__new__ __classcell__ removal and __classdictcell__ handling
youknowone c921c8b
Re-add __classdict__ cell and __classdictcell__ store
youknowone 60103dc
Reorder MakeFunctionFlag to match CPython's SET_FUNCTION_ATTRIBUTE
youknowone 560d8ae
Use CPython-compatible power-of-two encoding for SET_FUNCTION_ATTRIBUTE
youknowone 16ce7fb
Remove expectedFailure from test_elim_jump_after_return1 and test_no_…
youknowone 9820993
Remove __classcell__ and __classdictcell__ from class dict in type.__…
youknowone 35a8f7e
Remove expectedFailure from test___classcell___expected_behaviour, ca…
youknowone e0c7326
Handle MakeCell and CopyFreeVars as no-ops in JIT
youknowone c958739
Remove expectedFailure from test_load_fast_known_simple
youknowone 926a984
Restore expectedFailure for test_load_fast_known_simple
youknowone File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Eliminate unreachable blocks after jump normalization
Split DCE into two phases: (1) within-block truncation after terminal instructions (always runs), (2) whole-block elimination for blocks only reachable via fall-through from terminal blocks (runs after normalize_jumps when dead jump instructions exist).
- Loading branch information
commit 83a548eace3bde36b3e9264e01944bdfa0c1bf1c
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or 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
257 changes: 122 additions & 135 deletions
257
...s/codegen/src/snapshots/rustpython_codegen__compile__tests__nested_double_async_with.snap
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.