summaryrefslogtreecommitdiffstats
path: root/Objects
Commit message (Collapse)AuthorAgeFilesLines
...
* bpo-47186: Replace JUMP_IF_NOT_EG_MATCH by CHECK_EG_MATCH + jump (GH-32309)Irit Katriel2022-04-051-8/+2
|
* no-issue: Add assertion to PyModule_GetName for understanding (GH-32236)Dong-hee Na2022-04-021-1/+3
|
* bpo-47186: Replace JUMP_IF_NOT_EXC_MATCH by CHECK_EXC_MATCH + jump (GH-32231)Irit Katriel2022-04-011-3/+1
|
* bpo-46841: Use a `bytes` object for `_co_code_adaptive` (GH-32205)Brandt Bucher2022-04-011-2/+2
|
* bpo-46841: Avoid unnecessary allocations in code object comparisons (GH-32222)Brandt Bucher2022-04-011-13/+13
|
* bpo-47009: Streamline list.append for the common case (GH-31864)Dennis Sweeney2022-04-011-18/+18
|
* bpo-40421: Add missing getters for frame object attributes to C-API. (GH-32114)Mark Shannon2022-03-311-0/+22
|
* bpo-47182: Fix crash by named unicode characters after interpreter ↵Christian Heimes2022-03-311-0/+3
| | | | | reinitialization (GH-32212) Automerge-Triggered-By: GH:tiran
* bpo-14911: Corrected generator.throw() documentation (GH-32207)Dave Goncalves2022-03-311-4/+10
| | | Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
* bpo-47120: Replace the JUMP_ABSOLUTE opcode by the relative JUMP_BACKWARD ↵Irit Katriel2022-03-311-1/+6
| | | | (GH-32115)
* bpo-47164: Add _PyASCIIObject_CAST() macro (GH-32191)Victor Stinner2022-03-314-37/+34
| | | | | | | | | | | | Add macros to cast objects to PyASCIIObject*, PyCompactUnicodeObject* and PyUnicodeObject*: _PyASCIIObject_CAST(), _PyCompactUnicodeObject_CAST() and _PyUnicodeObject_CAST(). Using these new macros make the code more readable and check their argument with: assert(PyUnicode_Check(op)). Remove redundant assert(PyUnicode_Check(op)) in macros using directly or indirectly these new CAST macros. Replacing existing casts with these macros.
* bpo-47162: Add call trampoline to mitigate bad fpcasts on Emscripten (GH-32189)Christian Heimes2022-03-303-12/+48
|
* bpo-46775: OSError should call winerror_to_errno unconditionally on Windows ↵Dong-hee Na2022-03-301-8/+1
| | | | (GH-32179)
* bpo-47070: Add _PyBytes_Repeat() (GH-31999)Pieter Eendebak2022-03-283-72/+47
| | | Use it where appropriate: the repeat functions of `array.array`, `bytes`, `bytearray`, and `str`.
* bpo-47116: use _PyLong_FromUnsignedChar instead of PyLong_FromLong (GH-32110)Pieter Eendebak2022-03-262-5/+5
|
* bpo-42197: Don't create `f_locals` dictionary unless we actually need it. ↵Mark Shannon2022-03-251-6/+17
| | | | | | | | | | | (GH-32055) * `PyFrame_FastToLocalsWithError` and `PyFrame_LocalsToFast` are no longer called during profile and tracing. (Contributed by Fabio Zadrozny) * Make accesses to a frame's `f_locals` safe from C code, not relying on calls to `PyFrame_FastToLocals` or `PyFrame_LocalsToFast`. * Document new `PyFrame_GetLocals` C-API function.
* bpo-47012: speed up iteration of bytes and bytearray (GH-31867)Kumar Aditya2022-03-232-7/+4
|
* bpo-47045: Remove `f_state` field (GH-31963)Mark Shannon2022-03-222-93/+130
| | | | | * Remove the f_state field from _PyInterpreterFrame * Make ownership of the frame explicit, replacing the is_generator field with an owner field.
* bpo-47084: Clear Unicode cached representations on finalization (GH-32032)Jeremy Kloth2022-03-221-0/+44
|
* bpo-47067: Optimize calling GenericAlias objects (GH-31996)penguin_wwy2022-03-211-7/+32
| | | Use vectorcall, and replace `PyObject_SetAttrString` with `PyObject_SetAttr` and a global string.
* bpo-46841: Quicken code in-place (GH-31888)Brandt Bucher2022-03-215-137/+149
| | | | | | | | | | | | | | | | | | | * 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-45786: Remove _PyFrame_Fini() and _PyFrame_DebugMallocStats() (GH-31874)Victor Stinner2022-03-182-12/+0
| | | | Remove private empty _PyFrame_Fini() and _PyFrame_DebugMallocStats() functions.
* bpo-47005: Improve performance of bytearray_repeat and bytearray_irepeat ↵Pieter Eendebak2022-03-171-6/+22
| | | | (GH-31856)
* bpo-46841: Don't scan backwards in bytecode (GH-31901)Mark Shannon2022-03-161-2/+5
|
* bpo-46993: Speed up bytearray creation from list and tuple (GH-31834)Kumar Aditya2022-03-151-2/+27
|
* bpo-43721: Fix docstrings for property.getter/setter/deleter (GH-31046)Irit Katriel2022-03-141-3/+3
|
* bpo-46920: Remove disabled debug code added decades ago and likely ↵Oleg Iarygin2022-03-141-13/+0
| | | | unnecessary (GH-31812)
* bpo-46920: Remove code that has no explainer why it was disabled (GH-31814)Oleg Iarygin2022-03-141-17/+1
|
* bpo-39829: Fix `__len__()` is called twice in list() constructor (GH-31816)Crowthebird2022-03-141-17/+12
|
* bpo-43224: Implement PEP 646 changes to genericaliasobject.c (GH-31019)Matthew Rahtz2022-03-121-0/+75
| | | | | | | Specifically, prepare for starring of tuples via a new genericalias iter type. GenericAlias also partially supports the iterator protocol after this change. Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* bpo-46906: Add PyFloat_Pack8() to the C API (GH-31657)Victor Stinner2022-03-111-7/+13
| | | | | | | | | | | | | | | | | | | | | | Add new functions to pack and unpack C double (serialize and deserialize): * PyFloat_Pack2(), PyFloat_Pack4(), PyFloat_Pack8() * PyFloat_Unpack2(), PyFloat_Unpack4(), PyFloat_Unpack8() Document these functions and add unit tests. Rename private functions and move them from the internal C API to the public C API: * _PyFloat_Pack2() => PyFloat_Pack2() * _PyFloat_Pack4() => PyFloat_Pack4() * _PyFloat_Pack8() => PyFloat_Pack8() * _PyFloat_Unpack2() => PyFloat_Unpack2() * _PyFloat_Unpack4() => PyFloat_Unpack4() * _PyFloat_Unpack8() => PyFloat_Unpack8() Replace the "unsigned char*" type with "char*" which is more common and easy to use.
* bpo-46944: use FASTCALL calling convention in generator.throw (GH-31723)Kumar Aditya2022-03-111-14/+23
|
* bpo-46881: Fix refleak from GH-31616 (GH-31805)Jelle Zijlstra2022-03-111-2/+4
|
* bpo-44796: Unify TypeVar and ParamSpec substitution (GH-31143)Serhiy Storchaka2022-03-111-32/+14
| | | | | | Add methods __typing_subst__() in TypeVar and ParamSpec. Simplify code by using more object-oriented approach, especially the C code for types.GenericAlias and the Python code for collections.abc.Callable.
* bpo-46881: Statically allocate and initialize the latin1 characters. (GH-31616)Kumar Aditya2022-03-091-50/+14
|
* bpo-46841: Use inline caching for calls (GH-31709)Brandt Bucher2022-03-071-4/+1
|
* bpo-46940: Don't override existing AttributeError suggestion information ↵Pablo Galindo Salgado2022-03-071-12/+22
| | | | | | | | | | | | (GH-31710) When an exception is created in a nested call to PyObject_GetAttr, any external calls will override the context information of the AttributeError that we have already placed in the most internal call. This will cause the suggestions we create to nor work properly as the attribute name and object that we will be using are the incorrect ones. To avoid this, we need to check first if these attributes are already set and bail out if that's the case.
* bpo-46921: Vectorcall support for `super()` (GH-31687)Ken Jin2022-03-061-2/+53
| | | Co-Authored-By: Dong-hee Na <donghee.na@python.org>
* bpo-46864: Deprecate PyBytesObject.ob_shash. (GH-31598)Inada Naoki2022-03-061-0/+18
|
* bpo-46927: Include the type's name in the error message for subscripting ↵Serhiy Storchaka2022-03-051-0/+3
| | | | non-generic types (GH-31694)
* bpo-46903: Handle str-subclasses in virtual instance dictionaries. (GH-31658)Mark Shannon2022-03-041-10/+18
|
* bpo-46891: Fix creating a new instance of a module subclass with slots ↵Mark Shannon2022-03-031-1/+2
| | | | (GH-31643)
* dict: Fix refleak (GH-31650)Inada Naoki2022-03-031-4/+8
|
* bpo-46848: Move _PyBytes_Find() to internal C API (GH-31642)Victor Stinner2022-03-021-0/+1
| | | | | | Move _PyBytes_Find() and _PyBytes_ReverseFind() functions to the internal C API. bytesobject.c now includes pycore_bytesobject.h.
* dict: Internal cleanup (GH-31641)Inada Naoki2022-03-021-66/+44
| | | | * Make empty_key from split table to combined table. * Use unicode_get_hash() when possible.
* bpo-46848: Use stringlib/fastsearch in mmap (GH-31625)Dennis Sweeney2022-03-021-0/+18
| | | Speed up mmap.find(). Add _PyBytes_Find() and _PyBytes_ReverseFind().
* bpo-46845: Reduce dict size when all keys are Unicode (GH-31564)Inada Naoki2022-03-013-424/+782
|
* bpo-46311: Clean up PyLong_FromLong and PyLong_FromLongLong (GH-30496)Mark Dickinson2022-03-011-41/+31
|
* bpo-46753: Add the empty tuple to the _PyRuntimeState.global_objects. (gh-31345)Eric Snow2022-02-281-174/+164
| | | https://bugs.python.org/issue46753
* bpo-46857: Fix refleak in OSError INIT_ALIAS() (GH-31594)Victor Stinner2022-02-262-12/+5
| | | _Py_GetRefTotal() no longer decrements _PySet_Dummy refcount.