Lines Matching refs:divisor
111 * other words divisor has to be "bit-aligned to the left." bn_div_fixed_top
202 * BN_div computes dv := num / divisor, rounding towards
203 * zero, and sets up rm such that dv*divisor + rm = num holds.
205 * dv->neg == num->neg ^ divisor->neg (unless the result is zero)
209 int BN_div(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num, const BIGNUM *divisor,
214 if (BN_is_zero(divisor)) {
224 if (divisor->d[divisor->top - 1] == 0) {
229 ret = bn_div_fixed_top(dv, rm, num, divisor, ctx);
242 * It's argued that *length* of *significant* part of divisor is public.
246 * of limb length. Thanks to this assumption we can require that |divisor|
253 * as divisor, also zero-padded if needed. These actually leave sign bits
260 * - dividend is at least as "wide" as divisor, limb-wise, zero-padded
262 * divisor's length is considered public;
265 const BIGNUM *divisor, BN_CTX *ctx)
273 assert(divisor->top > 0 && divisor->d[divisor->top - 1] != 0);
276 bn_check_top(divisor);
289 if (!BN_copy(sdiv, divisor))
297 * doesn't need to compare dividend and divisor if they were originally
330 res->neg = (num_neg ^ divisor->neg);
445 /* snum holds remainder, it's as wide as divisor */