//
// sub_F7FBC from 0xf7fbc to 0xf8044 (136 bytes)
//
// 2 xrefs:
// > sub_F4718 @ 0xf496c
// > sub_F8044 @ 0xf8184
//
// 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 12:15:08 +0000
//
unsigned int __fastcall sub_F7FBC(int *a1)
{
int v1; // w19
int v2; // w20
float v3; // s0
unsigned int result; // w0
int v5; // w10
int v6; // w9
int v7; // w12
int v9; // w9
v2 = *a1;
v1 = a1[1];
v3 = pow((float)v1, (float)(1.0 / (float)*a1));
for ( result = vcvtms_s32_f32(v3); ; result += v9 )
{
v5 = 0;
v6 = 1;
v7 = 1;
while ( v5 < v2 )
{
v6 *= result;
v7 *= result + 1;
++v5;
}
if ( v6 <= v1 && v7 > v1 )
break;
if ( v6 > v1 )
v9 = -1;
else
v9 = 1;
}
return result;
}