aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Python/generated_cases.c.h
Commit message (Collapse)AuthorAge
...
* GH-123197: Only count an instruction as deferred if it hasn't deopted first. ↵Mark Shannon2024-08-22
| | | | | (GH-123222) Only count an instruction as deferred if hasn't deopted first.
* GH-115776: Allow any fixed sized object to have inline values (GH-123192)Mark Shannon2024-08-21
|
* GH-123197: Increment correct stat for CALL_KW (GH-123200)Mark Shannon2024-08-21
|
* GH-123185: Check for `NULL` after calling `_PyEvalFramePushAndInit` (GH-123194)Mark Shannon2024-08-21
|
* GH-118093: Make `CALL_ALLOC_AND_ENTER_INIT` suitable for tier 2. (GH-123140)Mark Shannon2024-08-20
| | | | | * Convert CALL_ALLOC_AND_ENTER_INIT to micro-ops such that tier 2 supports it * Allow inexact arguments for CALL_ALLOC_AND_ENTER_INIT.
* GH-118093: Specialize `CALL_KW` (GH-123006)Mark Shannon2024-08-16
|
* GH-118093: Turn some DEOPT_IFs into EXIT_IFs (GH-122998)Brandt Bucher2024-08-14
|
* GH-120024: Remove `CHECK_EVAL_BREAKER` macro. (GH-122968)Mark Shannon2024-08-14
| | | | | * Factor some instructions into micro-ops to isolate CHECK_EVAL_BREAKER for escape analysis * Eliminate CHECK_EVAL_BREAKER macro
* GH-118093: Handle some polymorphism before requiring progress in tier two ↵Brandt Bucher2024-08-12
| | | | (GH-122843)
* gh-117139: Replace _PyList_FromArraySteal with stack ref variant (#122830)Sam Gross2024-08-12
| | | | | | | This replaces `_PyList_FromArraySteal` with `_PyList_FromStackRefSteal`. It's functionally equivalent, but takes a `_PyStackRef` array instead of an array of `PyObject` pointers. Co-authored-by: Ken Jin <kenjin@python.org>
* gh-117139: Fix a few `_PyStackRef` related bugs (#122831)Sam Gross2024-08-12
| | | | | | `BUILD_SET` should use a borrow instead of a steal. The cleanup in `_DO_CALL` `CONVERSION_FAILED` was incorrect. Co-authored-by: Ken Jin <kenjin@python.org>
* GH-120024: Tidy up case generator code a bit. (GH-122780)Mark Shannon2024-08-08
|
* gh-118926: Spill deferred references to stack in cases generator (#122748)Sam Gross2024-08-07
| | | | | | | This automatically spills the results from `_PyStackRef_FromPyObjectNew` to the in-memory stack so that the deferred references are visible to the GC before we make any possibly escaping call. Co-authored-by: Ken Jin <kenjin@python.org>
* gh-122759: Remove `assert` from `RERAISE` error handling (#122760)sobolevn2024-08-07
|
* gh-117139: Fix an incorrect borrow in bytecodes.c (#122318)Sam Gross2024-08-07
| | | `_PyDict_SetItem_Take2` steals both the key (i.e., `sub`) and the value.
* GH-120024: Move three more escaping calls out of conditional statements ↵Mark Shannon2024-08-06
| | | | (GH-122734)
* GH-120024: Refactor code a bit so that escaping calls can be wrapped in ↵Mark Shannon2024-08-06
| | | | spill code in code generator (GH-122693)
* GH-122616: Simplify LOAD_ATTR_WITH_HINT and STORE_ATTR_WITH_HINT (GH-122620)Mark Shannon2024-08-05
|
* GH-117224: Move the body of a few large-ish micro-ops into helper functions ↵Mark Shannon2024-08-02
| | | | (GH-122601)
* GH-118095: Add tier two support for BINARY_SUBSCR_GETITEM (GH-120793)Mark Shannon2024-08-01
|
* GH-122155: Track local variables between pops and pushes in cases generator ↵Mark Shannon2024-08-01
| | | | (GH-122286)
* GH-116090: Fire RAISE events from _FOR_ITER_TIER_TWO (GH-122413)Brandt Bucher2024-07-29
|
* GH-122029: Break INSTRUMENTED_CALL into micro-ops, so that its behavior is ↵Mark Shannon2024-07-26
| | | | consistent with CALL (GH-122177)
* GH-121131: Clean up and fix some instrumented instructions. (GH-121132)Mark Shannon2024-07-26
| | | | * Add support for 'prev_instr' to code generator and refactor some INSTRUMENTED instructions
* GH-118093: Add tier two support for BINARY_OP_INPLACE_ADD_UNICODE (GH-122253)Brandt Bucher2024-07-25
|
* GH-118093: Add tier two support for LOAD_ATTR_PROPERTY (GH-122283)Brandt Bucher2024-07-25
|
* GH-122034: Add StackRef variants of type checks to reduce the number of ↵Mark Shannon2024-07-25
| | | | PyStackRef_AsPyObjectBorrow calls (GH-122037)
* GH-122160: Remove BUILD_CONST_KEY_MAP opcode. (GH-122164)Mark Shannon2024-07-25
|
* GH-118093: Add tier two support to several instructions (GH-121884)Brandt Bucher2024-07-18
|
* GH-121784: Generate an error during code gen if a variable is marked ↵Mark Shannon2024-07-18
| | | | | | | | | | | | `unused`, but is used and thus cached in a prior uop. (#121788) * Reject uop definitions that declare values as 'unused' that are already cached by prior uops * Track which variables are defined and only load from memory when needed * Support explicit `flush` in macro definitions. * Make sure stack is flushed in where needed.
* gh-117139: Add _PyTuple_FromStackRefSteal and use it (#121244)Sam Gross2024-07-02
| | | Avoids the extra conversion from stack refs to PyObjects.
* gh-117139: Fix a few wrong steals in bytecodes.c (GH-121127)Ken Jin2024-06-29
| | | Fix a few wrong steals in bytecodes.c
* gh-121040: Use __attribute__((fallthrough)) (#121044)Victor Stinner2024-06-27
| | | | | | | | | | | | | Fix warnings when using -Wimplicit-fallthrough compiler flag. Annotate explicitly "fall through" switch cases with a new _Py_FALLTHROUGH macro which uses __attribute__((fallthrough)) if available. Replace "fall through" comments with _Py_FALLTHROUGH. Add _Py__has_attribute() macro. No longer define __has_attribute() macro if it's not defined. Move also _Py__has_builtin() at the top of pyport.h. Co-Authored-By: Nikita Sobolev <mail@sobolevn.me>
* gh-117139: Convert the evaluation stack to stack refs (#118450)Ken Jin2024-06-27
| | | | | | | | | | | | | | | | | This PR sets up tagged pointers for CPython. The general idea is to create a separate struct _PyStackRef for everything on the evaluation stack to store the bits. This forces the C compiler to warn us if we try to cast things or pull things out of the struct directly. Only for free threading: We tag the low bit if something is deferred - that means we skip incref and decref operations on it. This behavior may change in the future if Mark's plans to defer all objects in the interpreter loop pans out. This implies a strict stack reference discipline is required. ALL incref and decref operations on stackrefs must use the stackref variants. It is unsafe to untag something then do normal incref/decref ops on it. The new incref and decref variants are called dup and close. They mimic a "handle" API operating on these stackrefs. Please read Include/internal/pycore_stackref.h for more information! --------- Co-authored-by: Mark Shannon <9448417+markshannon@users.noreply.github.com>
* GH-120982: Add stack check assertions to generated interpreter code (GH-120992)Mark Shannon2024-06-25
|
* gh-120834: fix type of *_iframe field in _PyGenObject_HEAD declaration (#120835)Irit Katriel2024-06-24
|
* GH-120507: Lower the `BEFORE_WITH` and `BEFORE_ASYNC_WITH` instructions. ↵Mark Shannon2024-06-18
| | | | | | | | | (#120640) * Remove BEFORE_WITH and BEFORE_ASYNC_WITH instructions. * Add LOAD_SPECIAL instruction * Reimplement `with` and `async with` statements using LOAD_SPECIAL
* GH-120619: Clean up `RETURN_VALUE` instruction (GH-120624)Mark Shannon2024-06-17
| | | | | * Rename _POP_FRAME to _RETURN_VALUE as it returns a value as well as popping a frame. * Remove remaining _POP_FRAMEs
* gh-119180: PEP 649 compiler changes (#119361)Jelle Zijlstra2024-06-11
|
* gh-74929: PEP 667 C API documentation (gh-119379)Alyssa Coghlan2024-06-01
| | | | | | | | * Add docs for new APIs * Add soft-deprecation notices * Add What's New porting entries * Update comments referencing `PyFrame_LocalsToFast()` to mention the proxy instead * Other related cleanups found when looking for refs to the deprecated APIs
* gh-119821: Support non-dict globals in LOAD_FROM_DICT_OR_GLOBALS (#119822)Jelle Zijlstra2024-05-31
| | | | | | | | | Support non-dict globals in LOAD_FROM_DICT_OR_GLOBALS The implementation basically copies LOAD_GLOBAL. Possibly it could be deduplicated, but that seems like it may get hairy since the two operations have different operands. This is important to fix in 3.14 for PEP 649, but it's a bug in earlier versions too, and we should backport to 3.13 and 3.12 if possible.
* GH-119258: Handle STORE_ATTR_WITH_HINT in tier two (GH-119481)Brandt Bucher2024-05-28
|
* GH-119476: Split _CHECK_FUNCTION_VERSION out of _CHECK_FUNCTION_EXACT_ARGS ↵Brandt Bucher2024-05-28
| | | | (GH-119510)
* gh-119180: Add LOAD_COMMON_CONSTANT opcode (#119321)Jelle Zijlstra2024-05-22
| | | | | | | | | | The PEP 649 implementation will require a way to load NotImplementedError from the bytecode. @markshannon suggested implementing this by converting LOAD_ASSERTION_ERROR into a more general mechanism for loading constants. This PR adds this new opcode. I will work on the rest of the implementation of the PEP separately. Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
* gh-118692: Avoid creating unnecessary StopIteration instances for monitoring ↵Irit Katriel2024-05-21
| | | | (#119216)
* gh-118414: Fix assertion in YIELD_VALUE when tracing lines or instrs (#118683)Tian Gao2024-05-06
|
* GH-115709: Invalidate executors when a local variable is changed via ↵Mark Shannon2024-05-06
| | | | | frame.f_locals (#118639) Also fix unrelated assert in debug Tier2/JIT builds.
* GH-118095: Use broader specializations of CALL in tier 1, for better tier 2 ↵Mark Shannon2024-05-04
| | | | | | | | | | support of calls. (GH-118322) * Add CALL_PY_GENERAL, CALL_BOUND_METHOD_GENERAL and call CALL_NON_PY_GENERAL specializations. * Remove CALL_PY_WITH_DEFAULTS specialization * Use CALL_NON_PY_GENERAL in more cases when otherwise failing to specialize
* gh-107674: Improve performance of `sys.settrace` (GH-117133)Tian Gao2024-05-03
| | | | | | * Check tracing in RESUME_CHECK * Only change to RESUME_CHECK if not tracing
* GH-117442: Check eval-breaker at start (rather than end) of tier 2 loops ↵Mark Shannon2024-05-02
| | | | (GH-118482)