-
-
Notifications
You must be signed in to change notification settings - Fork 34.5k
gh-91432: Specialize FOR_ITER #91713
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 1 commit
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
3a7f8df
initial attempt
sweeneyde 3b5ce1e
bump magic
sweeneyde b21b5f4
Merge remote-tracking branch 'upstream/main' into special_for_iter2
sweeneyde 37269cf
NOTRACE_DISPATCH_SAME_OPARG
sweeneyde ea0a7ee
Update mark_stacks
sweeneyde 0751228
comment out assertions
sweeneyde dc80fda
Merge branch 'main' into special_for_iter2
sweeneyde e429410
Make FOR_ITER_RANGE mutate the local
sweeneyde 1cb2de7
Merge remote-tracking branch 'upstream/main' into special_for_iter2
sweeneyde 73fa01c
Fix overflow
sweeneyde 4213582
fix test
sweeneyde bf58358
fix dis
sweeneyde bd7575e
Add more tests, add more casts
sweeneyde db8754b
Merge branch 'main' into special_for_iter2
sweeneyde 2050c4e
merge with main
sweeneyde 824e966
Fix stats, take out some PREDICT
sweeneyde 6b16772
📜🤖 Added by blurb_it.
blurb-it[bot] c2a75a5
merge with main
sweeneyde 6696384
remove PREDEICTED(STORE_FAST)
sweeneyde d297091
assert no tracing
sweeneyde 22635a6
Merge branch 'special_for_iter2' of https://github.com/sweeneyde/cpyt…
sweeneyde f360d65
remove unnecessary cast
sweeneyde 81e0500
merge with main
sweeneyde c2eab68
regen
sweeneyde 25689c3
merge and bump magic
sweeneyde b5df047
merge with main
sweeneyde 2b1c170
Merge remote-tracking branch 'upstream/main' into special_for_iter2
sweeneyde 91d280c
Fix test_dis
sweeneyde eba5e60
merge with main
sweeneyde 5b153d7
Merge branch 'main' into special_for_iter2
sweeneyde 76f9a74
merge with main
sweeneyde 0565a68
Merge branch 'special_for_iter2' of https://github.com/sweeneyde/cpyt…
sweeneyde 9ba5b79
merge with main
sweeneyde 6cdf0e4
Add comment about re-using the old PyLongObject
sweeneyde 03dde6a
Merge branch 'main' of https://github.com/python/cpython into special…
sweeneyde f1e2d39
update test_dis.py
sweeneyde 463c3b9
Merge remote-tracking branch 'upstream/main' into special_for_iter2
sweeneyde ed29777
use the new exponential backoff
sweeneyde 188b357
merge with main
sweeneyde 36d0999
revert using sdigits, add _PyLong_AssignValue
sweeneyde ad2e969
revert test_sys sizeof check
sweeneyde d55868f
revert test_range changes
sweeneyde 2d6ee26
add comment and use Py_ssize_t
sweeneyde db21da1
Add comment: only positive
sweeneyde 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
add comment and use Py_ssize_t
- Loading branch information
commit 2d6ee26f9528c459e1a228a337c7be45f44f8775
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4510,6 +4510,7 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, _PyInterpreterFrame *frame, int | |
| if (_PyLong_AssignValue(&GETLOCAL(_Py_OPARG(next)), value) < 0) { | ||
| goto error; | ||
| } | ||
| // The STORE_FAST is already done. | ||
| JUMPBY(INLINE_CACHE_ENTRIES_FOR_ITER + 1); | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could you add a comment explaining why this is |
||
| NOTRACE_DISPATCH(); | ||
| } | ||
|
|
||
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.
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.
This only works for positive integers.
Given that it is only used for
rangeiteration, that's fine for now.But could you add a comment, so it doesn't get overlooked when we implement faster-cpython/ideas#147