summaryrefslogtreecommitdiffstats
path: root/Python/specialize.c
diff options
context:
space:
mode:
authorBrandt Bucher <brandtbucher@microsoft.com>2023-04-05 21:15:49 (GMT)
committerGitHub <noreply@github.com>2023-04-05 21:15:49 (GMT)
commitb4978ff872be5102117b4e25d93dbbb4e04c8292 (patch)
tree3e6ef44b198924b39a84130933de7b353ebe1465 /Python/specialize.c
parentaa5a9b5eb767fd849ea09d0842e33691e690de7c (diff)
downloadcpython-b4978ff872be5102117b4e25d93dbbb4e04c8292.zip
cpython-b4978ff872be5102117b4e25d93dbbb4e04c8292.tar.gz
cpython-b4978ff872be5102117b4e25d93dbbb4e04c8292.tar.bz2
GH-88691: Shrink the CALL caches (GH-103230)
Diffstat (limited to 'Python/specialize.c')
-rw-r--r--Python/specialize.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/Python/specialize.c b/Python/specialize.c
index 9187438..a9d3226 100644
--- a/Python/specialize.c
+++ b/Python/specialize.c
@@ -1627,17 +1627,12 @@ specialize_py_call(PyFunctionObject *func, _Py_CODEUNIT *instr, int nargs,
assert(nargs <= argcount && nargs >= min_args);
assert(min_args >= 0 && defcount >= 0);
assert(defcount == 0 || func->func_defaults != NULL);
- if (min_args > 0xffff) {
- SPECIALIZATION_FAIL(CALL, SPEC_FAIL_OUT_OF_RANGE);
- return -1;
- }
int version = _PyFunction_GetVersionForCurrentState(func);
if (version == 0) {
SPECIALIZATION_FAIL(CALL, SPEC_FAIL_OUT_OF_VERSIONS);
return -1;
}
write_u32(cache->func_version, version);
- cache->min_args = min_args;
if (argcount == nargs) {
instr->op.code = bound_method ? CALL_BOUND_METHOD_EXACT_ARGS : CALL_PY_EXACT_ARGS;
}