mirror of
https://github.com/python/cpython.git
synced 2026-01-06 23:42:34 +00:00
replace thread state objects' ticker and checkinterval fields with two
globals, _Py_Ticker and _Py_CheckInterval. This also implements Jeremy's
shortcut in Py_AddPendingCall that zeroes out _Py_Ticker. This allows the
test in the main loop to only test a single value.
The gory details are at
http://python.org/sf/602191
This commit is contained in:
parent
d229b3ae04
commit
d581d7792b
5 changed files with 15 additions and 10 deletions
|
|
@ -48,6 +48,10 @@ PyAPI_FUNC(int) Py_GetRecursionLimit(void);
|
|||
PyAPI_FUNC(char *) PyEval_GetFuncName(PyObject *);
|
||||
PyAPI_FUNC(char *) PyEval_GetFuncDesc(PyObject *);
|
||||
|
||||
/* this used to be handled on a per-thread basis - now just two globals */
|
||||
PyAPI_DATA(volatile int) _Py_Ticker;
|
||||
PyAPI_DATA(int) _Py_CheckInterval;
|
||||
|
||||
/* Interface for threads.
|
||||
|
||||
A module that plans to do a blocking system call (or something else
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@ typedef struct _is {
|
|||
PyObject *sysdict;
|
||||
PyObject *builtins;
|
||||
|
||||
int checkinterval;
|
||||
#ifdef HAVE_DLOPEN
|
||||
int dlopenflags;
|
||||
#endif
|
||||
|
|
@ -50,7 +49,6 @@ typedef struct _ts {
|
|||
|
||||
struct _frame *frame;
|
||||
int recursion_depth;
|
||||
int ticker;
|
||||
int tracing;
|
||||
int use_tracing;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue