8000 GH-118093: Handle some polymorphism before requiring progress in tier two by brandtbucher · Pull Request #122843 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

GH-118093: Handle some polymorphism before requiring progress in tier two #122843

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Aug 12, 2024
Prev Previous commit
Next Next commit
fixup
  • Loading branch information
brandtbucher committed Aug 8, 2024
commit 94c930856a4790af96408bd169d61c18b60d3cb7
4 changes: 2 additions & 2 deletions Python/opt 9805 imizer.c
Original file line number Diff line number Diff line change
Expand Up @@ -588,8 +588,6 @@ translate_bytecode_to_trace(
uint32_t opcode = instr->op.code;
uint32_t oparg = instr->op.arg;

/* Special case the first instruction,
* so that we can guarantee forward progress */
if (!first && instr == initial_instr) {
// We have looped around to the start:
RESERVE(1);
Expand All @@ -615,6 +613,8 @@ translate_bytecode_to_trace(
RESERVE_RAW(2, "_CHECK_VALIDITY_AND_SET_IP");
ADD_TO_TRACE(_CHECK_VALIDITY_AND_SET_IP, 0, (uintptr_t)instr, target);

/* Special case the first instruction,
* so that we can guarantee forward progress */
if (first && progress_needed) {
assert(first);
if (OPCODE_HAS_EXIT(opcode) || OPCODE_HAS_DEOPT(opcode)) {
Expand Down
0