mirror of
https://github.com/python/cpython.git
synced 2026-01-08 08:22:41 +00:00
Use tstate->interp to get the interpreter state in bytecodes.c (GH-107506)
This commit is contained in:
parent
5e584eb704
commit
dfb55d9d7f
3 changed files with 8 additions and 8 deletions
|
|
@ -3245,7 +3245,7 @@ dummy_func(
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 1, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.len, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *arg = args[0];
|
||||
|
|
@ -3272,7 +3272,7 @@ dummy_func(
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 2, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.isinstance, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *cls = args[1];
|
||||
|
|
@ -3295,7 +3295,7 @@ dummy_func(
|
|||
ASSERT_KWNAMES_IS_NULL();
|
||||
assert(oparg == 1);
|
||||
assert(method != NULL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(method != interp->callable_cache.list_append, CALL);
|
||||
DEOPT_IF(!PyList_Check(self), CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
|
|
|
|||
4
Python/executor_cases.c.h
generated
4
Python/executor_cases.c.h
generated
|
|
@ -2154,7 +2154,7 @@
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 1, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.len, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *arg = args[0];
|
||||
|
|
@ -2189,7 +2189,7 @@
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 2, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.isinstance, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *cls = args[1];
|
||||
|
|
|
|||
6
Python/generated_cases.c.h
generated
6
Python/generated_cases.c.h
generated
|
|
@ -3984,7 +3984,7 @@
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 1, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.len, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *arg = args[0];
|
||||
|
|
@ -4020,7 +4020,7 @@
|
|||
total_args++;
|
||||
}
|
||||
DEOPT_IF(total_args != 2, CALL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(callable != interp->callable_cache.isinstance, CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
PyObject *cls = args[1];
|
||||
|
|
@ -4050,7 +4050,7 @@
|
|||
ASSERT_KWNAMES_IS_NULL();
|
||||
assert(oparg == 1);
|
||||
assert(method != NULL);
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyInterpreterState *interp = tstate->interp;
|
||||
DEOPT_IF(method != interp->callable_cache.list_append, CALL);
|
||||
DEOPT_IF(!PyList_Check(self), CALL);
|
||||
STAT_INC(CALL, hit);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue