//
// sub_FB4DC from 0xfb4dc to 0xfb568 (140 bytes)
//
// 2 xrefs:
// > sub_FB164 @ 0xfb3e4
// > sub_FBA90 @ 0xfbc4c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall sub_FB4DC(signed int a1, int a2)
{
int i; // w11
int v5; // w12
int v6; // w10
__int64 result; // x0
__int64 v8; // x11
__int64 v9; // x13
__int64 v10; // x12
int v12; // w10
for ( i = a1 >> ((int)((sub_FB148(a1) - 1) * (a2 - 1)) / a2); ; i = v12 + result )
{
v5 = i + 1;
v6 = 0;
result = i;
v8 = 1;
v9 = v5;
v10 = 1;
while ( v6 < a2 )
{
v8 *= result;
v10 *= v9;
++v6;
}
if ( v8 <= a1 && v10 > a1 )
break;
if ( v8 > a1 )
v12 = -1;
else
v12 = 1;
}
return result;
}