Title: expose platform-specific `PRIO_DARWIN_*` constants for core type selection on macOS in `os` module. · Issue #103545 · python/cpython · GitHub
Open Graph Title: expose platform-specific `PRIO_DARWIN_*` constants for core type selection on macOS in `os` module. · Issue #103545 · python/cpython
X Title: expose platform-specific `PRIO_DARWIN_*` constants for core type selection on macOS in `os` module. · Issue #103545 · python/cpython
Description: Feature or enhancement As described in this stack overflow answer, the way to select "efficiency" vs. "performance" cores on Apple Silicon macOS machines is to use setpriority. However, you need to use custom platform-specific constants ...
Open Graph Description: Feature or enhancement As described in this stack overflow answer, the way to select "efficiency" vs. "performance" cores on Apple Silicon macOS machines is to use setpriority. However, you need to...
X Description: Feature or enhancement As described in this stack overflow answer, the way to select "efficiency" vs. "performance" cores on Apple Silicon macOS machines is to use setpriority. ...
Opengraph URL: https://github.com/python/cpython/issues/103545
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"expose platform-specific `PRIO_DARWIN_*` constants for core type selection on macOS in `os` module.","articleBody":"# Feature or enhancement\r\n\r\nAs described in [this stack overflow answer](https://apple.stackexchange.com/a/443735/26977), the way to select \"efficiency\" vs. \"performance\" cores on Apple Silicon macOS machines is to use `setpriority`. However, you need to use custom platform-specific constants to do this, specifically, `PRIO_DARWIN_BG`, and either `PRIO_DARWIN_THREAD` or `PRIO_DARWIN_PROCESS`.\r\n\r\n# Pitch\r\n\r\nIt's just a few integer constants and it would expose a pretty important bit of power-efficiency/performance-tuning functionality for Python.\r\n\r\n# Previous discussion\r\n\r\nNo previous discussion anywhere, this seems like a fairly minor addition. This platform-specific functionality seems consistent with the way these functions are already treated, given that `os.PRIO_*` are already \"Unix, not Emscripten, not WASI\".\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-104606\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/glyph","@type":"Person","name":"glyph"},"datePublished":"2023-04-14T16:52:14.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/103545/cpython/issues/103545"}
| 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:c1901296-5b4a-93c3-6bbc-94e5c86fdc15 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | ACE4:30B952:D68A1D:126FDD9:6969F1E1 |
| html-safe-nonce | 9c042ebfa1bc81d66d012699b6c55a6af296b08cb0eb58dc02cf5c324766cd8b |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQ0U0OjMwQjk1MjpENjhBMUQ6MTI2RkREOTo2OTY5RjFFMSIsInZpc2l0b3JfaWQiOiIxNTcwNzEyNzQ5Mjg2NzQ4NjQxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 9ffa9ee90775851916e614813f238e967607e3cdb964a94853dc5fbc8d1fe383 |
| hovercard-subject-tag | issue:1668590537 |
| 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/103545/issue_layout |
| twitter:image | https://opengraph.githubassets.com/a03a37da6f663c359859990dd951c1164036d423e9823c045e27e7480a7d546c/python/cpython/issues/103545 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/a03a37da6f663c359859990dd951c1164036d423e9823c045e27e7480a7d546c/python/cpython/issues/103545 |
| og:image:alt | Feature or enhancement As described in this stack overflow answer, the way to select "efficiency" vs. "performance" cores on Apple Silicon macOS machines is to use setpriority. However, you need to... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | glyph |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7b32f1c7c4549428ee399213e8345494fc55b5637195d3fc5f493657579235e8 |
| 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 | bdde15ad1b403e23b08bbd89b53fbe6bdf688cad |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width