//
// std::__ndk1::vector>::__push_back_slow_path from 0x5a2c40 to 0x5a2cc8 (136 bytes)
//
// 2 xrefs:
// > GJBaseGameLayer::activateSongTrigger @ 0x5a2d38
// > GJBaseGameLayer::activateSongEditTrigger @ 0x5a51d0
//
// 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:53:18 +0000
//
void __fastcall std::vector::__push_back_slow_path(
_DWORD *a1,
_DWORD *a2)
{
int v4; // r2
unsigned int v5; // r1
int v6; // r3
unsigned int v7; // r0
unsigned int v8; // r0
void *v9[2]; // [sp+0h] [bp-1Ch] BYREF
char *v10; // [sp+8h] [bp-14h]
v4 = (a1[1] - *a1) >> 2;
v5 = v4 + 1;
v6 = (int)(a1 + 2);
if ( (unsigned int)(v4 + 1) >= 0x40000000 )
sub_388B48();
v7 = (a1[2] - *a1) >> 2;
if ( v7 > 0x1FFFFFFE )
{
v5 = 0x3FFFFFFF;
}
else
{
v8 = 2 * v7;
if ( v5 < v8 )
v5 = v8;
}
std::__split_buffer::__split_buffer(v9, v5, v4, v6);
if ( v10 )
*(_DWORD *)v10 = *a2;
v10 += 4;
std::vector::__swap_out_circular_buffer((int)a1, v9);
v10 -= 4 * ((unsigned int)(v10 - (char *)v9[1]) >> 2);
if ( v9[0] )
operator delete(v9[0]);
}