//
// jpeg_fdct_2x2 from 0xe8ee8c to 0xe8ef2c (160 bytes)
//
// 3 xrefs:
// > ??> @ 0x7e328
// > sub_E6CE20 @ 0xe6d990
// > ??> @ 0x1543438
//
// 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 13:10:55 +0000
//
__int64 __fastcall jpeg_fdct_2x2(_DWORD *a1, _QWORD *a2, unsigned int a3)
{
unsigned __int8 *v6; // x3
int v7; // w0
int v8; // w2
int v9; // w4
int v10; // w1
int v11; // w0
int v12; // w4
int v13; // w4
__int64 result; // x0
memset(a1, 0, 0x100u);
v6 = (unsigned __int8 *)(a2[1] + a3);
v7 = *(unsigned __int8 *)(*a2 + a3);
v8 = *v6;
v9 = *(unsigned __int8 *)(*a2 + a3 + 1LL);
LODWORD(v6) = v6[1];
v10 = v7 + v9;
v11 = v7 - v9;
v12 = v8 + (_DWORD)v6;
LODWORD(v6) = v8 - (_DWORD)v6;
*a1 = 16 * (v10 + v12 - 512);
a1[8] = 16 * (v10 - v12);
v13 = 16 * (v11 + (_DWORD)v6);
result = (unsigned int)(16 * (v11 - (_DWORD)v6));
a1[1] = v13;
a1[9] = result;
return result;
}