Lines Matching refs:B
270 mbedtls_mpi_uint *B = NULL;
283 TEST_EQUAL(mbedtls_test_read_mpi_core(&B, &limbs_B, input_B), 0);
299 mbedtls_mpi_mod_raw_sub(X, A, B, &m);
304 mbedtls_mpi_mod_raw_sub(X, X, B, &m);
307 /* alias X to B */
308 memcpy(X, B, bytes);
312 /* A == B: alias A and B */
313 if (memcmp(A, B, bytes) == 0) {
317 /* X, A, B all aliased together */
324 mbedtls_free(B);
389 mbedtls_mpi_uint *B = NULL;
403 TEST_EQUAL(mbedtls_test_read_mpi_core(&B, &limbs_B, input_B), 0);
422 mbedtls_mpi_mod_raw_mul(X, A, B, &m, T);
427 mbedtls_mpi_mod_raw_mul(X, X, B, &m, T);
430 /* alias X to B */
431 memcpy(X, B, bytes);
435 /* A == B: alias A and B */
436 if (memcmp(A, B, bytes) == 0) {
440 /* X, A, B all aliased together */
445 /* A != B: test B * A */
447 mbedtls_mpi_mod_raw_mul(X, B, A, &m, T);
450 /* B * A: alias X to A */
452 mbedtls_mpi_mod_raw_mul(X, B, X, &m, T);
455 /* B + A: alias X to B */
456 memcpy(X, B, bytes);
463 mbedtls_free(B);
552 mbedtls_mpi_uint *B = NULL;
562 TEST_EQUAL(0, mbedtls_test_read_mpi_core(&B, &B_limbs, input_B));
579 /* A + B => Correct result */
580 mbedtls_mpi_mod_raw_add(X, A, B, &m);
583 /* A + B: alias X to A => Correct result */
585 mbedtls_mpi_mod_raw_add(X, X, B, &m);
588 /* A + B: alias X to B => Correct result */
589 memcpy(X, B, bytes);
593 if (memcmp(A, B, bytes) == 0) {
594 /* A == B: alias A and B */
600 /* A + A: X, A, B all aliased together => Correct result */
605 /* A != B: test B + A */
607 /* B + A => Correct result */
608 mbedtls_mpi_mod_raw_add(X, B, A, &m);
611 /* B + A: alias X to A => Correct result */
613 mbedtls_mpi_mod_raw_add(X, B, X, &m);
616 /* B + A: alias X to B => Correct result */
617 memcpy(X, B, bytes);
626 mbedtls_free(B);