Warning: This file is not a C or C++ file. It does not have highlighting.
| 1 | //===-- Definition of a common mutex type ---------------------------------===// |
|---|---|
| 2 | // |
| 3 | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| 4 | // See https://llvm.org/LICENSE.txt for license information. |
| 5 | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
| 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | |
| 9 | #ifndef LLVM_LIBC_TYPES___MUTEX_TYPE_H |
| 10 | #define LLVM_LIBC_TYPES___MUTEX_TYPE_H |
| 11 | |
| 12 | #include "__futex_word.h" |
| 13 | |
| 14 | typedef struct { |
| 15 | unsigned char __timed; |
| 16 | unsigned char __recursive; |
| 17 | unsigned char __robust; |
| 18 | |
| 19 | void *__owner; |
| 20 | unsigned long long __lock_count; |
| 21 | |
| 22 | #ifdef __linux__ |
| 23 | __futex_word __ftxw; |
| 24 | #else |
| 25 | #error "Mutex type not defined for the target platform." |
| 26 | #endif |
| 27 | } __mutex_type; |
| 28 | |
| 29 | #endif // LLVM_LIBC_TYPES___MUTEX_TYPE_H |
| 30 |
Warning: This file is not a C or C++ file. It does not have highlighting.
