gh-133171: Re-enable JUMP_BACKWARD to free-threading build (gh-137800)

This commit is contained in:
Donghee Na 2025-09-24 14:19:17 +09:00 committed by GitHub
parent c8624cd367
commit c4f21d7c7c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 47 additions and 34 deletions

View file

@ -119,6 +119,7 @@ _PyOptimizer_Optimize(
PyInterpreterState *interp = _PyInterpreterState_GET();
assert(interp->jit);
assert(!interp->compiling);
#ifndef Py_GIL_DISABLED
interp->compiling = true;
// The first executor in a chain and the MAX_CHAIN_DEPTH'th executor *must*
// make progress in order to avoid infinite loops or excessively-long
@ -160,6 +161,9 @@ _PyOptimizer_Optimize(
assert((*executor_ptr)->vm_data.valid);
interp->compiling = false;
return 1;
#else
return 0;
#endif
}
static _PyExecutorObject *