diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2018-02-22 21:33:30 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-22 21:33:30 (GMT) |
commit | 520b7ae27e39d1c77ea74ccd1b184d7cb43f9dcb (patch) | |
tree | 8a661515a3574b0d79ea2024a3b92646dd7ee837 /Lib/opcode.py | |
parent | 4af8fd561433826ac897c55e41a087a5c5dbacf3 (diff) | |
download | cpython-520b7ae27e39d1c77ea74ccd1b184d7cb43f9dcb.zip cpython-520b7ae27e39d1c77ea74ccd1b184d7cb43f9dcb.tar.gz cpython-520b7ae27e39d1c77ea74ccd1b184d7cb43f9dcb.tar.bz2 |
bpo-17611. Move unwinding of stack for "pseudo exceptions" from interpreter to compiler. (GH-5006)
Co-authored-by: Mark Shannon <mark@hotpy.org>
Co-authored-by: Antoine Pitrou <antoine@python.org>
Diffstat (limited to 'Lib/opcode.py')
-rw-r--r-- | Lib/opcode.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/Lib/opcode.py b/Lib/opcode.py index 368472d..6de24c3 100644 --- a/Lib/opcode.py +++ b/Lib/opcode.py @@ -60,6 +60,7 @@ def_op('ROT_TWO', 2) def_op('ROT_THREE', 3) def_op('DUP_TOP', 4) def_op('DUP_TOP_TWO', 5) +def_op('ROT_FOUR', 6) def_op('NOP', 9) def_op('UNARY_POSITIVE', 10) @@ -86,6 +87,7 @@ def_op('INPLACE_TRUE_DIVIDE', 29) def_op('GET_AITER', 50) def_op('GET_ANEXT', 51) def_op('BEFORE_ASYNC_WITH', 52) +def_op('BEGIN_FINALLY', 53) def_op('INPLACE_ADD', 55) def_op('INPLACE_SUBTRACT', 56) @@ -113,10 +115,8 @@ def_op('INPLACE_RSHIFT', 76) def_op('INPLACE_AND', 77) def_op('INPLACE_XOR', 78) def_op('INPLACE_OR', 79) -def_op('BREAK_LOOP', 80) def_op('WITH_CLEANUP_START', 81) def_op('WITH_CLEANUP_FINISH', 82) - def_op('RETURN_VALUE', 83) def_op('IMPORT_STAR', 84) def_op('SETUP_ANNOTATIONS', 85) @@ -158,10 +158,7 @@ jabs_op('POP_JUMP_IF_TRUE', 115) # "" name_op('LOAD_GLOBAL', 116) # Index in name list -jabs_op('CONTINUE_LOOP', 119) # Target address -jrel_op('SETUP_LOOP', 120) # Distance to target address -jrel_op('SETUP_EXCEPT', 121) # "" -jrel_op('SETUP_FINALLY', 122) # "" +jrel_op('SETUP_FINALLY', 122) # Distance to target address def_op('LOAD_FAST', 124) # Local variable number haslocal.append(124) @@ -213,5 +210,7 @@ def_op('BUILD_TUPLE_UNPACK_WITH_CALL', 158) name_op('LOAD_METHOD', 160) def_op('CALL_METHOD', 161) +jrel_op('CALL_FINALLY', 162) +def_op('POP_FINALLY', 163) del def_op, name_op, jrel_op, jabs_op |