René's URL Explorer Experiment


Title: gh-146306: Optimize float operations by mutating uniquely-referenced operands in place (JIT only) by eendebakpt · Pull Request #146307 · python/cpython · GitHub

Open Graph Title: gh-146306: Optimize float operations by mutating uniquely-referenced operands in place (JIT only) by eendebakpt · Pull Request #146307 · python/cpython

X Title: gh-146306: Optimize float operations by mutating uniquely-referenced operands in place (JIT only) by eendebakpt · Pull Request #146307 · python/cpython

Description: We can add the following tier 2 micro-ops that mutate the uniquely-referenced operand: _BINARY_OP_ADD_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _BINARY_OP_SUBTRACT_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _BINARY_OP_MULTIPLY_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _UNARY_NEGATIVE_FLOAT_INPLACE — unique operand The _RIGHT variants handle commutative ops (add, multiply) plus subtract when only the RHS is unique. The optimizer emits these in optimizer_bytecodes.c when PyJitRef_IsUnique(left) or PyJitRef_IsUnique(right) is true and the operand is a known float. The mutated operand is marked as borrowed so the following _POP_TOP becomes _POP_TOP_NOP. Micro-benchmarks: Expression main optimized Speedup total += a*b + c 24.0 ns/iter 11.5 ns/iter 2.1x total += a + b 16.9 ns/iter 11.0 ns/iter 1.5x total += a*b + c*d 28.5 ns/iter 18.3 ns/iter 1.6x pyperformance nbody (20k iterations): main optimized Speedup nbody 60.6 ms 49.0 ms 1.19x (19% faster) Followup Some operations that could be added in followup PR's: division of floats (same as this PR, but needs to handle division by zero), operations on a float and an (compact) int with a uniquely referenced float, integer operations (but this is more involved because of small ints and number of digits), operations with complex numbers (same as this PR, but maybe the use case for complex is less). Script """Demo script for the inplace float mutation optimization in the tier 2 optimizer. ./configure --enable-experimental-jit=interpreter --with-pydebug ./configure --enable-experimental-jit=yes --with-pydebug Usage: ./python jit_float_demo.py # filtered trace (float-related ops) ./python jit_float_demo.py --all # full trace (all ops) """ import sys import timeit SHOW_ALL = "--all" in sys.argv # --- System info --- print("=" * 60) print("CPython JIT / Tier 2 Demo") print("=" * 60) print(f"Python version: {sys.version}") print(f"Debug build: {hasattr(sys, 'gettotalrefcount')}") print(f"Free-threaded: {not sys._is_gil_enabled()}") jit_mod = getattr(sys, "_jit", None) if jit_mod is not None: print(f"JIT available: {jit_mod.is_available()}") print(f"JIT enabled: {jit_mod.is_enabled()}") else: print("JIT: not compiled in") tier2 = False try: from _testinternalcapi import TIER2_THRESHOLD tier2 = True print(f"Tier 2: enabled (threshold={TIER2_THRESHOLD})") except (ImportError, AttributeError): print("Tier 2: disabled (build without _Py_TIER2)") print() # --- Example functions --- def f_adds(n, a, b, c): """a*b + c per iteration — the multiply result is unique and reused.""" total = 0.0 for i in range(n): total = a + b + c return total def f_chain(n, a, b, c): """a*b + c per iteration — the multiply result is unique and reused.""" total = 0.0 for i in range(n): total += a * b + c return total def f_simple_add(n, a, b): """a + b per iteration — no unique intermediate.""" total = 0.0 for i in range(n): total += a + b return total def f_long_chain(n, a, b, c, d): """a*b + c*d per iteration — two unique intermediates.""" total = 0.0 for i in range(n): total += a * b + c * d return total def f_negate(n, a, b): """a*b + c*d per iteration — two unique intermediates.""" total = 0.0 for i in range(n): total = - (a + b) return total # --- Warm up to trigger tier 2 --- LOOP = 10_000 f_adds(LOOP, 2.0, 3.0, 4.0) f_chain(LOOP, 2.0, 3.0, 4.0) f_simple_add(LOOP, 2.0, 3.0) f_long_chain(LOOP, 2.0, 3.0, 4.0, 5.0) # --- Op annotation --- def annotate_op(name, oparg, func): """Return a human-readable annotation for a uop.""" varnames = func.__code__.co_varnames consts = func.__code__.co_consts # _LOAD_FAST_BORROW_3 → local index 3 for prefix in ("_LOAD_FAST_BORROW_", "_LOAD_FAST_", "_SWAP_FAST_"): if name.startswith(prefix): idx = int(name[len(prefix):]) local = varnames[idx] if idx < len(varnames) else f"local{idx}" return local # _LOAD_CONST_INLINE_BORROW etc — operand is a pointer, not useful # but if oparg is a small index into consts, show it if "LOAD_CONST" in name and oparg < len(consts): return repr(consts[oparg]) # Binary ops if "MULTIPLY" in name: return "*" if "SUBTRACT" in name: return "-" if "ADD" in name and "UNICODE" not in name: return "+" # Guards if name == "_GUARD_TOS_FLOAT": return "top is float?" if name == "_GUARD_NOS_FLOAT": return "2nd is float?" if name == "_GUARD_TOS_INT": return "top is int?" if name == "_GUARD_NOS_INT": return "2nd is int?" if "NOT_EXHAUSTED" in name: return "iter not done?" # Pop / cleanup if name == "_POP_TOP_NOP": return "skip (borrowed/null)" if name == "_POP_TOP_FLOAT": return "decref float" if name == "_POP_TOP_INT": return "decref int" # Control flow if name == "_JUMP_TO_TOP": return "loop" if name == "_EXIT_TRACE": return "exit" if name == "_DEOPT": return "deoptimize" if name == "_ERROR_POP_N": return "error handler" if name == "_START_EXECUTOR": return "trace entry" if name == "_MAKE_WARM": return "warmup counter" return "" # --- Show traces --- FILTER_KEYWORDS = ( "FLOAT", "INPLACE", "BINARY_OP", "NOP", "LOAD_FAST", "LOAD_CONST", "GUARD", ) has_get_executor = False if tier2: try: from _opcode import get_executor has_get_executor = True except ImportError: pass if has_get_executor: mode = "all ops" if SHOW_ALL else "float-related ops only" print("-" * 60) print(f"Tier 2 traces ({mode})") print("-" * 60) for label, func in [ ("f_adds: total = a + b + c", f_adds), ("f_chain: total += a * b + c", f_chain), ("f_simple_add: total += a + b", f_simple_add), ("f_long_chain: total += a * b + c * d", f_long_chain), ]: code = func.__code__ found = False for i in range(len(code.co_code) // 2): try: ex = get_executor(code, i * 2) except (ValueError, TypeError, RuntimeError): continue if ex is None: continue print(f"\n {label}") for j, op in enumerate(ex): name, oparg = op[0], op[1] if not SHOW_ALL: if not any(k in name for k in FILTER_KEYWORDS): continue annotation = annotate_op(name, oparg, func) marker = " <<<" if "INPLACE" in name else "" if annotation: print(f" {j:3d}: {name:45s} # {annotation}{marker}") else: print(f" {j:3d}: {name}{marker}") found = True break if not found: print(f"\n {label}: (no executor found)") print() else: print("-" * 60) print("Tier 2 traces: skipped (tier 2 not available)") print("-" * 60) print() # --- Benchmark --- print("-" * 60) print("Benchmark") print("-" * 60) N = 2_000_000 INNER = 1000 benchmarks = [ ("total = a + b + c", lambda: f_adds(INNER, 2.0, 3.0, 4.0)), ("total += a*b + c ", lambda: f_chain(INNER, 2.0, 3.0, 4.0)), ("total += a + b ", lambda: f_simple_add(INNER, 2.0, 3.0)), ("total += a*b + c*d", lambda: f_long_chain(INNER, 2.0, 3.0, 4.0, 5.0)), ("total = - (a + b) ", lambda: f_negate(INNER, 2.0, 3.0)), ] for label, fn in benchmarks: iters = N // INNER t = timeit.timeit(fn, number=iters) ns_per = t / N * 1e9 print(f" {label}: {t:.3f}s ({ns_per:.0f} ns/iter)") print() print("The 'a*b + c' case benefits from _BINARY_OP_ADD_FLOAT_INPLACE:") print("the result of a*b is uniquely referenced, so the addition") print("mutates it in place instead of allocating a new float.") # --- N-body benchmark from pyperformance --- print() print("-" * 60) print("N-body benchmark (from pyperformance)") print("-" * 60) PI = 3.14159265358979323 SOLAR_MASS = 4 * PI * PI DAYS_PER_YEAR = 365.24 def _nbody_make_system(): bodies = [ # sun ([0.0, 0.0, 0.0], [0.0, 0.0, 0.0], SOLAR_MASS), # jupiter ([4.84143144246472090e+00, -1.16032004402742839e+00, -1.03622044471123109e-01], [1.66007664274403694e-03*DAYS_PER_YEAR, 7.69901118419740425e-03*DAYS_PER_YEAR, -6.90460016972063023e-05*DAYS_PER_YEAR], 9.54791938424326609e-04*SOLAR_MASS), # saturn ([8.34336671824457987e+00, 4.12479856412430479e+00, -4.03523417114321381e-01], [-2.76742510726862411e-03*DAYS_PER_YEAR, 4.99852801234917238e-03*DAYS_PER_YEAR, 2.30417297573763929e-05*DAYS_PER_YEAR], 2.85885980666130812e-04*SOLAR_MASS), # uranus ([1.28943695621391310e+01, -1.51111514016986312e+01, -2.23307578892655734e-01], [2.96460137564761618e-03*DAYS_PER_YEAR, 2.37847173959480950e-03*DAYS_PER_YEAR, -2.96589568540237556e-05*DAYS_PER_YEAR], 4.36624404335156298e-05*SOLAR_MASS), # neptune ([1.53796971148509165e+01, -2.59193146099879641e+01, 1.79258772950371181e-01], [2.68067772490389322e-03*DAYS_PER_YEAR, 1.62824170038242295e-03*DAYS_PER_YEAR, -9.51592254519715870e-05*DAYS_PER_YEAR], 5.15138902046611451e-05*SOLAR_MASS), ] pairs = [] for x in range(len(bodies) - 1): for y in bodies[x + 1:]: pairs.append((bodies[x], y)) return bodies, pairs def _nbody_advance(dt, n, bodies, pairs): for i in range(n): for (([x1, y1, z1], v1, m1), ([x2, y2, z2], v2, m2)) in pairs: dx = x1 - x2 dy = y1 - y2 dz = z1 - z2 mag = dt * ((dx * dx + dy * dy + dz * dz) ** (-1.5)) b1m = m1 * mag b2m = m2 * mag v1[0] -= dx * b2m v1[1] -= dy * b2m v1[2] -= dz * b2m v2[0] += dx * b1m v2[1] += dy * b1m v2[2] += dz * b1m for (r, [vx, vy, vz], m) in bodies: r[0] += dt * vx r[1] += dt * vy r[2] += dt * vz def _nbody_report_energy(bodies, pairs, e=0.0): for (((x1, y1, z1), v1, m1), ((x2, y2, z2), v2, m2)) in pairs: dx = x1 - x2 dy = y1 - y2 dz = z1 - z2 e -= (m1 * m2) / ((dx * dx + dy * dy + dz * dz) ** 0.5) for (r, [vx, vy, vz], m) in bodies: e += m * (vx * vx + vy * vy + vz * vz) / 2. return e def _nbody_offset_momentum(ref, bodies, px=0.0, py=0.0, pz=0.0): for (r, [vx, vy, vz], m) in bodies: px -= vx * m py -= vy * m pz -= vz * m (r, v, m) = ref v[0] = px / m v[1] = py / m v[2] = pz / m def bench_nbody(iterations=20000): bodies, pairs = _nbody_make_system() _nbody_offset_momentum(bodies[0], bodies) _nbody_report_energy(bodies, pairs) _nbody_advance(0.01, iterations, bodies, pairs) _nbody_report_energy(bodies, pairs) # Warmup bench_nbody(1000) NBODY_RUNS = 5 t = timeit.timeit(lambda: bench_nbody(20000), number=NBODY_RUNS) print(f" nbody (20k iterations, {NBODY_RUNS} runs): {t/NBODY_RUNS*1000:.1f} ms/run") Issue: gh-146306

Open Graph Description: We can add the following tier 2 micro-ops that mutate the uniquely-referenced operand: _BINARY_OP_ADD_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _BINARY_OP_SUBTRACT_FLOAT_INPLACE / _INPLACE...

X Description: We can add the following tier 2 micro-ops that mutate the uniquely-referenced operand: _BINARY_OP_ADD_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _BINARY_OP_SUBTRACT_FLOAT_INPLACE / _INPLACE...

Opengraph URL: https://github.com/python/cpython/pull/146307

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:26ffc28d-d7b5-a0b1-7062-f4535439eff0
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idE0F4:29D4D2:681D9:8AF74:6A517CA9
html-safe-nonce8ff9cb9a592f5a82ce12f4a37582f98ce746414426ca0af041455922cadff57d
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMEY0OjI5RDREMjo2ODFEOTo4QUY3NDo2QTUxN0NBOSIsInZpc2l0b3JfaWQiOiIxNTcxMDE1MzUxMjIyNzYyNjY1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac6995f403987cb22bc13ea66127538963e6fc25ee093fce99cfca467af612fbe6
hovercard-subject-tagpull_request:3431242947
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/python/cpython/pull/146307/files
twitter:imagehttps://avatars.githubusercontent.com/u/883786?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/883786?s=400&v=4
og:image:altWe can add the following tier 2 micro-ops that mutate the uniquely-referenced operand: _BINARY_OP_ADD_FLOAT_INPLACE / _INPLACE_RIGHT — unique LHS / RHS _BINARY_OP_SUBTRACT_FLOAT_INPLACE / _INPLACE...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noneb9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasee2c3fb1e56564ee0a4805542460de1eb8bd6bd77
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/pull/146307/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F146307%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F146307%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/pull/146307/files
Reloadhttps://github.com/python/cpython/pull/146307/files
Reloadhttps://github.com/python/cpython/pull/146307/files
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
Notifications https://github.com/login?return_to=%2Fpython%2Fcpython
Fork 35k https://github.com/login?return_to=%2Fpython%2Fcpython
Star 73.7k https://github.com/login?return_to=%2Fpython%2Fcpython
Code https://github.com/python/cpython
Issues 5k+ https://github.com/python/cpython/issues
Pull requests 2.3k https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality 0 https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
Code https://github.com/python/cpython
Issues https://github.com/python/cpython/issues
Pull requests https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose
Fidget-Spinnerhttps://github.com/Fidget-Spinner
python:mainhttps://github.com/python/cpython/tree/main
eendebakpt:jit_float_inplace_rebasedhttps://github.com/eendebakpt/cpython/tree/jit_float_inplace_rebased
Conversation 17 https://github.com/python/cpython/pull/146307
Commits 12 https://github.com/python/cpython/pull/146307/commits
Checks 87 https://github.com/python/cpython/pull/146307/checks
Files changed https://github.com/python/cpython/pull/146307/files
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
gh-146306: Optimize float operations by mutating uniquely-referenced operands in place (JIT only) https://github.com/python/cpython/pull/146307/files#top
Show all changes 12 commits https://github.com/python/cpython/pull/146307/files
42d12b7 gh-146306: Optimize float arithmetic in JIT by mutating uniquely-refe… eendebakpt Mar 22, 2026 https://github.com/python/cpython/pull/146307/commits/42d12b75c0cdf7fd169be7ffbbd355bee3ec6978
637803c Fix JIT stencil compilation on i686-pc-windows-msvc eendebakpt Mar 22, 2026 https://github.com/python/cpython/pull/146307/commits/637803c885f332a0fd34606c254f05cefe230c3a
8559fb8 Fix i686 Windows JIT: use x87 FPU instead of SSE for stencils eendebakpt Mar 22, 2026 https://github.com/python/cpython/pull/146307/commits/8559fb8b057364cdb20790380ac871e5100c9e12
7bfdedb Update Python/bytecodes.c eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/7bfdedb48413725c3109bf30b3802fa8978c1313
c8f860f Use sym_new_null for consumed operand slots in inplace float ops eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/c8f860f521a0e9392a97c0d03cacb7c5135e8857
fbedeb3 Revert unrelated bytecodes.c comment/whitespace changes eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/fbedeb31d526f2ed7cca50e4cfbaf14a4557dcfb
1efd764 Merge branch 'main' into jit_float_inplace_rebased eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/1efd764424c610330d2ecd1c382da13f433c6f45
78c11e1 regenerate eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/78c11e146a06527957a690a97c6b29a6ec9c882d
8af7b51 handle case there operand is set to null eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/8af7b51460288fbaf96253cf5eca28588041a9df
7d63316 reduce duplication in new opcodes eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/7d633168e98e8c5d6b18f67122c387754424d963
c61b9af review comments eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/c61b9af925fe00033f09e92bdff1d68b816e506a
4ff36c1 cleanup unary opcode eendebakpt Mar 24, 2026 https://github.com/python/cpython/pull/146307/commits/4ff36c1a08a55c7676caca2f70ebd3a45a00d920
Clear filters https://github.com/python/cpython/pull/146307/files
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
pycore_uop_ids.h https://github.com/python/cpython/pull/146307/files#diff-2a420e4d0d58009249c0f73f7c822167b053bd51cb213b20179bd2aebfc66ff9
pycore_uop_metadata.h https://github.com/python/cpython/pull/146307/files#diff-55e65a72fa31e9b746e03076d2c74b716c0c1171663f36960b2339fcbfae9bab
test_opt.py https://github.com/python/cpython/pull/146307/files#diff-67b5bd915e37f77df79907865982648172c27d3b96fbb072b30a73c6a2735439
2026-03-22-12-00-00.gh-issue-146306.870ef4.rst https://github.com/python/cpython/pull/146307/files#diff-a69009dc5c5a086ec69bbc555f5536d56716ff74a4e3f3ad1404db74b283d166
bytecodes.c https://github.com/python/cpython/pull/146307/files#diff-729a985b0cb8b431cb291f1edb561bbbfea22e3f8c262451cd83328a0936a342
ceval_macros.h https://github.com/python/cpython/pull/146307/files#diff-45baf725df91ed7826458cda8a17c2b4a2e5296504de1ed6a1c5a9ebe6390a47
executor_cases.c.h https://github.com/python/cpython/pull/146307/files#diff-a1c3430c42a66c16e6d2e154491a6da993b187b27c628545a12a02c7b2a06b81
optimizer_bytecodes.c https://github.com/python/cpython/pull/146307/files#diff-e5bd2b14b0b10f0f47786e26306d689ed1361c3dc3b11dcc3ea52b8a2422ff64
optimizer_cases.c.h https://github.com/python/cpython/pull/146307/files#diff-ed4567b3e67709ec57bf4df91ef058cfcbe00d7da11cd2a75e38241fa1ca99d2
_targets.py https://github.com/python/cpython/pull/146307/files#diff-700c6057d24addce74e8787edb5f5556f718299f6ef1742cbb1d79580cdb535c
Include/internal/pycore_uop_ids.hhttps://github.com/python/cpython/pull/146307/files#diff-2a420e4d0d58009249c0f73f7c822167b053bd51cb213b20179bd2aebfc66ff9
View file https://github.com/eendebakpt/cpython/blob/4ff36c1a08a55c7676caca2f70ebd3a45a00d920/Include/internal/pycore_uop_ids.h
Open in desktop https://desktop.github.com
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
Include/internal/pycore_uop_metadata.hhttps://github.com/python/cpython/pull/146307/files#diff-55e65a72fa31e9b746e03076d2c74b716c0c1171663f36960b2339fcbfae9bab
View file https://github.com/eendebakpt/cpython/blob/4ff36c1a08a55c7676caca2f70ebd3a45a00d920/Include/internal/pycore_uop_metadata.h
Open in desktop https://desktop.github.com
how customized files appear on GitHubhttps://docs.github.com/github/administering-a-repository/customizing-how-changed-files-appear-on-github
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
Lib/test/test_capi/test_opt.pyhttps://github.com/python/cpython/pull/146307/files#diff-67b5bd915e37f77df79907865982648172c27d3b96fbb072b30a73c6a2735439
View file https://github.com/eendebakpt/cpython/blob/4ff36c1a08a55c7676caca2f70ebd3a45a00d920/Lib/test/test_capi/test_opt.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python/cpython/pull/146307/{{ revealButtonHref }}
https://github.com/python/cpython/pull/146307/files#diff-67b5bd915e37f77df79907865982648172c27d3b96fbb072b30a73c6a2735439
https://github.com/python/cpython/pull/146307/files#diff-67b5bd915e37f77df79907865982648172c27d3b96fbb072b30a73c6a2735439
Misc/NEWS.d/next/Core_and_Builtins/2026-03-22-12-00-00.gh-issue-146306.870ef4.rsthttps://github.com/python/cpython/pull/146307/files#diff-a69009dc5c5a086ec69bbc555f5536d56716ff74a4e3f3ad1404db74b283d166
View file https://github.com/eendebakpt/cpython/blob/4ff36c1a08a55c7676caca2f70ebd3a45a00d920/Misc/NEWS.d/next/Core_and_Builtins/2026-03-22-12-00-00.gh-issue-146306.870ef4.rst
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python/cpython/pull/146307/{{ revealButtonHref }}
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
Please reload this pagehttps://github.com/python/cpython/pull/146307/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.