FreeBSD: implement support for pthread synchronization primitives #3571
Labels
A-concurrency
Area: affects our concurrency (multi-thread) support
A-freebsd
Area: affects our FreeBSD target support
A-shims
Area: This affects the external function shims
C-enhancement
Category: a PR with an enhancement or an issue tracking an accepted enhancement
We currently don't support the pthread synchronization primitives on FreeBSD. And it turns out that supporting them will require some refactoring of how we implement those primitives: on FreeBSD,
pthread_mutex_t
et al are just a pointer to the actual data. That means on a 32bit system they are only 4 bytes large, which is not large enough for us to store the data we need to store directly in thepthread_mutex_t
.So we should move that data out of machine memory into dedicated machine state, which also has the advantage of making it more tamper-resistant. Once that's done, implementing FreeBSD support should be fairly easy.
The text was updated successfully, but these errors were encountered: