/* For now we hard-code this to a value for which we are confident
all the static builtin types will fit (for all builds). */
-#define _Py_MAX_MANAGED_STATIC_BUILTIN_TYPES 201
+#define _Py_MAX_MANAGED_STATIC_BUILTIN_TYPES 202
#define _Py_MAX_MANAGED_STATIC_EXT_TYPES 10
#define _Py_MAX_MANAGED_STATIC_TYPES \
(_Py_MAX_MANAGED_STATIC_BUILTIN_TYPES + _Py_MAX_MANAGED_STATIC_EXT_TYPES)
static int
module_exec(PyObject *module)
{
+ PyInterpreterState *interp = PyInterpreterState_Get();
+
if (_PyTestInternalCapi_Init_Lock(module) < 0) {
return 1;
}
return 1;
}
+ // + 1 more due to one loop spent on tracing.
+ unsigned long threshold = interp->opt_config.jump_backward_initial_value + 2;
if (PyModule_Add(module, "TIER2_THRESHOLD",
- // + 1 more due to one loop spent on tracing.
- PyLong_FromLong(JUMP_BACKWARD_INITIAL_VALUE + 2)) < 0) {
+ PyLong_FromUnsignedLong(threshold)) < 0) {
return 1;
}