aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Tools/scripts/generate_opcode_h.py
Commit message (Collapse)AuthorAge
* gh-92031: Deoptimize Static Code at Finalization (GH-92039)Dennis Sweeney2022-05-03
|
* gh-91719: Add pycore_opcode.h internal header file (#91906)Victor Stinner2022-04-26
| | | | | | | | | | | Move the following API from Include/opcode.h (public C API) to a new Include/internal/pycore_opcode.h header file (internal C API): * EXTRA_CASES * _PyOpcode_Caches * _PyOpcode_Deopt * _PyOpcode_Jump * _PyOpcode_OpName * _PyOpcode_RelativeJump
* GH-91719: Make MSVC generate somewhat faster switch code (#91718)Guido van Rossum2022-04-21
| | | | | | | | | | | Apparently a switch on an 8-bit quantity where all cases are present generates a more efficient jump (doing only one indexed memory load instead of two). So we make opcode and use_tracing uint8_t, and generate a macro full of extra `case NNN:` lines for all unused opcodes. See https://github.com/faster-cpython/ideas/issues/321#issuecomment-1103263673
* gh-91428: include specialized opcodes in _PyOpcode_OpName (GH-91467)Dennis Sweeney2022-04-14
|
* gh-91428: Add _PyOpcode_OpName to opcode.h of debug builds (GH-91430)Dennis Sweeney2022-04-11
|
* bpo-46841: Quicken code in-place (GH-31888)Brandt Bucher2022-03-21
| | | | | | | | | | | | | | | | | | | * Moves the bytecode to the end of the corresponding PyCodeObject, and quickens it in-place. * Removes the almost-always-unused co_varnames, co_freevars, and co_cellvars member caches * _PyOpcode_Deopt is a new mapping from all opcodes to their un-quickened forms. * _PyOpcode_InlineCacheEntries is renamed to _PyOpcode_Caches * _Py_IncrementCountAndMaybeQuicken is renamed to _PyCode_Warmup * _Py_Quicken is renamed to _PyCode_Quicken * _co_quickened is renamed to _co_code_adaptive (and is now a read-only memoryview). * Do not emit unused nonzero opargs anymore in the compiler.
* bpo-46841: Move the cache for `LOAD_GLOBAL` inline. (GH-31575)Mark Shannon2022-02-28
|
* bpo-46841: Use *inline* caching for `BINARY_OP` (GH-31543)Brandt Bucher2022-02-25
|
* bpo-45636: Merge all numeric operators (GH-29482)Brandt Bucher2021-11-10
|
* bpo-43760: Check for tracing using 'bitwise or' instead of branch in ↵Mark Shannon2021-10-05
| | | | dispatch. (GH-28723)
* bpo-45152: Add HAS_CONST macro and get_const_value() function and use… ↵Irit Katriel2021-09-14
| | | | (#28262)
* bpo-44337: Port LOAD_ATTR to PEP 659 adaptive interpreter (GH-26595)Mark Shannon2021-06-10
| | | | | | | | | | | | | | * Specialize LOAD_ATTR with LOAD_ATTR_SLOT and LOAD_ATTR_SPLIT_KEYS * Move dict-common.h to internal/pycore_dict.h * Add LOAD_ATTR_WITH_HINT specialized opcode. * Quicken in function if loopy * Specialize LOAD_ATTR for module attributes. * Add specialization stats
* bpo-40222: "Zero cost" exception handling (GH-25729)Mark Shannon2021-05-07
| | | | | | | | "Zero cost" exception handling. * Uses a lookup table to determine how to handle exceptions. * Removes SETUP_FINALLY and POP_TOP block instructions, eliminating (most of) the runtime overhead of try statements. * Reduces the size of the frame object by about 60%.
* bpo-41463: Generate information about jumps from 'opcode.py' rather than ↵Mark Shannon2020-08-04
| | | | | duplicating it in 'compile.c' (GH-21714) Generate information about jumps from 'opcode.py' rather than duplicate it in 'compile.c'
* bpo-39156: Break up COMPARE_OP into four logically distinct opcodes. (GH-17754)Mark Shannon2020-01-14
| | | | | | | | Break up COMPARE_OP into four logically distinct opcodes: * COMPARE_OP for rich comparisons * IS_OP for 'is' and 'is not' tests * CONTAINS_OP for 'in' and 'is not' tests * JUMP_IF_NOT_EXC_MATCH for checking exceptions in 'try-except' statements.
* Update opcode.h header comment to mention the source data file (GH-9935)Shivank982018-10-18
| | | This is intended to help code explorers find out more about what's defined there.
* Reintroduce Python2 support in generate_opcode_h.pyVictor Stinner2016-11-28
| | | | | | Issue #28821. Add also a message to show that the command did something :-)
* Fix a ResourceWarning in generate_opcode_h.pyVictor Stinner2016-11-25
| | | | | Use a context manager to close the Python file. Replace also open() with tokenize.open() to handle coding cookie if any in Lib/opcode.py.
* Remove legacy "from __future__ import with_statement" lines.Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)2016-09-08
|
* Issue #24288: Generated opcode.h no longer contains trailing spaces and tabs.Serhiy Storchaka2015-05-27
|
* Issue #17861: Allow generate_opcode_h to run with a system Python 2.5.Ned Deily2014-04-28
| | | | Patch by David Bolen.
* Fix Tools/scripts/generate_opcode_h.py from issue #17861 to work correctlyThomas Wouters2014-04-17
| | | | | when building in a separate object tree. More people should build this way. This may still fail if the source is unwritable, I haven't tested that yet.
* Closes Issue 17861: Autogenerate Include/opcode.h from opcode.py.Kushal Das2014-04-15
It includes required changes in Makefile.pre.in and configure.ac among other files.