//
// std::__ndk1::__sp_mut::lock from 0xf79a1c to 0xf79a6c (80 bytes)
//
// 1 xrefs:
// > ??> @ 0xd4c20
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 13:13:44 +0000
//
__int64 __fastcall std::__sp_mut::lock(std::mutex **this)
{
std::mutex *v1; // x19
int v2; // w20
__int64 result; // x0
v1 = *this;
v2 = 0;
while ( 1 )
{
result = std::mutex::try_lock(v1);
if ( (result & 1) != 0 )
break;
if ( (unsigned int)++v2 >= 0x11 )
return std::mutex::lock(v1);
sched_yield();
}
return result;
}