-
-
Notifications
You must be signed in to change notification settings - Fork 32k
gh-109094: replace frame->prev_instr by frame->instr_ptr #109095
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
Merged
Changes from all commits
Commits
Show all changes
102 commits
Select commit
Hold shift + click to select a range
637b5da
add instr_ptr and assert it's 1 more than prev_instr in SET_LOCALS_FR…
iritkatriel ffb980c
fix YIELD_VALUE
iritkatriel 82a5b92
fix test_sys
iritkatriel 1fc0df1
update instr_ptr in _PyOptimizer_BackEdge
iritkatriel 6bbb1c2
All tests pass except test_jump_from_yield (which is disabled)
iritkatriel be6d428
assert always
iritkatriel bbe8e2c
remove unnecessary stuff
iritkatriel 50a1f3a
fix test_sys expected sizes
iritkatriel 4beb50b
add assert
iritkatriel 8e4a310
use instr_ptr instead of prev_instr in genobject.c
iritkatriel 58d3bc5
update executor.c
iritkatriel 909de93
remove unecessary setting of prev_instr in _Py_call_instrumentation_jump
iritkatriel 0a06b75
replace assignment by assertion in _Py_call_instrumentation_line
iritkatriel da6c97b
revert change to signature of _PyFrame_PushTrampolineUnchecked
iritkatriel 6488d69
prev_instr --> previous_instr to avoid confusion
iritkatriel 6c684b0
revert change to JUMPBY
iritkatriel b6a8b0c
use instr_ptr in _PyFrame_OpAlreadyRan
iritkatriel 1ceeba1
use instr_ptr in _PyFrame_IsIncomplete
iritkatriel 371fa66
use instr_ptr in LOAD_IP
iritkatriel 557f36f
use intr_ptr in INSTRUMENTED_RESUME
iritkatriel cb22365
Python/optimizer.c
iritkatriel 9875704
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel aea21a6
tweaks
iritkatriel b2221d1
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel 7078fe5
skip test_long_loop for now
iritkatriel 3ac7cc6
added harness for LASTI migration, but no functional change yet
iritkatriel 5a672a4
WIP
iritkatriel 4fd470e
WIP
iritkatriel d676f9c
WIP
iritkatriel 1afba52
WIP
iritkatriel 8b1643a
WIP
iritkatriel a386dee
fix bug
iritkatriel 32b2cfd
add dump_frame
iritkatriel add2321
add yield_offset
iritkatriel 218228b
give the POP_TOP after a RETURN_GENERATOR the same line number
iritkatriel 0d0c25d
fix getattr overridden
iritkatriel 4418fc4
add more data to debug output
iritkatriel e07b415
disable Uops tests for now
iritkatriel cb96aa0
always assert
iritkatriel 729944f
remove some debug prints
iritkatriel 44e37ee
use new lasti macro
iritkatriel b3b55ee
rename local
iritkatriel 6f0fe7b
use prev_traced_instr instead of prev_instr in line tracing
iritkatriel 2cf7e94
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel 66005ce
remove some debug prints
iritkatriel c9a9601
don't use prev_instr in jump instrumentation
iritkatriel 764bd37
remove prev_instr and return_offset from frame
iritkatriel 30e74de
skip failing tests
iritkatriel b63c8da
fix test_sys_settrace tests
iritkatriel 8bade18
re-enable some tests
iritkatriel 8b14bde
remove prev_traced_instr
iritkatriel d1387ed
unskip tests which are now passing
iritkatriel 9c10b8d
one more test
iritkatriel 287c1a5
more tests
iritkatriel 3639796
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel 41bba62
rename new_return_offset to next_instr_offset
iritkatriel d363fc3
remove debug prints
iritkatriel efa8eab
tidy up
iritkatriel 86cf45f
use constants
iritkatriel 19da0c0
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel cbee4f8
add and use constant NEXT_INSTR_OFFSET_FOR_YIELD
iritkatriel
8000
Oct 13, 2023
3a9a029
remove yield_offset from the frame
iritkatriel a44f4db
re-enable test_sys
iritkatriel 62ca8ce
adjust shim frame
iritkatriel 3fa0423
tweak assertions
iritkatriel 488e5e7
tweaks
iritkatriel 85f08bc
cleanup
iritkatriel 012f911
add news
iritkatriel 3fcfc47
fix most uop tests
iritkatriel d796107
_PUSH_FRAME doesn't need to update next_instr_offset
iritkatriel 76474e3
Apply suggestions from code review
iritkatriel 3fcbc3a
fix ()
iritkatriel 2043c83
assert YIELD has no caches
iritkatriel 3511bef
apply review feedback
iritkatriel 6a85588
remove obsolete comment
iritkatriel 8ccbe6e
remove frame->instr_ptr--; in executor
iritkatriel d55f048
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel b7f86a7
Add uops support to instr_ptr branch (#55)
gvanrossum c6d69da
address some of Mark's comments
iritkatriel 0da356b
address some of Mark's comments
iritkatriel 0089b30
apply next_instr_offset on return/yield
iritkatriel e1ab25d
remove debug stuff
iritkatriel 3e0b86d
prev can't be NULL
iritkatriel d0b2469
yield doesn't need to use next_instr_offset
iritkatriel 7d15260
apply next_instr_offset to next_instr instead of instr_ptr
iritkatriel 2986b9c
rename next_instr_offset to return_offset
iritkatriel 91eb2a4
Merge remote-tracking branch 'upstream/main' into instr_ptr
iritkatriel 1bd0be3
disable a few tier2 tests
iritkatriel 91dddc0
revert some unnecessary changes
iritkatriel f3c25b5
fix ENTER_EXECUTOR and re-enable the tests
iritkatriel 6617d60
cleanup
iritkatriel 661dad0
_SAVE_CURRENT_IP --> _SAVE_RETURN_OFFSET
iritkatriel 5a5103b
assignment to assertion
iritkatriel 0b68e54
address (most of) Guido's comments
iritkatriel 96a996c
LOAD_IP takes the offset
iritkatriel 8574469
no need to zero return_offset
iritkatriel 855513a
remove OPARG_SET_IP
iritkatriel 0cf9ec9
fix test_gdb?
iritkatriel 82f9d9d
move explanations to frame_layout.md
iritkatriel 95b63df
Mark's comments
iritkatriel f2d149b
same tweak to INSTRUMENTED_YIELD_VALUE as well
iritkatriel 578e266
Merge branch 'main' into instr_ptr
iritkatriel 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
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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
3 changes: 3 additions & 0 deletions
3
Misc/NEWS.d/next/Core and Builtins/2023-10-13-16-55-55.gh-issue-109094.ziL4cJ.rst
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Replace ``prev_instr`` on the interpreter frame by ``instr_ptr`` which | ||
points to the beginning of the instruction that is currently executing (or | ||
will execute once the frame resumes). |
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
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
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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.