forked from wolfSSL/wolfssl
Support for mp_dump
with SP Math ALL.
This commit is contained in:
@@ -156,7 +156,7 @@ extern "C" {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* Detemine the number of bits to use in each word. */
|
/* Determine the number of bits to use in each word. */
|
||||||
#ifdef SP_WORD_SIZE
|
#ifdef SP_WORD_SIZE
|
||||||
#elif defined(WOLFSSL_DSP_BUILD)
|
#elif defined(WOLFSSL_DSP_BUILD)
|
||||||
#define SP_WORD_SIZE 32
|
#define SP_WORD_SIZE 32
|
||||||
@@ -510,7 +510,7 @@ typedef struct sp_ecc_ctx {
|
|||||||
#define sp_print_digit(a, s)
|
#define sp_print_digit(a, s)
|
||||||
#define sp_print_int(a, s)
|
#define sp_print_int(a, s)
|
||||||
|
|
||||||
#endif
|
#endif /* !NO_FILESYSTEM */
|
||||||
|
|
||||||
/* Returns whether multi-precision number is odd
|
/* Returns whether multi-precision number is odd
|
||||||
*
|
*
|
||||||
@@ -978,8 +978,16 @@ WOLFSSL_API word32 CheckRunTimeFastMath(void);
|
|||||||
#define mp_gcd sp_gcd
|
#define mp_gcd sp_gcd
|
||||||
#define mp_lcm sp_lcm
|
#define mp_lcm sp_lcm
|
||||||
|
|
||||||
|
#ifdef WOLFSSL_DEBUG_MATH
|
||||||
|
static inline void mp_dump(const char* desc, mp_int* a, byte verbose)
|
||||||
|
{
|
||||||
|
sp_print(a, desc);
|
||||||
|
(void)verbose;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif /* WOLFSSL_SP_MATH || WOLFSSL_SP_MATH_ALL */
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user