Rahul Sharma (Editor)

Prime95

Updated on
Edit
Like
Comment
Share on FacebookTweet on TwitterShare on LinkedInShare on Reddit
Developer(s)
  
George Woltman

Website
  
mersenne.org

License
  
GIMPS prize terms

Prime95

Stable release
  
28.9 / March 29, 2016 (2016-03-29)

Operating system
  
Microsoft Windows, macOS, Linux (MPrime), FreeBSD (MPrime)

Type
  
Mersenne prime finder / system stability tester

Prime95 is the freeware application written by George Woltman that is used by GIMPS, a distributed computing project dedicated to finding new Mersenne prime numbers. More specifically, Prime95 refers to the Windows and macOS versions of the software.

Contents

MPrime is the Linux command-line interface version of Prime95, to be run in a text terminal or in a terminal emulator window as a remote shell client. It is identical to Prime95 in functionality, except it lacks a graphical user interface.

Although most of the GIMPS software's source code is publicly available, it is technically not free software as users must abide by the project's distribution terms if the software is used to discover a prime number with at least 100,000,000 decimal digits and wins the $150,000 bounty offered by the EFF. As such, a user who uses Prime95 to discover a qualifying prime number would not be able to claim the prize directly ($50,000 will go to the person who finds the prime number, $50,000 will go to a mathematics-related charity, $50,000 will be kept as reserve by GIMP). A free software package would not have this restriction.

The code that is used to generate checksums is not publicly available for security reasons. The rewritten FFT assembly code in the current stable version 28 (since June 1, 2014) uses FMA instruction set (FMA3) instructions of Haswell (microarchitecture) CPUs (Core i3/i5/i7-4xxx models), resulting in a huge performance increase.

Prime95 currently does not have GPU support, although Woltman has indicated that it is under development. However, there are third-party programs, such as CUDALucas, that make use of the processing power of GPUs.

Finding Mersenne primes by distributed computing

As of 2014, 14 new Mersenne prime numbers have been found by the network of participants, and a new Mersenne prime was discovered approximately every year until 2009; the latest was four years later. Scott Kurowski wrote the Internet PrimeNet Server that supports the Prime95/MPrime software on GIMPS, one of the earliest grid computing projects, researching Mersenne prime numbers, to demonstrate Entropia-distributed computing software, a company he founded in 1997.

Processing power

A table of selected benchmarks is provided below. The complete list can be found at the official GIMPS website.

Use for stress testing

Over the years, Prime95 has become extremely popular among PC enthusiasts and overclockers as a stability testing utility. It includes a "Torture Test" mode designed specifically for testing PC subsystems for errors in order to help ensure the correct operation of Prime95 on that system. This is important because each iteration of the Lucas-Lehmer depends on the previous one; if one iteration is incorrect, so will be the entire primality test.

The stress-test feature in Prime95 can be configured to better test various components of the computer by changing the fast fourier transform (FFT) size. Three pre-set configurations are available: Small FFTs and In-place FFTs, and Blend. Small and In-place modes primarily test the FPU and the caches of the CPU, whereas the Blend mode tests everything, including the memory.

By selecting Custom, the user can gain further control of the configuration. For example, by selecting 8-8 kB as the FFT size, the program stresses primarily the CPU. By selecting 2048-4096 kB and unchecking the "Run FFTs in-place" checkbox, providing the maximum amount of RAM free in the system, the program tests the memory and the chipset. If the amount of memory to use option is set too high, then the system will start using the paging file and the test will not stress the memory.

On an absolutely stable system, Prime95 would run indefinitely. If an error occurs, at which point the stress test would terminate, this would indicate that the system may be unstable. There is an ongoing debate about terms "stable" and "Prime-stable", as Prime95 often fails before the system becomes unstable or crashes in any other application. This is because Prime95 is designed to subject the CPU to an incredibly intense workload, and to halt when it encounters even one minor error, whereas most normal applications do not stress the CPU anywhere near as much, and will continue to operate unless they encounter a fatal error.

In the overclocking community, a rule of thumb is often used to determine how long to run Prime95: test the CPU (8 kB FFT) for 10 hours and the memory (4096 kB FFT) for 10 hours, and if the system passes, there is a high chance that it is stable. Twenty-four hours of testing is recommended to be sure, as errors may show up after 16 or more hours of testing (compared to, say, just four hours of testing). Moreover, a large proportion of system overclockers and enthusiasts favor Prime95 over other benchmarking suites because Prime95 pushes the CPU's floating point units extremely hard, causing the CPU to become extremely hot. In addition, Prime95 stresses a computer far more than the majority of software-based torture suites. The nature of this is because the operating system usually shuts down the floating-point unit when unused by other programs, whereas Prime95 is well-optimized to continuously and effectively thread the FPU, causing it to be deeply pipelined, thereby generating significantly more heat because of elevated power consumption under the massive workload conditions. In CPUs which are not adequately cooled, errors are likely to occur. Prime95 also constantly accesses main memory at up to 60 MB per second. This constant activity will detect memory problems that other programs will not.

Lastly, power supply units of any machine running Prime95 are subject to the consistent ramifications of such harsh conditions. Power must be maintained clean, while providing adequate voltage, particularly to the CPU, RAM, and chipsets (mainboard chipsets such as the Northbridge where the memory controller may or may not reside; see Athlon 64 or Intel Core i7 for on-die memory controllers) to provide peak performance while maintaining stability. Cray Research used programs similar to Prime95 for over a decade for the purpose of stability testing.

Limits

Version 24 and older of Prime95 cannot test Mersenne numbers beyond 2 79 , 300 , 000 1 . This is slightly shorter than a 24 million digit number. Newer versions of Prime95 (version 25, 26, 27 and 28) can handle Mersenne numbers up to the limit 2 596 , 000 , 000 1 . However, they can perform Trial Factoring on Mersenne numbers up to 2 2 , 147 , 483 , 647 1 .

Prime95 does not fully stress all processor threads when the threads number is more than 64 in Windows, or 32 for the 32-bit version. Windows will manage the processors in groups when the number is beyond 64. Each group will only have a maximum of 64. Prime95 will only load into one processor group.

Release history

More details are located in the whatsnew.txt file.

References

Prime95 Wikipedia