//
// sub_1005FF0D8 from 0x1005ff0d8 to 0x1005ff120 (72 bytes)
//
// 0 xrefs:
//
// 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 11:09:56 +0000
//
__int64 __fastcall sub_1005FF0D8(unsigned int a1, unsigned int a2)
{
unsigned int v2; // w8
unsigned int v3; // w9
char v4; // w10
unsigned int v5; // w9
unsigned int v6; // w10
v2 = 0;
if ( (a1 & 1) == 0 )
{
v3 = a1;
do
{
v4 = v3;
++v2;
v3 >>= 1;
}
while ( (v4 & 2) == 0 );
}
if ( v2 >= 0xF )
v2 = 15;
do
{
v5 = v2 - 1;
if ( !v2 )
break;
v6 = a1 >> v2--;
}
while ( v6 <= a2 );
return v5 + 1;
}