Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | Spacing cleanup. | Torbjorn Granlund | 2011-11-21 | 1 | -1/+1 | |
| | ||||||
* | Add swap functions to gmpxx. | Marc Glisse | 2011-09-21 | 1 | -0/+10 | |
| | ||||||
* | __builtin_constant_p optimizations to turn x+0 into x, x*4 into x<<2, etc, ↵ | Marc Glisse | 2011-08-21 | 1 | -168/+301 | |
| | | | | | | all done in the C++ layer. Also rewrote the addition of rational and integer which always did a mpq_set first. | |||||
* | C++: automatically turn c=(a+b)/2 into c=a+b;c/=2, no need for a temporary. | Marc Glisse | 2011-05-15 | 1 | -8/+8 | |
| | ||||||
* | Remove an unneeded overload of << | Marc Glisse | 2011-05-15 | 1 | -9/+1 | |
| | ||||||
* | Test stream input/output on mp*_class and not just mp*_t. | Marc Glisse | 2011-05-10 | 1 | -3/+6 | |
| | | | | Simple optimization: c=-(a+b) becomes c=a+b;c=-c. | |||||
* | mp_bitcnt_t for [lr]shift. | Marc Glisse | 2011-05-08 | 1 | -12/+12 | |
| | ||||||
* | More mp_bitcnt_t. Probably still some left. | Marc Glisse | 2011-05-08 | 1 | -4/+4 | |
| | ||||||
* | More mp_bitcnt_t missed. | Marc Glisse | 2011-05-08 | 1 | -25/+25 | |
| | ||||||
* | Small gmpxx simplifications and optimizations. | Marc Glisse | 2011-05-07 | 1 | -98/+28 | |
| | ||||||
* | Make some conversions between C++ types explicit. | Marc Glisse | 2011-05-06 | 1 | -2/+11 | |
| | ||||||
* | Dedup the comparison code. | Marc Glisse | 2011-03-20 | 1 | -197/+3 | |
| | ||||||
* | Fix __gmp_set_expr declaration. | Marc Glisse | 2011-03-20 | 1 | -17/+0 | |
| | ||||||
* | Inline mpz_set_*i where it is safe | Marc Glisse | 2011-03-16 | 1 | -8/+27 | |
| | ||||||
* | Make __GMPZ_ULI_LIMBS more preprocessor-friendly. | Marc Glisse | 2011-03-15 | 1 | -1/+7 | |
| | ||||||
* | Store small temporary mpq on the stack. | Marc Glisse | 2011-03-15 | 1 | -56/+27 | |
| | ||||||
* | Put temp mpz_t from double on stack everywhere | Marc Glisse | 2011-03-12 | 1 | -101/+51 | |
| | ||||||
* | Remove leftover #undefs | Marc Glisse | 2011-03-12 | 1 | -6/+0 | |
| | ||||||
* | Change all bit counts for bignums to use mp_bitcnt_t. Update documentation. | Torbjorn Granlund | 2009-12-20 | 1 | -42/+42 | |
| | ||||||
* | (__GMP_DBL_LIMBS): Use DBL_MAX_EXP instead of | Torbjorn Granlund | 2008-09-08 | 1 | -76/+73 | |
| | | | | | | | | | | | | | | | | | std::numeric_limits<double>::max_exponent for better portability. (__GMP_DBL_LIMBS): New #define. (__GMP_ULI_LIMBS): New #define. (__GMPXX_TMP_UI): New macro. (__GMPXX_TMP_SI): New macro. (__GMPXX_TMP_D): New macro. (struct __gmp_binary_and): Rewrite, using the new macros. (struct __gmp_binary_ior): Likewise. (struct __gmp_binary_xor): Likewise. Use __GMPZ_* instead of __GMPZZ_* for bitwise ops, remove __GMPZZ_*. Remove repeated #undefs. (__gmp_alloc_cstring): Declare freefunc as extern "C". | |||||
* | * gmpxx.h (struct __gmp_binary_rshift): Use floor rounding, not truncation. | tege | 2008-02-27 | 1 | -1/+1 | |
| | ||||||
* | (__gmp_binary_and, __gmp_binary_ior, __gmp_binary_xor): | tege | 2008-02-27 | 1 | -0/+54 | |
| | | | | Add variants with unsigned long int argument. | |||||
* | Update license to version 3. | tege | 2007-09-18 | 1 | -4/+2 | |
| | ||||||
* | Remove ternary stuff, it is hardly an optimization and it | tege | 2006-11-04 | 1 | -497/+0 | |
| | | | | writes to destination before reading all source operands. | |||||
* | (__GMP_DEFINE_TERNARY_EXPR2): Remove for now. | tege | 2006-04-08 | 1 | -1354/+6 | |
| | | | | | | | | | | (struct __gmp_ternary_addmul2): Likewise. (struct __gmp_ternary_submul2): Likewise. #include <cstring>. (struct __gmp_alloc_cstring): Prefix strlen with std::. Remove mpfr code. | |||||
* | Update FSF's address. | tege | 2006-02-15 | 1 | -2/+2 | |
| | ||||||
* | * gmpxx.h (__gmp_binary_equal, __gmp_binary_not_equal, | Kevin Ryde | 2003-12-09 | 1 | -462/+28 | |
| | | | | | | __gmp_binary_less, __gmp_binary_less_equal, __gmp_binary_greater, __gmp_binary_greater_equal, __gmp_cmp_function): Use mpfr_cmp_si and mpfr_cmp_d. | |||||
* | * gmpxx.h (gmp_randclass gmp_randinit_lc_2exp_size constructor): Throw | Kevin Ryde | 2003-10-18 | 1 | -1/+4 | |
| | | | | std::length_error if size is too big. | |||||
* | * gmpxx.h (mpz_class, mpq_class, mpf_class, mpfr_class constructors | Kevin Ryde | 2003-10-18 | 1 | -26/+154 | |
| | | | | | and operator= taking string or char*): Throw std::invalid_argument if string cannot be converted. | |||||
* | * gmpxx.h [__MPFR_H]: Include full <iostream> for inlines. | Kevin Ryde | 2003-08-17 | 1 | -0/+6 | |
| | ||||||
* | * gmpxx.h: Correction to temp variable type in mpf -> mpfr assignment. | Kevin Ryde | 2003-08-17 | 1 | -1/+1 | |
| | | | | Reported by Derrick Bass. | |||||
* | (struct __gmp_hypot_function): Correction to mpfr_hypot addition. | Kevin Ryde | 2003-08-17 | 1 | -4/+4 | |
| | ||||||
* | * gmpxx.h: __gmp_default_rounding_mode -> __gmpfr_default_rounding_mode | Kevin Ryde | 2003-08-17 | 1 | -149/+149 | |
| | ||||||
* | * gmpxx.h (struct __gmp_binary_multiplies): Use mpz_mul_si for | Kevin Ryde | 2003-07-24 | 1 | -18/+2 | |
| | | | | mpz*long and long*mpz. | |||||
* | * gmpxx.h (struct __gmp_hypot_function): Use mpfr_hypot. | Kevin Ryde | 2003-07-24 | 1 | -45/+19 | |
| | ||||||
* | * gmpxx.h (mpz_class __gmp_binary_divides, __gmp_binary_modulus): Fix | Kevin Ryde | 2003-06-22 | 1 | -7/+12 | |
| | | | | | long/mpz and long%mpz for dividend==LONG_MIN divisor==-LONG_MIN. (mpz_class __gmp_binary_modulus): Fix mpz%long for negative dividend. | |||||
* | * gmpxx.h (get_d): Remove comments about long double, double is | Kevin Ryde | 2003-06-21 | 1 | -5/+4 | |
| | | | | correct for get_d, a future long double form would be get_ld. | |||||
* | * gmpxx.h (struct __gmp_alloc_cstring): Use mp_get_memory_functions, | Kevin Ryde | 2002-12-21 | 1 | -2/+7 | |
| | | | | not __gmp_free_func. | |||||
* | * gmpxx.h (__gmp_randinit_lc_2exp_size_t): Return type is int. | Kevin Ryde | 2002-11-19 | 1 | -1/+1 | |
| | ||||||
* | 2002-11-14 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-11-13 | 1 | -3/+5 | |
| | | | | | | * gmpxx.h (__gmp_randinit_default_t, __gmp_randinit_lc_2exp_t, __gmp_randinit_lc_2exp_size_t): Use extern "C" { typedef ... }, for the benefit of g++ prior to 3.2. | |||||
* | * gmpxx.h (gmp_randclass constructors): Patch from Roberto Bagnara to | Kevin Ryde | 2002-11-12 | 1 | -4/+7 | |
| | | | | use extern "C" on C function pointer arguments. | |||||
* | 2002-09-26 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-09-26 | 1 | -2/+2 | |
| | | | | | * gmpxx.h (__gmp_cmp_function): Bug fixes in double/mpq and double/mpfr comparisons. | |||||
* | 2002-09-24 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-09-24 | 1 | -3/+8 | |
| | | | | | * gmpxx.h (mpfr_class constructors from strings): Precision was set incorrectly, fixed. | |||||
* | 2002-09-20 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-09-20 | 1 | -4/+4 | |
| | | | | | * gmpxx.h (__gmp_binary_equal, __gmp_binary_not_equal): Fix broken mpq/double functions. | |||||
* | 2002-07-30 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-09-08 | 1 | -2020/+1338 | |
| | | | | | | | | * gmpxx.h (__gmpz_value etc): Remove, use mpz_t etc instead. (__gmp_expr): Reorganise specializations, use __gmp_expr<T,T> not mpz_class etc. (mpfr evals): Remove mode parameter, was always __gmp_default_rounding_mode anyway. | |||||
* | 2002-07-30 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-07-30 | 1 | -1074/+2572 | |
| | | | | | * gmpxx.h: Use mpz_addmul etc for ternary a+b*c etc. Reorganise some macros for maintainability. Merge mpfrxx.h. | |||||
* | * gmpxx.h (mpf_class::get_str): Make exponent mp_exp_t&, default | Kevin Ryde | 2002-06-22 | 1 | -2/+8 | |
| | | | | | | base=10 and ndigits=0. (mpz_class::set_str, mpq_class::set_str, mpf_class::set_str): Add versions accepting "const char *". | |||||
* | 2002-06-20 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-06-20 | 1 | -423/+17 | |
| | | | | | | * gmpxx.h, mpfrxx.h: Remove mpz_classref, let mpq_class::get_num and mpq_class::get_den return mpz_class& as per the documentation. Reported by Roberto Bagnara. | |||||
* | * gmpxx.h (struct __gmp_binary_minus): Use mpz_ui_sub. | Kevin Ryde | 2002-05-08 | 1 | -7/+6 | |
| | ||||||
* | 2002-04-17 Gerardo Ballabio <gerardo.ballabio@unimib.it> | Kevin Ryde | 2002-04-17 | 1 | -86/+136 | |
| | | | | | | * gmpxx.h, mpfrxx.h: Remove mpfr_class bool combinations, remove mpfr_class::get_str2, use mp_rnd_t for rounding modes, use 8*sizeof(double) for mpfr_t's holding doubles. |