|Bill Allombert on Thu, 25 Oct 2012 18:26:54 +0200|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
|forprime in 32bit is 50x slower if p>2^32|
Dear PARI developers, forprime is very slow in 32bit for large primes: gettime();my(s);forprime(p=2,6*10^9,s++;if(s%10^7==0,print(p,":",gettime())));s *** last result computed in 2min, 11,909 ms. give time close to 4700 ms/10^7 primes on 64bit. On 32bit we get times around 5000ms until we hit 2^32, then: 4222234741:4912 4444120783:172124 4666527007:261320 4889388631:266533 5112733757:270694 5336500537:274085 5560695863:274562 5785258351:278089 ? ## *** last result computed in 36min, 7,175 ms. This is a 50x slowdown. This explains why ellheegner is significantly slower on 32bit. At least now we get the same number of primes on 32bit and 64bit! Cheers, Bill.