Repository navigation
Document bytecode changes in 3.6 #72996
Copy link
Copy link
Closed
Labels
3.7 (EOL)end of lifeend of lifedocsDocumentation in the Doc dirDocumentation in the Doc dirtype-featureA feature request or enhancementA feature request or enhancement
Description
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee = 'https://github.com/brettcannon'
closed_at = <Date 2017-03-24.21:32:35.326>
created_at = <Date 2016-11-26.18:24:04.503>
labels = ['type-feature', '3.7', 'docs']
title = 'Document bytecode changes in 3.6'
updated_at = <Date 2017-03-31.09:12:21.016>
user = 'https://github.com/serhiy-storchaka'bugs.python.org fields:
activity = <Date 2017-03-31.09:12:21.016>
actor = 'Mariatta'
assignee = 'brett.cannon'
closed = True
closed_date = <Date 2017-03-24.21:32:35.326>
closer = 'levkivskyi'
components = ['Documentation']
creation = <Date 2016-11-26.18:24:04.503>
creator = 'serhiy.storchaka'
dependencies = ['26213']
files = ['45780']
hgrepos = []
issue_num = 28810
keywords = ['patch']
message_count = 22.0
messages = ['281788', '281795', '281798', '282577', '286212', '286215', '288300', '288358', '289247', '289250', '289256', '289419', '290140', '290141', '290142', '290147', '290184', '290234', '290236', '290237', '290238', '290901']
nosy_count = 7.0
nosy_names = ['brett.cannon', 'docs@python', 'berker.peksag', 'serhiy.storchaka', 'levkivskyi', 'Mariatta', 'mdartiailh']
pr_nums = ['239', '250', '605', '607', '651', '665', '808', '919']
priority = 'high'
resolution = 'fixed'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'enhancement'
url = 'https://bugs.python.org/issue28810'
versions = ['Python 3.6', 'Python 3.7']Metadata
Metadata
Assignees
Labels
3.7 (EOL)end of lifeend of lifedocsDocumentation in the Doc dirDocumentation in the Doc dirtype-featureA feature request or enhancementA feature request or enhancement
Activity
serhiy-storchaka commentedon Nov 26, 2016
There are many bytecode changes in 3.6, but seems most of them are not documented (besides short line in _bootstrap_external.py).
The bytecode now uses 16 bit units (wordcode) (bpo-26647).
Added FORMAT_VALUE opcode (bpo-25483).
Added BUILD_CONST_KEY_MAP opcode (bpo-27140).
Added BUILD_STRING opcode (bpo-27078).
Added BUILD_TUPLE_UNPACK_WITH_CALL opcode (bpo-28257).
Added SETUP_ANNOTATIONS and STORE_ANNOTATION opcodes (bpo-27985).
Changed CALL_FUNCTION, CALL_FUNCTION_KW and BUILD_MAP_UNPACK_WITH_CALL opcodes, removed CALL_FUNCTION_VAR, CALL_FUNCTION_VAR_KW opcodes, added CALL_FUNCTION_EX opcode (bpo-27213).
Changed MAKE_FUNCTION opcode, removed MAKE_CLOSURE opcode (bpo-27095).
Not related to the bytecode itself: lineno delta of code.co_lnotab now is signed (bpo-26107).
There are third-party projects that need correct information about bytecode changes.
ilevkivskyi commentedon Nov 26, 2016
SETUP_ANNOTATIONS and STORE_ANNOTATION opcodes are documented in documentation for dis module. Should they be documented also somewhere else?
serhiy-storchaka commentedon Nov 26, 2016
I think only the mention in What's News is needed. Elvis already provided a patch in bpo-28635.
But the documentation of other opcodes may be missed or outdated.
serhiy-storchaka commentedon Dec 6, 2016
Because nobody proposed a patch, here is my attempt. Following patch documents opcodes CALL_FUNCTION, CALL_FUNCTION_KW and CALL_FUNCTION_EX.
serhiy-storchaka commentedon Jan 24, 2017
Several third-party bytecode manipulating projects still are not updated to 3.6. Correct documentation is needed for them. Could anyone please make a review of the patch (or maybe totally rewrite it)?
brettcannon commentedon Jan 24, 2017
I'll review your patch sometime this week, Serhiy.
MatthieuDartiailh commentedon Feb 21, 2017
Anyone to review this. Working on bytecode manipulation for different projects I wish I had known this existed before.
serhiy-storchaka commentedon Feb 22, 2017
Thank you for your patches Ivan. Feel free to rewrite my patch, I'm sure it uses poor English.
serhiy-storchaka commentedon Mar 8, 2017
Ping.
brettcannon commentedon Mar 8, 2017
If the "ping" is for me, I spent my open source day last week reviewing the dependency for this issue (and other stuff) so I plan to get to this PR this Friday.
ilevkivskyi commentedon Mar 8, 2017
It looks like there are still few things that are not covered in two open PRs. I will add these in an additional PR in the next few days.
brettcannon commentedon Mar 10, 2017
I have merged all the PRs that Ivan had open. I'll leave the issue open since Ivan said he had another PR he wanted to create.
brettcannon commentedon Mar 24, 2017
New changeset 8f9e1bb by Brett Cannon (Ivan Levkivskyi) in branch 'master':
bpo-28810: Document remaining bytecode changes in 3.6 (GH-651)
8f9e1bb
brettcannon commentedon Mar 24, 2017
New changeset 74bfcc3 by Brett Cannon in branch '3.6':
bpo-28810: Document remaining bytecode changes in 3.6 (GH-651) (GH-808)
74bfcc3
brettcannon commentedon Mar 24, 2017
Is there anything left to do for this Ivan?
ilevkivskyi commentedon Mar 24, 2017
Thanks Brett!
I think this could be closed now.
serhiy-storchaka commentedon Mar 24, 2017
New changeset 9135275 by Serhiy Storchaka (Ivan Levkivskyi) in branch 'master':
bpo-28810: Update lnotab_notes.txt (#665)
9135275
brettcannon commentedon Mar 24, 2017
New changeset 4807fa8 by Brett Cannon in branch '3.6':
bpo-28810: Document changes to CALL_FUNCTION opcodes (GH-607)
4807fa8
brettcannon commentedon Mar 24, 2017
New changeset 4b2a2a4 by Brett Cannon (Ivan Levkivskyi) in branch 'master':
bpo-28810: Document changes to CALL_FUNCTION opcodes (GH-250)
4b2a2a4
brettcannon commentedon Mar 24, 2017
New changeset 68c5e4c by Brett Cannon in branch '3.6':
bpo-28810: Document BUILD_TUPLE_UNPACK_WITH_CALL bytecode (GH-605)
68c5e4c
brettcannon commentedon Mar 24, 2017
New changeset 7e52c3e by Brett Cannon (Ivan Levkivskyi) in branch 'master':
bpo-28810: Document BUILD_TUPLE_UNPACK_WITH_CALL bytecode added in 3.6 (GH-239)
7e52c3e
Mariatta commentedon Mar 31, 2017
New changeset 0a17e58 by Mariatta in branch '3.6':
bpo-28810: Update lnotab_notes.txt (GH-665) (GH-919)
0a17e58