summaryrefslogtreecommitdiffstats
path: root/Python
Commit message (Collapse)AuthorAgeFilesLines
...
* GH-111438: Add Support for Sharing Floats Between Interpreters (gh-111439)Anthony Shaw2023-10-311-0/+28
| | | This only affects users of the APIs in pycore_crossinterp.h (AKA _xxsubinterpretersmodule.c and _xxinterpchannels.c).
* GH-111485: Remove some special cases from the code generator and bytecodes.c ↵Mark Shannon2023-10-314-10/+89
| | | | (GH-111540)
* GH-111485: Increment `next_instr` consistently at the start of the ↵Mark Shannon2023-10-315-493/+969
| | | | instruction. (GH-111486)
* gh-109329: Count tier2 opcode misses (#110561)Michael Droettboom2023-10-312-1/+5
| | | This keeps a separate 'miss' counter for each micro-opcode, incremented whenever a guard uop takes a deoptimization side exit.
* gh-76785: Move the Cross-Interpreter Code to Its Own File (gh-111502)Eric Snow2023-10-302-591/+631
| | | This is partly to clear this stuff out of pystate.c, but also in preparation for moving some code out of _xxsubinterpretersmodule.c. This change also moves this stuff to the internal API (new: Include/internal/pycore_crossinterp.h). @vstinner did this previously and I undid it. Now I'm re-doing it. :/
* gh-110481: Implement biased reference counting (gh-110764)Sam Gross2023-10-303-12/+5
|
* GH-111339: Fix initialization and finalization of static optimizer types ↵Savannah Ostrowski2023-10-291-14/+10
| | | | (GH-111430)
* gh-111386: Fix `uint32_t` cast in `generated_cases.c.h` (#111387)Nikita Sobolev2023-10-272-2/+2
|
* gh-109587: Allow "precompiled" perf-trampolines to largely mitigate the cost ↵gsallam2023-10-272-7/+84
| | | | of enabling perf-trampolines (#109666)
* gh-111354: define names for RESUME oparg values (#111365)Irit Katriel2023-10-265-7/+8
|
* gh-109094: replace frame->prev_instr by frame->instr_ptr (#109095)Irit Katriel2023-10-2611-120/+184
|
* GH-111213: Fix a few broken stats (GH-111216)Mark Shannon2023-10-261-1/+1
|
* GH-111339: Change `valid` property of executors to `is_valid()` method ↵Mark Shannon2023-10-261-13/+13
| | | | (GH-111350)
* gh-67224: Show source lines in tracebacks when using the -c option when ↵Pablo Galindo Salgado2023-10-261-19/+61
| | | | running Python (#111200)
* gh-106320: Re-add some PyLong/PyDict C-API functions (GH-#111162)scoder2023-10-251-1/+0
| | | | | | | | * gh-106320: Re-add _PyLong_FromByteArray(), _PyLong_AsByteArray() and _PyLong_GCD() to the public header files since they are used by third-party packages and there is no efficient replacement. See https://github.com/python/cpython/issues/111140 See https://github.com/python/cpython/issues/111139 * gh-111262: Re-add _PyDict_Pop() to have a C-API until a new public one is designed.
* GH-109214: _SET_IP before _PUSH_FRAME (but not _POP_FRAME) (GH-111001)Brandt Bucher2023-10-243-42/+25
|
* GH-109369: Add machinery for deoptimizing tier2 executors, both individually ↵Mark Shannon2023-10-233-2/+237
| | | | and globally. (GH-110384)
* gh-67565: Remove redundant C-contiguity checks (GH-105521)Furkan Onder2023-10-233-21/+8
| | | | Co-authored-by: Stefan Krah <skrah@bytereef.org>
* gh-111123: symtable should visit exception handlers before the else block ↵Irit Katriel2023-10-211-2/+2
| | | | (#111142)
* gh-111133: Remove unnecessary PyFrozenSet_Check() calls in const folding ↵Kirill Podoprigora2023-10-201-14/+3
| | | | | (GH-111137) frozenset does not support multiplication.
* gh-111132: Fix crash on interactive_filename in `run_mod` (#111136)Nikita Sobolev2023-10-201-1/+3
|
* gh-76785: Clean Up the Channels Module (gh-110568)Eric Snow2023-10-171-7/+7
|
* gh-84570: Add Timeouts to SendChannel.send() and RecvChannel.recv() (gh-110567)Eric Snow2023-10-171-0/+34
|
* gh-84570: Send-Wait Fixes for _xxinterpchannels (gh-111006)Eric Snow2023-10-171-0/+50
| | | | | There were a few things I did in gh-110565 that need to be fixed. I also forgot to add tests in that PR. (Note that this PR exposes a refleak introduced by gh-110246. I'll take care of that separately.)
* gh-109693: Remove pycore_atomic.h (gh-110992)Donghee Na2023-10-172-2/+0
|
* gh-110964: Remove private _PyArg functions (#110966)Victor Stinner2023-10-1710-9/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the following private functions and structures to pycore_modsupport.h internal C API: * _PyArg_BadArgument() * _PyArg_CheckPositional() * _PyArg_NoKeywords() * _PyArg_NoPositional() * _PyArg_ParseStack() * _PyArg_ParseStackAndKeywords() * _PyArg_Parser structure * _PyArg_UnpackKeywords() * _PyArg_UnpackKeywordsWithVararg() * _PyArg_UnpackStack() * _Py_ANY_VARARGS() Changes: * Python/getargs.h now includes pycore_modsupport.h to export functions. * clinic.py now adds pycore_modsupport.h when one of these functions is used. * Add pycore_modsupport.h includes when a C extension uses one of these functions. * Define Py_BUILD_CORE_MODULE in C extensions which now include directly or indirectly (via code generated by Argument Clinic) pycore_modsupport.h: * _csv * _curses_panel * _dbm * _gdbm * _multiprocessing.posixshmem * _sqlite.row * _statistics * grp * resource * syslog * _testcapi: bad_get() no longer uses METH_FASTCALL calling convention but METH_VARARGS. Replace _PyArg_UnpackStack() with PyArg_ParseTuple(). * _testcapi: add PYTESTCAPI_NEED_INTERNAL_API macro which is defined by _testcapi sub-modules which need the internal C API (pycore_modsupport.h): exceptions.c, float.c, vectorcall.c, watchers.c. * Remove Include/cpython/modsupport.h header file. Include/modsupport.h no longer includes the removed header file. * Fix mypy clinic.py
* gh-109693: Update _gil_runtime_state.locked to use pyatomic.h (gh-110836)Donghee Na2023-10-162-16/+12
|
* gh-110912: Correctly display tracebacks for MemoryError exceptions using the ↵Pablo Galindo Salgado2023-10-161-4/+1
| | | | traceback module (#110921)
* gh-110864: Fix _PyArg_UnpackKeywordsWithVararg overwriting vararg with NULL ↵Nikita Sobolev2023-10-161-1/+1
| | | | (#110868)
* gh-110722: Add PYTHON_PRESITE to import a module before site.py is run (#110769)Łukasz Langa2023-10-142-0/+90
|
* gh-110815: Support non-ASCII keyword names in PyArg_ParseTupleAndKeywords() ↵Serhiy Storchaka2023-10-141-1/+1
| | | | | | | (GH-110816) It already mostly worked, except in the case when invalid keyword argument with non-ASCII name was passed to function with non-ASCII parameter names. Then it crashed in the debug mode.
* gh-110805: Allow the repl to show source code and complete tracebacks (#110775)Pablo Galindo Salgado2023-10-131-12/+72
|
* gh-109693: Update _gil_runtime_state.last_holder to use pyatomic.h (#110605)Donghee Na2023-10-131-7/+7
|
* gh-110721: Use the traceback module for PyErr_Display() and fallback to the ↵Pablo Galindo Salgado2023-10-122-814/+78
| | | | C implementation (#110702)
* gh-110752: Reset `ceval.eval_breaker` to 0 in `interpreter_clear` (GH-110753)Tian Gao2023-10-121-0/+4
|
* gh-109094: remove redundant arg to _PyFrame_PushTrampolineUnchecked (GH-110759)Irit Katriel2023-10-122-2/+2
|
* GH-109214: Convert _SAVE_CURRENT_IP to _SET_IP in tier 2 trace creation. ↵Mark Shannon2023-10-126-52/+15
| | | | (GH-110755)
* gh-104169: Fix test_peg_generator after tokenizer refactoring (#110727)Lysandros Nikolaou2023-10-121-1/+1
| | | | * Fix test_peg_generator after tokenizer refactoring * Remove references to tokenizer.c in comments etc.
* gh-104169: Refactor tokenizer into lexer and wrappers (#110684)Lysandros Nikolaou2023-10-111-1/+3
| | | | | | | | | | | * The lexer, which include the actual lexeme producing logic, goes into the `lexer` directory. * The wrappers, one wrapper per input mode (file, string, utf-8, and readline), go into the `tokenizer` directory and include logic for creating a lexer instance and managing the buffer for different modes. --------- Co-authored-by: Pablo Galindo <pablogsal@gmail.com> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
* gh-84489: Properly handle trailing spaces in Py_BuildValue() format strings ↵Zackery Spytz2023-10-111-27/+23
| | | | | | | | | (GH-21158) The docs state that the space, tab, colon, and comma characters are ignored in Py_BuildValue() format strings. Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-109595: Add -Xcpu_count=<n> cmdline for container users (#109667)Donghee Na2023-10-103-2/+101
| | | | | | --------- Co-authored-by: Victor Stinner <vstinner@python.org> Co-authored-by: Gregory P. Smith [Google LLC] <greg@krypto.org>
* Remove an old macro from executor.c (#110597)Brandt Bucher2023-10-101-3/+0
|
* gh-109693: Use pyatomic.h for signal module (gh-110480)Donghee Na2023-10-091-1/+1
|
* gh-76785: Add SendChannel.send_buffer() (#110246)Eric Snow2023-10-092-29/+45
| | | (This is still a test module.)
* gh-110514: Add PY_THROW to `sys.setprofile` events (GH-110524)Tian Gao2023-10-091-1/+7
|
* gh-110237: Check `PyList_Append` for errors in `_PyEval_MatchClass` (#110238)denballakh2023-10-081-3/+11
|
* gh-108277: Add os.timerfd_create() function (#108382)Masaru Tsuchiyama2023-10-071-2/+12
| | | | | | | | Add wrapper for timerfd_create, timerfd_settime, and timerfd_gettime to os module. Co-authored-by: Serhiy Storchaka <storchaka@gmail.com> Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com> Co-authored-by: Victor Stinner <vstinner@python.org>
* GH-110455: Guard `assert(tstate->thread_id > 0)` with `#ifndef ↵Brett Cannon2023-10-061-2/+2
| | | | HAVE_PTHREAD_STUBS` (GH-110487)
* gh-85283: Add PySys_AuditTuple() function (#108965)Victor Stinner2023-10-051-3/+19
| | | | | | sys.audit() now has assertions to check that the event argument is not NULL and that the format argument does not use the "N" format. Add tests on PySys_AuditTuple().
* gh-109549: Add new states to PyThreadState to support PEP 703 (gh-109915)Sam Gross2023-10-053-91/+95
| | | This adds a new field 'state' to PyThreadState that can take on one of three values: _Py_THREAD_ATTACHED, _Py_THREAD_DETACHED, or _Py_THREAD_GC. The "attached" and "detached" states correspond closely to acquiring and releasing the GIL. The "gc" state is current unused, but will be used to implement stop-the-world GC for --disable-gil builds in the near future.