mirror of
https://github.com/python/cpython.git
synced 2026-02-11 04:11:11 +00:00
[3.11] GH-93516: Backport GH-93769: Speedup line number checks when tracing (GH-94127)
Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
This commit is contained in:
parent
8c2af49071
commit
3ece6e6feb
7 changed files with 409 additions and 298 deletions
|
|
@ -62,7 +62,8 @@ typedef uint16_t _Py_CODEUNIT;
|
|||
PyObject *co_exceptiontable; /* Byte string encoding exception handling \
|
||||
table */ \
|
||||
int co_flags; /* CO_..., see below */ \
|
||||
int co_warmup; /* Warmup counter for quickening */ \
|
||||
short co_warmup; /* Warmup counter for quickening */ \
|
||||
short _co_linearray_entry_size; /* Size of each entry in _co_linearray */ \
|
||||
\
|
||||
/* The rest are not so impactful on performance. */ \
|
||||
int co_argcount; /* #arguments, except *args */ \
|
||||
|
|
@ -88,6 +89,7 @@ typedef uint16_t _Py_CODEUNIT;
|
|||
PyObject *co_qualname; /* unicode (qualname, for reference) */ \
|
||||
PyObject *co_linetable; /* bytes object that holds location info */ \
|
||||
PyObject *co_weakreflist; /* to support weakrefs to code objects */ \
|
||||
char *_co_linearray; /* array of line offsets */ \
|
||||
/* Scratch space for extra data relating to the code object. \
|
||||
Type is a void* to keep the format private in codeobject.c to force \
|
||||
people to go through the proper APIs. */ \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue