8000 gh-90997: bpo-46841: Disassembly of quickened code by penguin-wwy · Pull Request #32099 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-90997: bpo-46841: Disassembly of quickened code #32099

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 16 commits into from
Apr 19, 2022
Merged
Show file tree
Hide file tree
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
Merge branch 'main' of https://github.com/python/cpython into dis_qui…
…ckened_code
  • Loading branch information
penguin-wwy committed Apr 1, 2022
commit 88ab80c5b509c33f286342080dd485693ae4c0cf
3 changes: 2 additions & 1 deletion Lib/dis.py
Original file line number Diff line number Diff line change
Expand Up @@ -456,7 +456,8 @@ def _get_instructions_bytes(code, varname_from_oparg=None,
argval = arg*2
argrepr = "to " + repr(argval)
elif deop in hasjrel:
argval = offset + 2 + arg*2
signed_arg = -arg if deop == JUMP_BACKWARD else arg
argval = offset + 2 + signed_arg*2
argrepr = "to " + repr(argval)
elif deop in haslocal or deop in hasfree:
argval, argrepr = _get_name_info(arg, varname_from_oparg)
Expand Down
2 changes: 1 addition & 1 deletion Lib/test/test_dis.py
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ def test_boundaries(self):

def test_widths(self):
for opcode, opname in enumerate(dis.opname):
if opname in dis.deoptmap or opname == "JUMP_IF_NOT_EXC_MATCH":
if opname in dis.deoptmap:
continue
with self.subTest(opname=opname):
width = dis._OPNAME_WIDTH
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.
0