Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
sagemath
GitHub Repository: sagemath/sagelib
Path: blob/master/sage/ext/multi_modular.h
4045 views
1
#define mod_int uint_fast64_t
2
3
/* This is the largest value we can do arithmetic on without risking overflowing.
4
* It will be optimized to a constant if any optimization is turned on.
5
* The expression below assumes unsigned.
6
*/
7
#define MOD_INT_MAX ((1 << (sizeof(mod_int)*4)) - 1)
8
#define MOD_INT_OVERFLOW ((1 << (sizeof(mod_int)*8)) - 1)
9
10
/* Don't want to be up against the limit so
11
* we have room to gather.
12
*/
13
#define START_PRIME_MAX (MOD_INT_MAX/7)
14
15
#define LINBOX_PRIME_MAX ((1<< 50)-1)
16
17