pw_sync_baremetal#
Pigweed AI summary: The "pw_sync_baremetal" is a set of backends for pw_sync that is still under construction and not ready for use. It does not support hardware multi-threading and does not perform interrupt masking or disable global interrupts, making it unsafe to use. The implementation includes InterruptSpinLock, Mutex, and RecursiveMutex, with the latter not available for general use in Pigweed.
This is a set of backends for pw_sync that works on baremetal targets. It is not ready for use, and is under construction.
Note
All constructs in this baremetal backend do not support hardware multi-threading (SMP, SMT, etc).
Warning
It does not perform interrupt masking or disable global interrupts. This is not safe to use yet!
InterruptSpinLock#
Pigweed AI summary: The InterruptSpinLock implementation tries to acquire a lock and will assert if it is unavailable, but it does not perform interrupt masking or disable global interrupts.
The interrupt spin-lock implementation makes a single attempt to acquire the lock and asserts if it is unavailable. It does not perform interrupt masking or disable global interrupts.
Mutex#
Pigweed AI summary: The mutex implementation attempts to acquire the lock only once and will assert if it is unavailable.
The mutex implementation makes a single attempt to acquire the lock and asserts if it is unavailable.
RecursiveMutex#
Pigweed AI summary: The RecursiveMutex implementation keeps track of the number of lock and unlock calls and will assert if the mutex is unlocked too many times or destroyed while still locked. However, it is important to note that recursive mutexes are not available for general use in Pigweed.
The recursive mutex implementation counts the number of lock and unlock calls and asserts if the mutex is unlocked too many times or destroyed while locked. Note that recursive mutexes are not available for general use in Pigweed.