| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
'limited range of type' warnings about comparisons on 32-bit systems, and
allows 32-bit systems to compute the full range of primes.
Notes:
svn path=/head/; revision=272207
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Prior to this commit, primes(6) relied solely on sieving with primes up
to 65537, with the effect that composite numbers which are the product
of two non-16-bit primes would be incorrectly identified as prime. For
example,
# primes 1099511627800 1099511627820
would output
1099511627803
1099511627807
1099511627813
when in fact only the first of those values is prime.
This commit adds strong pseudoprime tests to validate the candidates
which pass the initial sieving stage, using bases of 2, 3, 5, 7, 11,
13, 17, 19, and 23. Thanks to papers from C. Pomerance, J.L. Selfridge,
and S.S. Wagstaff, Jr.; G. Jaeschke; and Y. Jiang and Y. Deng, we know
that the smallest value which passes these tests is 3825123056546413051.
At present we do not know how many strong pseudoprime tests are required
to prove primality for values larger than 3825123056546413050, so we
force primes(6) to stop at that point.
Reviewed by: jmg
Relnotes: primes(6) now correctly enumerates primes up to
3825123056546413050
MFC after: 7 days
Sponsored by: EuroBSDCon devsummit
Notes:
svn path=/head/; revision=272166
|
|
|
|
|
|
|
|
|
| |
and finish the job. ncurses is now the only Makefile in the tree that
uses it since it wasn't a simple mechanical change, and will be
addressed in a future commit.
Notes:
svn path=/head/; revision=264400
|
|
|
|
|
|
|
| |
letter in /COPYRIGHT.
Notes:
svn path=/head/; revision=203932
|
|
|
|
|
|
|
| |
OK'ed by: core
Notes:
svn path=/head/; revision=139103
|
|
|
|
|
|
|
| |
any fake value.
Notes:
svn path=/head/; revision=136910
|
|
|
|
|
|
|
| |
especially in troff files.
Notes:
svn path=/head/; revision=108533
|
|
|
|
|
|
|
| |
-CURRENT to be WARNS-safe (but not -STABLE for some reason)
Notes:
svn path=/head/; revision=104728
|
|
|
|
|
|
|
| |
it's still in the NetBSD version.
Notes:
svn path=/head/; revision=104725
|
|
|
|
|
|
|
|
|
|
|
|
| |
various usage synopses; bogus and/or unnecessary casting; exit values;
use LINE_MAX instead of magic numbers; declare extern variables in a
header; add $FreeBSD$ where missing.
Reviewed by: markm, obrien
Obtained from: NetBSD | fanf
Notes:
svn path=/head/; revision=104720
|
|
|
|
|
|
|
|
|
| |
change function declarations to ANSI
change a variable that stores sizeof() values to size_t
use return to escape the end of main(), not exit(3)
Notes:
svn path=/head/; revision=91027
|
|
|
|
|
|
|
|
|
|
|
| |
to be.
PR: misc/35181
Submitted by: Stefan Farfeleder <e0026813@stud3.tuwien.ac.at>
MFC after: 3 days
Notes:
svn path=/head/; revision=91026
|
|
|
|
|
|
|
|
|
| |
Remove __STDC__ (which means we now use stdarg rather than vararg)
Remove register
Remove main prototype
Notes:
svn path=/head/; revision=90828
|
|
|
|
|
|
|
|
|
|
| |
'if and only iff' does not.
PR: 33242
Submitted by: Eric Yu <ericyu@mail2000.com.tw>
Notes:
svn path=/head/; revision=88530
|
|
|
|
| |
Notes:
svn path=/head/; revision=53920
|
|
|
|
| |
Notes:
svn path=/head/; revision=53210
|
|
|
|
| |
Notes:
svn path=/head/; revision=53209
|
|
|
|
|
|
|
|
|
|
| |
Fix old bug with bogus casing to (long).
Document the true limits of factor on 64-bit architectures.
Submitted by: bde
Notes:
svn path=/head/; revision=42357
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use '0' for base rather than 10 to allow for more flexible input bases.
Inspired by changes in PR 7402, but mostly redone by me to get past
bde filter.
Submitted by: Timo J. Rinne
PR: 7402
Notes:
svn path=/head/; revision=42338
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR7402 was even less suitable for committing almost verbatim than at
first appearance. Rev.1.9 of primes.c has at least the following defects.
- no update for man page.
- no update for usage string.
- blowing away of a previous commit to change EOF to -1 in getopt() test.
- blowing away of a previous commit to fix printf format errors.
- new printf format errors.
- one gratuitous ANSIism.
- two style bugs.
- ... and a partition in a pear tree.
PR: 7402
Notes:
svn path=/head/; revision=38199
|
|
|
|
|
|
|
|
|
|
|
| |
This would make these `games' somewhat useful tools.
PR: 7402
Reviewed by: phk
Submitted by: Timo J. Rinne <tri@iki.fi>
Notes:
svn path=/head/; revision=38153
|
|
|
|
| |
Notes:
svn path=/head/; revision=37309
|
|
|
|
|
|
|
|
| |
Hopefully that's the last of the 64-bit cleaning of src/games. That is,
without adding -Wall to the compiler flags. That's not a pretty sight.
Notes:
svn path=/head/; revision=35892
|
|
|
|
|
|
|
|
|
|
| |
EOF? The getopt(3) manpage clearly states that the return value is *-1*,
not EOF! Besides, getopt(3) isn't reading from a file. :)
Noticed-while: merging to 2.2 (where this is correct).
Notes:
svn path=/head/; revision=33937
|
|
|
|
| |
Notes:
svn path=/head/; revision=29016
|
|
|
|
|
|
|
|
| |
Reviewed by: maybe@yes.no
Obtained from: OpenBSD (mostly deraadt@openbsd.org)
Notes:
svn path=/head/; revision=28979
|
|
|
|
| |
Notes:
svn path=/head/; revision=23726
|
|
|
|
| |
Notes:
svn path=/head/; revision=8856
|
|
of the x11 based games. I'm not going to tag the originals with bsd_44_lite
and do this in two stages since it's just not worth it for this collection,
and I've got directory renames to deal with that way. Bleah.
Submitted by: jkh
Notes:
svn path=/cvs2svn/branches/unlabeled-1.1.1/; revision=2490
|