MCPcopy Create free account
hub / github.com/devkitPro/libctru / __strex

Function __strex

libctru/include/3ds/synchronization.h:75–80  ·  view source on GitHub ↗

* @brief Performs a strex operation. * @param addr Address to perform the operation on. * @param val Value to store. * @return Whether the operation was successful. */

Source from the content-addressed store, hash-verified

73 * @return Whether the operation was successful.
74 */
75static inline bool __strex(s32* addr, s32 val)
76{
77 bool res;
78 __asm__ __volatile__("strex %[res], %[val], %[addr]" : [res] "=&r" (res) : [val] "r" (val), [addr] "Q" (*addr));
79 return res;
80}
81
82/**
83 * @brief Performs a ldrexh operation.

Callers 15

LightLock_InitFunction · 0.85
LightLock_LockFunction · 0.85
LightLock_TryLockFunction · 0.85
LightLock_UnlockFunction · 0.85
CondVar_BeginWaitFunction · 0.85
CondVar_EndWaitFunction · 0.85
LightEvent_SetStateFunction · 0.85
LightEvent_TryResetFunction · 0.85
LightSemaphore_AcquireFunction · 0.85
LightSemaphore_ReleaseFunction · 0.85
gspInitFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected