//
// BN_GF2m_mod_solve_quad from 0xe76afc to 0xe76bd4 (216 bytes)
//
// 1 xrefs:
// > ??> @ 0x9fa98
//
// 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 BN_GF2m_mod_solve_quad(unsigned __int64 *a1, __int64 a2, __int64 a3, int32x2_t *a4)
{
int v8; // w21
int *v9; // x19
int v10; // w0
unsigned int v11; // w20
v8 = BN_num_bits(a3) + 1;
v9 = (int *)CRYPTO_malloc((void *)(4LL * v8), (__int64)"crypto/bn/bn_gf2m.c", 1153);
if ( v9 )
{
v10 = BN_GF2m_poly2arr(a3, (__int64)v9, v8);
v11 = v10;
if ( v10 <= v8 && v10 )
v11 = BN_GF2m_mod_solve_quad_arr(a1, a2, v9, a4);
else
ERR_put_error(3, 134, 106, (__int64)"crypto/bn/bn_gf2m.c", 1157);
}
else
{
v11 = 0;
}
CRYPTO_free(v9, (__int64)"crypto/bn/bn_gf2m.c", 1163);
return v11;
}