Changeset 25831 in vbox for trunk/src/VBox/Runtime/r3
- Timestamp:
- Jan 14, 2010 3:12:53 PM (15 years ago)
- Location:
- trunk/src/VBox/Runtime/r3
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r3/linux/semevent-linux.cpp
r25724 r25831 137 137 pThis->fSignalled = 0; 138 138 #ifdef RTSEMEVENT_STRICT 139 va_list va; 140 va_start(va, pszNameFmt); 141 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 142 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 143 pszNameFmt, va); 144 va_end(va); 139 if (!pszNameFmt) 140 { 141 static uint32_t volatile s_iSemEventAnon = 0; 142 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 143 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 144 "RTSemEvent-%u", ASMAtomicIncU32(&s_iSemEventAnon) - 1); 145 } 146 else 147 { 148 va_list va; 149 va_start(va, pszNameFmt); 150 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 151 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 152 pszNameFmt, va); 153 va_end(va); 154 } 145 155 pThis->fEverHadSignallers = false; 146 156 #endif -
trunk/src/VBox/Runtime/r3/linux/semeventmulti-linux.cpp
r25724 r25831 139 139 pThis->iState = 0; 140 140 #ifdef RTSEMEVENTMULTI_STRICT 141 va_list va; 142 va_start(va, pszNameFmt); 143 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 144 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 145 pszNameFmt, va); 146 va_end(va); 141 if (!pszNameFmt) 142 { 143 static uint32_t volatile s_iSemEventMultiAnon = 0; 144 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 145 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 146 "RTSemEventMulti-%u", ASMAtomicIncU32(&s_iSemEventMultiAnon) - 1); 147 } 148 else 149 { 150 va_list va; 151 va_start(va, pszNameFmt); 152 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 153 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 154 pszNameFmt, va); 155 va_end(va); 156 } 147 157 pThis->fEverHadSignallers = false; 148 158 #endif -
trunk/src/VBox/Runtime/r3/linux/semmutex-linux.cpp
r25724 r25831 126 126 pThis->cNestings = 0; 127 127 #ifdef RTSEMMUTEX_STRICT 128 va_list va; 129 va_start(va, pszNameFmt); 130 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 131 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 132 va_end(va); 128 if (!pszNameFmt) 129 { 130 static uint32_t volatile s_iMutexAnon = 0; 131 RTLockValidatorRecExclInit(&pThis->ValidatorRec, hClass, uSubClass, pThis, 132 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), 133 "RTSemMutex-%u", ASMAtomicIncU32(&s_iMutexAnon) - 1); 134 } 135 else 136 { 137 va_list va; 138 va_start(va, pszNameFmt); 139 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 140 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 141 va_end(va); 142 } 133 143 #endif 134 144 -
trunk/src/VBox/Runtime/r3/posix/semevent-posix.cpp
r25724 r25831 139 139 ASMAtomicXchgU32(&pThis->cWaiters, 0); 140 140 #ifdef RTSEMEVENT_STRICT 141 va_list va; 142 va_start(va, pszNameFmt); 143 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 144 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 145 pszNameFmt, va); 146 va_end(va); 141 if (!pszNameFmt) 142 { 143 static uint32_t volatile s_iSemEventAnon = 0; 144 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 145 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 146 "RTSemEvent-%u", ASMAtomicIncU32(&s_iSemEventAnon) - 1); 147 } 148 else 149 { 150 va_list va; 151 va_start(va, pszNameFmt); 152 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 153 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 154 pszNameFmt, va); 155 va_end(va); 156 } 147 157 pThis->fEverHadSignallers = false; 148 158 #endif -
trunk/src/VBox/Runtime/r3/posix/semeventmulti-posix.cpp
r25724 r25831 130 130 ASMAtomicXchgU32(&pThis->cWaiters, 0); 131 131 #ifdef RTSEMEVENTMULTI_STRICT 132 va_list va; 133 va_start(va, pszNameFmt); 134 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 135 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 136 pszNameFmt, va); 137 va_end(va); 132 if (!pszNameFmt) 133 { 134 static uint32_t volatile s_iSemEventMultiAnon = 0; 135 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 136 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 137 "RTSemEventMulti-%u", ASMAtomicIncU32(&s_iSemEventMultiAnon) - 1); 138 } 139 else 140 { 141 va_list va; 142 va_start(va, pszNameFmt); 143 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 144 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 145 pszNameFmt, va); 146 va_end(va); 147 } 138 148 pThis->fEverHadSignallers = false; 139 149 #endif -
trunk/src/VBox/Runtime/r3/posix/semmutex-posix.cpp
r25724 r25831 106 106 pThis->u32Magic = RTSEMMUTEX_MAGIC; 107 107 #ifdef RTSEMMUTEX_STRICT 108 va_list va; 109 va_start(va, pszNameFmt); 110 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 111 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 112 va_end(va); 108 if (!pszNameFmt) 109 { 110 static uint32_t volatile s_iMutexAnon = 0; 111 RTLockValidatorRecExclInit(&pThis->ValidatorRec, hClass, uSubClass, pThis, 112 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), 113 "RTSemMutex-%u", ASMAtomicIncU32(&s_iMutexAnon) - 1); 114 } 115 else 116 { 117 va_list va; 118 va_start(va, pszNameFmt); 119 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 120 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 121 va_end(va); 122 } 113 123 #endif 114 124 -
trunk/src/VBox/Runtime/r3/posix/semrw-posix.cpp
r25723 r25831 130 130 #ifdef RTSEMRW_STRICT 131 131 bool const fLVEnabled = !(fFlags & RTSEMRW_FLAGS_NO_LOCK_VAL); 132 va_list va; 133 va_start(va, pszNameFmt); 134 RTLockValidatorRecExclInitV(&pThis->ValidatorWrite, hClass, uSubClass, pThis, fLVEnabled, pszNameFmt, va); 135 va_end(va); 136 va_start(va, pszNameFmt); 137 RTLockValidatorRecSharedInitV(&pThis->ValidatorRead, hClass, uSubClass, pThis, false /*fSignaller*/, 138 fLVEnabled, pszNameFmt, va); 139 va_end(va); 132 if (!pszNameFmt) 133 { 134 static uint32_t volatile s_iSemRWAnon = 0; 135 uint32_t i = ASMAtomicIncU32(&s_iSemRWAnon) - 1; 136 RTLockValidatorRecExclInit(&pThis->ValidatorWrite, hClass, uSubClass, pThis, 137 fLVEnabled, "RTSemRW-%u", i); 138 RTLockValidatorRecSharedInit(&pThis->ValidatorRead, hClass, uSubClass, pThis, 139 false /*fSignaller*/, fLVEnabled, "RTSemRW-%u", i); 140 } 141 else 142 { 143 va_list va; 144 va_start(va, pszNameFmt); 145 RTLockValidatorRecExclInitV(&pThis->ValidatorWrite, hClass, uSubClass, pThis, 146 fLVEnabled, pszNameFmt, va); 147 va_end(va); 148 va_start(va, pszNameFmt); 149 RTLockValidatorRecSharedInitV(&pThis->ValidatorRead, hClass, uSubClass, pThis, 150 false /*fSignaller*/, fLVEnabled, pszNameFmt, va); 151 va_end(va); 152 } 140 153 RTLockValidatorRecMakeSiblings(&pThis->ValidatorWrite.Core, &pThis->ValidatorRead.Core); 141 154 #endif -
trunk/src/VBox/Runtime/r3/win/semevent-win.cpp
r25724 r25831 91 91 pThis->u32Magic = RTSEMEVENT_MAGIC; 92 92 #ifdef RTSEMEVENT_STRICT 93 va_list va; 94 va_start(va, pszNameFmt); 95 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 96 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 97 pszNameFmt, va); 98 va_end(va); 93 if (!pszNameFmt) 94 { 95 static uint32_t volatile s_iSemEventAnon = 0; 96 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 97 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 98 "RTSemEvent-%u", ASMAtomicIncU32(&s_iSemEventAnon) - 1); 99 } 100 else 101 { 102 va_list va; 103 va_start(va, pszNameFmt); 104 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 105 true /*fSignaller*/, !(fFlags & RTSEMEVENT_FLAGS_NO_LOCK_VAL), 106 pszNameFmt, va); 107 va_end(va); 108 } 99 109 pThis->fEverHadSignallers = false; 100 110 #endif -
trunk/src/VBox/Runtime/r3/win/semeventmulti-win.cpp
r25724 r25831 95 95 pThis->u32Magic = RTSEMEVENTMULTI_MAGIC; 96 96 #ifdef RTSEMEVENT_STRICT 97 va_list va; 98 va_start(va, pszNameFmt); 99 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 100 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 101 pszNameFmt, va); 102 va_end(va); 97 if (!pszNameFmt) 98 { 99 static uint32_t volatile s_iSemEventMultiAnon = 0; 100 RTLockValidatorRecSharedInit(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 101 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 102 "RTSemEventMulti-%u", ASMAtomicIncU32(&s_iSemEventMultiAnon) - 1); 103 } 104 else 105 { 106 va_list va; 107 va_start(va, pszNameFmt); 108 RTLockValidatorRecSharedInitV(&pThis->Signallers, hClass, RTLOCKVAL_SUB_CLASS_ANY, pThis, 109 true /*fSignaller*/, !(fFlags & RTSEMEVENTMULTI_FLAGS_NO_LOCK_VAL), 110 pszNameFmt, va); 111 va_end(va); 112 } 103 113 pThis->fEverHadSignallers = false; 104 114 #endif -
trunk/src/VBox/Runtime/r3/win/semmutex-win.cpp
r25724 r25831 98 98 pThis->cRecursions = 0; 99 99 #ifdef RTSEMMUTEX_STRICT 100 va_list va; 101 va_start(va, pszNameFmt); 102 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 103 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 104 va_end(va); 100 if (!pszNameFmt) 101 { 102 static uint32_t volatile s_iMutexAnon = 0; 103 RTLockValidatorRecExclInit(&pThis->ValidatorRec, hClass, uSubClass, pThis, 104 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), 105 "RTSemMutex-%u", ASMAtomicIncU32(&s_iMutexAnon) - 1); 106 } 107 else 108 { 109 va_list va; 110 va_start(va, pszNameFmt); 111 RTLockValidatorRecExclInitV(&pThis->ValidatorRec, hClass, uSubClass, pThis, 112 !(fFlags & RTSEMMUTEX_FLAGS_NO_LOCK_VAL), pszNameFmt, va); 113 va_end(va); 114 } 105 115 #endif 106 116 *phMutexSem = pThis;
Note:
See TracChangeset
for help on using the changeset viewer.