//
// sub_D04B4 from 0xd04b4 to 0xd04ee (58 bytes)
//
// 5 xrefs:
// > sub_CFEB4 @ 0xcfff2
// > sub_CFEB4 @ 0xd01e4
// > sub_CFEB4 @ 0xd023c
// > sub_D0438 @ 0xd0448
// > sub_D054C @ 0xd0588
//
// 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:41:58 +0000
//
unsigned int __fastcall sub_D04B4(unsigned int a1)
{
unsigned int v1; // r0
unsigned int v2; // r0
unsigned int v3; // r0
v1 = bswap32(a1);
v2 = ((v1 >> 4) & 0xF0F0F0F) + ((16 * v1) & 0xF0F0F0F0);
v3 = ((v2 >> 2) & 0x33333333) + ((4 * v2) & 0xCCCCCCCC);
return ((v3 >> 1) & 0x55555555) + ((2 * v3) & 0xAAAAAAAA);
}