//
// SongInfoObject::addTags from 0x57558c to 0x575658 (204 bytes)
//
// 1 xrefs:
// > MusicDownloadManager::parseMusicLibrary @ 0x578f20
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:52:41 +0000
//
int __fastcall SongInfoObject::addTags(int result, unsigned __int8 *a2)
{
int v2; // r8
int v4; // r3
int v5; // r3
_BOOL4 v6; // r6
unsigned int i; // r5
int v8; // r0
const char *v9; // r0
int v10; // [sp+0h] [bp-28h] BYREF
_BYTE v11[8]; // [sp+4h] [bp-24h] BYREF
int v12[3]; // [sp+Ch] [bp-1Ch] BYREF
int v13; // [sp+18h] [bp-10h] BYREF
int v14; // [sp+1Ch] [bp-Ch]
int v15; // [sp+20h] [bp-8h]
v2 = result;
v4 = *a2;
if ( (v4 & 1) != 0 )
v5 = *((_DWORD *)a2 + 1);
else
v5 = v4 >> 1;
if ( v5 )
{
memset(v12, 0, sizeof(v12));
std::string::__init(v12, ".", 1u);
v6 = sub_56B0BE(a2, (unsigned __int8 *)v12);
result = std::string::~string((int)v12);
if ( !v6 )
{
v13 = 0;
v14 = 0;
v15 = 0;
sub_56DAB4(a2, ".", &v13);
for ( i = 0; i < -1431655765 * ((v14 - v13) >> 2); ++i )
{
v8 = v13 + 12 * i;
if ( (*(_BYTE *)v8 & 1) != 0 )
v9 = *(const char **)(v8 + 8);
else
v9 = (const char *)(v8 + 1);
v10 = atoi(v9);
if ( v10 > 0 )
std::__tree::__emplace_unique_key_args((int)v11, v2 + 436, &v10, &v10);
}
return std::__vector_base::~__vector_base((int)&v13);
}
}
return result;
}