This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: split JUMP_IF_NOT_EXC/EG_MATCH into CHECK_EXC/EG_MATCH + jump
Type: enhancement Stage: resolved
Components: Interpreter Core Versions: Python 3.11
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: iritkatriel Nosy List: Mark.Shannon, iritkatriel
Priority: normal Keywords: patch

Created on 2022-04-01 11:48 by iritkatriel, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 32231 merged iritkatriel, 2022-04-01 11:52
PR 32309 merged iritkatriel, 2022-04-04 17:39
Messages (3)
msg416484 - (view) Author: Irit Katriel (iritkatriel) * (Python committer) Date: 2022-04-01 11:48
It would help issue47120 to reduce the number of jump opcodes.

The exception matching opcodes JUMP_IF_NOT_EXC_MATCH  and JUMP_IF_NOT_EG_MATCH are not hot, and we can split them into a check + ordinary jump. 

For JUMP_IF_NOT_EXC_MATCH  this is simple because the stack effect is the same for the jump and non-jump case. For JUMP_IF_NOT_EG_MATCH the stack effect will need to be made the same, and the opcodes emitted around it adapted.
msg416485 - (view) Author: Mark Shannon (Mark.Shannon) * (Python committer) Date: 2022-04-01 12:59
New changeset 04e07c258f4f2ac85e25355242a113f98a706f04 by Irit Katriel in branch 'main':
bpo-47186: Replace JUMP_IF_NOT_EXC_MATCH by CHECK_EXC_MATCH + jump (GH-32231)
https://github.com/python/cpython/commit/04e07c258f4f2ac85e25355242a113f98a706f04
msg416770 - (view) Author: Irit Katriel (iritkatriel) * (Python committer) Date: 2022-04-05 11:06
New changeset 32091df41ce6e3a71df2cf37dc74b728c0d885f2 by Irit Katriel in branch 'main':
bpo-47186: Replace JUMP_IF_NOT_EG_MATCH by CHECK_EG_MATCH + jump (GH-32309)
https://github.com/python/cpython/commit/32091df41ce6e3a71df2cf37dc74b728c0d885f2
History
Date User Action Args
2022-04-11 14:59:57adminsetgithub: 91342
2022-04-05 11:11:01iritkatrielsetstatus: open -> closed
type: enhancement
resolution: fixed
stage: patch review -> resolved
2022-04-05 11:06:41iritkatrielsetmessages: + msg416770
2022-04-04 17:39:15iritkatrielsetpull_requests: + pull_request30370
2022-04-01 12:59:48Mark.Shannonsetnosy: + Mark.Shannon
messages: + msg416485
2022-04-01 11:52:49iritkatrielsetkeywords: + patch
stage: patch review
pull_requests: + pull_request30303
2022-04-01 11:48:57iritkatrielcreate