You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
RalfJung opened this issue
Sep 29, 2024
· 1 comment
Labels
A-atomicArea: Atomics, barriers, and sync primitivesO-macosOperating system: macOST-libsRelevant to the library team, which will review and decide on the PR/issue.
This was brought up over here: our current macOS implementation for Mutex and Condvar use heap allocations. That's unfortunate because it can lead to OOM, and also seems like a slight efficiency hit.
Heap allocations are required because we are using the pthread API on macOS, and pthread Mutexes are not movable. AFAIK, @joboet has been working on alternative implementations that avoid the pthread API (#122408). The alternative, suggested by @daira , is to get Apple to guarantee that their pthread mutexes are movable under certain conditions. Given the black box that Apple is, I have no idea if that's even remotely realistic. But anyway it seems worth tracking this somewhere so here we go. :)
The text was updated successfully, but these errors were encountered:
Noratrieb
added
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
and removed
needs-triage
This issue may need triage. Remove it if it has been sufficiently triaged.
labels
Nov 9, 2024
A-atomicArea: Atomics, barriers, and sync primitivesO-macosOperating system: macOST-libsRelevant to the library team, which will review and decide on the PR/issue.
This was brought up over here: our current macOS implementation for
Mutex
andCondvar
use heap allocations. That's unfortunate because it can lead to OOM, and also seems like a slight efficiency hit.Heap allocations are required because we are using the pthread API on macOS, and pthread Mutexes are not movable. AFAIK, @joboet has been working on alternative implementations that avoid the pthread API (#122408). The alternative, suggested by @daira , is to get Apple to guarantee that their pthread mutexes are movable under certain conditions. Given the black box that Apple is, I have no idea if that's even remotely realistic. But anyway it seems worth tracking this somewhere so here we go. :)
The text was updated successfully, but these errors were encountered: