//
// sub_F8CCE0 from 0xf8cce0 to 0xf8cddc (252 bytes)
//
// 2 xrefs:
// > __cxa_demangle @ 0xf8c430
// > sub_F96E94 @ 0xf97108
//
// 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:57 +0000
//
void __fastcall sub_F8CCE0(__int64 a1)
{
__int64 v2; // x21
__int64 v3; // x22
char *v4; // x20
char *v5; // x8
unsigned __int64 v6; // x8
void *v7; // x0
unsigned __int64 v8; // x8
v2 = *(_QWORD *)(a1 + 8);
while ( 1 )
{
v3 = *(_QWORD *)(a1 + 16);
if ( v3 == v2 )
break;
*(_QWORD *)(a1 + 16) = v3 - 32;
v4 = *(char **)(v3 - 32);
if ( v4 )
{
v5 = *(char **)(v3 - 24);
if ( v5 != v4 )
{
do
{
*(_QWORD *)(v3 - 24) = v5 - 32;
sub_F8CC30((__int64)(v5 - 32));
v5 = *(char **)(v3 - 24);
}
while ( v5 != v4 );
v4 = *(char **)(v3 - 32);
}
v6 = *(_QWORD *)(v3 - 8);
if ( v6 > (unsigned __int64)v4 || v6 + 4096 < (unsigned __int64)v4 )
{
free(v4);
}
else if ( *(_QWORD *)(v3 - 16) == *(_QWORD *)(v6 + 4096) )
{
*(_QWORD *)(v6 + 4096) = v4;
}
}
}
v7 = *(void **)a1;
if ( *(_QWORD *)a1 )
{
v8 = **(_QWORD **)(a1 + 32);
if ( v8 > (unsigned __int64)v7 || v8 + 4096 < (unsigned __int64)v7 )
{
free(v7);
}
else if ( *(_QWORD *)(a1 + 24) == *(_QWORD *)(v8 + 4096) )
{
*(_QWORD *)(v8 + 4096) = v7;
}
}
}