8000 gh-95913: Edit, expand & format Bytecode sect in 3.11 WhatsNew by CAM-Gerlach · Pull Request #98559 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-95913: Edit, expand & format Bytecode sect in 3.11 WhatsNew #98559

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 13 commits into from
Oct 24, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use clear, consistant phrasing on all Bytecode entries
  • Loading branch information
CAM-Gerlach committed Oct 20, 2022
commit 4a3d83028b716f5328583e92f5efe8fe1d50b557
23 changes: 11 additions & 12 deletions Doc/whatsnew/3.11.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1426,21 +1426,20 @@ CPython bytecode changes

* Removed :opcode:`!COPY_DICT_WITHOUT_KEYS` and :opcode:`!GEN_START`.

* :opcode:`MATCH_CLASS` and :opcode:`MATCH_KEYS` no longer push an additional
boolean value indicating whether the match succeeded or failed. Instead, they
indicate failure with ``None`` (where a tuple of extracted values would
otherwise be).
* Changed :opcode:`MATCH_CLASS` and :opcode:`MATCH_KEYS`
to no longer push an additional boolean value
indicating whether the match succeeded or failed.
Instead, they indicate failure with ``None``
(where a tuple of extracted values would otherwise be).

* Replaced several stack manipulation instructions
(:opcode:`!DUP_TOP`, :opcode:`!DUP_TOP_TWO`, :opcode:`!ROT_TWO`,
:opcode:`!ROT_THREE`, :opcode:`!ROT_FOUR`, and :opcode:`!ROT_N`)
with new :opcode:`COPY` and :opcode:`SWAP` instructions.

* Replaced :opcode:`!JUMP_IF_NOT_EXC_MATCH` by :opcode:`CHECK_EXC_MATCH`, which
performs the check but does not jump.

* Replaced :opcode:`!JUMP_IF_NOT_EG_MATCH` by :opcode:`CHECK_EG_MATCH` which
performs the check but does not jump.
* Replaced :opcode:`!JUMP_IF_NOT_EXC_MATCH` with :opcode:`CHECK_EXC_MATCH`
and :opcode:`!JUMP_IF_NOT_EG_MATCH` with :opcode:`CHECK_EG_MATCH`,
which perform the check but do not jump.

* Replaced :opcode:`!JUMP_ABSOLUTE` by the relative :opcode:`JUMP_BACKWARD`.

Expand All @@ -1457,10 +1456,10 @@ CPython bytecode changes
:opcode:`POP_JUMP_FORWARD_IF_NONE` and :opcode:`POP_JUMP_BACKWARD_IF_NONE`
opcodes to speed up conditional jumps.

* :opcode:`JUMP_IF_TRUE_OR_POP` and :opcode:`JUMP_IF_FALSE_OR_POP` are now
relative rather than absolute.
* Changed :opcode:`JUMP_IF_TRUE_OR_POP` and :opcode:`JUMP_IF_FALSE_OR_POP`
to now be relative rather than absolute.

* :opcode:`RESUME` has been added. It is a no-op,
* Added the :opcode:`RESUME` opcode. It is a no-op,
and performs internal tracing, debugging and optimization checks.


Expand Down
0