FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[3.14] gh-140104: Revert "Set next_instr properly in the JIT during exceptions (GH-140233) (GH-140687)" by Fidget-Spinner · Pull Request #140890 · python/cpython · GitHub

/ cpython Public
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .h  (1) .py  (1) .rst  (1) All 3 file types selected
Deleted files Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
21 changes: 0 additions & 21 deletions Lib/test/test_capi/test_opt.py
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
Expand Up @@ -1972,27 +1972,6 @@ def testfunc(n):
assert ex is not None
"""))

def test_next_instr_for_exception_handler_set(self):
# gh-140104: We just want the exception to be caught properly.
def f():
for i in range(TIER2_THRESHOLD + 3):
try:
undefined_variable(i)
except Exception:
pass

f()

def test_next_instr_for_exception_handler_set_lasts_instr(self):
# gh-140104: We just want the exception to be caught properly.
def f():
a_list = []
for _ in range(TIER2_THRESHOLD + 3):
try:
a_list[""] = 0
except Exception:
pass


def global_identity(x):
return x
Expand Down

This file was deleted.

4 changes: 1 addition & 3 deletions Python/ceval_macros.h
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
Expand Up @@ -368,9 +368,7 @@ do { \
frame = tstate->current_frame; \
stack_pointer = _PyFrame_GetStackPointer(frame); \
if (next_instr == NULL) { \
/* gh-140104: The exception handler expects frame->instr_ptr
to after this_instr, not this_instr! */ \
next_instr = frame->instr_ptr + 1; \
next_instr = frame->instr_ptr; \
JUMP_TO_LABEL(error); \
} \
DISPATCH(); \
Expand Down
Loading

Back | FazBrowse Home | New Git URL