[Ecm-commits] r2380 - trunk

cvs commits ecm-commits at lists.gforge.inria.fr
Thu Feb 7 15:59:54 CET 2013


Author: morain
Date: 2013-02-07 15:59:54 +0100 (Thu, 07 Feb 2013)
New Revision: 2380

Log:
More prototypes, less bugs.


Modified:
   trunk/ecm.c
   trunk/manyecm.c
   trunk/torsions.h
Modified: trunk/ecm.c
===================================================================
--- trunk/ecm.c	2013-02-07 14:08:50 UTC (rev 2379)
+++ trunk/ecm.c	2013-02-07 14:59:54 UTC (rev 2380)
@@ -1206,7 +1206,7 @@
   mpres_init (P.y, modulus);
   mpres_init (P.A, modulus);
 
-  is_E_CM = (zE->disc != 0) && (mpz_cmp_ui(zE->sq[0], 1) != 0);
+  is_E_CM = (zE->disc != 0);
   ec_curve_set_z(E, zE, modulus);
 
   youpi = set_stage_2_params (B2, B2_parm, B2min, B2min_parm, 

Modified: trunk/manyecm.c
===================================================================
--- trunk/manyecm.c	2013-02-07 14:08:50 UTC (rev 2379)
+++ trunk/manyecm.c	2013-02-07 14:59:54 UTC (rev 2380)
@@ -50,9 +50,9 @@
 	params->sigma_is_A = 1;
     else{
 	params->sigma_is_A = -1;
-	params->E = E;
 	mpz_set(params->y, P->y);
     }
+    params->E = E;
     ret = ecm_factor(f, N, B1, params);
     return ret;
 }

Modified: trunk/torsions.h
===================================================================
--- trunk/torsions.h	2013-02-07 14:08:50 UTC (rev 2379)
+++ trunk/torsions.h	2013-02-07 14:59:54 UTC (rev 2380)
@@ -1,5 +1,6 @@
 void mod_div_2(mpz_t x, mpz_t n);
 int mod_from_rat(mpz_t r, mpq_t q, mpz_t N);
+int mod_from_rat2(mpz_t r, mpz_t num, mpz_t den, mpz_t N);
 void ec_force_point(ec_curve_t E, ec_point_t P, mpz_t B, long *x0, mpz_t n);
 
 int




More information about the Ecm-commits mailing list