cpython/Modules/clinic
Brandt Bucher 336366fd7c
GH-140643: Add <native> and <GC> frames to the sampling profiler (#141108)
- Introduce a new field in the GC state to store the frame that initiated garbage collection.
- Update RemoteUnwinder to include options for including "<native>" and "<GC>" frames in the stack trace.
- Modify the sampling profiler to accept parameters for controlling the inclusion of native and GC frames.
- Enhance the stack collector to properly format and append these frames during profiling.
- Add tests to verify the correct behavior of the profiler with respect to native and GC frames, including options to exclude them.

Co-authored-by: Pablo Galindo Salgado <pablogsal@gmail.com>
2025-11-17 13:39:00 +00:00
..
_abc.c.h gh-110964: Remove private _PyArg functions (#110966) 2023-10-17 14:30:31 +02:00
_asynciomodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_bisectmodule.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
_bz2module.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_codecsmodule.c.h gh-55531: Implement normalize_encoding in C (#136643) 2025-10-30 15:31:47 +01:00
_collectionsmodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_csv.c.h gh-137986: Fix and improve the csv functions docstrings (GH-137987) 2025-08-24 11:13:31 +03:00
_curses_panel.c.h gh-133579: correctly report C curses errors in _curses_panel (#134629) 2025-06-08 09:10:52 +02:00
_cursesmodule.c.h gh-137920: Fix semantically relevant typo in curses.window.attron (#137940) 2025-08-22 10:27:02 +02:00
_datetimemodule.c.h gh-97517: Add documentation links to datetime strftime/strptime docstrings (#138559) 2025-09-15 19:50:46 +01:00
_dbmmodule.c.h gh-127081: add critical sections to dbm objects (gh-132749) 2025-05-14 13:49:35 -04:00
_elementtree.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_functoolsmodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_gdbmmodule.c.h gh-127081: add critical sections to dbm objects (gh-132749) 2025-05-14 13:49:35 -04:00
_hashopenssl.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
_heapqmodule.c.h gh-116738: Make _heapq module thread-safe (#135036) 2025-06-09 10:57:29 -07:00
_interpqueuesmodule.c.h GH-137630: Convert `_interpqueues` to use Argument Clinic (#137685) 2025-09-17 17:35:00 +01:00
_interpretersmodule.c.h GH-137630: Argument Clinic: Reduce use of 'as' for renaming in `_interpretersmodule.c` (#137680) 2025-08-12 23:28:38 +01:00
_json.c.h gh-137821: Improve Argument Clinic definitions in the `_json` module (#140780) 2025-10-30 10:32:08 +00:00
_localemodule.c.h gh-111089: Revert PyUnicode_AsUTF8() changes (#111833) 2023-11-07 22:36:13 +00:00
_lsprof.c.h gh-116738: make cProfile module thread-safe (#138229) 2025-09-06 13:19:14 +05:30
_lzmamodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_opcode.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_operator.c.h gh-115808: Add `is_none and is_not_none to operator` (#115814) 2024-08-10 20:16:34 +01:00
_pickle.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_posixsubprocess.c.h gh-121381 Remove subprocess._USE_VFORK escape hatch (#121383) 2024-07-30 18:39:54 -07:00
_queuemodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_randommodule.c.h gh-133489: Remove size restrictions on getrandbits() and randbytes() (GH-133658) 2025-05-31 11:23:01 +03:00
_remote_debugging_module.c.h GH-140643: Add <native> and <GC> frames to the sampling profiler (#141108) 2025-11-17 13:39:00 +00:00
_ssl.c.h gh-139748: fix leaks in AC error paths when using unicode FS-based converters (#139765) 2025-10-08 20:52:44 +05:30
_statisticsmodule.c.h gh-85283: Build _statistics extension with the limited C API (#116927) 2024-03-17 18:59:02 +01:00
_struct.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_suggestions.c.h gh-116738: Make _suggestions module thread-safe (gh-140321) 2025-10-22 09:14:48 +09:00
_sysconfig.c.h gh-88402: Add new sysconfig variables on Windows (GH-110049) 2023-10-04 22:50:29 +00:00
_testclinic.c.h gh-111489: Remove _PyTuple_FromArray() alias (#139973) 2025-10-11 22:58:14 +02:00
_testclinic_depr.c.h gh-111489: Remove _PyTuple_FromArray() alias (#139973) 2025-10-11 22:58:14 +02:00
_testclinic_kwds.c.h gh-111489: Remove _PyTuple_FromArray() alias (#139973) 2025-10-11 22:58:14 +02:00
_testclinic_limited.c.h gh-116646: Add limited C API support to AC fildes converter (#116769) 2024-03-14 10:28:58 +01:00
_testinternalcapi.c.h gh-122320: Limit dict key versions used by test_opcache. (gh-132961) 2025-04-28 12:54:55 -07:00
_testmultiphase.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
_threadmodule.c.h gh-137808: use argument clinic for _thread.lock and _thread.RLock (#137809) 2025-08-15 13:58:10 +00:00
_tkinter.c.h gh-111178: Change Argument Clinic signature for METH_O (#130682) 2025-03-11 16:33:36 +01:00
_tracemalloc.c.h gh-110964: Remove private _PyArg functions (#110966) 2023-10-17 14:30:31 +02:00
_typingmodule.c.h gh-107603: Argument Clinic: Only include pycore_gc.h if needed (#108726) 2023-08-31 23:42:34 +02:00
_weakref.c.h gh-111926: Make weakrefs thread-safe in free-threaded builds (#117168) 2024-04-08 10:58:38 -04:00
_winapi.c.h gh-133711: Log Windows OEM code page in test.pythoninfo (#134840) 2025-05-28 17:41:11 +02:00
_zoneinfo.c.h gh-132629: Deprecate accepting out-of-range values for unsigned integers in PyArg_Parse (GH-132630) 2025-07-13 12:44:54 +03:00
arraymodule.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
binascii.c.h gh-132629: Deprecate accepting out-of-range values for unsigned integers in PyArg_Parse (GH-132630) 2025-07-13 12:44:54 +03:00
blake2module.c.h gh-135532: use defining_class for copying BLAKE-2 and SHA-3 objects (#135838) 2025-06-24 09:58:07 +02:00
cmathmodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
faulthandler.c.h gh-137725: Convert faulthandler to Argument Clinic (#137726) 2025-08-16 15:16:04 +02:00
fcntlmodule.c.h gh-140615: Update docstrings in the fcntl module (GH-140619) 2025-11-08 12:17:59 +02:00
gcmodule.c.h gh-111489: Remove _PyTuple_FromArray() alias (#139973) 2025-10-11 22:58:14 +02:00
grpmodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
hmacmodule.c.h gh-99108: Implement HACL* HMAC (#130157) 2025-04-04 19:04:00 +02:00
itertoolsmodule.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
mathintegermodule.c.h gh-81313: Add the math.integer module (PEP-791) (GH-133909) 2025-10-31 16:13:43 +02:00
mathmodule.c.h gh-81313: Add the math.integer module (PEP-791) (GH-133909) 2025-10-31 16:13:43 +02:00
md5module.c.h gh-134696: align OpenSSL and HACL*-based hash functions constructors AC signatures (#134713) 2025-05-31 09:37:47 +02:00
mmapmodule.c.h gh-116738: make mmap module thread-safe (#139237) 2025-10-09 12:00:47 +05:30
overlapped.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
posixmodule.c.h fix typo in comments PyOS_CallInputHook -> PyOS_InputHook (#140237) 2025-10-20 14:25:57 +05:30
pwdmodule.c.h gh-116738: Make pwd module thread-safe (#136695) 2025-07-17 09:16:01 -07:00
pyexpat.c.h gh-90949: expose Expat API to tune exponential expansion protections (#139368) 2025-09-28 08:27:04 +00:00
readline.c.h gh-126895: Fix readline module in free-threaded build (#131208) 2025-03-17 11:57:11 -04:00
resource.c.h gh-137044: Support large limit values in getrlimit() and setrlimit() (GH-137338) 2025-08-07 11:06:37 +03:00
selectmodule.c.h gh-67795: Accept any real numbers as timestamp and timeout (GH-139224) 2025-09-23 21:31:42 +03:00
sha1module.c.h gh-134696: align OpenSSL and HACL*-based hash functions constructors AC signatures (#134713) 2025-05-31 09:37:47 +02:00
sha2module.c.h gh-134696: align OpenSSL and HACL*-based hash functions constructors AC signatures (#134713) 2025-05-31 09:37:47 +02:00
sha3module.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
signalmodule.c.h gh-67795: Accept any real numbers as timestamp and timeout (GH-139224) 2025-09-23 21:31:42 +03:00
socketmodule.c.h gh-139748: fix leaks in AC error paths when using unicode FS-based converters (#139765) 2025-10-08 20:52:44 +05:30
symtablemodule.c.h gh-135801: Add the module parameter to compile() etc (GH-139652) 2025-11-13 13:21:32 +02:00
syslogmodule.c.h gh-131525: Cache the result of tuple_hash (#131529) 2025-03-27 09:57:06 -04:00
termios.c.h gh-85283: Build termios extension with the limited C API (#116928) 2024-03-17 15:12:29 +00:00
timemodule.c.h gh-111482: Use Argument Clinic for clock_gettime() (#111641) 2023-11-02 14:29:05 +01:00
unicodedata.c.h gh-129117: Add unicodedata.isxidstart() function (#140269) 2025-10-30 10:18:12 +00:00
zlibmodule.c.h GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00