Skip to content

Commit

Permalink
fix some bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
Fidget-Spinner committed Dec 10, 2024
1 parent 7644afe commit 55c51b4
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion Python/bytecodes.c
Original file line number Diff line number Diff line change
Expand Up @@ -4956,7 +4956,6 @@ dummy_func(
tier2 op(_CHECK_FUNCTION_UNMODIFIED, (func_version/2, callable_p/4 --)) {
assert(PyFunction_Check(callable_p));
PyFunctionObject *func = (PyFunctionObject *)callable_p;
assert(func == PyStackRef_AsPyObjectBorrow(frame->f_funcobj));
DEOPT_IF(func->func_version != func_version);
}

Expand Down
1 change: 0 additions & 1 deletion Python/executor_cases.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Python/partial_evaluator_bytecodes.c
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,7 @@ dummy_func(void) {
}
else {
DPRINTF(2, "Virtualizing function\n");
materialize(&retval);
// The amount to shrink is the number of locals + 2 (callable and null/self).
REPLACE_OP(this_instr, _SHRINK_STACK, 0, this_instr->operand0);
this_instr->operand1 = ctx->frame->locals_len + 2;
Expand Down
1 change: 1 addition & 0 deletions Python/partial_evaluator_cases.c.h
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,7 @@
}
else {
DPRINTF(2, "Virtualizing function\n");
materialize(&retval);
// The amount to shrink is the number of locals + 2 (callable and null/self).
REPLACE_OP(this_instr, _SHRINK_STACK, 0, this_instr->operand0);
this_instr->operand1 = ctx->frame->locals_len + 2;
Expand Down

0 comments on commit 55c51b4

Please sign in to comment.