◐ Shell
clean mode source ↗

gh-104584: Allow unspecialized instructions in superblocks by gvanrossum · Pull Request #106497 · python/cpython

This is done by not searching for forbidden words inside #if ENABLE_SPECIALIZATION. (And making that flag false when the Tier 2 uops are being compiled.)

@markshannon, I know this is controversial, but while we are incrementally developing superblock generation, I find it helpful if there are as many superblocks as possible, and those are as long as possible. Allowing unspecialized instructions helps towards this goal (and is quicker than inventing new specializations). I'm making it its own PR so hopefully it will be easy to roll back in the future. (In fact, all you'd have to do is change the one call to variable_used_unspecialized in generate_cases.py back to variable_used, and regenerate.)