//
// SongInfoObject::getArtistNames from 0x96da40 to 0x96df88 (1352 bytes)
//
// 2 xrefs:
// > SongInfoLayer::create @ 0x906528
// > ??> @ 0xb86d8
//
// 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:57:39 +0000
//
__int64 *__usercall SongInfoObject::getArtistNames@(__int64 *__return_ptr a1@, SongInfoObject *this@)
{
char *v2; // x2
__int64 v5; // x0
__int64 v6; // x1
unsigned __int8 v7; // w1
__int64 v8; // x2
__int64 *i; // x20
MusicDownloadManager *v10; // x0
__int64 *MusicArtistForID; // x0
const void *v12; // x1
size_t v13; // x2
int v14; // w2
int v15; // w3
__int64 v16; // x1
char *v17; // x1
size_t v18; // x2
void **v19; // x19
void **v20; // x20
void **v21; // x0
void *v22; // x0
unsigned __int64 v24; // x9
unsigned __int64 v25; // x7
__int64 *v26; // x0
unsigned __int64 v27; // x2
unsigned __int64 v28; // x2
__int64 *v29; // x0
const void *v30; // x1
size_t v31; // x2
_BYTE *v32; // x28
__int64 v33; // x20
unsigned __int64 v34; // x22
size_t v35; // x5
const char *v36; // x0
int v37; // w0
char *v38; // x2
__int64 *v39; // x0
void *v40; // x0
_BYTE *v41; // x1
int v42; // [xsp+6Ch] [xbp+6Ch] BYREF
void *v43; // [xsp+70h] [xbp+70h] BYREF
_BYTE *v44; // [xsp+78h] [xbp+78h]
__int64 v45; // [xsp+80h] [xbp+80h]
__int64 v46; // [xsp+88h] [xbp+88h] BYREF
size_t v47; // [xsp+90h] [xbp+90h]
void *v48; // [xsp+98h] [xbp+98h]
void *v49; // [xsp+A0h] [xbp+A0h] BYREF
unsigned __int64 v50; // [xsp+A8h] [xbp+A8h]
void *v51; // [xsp+B0h] [xbp+B0h]
__int64 v52; // [xsp+B8h] [xbp+B8h]
float v53; // [xsp+C0h] [xbp+C0h]
__int64 v54; // [xsp+C8h] [xbp+C8h]
v2 = (char *)this + 344;
a1[1] = 0;
v5 = _stack_chk_guard;
a1[2] = 0;
*a1 = 0;
v54 = v5;
if ( (*((_BYTE *)this + 344) & 1) != 0 )
{
std::string::__init(a1, *((void **)v2 + 2), *((_QWORD *)v2 + 1));
}
else
{
v6 = *((_QWORD *)v2 + 1);
*a1 = *(_QWORD *)v2;
a1[1] = v6;
a1[2] = *((_QWORD *)v2 + 2);
}
if ( *((_QWORD *)this + 64) )
{
v7 = *((_BYTE *)this + 464);
v49 = nullptr;
v50 = 0;
v8 = v7 >> 1;
v51 = nullptr;
v52 = 0;
v53 = 1.0;
if ( (v7 & 1) != 0 )
v8 = *((_QWORD *)this + 59);
if ( v8 )
{
v43 = nullptr;
v44 = nullptr;
v45 = 0;
sub_961B60((unsigned __int8 *)this + 464, &byte_1169BE0, (__int64 *)&v43);
v32 = v43;
if ( 0xAAAAAAAAAAAAAAABLL * ((v44 - (_BYTE *)v43) >> 3) > 1 )
{
v33 = 0;
v34 = 0;
do
{
v36 = &v32[v33 + 1];
if ( (v32[v33] & 1) != 0 )
v36 = *(const char **)&v32[v33 + 16];
v37 = atoi(v36);
v46 = 0;
v42 = v37;
v47 = 0;
v38 = &v32[v33 + 24];
v48 = nullptr;
if ( (*v38 & 1) != 0 )
{
std::string::__init(&v46, *((void **)v38 + 2), *((_QWORD *)v38 + 1));
v37 = v42;
}
else
{
v35 = *((_QWORD *)v38 + 1);
v46 = *(_QWORD *)v38;
v47 = v35;
v48 = *((void **)v38 + 2);
}
if ( v37 != 10004636 && v37 > 0 )
{
v39 = (__int64 *)std::unordered_map::operator[]((__int64)&v49, &v42);
if ( v39 != &v46 )
{
if ( (v46 & 1) != 0 )
std::string::assign(v39, v48, v47);
else
std::string::assign(v39, (char *)&v46 + 1, (unsigned __int8)v46 >> 1);
}
}
if ( (v46 & 1) != 0 )
operator delete(v48);
v32 = v43;
v34 += 2LL;
v33 += 48;
}
while ( v34 < 0xAAAAAAAAAAAAAAABLL * ((v44 - (_BYTE *)v43) >> 3) );
}
v40 = v32;
if ( v32 )
{
v41 = v44;
if ( v44 != v32 )
{
do
{
v44 = v41 - 24;
std::string::~string((__int64)(v41 - 24));
v41 = v44;
}
while ( v44 != v32 );
v40 = v43;
}
operator delete(v40);
}
}
for ( i = *((__int64 **)this + 63); i; i = (__int64 *)*i )
{
LODWORD(v43) = *((_DWORD *)i + 4);
if ( (_DWORD)v43 == (unsigned int)&loc_98A89C )
continue;
v46 = 0;
v47 = 0;
v48 = nullptr;
v10 = (MusicDownloadManager *)MusicDownloadManager::sharedState((MusicDownloadManager *)&loc_98A89C);
MusicArtistForID = (__int64 *)MusicDownloadManager::getMusicArtistForID(v10, (int)v43);
if ( MusicArtistForID && &v46 != MusicArtistForID + 8 )
{
if ( (MusicArtistForID[8] & 1) != 0 )
{
v12 = (const void *)MusicArtistForID[10];
v13 = MusicArtistForID[9];
}
else
{
v12 = (char *)MusicArtistForID + 65;
v13 = *((_BYTE *)MusicArtistForID + 64) >> 1;
}
std::string::assign(&v46, v12, v13);
}
if ( (v46 & 1) != 0 )
{
if ( v47 )
{
LOBYTE(v14) = v46;
goto LABEL_17;
}
}
else
{
v14 = (unsigned __int8)v46;
if ( (int)(unsigned __int8)v46 >> 1 )
goto LABEL_37;
}
if ( v50 )
{
v24 = v50 - 1;
v25 = ((v50 - 1) & v50) != 0 ? (int)v43 % v50 : v24 & (int)v43;
v26 = *((__int64 **)v49 + v25);
if ( v26 )
{
while ( 1 )
{
v26 = (__int64 *)*v26;
if ( !v26 )
break;
v27 = v26[1];
v28 = ((v50 - 1) & v50) != 0 ? v27 % v50 : v24 & v27;
if ( v25 != v28 )
break;
if ( (_DWORD)v43 == *((_DWORD *)v26 + 4) )
{
v29 = (__int64 *)std::unordered_map::operator[]((__int64)&v49, (int *)&v43);
if ( v29 != &v46 )
{
if ( (*(_BYTE *)v29 & 1) != 0 )
{
v30 = (const void *)v29[2];
v31 = v29[1];
}
else
{
v30 = (char *)v29 + 1;
v31 = *(_BYTE *)v29 >> 1;
}
std::string::assign(&v46, v30, v31);
}
v14 = (unsigned __int8)v46;
if ( (v46 & 1) == 0 )
goto LABEL_37;
goto LABEL_17;
}
}
}
}
v14 = (unsigned __int8)v46;
if ( (v46 & 1) == 0 )
{
LABEL_37:
if ( !(v14 >> 1) )
continue;
v15 = 0;
goto LABEL_19;
}
LABEL_17:
if ( !v47 )
goto LABEL_35;
v15 = 1;
LABEL_19:
v16 = *(_BYTE *)a1 >> 1;
if ( (*(_BYTE *)a1 & 1) != 0 )
v16 = a1[1];
if ( v16 )
{
std::string::append((__int64)a1, ", ", 2u);
LOBYTE(v14) = v46;
if ( (v46 & 1) != 0 )
{
LABEL_23:
v17 = (char *)v48;
v18 = v47;
goto LABEL_24;
}
}
else if ( v15 )
{
goto LABEL_23;
}
v18 = (unsigned __int8)v14 >> 1;
v17 = (char *)&v46 + 1;
LABEL_24:
std::string::append((__int64)a1, v17, v18);
if ( (v46 & 1) != 0 )
LABEL_35:
operator delete(v48);
}
v19 = (void **)v51;
if ( v51 )
{
do
{
v20 = (void **)*v19;
if ( ((_BYTE)v19[3] & 1) != 0 )
operator delete(v19[5]);
v21 = v19;
v19 = v20;
operator delete(v21);
}
while ( v20 );
}
v22 = v49;
v49 = nullptr;
if ( v22 )
operator delete(v22);
}
return a1;
}