Sample Pi Program

A simple C++ program that calculates Pi to 8,765,4321 digits using the Leibniz formula. This test can be used for showcasing how to write a basic test profile.

To run this test with the Phoronix Test Suite, the basic command is: phoronix-test-suite benchmark sample-program.

Use with caution this test profile is currently marked Experimental.

Test Created

6 December 2010

Last Updated

8 April 2018

Test Maintainer

Phoronix Media 

Test Type

Processor

Average Install Time

2 Seconds

Average Run Time

1 Minute, 58 Seconds

Accolades

100k+ Downloads

Supported Platforms


Public Result Uploads *Reported Test Completions **Reported Installs **Test Profile Page Views ***OpenBenchmarking.orgEventsSample Pi Program Popularity Statisticspts/sample-program2010.122011.052011.102012.032012.082013.012013.062013.112014.042014.092015.022015.072015.122016.052016.102017.032017.082018.012018.062018.112019.042019.092020.022020.072020.122021.052021.102022.032022.082023.012023.062023.112024.042K4K6K8K10K
* Uploading of benchmark result data to OpenBenchmarking.org is always optional (opt-in) via the Phoronix Test Suite for users wishing to share their results publicly.
** Data based on those opting to upload their test results to OpenBenchmarking.org and users enabling the opt-in anonymous statistics reporting while running benchmarks from an Internet-connected platform.
*** Test profile page view reporting began March 2021.
Data updated weekly as of 23 May 2024.

Revision History

pts/sample-program-1.1.1   [View Source]   Sun, 08 Apr 2018 06:16:35 GMT
Minor fixes.

pts/sample-program-1.1.0   [View Source]   Mon, 06 Dec 2010 15:21:02 GMT
Initial import into OpenBenchmarking.org


Performance Metrics

Analyze Test Configuration:

Sample Pi Program

Phoronix Test Suite v5.2.1

OpenBenchmarking.org metrics for this test profile configuration based on 424 public results since 31 July 2014 with the latest data as of 23 October 2023.

Below is an overview of the generalized performance for components where there is sufficient statistically significant data based upon user-uploaded results. It is important to keep in mind particularly in the Linux/open-source space there can be vastly different OS configurations, with this overview intended to offer just general guidance as to the performance expectations.

Component
Percentile Rank
# Compatible Public Results
Seconds (Average)
81st
66
3.9 +/- 0.2
Mid-Tier
75th
> 4.0
50th
4
4.7 +/- 0.1
34th
6
12.4 +/- 0.4
31st
3
12.7 +/- 0.2
31st
5
12.7 +/- 1.0
Low-Tier
25th
> 14.2
13th
4
26.4 +/- 0.2
11th
6
29.8 +/- 0.4
6th
14
42.0 +/- 4.5
2nd
8
65.0 +/- 1.0
OpenBenchmarking.orgDistribution Of Public Results - Phoronix Test Suite v5.2.1424 Results Range From 3 To 470 Seconds32547699111313515717920122324526728931133335537739942144346548780160240320400

Based on OpenBenchmarking.org data, the selected test / test configuration (Sample Pi Program - Phoronix Test Suite v5.2.1) has an average run-time of 2 minutes. By default this test profile is set to run at least 3 times but may increase if the standard deviation exceeds pre-defined defaults or other calculations deem additional runs necessary for greater statistical accuracy of the result.

OpenBenchmarking.orgMinutesTime Required To Complete BenchmarkPhoronix Test Suite v5.2.1Run-Time246810Min: 1 / Avg: 1.21 / Max: 2

Based on public OpenBenchmarking.org results, the selected test / test configuration has an average standard deviation of 0.3%.

OpenBenchmarking.orgPercent, Fewer Is BetterAverage Deviation Between RunsPhoronix Test Suite v5.2.1Deviation246810Min: 0 / Avg: 0.32 / Max: 4

Tested CPU Architectures

This benchmark has been successfully tested on the below mentioned architectures. The CPU architectures listed is where successful OpenBenchmarking.org result uploads occurred, namely for helping to determine if a given test is compatible with various alternative CPU architectures.

CPU Architecture
Kernel Identifier
Verified On
Intel / AMD x86 64-bit
x86_64
(Many Processors)
IBM POWER (PowerPC) 64-bit
ppc64
(Many Processors)
Loongson LoongArch 64-bit
loongarch64
Loongson-3A5000, Loongson-3A5000LL, Loongson-3A6000
Intel / AMD x86 32-bit
i686
(Many Processors)
ARMv7 32-bit
armv7l
ARMv7 Cortex-A7 4-Core, ARMv7 rev 3 4-Core, ARMv7 rev 4 4-Core, ARMv7 rev 5 4-Core
ARMv8 64-bit
aarch64
AArch64 rev 12, AArch64 rev 14, ARMv8 Cortex-A72 4-Core, ARMv8 Cortex-A75 8-Core, ARMv8 Cortex-A77 8-Core, ARMv8 rev 3 6-Core, HUAWEI Kunpeng 920, Phytium D2000, Phytium FT1500A, Phytium FT2000A 4-Core, Rockchip ARMv8 Cortex-A76 8-Core