[Mono-bugs] [Bug 81857][Nor] Changed - BigInteger.IsProbablePrime() fails on some primes

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Thu Jul 5 07:45:40 EDT 2007

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by sebastien at ximian.com.


--- shadow/81857	2007-07-05 02:13:21.000000000 -0400
+++ shadow/81857.tmp.27975	2007-07-05 07:45:40.000000000 -0400
@@ -111,6 +111,16 @@
 the arugment is 65537. Probably it takes too much.
 ------- Additional Comments From atsushi at ximian.com  2007-07-05 02:13 -------
 Another guess from Kazuki: it is likely due to the Mirror-Rabin
 testing. When we generate a random number, it will be abandoned and
 regenerated when it is in 17 bits and bigger than 65537.
+------- Additional Comments From sebastien at ximian.com  2007-07-05 07:45 -------
+Yes, Kazuki guess is right, it occurs inside MR. This is a corner case
+since 65537 is the first 17-bit number, making it somewhat long to get
+a random number matching MR criteria.
+This isn't something that's likely to occurs when testing random
+primes on very large numbers - which is the point of the code. But
+it's likely that I'll remove/comment/disable this case from the unit

More information about the mono-bugs mailing list