//
// __common_scos_cout_rare from 0x180123ec0 to 0x180123f30 (112 bytes)
//
// 4 xrefs:
// > _sse2_cosf4 @ 0x1801220e9
// > _sse4_cosf4 @ 0x180122a44
// > ??> @ 0x180202624
// > ??> @ 0x180202630
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall _common_scos_cout_rare(__int64 a1, float *a2)
{
__int64 result; // rax
float v3; // xmm0_4
float v4; // [rsp+20h] [rbp-8h]
v4 = *(float *)a1;
if ( (*(_WORD *)(a1 + 2) & 0x7F80) != 0x7F80 )
return 0;
HIBYTE(v4) = HIBYTE(*(_DWORD *)a1) & 0x7F;
if ( v4 == INFINITY )
{
result = 1;
v3 = *(float *)a1 * 0.0;
}
else
{
result = 0;
v3 = *(float *)a1 * *(float *)a1;
}
*a2 = v3;
return result;
}