WPILibC++  2020.3.2-60-g3011ebe
wpi::recursive_spinlock1 Class Reference

A recursive spinlock mutex. More...

#include <spinlock.h>

Public Member Functions

LLVM_ATTRIBUTE_ALWAYS_INLINE bool try_lock ()
 
LLVM_ATTRIBUTE_ALWAYS_INLINE void lock ()
 
LLVM_ATTRIBUTE_ALWAYS_INLINE void unlock ()
 

Detailed Description

A recursive spinlock mutex.

This version uses std::atomic_flag for spin, then checks the thread id for recursion. It is generally faster on desktop platforms compared to recursive_spinlock2.


The documentation for this class was generated from the following file: