libtommath/bn_cutoffs.c
Daniel Mendler 818d8fb7f5
Rework handling of tunable cutoffs
* In the default settings, a cutoff X can be modified at runtime
   by adjusting the corresponding X_CUTOFF variable.

 * Tunability of the library can be disabled at compile time
   by defining the MP_FIXED_CUTOFFS macro.

 * There is an additional file tommath_cutoffs.h, which defines
   the default cutoffs. These can be adjusted manually or by the
   autotuner.
2019-05-04 13:08:37 +02:00

15 lines
449 B
C

#include "tommath_private.h"
#ifdef BN_CUTOFFS_C
/* LibTomMath, multiple-precision integer library -- Tom St Denis */
/* SPDX-License-Identifier: Unlicense */
#ifndef MP_FIXED_CUTOFFS
#include "tommath_cutoffs.h"
int KARATSUBA_MUL_CUTOFF = MP_DEFAULT_KARATSUBA_MUL_CUTOFF,
KARATSUBA_SQR_CUTOFF = MP_DEFAULT_KARATSUBA_SQR_CUTOFF,
TOOM_MUL_CUTOFF = MP_DEFAULT_TOOM_MUL_CUTOFF,
TOOM_SQR_CUTOFF = MP_DEFAULT_TOOM_SQR_CUTOFF;
#endif
#endif