Lines Matching refs:ciL

67 #define ciL    (sizeof(mbedtls_mpi_uint))         /* chars in limb  */  macro
68 #define biL (ciL << 3) /* bits in limb */
69 #define biH (ciL << 2) /* half limb size */
78 #define CHARS_TO_LIMBS(i) ( (i) / ciL + ( (i) % ciL != 0 ) )
85 mbedtls_platform_zeroize( v, ciL * n ); in mbedtls_mpi_zeroize()
148 p = mempool_alloc( mbedtls_mpi_mempool, nblimbs * ciL ); in mbedtls_mpi_grow()
151 memset( p, 0, nblimbs * ciL ); in mbedtls_mpi_grow()
155 p = (mbedtls_mpi_uint*)mbedtls_calloc( nblimbs, ciL ); in mbedtls_mpi_grow()
162 memcpy( p, X->p, X->n * ciL ); in mbedtls_mpi_grow()
205 p = mempool_alloc( mbedtls_mpi_mempool, i * ciL ); in mbedtls_mpi_shrink()
208 memset( p, 0, i * ciL ); in mbedtls_mpi_shrink()
212 p = (mbedtls_mpi_uint*)mbedtls_calloc( i, ciL ); in mbedtls_mpi_shrink()
219 memcpy( p, X->p, i * ciL ); in mbedtls_mpi_shrink()
243 memset( X->p, 0, limbs * ciL ); in mbedtls_mpi_resize_clear()
278 memset( X->p, 0, X->n * ciL ); in mbedtls_mpi_copy()
296 memset( X->p + i, 0, ( X->n - i ) * ciL ); in mbedtls_mpi_copy()
299 memcpy( X->p, Y->p, i * ciL ); in mbedtls_mpi_copy()
329 memset( X->p, 0, X->n * ciL ); in mbedtls_mpi_lset()
354 ( ( ( X )->p[( i ) / ciL] >> ( ( ( i ) % ciL ) * 8 ) ) & 0xff )
508 X->p[j / ( 2 * ciL )] |= d << ( ( j % ( 2 * ciL ) ) << 2 ); in mbedtls_mpi_read_string()
626 for( j = ciL; j > 0; j-- ) in mbedtls_mpi_write_string()
752 for( i = 0, x_ptr = (unsigned char*) &x; i < ciL; i++, x_ptr++ ) in mpi_uint_bigendian_to_host_c()
847 X->p[i / ciL] |= ((mbedtls_mpi_uint) buf[i]) << ((i % ciL) << 3); in mbedtls_mpi_read_binary_le()
866 size_t const overhead = ( limbs * ciL ) - buflen; in mbedtls_mpi_read_binary()
901 size_t stored_bytes = X->n * ciL; in mbedtls_mpi_write_binary_le()
948 stored_bytes = X->n * ciL; in mbedtls_mpi_write_binary()
1280 memcpy( X->p + n, A->p + n, ( A->n - n ) * ciL ); in mbedtls_mpi_sub_abs()
1282 memset( X->p + A->n, 0, ( X->n - A->n ) * ciL ); in mbedtls_mpi_sub_abs()
1969 memset( T->p, 0, T->n * ciL ); in mpi_montmul()
1995 memcpy( A->p, d, n * ciL ); in mpi_montmul()
2445 const size_t overhead = ( limbs * ciL ) - n_bytes; in mpi_fill_random_internal()
2451 memset( (unsigned char *) X->p + limbs * ciL, 0, ( X->n - limbs ) * ciL ); in mpi_fill_random_internal()
2756 MBEDTLS_MPI_CHK( mbedtls_mpi_fill_random( &A, X->n * ciL, f_rng, p_rng ) ); in mpi_miller_rabin()
2926 MBEDTLS_MPI_CHK( mbedtls_mpi_fill_random( X, n * ciL, f_rng, p_rng ) ); in mbedtls_mpi_gen_prime()