mirror of
https://github.com/python/cpython.git
synced 2026-02-07 10:20:33 +00:00
gh-139109: Replace _CHECK_STACK_SPACE with _CHECK_STACK_SPACE_OPERAND in JIT optiimizer (GH-144394)
This commit is contained in:
parent
141fd8b894
commit
89e6607e05
5 changed files with 43 additions and 63 deletions
|
|
@ -1068,13 +1068,17 @@ dummy_func(void) {
|
|||
}
|
||||
|
||||
op(_CHECK_STACK_SPACE, (unused, unused, unused[oparg] -- unused, unused, unused[oparg])) {
|
||||
assert((this_instr + 4)->opcode == _PUSH_FRAME);
|
||||
PyCodeObject *co = get_code_with_logging((this_instr + 4));
|
||||
if (co == NULL) {
|
||||
ctx->done = true;
|
||||
break;
|
||||
}
|
||||
ADD_OP(_CHECK_STACK_SPACE_OPERAND, 0, co->co_framesize);
|
||||
}
|
||||
|
||||
op (_CHECK_STACK_SPACE_OPERAND, (framesize/2 -- )) {
|
||||
(void)framesize;
|
||||
/* We should never see _CHECK_STACK_SPACE_OPERANDs.
|
||||
* They are only created at the end of this pass. */
|
||||
Py_UNREACHABLE();
|
||||
}
|
||||
|
||||
op(_PUSH_FRAME, (new_frame -- )) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue