//
// bn_mul_low_recursive from 0x9ebe58 to 0x9ebf6c (276 bytes)
//
// 3 xrefs:
// > bn_mul_low_recursive @ 0x9ebf20
// > bn_mul_low_recursive @ 0x9ebf4c
// > ??> @ 0x7993c
//
// 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 12:07:27 +0000
//
int __fastcall bn_mul_low_recursive(int a1, _DWORD *a2, _DWORD *a3, int a4, int a5)
{
int v5; // r4
int v10; // r0
int v11; // r1
int v12; // r2
int v13; // r5
int v14; // r6
v5 = a4 / 2;
bn_mul_recursive(a1, a2, a3, a4 / 2, 0, 0, a5);
if ( v5 > 31 )
{
v13 = a5 + 4 * a4;
v14 = a1 + 4 * v5;
bn_mul_low_recursive(a5, a2, &a3[v5], v5, v13);
bn_add_words(v14, v14, a5, v5);
bn_mul_low_recursive(a5, &a2[v5], a3, v5, v13);
v10 = v14;
v11 = v14;
v12 = a5;
}
else
{
bn_mul_low_normal(a5, (int)a2, &a3[v5], v5);
bn_mul_low_normal(a5 + 4 * v5, (int)&a2[v5], a3, v5);
bn_add_words(a1 + 4 * v5, a1 + 4 * v5, a5, v5);
v10 = a1 + 4 * v5;
v11 = v10;
v12 = a5 + 4 * v5;
}
return bn_add_words(v10, v11, v12, v5);
}