//
// BN_reciprocal from 0x8712d8 to 0x871354 (124 bytes)
//
// 2 xrefs:
// > BN_div_recp @ 0x871420
// > ??> @ 0x69e2c
//
// 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
//
int __fastcall BN_reciprocal(int **a1, int *a2, int a3, int ***a4)
{
int *v8; // r0
int *v9; // r7
BN_CTX_start((int)a4);
v8 = (int *)BN_CTX_get(a4);
v9 = v8;
if ( !v8 || !BN_set_bit(v8, a3) || !BN_div(a1, 0, v9, a2, a4) )
a3 = -1;
BN_CTX_end(a4);
return a3;
}