Lines Matching refs:DIGIT_BIT
314 W[ix + 1] += W[ix] >> ((mp_word) DIGIT_BIT);
334 *_W++ += *_W1++ >> ((mp_word) DIGIT_BIT);
460 _W = _W >> ((mp_word)DIGIT_BIT);
561 _W = _W >> ((mp_word)DIGIT_BIT);
681 W1 = _W >> ((mp_word)DIGIT_BIT);
743 if ((res = mp_grow (a, b / DIGIT_BIT + 1)) != MP_OKAY) {
748 a->used = b / DIGIT_BIT + 1;
751 a->dp[b / DIGIT_BIT] = ((mp_digit)1) << (b % DIGIT_BIT);
934 mu = *tmpc >> DIGIT_BIT;
940 mu = *tmpc >> DIGIT_BIT;
1413 x *= DIGIT_BIT;
1537 r = (a->used - 1) * DIGIT_BIT;
1706 /* normalize both x and y, ensure that y >= b/2, [b == 2**DIGIT_BIT] */
1707 norm = mp_count_bits(&y) % DIGIT_BIT;
1708 if (norm < (int)(DIGIT_BIT-1)) {
1709 norm = (DIGIT_BIT-1) - norm;
1748 q.dp[i - t - 1] = ((((mp_digit)1) << DIGIT_BIT) - 1);
1751 tmp = ((mp_word) x.dp[i]) << ((mp_word) DIGIT_BIT);
1899 *tmpb-- = (*tmpa-- >> 1) | (r << (DIGIT_BIT - 1));
1977 if (b >= (int)DIGIT_BIT) {
1978 mp_rshd (c, b / DIGIT_BIT);
1981 /* shift any bit count < DIGIT_BIT */
1982 D = (mp_digit) (b % DIGIT_BIT);
1990 shift = DIGIT_BIT - D;
2051 /* b = 2**DIGIT_BIT / 3 */
2052 b = (((mp_word)1) << ((mp_word)DIGIT_BIT)) / ((mp_word)3);
2062 w = (w << ((mp_word)DIGIT_BIT)) | ((mp_word)a->dp[ix]);
2066 t = (w * ((mp_word)b)) >> ((mp_word)DIGIT_BIT);
2129 for (x = 1; x < DIGIT_BIT; x++) {
2189 w = (w << ((mp_word)DIGIT_BIT)) | ((mp_word)a->dp[ix]);
2335 mu = (mp_digit)(r >> ((mp_word)DIGIT_BIT));
2387 /* the casts are required if DIGIT_BIT is one less than
2388 * the number of bits in a mp_digit [e.g. DIGIT_BIT==31]
2390 *d = (mp_digit)((((mp_word)1) << ((mp_word)DIGIT_BIT)) -
2471 for (x = 0; x < (int) DIGIT_BIT; x++) {
2479 if ((b & (mp_digit) (((mp_digit)1) << (DIGIT_BIT - 1))) != 0) {
2717 P->used < (1 << ((CHAR_BIT * sizeof (mp_word)) - (2 * DIGIT_BIT)))) {
2827 bitcnt = (int)DIGIT_BIT;
2831 y = (mp_digit)(buf >> (DIGIT_BIT - 1)) & 1;
3293 i = MIN(a->used,(int)((sizeof(unsigned long)*CHAR_BIT+DIGIT_BIT-1)/DIGIT_BIT))-1;
3299 res = (res << DIGIT_BIT) | DIGIT(a,i);
3932 /* First check mod 128 (suppose that DIGIT_BIT is at least 7) */
4115 * Let B represent the radix [e.g. 2**DIGIT_BIT] and
4608 if (b >= (int) (a->used * DIGIT_BIT)) {
4619 for (x = (b / DIGIT_BIT) + ((b % DIGIT_BIT) == 0 ? 0 : 1); x < c->used; x++) {
4623 c->dp[b / DIGIT_BIT] &=
4624 (mp_digit) ((((mp_digit) 1) << (((mp_digit) b) % DIGIT_BIT)) - ((mp_digit) 1));
4696 bits = mp_count_bits (b) % DIGIT_BIT;
4699 if ((res = mp_2expt (a, (b->used - 1) * DIGIT_BIT + bits - 1)) != MP_OKAY) {
4709 for (x = bits - 1; x < (int)DIGIT_BIT; x++) {
4764 (1 << ((CHAR_BIT * sizeof (mp_word)) - (2 * DIGIT_BIT)))) {
4809 u = (mp_digit)(r >> ((mp_word) DIGIT_BIT));
4820 u = *tmpx >> DIGIT_BIT;
4903 *rho = (unsigned long)(((mp_word)1 << ((mp_word) DIGIT_BIT)) - x) & MP_MASK;
4963 (1 << ((CHAR_BIT * sizeof (mp_word)) - (2 * DIGIT_BIT)))) {
5034 rr = *tmpa >> ((mp_digit)(DIGIT_BIT - 1));
5102 if (c->alloc < (int)(c->used + b/DIGIT_BIT + 1)) {
5103 if ((res = mp_grow (c, c->used + b / DIGIT_BIT + 1)) != MP_OKAY) {
5109 if (b >= (int)DIGIT_BIT) {
5110 if ((res = mp_lshd (c, b / DIGIT_BIT)) != MP_OKAY) {
5115 /* shift any bit count < DIGIT_BIT */
5116 d = (mp_digit) (b % DIGIT_BIT);
5125 shift = DIGIT_BIT - d;
5217 u = (mp_digit) (r >> ((mp_word) DIGIT_BIT));
5967 } while (y == 1 && step < ((((mp_digit)1)<<DIGIT_BIT) - kstep));
5975 if (y == 1 && step >= ((((mp_digit)1)<<DIGIT_BIT) - kstep)) {
6592 if (((unsigned long) um) > (((mp_digit)1) << (DIGIT_BIT - 1))) {
6617 if ((res = mp_mod_2d (x, DIGIT_BIT * (um + 1), x)) != MP_OKAY) {
6924 for (ix = DIGIT_BIT; ix < iy; ix++) {
7019 if ((res = mp_2expt (a, b->used * 2 * DIGIT_BIT)) != MP_OKAY) {
7304 (1 << (sizeof(mp_word) * CHAR_BIT - 2*DIGIT_BIT - 1))) {
7861 DIGIT_BIT * B, &a0)) != MP_OKAY) {
7869 mp_mod_2d(&a1, DIGIT_BIT * B, &a1);
7877 if ((res = mp_mod_2d(b, DIGIT_BIT * B, &b0)) != MP_OKAY) {
7885 mp_mod_2d(&b1, DIGIT_BIT * B, &b1);
8142 if ((res = mp_mod_2d(a, DIGIT_BIT * B, &a0)) != MP_OKAY) {
8150 mp_mod_2d(&a1, DIGIT_BIT * B, &a1);
8815 u = *tmpc >> ((mp_digit)DIGIT_BIT);
8830 u = *tmpc >> ((mp_digit)DIGIT_BIT);
9012 bitcnt = (int) DIGIT_BIT;
9016 y = (buf >> (mp_digit)(DIGIT_BIT - 1)) & 1;
9146 (1 << ((CHAR_BIT * sizeof (mp_word)) - (2 * DIGIT_BIT)))) {
9185 u = (mp_digit) (r >> ((mp_word) DIGIT_BIT));
9240 && MIN (a->used, b->used) < (1 << ((CHAR_BIT * sizeof (mp_word)) - (2 * DIGIT_BIT)))) {
9275 u = (mp_digit) (r >> ((mp_word) DIGIT_BIT));
9336 u = (mp_digit)(r >> ((mp_word) DIGIT_BIT));
9357 u = (mp_digit)(r >> ((mp_word) DIGIT_BIT));
9363 u = (mp_digit)(r >> ((mp_word) DIGIT_BIT));