FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

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

/ cpython Public

gh-104584: Allow unspecialized instructions in superblocks - #106497

Merged
gvanrossum merged 5 commits into
python:mainfrom
gvanrossum:unspecialized-uops
Jul 7, 2023
Merged

gh-104584: Allow unspecialized instructions in superblocks#106497
gvanrossum merged 5 commits into
python:mainfrom
gvanrossum:unspecialized-uops

Conversation

gvanrossum commented Jul 6, 2023
edited
Loading

Copy link
Copy Markdown
Member

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.)

This adds a whole bunch of unspecialized opcodes to superblocks.
While we may not want that eventually, for now this helps finding bugs.

markshannon commented Jul 7, 2023
edited
Loading

Copy link
Copy Markdown
Member

I'm hoping that our specialization will become good enough that it will be become largely irrelevant whether we include unspecialized instructions or not.

If it helps testing, then let's add them. As you say, we can also remove them later if they are a problem.

gvanrossum enabled auto-merge (squash) July 7, 2023 16:47
gvanrossum merged commit b3648f0 into python:main Jul 7, 2023
gvanrossum deleted the unspecialized-uops branch July 7, 2023 18:05
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL