/* * @blocker: Combines lock address and blocking type. * * Since lock pointers are at least 4-byte aligned(32-bit) or 8-byte * aligned(64-bit). This leaves the 2 least bits (LSBs) of the pointer * always zero. So we can use these bits to encode the specific blocking * type. * * Note that on architectures where this is not guaranteed, or for any * unaligned lock, this tracking mechanism is silently skipped for that * lock. * * Type encoding: * 00 - Blocked on mutex (BLOCKER_TYPE_MUTEX) * 01 - Blocked on semaphore (BLOCKER_TYPE_SEM) * 10 - Blocked on rw-semaphore as READER (BLOCKER_TYPE_RWSEM_READER) * 11 - Blocked on rw-semaphore as WRITER (BLOCKER_TYPE_RWSEM_WRITER)
*/ #define BLOCKER_TYPE_MUTEX 0x00UL #define BLOCKER_TYPE_SEM 0x01UL #define BLOCKER_TYPE_RWSEM_READER 0x02UL #define BLOCKER_TYPE_RWSEM_WRITER 0x03UL
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.