10000 gh-120437: drop specialization when the code frame is exceed current … · python/cpython@aeee3db · GitHub
[go: up one dir, main page]

Skip to content

Commit aeee3db

Browse files
committed
gh-120437: drop specialization when the code frame is exceed current stack
Signed-off-by: Manjusaka <me@manjusaka.me>
1 parent 49f51de commit aeee3db

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

Python/bytecodes.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3238,6 +3238,7 @@ dummy_func(
32383238
assert(PyFunction_Check(callable));
32393239
PyFunctionObject *func = (PyFunctionObject *)callable;
32403240
PyCodeObject *code = (PyCodeObject *)func->func_code;
3241+
EXIT_IF(!_PyThreadState_HasStackSpace(tstate, code->co_framesize));
32413242
EXIT_IF(code->co_argcount != oparg + (self_or_null != NULL));
32423243
}
32433244

Python/executor_cases.c.h

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/generated_cases.c.h

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)
0