Title: Refactor the JIT uops · Issue #148211 · python/cpython · GitHub
Open Graph Title: Refactor the JIT uops · Issue #148211 · python/cpython
X Title: Refactor the JIT uops · Issue #148211 · python/cpython
Description: Feature or enhancement Proposal: The JIT optimizer initially only allowed a inplace op rewrites. This led to us contorting the JIT uops to fit that. Now that the JIT optimizer allows more than one op to be written at once, we should clea...
Open Graph Description: Feature or enhancement Proposal: The JIT optimizer initially only allowed a inplace op rewrites. This led to us contorting the JIT uops to fit that. Now that the JIT optimizer allows more than one ...
X Description: Feature or enhancement Proposal: The JIT optimizer initially only allowed a inplace op rewrites. This led to us contorting the JIT uops to fit that. Now that the JIT optimizer allows more than one ...
Opengraph URL: https://github.com/python/cpython/issues/148211
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Refactor the JIT uops","articleBody":"# Feature or enhancement\n\n### Proposal:\n\nThe JIT optimizer initially only allowed a inplace op rewrites. This led to us contorting the JIT uops to fit that.\n\nNow that the JIT optimizer allows more than one op to be written at once, we should clean up and de-duplicate all the composite uops.\n\nE.g.\n```\nREPLACE_OP(_POP_TOP_LOAD_CONST_INLINE_BORROW, ..)\n```\nshould become\n```\nADD_OP(_POP_TOP, ...)\nADD_OP(_LOAD_CONST_INLINE_BORROW, ...)\n```\nand `_POP_TOP_LOAD_CONST_INLINE_BORROW` should then be completely removed from the JIT uops and bytecodes.c. This will allow us to de-duplicate and refactor the code greatly, while making the existing optimizations also more effective as we don't have to do as much repeated work.\n\n### Has this already been discussed elsewhere?\n\nThis is a minor feature, which does not need previous discussion elsewhere\n\n### Links to previous discussion of this feature:\n\n_No response_\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-148230\n* gh-148258\n* gh-148283\n* gh-148313\n* gh-148357\n* gh-148377\n* gh-148816\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/Fidget-Spinner","@type":"Person","name":"Fidget-Spinner"},"datePublished":"2026-04-07T12:35:54.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":10},"url":"https://github.com/148211/cpython/issues/148211"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b965477c-70b7-9a84-11eb-a707fe8c804e |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8024:3A486F:1F563:29EF8:6A52DC5B |
| html-safe-nonce | 7c7d2ce24bbe209d6f0f16b9fe4dd3a6cdba1de9d92079fd89941d91fe77c628 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MDI0OjNBNDg2RjoxRjU2MzoyOUVGODo2QTUyREM1QiIsInZpc2l0b3JfaWQiOiI4NTE5MzA2NjMxMTQ5OTY4NDc1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | b27f596fcd83c4bb367800be171139dd1c30362e19ed1abca5c309c0530c03c5 |
| hovercard-subject-tag | issue:4217684590 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/148211/issue_layout |
| twitter:image | https://opengraph.githubassets.com/ca642c97e1e8a16a773b859e714e1113708875649b14b8d40e63cd87603db9bd/python/cpython/issues/148211 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ca642c97e1e8a16a773b859e714e1113708875649b14b8d40e63cd87603db9bd/python/cpython/issues/148211 |
| og:image:alt | Feature or enhancement Proposal: The JIT optimizer initially only allowed a inplace op rewrites. This led to us contorting the JIT uops to fit that. Now that the JIT optimizer allows more than one ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Fidget-Spinner |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width