GH-109214: Convert _SAVE_CURRENT_IP to _SET_IP in tier 2 trace creation. (GH-110755)

This commit is contained in:
Mark Shannon 2023-10-12 10:34:32 +01:00 committed by GitHub
parent fb7843ee89
commit 19b7ead5eb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 22 additions and 59 deletions

View file

@ -3270,21 +3270,11 @@
}
case _SET_IP: {
TIER_TWO_ONLY
frame->prev_instr = ip_offset + oparg;
break;
}
case _SAVE_CURRENT_IP: {
#if TIER_ONE
frame->prev_instr = next_instr - 1;
#endif
#if TIER_TWO
// Relies on a preceding _SET_IP
frame->prev_instr--;
#endif
break;
}
case _EXIT_TRACE: {
frame->prev_instr--; // Back up to just before destination
_PyFrame_SetStackPointer(frame, stack_pointer);