Title: bpo-42246: Remove DO_NOT_EMIT_BYTECODE macros, so that while loops and if statements conform to PEP 626. by markshannon · Pull Request #23743 · python/cpython · GitHub
Open Graph Title: bpo-42246: Remove DO_NOT_EMIT_BYTECODE macros, so that while loops and if statements conform to PEP 626. by markshannon · Pull Request #23743 · python/cpython
X Title: bpo-42246: Remove DO_NOT_EMIT_BYTECODE macros, so that while loops and if statements conform to PEP 626. by markshannon · Pull Request #23743 · python/cpython
Description: PEP 626 requires all expressions and statements to be traced, even if the code is redundant. This PR does that for while and if statements. The performance impact on while 1: loops is minimized by copying the test to the end of the loop. while test: body used to compile to: start: if not test: goto end body goto start end: It now compiles to: if not test: goto end loop: body if test goto loop end: which will be a tiny bit slower for while 1 loops and a bit faster for other while loops. I'm skipping news, as this PR is part of PEP 626 and is covered by that. https://bugs.python.org/issue42246
Open Graph Description: PEP 626 requires all expressions and statements to be traced, even if the code is redundant. This PR does that for while and if statements. The performance impact on while 1: loops is minimized by ...
X Description: PEP 626 requires all expressions and statements to be traced, even if the code is redundant. This PR does that for while and if statements. The performance impact on while 1: loops is minimized by ...
Opengraph URL: https://github.com/python/cpython/pull/23743
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/checks(.:format) |
| route-controller | pull_requests |
| route-action | checks |
| fetch-nonce | v2:9fc5988c-cd0d-8006-6da3-7feda6cb0285 |
| current-catalog-service-hash | 87dc3bc62d9b466312751bfd5f889726f4f1337bdff4e8be7da7c93d6c00a25a |
| request-id | D9F2:39E51F:36D845:4793B4:696ADDB1 |
| html-safe-nonce | 7bd99aca108805f0becd500f9d8b0b13f64b7fd6b05622ac405a975069324adc |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOUYyOjM5RTUxRjozNkQ4NDU6NDc5M0I0OjY5NkFEREIxIiwidmlzaXRvcl9pZCI6IjIyMTY4Mzg3Njg3Nzk1MTczNjEiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 012f9d4fb9977f03b354121d92f429948e13484f83f8a6363cc6b2e3c20059e5 |
| hovercard-subject-tag | pull_request:536954679 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,checks,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/python/cpython/pull/23743/checks |
| twitter:image | https://avatars.githubusercontent.com/u/9448417?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/9448417?s=400&v=4 |
| og:image:alt | PEP 626 requires all expressions and statements to be traced, even if the code is redundant. This PR does that for while and if statements. The performance impact on while 1: loops is minimized by ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| 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 full-width full-width-p-0 |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 524a93f2c1f36522a3b4be4c110467ee4172245d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width