This reimplements the spinlock on top of std::atomic_flag, which is guaranteed to be lockless. It also inserts the PAUSE (REP NOP) instruction which is strongly recommended to be placed in busy-wait loops by Intel. This also includes a recursive spinlock implementation. The spinlock implementation is disabled by default, but can be enabled by adding the --override MUTEX_SPINLOCK=1 flag to makepanda. |
||
|---|---|---|
| .. | ||
| metalibs | ||
| src | ||
| PandaVersion.pp | ||