| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…TOP instead of END_FOR. To support tier 2 side exits in loops.
|
Maybe we can do without a separate END_FOR opcode and instead just generate a POP_TOP? EDIT: Never mind, it's needed for instrumentation. |
Sorry, something went wrong.
There was a problem hiding this comment.
Looks good, never mind my premature commend about END_FOR/POP_TOP.
Sorry, something went wrong.
| string = &_Py_ID(alias); | ||
| assert(_PyUnicode_CheckConsistency(string, 1)); | ||
| _PyUnicode_InternInPlace(interp, &string); |
There was a problem hiding this comment.
(The updates to this file (and a few other generated files) are spurious and will disappear after merging the latest main.)
Sorry, something went wrong.
|
The benchmarks show no performance impact. |
Sorry, something went wrong.
That's evidently not clear. The order of the POP_TOP and END_FOR is important as well. |
Sorry, something went wrong.
There was a problem hiding this comment.
Thanks!
Sorry, something went wrong.
|
Oh, fun stuff. Windows compilation error. :-( |
Sorry, something went wrong.
…GH-114247) * Compiler emits END_FOR; POP_TOP instead of END_FOR. To support tier 2 side exits in loops.
…GH-114247) * Compiler emits END_FOR; POP_TOP instead of END_FOR. To support tier 2 side exits in loops.
| Back | FazBrowse Home | New Git URL |
In order to support tier 2 side-exits from FOR_ITER variants, we need a target that has the same stack as the exhaustion guard.
Currently we can either jump to the END_FOR, as we do for generators or the instruction afterwards, which we do for FOR_ITER.
In order to exit a guard we need a target in between those instructions, that pops the iterator, but not the value.
The compiler emits END_FOR; POP_TOP instead of END_FOR.
Previously:
Now: