Compare commits

...

268 Commits

Author SHA1 Message Date
Michael Larabel
a7fab960a1 Update some links to HTTPS 2018-11-26 06:52:44 -06:00
Michael Larabel
6b5e8df4e3 Update some links to HTTPS 2018-11-26 06:52:29 -06:00
Michael Larabel
f6356c4a27 Prep for Phoronix Test Suite 8.4.0 2018-11-26 06:43:14 -06:00
Michael Larabel
027f7e84bb phodevi: Another string fix 2018-11-26 06:12:32 -06:00
Michael Larabel
eaa7431823 phodevi: Remove duplicate words from strings 2018-11-24 12:09:39 -06:00
Michael Larabel
088a710bcd phodevi: x86_64 default frequency reporting tweak 2018-11-24 11:59:31 -06:00
Michael Larabel
b717fa9582 pts-core: Another info tweak 2018-11-24 05:48:59 -06:00
Michael Larabel
f456fcb084 pts-core: Drop change-log reporting from info command as during debug-self-test skews timing 2018-11-24 05:47:07 -06:00
Michael Larabel
12f3d80f39 pts-core: Via info command report large system counts on result files for easy interpretation 2018-11-22 19:09:04 -06:00
Michael Larabel
0bd0dee4d4 Prep for Phoronix Test Suite 8.4 Milestone 3 2018-11-20 06:06:00 -06:00
Michael Larabel
5df5624c2a pts-core: Fix for compacting system table in more cases of GPU driver comparisons 2018-11-17 18:38:31 -06:00
Michael Larabel
571102774c pts-core: Add RemoveInstallDirectoryOnReinstall to toggle test re-installation behavior 2018-11-17 14:57:44 -06:00
Michael Larabel
1554c1804c pts-core: Continued POWER9 support improvements 2018-11-15 16:48:58 -06:00
Michael Larabel
146fff9de6 pts-core: More TUI graph stylization work 2018-11-13 16:57:40 -06:00
Michael Larabel
2f183c8100 pts-core: Only TUI graph brand colors when more than one line to color per result 2018-11-13 16:11:00 -06:00
Michael Larabel
be85bb3466 pts-core: Fix warning introduced in earlier commit 2018-11-13 15:33:40 -06:00
Michael Larabel
ffbe0513e9 pts-core: Provide a cache for identifier_to_brand_color 2018-11-13 15:27:34 -06:00
Michael Larabel
4bf1a781b7 pts-core: Allow branded colors to work in the terminal/CLI text graphs 2018-11-13 14:23:34 -06:00
Michael Larabel
41759ab9ef phoronix-test-suite: Basic helper updates 2018-11-13 14:22:13 -06:00
Michael Larabel
02f4d29d16 pts-core: Fix possible situation of openbenchmarking-refresh not updating when IndexCacheTTL is set to 0
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/306
2018-11-12 08:32:56 -06:00
Michael Larabel
d286f89f92 pts-core: Fix bool input handling on invalid input 2018-11-11 18:09:54 -06:00
Michael Larabel
cf8e834598 pts_Graph: Fix for sometimes tick marker text overlapping 2018-11-11 15:50:05 -06:00
Michael Larabel
3902d680be pts-core: Ubuntu package updates 2018-11-09 18:01:45 -06:00
Fatima Sheremetyeva
1ec7a10523 Merge branch 'master' of https://github.com/phoronix-test-suite/phoronix-test-suite 2018-11-09 16:06:54 -06:00
Fatima Sheremetyeva
8afd4eb3ce pts-core: Fix behavior of AppendToArguments sometimes double appending when running against an existing result file of that test 2018-11-09 16:06:41 -06:00
Michael Larabel
f01ba250c2 pts-core: Expose NUM_CPU_PHYSICAL_CORES 2018-11-09 11:36:08 -06:00
Michael Larabel
56ca809504 pts-core: Frame timing parser fix from earlier commit 2018-11-06 09:23:18 -06:00
Michael Larabel
8331cf461e phodevi: Improved CPU cache size detection 2018-11-05 19:12:34 -06:00
Michael Larabel
eb4e073f80 phodevi: More work on previous commit 2018-11-05 19:09:26 -06:00
Michael Larabel
1f10bf12e3 phodevi: Improved physical CPU core detection for architectures like POWER 2018-11-05 19:03:41 -06:00
Michael Larabel
568bbf124a pts-core: Drop "and subsidiaries" from strings 2018-11-05 10:03:42 -06:00
Michael Larabel
7955d58335 Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-11-05 06:31:27 -06:00
Michael Larabel
b74049cbf4 Rebuild for 8.4 M2 2018-11-05 06:31:21 -06:00
Michael Larabel
a60d870932 Prep for 8.4 M2 2018-11-05 06:30:33 -06:00
Fatima Sheremetyeva
38f0f3eb6b CSV parsing for F1 2018 format 2018-11-05 03:33:53 -06:00
Fatima Sheremetyeva
655100774f CSGO per-frame time reporting 2018-11-03 11:11:43 -05:00
Michael Larabel
1f6c7b7fa4 phodevi: Another BSD core count fix 2018-10-29 07:01:46 -05:00
Michael Larabel
f410ada612 phodevi: Vulkan driver reporting fix 2018-10-26 14:57:08 -05:00
Michael Larabel
ba3203de8d Fix nodejs external dependency on openSUSE 2018-10-23 06:44:33 -05:00
Michael Larabel
68f34c22ff phodevi: Another fix for X server version detection 2018-10-20 15:27:09 -05:00
Michael Larabel
6c8067a20b phodevi: Fix for previous commit 2018-10-20 15:22:30 -05:00
Michael Larabel
50d8cdc3fb phodevi: Fix X Version detection 2018-10-20 15:21:24 -05:00
Michael Larabel
93325244c4 phodevi: CPU core detection fix on DragonFlyBSD depending upon topology 2018-10-16 17:19:51 -05:00
Michael Larabel
3ad38b6939 phodevi: Ampere eMAG CPU detection 2018-10-09 09:44:48 -05:00
Michael Larabel
f575d21074 phodevi: Typo fix for ARMv8 2018-10-09 09:43:13 -05:00
Michael Larabel
049b759f10 phodevi: Pick up 0x50 implementer for AArch64 2018-10-09 09:42:37 -05:00
Michael Larabel
c6f48b95c5 pts-core: Add dry-run test option 2018-10-08 13:20:12 -05:00
Michael Larabel
ee04d64563 pts-core: Allow passing PTS environment variables as arguments to PTS and then just have PTS set them in the environment 2018-10-08 11:34:39 -05:00
Michael Larabel
0a645235a6 Prep Phoronix Test Suite 8.4 Milestone 1 2018-10-07 15:05:34 -05:00
Michael Larabel
95e6d0d01b pts-core: Tweak italic line on non-verified tests 2018-10-07 12:21:14 -05:00
Michael Larabel
ae9b7b1621 system_monitor: Only save per-run if the run was successful 2018-10-07 11:53:33 -05:00
Michael Larabel
3b7e3c7e70 pts-core: Fix typo from previous commit 2018-10-05 09:06:35 -05:00
Michael Larabel
e54b418ef2 pts_Graph: Highlight AMD red "Athlon " 2018-10-05 07:20:17 -05:00
Michael Larabel
9bafbd7195 phodevi: Drop information reporting support for the long ago Catalyst/fglrx driver stack that hasn't been supported/maintained in many years 2018-10-04 17:28:33 -05:00
Michael Larabel
87a90709f7 pts-core: Ubuntu ex dep file check fix for numpy 2018-10-03 07:01:03 -05:00
Michael Larabel
30eb45846a pts-core: Fix for previous commit 2018-10-02 16:40:49 -05:00
Michael Larabel
2b93102268 pts-core: At run-time also report if test is deprecated/broken 2018-10-02 14:16:00 -05:00
Michael Larabel
03029d5be5 pts-core: Cleanup ubuntu install ex dep script
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/293
2018-10-02 13:57:32 -05:00
Michael Larabel
19914d4577 pts-core: Add pts_client::get_path_separator() 2018-10-02 11:24:45 -05:00
Michael Larabel
78de8c6b7b pts-core: CHange ; to : for separators in DEBUG_PATH 2018-10-02 11:15:19 -05:00
Michael Larabel
e77df95389 pts-core: Add DEBUG_PATH 2018-10-02 11:14:25 -05:00
Michael Larabel
b016dd899b pts-core: Add some more possible Windows dependencies 2018-10-02 10:09:48 -05:00
Michael Larabel
79d8fcd41e pts-core: Add "node-npm" as an external dependency for Node.js + NPM 2018-10-01 12:35:00 -05:00
Michael Larabel
a5f28439e6 phodevi: Report vRAM size on GPU model string in GB when over 1GB 2018-10-01 06:26:38 -05:00
Michael Larabel
3747113313 pts-core: Fix warning in make-download-cache 2018-09-25 16:30:09 -05:00
Michael Larabel
c01a9b010e phodevi: Improved resolution exposure 2018-09-19 20:05:04 -05:00
Michael Larabel
56aa7199c3 phodevi: Check if "/root" writable as an alternative to username check, might fix some issues when running as crontab 2018-09-18 11:35:42 -05:00
Michael Larabel
0fc8b88b30 pts-core: Don't drop last digit from /dev/md in auto-disks
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/292
2018-09-11 06:42:16 -05:00
Michael Larabel
5c0c048e81 Add Phoronix Test Suite 8.2 release highlights 2018-09-11 06:38:40 -05:00
Michael Larabel
9f2a7b3201 More prepping for Phoronix Test Suite 8.2.0 2018-09-11 06:32:23 -05:00
Michael Larabel
42069d2df7 pts-core: Drop Google fonts from the result viewer to speed up when without Internet 2018-09-11 05:52:21 -05:00
Michael Larabel
7454652df9 pts-core: Add numeric check 2018-09-09 14:31:33 -05:00
Michael Larabel
acc90e44f1 pts-core: Fix for previous commit 2018-09-09 12:14:44 -05:00
Michael Larabel
14a49bc295 pts-core: More adjust precision work 2018-09-09 11:52:32 -05:00
Michael Larabel
a789c44b74 pts-core: Auto-adjust precision for result graphs having all large numbers 2018-09-09 11:44:50 -05:00
Michael Larabel
0f6f2a4a57 phodevi: Add extra fallback detection for LXC in system-layer 2018-09-09 09:43:49 -05:00
Michael Larabel
edbb31e8ed pts-core: Drop systems before system to avoid possible " s" in some strings like Matrox VGA adapters 2018-09-09 09:34:06 -05:00
Michael Larabel
9766cd1993 phodevi: More robust DMI decode ignore value handling 2018-09-09 09:32:17 -05:00
Michael Larabel
87be9c54d1 pts-core: Addition for previous commit 2018-09-09 09:29:13 -05:00
Michael Larabel
4078ffd39a phodevi: Improve CPU thread count detection when running under LXC 2018-09-09 09:27:50 -05:00
Michael Larabel
6e6fbd97a5 pts-core: Cleanup some formatting on test run prompts 2018-09-09 05:49:03 -05:00
Michael Larabel
0e707d0bf3 pts-core: Show first error on problems 2018-09-08 20:25:47 -05:00
Michael Larabel
22232f9cec pts-core: Tab errors 2018-09-08 20:24:56 -05:00
Michael Larabel
e8677218bb pts-core: Install error improvement 2018-09-08 20:21:36 -05:00
Michael Larabel
943affd275 pts-core: Clean up some repetitive errors 2018-09-08 19:42:58 -05:00
Michael Larabel
cb4f09282b pts-core: Don't install tests where the current run-time checks will fail 2018-09-08 19:39:32 -05:00
Michael Larabel
d2e8ffc29a pts-core: Add RequiresInternet test profile property to indicate if the test profile needs a working Internet connection 2018-09-08 16:11:41 -05:00
Michael Larabel
2b2978b724 pts-core: Add RequiresNetwork test profile property to indicate if the test profile needs a working network connection 2018-09-08 16:07:16 -05:00
Michael Larabel
43c8759f85 pts-core: Allow TestType = Graphics and RequiresDisplay = FALSE to accomodate for CUDA/OpenCL compute headless tests... 2018-09-08 15:52:11 -05:00
Michael Larabel
3567d78b32 pts-core: Add RequiresDisplay test profile property to indicate if the test profile explicitly requires a monitor / display server to work 2018-09-08 15:47:37 -05:00
Michael Larabel
2fc399d738 phoromatic: Should fix suite editing
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/260
2018-09-08 10:53:07 -05:00
Michael Larabel
2f29f6bf3f ob_auto_compare: Clear up description string 2018-09-07 14:03:07 -05:00
Michael Larabel
f2a31091d1 Phoronix Test Suite 8.2 Milestone 4 2018-09-07 09:47:19 -05:00
Michael Larabel
39c12608bc ob_auto_compare: Fix for previous commit 2018-09-07 07:30:28 -05:00
Michael Larabel
dc7e4a57a4 ob_auto_compare: Default first to trying to do an automated local result comparison 2018-09-07 07:29:50 -05:00
Michael Larabel
0e75347ad4 pts-core: Add TERMINAL_WIDTH to diagnostics variable 2018-09-07 07:10:26 -05:00
Michael Larabel
a157c287af Merge pull request #290 from spandruvada/master
phodevi: Expanded sensor coverage using Intel RAPL
2018-09-06 16:38:07 -04:00
Srinivas Pandruvada
194ffd2f2b phodevi: Expanded sensor coverage using Intel RAPL
Use Intel RAPL (Running Average Power Limit) counters to get package power
consumption. For multi package system it adds power of all packages.
2018-09-05 17:34:51 -07:00
Michael Larabel
3bd012418b phodevi: Silly typo... 2018-09-04 09:37:14 -05:00
Michael Larabel
ecab40c00c pts-core: Fix for previous commit 2018-09-04 09:36:02 -05:00
Michael Larabel
98a7c3e06f phodevi: Embedded ARM Cortex / ARM part model detection 2018-09-04 09:31:30 -05:00
Michael Larabel
c428c7fb5e pts-core: Add reinstall / re-install aliases to force-install 2018-09-03 18:42:32 -05:00
Michael Larabel
c74602eec1 phodevi: Rockchip SoC fallback detection 2018-09-03 11:07:41 -05:00
Michael Larabel
cd8a6bea93 phodevi: Avoid lxpanel warning when x server is not running 2018-08-31 08:26:24 -05:00
Michael Larabel
2c5ed3a834 phodevi: Amlogic SoC detection based on meson_cpufreq driver 2018-08-31 07:11:33 -05:00
Michael Larabel
3b55ce6ade pts-core: Fix potential validation error 2018-08-29 16:44:44 -05:00
Michael Larabel
a5b88d5f48 pts-core: Fix behavior of "Would you like to stop and install these tests now"
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/287
2018-08-28 14:36:10 -05:00
Michael Larabel
37c29aa463 pts-core: Fix for previous commit 2018-08-28 10:20:59 -05:00
Michael Larabel
44b6330ce3 pts-core: Phoromatic server relay check for first part of IP address to allow for working in VMs on LAN 2018-08-28 10:19:54 -05:00
Michael Larabel
eadafced08 phodevi: RISC-V reporting fix 2018-08-24 08:18:50 -05:00
Michael Larabel
33057a6835 pts-core: Other fixed logic overlooked yesterday in result browser prompt 2018-08-23 14:30:17 -05:00
Michael Larabel
b21459a063 pts-core: Fix inverted logic from commit yesterday 2018-08-23 06:05:33 -05:00
Michael Larabel
1a2746d31e pts-core: Minor tweaks 2018-08-22 18:43:59 -05:00
Michael Larabel
516ff81122 phodevi: Don't allow graphics tests on Docker 2018-08-22 14:16:55 -05:00
Michael Larabel
d44f32920b Prep for Phoronix Test Suite 8.2 Milestone 3 2018-08-22 13:50:30 -05:00
Michael Larabel
3bba1e986c pts-core: Introduce phodevi phodevi::is_display_server_active() to clean up some logic 2018-08-22 13:30:57 -05:00
Michael Larabel
4727f39640 pts-core: Move list-all-tests off to its own file to clean up logic 2018-08-22 13:18:03 -05:00
Michael Larabel
b1866bf84e pts-core: Add list-cached-tests option 2018-08-22 13:06:02 -05:00
Michael Larabel
cd89e8c61a pts-core: Don't download tests/suites preemptively on build-suite 2018-08-22 07:32:25 -05:00
Michael Larabel
dbf2efc4c9 phodevi: Basic Docker detection 2018-08-21 15:01:36 -05:00
Michael Larabel
37597496e2 pts-core: Add PTS_DOWNLOAD_CACHING_PLATFORM_LIMIT environment variable for make-download-cache 2018-08-21 14:33:41 -05:00
Michael Larabel
e8c105cf9a pts-core: Allow lean openbenchmarking caches in make-openbenchmarking-cache (just the latest version) 2018-08-21 14:25:18 -05:00
Michael Larabel
2cb34a74e4 pts-core: Add PTS_USER_PATH_OVERRIDE environment variable to override PTS_USER_PATH on initialization 2018-08-21 13:55:29 -05:00
Michael Larabel
f713559157 pts-core: Add PTS_DOWNLOAD_CACHE_OVERRIDE environment variable option on make-download-cache 2018-08-21 13:48:44 -05:00
Michael Larabel
4abad35787 pts-core: Some shell string tweaks 2018-08-21 12:23:04 -05:00
Michael Larabel
5cedc72ba8 pts-core: Show deprecated tests too when running list-all-tests 2018-08-21 08:58:07 -05:00
Michael Larabel
d8a121dcd9 pts-core: Fix for increase run count 2018-08-18 07:16:33 -05:00
Michael Larabel
642feee050 pts-core: Clean up some of the increase_run_count_check logic 2018-08-17 12:13:55 -05:00
Michael Larabel
b0099ac69e pts-core: Add DropNoisyResults option if wishing to not save results that have too high of deviation between runs 2018-08-17 12:06:30 -05:00
Michael Larabel
a7a6f9df59 pts-core: Fix warning over Windows readline functionality on tab 2018-08-17 08:11:23 -05:00
Michael Larabel
b3195478e1 pts-core: Fix for previous commit 2018-08-16 10:40:07 -05:00
Michael Larabel
2dcb8e8b82 pts-core: Minor updates to logic for determining how many times to dynamically increase run count on high variance results 2018-08-16 10:15:03 -05:00
Michael Larabel
f40caa8ec5 pts-core: Only show 'recommended tests' in the command helper when a test profile can actually be passed as an arg 2018-08-15 18:04:57 -05:00
Michael Larabel
88ec569699 pts-core: Clear up some Windows helpers 2018-08-15 16:26:09 -05:00
Michael Larabel
e4c5ca1aeb Prep for Phoronix Test Suite 8.2 M2 2018-08-15 14:02:46 -05:00
Michael Larabel
4c03aae195 pts_Graph: Tweaks to text sizing on vertical bar graphs 2018-08-15 13:08:23 -05:00
Michael Larabel
3d0e276743 pts-core: Fix "version" being stripped from (PTE) Inversion. 2018-08-14 13:14:40 -05:00
Michael Larabel
1a9f2b7016 phodevi: Reporting of L1TF / Level 1 Terminal Fault vulnerability 2018-08-14 12:46:15 -05:00
Michael Larabel
1e37a3ef06 pts-core: Allow comparing dynamic in-line result comparisons against local results when no Internet results matching or Internet not available 2018-08-12 18:23:12 -05:00
Michael Larabel
6de34d532c pts-core: Be clearer when no search results found on search sub-command 2018-08-12 17:41:18 -05:00
Michael Larabel
a6ab934444 pts-core: Allow stress-run to be triggered from interactive mode 2018-08-12 17:36:15 -05:00
Michael Larabel
67d35e72dc pts-core: Show "popular tests" in the invalid command helper 2018-08-12 16:26:43 -05:00
Michael Larabel
ad38824cbd pts-core: Rework list-recommended-tests to make use of download count information exposed via OB index repository data rather than needing to make fresh web query 2018-08-12 15:42:34 -05:00
Michael Larabel
847cfe2822 pts-core: Tweaks to shell sensor output 2018-08-12 13:45:23 -05:00
Michael Larabel
d3b2442fc0 pts-core: When Internet is not available and running list-tests, only show tests that are available via caches unless list-all-tests is run 2018-08-12 13:36:26 -05:00
Michael Larabel
edb57ebea0 pts-core: Fix possible alignment issue with value/spacer on outputting text-based result graphs 2018-08-09 19:20:34 -04:00
Michael Larabel
db224c251f pts-core: Readline improvement 2018-08-09 16:20:13 -05:00
Michael Larabel
6feb535eff pts-core: Few result output tweaks 2018-08-07 09:41:28 -05:00
Michael Larabel
ae96d87c5e pts-core: Clear up some PHP 7.3 warnings 2018-08-06 08:18:42 -05:00
Michael Larabel
0223dd4890 pts-core: Optional support with PHP 7.3+ to also obtain network info using net_get_interfaces() 2018-08-06 07:18:05 -05:00
Michael Larabel
096b18aca9 pts-core: Fix pts_logger warning 2018-08-04 17:59:47 -05:00
Michael Larabel
26a45e0a53 pts-core: Set LANG default to "en_US.utf8" 2018-08-01 15:03:26 -05:00
Michael Larabel
90436b882a pts-core: Add some possible missing dependencies on some configurations
From https://github.com/phoronix-test-suite/phoronix-test-suite/issues/279
2018-07-29 13:52:43 -05:00
Michael Larabel
31d7ee84bd pts-core: Alert the user when the test install directory is on a file-system mounted with 'noexec'
Suggested by https://github.com/phoronix-test-suite/phoronix-test-suite/issues/283
2018-07-29 13:48:45 -05:00
Michael Larabel
f371e1e7ed pts-core: Add libevent as possible external dependency 2018-07-29 12:48:41 -05:00
Michael Larabel
e50629c231 pts-core: Bump for previous commit the core version 2018-07-29 12:38:42 -05:00
Michael Larabel
08bf9d4e57 pts-core: Add DivideResultDivisor to result parser 2018-07-29 12:36:10 -05:00
Michael Larabel
fc9157fbf5 pts-core: Ubuntu package update for libtool 2018-07-28 19:33:51 -05:00
Michael Larabel
3073e04dee Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-07-28 18:32:44 -05:00
Michael Larabel
e5daa542df pts-core: Minor updates 2018-07-28 18:32:35 -05:00
Michael Larabel
95fdf3527f pts-core: Better handling when no files are downloaded due to no URLs being specified, a.k.a. files need to be manually downloaded or placed in cache by user. 2018-07-28 14:21:22 -04:00
Michael Larabel
f70020785d pts-core: Fix in result parser generation 2018-07-28 13:36:09 -04:00
Michael Larabel
a235986a30 pts-core: Add readline to detected PTS functions desired 2018-07-21 10:10:35 -05:00
Michael Larabel
7124b0454a Phoronix Test Suite 8.2 M1 prep 2018-07-21 08:56:20 -05:00
Michael Larabel
24ecd03a93 pts-core: Just another readline tweak 2018-07-20 14:31:01 -05:00
Michael Larabel
6ddfbb587d system_monitor: default to 1 sec frequency 2018-07-20 13:05:04 -05:00
Michael Larabel
affdba821b pts-core: Add autocompletion support for result file identifier based on installed software/hardware 2018-07-20 08:38:56 -05:00
Michael Larabel
6ccebe9f36 Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-07-19 12:50:11 -05:00
Michael Larabel
443ad9ab31 pgo: Enforce make serial on second build too 2018-07-19 12:49:46 -05:00
Michael Larabel
6e69b1e00c pts-core: Ignore blank unknown tests 2018-07-19 11:59:19 -05:00
Michael Larabel
808981640a pts-core: Metadata improvements 2018-07-19 11:37:35 -04:00
Michael Larabel
a15df82d88 Appdata update... 2018-07-19 11:19:30 -04:00
Michael Larabel
29ccdced61 pts-core: Fix for previous commit 2018-07-19 09:08:36 -05:00
Michael Larabel
e12923c068 pts-core: Add support for overriding environment variables exposed to test scripts 2018-07-19 08:57:54 -05:00
Michael Larabel
a70649dfc7 pgo: Couple improvements... 2018-07-19 09:42:53 -04:00
Michael Larabel
4f0db42e09 pgo: Add a PGO module to make it super simple/easy to do PGO testing with PTS 2018-07-18 20:29:02 -04:00
Michael Larabel
53067f4e7a pts-core: Use array keys for OB IDs on shell auto completion 2018-07-18 17:52:32 -05:00
Michael Larabel
0f6e12600e pts-core: Auto-completion fix for Windows 2018-07-18 17:49:50 -05:00
Michael Larabel
651da1d84d Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-07-18 17:05:57 -05:00
Michael Larabel
3346e597cd pts-core: More Shell improvements 2018-07-18 17:05:41 -05:00
Michael Larabel
e1c6ca4dee pts-core: Various improvements to the Shell sub-command functionality, including auto-completion support 2018-07-18 16:58:58 -05:00
Michael Larabel
c6afe38549 Merge branch 'master' of https://github.com/phoronix-test-suite/phoronix-test-suite 2018-07-18 13:49:46 -04:00
Michael Larabel
6ac2703f33 pts-core: Tweaks for landing PGO module soon 2018-07-18 13:49:22 -04:00
Michael Larabel
fe2ec09d16 pts-core: Windows external dependency updates 2018-07-18 12:33:28 -05:00
Michael Larabel
b87abf9bc4 phodevi: Another fix for prev commit 2018-07-18 07:02:42 -05:00
Michael Larabel
d655229fe4 phodevi: Adjust previous commit 2018-07-18 07:00:36 -05:00
Michael Larabel
dfb81b475d phodevi: Improve Linux multi-socket CPU detection when lscpu is not present 2018-07-18 06:58:47 -05:00
Michael Larabel
22e630d5e1 phodevi: overlayfs detection improvement 2018-07-18 06:54:43 -05:00
Michael Larabel
9f88c84d31 phodevi: Avoid lscpu warning when not present 2018-07-18 06:52:52 -05:00
Michael Larabel
6d24536e3c phodevi: Further adjust previous commit 2018-07-18 06:51:11 -05:00
Michael Larabel
7ffc816cc8 phodevi: Improve upon previous commit 2018-07-18 06:49:59 -05:00
Michael Larabel
105f47a17a phodevi: Fix for ps process detection when using busybox where command is unrecognized 2018-07-18 06:46:21 -05:00
Michael Larabel
cdd771dbb0 phoronix-test-suite: Drop some outdated php5 references in helper outputs 2018-07-18 06:43:04 -05:00
Michael Larabel
2f9e34edfb pts-core: Add initial qt5-development external dependency handling 2018-07-15 17:32:56 -05:00
Michael Larabel
7ef2be2de9 pts-core: Validation for result parser DisplayFormat 2018-07-15 13:58:39 -05:00
Michael Larabel
904e02041e pts-core: Allow specifying PASS_FAIL / DisplayFormat via result parser 2018-07-15 12:29:17 -04:00
Michael Larabel
08c24a4ad1 pts-core: Add mongodb to external dependencies 2018-07-14 19:53:17 -05:00
Michael Larabel
2f26c0a93f pts-core: Add readline-based autocompletion support for the result file save name for trying to match existing result file identifiers 2018-07-14 10:48:23 -05:00
Michael Larabel
f7884463ff pts-core: Add readline-based autocompletion support for text-based menu selection lists 2018-07-14 10:41:15 -05:00
Michael Larabel
1a6b8403ad phodevi: Improved multi CPU socket reporting on Windows
devi: Improved multi CPU socket reporting on Windows
y
2018-07-10 17:14:13 -07:00
Michael Larabel
a1adf66b72 PTS Windows: don't try cygwin php build right now since pcntl ended up being removed it appears 2018-07-06 14:39:49 -05:00
Michael Larabel
49b8f6d82b PTS Windows: see if cygwin php build available 2018-07-06 14:27:43 -05:00
Michael Larabel
5eaafaa9b1 phodevi: Fix for previous commit 2018-07-06 14:16:42 -05:00
Michael Larabel
5581622977 phodevi: Unit reporting for Windows battery 2018-07-06 14:15:16 -05:00
Michael Larabel
dc4c82a7f7 phodevi: Windows battery reporting discharge rate support 2018-07-06 14:14:15 -05:00
Michael Larabel
09bab0797d phodevi: Don't report Windows virtual network adapters 2018-07-06 13:54:07 -05:00
Michael Larabel
841082197d Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-07-03 12:59:56 -05:00
Michael Larabel
8d6d9ccc58 phoromatic: Drop the first network on failure check since eventually (after more attempts) it will then hit the secondary check and reboot if still having network issues further into the process 2018-07-03 12:59:14 -05:00
Michael Larabel
e091126310 Open RAKKESTAD for development 2018-07-03 12:58:37 -05:00
Michael Larabel
e4f402d161 pts-core: Kill pts_test_profile_downloads_writer 2018-07-01 16:15:01 -05:00
Michael Larabel
aa3a2535e9 pts-core: Kill pts_test_profile_writer 2018-07-01 16:04:25 -05:00
Michael Larabel
42f4393b40 pts-core: XML generation should be working correctly now from XSD 2018-07-01 15:58:03 -05:00
Michael Larabel
d17e99b093 Merge pull request #274 from FabioLolix/Arch_pacman
install-arch-packages.sh: Add --asdeps option
2018-07-01 06:49:17 -04:00
Michael Larabel
e3e49a95b8 Merge pull request #275 from FabioLolix/Arch_deps
pts-core: Arch deps, fixed zlib name, add freeimage, removed double mesa-demos
2018-07-01 06:48:49 -04:00
FabioLolix
f535953155 pts-core: Arch deps, fixed zlib name, add freeimage, removed double
common-dependencies is already added (mesa-demos + unzip)
freeimage is required by universe-x
nothing complained about zlib but name is not zlib1
2018-06-30 23:33:04 +02:00
FabioLolix
d2de17243a install-arch-packages.sh: Add --asdeps option
With this option installed packages will result as 'orphan' for an easy removal when no more needed, this option is already added in the three AUR pkgbuilds
2018-06-30 22:48:48 +02:00
Michael Larabel
9fb1641f24 pts-core: WIP on validation/XSD generation improvements 2018-06-30 11:06:38 -05:00
Michael Larabel
f660a20b46 phoromatic: Fix for previous commit 2018-06-30 09:40:31 -05:00
Michael Larabel
3affaad204 phoromatic: From rootadmin allow the rootadmin to override/reset a user account password 2018-06-30 09:34:08 -05:00
Michael Larabel
acd397cc7e pts-core: Strengthen GD check in result-file-to-pdf
https://github.com/phoronix-test-suite/phoronix-test-suite/issues/117#issuecomment-400772902
2018-06-27 13:03:04 -05:00
Michael Larabel
a86f4b31b7 Prep Phoronix Test Suite 8.0.1 2018-06-26 12:19:28 -05:00
Michael Larabel
866ca38051 use_wine: On test profiles having a wine external dependency, reset the os_under_test at install time too 2018-06-21 08:31:02 -05:00
Michael Larabel
e2323f8ac1 pts-core: On __post_test_install() to modules, pass the test install request object rather than just the identifier 2018-06-21 08:30:20 -05:00
Michael Larabel
852d7e06e5 pts-core: Pass the test install request object to the __pre_test_install() module call 2018-06-21 08:28:35 -05:00
Michael Larabel
690e89e46b Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-06-21 07:36:15 -05:00
Michael Larabel
cfd9808f8d pts-core: Fix skip-test behavior 2018-06-21 07:35:45 -05:00
Michael Larabel
b122474ffb TODO update 2018-06-21 07:35:35 -05:00
Michael Larabel
ae889bedd2 Merge pull request #270 from swarth100/add-rh-sudo-check
install-fedora-packages.sh: Add sudo password prompt
2018-06-20 05:22:13 -04:00
gresearch
acf5ff1a96 install-fedora-packages.sh: Fix inconsistent spacing 2018-06-20 10:17:45 +01:00
gresearch
71f514d185 install-fedora-packages.sh: Add SUDO password prompt prior to ROOT password prompt in CentOS/Fedora package installs 2018-06-20 10:15:16 +01:00
Michael Larabel
e3e815a451 Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-06-19 19:07:10 -05:00
Michael Larabel
d8a8642f85 use_wine: On tests explicitly using wine as an external dependency, don't preser "_windows" test scripts for execution, reset to original handle. 2018-06-19 19:06:08 -05:00
Michael Larabel
ba6dcafb6f pts-core: Windows browser handling improvements 2018-06-18 09:49:07 -05:00
Michael Larabel
04278d1d5c pts-core: Rework commit from earlier today 2018-06-16 17:14:53 -05:00
Michael Larabel
6d2542d4ee pts-core: Fix for system log saving on Windows 2018-06-16 16:19:52 -05:00
Michael Larabel
3ce2bde8b9 pts-core: Don't run chmod process on Windows 2018-06-16 11:27:25 -05:00
Michael Larabel
d964e31c40 pts-core: Better checking of system binaries in external dependency handler 2018-06-16 10:46:50 -05:00
Michael Larabel
abf4772178 pts-core: Don't show "Test Profile Status: " on null string 2018-06-16 09:48:54 -05:00
Michael Larabel
4a9d0170e7 pts-core: Boldness of process string 2018-06-16 09:46:21 -05:00
Michael Larabel
fe58e75f72 pts-core: Ensure files for all platforms are cached on running make-download-cache 2018-06-16 09:38:55 -05:00
Michael Larabel
a626830375 pts-core: Don't prompt on failed downloads within make-download-cache 2018-06-16 09:33:51 -05:00
Michael Larabel
85b3d2e6c6 windows: Allow space in path to PTS without causing error 2018-06-16 05:22:18 -05:00
Michael Larabel
ee2973c218 pts-core: Fix alignment in CSV output of results 2018-06-14 12:24:50 -05:00
Michael Larabel
c1eee98338 pts-core: tiff-dev dependency fix for Ubuntu 2018-06-12 16:38:52 -05:00
Michael Larabel
606c25aa78 pts-core: Fix renderer logic check 2018-06-12 10:33:11 -05:00
Michael Larabel
e6772ca738 pts-core: Also check for D3D in renderer string as part of Direct3D checking 2018-06-12 09:58:41 -05:00
Michael Larabel
0a1ce03323 pts-core: Only show "Direct3D" options for "renderer" test options when running on Windows/Wine 2018-06-12 09:39:18 -05:00
Michael Larabel
5809354dc8 phodevi: Report wine version in system layer if any test external dependency has wine set 2018-06-12 09:09:46 -05:00
Michael Larabel
940c09ddb4 use_wine: Cleanup previous commit 2018-06-12 08:55:45 -05:00
Michael Larabel
2c12d1f723 use_wine: check for msiexec.exe as well 2018-06-12 08:54:37 -05:00
Michael Larabel
266802527b phodevi: Report Wine version if WINE_VERSION environment variable is set 2018-06-12 08:53:12 -05:00
Michael Larabel
f98563e117 use_wine: Don't run when the test profile is already catered for wine 2018-06-12 08:51:22 -05:00
Michael Larabel
a4581c72b2 pts-core: Add "wine" external dependency support 2018-06-12 08:40:32 -05:00
Michael Larabel
3c936252ca 0002-use_wine-Replace-cygdrive-with-WINEPREFIX-dosdevices 2018-06-12 08:30:54 -05:00
Michael Larabel
7e9124d870 use_wine: Patch from Stefan Dosinger for using WINEPREFIX if set 2018-06-12 08:30:01 -05:00
Michael Larabel
475ef6709e use_wine: Latest updates to get a few more test profiles running... 2018-06-11 20:38:00 -04:00
Michael Larabel
3642106f7d Merge branch 'master' of github.com:phoronix-test-suite/phoronix-test-suite 2018-06-11 19:27:54 -05:00
Michael Larabel
30d212c108 phodevi: Add USE_WINE to system id string so when its value changes, tests are rebuilt 2018-06-11 19:14:02 -05:00
Michael Larabel
4fa5475036 use_wine: New module to use Wine for benchmarks of Windows test scripts on Linux 2018-06-11 18:27:15 -04:00
Michael Larabel
658974ed00 pts-core: Preparations for Wine module, abstracting out some OS queries 2018-06-11 18:25:54 -04:00
Michael Larabel
33a0c9ff05 phodevi: Add USE_WINE environment variable check, point it towards the wine binary you wish to test 2018-06-11 10:25:42 -05:00
Michael Larabel
6fad23f40b phoromatic: Allow system variables to be edited from the system variables page, to address https://github.com/phoronix-test-suite/phoronix-test-suite/issues/264 2018-06-09 09:27:42 -05:00
Michael Larabel
4ab129fa12 phoromatic: fix public comparisons 2018-06-09 09:23:06 -05:00
Michael Larabel
b0683fb654 phoromatic: public viewer improvements 2018-06-09 09:19:49 -05:00
Michael Larabel
9434f3e1fe pts-core: Ensure clean log when adding to the log 2018-06-09 08:57:01 -05:00
Michael Larabel
073d4fe568 phoromatic: Ensure logs are stripped of extra characters before uploading to Phoromatic 2018-06-09 08:51:40 -05:00
Michael Larabel
8daabc9fce pts-core: Minor tweaks 2018-06-08 09:12:09 -05:00
Fatima Sheremetyeva
cc5704555c pts-core: Add csv-individual-frame-times 2018-06-08 09:52:46 -04:00
134 changed files with 3190 additions and 1450 deletions

106
ChangeLog
View File

@@ -1,5 +1,111 @@
PHORONIX TEST SUITE CHANGE-LOG
Phoronix Test Suite 8.4.0-Skiptvet
26 November 2018
phodevi: Various minor tweaks
Phoronix Test Suite 8.4.0 Milestone 3
20 November 2018
pts-core: Various external dependency updates
pts-core: Expose NUM_CPU_PHYSICAL_CORES to test profiles as alternative to NUM_CPU_CORES (logical count)
pts-core: Fix possible situation of openbenchmarking-refresh not updating when IndexCacheTTL is set to 0
pts-core: Allow branded colors to work in the terminal/CLI text graphs
pts-core: Continued POWER9 support improvements
pts-core: Add RemoveInstallDirectoryOnReinstall to toggle test re-installation behavior
pts_Graph: Fix for sometimes tick marker text overlapping
phodevi: Improved physical CPU core detection for architectures like POWER
phodevi: Improved CPU cache size detection
Phoronix Test Suite 8.4.0 Milestone 2
5 November 2018
pts-core: Allow passing PTS environment variables as arguments to PTS and then just have PTS set them in the environment
pts-core: Add dry-run test option
pts-core: Various result parser additions to help parsing of CSV frame-time data for more test profiles (games)
phodevi: Vulkan driver reporting fix
Phoronix Test Suite 8.4.0 Milestone 1
8 October 2018
phodevi: Report vRAM size on GPU model string in GB when over 1GB
pts-core: At run-time also report if test is deprecated/broken
pts-core: Add "node-npm" as an external dependency for Node.js + NPM
phodevi: Drop information reporting support for the long ago Catalyst/fglrx driver stack that hasn't been supported/maintained in many years
Phoronix Test Suite 8.2.0-Rakkestad
11 September 2018
pts-core: Add RequiresDisplay test profile property to indicate if the test profile explicitly requires a monitor / display server to work
pts-core: Add RequiresNetwork test profile property to indicate if the test profile needs a working network connection
pts-core: Add RequiresInternet test profile property to indicate if the test profile needs a working Internet connection
pts-core: Don't install tests where the current run-time checks will fail
phodevi: Improve CPU thread count detection when running under LXC
phodevi: More robust DMI decode ignore value handling
phodevi: Add extra fallback detection for LXC in system-layer
Phoronix Test Suite 8.2.0 Milestone 4
7 September 2018
pts-core: Fix behavior of "Would you like to stop and install these tests now"
pts-core: Add reinstall / re-install aliases to force-install
ob_auto_compare: Default first to trying to do an automated local result comparison
phodevi: Amlogic SoC detection based on meson_cpufreq driver
phodevi: Rockchip SoC fallback detection
phodevi: Embedded ARM Cortex / ARM part model detection
phodevi: Expanded sensor coverage using Intel RAPL
Phoronix Test Suite 8.2.0 Milestone 3
22 August 2018
pts-core: Minor updates to logic for determining how many times to dynamically increase run count on high variance results
pts-core: Show deprecated tests too when running list-all-tests
pts-core: Add DropNoisyResults option if wishing to not save results that have too high of deviation between runs
pts-core: Add PTS_DOWNLOAD_CACHE_OVERRIDE environment variable option on make-download-cache
pts-core: Add PTS_USER_PATH_OVERRIDE environment variable to override PTS_USER_PATH on initialization
pts-core: Add PTS_DOWNLOAD_CACHING_PLATFORM_LIMIT environment variable for make-download-cache
pts-core: Add list-cached-tests option
Phoronix Test Suite 8.2.0 Milestone 2
15 August 2018
pts-core: Add DivideResultDivisor to result parser
pts-core: Add libevent as possible external dependency
pts-core: Alert the user when the test install directory is on a file-system mounted with 'noexec'
pts-core: Optional support with PHP 7.3+ to also obtain network info using net_get_interfaces()
pts-core: Fix possible alignment issue with value/spacer on outputting text-based result graphs
pts-core: When Internet is not available and running list-tests, only show tests that are available via caches unless `list-all-tests` is run
pts-core: Rework `list-recommended-tests` to make use of download count information exposed via OB index repository data rather than needing to make fresh web query
pts-core: Show "popular tests" in the invalid command helper
pts-core: Allow stress-run to be triggered from interactive mode
pts-core: Allow comparing dynamic in-line result comparisons against local results when no Internet results matching or Internet not available
phodevi: Reporting of L1TF / Level 1 Terminal Fault vulnerability
pts_Graph: Tweaks to text sizing on vertical bar graphs
Phoronix Test Suite 8.2.0 Milestone 1
21 July 2018
pts-core: Add readline-based autocompletion support for text-based menu selection lists
pts-core: Add readline-based autocompletion support for the result file save name for trying to match existing result file identifiers
pts-core: Add autocompletion support for result file identifier based on installed software/hardware
pts-core: Various Alpine Linux external dependency updates
pts-core: Various improvements to the Shell sub-command functionality, including auto-completion support
phoromatic: From rootadmin allow the rootadmin to override/reset a user account password
phodevi: Windows battery reporting discharge rate support
phodevi: Improved multi CPU socket reporting on Windows
phodevi: Various hardware/software detection improvements when running within Docker/containers
pgo: New module to provide for automated compiler PGO (Profile Guided Optimizations) testing on GCC/Clang
Phoronix Test Suite 8.0.1-Aremark
26 June 2018
pts-core: Add "wine" external dependency support
pts-core: Fix skip-test behavior
pts-core: Web browser handling improvements on Windows, other Windows updates
phoromatic: Various minor fixes and enhancements
phodevi: Add USE_WINE environment variable check, point it towards the wine binary you wish to test
Phoronix Test Suite 8.0.0-Aremark
5 June 2018

View File

@@ -1,5 +1,5 @@
# Phoronix Test Suite 8.0.0
http://www.phoronix-test-suite.com/
# Phoronix Test Suite 8.4.0
https://www.phoronix-test-suite.com/
The **Phoronix Test Suite** is the most comprehensive testing and benchmarking
platform available for Linux, Solaris, OS X, and BSD operating systems. The

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2016, Phoronix Media
Copyright (C) 2008 - 2016, Michael Larabel
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by

View File

@@ -13,16 +13,13 @@ PHORONIX TEST SUITE PUBLIC TODO LIST:
- Optimus / DRI_PRIME=1 / xrandr --listproviders better GPU detection
- NVIDIA make use of UsedDedicatedGPUMemory as new GPU sensor
- Clean up all the WebSocket code and make it fit to spec
- Incremental result uploads support
- Incremental/streaming result uploads support
- Check with Phodevi's parsers what other tools support JSON outputs - e.g. http://karelzak.blogspot.com/2015/06/json-output-for-basic-tools.html for cleaner parsing
- Figure out why TestClientVersion in result file XML is missing after adding multiple systems, the previous ones are then blank
- Restore the ReferenceID support in the results XML
- Improve titles on tables like in: http://openbenchmarking.org/result/1603172-GA-AMDTONGA973
### PTS-GRAPH ###
- Rotated text alignment for some PNG graphixs is sometimes off by 90/180 degrees compared to SVG, e.g. http://openbenchmarking.org/s/Compiler
- Rotated text alignment for some PNG graphics is sometimes off by 90/180 degrees compared to SVG, e.g. http://openbenchmarking.org/s/Compiler
### OPENBENCHMARKING.ORG ###
@@ -39,7 +36,6 @@ PHORONIX TEST SUITE PUBLIC TODO LIST:
- SIPP [http://sipp.sourceforge.net/]
- oclGaussCrack [https://hashcat.net/oclGaussCrack/]
- http://hashcat.net/oclhashcat/
- Handbrake [http://handbrake.fr/]
- libMicro [https://github.com/portante/libMicro]
- http://markjstock.org/pages/rad_bench.html
- https://code.google.com/p/pyrit/
@@ -48,7 +44,6 @@ PHORONIX TEST SUITE PUBLIC TODO LIST:
- http://sourceforge.net/projects/ffsb/
- http://www.ratgpu.com/
- http://panthema.net/2013/pmbw/
- http://parsec.cs.princeton.edu/parsec3-doc.htm
- http://www.capsl.udel.edu/splash/Download.html
- stephentu/silo
- https://code.google.com/p/smhasher/wiki/SMHasher
@@ -61,6 +56,24 @@ PHORONIX TEST SUITE PUBLIC TODO LIST:
- https://github.com/soumith/convnet-benchmarks
- http://apt.cs.manchester.ac.uk/projects/PAMELA/tools/SLAMBench/
- https://haasn.xyz/posts/2017-10-05-how-to-benchmark-mpvs-raw-throughput.html
- suitesparse http://faculty.cse.tamu.edu/davis/suitesparse.html
- ospray/ospray
- Microsoft/X-Mem
- https://www2.mrc-lmb.cam.ac.uk/relion/index.php?title=Benchmarks_%26_computer_hardware
- kripke
- nekbone
- https://github.com/u39kun/deep-learning-benchmark
- AMG
- CORAL-2 benchmarks
- CompuBench (Windows)
https://github.com/cart/amethyst-bunnymark
rav1e (not yet multithreaded as of Oct 2018)
gnzlbg/aobench
https://github.com/mpicbg-scicomp/gearshifft
https://github.com/hyperledger/caliper
dav1d
RedShift demo
https://wiki.fysik.dtu.dk/gpaw/devel/benchmarks.html
### WEB SOCKET / HTML5 USER INTERFACE WORK ###

View File

@@ -1,4 +1,4 @@
.TH phoronix-test-suite 1 "www.phoronix-test-suite.com" "8.0.0"
.TH phoronix-test-suite 1 "www.phoronix-test-suite.com" "8.4.0"
.SH NAME
phoronix-test-suite \- The Phoronix Test Suite is an extensible open-source platform for performing testing and performance evaluation.
.SH SYNOPSIS
@@ -9,9 +9,28 @@ phoronix-test-suite \- The Phoronix Test Suite is an extensible open-source plat
The **Phoronix Test Suite** is the most comprehensive testing and benchmarking platform available for Linux, Solaris, OS X, and BSD operating systems. The Phoronix Test Suite allows for carrying out tests in a fully automated manner from test installation to execution and reporting. All tests are meant to be easily reproducible, easy-to-use, and support fully automated execution. The Phoronix Test Suite is open-source under the GNU GPLv3 license and is developed by Phoronix Media in cooperation with partners.
.SH OPTIONS
.TP
.SH SYSTEM
.B diagnostics
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
.TP
.B interactive
A simple text-driven interactive interface to the Phoronix Test Suite.
.TP
.B php-conf
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
.TP
.B shell
A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite
.TP
.B system-info
Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.
.TP
.B system-sensors
Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.
.TP
.SH TEST INSTALLATION
.B force-install [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem.
This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem or wishing to re-install test(s) due to compiler or other environmental changes.
.TP
.B install [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will install the selected test(s) inside the testing environment directory. The install process from downloading of the test files to the installation is fully automated. The install option needs to be supplied with the test name or suite as an argument. Optionally, a OpenBenchmarking.org ID or the name of a saved results file can be supplied as well and the test(s) to install will automatically be extracted from that information. If the test is already installed and was run by the latest version of the installation process, no action will be taken. Multiple arguments can be supplied to install additional tests at the same time.
@@ -69,6 +88,9 @@ This option will install the selected test(s) (if needed) and will proceed to ru
.B default-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will run the selected test(s). The name of the test or suite must be supplied or the OpenBenchmarking.org ID or saved local file name. Multiple arguments can be supplied to run additional tests at the same time and save the results in a suite-like fashion. Unlike the normal run option, the default-run will not prompt the user to select from the available test options but will instead use the default options as automatically set by pts-core or the test profile. Use batch-run to automatically test all of the available options.
.TP
.B dry-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option and its arguments pre-set the Phoronix Test Suite batch run mode with enforcing of defaults to not save any results and other behavior intended for a dry/test run. This option is primarily intended for testing/evaluation purposes.
.TP
.B internal-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option and its arguments pre-set the Phoronix Test Suite batch run mode with sane values for carrying out benchmarks in a semi-automated manner and without uploading any of the result data to the public OpenBenchmarking.org.
.TP
@@ -106,38 +128,25 @@ This option can be used for uploading a test profile to your account on OpenBenc
.B upload-test-suite
This option can be used for uploading a test suite to your account on OpenBenchmarking.org. By uploading your test suite to OpenBenchmarking.org, others are then able to browse and access this test suite for easy distribution.
.TP
.SH SYSTEM
.B diagnostics
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
.TP
.B interactive
A simple text-driven interactive interface to the Phoronix Test Suite.
.TP
.B php-conf
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
.TP
.B shell
A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite
.TP
.B system-info
Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.
.TP
.B system-sensors
Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.
.TP
.SH INFORMATION
.B info [Test | Suite | OpenBenchmarking ID | Test Result]
This option will show details about the supplied test, suite, virtual suite, or result file.
.TP
.B list-all-tests
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories. Unlike the other test listing options, list-all-tests will show deprecated tests, potentially broken tests, or other tests not recommended for all environments. The only check in place is ensuring the test profiles are at least compatible with the operating system in use.
.TP
.B list-available-suites
This option will list all test suites that are available from the enabled OpenBenchmarking.org repositories.
.TP
.B list-available-tests
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state.
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state. If the system has no Internet access, it will only list the test profiles where the necesary test assets are available locally on the system or on an available network cache (the same behavior as using the list-cached-tests sub-command), unless using the list-all-tests option to override this behavior.
.TP
.B list-available-virtual-suites
This option will list all available virtual test suites that can be dynamically created based upon the available tests from enabled OpenBenchmarking.org repositories.
.TP
.B list-cached-tests
This option will list all test profiles where any needed test profiles are already cached or available from the local system under test. This is primarily useful if testing offline/behind-the-firewall and other use-cases where wanting to rely only upon local data.
.TP
.B list-installed-dependencies
This option will list all of the packages / external test dependencies that are already installed on the system that the Phoronix Test Suite may potentially depend upon by test profiles.
.TP
@@ -322,15 +331,15 @@ _
.SH SEE ALSO
.B Websites:
.br
http://www.phoronix-test-suite.com/
https://www.phoronix-test-suite.com/
.br
http://commercial.phoronix-test-suite.com/
https://commercial.phoronix-test-suite.com/
.br
http://www.openbenchmarking.org/
https://www.openbenchmarking.org/
.br
http://www.phoronix.com/
https://www.phoronix.com/
.br
http://www.phoronix.com/forums/
https://www.phoronix.com/forums/
.SH AUTHORS
Copyright 2008 - 2018 by Phoronix Media, Michael Larabel.
.TP

File diff suppressed because one or more lines are too long

View File

@@ -20,9 +20,23 @@ The following options are currently supported by the Phoronix Test Suite client.
---
## System
#### diagnostics
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
#### interactive
A simple text-driven interactive interface to the Phoronix Test Suite.
#### php-conf
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
#### shell
A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite
#### system-info
Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.
#### system-sensors
Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.
## Test Installation
#### force-install [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem.
This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem or wishing to re-install test(s) due to compiler or other environmental changes.
#### install [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will install the selected test(s) inside the testing environment directory. The install process from downloading of the test files to the installation is fully automated. The install option needs to be supplied with the test name or suite as an argument. Optionally, a OpenBenchmarking.org ID or the name of a saved results file can be supplied as well and the test(s) to install will automatically be extracted from that information. If the test is already installed and was run by the latest version of the installation process, no action will be taken. Multiple arguments can be supplied to install additional tests at the same time.
#### install-dependencies [Test | Suite | OpenBenchmarking ID | Test Result] ...
@@ -63,6 +77,8 @@ This option is used to configure the batch mode options for the Phoronix Test Su
This option will install the selected test(s) (if needed) and will proceed to run the test(s) in the defaults mode. This option is equivalent to running phoronix-test-suite with the install option followed by the default-run option.
#### default-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option will run the selected test(s). The name of the test or suite must be supplied or the OpenBenchmarking.org ID or saved local file name. Multiple arguments can be supplied to run additional tests at the same time and save the results in a suite-like fashion. Unlike the normal run option, the default-run will not prompt the user to select from the available test options but will instead use the default options as automatically set by pts-core or the test profile. Use batch-run to automatically test all of the available options.
#### dry-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option and its arguments pre-set the Phoronix Test Suite batch run mode with enforcing of defaults to not save any results and other behavior intended for a dry/test run. This option is primarily intended for testing/evaluation purposes.
#### internal-run [Test | Suite | OpenBenchmarking ID | Test Result] ...
This option and its arguments pre-set the Phoronix Test Suite batch run mode with sane values for carrying out benchmarks in a semi-automated manner and without uploading any of the result data to the public OpenBenchmarking.org.
@@ -90,29 +106,19 @@ This option can be used for uploading a test profile to your account on OpenBenc
#### upload-test-suite
This option can be used for uploading a test suite to your account on OpenBenchmarking.org. By uploading your test suite to OpenBenchmarking.org, others are then able to browse and access this test suite for easy distribution.
## System
#### diagnostics
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
#### interactive
A simple text-driven interactive interface to the Phoronix Test Suite.
#### php-conf
This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.
#### shell
A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite
#### system-info
Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.
#### system-sensors
Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.
## Information
#### info [Test | Suite | OpenBenchmarking ID | Test Result]
This option will show details about the supplied test, suite, virtual suite, or result file.
#### list-all-tests
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories. Unlike the other test listing options, list-all-tests will show deprecated tests, potentially broken tests, or other tests not recommended for all environments. The only check in place is ensuring the test profiles are at least compatible with the operating system in use.
#### list-available-suites
This option will list all test suites that are available from the enabled OpenBenchmarking.org repositories.
#### list-available-tests
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state.
This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state. If the system has no Internet access, it will only list the test profiles where the necesary test assets are available locally on the system or on an available network cache (the same behavior as using the list-cached-tests sub-command), unless using the list-all-tests option to override this behavior.
#### list-available-virtual-suites
This option will list all available virtual test suites that can be dynamically created based upon the available tests from enabled OpenBenchmarking.org repositories.
#### list-cached-tests
This option will list all test profiles where any needed test profiles are already cached or available from the local system under test. This is primarily useful if testing offline/behind-the-firewall and other use-cases where wanting to rely only upon local data.
#### list-installed-dependencies
This option will list all of the packages / external test dependencies that are already installed on the system that the Phoronix Test Suite may potentially depend upon by test profiles.
#### list-installed-suites
@@ -297,6 +303,10 @@ This module alerts the user if the system configuration may not be the right one
phoronix-test-suite perf_tips.show
This module utilizes the following environmental variables: SUPPRESS_PERF_TIPS.
### Benchmarking Compiler PGO Impact
This module makes it easy to test a compiler PGO (Profile Guided Optimization) performance impact by running a test without PGO optimizations, capturing the PGO profile, rebuilding the tests with the PGO profile generated, and then repeat the benchmarks.
phoronix-test-suite pgo.benchmark
### Phoromatic Client
The Phoromatic client is used for connecting to a Phoromatic server (Phoromatic.com or a locally run server) to facilitate the automatic running of tests, generally across multiple test nodes in a routine manner. For more details visit http://www.phoromatic.com/. This module is intended to be used with Phoronix Test Suite 5.2+ clients and servers.
phoronix-test-suite phoromatic.connect
@@ -337,6 +347,10 @@ This module utilizes the following environmental variables: HALT_SCREENSAVER.
### Update Checker
This module checks to see if the Phoronix Test Suite -- and its tests and suites -- are up to date.
### Utilize Wine On Linux Benchmarking
This module when activated via the USE_WINE environment variable on Linux systems will override the test profile OS target to Windows and attempt to run the (Windows) tests under Wine, if installed on the system. USE_WINE can be either set to the name of the desired wine command or the absolute path to the wine binary you wish to use for benchmarking.
This module utilizes the following environmental variables: USE_WINE.
### System Event Watchdog
This module has support for stopping/interrupting tests if various system issues occur, like a temperature sensor exceeds a defined threshold.
This module utilizes the following environmental variables: WATCHDOG_SENSOR, WATCHDOG_SENSOR_THRESHOLD.
@@ -609,14 +623,14 @@ This is a collection of test profiles found within the specified OpenBenchmarkin
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing smp.
#### Cuda Tests pts/cuda
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing cuda.
#### Openmp Tests pts/openmp
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing openmp.
#### Python Tests pts/python
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing python.
#### Go Tests pts/go
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing go.
#### Mpi Tests pts/mpi
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing mpi.
#### Openmp Tests pts/openmp
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing openmp.
#### Vdpau Tests pts/vdpau
This is a collection of test profiles found within the specified OpenBenchmarking.org repository where the test profile is specified via an internal tag as testing vdpau.
#### Video Tests pts/video

View File

@@ -5,10 +5,29 @@
</head>
<body>
<p>The following options are currently supported by the Phoronix Test Suite client. A list of available options can also be found by running <em>phoronix-test-suite help.</em><hr></p>
<h1>System</h1>
<h3>diagnostics<em> </em>
</h3>
<p>This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.</p>
<h3>interactive<em> </em>
</h3>
<p>A simple text-driven interactive interface to the Phoronix Test Suite.</p>
<h3>php-conf<em> </em>
</h3>
<p>This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.</p>
<h3>shell<em> </em>
</h3>
<p>A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite</p>
<h3>system-info<em> </em>
</h3>
<p>Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.</p>
<h3>system-sensors<em> </em>
</h3>
<p>Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.</p>
<h1>Test Installation</h1>
<h3>force-install<em> [Test | Suite | OpenBenchmarking ID | Test Result] ...</em>
</h3>
<p>This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem.</p>
<p>This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem or wishing to re-install test(s) due to compiler or other environmental changes.</p>
<h3>install<em> [Test | Suite | OpenBenchmarking ID | Test Result] ...</em>
</h3>
<p>This option will install the selected test(s) inside the testing environment directory. The install process from downloading of the test files to the installation is fully automated. The install option needs to be supplied with the test name or suite as an argument. Optionally, a OpenBenchmarking.org ID or the name of a saved results file can be supplied as well and the test(s) to install will automatically be extracted from that information. If the test is already installed and was run by the latest version of the installation process, no action will be taken. Multiple arguments can be supplied to install additional tests at the same time.</p>
@@ -65,6 +84,9 @@
<h3>default-run<em> [Test | Suite | OpenBenchmarking ID | Test Result] ...</em>
</h3>
<p>This option will run the selected test(s). The name of the test or suite must be supplied or the OpenBenchmarking.org ID or saved local file name. Multiple arguments can be supplied to run additional tests at the same time and save the results in a suite-like fashion. Unlike the normal run option, the default-run will not prompt the user to select from the available test options but will instead use the default options as automatically set by pts-core or the test profile. Use batch-run to automatically test all of the available options.</p>
<h3>dry-run<em> [Test | Suite | OpenBenchmarking ID | Test Result] ...</em>
</h3>
<p>This option and its arguments pre-set the Phoronix Test Suite batch run mode with enforcing of defaults to not save any results and other behavior intended for a dry/test run. This option is primarily intended for testing/evaluation purposes.</p>
<h3>internal-run<em> [Test | Suite | OpenBenchmarking ID | Test Result] ...</em>
</h3>
<p>This option and its arguments pre-set the Phoronix Test Suite batch run mode with sane values for carrying out benchmarks in a semi-automated manner and without uploading any of the result data to the public OpenBenchmarking.org.</p>
@@ -102,38 +124,25 @@
<h3>upload-test-suite<em> </em>
</h3>
<p>This option can be used for uploading a test suite to your account on OpenBenchmarking.org. By uploading your test suite to OpenBenchmarking.org, others are then able to browse and access this test suite for easy distribution.</p>
<h1>System</h1>
<h3>diagnostics<em> </em>
</h3>
<p>This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.</p>
<h3>interactive<em> </em>
</h3>
<p>A simple text-driven interactive interface to the Phoronix Test Suite.</p>
<h3>php-conf<em> </em>
</h3>
<p>This option will print information that is useful to developers when debugging problems with the Phoronix Test Suite and/or test profiles and test suites.</p>
<h3>shell<em> </em>
</h3>
<p>A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite</p>
<h3>system-info<em> </em>
</h3>
<p>Display the installed system hardware and software information as detected by the Phoronix Test Suite Phodevi Library.</p>
<h3>system-sensors<em> </em>
</h3>
<p>Display the installed system hardware and software sensors in real-time as detected by the Phoronix Test Suite Phodevi Library.</p>
<h1>Information</h1>
<h3>info<em> [Test | Suite | OpenBenchmarking ID | Test Result]</em>
</h3>
<p>This option will show details about the supplied test, suite, virtual suite, or result file.</p>
<h3>list-all-tests<em> </em>
</h3>
<p>This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories. Unlike the other test listing options, list-all-tests will show deprecated tests, potentially broken tests, or other tests not recommended for all environments. The only check in place is ensuring the test profiles are at least compatible with the operating system in use.</p>
<h3>list-available-suites<em> </em>
</h3>
<p>This option will list all test suites that are available from the enabled OpenBenchmarking.org repositories.</p>
<h3>list-available-tests<em> </em>
</h3>
<p>This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state.</p>
<p>This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state. If the system has no Internet access, it will only list the test profiles where the necesary test assets are available locally on the system or on an available network cache (the same behavior as using the list-cached-tests sub-command), unless using the list-all-tests option to override this behavior.</p>
<h3>list-available-virtual-suites<em> </em>
</h3>
<p>This option will list all available virtual test suites that can be dynamically created based upon the available tests from enabled OpenBenchmarking.org repositories.</p>
<h3>list-cached-tests<em> </em>
</h3>
<p>This option will list all test profiles where any needed test profiles are already cached or available from the local system under test. This is primarily useful if testing offline/behind-the-firewall and other use-cases where wanting to rely only upon local data.</p>
<h3>list-installed-dependencies<em> </em>
</h3>
<p>This option will list all of the packages / external test dependencies that are already installed on the system that the Phoronix Test Suite may potentially depend upon by test profiles.</p>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -53,18 +53,12 @@ then
elif [ -x /usr/bin/php7 ] || [ -x /usr/local/bin/php7 ] || [ -x /usr/pkg/bin/php7 ]
then
export PHP_BIN="php7"
elif [ -x /usr/bin/php5 ] || [ -x /usr/local/bin/php5 ] || [ -x /usr/pkg/bin/php5 ]
then
export PHP_BIN="php5"
elif [ -x /usr/bin/php ] || [ -x /usr/pkg/bin/php ]
then
export PHP_BIN="php"
elif [ -x /usr/php7/bin/php ]
then
export PHP_BIN="/usr/php7/bin/php"
elif [ -x /usr/php5/bin/php ]
then
export PHP_BIN="/usr/php5/bin/php"
elif [ -x /usr/php/bin/php ]
then
export PHP_BIN="/usr/php/bin/php"
@@ -92,6 +86,12 @@ then
elif which php7 >/dev/null 2>&1 ;
then
export PHP_BIN="php7"
elif [ -x /usr/php5/bin/php ]
then
export PHP_BIN="/usr/php5/bin/php"
elif [ -x /usr/bin/php5 ] || [ -x /usr/local/bin/php5 ] || [ -x /usr/pkg/bin/php5 ]
then
export PHP_BIN="php5"
elif which php5 >/dev/null 2>&1 ;
then
export PHP_BIN="php5"
@@ -135,7 +135,7 @@ elif [ -x /usr/bin/dnf ]
then
# Modern Fedora
echo "The command to likely run for your operating system is: "
echo "# dnf install php-cli php-xml"
echo "# dnf install php-cli php-xml php-json"
echo " "
elif [ -x /usr/bin/yum ]
then
@@ -147,7 +147,7 @@ elif [ -x /usr/bin/pkg_radd ]
then
# BSD
echo "The command to likely run for your operating system is: "
echo "# pkg_radd php5 php5-json php5-zip php5-dom"
echo "# pkg_radd php7 php7-json php7-zip php7-dom"
echo " "
elif [ -x /usr/bin/pacman ]
then
@@ -195,7 +195,7 @@ elif [ -x /sbin/apk ]
then
# Alpine Linux
echo "The command to likely run for your operating system is: "
echo "# apk add php5 php5-dom php5-zip php5-json"
echo "# apk add php7 php7-dom php7-zip php7-json php7-simplexml"
echo " "
elif [ -x /usr/bin/urpmi ]
then
@@ -213,7 +213,7 @@ elif [ -x /usr/sbin/mport ]
then
# MidnightBSD
echo "The command to likely run for your operating system is: "
echo "# mport install php70 php70-dom php70-zip php70-json php70-simplexml"
echo "# mport install php71 php71-dom php71-zip php71-json php71-simplexml"
echo " "
elif [ -x /bin/opkg ]
then

View File

@@ -24,6 +24,11 @@ set PTS_DIR=%~dp0
set PTS_MODE=CLIENT
set PTS_LAUNCHER=%0
:: See if php was setup via Cygwin64, the benefit there is allowing access to PCNTL extensions, etc
:: If exist C:\cygwin64\bin\php.exe (
:: set PHP_BIN=C:\cygwin64\bin\php.exe
:: )
:: TODO: Other work to bring this up to sync with the *NIX phoronix-test-suite launcher
If defined PHP_BIN goto SkipBinSearch
@@ -45,4 +50,4 @@ set PHP_BIN=C:\PHP\php.exe
:SkipBinSearch
%PHP_BIN% %PTS_DIR%\pts-core\phoronix-test-suite.php %*
%PHP_BIN% "%PTS_DIR%\pts-core\phoronix-test-suite.php" %*

View File

@@ -34,8 +34,8 @@ class build_suite implements pts_option_interface
$suite_maintainer = pts_user_io::prompt_user_input('Enter suite maintainer name');
$suite_description = pts_user_io::prompt_user_input('Enter suite description');
$possible_suites = pts_openbenchmarking::available_suites();
$possible_tests = pts_openbenchmarking::available_tests();
$possible_suites = pts_openbenchmarking::available_suites(false);
$possible_tests = pts_openbenchmarking::available_tests(false);
$new_suite = new pts_test_suite();
$new_suite->set_title($suite_name);

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2014, Phoronix Media
Copyright (C) 2008 - 2014, Michael Larabel
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -34,18 +34,18 @@ class diagnostics implements pts_option_interface
continue;
}
echo $constant . ' = ' . $constant_value . PHP_EOL;
echo pts_client::cli_just_bold($constant) . ' = ' . $constant_value . PHP_EOL;
}
echo PHP_EOL . 'Variables That Can Be Used As Result Identifiers / File Names:' . PHP_EOL;
foreach(pts_client::user_run_save_variables() as $var => $var_value)
{
echo $var . ' = ' . $var_value . PHP_EOL;
echo pts_client::cli_just_bold($var) . ' = ' . $var_value . PHP_EOL;
}
echo PHP_EOL . 'Environmental Variables (accessible via test scripts):' . PHP_EOL;
foreach(pts_client::environmental_variables() as $var => $var_value)
{
echo $var . ' = ' . $var_value . PHP_EOL;
echo pts_client::cli_just_bold($var) . ' = ' . $var_value . PHP_EOL;
}
echo PHP_EOL;
}

View File

@@ -0,0 +1,51 @@
<?php
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2013 - 2018, Phoronix Media
Copyright (C) 2013 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class dry_run implements pts_option_interface
{
const doc_section = 'Batch Testing';
const doc_description = 'This option and its arguments pre-set the Phoronix Test Suite batch run mode with enforcing of defaults to not save any results and other behavior intended for a dry/test run. This option is primarily intended for testing/evaluation purposes.';
public static function argument_checks()
{
return array(
new pts_argument_check('VARIABLE_LENGTH', array('pts_types', 'identifier_to_object'), null)
);
}
public static function run($r)
{
pts_test_installer::standard_install($r);
$test_run_manager = new pts_test_run_manager(array(
'UploadResults' => false,
'SaveResults' => false,
'PromptForTestDescription' => false,
'RunAllTestCombinations' => false,
'PromptSaveName' => false,
'PromptForTestIdentifier' => false,
'OpenBrowser' => false
));
$test_run_manager->standard_run($r);
}
}
?>

View File

@@ -28,9 +28,9 @@ class dump_documentation implements pts_option_interface
$html_doc = new pts_html_template(pts_core::program_title(false), 'Test Client Documentation');
$pdf->AddPage();
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/pts-308x160.png', 69, 85, 73, 38, 'PNG', 'http://www.phoronix-test-suite.com/');
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/pts-308x160.png', 69, 85, 73, 38, 'PNG', 'https://www.phoronix-test-suite.com/');
$pdf->Ln(120);
$pdf->WriteStatement('www.phoronix-test-suite.com', 'C', 'http://www.phoronix-test-suite.com/');
$pdf->WriteStatement('www.phoronix-test-suite.com', 'C', 'https://www.phoronix-test-suite.com/');
$pdf->Ln(15);
$pdf->WriteBigHeaderCenter(pts_core::program_title(true));
$pdf->WriteHeaderCenter('User Manual');
@@ -250,7 +250,7 @@ class dump_documentation implements pts_option_interface
$man_page .= '.B ' . trim($option[0] . ' ' . (!empty($option[1]) && is_array($option[1]) ? implode(' ', $option[1]) : null)) . PHP_EOL . $option[2] . PHP_EOL . '.TP' . PHP_EOL;
}
}
$man_page .= '.SH SEE ALSO' . PHP_EOL . '.B Websites:' . PHP_EOL . '.br' . PHP_EOL . 'http://www.phoronix-test-suite.com/' . PHP_EOL . '.br' . PHP_EOL . 'http://commercial.phoronix-test-suite.com/' . PHP_EOL . '.br' . PHP_EOL . 'http://www.openbenchmarking.org/' . PHP_EOL . '.br' . PHP_EOL . 'http://www.phoronix.com/' . PHP_EOL . '.br' . PHP_EOL . 'http://www.phoronix.com/forums/' . PHP_EOL;
$man_page .= '.SH SEE ALSO' . PHP_EOL . '.B Websites:' . PHP_EOL . '.br' . PHP_EOL . 'https://www.phoronix-test-suite.com/' . PHP_EOL . '.br' . PHP_EOL . 'https://commercial.phoronix-test-suite.com/' . PHP_EOL . '.br' . PHP_EOL . 'https://www.openbenchmarking.org/' . PHP_EOL . '.br' . PHP_EOL . 'https://www.phoronix.com/' . PHP_EOL . '.br' . PHP_EOL . 'https://www.phoronix.com/forums/' . PHP_EOL;
$man_page .= '.SH AUTHORS' . PHP_EOL . 'Copyright 2008 - ' . date('Y') . ' by Phoronix Media, Michael Larabel.' . PHP_EOL . '.TP' . PHP_EOL;
file_put_contents(PTS_PATH . 'documentation/man-pages/phoronix-test-suite.1', $man_page);
@@ -258,7 +258,7 @@ class dump_documentation implements pts_option_interface
// simple README
$readme = '# Phoronix Test Suite ' . PTS_VERSION . PHP_EOL . 'http://www.phoronix-test-suite.com/' . PHP_EOL . PHP_EOL;
$readme = '# Phoronix Test Suite ' . PTS_VERSION . PHP_EOL . 'https://www.phoronix-test-suite.com/' . PHP_EOL . PHP_EOL;
$readme .= pts_documentation::basic_description() . PHP_EOL . PHP_EOL;
$readme .= pts_file_io::file_get_contents(PTS_PATH . 'documentation/stubs/readme-basics.txt') . PHP_EOL . PHP_EOL;
$readme = wordwrap($readme, 80, PHP_EOL);
@@ -269,12 +269,12 @@ class dump_documentation implements pts_option_interface
$html_doc = new pts_html_template(pts_core::program_title(false), 'Phoromatic Documentation');
$pdf->AddPage();
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/pts-308x160.png', 69, 85, 73, 38, 'PNG', 'http://www.phoronix-test-suite.com/');
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/pts-308x160.png', 69, 85, 73, 38, 'PNG', 'https://www.phoronix-test-suite.com/');
$pdf->Ln(120);
$pdf->WriteStatement('www.phoronix-test-suite.com', 'C', 'http://www.phoronix-test-suite.com/');
$pdf->WriteStatement('www.phoronix-test-suite.com', 'C', 'https://www.phoronix-test-suite.com/');
$pdf->Ln(15);
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/phoromatic-390x56.png', 55, 250, 0, 0, 'PNG', 'http://www.phoronix-test-suite.com/');
//$pdf->Image(PTS_CORE_STATIC_PATH . 'images/phoromatic-390x56.png', 69, 85, 73, 38, 'PNG', 'http://www.phoromatic.com/');
$pdf->Image(PTS_CORE_STATIC_PATH . 'images/phoromatic-390x56.png', 55, 250, 0, 0, 'PNG', 'https://www.phoronix-test-suite.com/');
//$pdf->Image(PTS_CORE_STATIC_PATH . 'images/phoromatic-390x56.png', 69, 85, 73, 38, 'PNG', 'https://www.phoromatic.com/');
$pdf->WriteBigHeaderCenter(pts_core::program_title(true));
$pdf->WriteHeaderCenter('Phoromatic User Manual');
$pdf->html_to_pdf(PTS_PATH . 'documentation/phoromatic.html');

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2009 - 2016, Phoronix Media
Copyright (C) 2009 - 2016, Michael Larabel
Copyright (C) 2009 - 2018, Phoronix Media
Copyright (C) 2009 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -24,20 +24,8 @@ class dump_possible_options implements pts_option_interface
{
public static function run($r)
{
$options = array();
foreach(pts_file_io::glob(PTS_COMMAND_PATH . '*.php') as $option_php)
{
$name = str_replace('_', '-', basename($option_php, '.php'));
if(!in_array(pts_strings::first_in_string($name, '-'), array('dump', 'debug', 'task')))
{
$options[] = $name;
}
}
$is_true = isset($r[0]) && $r[0] == 'TRUE';
echo implode($is_true ? ' ' : PHP_EOL, $options) . ($is_true ? null : PHP_EOL);
echo implode($is_true ? ' ' : PHP_EOL, pts_client::possible_sub_commands()) . ($is_true ? null : PHP_EOL);
}
}

View File

@@ -23,8 +23,12 @@
class force_install implements pts_option_interface
{
const doc_section = 'Test Installation';
const doc_description = 'This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem.';
const doc_description = 'This option will force the installation (or re-installation) of a test or suite. The arguments and process is similar to the install option but even if the test is installed, the entire installation process will automatically be executed. This option is generally used when debugging a test installation problem or wishing to re-install test(s) due to compiler or other environmental changes.';
public static function command_aliases()
{
return array('reinstall', 're-install');
}
public static function argument_checks()
{
return array(

View File

@@ -175,7 +175,7 @@ class info implements pts_option_interface
// OpenBenchmarking.org Change-Log
if(stripos($o->get_identifier(), 'local/') === false)
if(stripos($o->get_identifier(), 'local/') === false && !defined('PHOROMATIC_PROCESS'))
{
$change_log = pts_openbenchmarking_client::fetch_repository_test_profile_changelog($o->get_identifier(false));
@@ -193,24 +193,27 @@ class info implements pts_option_interface
}
// Recent Test Results With This Test
$o_identifier = $o->get_identifier(false);
$table = array();
foreach(pts_client::saved_test_results() as $saved_results_identifier)
if(!defined('PHOROMATIC_PROCESS'))
{
$result_file = new pts_result_file($saved_results_identifier);
foreach($result_file->get_result_objects() as $result_object)
$o_identifier = $o->get_identifier(false);
$table = array();
foreach(pts_client::saved_test_results() as $saved_results_identifier)
{
if($result_object->test_profile->get_identifier(false) == $o_identifier)
$result_file = new pts_result_file($saved_results_identifier);
foreach($result_file->get_result_objects() as $result_object)
{
$table[] = array(pts_client::cli_just_bold($result_file->get_identifier()), $result_file->get_title());
break;
if($result_object->test_profile->get_identifier(false) == $o_identifier)
{
$table[] = array(pts_client::cli_just_bold($result_file->get_identifier()), $result_file->get_title());
break;
}
}
}
}
if(!empty($table))
{
echo PHP_EOL . pts_client::cli_just_bold('Results Containing This Test') . PHP_EOL;
echo pts_user_io::display_text_table($table);
if(!empty($table))
{
echo PHP_EOL . pts_client::cli_just_bold('Results Containing This Test') . PHP_EOL;
echo pts_user_io::display_text_table($table);
}
}
}
else if($o instanceof pts_result_file)
@@ -218,6 +221,11 @@ class info implements pts_option_interface
echo pts_client::cli_just_bold('Title: ') . $o->get_title() . PHP_EOL . pts_client::cli_just_bold('Identifier: ') . $o->get_identifier() . PHP_EOL;
echo PHP_EOL . pts_client::cli_just_bold('Test Result Identifiers:') . PHP_EOL;
echo pts_user_io::display_text_list($o->get_system_identifiers());
$system_count = count($o->get_system_identifiers());
if($system_count > 8)
{
echo pts_client::cli_just_italic($system_count . ' Systems') . PHP_EOL;
}
$test_titles = array();
foreach($o->get_result_objects() as $result_object)

View File

@@ -35,15 +35,16 @@ class interactive implements pts_option_interface
do
{
$only_show_available_cached_tests = pts_network::internet_support_available() == false;
$options = array(
'RUN_TEST' => 'Run A Test',
'RUN_SUITE' => 'Run A Suite [A Collection Of Tests]',
'RUN_SYSTEM_TEST' => 'Run Complex System Test',
'RUN_TEST' => 'Run A Test / Benchmark',
'RUN_SUITE' => 'Run A Suite [A Collection Of Tests]',
'RUN_STRESS_TEST' => 'Run A Stress Test [Concurrent Benchmarks For Heavy System Load]',
'SHOW_INFO' => 'Show System Hardware / Software Information',
'SHOW_SENSORS' => 'Show Available System Sensors',
'LIST_TESTS' => 'List Available Tests',
'LIST_RECOMMENDED_TESTS' => 'List Recommended Tests',
'SET_RUN_COUNT' => 'Set Test Run Repetition',
// 'SET_RUN_COUNT' => 'Set Test Run Repetition',
'SEARCH' => 'Search Tests / Suites / Results'
);
@@ -58,13 +59,18 @@ class interactive implements pts_option_interface
switch($response)
{
case 'RUN_TEST':
$supported_tests = pts_openbenchmarking::available_tests();
$supported_tests = pts_openbenchmarking::available_tests(!$only_show_available_cached_tests, false, false, false, $only_show_available_cached_tests);
$supported_tests = pts_types::identifiers_to_test_profile_objects($supported_tests, false, true);
$longest_title_length = 0;
foreach($supported_tests as $i => &$test_profile)
{
if($test_profile->get_title() == null)
if($test_profile->get_title() == null || $test_profile->get_license() == 'Retail')
{
unset($supported_tests[$i]);
continue;
}
if(!pts_test_run_manager::test_profile_system_compatibility_check($test_profile))
{
unset($supported_tests[$i]);
continue;
@@ -84,7 +90,7 @@ class interactive implements pts_option_interface
$supported_tests = $t;
asort($supported_tests);
$tests_to_run = pts_user_io::prompt_text_menu('Select Test', $supported_tests, true, true);
$tests_to_run = pts_user_io::prompt_text_menu('Select Test(s)', $supported_tests, true, true);
$tests_to_run = explode(',', $tests_to_run);
pts_test_installer::standard_install($tests_to_run);
$run_manager = new pts_test_run_manager(false, 2);
@@ -94,6 +100,49 @@ class interactive implements pts_option_interface
pts_client::display_web_page(PTS_SAVE_RESULTS_PATH . $run_manager->get_file_name() . '/index.html', null, true, true);
}
break;
case 'RUN_STRESS_TEST':
$supported_tests = pts_openbenchmarking::available_tests(!$only_show_available_cached_tests, false, false, false, $only_show_available_cached_tests);
$supported_tests = pts_types::identifiers_to_test_profile_objects($supported_tests, false, true);
$longest_title_length = 0;
foreach($supported_tests as $i => &$test_profile)
{
if($test_profile->get_title() == null || $test_profile->get_license() == 'Retail')
{
unset($supported_tests[$i]);
continue;
}
if(!pts_test_run_manager::test_profile_system_compatibility_check($test_profile))
{
unset($supported_tests[$i]);
continue;
}
$longest_title_length = max($longest_title_length, strlen($test_profile->get_title()));
}
$t = array();
foreach($supported_tests as $i => &$test_profile)
{
if($test_profile instanceof pts_test_profile)
{
$t[$test_profile->get_identifier()] = sprintf('%-' . ($longest_title_length + 1) . 'ls - %-10ls', $test_profile->get_title(), $test_profile->get_test_hardware_type());
}
}
$supported_tests = $t;
asort($supported_tests);
$tests_to_run = pts_user_io::prompt_text_menu('Select Test(s)', $supported_tests, true, true);
$tests_to_run = explode(',', $tests_to_run);
$concurrent_runs = pts_user_io::prompt_user_input('Number of tests to run concurrently');
putenv('PTS_CONCURRENT_TEST_RUNS=' . trim($concurrent_runs));
$minutes_loop_time = pts_user_io::prompt_user_input('Number of minutes to stress run');
putenv('TOTAL_LOOP_TIME=' . trim($minutes_loop_time));
pts_test_installer::standard_install($tests_to_run);
pts_client::execute_command('stress_run', $tests_to_run);
break;
case 'RUN_SUITE':
$possible_suites = pts_openbenchmarking::available_suites();
@@ -116,17 +165,6 @@ class interactive implements pts_option_interface
case 'SEARCH':
pts_client::execute_command('search');
break;
case 'RUN_SYSTEM_TEST':
pts_client::$display->generic_heading('System Test');
$system_tests = array('apache', 'c-ray', 'ramspeed', 'postmark');
pts_test_installer::standard_install($system_tests);
$run_manager = new pts_test_run_manager(false, 2);
$run_manager->standard_run($system_tests);
if($run_manager != false)
{
pts_client::display_web_page(PTS_SAVE_RESULTS_PATH . $run_manager->get_file_name() . '/index.html', null, true, true);
}
break;
case 'SHOW_INFO':
pts_client::execute_command('system_info');
break;

View File

@@ -0,0 +1,80 @@
<?php
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class list_all_tests implements pts_option_interface
{
const doc_section = 'Information';
const doc_description = 'This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories. Unlike the other test listing options, list-all-tests will show deprecated tests, potentially broken tests, or other tests not recommended for all environments. The only check in place is ensuring the test profiles are at least compatible with the operating system in use.';
public static function run($r)
{
pts_client::$display->generic_heading('Available Tests');
$list_all_tests = pts_client::get_sent_command() == 'list_all_tests';
$only_show_available_cached_tests = !$list_all_tests && pts_network::internet_support_available() == false;
if($only_show_available_cached_tests)
{
echo 'Internet support is not available/enabled, so the Phoronix Test Suite is only listing test profiles where any necessary test assets are already downloaded to the system or available via a network download cache. To override this behavior, use the ' . pts_client::cli_just_bold('phoronix-test-suite list-all-tests') . ' option.' . PHP_EOL . PHP_EOL;
pts_client::execute_command('list_cached_tests');
return true;
}
$test_count = 0;
foreach(pts_openbenchmarking::available_tests(false) as $identifier)
{
$repo = substr($identifier, 0, strpos($identifier, '/'));
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
// Don't show unsupported tests
continue;
}
if($list_all_tests == false && !empty($repo_index['tests'][$id]['status']) && $repo_index['tests'][$id]['status'] != 'Verified')
{
// Don't show unsupported tests
continue;
}
echo sprintf('%-30ls - %-39ls %-9ls', $identifier, $repo_index['tests'][$id]['title'], $repo_index['tests'][$id]['test_type']) . PHP_EOL;
$test_count++;
}
foreach(pts_tests::local_tests() as $identifier)
{
$test_profile = new pts_test_profile($identifier);
if($test_profile->get_title() != null && $test_profile->is_supported(false))
{
echo sprintf('%-30ls - %-39ls %-9ls', $test_profile->get_identifier(), $test_profile->get_title(), $test_profile->get_test_hardware_type()) . PHP_EOL;
$test_count++;
}
}
if($test_count == 0)
{
echo PHP_EOL . 'No tests found. Please check that you have Internet connectivity to download test profile data from OpenBenchmarking.org. The Phoronix Test Suite has documentation on configuring the network setup, proxy settings, and PHP network options. Please contact Phoronix Media if you continuing to experience problems.' . PHP_EOL . PHP_EOL;
}
}
}
?>

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2013, Phoronix Media
Copyright (C) 2008 - 2013, Michael Larabel
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -31,7 +31,7 @@ class list_available_suites implements pts_option_interface
}
public static function run($r)
{
$available_suites = array_merge(pts_openbenchmarking::available_suites(false), pts_tests::local_suites());
$available_suites = pts_tests::all_suites();
pts_client::$display->generic_heading('Available Suites');
if(count($available_suites) > 0)

View File

@@ -23,7 +23,7 @@
class list_available_tests implements pts_option_interface
{
const doc_section = 'Information';
const doc_description = 'This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state.';
const doc_description = 'This option will list all test profiles that are available from the enabled OpenBenchmarking.org repositories where supported on the system and are of a verified state. If the system has no Internet access, it will only list the test profiles where the necesary test assets are available locally on the system or on an available network cache (the same behavior as using the list-cached-tests sub-command), unless using the list-all-tests option to override this behavior.';
public static function command_aliases()
{
@@ -32,14 +32,22 @@ class list_available_tests implements pts_option_interface
public static function run($r)
{
pts_client::$display->generic_heading('Available Tests');
$only_show_available_cached_tests = pts_network::internet_support_available() == false;
if($only_show_available_cached_tests)
{
echo 'Internet support is not available/enabled, so the Phoronix Test Suite is only listing test profiles where any necessary test assets are already downloaded to the system or available via a network download cache. To override this behavior, use the ' . pts_client::cli_just_bold('phoronix-test-suite list-all-tests') . ' option.' . PHP_EOL . PHP_EOL;
pts_client::execute_command('list_cached_tests');
return true;
}
$test_count = 0;
foreach(pts_openbenchmarking::available_tests(false) as $identifier)
{
$repo = substr($identifier, 0, strpos($identifier, '/'));
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::operating_system(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
// Don't show unsupported tests
continue;
@@ -49,8 +57,13 @@ class list_available_tests implements pts_option_interface
// Don't show unsupported tests
continue;
}
if($repo_index['tests'][$id]['test_type'] == 'Graphics' && !phodevi::is_display_server_active())
{
// Don't display graphics tests that can't run
continue;
}
echo sprintf('%-30ls - %-35ls %-9ls', $identifier, $repo_index['tests'][$id]['title'], $repo_index['tests'][$id]['test_type']) . PHP_EOL;
echo sprintf('%-30ls - %-39ls %-9ls', $identifier, $repo_index['tests'][$id]['title'], $repo_index['tests'][$id]['test_type']) . PHP_EOL;
$test_count++;
}
@@ -60,7 +73,7 @@ class list_available_tests implements pts_option_interface
if($test_profile->get_title() != null && $test_profile->is_supported(false))
{
echo sprintf('%-30ls - %-35ls %-9ls', $test_profile->get_identifier(), $test_profile->get_title(), $test_profile->get_test_hardware_type()) . PHP_EOL;
echo sprintf('%-30ls - %-39ls %-9ls', $test_profile->get_identifier(), $test_profile->get_title(), $test_profile->get_test_hardware_type()) . PHP_EOL;
$test_count++;
}
}

View File

@@ -0,0 +1,99 @@
<?php
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class list_cached_tests implements pts_option_interface
{
const doc_section = 'Information';
const doc_description = 'This option will list all test profiles where any needed test profiles are already cached or available from the local system under test. This is primarily useful if testing offline/behind-the-firewall and other use-cases where wanting to rely only upon local data.';
public static function run($r)
{
pts_client::$display->generic_heading('Cached Tests');
$test_count = 0;
foreach(pts_openbenchmarking::available_tests(false) as $identifier)
{
$repo = substr($identifier, 0, strpos($identifier, '/'));
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
// Don't show unsupported tests
continue;
}
if($repo_index['tests'][$id]['test_type'] == 'Graphics' && !phodevi::is_display_server_active())
{
// Don't display graphics tests that can't run
continue;
}
$show = false;
foreach($repo_index['tests'][$id]['versions'] as $version)
{
if(!pts_openbenchmarking::is_test_profile_downloaded($identifier . '-' . $version))
{
// Without Internet, won't be able to download test, so don't show it
continue;
}
$test_profile = new pts_test_profile($identifier . '-' . $version);
if(pts_test_install_request::test_files_available_via_cache($test_profile) == false)
{
// only show tests where files are local or in an available cache
continue;
}
$show = true;
$identifier .= '-' . $version;
break;
}
if($show == false)
{
continue;
}
echo sprintf('%-30ls - %-39ls %-9ls', $identifier, $repo_index['tests'][$id]['title'], $repo_index['tests'][$id]['test_type']) . PHP_EOL;
$test_count++;
}
foreach(pts_tests::local_tests() as $identifier)
{
$test_profile = new pts_test_profile($identifier);
if(pts_test_install_request::test_files_available_via_cache($test_profile) == false)
{
// only show tests where files are local or in an available cache
continue;
}
if($test_profile->get_title() != null && $test_profile->is_supported(false))
{
echo sprintf('%-30ls - %-39ls %-9ls', $test_profile->get_identifier(), $test_profile->get_title(), $test_profile->get_test_hardware_type()) . PHP_EOL;
$test_count++;
}
}
if($test_count == 0)
{
echo PHP_EOL . 'No tests found. Please check that you have Internet connectivity to download test profile data from OpenBenchmarking.org. The Phoronix Test Suite has documentation on configuring the network setup, proxy settings, and PHP network options. Please contact Phoronix Media if you continuing to experience problems.' . PHP_EOL . PHP_EOL;
}
}
}
?>

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2016, Phoronix Media
Copyright (C) 2016, Michael Larabel
Copyright (C) 2016 - 2018, Phoronix Media
Copyright (C) 2016 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -39,7 +39,7 @@ class list_not_installed_tests implements pts_option_interface
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::operating_system(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
// Don't show unsupported tests
continue;

View File

@@ -28,24 +28,47 @@ class list_recommended_tests implements pts_option_interface
public static function run($r)
{
pts_client::$display->generic_heading('Recommended OpenBenchmarking.org Test Profiles');
$test_count = 0;
$recommendation_index = pts_openbenchmarking::make_openbenchmarking_request('recommended_tests_index');
$recommendation_index = json_decode($recommendation_index, true);
foreach($recommendation_index['recommended_tests'] as $subsystem => $tests)
$tests = array();
foreach(pts_openbenchmarking::available_tests(false) as $identifier)
{
pts_client::$display->generic_heading($subsystem . ' Tests');
foreach($tests as $test)
$repo = substr($identifier, 0, strpos($identifier, '/'));
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
echo sprintf('%-32ls - %-35ls', $test['test_profile'], $test['title']) . PHP_EOL;
// Don't show unsupported tests
continue;
}
if(!empty($repo_index['tests'][$id]['status']) && $repo_index['tests'][$id]['status'] != 'Verified')
{
// Don't show unsupported tests
continue;
}
$test_count++;
if($repo_index['tests'][$id]['last_updated'] < (time() - (60 * 60 * 24 * 365)))
{
// Don't show tests not actively maintained
continue;
}
if(!isset($tests[$repo_index['tests'][$id]['test_type']]))
{
$tests[$repo_index['tests'][$id]['test_type']] = array();
}
$tests[$repo_index['tests'][$id]['test_type']][$identifier] = $repo_index['tests'][$id];
}
if($test_count == 0)
foreach($tests as $subsystem => $test_json)
{
echo PHP_EOL . 'No tests found. Please check that you have Internet connectivity to download test profile data from OpenBenchmarking.org. The Phoronix Test Suite has documentation on configuring the network setup, proxy settings, and PHP network options. Please contact Phoronix Media if you continuing to experience problems.' . PHP_EOL . PHP_EOL;
uasort($test_json, array('pts_openbenchmarking_client', 'compare_test_json_download_counts'));
$test_json = array_slice($test_json, 0, 10);
pts_client::$display->generic_heading($subsystem . ' Tests');
foreach($test_json as $identifier => $test_individual_json)
{
echo sprintf('%-30ls - %-39ls', $identifier, $test_individual_json['title']) . PHP_EOL;
}
}
}
}

View File

@@ -45,7 +45,7 @@ class list_unsupported_tests implements pts_option_interface
if($unsupported)
{
echo sprintf('%-28ls - %-30ls %-9ls', $identifier, $unsupported, $repo_index['tests'][$id]['test_type']) . PHP_EOL;
echo sprintf('%-28ls - %-30ls', $identifier, $unsupported) . PHP_EOL;
}
}

View File

@@ -32,6 +32,10 @@ class make_download_cache implements pts_option_interface
// Determine cache location
$dc_write_directory = pts_client::download_cache_path();
if(($dc_override = getenv('PTS_DOWNLOAD_CACHE_OVERRIDE')) != false && is_dir($dc_override))
{
$dc_write_directory = $dc_override;
}
pts_file_io::mkdir($dc_write_directory);
echo PHP_EOL . 'Download Cache Directory: ' . $dc_write_directory . PHP_EOL;
@@ -48,7 +52,7 @@ class make_download_cache implements pts_option_interface
if(count($test_profiles) > 0)
{
echo PHP_EOL . 'Downloading Test Files For: ' . implode(' ', $test_profiles);
pts_test_installer::only_download_test_files($test_profiles, $dc_write_directory);
pts_test_installer::only_download_test_files($test_profiles, $dc_write_directory, getenv('PTS_DOWNLOAD_CACHING_PLATFORM_LIMIT') !== false);
}
}
@@ -62,7 +66,19 @@ class make_download_cache implements pts_option_interface
$test_profile = new pts_test_profile($test);
echo PHP_EOL . pts_client::cli_just_bold('Checking Downloads For: ') . $test . PHP_EOL;
foreach($test_profile->get_downloads() as $file)
if(getenv('PTS_DOWNLOAD_CACHING_PLATFORM_LIMIT') !== false)
{
// Don't get all download files but just those for the given platform
$tr = new pts_test_install_request($test_profile);
$tr->generate_download_object_list(true);
$downloads = $tr->get_download_objects();
}
else
{
$downloads = $test_profile->get_downloads();
}
foreach($downloads as $file)
{
$cached_valid = false;
if(is_file($dc_write_directory . $file->get_filename()) && $file->check_file_hash($dc_write_directory . $file->get_filename()))

View File

@@ -54,7 +54,14 @@ class make_openbenchmarking_cache implements pts_option_interface
$repo_index = pts_openbenchmarking::read_repository_index($repo);
echo $i . '/' . $total_count . ': ' . ($repo_index['tests'][$test]['title'] != null ? $repo_index['tests'][$test]['title'] . ' [' . $repo_index['tests'][$test]['test_type'] . ']' : null) . PHP_EOL;
foreach($repo_index['tests'][$test]['versions'] as $version)
$versions = $repo_index['tests'][$test]['versions'];
if(isset($r[0]) && $r[0] == 'lean')
{
$versions = array(array_shift($versions));
}
foreach($versions as $version)
{
$qualified_identifier = $repo . '/' . $test . '-' . $version;
echo $qualified_identifier;

View File

@@ -33,7 +33,7 @@ class result_file_to_pdf implements pts_option_interface
}
public static function run($r)
{
if(!function_exists('getimagesizefromstring'))
if(!function_exists('getimagesizefromstring') || !extension_loaded('gd'))
{
echo 'PHP GD support is required for this command.' . PHP_EOL . PHP_EOL;
return false;

View File

@@ -145,8 +145,8 @@ class run_random_tests implements pts_option_interface
$test_run_manager->auto_save_results($title, null, 'Various open-source benchmarks by the ' . pts_core::program_title(true) . '.', true);
$test_run_manager->auto_generate_results_identifier();
echo PHP_EOL;
pts_client::$display->generic_sub_heading('Result File: ' . $test_run_manager->get_file_name());
pts_client::$display->generic_sub_heading('Result Identifier: ' . $test_run_manager->get_results_identifier());
pts_client::$display->generic_sub_heading(pts_client::cli_just_bold('Result File: ') . $test_run_manager->get_file_name());
pts_client::$display->generic_sub_heading(pts_client::cli_just_bold('Result Identifier: ') . $test_run_manager->get_results_identifier());
// BENCHMARK
$test_run_manager->pre_execution_process();

View File

@@ -32,6 +32,7 @@ class search implements pts_option_interface
$table = array();
$tests = array();
$results_found = false;
foreach(pts_search::search_test_profiles($search_query) as $test_profile)
{
$table[] = array(pts_client::cli_just_bold($test_profile->get_identifier()), $test_profile->get_title(), $test_profile->get_test_hardware_type());
@@ -45,6 +46,7 @@ class search implements pts_option_interface
}
if(count($table) > 0)
{
$results_found = true;
echo pts_client::cli_colored_text('TEST PROFILES', 'green', true) . PHP_EOL . pts_user_io::display_text_table($table, null, 1) . PHP_EOL . pts_client::cli_colored_text(pts_strings::plural_handler(count($table), 'Test') . ' Matching', 'gray');
$table = array();
@@ -66,6 +68,7 @@ class search implements pts_option_interface
}
if(count($table) > 0)
{
$results_found = true;
echo PHP_EOL . PHP_EOL . pts_client::cli_colored_text('TEST SUITES', 'green', true) . PHP_EOL . pts_user_io::display_text_table($table, null, 1) . PHP_EOL . pts_client::cli_colored_text(pts_strings::plural_handler(count($table), 'Suite') . ' Matching', 'gray');
}
@@ -77,9 +80,15 @@ class search implements pts_option_interface
}
if(count($table) > 0)
{
$results_found = true;
echo PHP_EOL . PHP_EOL . pts_client::cli_colored_text('TEST RESULTS', 'green', true) . PHP_EOL . pts_user_io::display_text_table($table, null, 1) . PHP_EOL . pts_client::cli_colored_text(pts_strings::plural_handler(count($table), 'Test Result') . ' Matching', 'gray');
}
if(!$results_found)
{
echo PHP_EOL . pts_client::cli_just_bold('No Search Matches Found');
}
echo PHP_EOL . PHP_EOL;
}
}

View File

@@ -25,18 +25,87 @@ class shell implements pts_option_interface
const doc_section = 'System';
const doc_description = 'A simple text-driven shell interface / helper to the Phoronix Test Suite. Ideal for those that may be new to the Phoronix Test Suite';
protected static $auto_completion_cache = null;
public static function run($r)
{
pts_openbenchmarking::refresh_repository_lists();
pts_client::$display->generic_heading('Interactive Shell');
echo 'Generating Shell Cache...' . PHP_EOL;
self::$auto_completion_cache = pts_documentation::client_commands_possible_values();
echo 'Refreshing OpenBenchmarking.org Repository Cache...' . PHP_EOL;
pts_openbenchmarking::refresh_repository_lists();
echo phodevi::system_centralized_view();
//echo PHP_EOL . (phodevi::read_property('motherboard', 'serial-number') != null ? PHP_EOL . 'System Serial Number: ' . phodevi::read_property('motherboard', 'serial-number') . PHP_EOL : null);
echo PHP_EOL;
$autocompletion = false;
if(function_exists('readline') && function_exists('readline_completion_function'))
{
$autocompletion = ' Tab auto-completion support available.';
}
$blacklisted_commands = array('shell', 'quit', 'exit');
do
{
self::sensor_overview();
echo PHP_EOL . 'Phoronix Test Suite command to run or ' . pts_client::cli_colored_text('help', 'green') . ' for all possible options, ' . pts_client::cli_colored_text('commands', 'green') . ' for a quick overview of options, ' . pts_client::cli_colored_text('interactive', 'green') . ' for a guided experience, ' . pts_client::cli_colored_text('system-info', 'green') . ' to view system hardware/software information, ' . pts_client::cli_colored_text('exit', 'green') . ' to exit. For new users, ' . pts_client::cli_colored_text('benchmark', 'green') . ' is the simplest and most important sub-command.' . ($autocompletion ? $autocompletion : '') . PHP_EOL;
echo PHP_EOL . pts_client::cli_colored_text((phodevi::is_root() ? '#' : '$'), 'white') . ' ' . pts_client::cli_colored_text('phoronix-test-suite', 'gray') . ' ';
if($autocompletion)
{
readline_completion_function(array('shell', 'shell_auto_completion_handler'));
$input = readline();
}
else
{
$input = pts_user_io::read_user_input();
}
$argv = explode(' ', $input);
if($argv[0] == 'phoronix-test-suite')
{
array_shift($argv);
}
$argc = count($argv);
$sent_command = strtolower(str_replace('-', '_', (isset($argv[0]) ? $argv[0] : null)));
if(!in_array($sent_command, $blacklisted_commands))
{
$passed = pts_client::handle_sent_command($sent_command, $argv, $argc);
if(!$passed)
{
if(empty($argv[0]))
{
echo PHP_EOL . pts_client::cli_colored_text('Enter command to run.', 'red', true) . PHP_EOL;
}
else
{
echo PHP_EOL . pts_client::cli_colored_text('Unsupported command: ' . $argv[0], 'red', true) . PHP_EOL;
}
}
else
{
if($autocompletion)
{
readline_add_history($input);
}
$pass_args = array();
for($i = 1; $i < $argc; $i++)
{
$pass_args[] = $argv[$i];
}
pts_client::execute_command($sent_command, $pass_args); // Run command
}
}
}
while($sent_command != 'exit' && $sent_command != 'quit');
}
protected static function sensor_overview()
{
// SENSORS
$terminal_width = pts_client::terminal_width();
$sensors = array();
foreach(phodevi::supported_sensors(array('cpu_usage', 'cpu_temp', 'sys_temp', 'gpu_usage', 'gpu_temp', 'memory_usage')) as $sensor)
foreach(phodevi::supported_sensors(array('cpu_usage', 'cpu_temp', 'sys_temp', 'sys_power', 'gpu_usage', 'gpu_temp', 'memory_usage')) as $sensor)
{
$supported_devices = call_user_func(array($sensor[2], 'get_supported_devices'));
@@ -54,16 +123,20 @@ class shell implements pts_option_interface
{
$sensor_object = new $sensor[2](0, $device);
$sensor_value = phodevi::read_sensor($sensor_object);
if($sensor_value < 0)
if($sensor_value < 0 || empty($sensor_value))
{
continue;
}
$sensor_name = phodevi::sensor_object_name($sensor_object) . ':';
$sensor_unit = phodevi::read_sensor_object_unit($sensor_object);
$sensor_unit = phodevi::read_sensor_object_unit_short($sensor_object);
$sensors[] = array($sensor_name, $sensor_value, $sensor_unit);
}
}
if(($uptime = phodevi::system_uptime()) > 0)
{
$sensors[] = array('System Uptime', round($uptime / 60), 'M');
}
$longest = array();
foreach($sensors as $ar)
{
@@ -78,6 +151,7 @@ class shell implements pts_option_interface
$sensor_length = array_sum($longest);
$sensors_per_line = floor($terminal_width / $sensor_length);
echo PHP_EOL;
$i = 0;
foreach($sensors as $sensor_data)
{
@@ -93,32 +167,39 @@ class shell implements pts_option_interface
echo PHP_EOL;
// END OF SENSORS
$blacklisted_commands = array('shell', 'quit', 'exit');
do
{
echo PHP_EOL . 'Phoronix Test Suite command to run or ' . pts_client::cli_colored_text('help', 'green') . ' for help, ' . pts_client::cli_colored_text('commands', 'green') . ' for possible options, ' . pts_client::cli_colored_text('interactive', 'green') . ' for a guided experience, ' . pts_client::cli_colored_text('exit', 'green') . ' to exit: ' . PHP_EOL;
echo PHP_EOL . pts_client::cli_colored_text((phodevi::is_root() ? '#' : '$'), 'white') . ' ' . pts_client::cli_colored_text('phoronix-test-suite', 'gray') . ' ';
$input = pts_user_io::read_user_input();
$argv = explode(' ', $input);
if($argv[0] == 'phoronix-test-suite')
{
array_shift($argv);
}
$argc = count($argv);
$sent_command = strtolower(str_replace('-', '_', (isset($argv[0]) ? $argv[0] : null)));
if(!in_array($sent_command, $blacklisted_commands))
{
pts_client::handle_sent_command($sent_command, $argv, $argc);
$pass_args = array();
for($i = 1; $i < $argc; $i++)
{
$pass_args[] = $argv[$i];
}
}
protected static function shell_auto_completion_handler($input)
{
$possibilities = array();
$readline_info = readline_info();
$input = isset($readline_info['end']) ? substr($readline_info['line_buffer'], 0, $readline_info['end']) : $readline_info['line_buffer'];
$input_length = strlen($input);
$possible_sub_commands = pts_client::possible_sub_commands();
pts_client::execute_command($sent_command, $pass_args); // Run command
$argv = explode(' ', trim($input));
if(count($argv) == 1 && !isset(self::$auto_completion_cache[$argv[0]]))
{
foreach($possible_sub_commands as $possibility)
{
if(substr($possibility, 0, $input_length) === $input)
{
$possibilities[] = $possibility;
}
}
}
while($sent_command != 'exit');
else
{
$targeted_sub_command = $argv[0];
if(isset(self::$auto_completion_cache[$argv[0]]))
{
$possibilities = self::$auto_completion_cache[$argv[0]];
}
}
//$possibilities[] = '';
sort($possibilities);
return $possibilities;
}
}

View File

@@ -81,6 +81,7 @@ class winners_and_losers implements pts_option_interface
arsort($winners);
arsort($losers);
echo pts_client::cli_colored_text('TESTS COUNTED: ', 'cyan', true) . $tests_counted . PHP_EOL . PHP_EOL;
echo pts_client::cli_colored_text('WINS:', 'green', true) . PHP_EOL;
$table = array();
foreach($winners as $identifier => $count)

View File

@@ -36,7 +36,7 @@ class microsoft_dependency_handler implements pts_dependency_handler
$cwd = getcwd();
$cygwin_location = self::get_cygwin();
chdir(dirname($cygwin_location));
echo PHP_EOL . 'Configuring Cygwin...' . PHP_EOL;
echo PHP_EOL . 'Configuring Cygwin for handling of some portable test scripts, extracting .tar.gz/xz files, and other script helpers... More details on the Phoronix Test Suite for Windows @ https://github.com/phoronix-test-suite/phoronix-test-suite/blob/master/documentation/phoronix-test-suite-window.md ' . PHP_EOL;
shell_exec(basename($cygwin_location) . ' -q -P unzip -P wget -P bc -P which -W');
chdir($cwd);
}

View File

@@ -3,5 +3,5 @@
# Arch package installation
echo "Please enter your root password below:" 1>&2
su root -c "pacman -Sy --noconfirm --needed $*"
su root -c "pacman -Sy --noconfirm --needed --asdeps $*"
exit

View File

@@ -8,8 +8,12 @@ elif [ -x /usr/bin/dnf ]; then
elif [ `whoami` = "ec2-user" ]; then
sudo yum -y --skip-broken install $*
else
echo "Please enter your root password below:" 1>&2
su root -c "yum -y --skip-broken install $*"
echo "Please enter your SUDO password below:" 1>&2
read -s -p "Password: " passwd
if ! echo $passwd | sudo -S -p '' yum -y --skip-broken install $*; then
echo "Please enter your ROOT password below:" 1>&2
su root -c "yum -y --skip-broken install $*"
fi
fi
exit

View File

@@ -9,6 +9,7 @@ elif [ `whoami` != "root" ] && [ ! -z "$DISPLAY" ]; then
elif [ -x /usr/bin/sudo ]; then
ROOT="/usr/bin/sudo"
fi
$ROOT -- su -c "apt-get -y --ignore-missing install $*"
elif [ -z "$DISPLAY" ]; then
sudo -- apt-get -y --ignore-missing install $*
else
@@ -20,6 +21,4 @@ fi
# aptitude is nice since it doesn't fail if a non-existant package is hit
# See: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=503215
# $ROOT -- "aptitude -y install $*"
#else
$ROOT -- su -c "apt-get -y --ignore-missing install $*"
#fi

View File

@@ -9,8 +9,8 @@
</Information>
<Package>
<GenericName>common-dependencies</GenericName>
<PackageName>unzip</PackageName>
<FileCheck>unzip</FileCheck>
<PackageName>unzip bash</PackageName>
<FileCheck>unzip bash</FileCheck>
</Package>
<Package>
<GenericName>gtk-development</GenericName>
@@ -38,16 +38,12 @@
</Package>
<Package>
<GenericName>build-utilities</GenericName>
<PackageName>gcc make build-base automake autoconf</PackageName>
<PackageName>gcc make build-base automake autoconf linux-headers</PackageName>
</Package>
<Package>
<GenericName>cairo-development</GenericName>
<PackageName>cairo</PackageName>
</Package>
<Package>
<GenericName>xorg-development</GenericName>
<PackageName>xorg-server</PackageName>
</Package>
<Package>
<GenericName>tiff</GenericName>
<PackageName>tiff</PackageName>
@@ -174,7 +170,7 @@
</Package>
<Package>
<GenericName>python</GenericName>
<PackageName>python</PackageName>
<PackageName>python python3</PackageName>
</Package>
<Package>
<GenericName>yasm</GenericName>
@@ -208,5 +204,9 @@
<GenericName>httpd</GenericName>
<PackageName>apache2</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -6,11 +6,6 @@
<Name>Arch Linux</Name>
<PackageManager>pacman</PackageManager>
</Information>
<Package>
<GenericName>common-dependencies</GenericName>
<PackageName>mesa-demos</PackageName>
<FileCheck>glxinfo</FileCheck>
</Package>
<Package>
<GenericName>gtk-development</GenericName>
<PackageName>gtk2</PackageName>
@@ -106,7 +101,7 @@
</Package>
<Package>
<GenericName>zlib-development</GenericName>
<PackageName>zlib1</PackageName>
<PackageName>zlib</PackageName>
</Package>
<Package>
<GenericName>jpeg-development</GenericName>
@@ -116,6 +111,10 @@
<GenericName>bc</GenericName>
<PackageName>bc</PackageName>
</Package>
<Package>
<GenericName>freeimage</GenericName>
<PackageName>freeimage</PackageName>
</Package>
<Package>
<GenericName>perl</GenericName>
<PackageName>perl</PackageName>
@@ -145,6 +144,10 @@
<GenericName>qt4-development</GenericName>
<PackageName>qt4</PackageName>
</Package>
<Package>
<GenericName>qt5-development</GenericName>
<PackageName>qt5-base qt5-examples</PackageName>
</Package>
<Package>
<GenericName>autoconf</GenericName>
<PackageName>autoconf</PackageName>
@@ -209,7 +212,7 @@
</Package>
<Package>
<GenericName>yasm</GenericName>
<PackageName>yasm</PackageName>
<PackageName>yasm nasm</PackageName>
</Package>
<Package>
<GenericName>lib3ds</GenericName>
@@ -239,6 +242,10 @@
<GenericName>openmpi-development</GenericName>
<PackageName>openmpi</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>libevent</PackageName>
</Package>
<Package>
<GenericName>dune</GenericName>
<PackageName>dune-common dune-grid dune-istl</PackageName>
@@ -287,5 +294,17 @@
<GenericName>ruby</GenericName>
<PackageName>ruby</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -230,6 +230,10 @@
<GenericName>redis-server</GenericName>
<PackageName>redis</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>libevent</PackageName>
</Package>
<Package>
<GenericName>opencv</GenericName>
<PackageName>opencv</PackageName>
@@ -246,5 +250,17 @@
<GenericName>ruby</GenericName>
<PackageName>ruby</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -216,5 +216,13 @@
<GenericName>Rscript</GenericName>
<PackageName>R</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -9,8 +9,8 @@
</Information>
<Package>
<GenericName>common-dependencies</GenericName>
<PackageName>unzip</PackageName>
<FileCheck>unzip</FileCheck>
<PackageName>unzip bzip2</PackageName>
<FileCheck>unzip, bzip2</FileCheck>
</Package>
<Package>
<GenericName>32bit-compatibility</GenericName>
@@ -64,7 +64,7 @@
</Package>
<Package>
<GenericName>build-utilities</GenericName>
<PackageName>gcc gcc-c++ make autoconf automake glibc-static patch</PackageName>
<PackageName>gcc gcc-c++ make autoconf automake glibc-static patch expat-devel</PackageName>
<FileCheck>gcc, c++</FileCheck>
</Package>
<Package>
@@ -163,6 +163,10 @@
<GenericName>qt4-development</GenericName>
<PackageName>qt4-devel</PackageName>
</Package>
<Package>
<GenericName>qt5-development</GenericName>
<PackageName>qt5-qtbase-devel qt5-devel</PackageName>
</Package>
<Package>
<GenericName>autoconf</GenericName>
<PackageName>autoconf</PackageName>
@@ -171,6 +175,10 @@
<GenericName>libtool</GenericName>
<PackageName>libtool</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>libevent-devel</PackageName>
</Package>
<Package>
<GenericName>ncurses-development</GenericName>
<PackageName>ncurses-devel</PackageName>
@@ -320,5 +328,17 @@
<GenericName>ruby</GenericName>
<PackageName>ruby</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -247,6 +247,12 @@
<PossibleNames>libqt4-dev, libqt4-devel, qt4-devel</PossibleNames>
<FileCheck>qmake OR qmake-qt4</FileCheck>
</Package>
<Package>
<GenericName>qt5-development</GenericName>
<Title>Qt5 Development Files</Title>
<PossibleNames>libqt5-dev, qt5-devel</PossibleNames>
<FileCheck>qmake</FileCheck>
</Package>
<Package>
<GenericName>autoconf</GenericName>
<Title>Autoconf</Title>
@@ -257,7 +263,13 @@
<GenericName>libtool</GenericName>
<Title>Libtool</Title>
<PossibleNames>libtool</PossibleNames>
<FileCheck>libtool</FileCheck>
<FileCheck>libtool OR libtoolize</FileCheck>
</Package>
<Package>
<GenericName>libevent</GenericName>
<Title>Libevent</Title>
<PossibleNames>libevent, libevent-dev</PossibleNames>
<FileCheck>event.h</FileCheck>
</Package>
<Package>
<GenericName>popt</GenericName>
@@ -495,10 +507,28 @@
<FileCheck>v8.h, libv8.so</FileCheck>
</Package>
<Package>
<GenericName>Ruby</GenericName>
<GenericName>ruby</GenericName>
<Title>Ruby</Title>
<PossibleNames>ruby</PossibleNames>
<FileCheck>ruby</FileCheck>
</Package>
<Package>
<GenericName>wine</GenericName>
<Title>Wine</Title>
<PossibleNames>wine</PossibleNames>
<FileCheck>wine</FileCheck>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<Title>MongoDB</Title>
<PossibleNames>mongodb</PossibleNames>
<FileCheck>mongo</FileCheck>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<Title>Node.js + NPM</Title>
<PossibleNames>npm, nodejs</PossibleNames>
<FileCheck>npm</FileCheck>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -304,9 +304,21 @@
<GenericName>V8</GenericName>
<PackageName>dev-lang/v8</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>dev-libs/libevent</PackageName>
</Package>
<Package>
<GenericName>ruby</GenericName>
<PackageName>dev-lang/ruby</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>virtual/wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>dev-db/mongodb</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -188,5 +188,9 @@
<GenericName>git</GenericName>
<PackageName>git-core</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -263,5 +263,13 @@
<GenericName>perl-digest-md5</GenericName>
<PackageName>perl-Digest-MD5</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -18,17 +18,17 @@
</Package>
<Package>
<GenericName>java</GenericName>
<PackageName>https://github.com/ojdkbuild/ojdkbuild/releases/download/9.0.4-1/java-9-openjdk-9.0.4-1.b11.ojdkbuild.windows.x86_64.msi</PackageName>
<PackageName>https://github.com/ojdkbuild/ojdkbuild/releases/download/10.0.1-1/java-10-openjdk-10.0.1-1.b10.ojdkbuild.windows.x86_64.msi</PackageName>
<FileCheck>C:\Program Files\ojdkbuild OR C:\Program Files\Java</FileCheck>
</Package>
<Package>
<GenericName>golang</GenericName>
<PackageName>https://dl.google.com/go/go1.10.windows-amd64.msi</PackageName>
<PackageName>https://dl.google.com/go/go1.11.windows-amd64.msi</PackageName>
<FileCheck>C:\Go</FileCheck>
</Package>
<Package>
<GenericName>perl</GenericName>
<PackageName>http://strawberryperl.com/download/5.26.1.1/strawberry-perl-5.26.1.1-64bit.msi</PackageName>
<PackageName>http://strawberryperl.com/download/5.28.0.1/strawberry-perl-5.28.0.1-64bit.msi</PackageName>
<FileCheck>C:\Strawberry\perl\bin</FileCheck>
</Package>
<Package>
@@ -38,12 +38,12 @@
</Package>
<Package>
<GenericName>python</GenericName>
<PackageName>https://www.python.org/ftp/python/3.6.4/python-3.6.4-amd64.exe https://www.python.org/ftp/python/2.7.14/python-2.7.14.amd64.msi python2</PackageName>
<PackageName>https://www.python.org/ftp/python/3.7.0/python-3.7.0-amd64.exe https://www.python.org/ftp/python/2.7.15/python-2.7.15.amd64.msi python2</PackageName>
<FileCheck>C:\Python27</FileCheck>
</Package>
<Package>
<GenericName>git</GenericName>
<PackageName>https://github.com/git-for-windows/git/releases/download/v2.16.2.windows.1/Git-2.16.2-64-bit.exe</PackageName>
<PackageName>https://github.com/git-for-windows/git/releases/download/v2.19.0.windows.1/Git-2.19.0-64-bit.exe</PackageName>
<FileCheck>C:\Program Files\Git</FileCheck>
</Package>
<Package>
@@ -61,5 +61,24 @@
<PackageName>cmake</PackageName>
<FileCheck>C:\cygwin64\bin\cmake.exe</FileCheck>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>https://nodejs.org/dist/v10.11.0/node-v10.11.0-x64.msi</PackageName>
<FileCheck>C:\Program Files\nodejs</FileCheck>
</Package>
<Package>
<GenericName>tesseract</GenericName>
<PackageName>https://digi.bib.uni-mannheim.de/tesseract/tesseract-ocr-w64-setup-v4.0.0-beta.4.20180912.exe</PackageName>
<FileCheck>C:\Program Files (x86)\Tesseract-OCR</FileCheck>
</Package>
<Package>
<GenericName>rust</GenericName>
<PackageName>https://static.rust-lang.org/dist/rust-1.29.1-x86_64-pc-windows-msvc.msi</PackageName>
<FileCheck>rustc.exe</FileCheck>
</Package>
<Package>
<GenericName>opencv</GenericName>
<PackageName>https://github.com/opencv/opencv/releases/download/3.4.3/opencv-3.4.3-vc14_vc15.exe</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -306,5 +306,21 @@
<GenericName>ruby</GenericName>
<PackageName>ruby</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>libevent-devel</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>nodejs</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -238,5 +238,9 @@
<PackageName>libgmp3</PackageName>
<FileCheck>/usr/include/gmp.h</FileCheck>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -277,5 +277,9 @@
<PackageName>scikit-learn</PackageName>
<FileCheck>/usr/lib/python2.7/site-packages/sklearn</FileCheck>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -55,7 +55,7 @@
</Package>
<Package>
<GenericName>openssl-development</GenericName>
<PackageName>libssl-dev</PackageName>
<PackageName>libssl1.0-dev</PackageName>
</Package>
<Package>
<GenericName>build-utilities</GenericName>
@@ -73,7 +73,7 @@
</Package>
<Package>
<GenericName>tiff</GenericName>
<PackageName>libtiff-dev</PackageName>
<PackageName>libtiff5-dev</PackageName>
</Package>
<Package>
<GenericName>bison</GenericName>
@@ -183,6 +183,11 @@
<PackageName>libqt4-dev libqt4-opengl-dev</PackageName>
<FileCheck>qmake-qt4, qt4/Qt/qgl.h</FileCheck>
</Package>
<Package>
<GenericName>qt5-development</GenericName>
<PackageName>qml-module-qtquick2 qtdeclarative5-dev qt5-default qtbase5-dev</PackageName>
<FileCheck>qmake</FileCheck>
</Package>
<Package>
<GenericName>autoconf</GenericName>
<PackageName>autoconf</PackageName>
@@ -191,6 +196,10 @@
<GenericName>libtool</GenericName>
<PackageName>libtool</PackageName>
</Package>
<Package>
<GenericName>libevent</GenericName>
<PackageName>libevent-dev</PackageName>
</Package>
<Package>
<GenericName>ncurses-development</GenericName>
<PackageName>libncurses5-dev</PackageName>
@@ -205,7 +214,7 @@
</Package>
<Package>
<GenericName>curl</GenericName>
<PackageName>libcurl3 curl libcurl4-openssl-dev</PackageName>
<PackageName>curl libcurl4-openssl-dev</PackageName>
</Package>
<Package>
<GenericName>fftw3-development</GenericName>
@@ -260,7 +269,7 @@
</Package>
<Package>
<GenericName>python</GenericName>
<PackageName>python python3-pip</PackageName>
<PackageName>python python-pip python3-pip</PackageName>
</Package>
<Package>
<GenericName>python-boost-development</GenericName>
@@ -273,11 +282,11 @@
<Package>
<GenericName>python-numpy</GenericName>
<PackageName>python-numpy</PackageName>
<FileCheck>/usr/share/pyshared/numpy/version.py</FileCheck>
<FileCheck>/usr/share/pyshared/numpy/version.py OR /usr/lib/python2.7/dist-packages/numpy/version.py</FileCheck>
</Package>
<Package>
<GenericName>yasm</GenericName>
<PackageName>yasm</PackageName>
<PackageName>yasm nasm</PackageName>
</Package>
<Package>
<GenericName>gmp-library</GenericName>
@@ -369,5 +378,17 @@
<GenericName>darktable</GenericName>
<PackageName>darktable</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
<Package>
<GenericName>mongodb</GenericName>
<PackageName>mongodb</PackageName>
</Package>
<Package>
<GenericName>node-npm</GenericName>
<PackageName>npm</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -260,5 +260,9 @@
<GenericName>golang</GenericName>
<PackageName>go</PackageName>
</Package>
<Package>
<GenericName>wine</GenericName>
<PackageName>wine</PackageName>
</Package>
</ExternalDependencies>
</PhoronixTestSuite>

View File

@@ -35,7 +35,7 @@ class backup extends pts_module_interface
{
if(!isset($r[0]) || empty($r[0]))
{
echo PHP_EOL . pts_client::cli_just_bold('ERROR:') . 'You must pass the name of the backup file to create and/or any absolute path for the said file you would like to create.' . PHP_EOL . PHP_EOL;
echo PHP_EOL . pts_client::cli_just_bold('ERROR: ') . 'You must pass the name of the backup file to create and/or any absolute path for the said file you would like to create.' . PHP_EOL . PHP_EOL;
return false;
}
$backup_location = $r[0];

View File

@@ -50,18 +50,9 @@ class graphics_override extends pts_module_interface
shell_exec("nvidia-settings --assign " . $attribute . "=" . $value . " 2>&1");
}
}
public static function set_amd_pcsdb($attribute, $value)
{
// Sets a value for AMD's PCSDB, Persistent Configuration Store Database
if(phodevi::is_ati_graphics() && phodevi::is_linux() && !empty($value))
{
$DISPLAY = substr(pts_client::read_env("DISPLAY"), 1, 1);
$info = shell_exec("DISPLAY=:" . $DISPLAY . " aticonfig --set-pcs-val=" . $attribute . "," . $value . " 2>&1");
}
}
public static function __pre_run_process()
{
if(!(phodevi::is_nvidia_graphics() || (phodevi::is_ati_graphics() && phodevi::is_linux())))
if(!phodevi::is_nvidia_graphics())
{
echo "\nNo supported driver found for graphics_override module!\n";
return pts_module::MODULE_UNLOAD; // Not using a supported driver, quit the module
@@ -100,34 +91,6 @@ class graphics_override extends pts_module_interface
self::set_nvidia_extension("FSAAAppControlled", 0);
}
}
else if(phodevi::is_ati_graphics())
{
self::$preset_aa = phodevi_linux_parser::read_amd_pcsdb("OpenGL,AntiAliasSamples");
self::$preset_aa_control = phodevi_linux_parser::read_amd_pcsdb("OpenGL,AAF");
switch($force_aa)
{
case 2:
$ati_aa = "0x00000002";
break;
case 4:
$ati_aa = "0x00000004";
break;
case 8:
$ati_aa = "0x00000008";
break;
case 16:
echo "\nThe ATI fglrx driver currently does not support 16x AA! Defaulting to 8x AA!\n";
$ati_aa = "0x00000008";
break;
}
if(isset($ati_aa))
{
self::set_amd_pcsdb("OpenGL,AntiAliasSamples", $ati_aa);
self::set_amd_pcsdb("OpenGL,AAF", "0x00000000");
}
}
}
if($force_af !== FALSE && in_array($force_af, self::$supported_af_levels))
@@ -160,31 +123,6 @@ class graphics_override extends pts_module_interface
self::set_nvidia_extension("LogAnisoAppControlled", 0);
}
}
else if(phodevi::is_ati_graphics())
{
self::$preset_af = phodevi_linux_parser::read_amd_pcsdb("OpenGL,AnisoDegree");
switch($force_af)
{
case 2:
$ati_af = "0x00000002";
break;
case 4:
$ati_af = "0x00000004";
break;
case 8:
$ati_af = "0x00000008";
break;
case 16:
$ati_af = "0x00000010";
break;
}
if(isset($ati_af))
{
self::set_amd_pcsdb("OpenGL,AnisoDegree", $ati_af);
}
}
}
}
public static function __post_option_process()
@@ -202,18 +140,6 @@ class graphics_override extends pts_module_interface
self::set_nvidia_extension("LogAnisoAppControlled", self::$preset_af_control);
}
}
else if(phodevi::is_ati_graphics())
{
if(self::$preset_aa !== FALSE)
{
self::set_amd_pcsdb("OpenGL,AntiAliasSamples", self::$preset_aa);
self::set_amd_pcsdb("OpenGL,AAF", self::$preset_aa_control);
}
if(self::$preset_af !== FALSE)
{
self::set_amd_pcsdb("OpenGL,AnisoDegree", self::$preset_af);
}
}
}
}

View File

@@ -3,7 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2017, Michael Larabel
Copyright (C) 2017 - 2018, Phoronix Media
Copyright (C) 2017 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -22,11 +23,12 @@
class ob_auto_compare extends pts_module_interface
{
const module_name = 'OpenBenchmarking.org Auto Comparison';
const module_version = '1.0.0';
const module_version = '1.2.0';
const module_description = 'This module prints comparable OpenBenchmarking.org results in the command-line for reference purposes as tests are being run. OpenBenchmarking.org is automatically queried for results to show based on the test comparison hash and the system type (mobile, desktop, server, cloud, workstation, etc). No other system information or result data is transmitted..';
const module_author = 'Michael Larabel';
private static $response_time = 0;
protected static $current_result_file = null;
public static function user_commands()
{
@@ -40,12 +42,13 @@ class ob_auto_compare extends pts_module_interface
return;
}
$result_file = new pts_result_file($r[0]);
self::$current_result_file = $r[0];
foreach($result_file->get_result_objects() as $result_object)
{
echo trim($result_object->test_profile->get_title() . ' ' . $result_object->test_profile->get_app_version() . PHP_EOL . $result_object->get_arguments_description()) . PHP_EOL;
echo 'COMPARISON HASH:' . $result_object->get_comparison_hash(true, false) . PHP_EOL;
echo 'SYSTEM TYPE: ' . phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()) . PHP_EOL;
$auto_comparison_result_file = self::request_compare_from_ob($result_object->get_comparison_hash(), phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()));
$auto_comparison_result_file = self::request_compare($result_object, phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()));
if($auto_comparison_result_file instanceof pts_result_file)
{
@@ -64,9 +67,49 @@ class ob_auto_compare extends pts_module_interface
echo PHP_EOL . PHP_EOL;
}
}
protected static function request_compare(&$result_object, $system_type)
{
$result_file = null;
if(true) // default to see if local comparison first
{
$comparison_hash = $result_object->get_comparison_hash(true, false);
$result_file = self::request_compare_from_local_results($comparison_hash);
}
if(empty($result_file) && pts_network::internet_support_available())
{
$comparison_hash = $result_object->get_comparison_hash();
$result_file = self::request_compare_from_ob($comparison_hash, $system_type);
}
return $result_file;
}
protected static function request_compare_from_local_results($comparison_hash)
{
$saved_results = pts_client::saved_test_results();
shuffle($saved_results);
foreach($saved_results as $tr)
{
$result_file = new pts_result_file($tr);
if(self::$current_result_file != null && self::$current_result_file == $result_file->get_identifier())
{
continue;
}
if($result_file->get_result($comparison_hash) != false)
{
$result_file->set_reference_id($result_file->get_identifier());
return $result_file;
}
}
return null;
}
protected static function request_compare_from_ob($comparison_hash, $system_type)
{
if(!pts_network::internet_support_available() || self::$response_time > 12)
if(!pts_network::internet_support_available() || self::$response_time > 8)
{
// If no network or OB requests are being slow...
return false;
@@ -98,13 +141,14 @@ class ob_auto_compare extends pts_module_interface
{
return pts_module::MODULE_UNLOAD;
}
self::$current_result_file = $test_run_manager->get_file_name();
}
public static function __test_run_success_inline_result($result_object)
{
// Passed is a copy of the successful pts_test_result after showing other inline metrics
if($result_object->test_result_buffer->get_count() < 3)
{
$auto_comparison_result_file = self::request_compare_from_ob($result_object->get_comparison_hash(), phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()));
$auto_comparison_result_file = self::request_compare($result_object, phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()));
if($auto_comparison_result_file instanceof pts_result_file)
{
@@ -112,9 +156,10 @@ class ob_auto_compare extends pts_module_interface
$ro = $auto_comparison_result_file->get_result($merge_ch);
$ro->sort_results_by_performance();
$ro->test_result_buffer->buffer_values_reverse();
echo PHP_EOL.pts_client::cli_just_bold(' OpenBenchmarking.org Dynamic Comparison: ');
$is_ob_comparison = pts_openbenchmarking::is_string_openbenchmarking_result_id_compliant($auto_comparison_result_file->get_reference_id());
echo PHP_EOL.pts_client::cli_just_bold(' ' . ($is_ob_comparison ? 'OpenBenchmarking.org ' : '') . 'Dynamic Comparison: ');
echo pts_result_file_output::test_result_to_text($ro, pts_client::terminal_width(), true, $result_object->test_result_buffer->get_identifiers());
echo PHP_EOL . pts_client::cli_just_bold(' Result Perspective:') . ' https://openbenchmarking.org/result/' . $auto_comparison_result_file->get_reference_id() . PHP_EOL;
echo PHP_EOL . pts_client::cli_just_bold(' Result Perspective:') . ' ' . ($is_ob_comparison ? 'https://openbenchmarking.org/result/' : '') . $auto_comparison_result_file->get_reference_id() . PHP_EOL;
}
}
}

View File

@@ -20,6 +20,11 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
// Possibilities:
// vm.dirty_ratio
// noatime / nobarrier
// transparent_hugepages
class pts_perf_tip_msg
{
public $message;
@@ -117,7 +122,7 @@ class perf_tips extends pts_module_interface
if(stripos($cpu_scaling_governor, 'powersave') !== false)
{
$perf_tips[] = new pts_perf_tip_msg('The powersave CPU scaling governor is currently in use. It\'s possible to obtain greater performance if using the performance governor.', 'echo performance | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor', 'http://openbenchmarking.org/result/1706268-TR-CPUGOVERN32');
$perf_tips[] = new pts_perf_tip_msg('The powersave CPU scaling governor is currently in use. It\'s possible to obtain greater performance if using the performance governor.', 'echo performance | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor', 'https://openbenchmarking.org/result/1706268-TR-CPUGOVERN32');
}
}

116
pts-core/modules/pgo.php Normal file
View File

@@ -0,0 +1,116 @@
<?php
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2018, Phoronix Media
Copyright (C) 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class pgo extends pts_module_interface
{
const module_name = 'Benchmarking Compiler PGO Impact';
const module_version = '1.0.0';
const module_description = 'This module makes it easy to test a compiler PGO (Profile Guided Optimization) performance impact by running a test without PGO optimizations, capturing the PGO profile, rebuilding the tests with the PGO profile generated, and then repeat the benchmarks.';
const module_author = 'Michael Larabel';
protected static $phase = '';
protected static $pgo_storage_dir = '';
protected static $stock_cflags = '';
protected static $stock_cxxflags = '';
public static function user_commands()
{
return array('benchmark' => 'pgo_benchmark');
}
public static function pgo_benchmark($to_run)
{
self::$pgo_storage_dir = pts_client::create_temporary_directory('pgo', true);
echo 'PGO directory is: ' . self::$pgo_storage_dir . PHP_EOL;
self::$stock_cflags = getenv('CFLAGS');
self::$stock_cxxflags = getenv('CXXFLAGS');
// make the initial run manager, collect the result file data we'll need, and run the tests pre-PGO...
$run_manager = new pts_test_run_manager();
$save_name = $run_manager->prompt_save_name();
$result_identifier = $run_manager->prompt_results_identifier();
$run_manager->do_skip_post_execution_options();
// Also force a fresh install before doing any of the PGO-related args...
self::$phase = 'PRE_PGO';
pts_test_installer::standard_install($to_run, true);
// run the tests saving PRE-PGO results
$run_manager->standard_run($to_run);
// force install of tests with PGO generation bits...
self::$phase = 'GENERATE_PGO';
// at least some say serial make ends up being better for PGO generation to not confuse the PGO process, the below override ensures -j 1
pts_client::override_pts_env_var('NUM_CPU_CORES', 1);
pts_client::override_pts_env_var('NUM_CPU_JOBS', 1);
pts_test_installer::standard_install(array($save_name), true);
// restore env vars about CPU core/jobs count
pts_client::unset_pts_env_var_override('NUM_CPU_CORES');
pts_client::unset_pts_env_var_override('NUM_CPU_JOBS');
// run the tests one time each, not saving the results, in order to generate the PGO profiles...
putenv('FORCE_TIMES_TO_RUN=1');
$run_manager = new pts_test_run_manager(array('SaveResults' => false, 'RunAllTestCombinations' => false), true);
$run_manager->standard_run(array($save_name));
putenv('FORCE_TIMES_TO_RUN'); // unset
// force re-install of tests, in process set PGO using bits -fprofile-dir=/data/pgo -fprofile-use=/data/pgo -fprofile-correction
self::$phase = 'USE_PGO';
pts_client::override_pts_env_var('NUM_CPU_CORES', 1);
pts_client::override_pts_env_var('NUM_CPU_JOBS', 1);
pts_test_installer::standard_install(array($save_name), true);
pts_client::unset_pts_env_var_override('NUM_CPU_CORES');
pts_client::unset_pts_env_var_override('NUM_CPU_JOBS');
// run the tests saving results with " - PGO" postfix
$run_manager = new pts_test_run_manager(array('UploadResults' => false, 'SaveResults' => true, 'PromptForTestDescription' => false, 'RunAllTestCombinations' => false, 'PromptSaveName' => true, 'PromptForTestIdentifier' => true, 'OpenBrowser' => true), true);
$run_manager->set_save_name($save_name, false);
$run_manager->set_results_identifier($result_identifier . ' - PGO');
$run_manager->standard_run(array($save_name));
// remove PGO files
pts_file_io::delete(self::$pgo_storage_dir);
}
public static function __pre_test_install($test_install_request)
{
$pgo_dir = self::$pgo_storage_dir . $test_install_request->test_profile->get_identifier() . '/';
pts_file_io::mkdir($pgo_dir);
switch(self::$phase)
{
case 'PRE_PGO':
break;
case 'GENERATE_PGO':
putenv('CFLAGS=' . self::$stock_cflags . ' -fprofile-dir=' . $pgo_dir . ' -fprofile-generate=' . $pgo_dir);
putenv('CXXFLAGS=' . self::$stock_cxxflags . ' -fprofile-dir=' . $pgo_dir . ' -fprofile-generate=' . $pgo_dir);
break;
case 'USE_PGO':
putenv('CFLAGS=' . self::$stock_cflags . ' -fprofile-dir=' . $pgo_dir . ' -fprofile-use=' . $pgo_dir . ' -fprofile-correction');
putenv('CXXFLAGS=' . self::$stock_cxxflags . ' -fprofile-dir=' . $pgo_dir . ' -fprofile-use=' . $pgo_dir . ' -fprofile-correction');
break;
}
}
}
?>

View File

@@ -465,6 +465,7 @@ class phoromatic extends pts_module_interface
$server_setup = self::setup_server_addressing($args);
//$http_comm = new phoromatic_client_comm_http();
/*
if(!$server_setup)
{
if(getenv('PTS_NO_REBOOT_ON_NETWORK_FAILURE') == false && PTS_IS_DAEMONIZED_SERVER_PROCESS)
@@ -474,6 +475,7 @@ class phoromatic extends pts_module_interface
return false;
}
*/
$times_failed = 0;
$has_success = false;
@@ -905,7 +907,7 @@ class phoromatic extends pts_module_interface
$res = phoromatic::upload_to_remote_server(array(
'r' => 'stress_log_upload',
'bid' => self::$benchmark_ticket_id,
'l' => $stress_log
'l' => pts_user_io::strip_ansi_escape_sequences($stress_log)
));
$times_tried++;
@@ -1047,7 +1049,7 @@ class phoromatic extends pts_module_interface
));
}
}
public static function __pre_test_install($test_identifier)
public static function __pre_test_install(&$test_install_request)
{
/* if(self::$has_run_server_setup_func == false)
{
@@ -1065,7 +1067,7 @@ class phoromatic extends pts_module_interface
if(time() > ($last_update_time + 30))
{
phoromatic::update_system_status('Installing: ' . $test_identifier);
phoromatic::update_system_status('Installing: ' . $test_install_request->test_profile->get_identifier());
$last_update_time = time();
}
}

View File

@@ -46,7 +46,7 @@ class system_monitor extends pts_module_interface
private static $cgroup_enabled_controllers = array();
private static $test_run_try_number = null;
private static $sensor_monitoring_frequency = 2;
private static $sensor_monitoring_frequency = 1;
private static $test_run_timer = 0;
private static $perf_per_watt_collection;
@@ -167,7 +167,7 @@ class system_monitor extends pts_module_interface
self::process_perf_per_watt($result_file);
}
if(self::$individual_monitoring != false)
if(self::$individual_monitoring != false && self::$successful_test_run_request)
{
foreach(self::$to_monitor as $sensor)
{

View File

@@ -0,0 +1,227 @@
<?php
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2018, Phoronix Media
Copyright (C) 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class use_wine extends pts_module_interface
{
const module_name = 'Utilize Wine On Linux Benchmarking';
const module_version = '1.0.0';
const module_description = 'This module when activated via the USE_WINE environment variable on Linux systems will override the test profile OS target to Windows and attempt to run the (Windows) tests under Wine, if installed on the system. USE_WINE can be either set to the name of the desired wine command or the absolute path to the wine binary you wish to use for benchmarking.';
const module_author = 'Michael Larabel';
protected static $wine_bin = false;
protected static $original_os_under_test = null;
public static function module_environmental_variables()
{
return array('USE_WINE');
}
public static function __startup()
{
$use_wine = getenv('USE_WINE');
if(is_executable($use_wine) || ($use_wine = pts_client::executable_in_path($use_wine)) !== false)
{
echo pts_client::cli_just_bold('Using Wine For Benchmarks: ') . $use_wine . PHP_EOL;
}
else
{
return pts_module::MODULE_UNLOAD;
}
echo pts_client::cli_just_bold('Wine Version: ') . phodevi::read_property('system', 'wine-version') . PHP_EOL;
$overrode = pts_tests::override_script_test_execution_handler(array('use_wine', 'test_script_handler'));
if(!$overrode)
{
echo 'Failed to override the test script handler.' . PHP_EOL;
return pts_module::MODULE_UNLOAD;
}
// Override the operating system string that is queried by test download/installation code for determining the OS-specific code paths in test profiles...
self::$original_os_under_test = phodevi::os_under_test();
phodevi::os_under_test(true, 'Windows');
// Set $wine_bin to the Wine binary specified via USE_WINE
self::$wine_bin = $use_wine;
}
public static function __pre_test_install(&$test_install_request)
{
// Restore the os_under_test back to the original OS type so it will use its native test script if it's explicitly using Wine...
if(in_array('wine', $test_install_request->test_profile->get_external_dependencies()))
{
phodevi::os_under_test(true, self::$original_os_under_test);
}
}
public static function __post_test_install(&$test_install_request)
{
// Reset the Wine override
if(in_array('wine', $test_install_request->test_profile->get_external_dependencies()))
{
phodevi::os_under_test(true, 'Windows');
}
}
public static function __pre_test_run(&$test_run_request)
{
// Restore the os_under_test back to the original OS type so it will use its native test script if it's explicitly using Wine...
if(in_array('wine', $test_run_request->test_profile->get_external_dependencies()))
{
phodevi::os_under_test(true, self::$original_os_under_test);
}
}
public static function __post_test_run(&$test_run_request)
{
// Reset the Wine override
if(in_array('wine', $test_run_request->test_profile->get_external_dependencies()))
{
phodevi::os_under_test(true, 'Windows');
}
}
public static function test_script_handler($test_directory, $shell, $run_file, $pass_argument, $extra_vars, $test_profile)
{
// Rather than conventional PTS code paths, whenever a pre/install/post/interim test profile script is to be executed, this function will now be called by PTS for its execution
if(in_array('wine', $test_profile->get_external_dependencies()))
{
// The test is a wine-focused test already, so don't try to further re-customize it...
return -1;
}
// Let's make a temporary file in test_directory so we can modify the script before execution....
$new_run_file = dirname($run_file) . '/' . 'wine_' . basename($run_file);
touch($new_run_file);
if(!is_file($run_file))
{
echo 'Problem finding: ' . $run_file . PHP_EOL;
return false;
}
// Let's go through the intended run file line by line and make intended modifications to what's needed for making Wine happy... As we go, write it to the new temporary file
$new_script = '';
foreach(explode(PHP_EOL, pts_file_io::file_get_contents($run_file)) as $line)
{
if($line == null)
{
continue;
}
$words_in_line = pts_strings::trim_explode(' ', $line);
if($words_in_line[0] == 'wine')
{
// if 'wine' is already found in the test profile, assume test is already customized for Wine usage
// reset $new_script to original script
$new_script = pts_file_io::file_get_contents($run_file);
break;
}
// Replace /cygdrive/c/ with $WINEPREFIX/drive_c/
if (stripos($line, '/cygdrive/c/') !== false)
{
if (getenv("WINEPREFIX") !== false)
{
$line = str_replace('/cygdrive/c/', '$WINEPREFIX/drive_c/', $line);
}
else
{
$line = str_replace('/cygdrive/c/', '$HOME/.wine/drive_c/', $line);
}
}
if($words_in_line[0] == 'msiexec' || $words_in_line[0] == 'msiexec.exe')
{
// At least in my tests with unigine-valley, calling its msiexec line didn't work and just silently failed... so let's turn that into running the Wine command.
$line = str_replace(array('msiexec.exe', 'msiexec'), self::$wine_bin, $line);
// Remove potential garbage from line...
$line = str_replace(array('/package', '/passive'), '', $line);
}
else if($words_in_line[0] == 'cmd')
{
$line = self::$wine_bin . ' ' . $line;
$line = str_replace('cmd /c', '', $line);
}
else if($words_in_line[0] == 'cd' && stripos($line, 'C:\\') !== false)
{
// Try to map a Windows C:\ path into correct directory for Wine...
// Trim off the "cd " portion of line
$cd_dir = substr($line, 3);
// Get rid of quotes for now... maybe have to change this...
$cd_dir = str_replace('"', '', $cd_dir);
// Map the drive. Using "dosdevices/c:" would be nicer, but the colon makes
// this an escaping pain.
if (getenv("WINEPREFIX") !== false)
{
$cd_dir = str_replace('C:\\', '$WINEPREFIX/drive_c/', $cd_dir);
}
else
{
$cd_dir = str_replace('C:\\', '$HOME/.wine/drive_c/', $cd_dir);
}
$cd_dir = str_replace('\\ ', ' ', $cd_dir);
$cd_dir = str_replace('\\(', '(', $cd_dir);
$cd_dir = str_replace('\\)', ')', $cd_dir);
// Switch over remaining \ to /
$cd_dir = str_replace('\\', '/', $cd_dir);
// escape necessary characters for path
$cd_dir = str_replace(' ', '\\ ', $cd_dir);
$cd_dir = str_replace(')', '\\)', $cd_dir);
$cd_dir = str_replace('(', '\\(', $cd_dir);
$line = 'cd ' . $cd_dir;
}
else if(stripos($words_in_line[0], '.exe') !== false || stripos($words_in_line[0], '.msi') !== false)
{
// Append wine to start of string that appears to be calling an EXE/MSI executable...
$line = self::$wine_bin . ' ' . $line;
$line = str_replace('cmd /c', '', $line);
}
else if($words_in_line[0] == './\\$@')
{
$line = self::$wine_bin . ' ' . $line;
}
$new_script .= $line . PHP_EOL;
}
// Write out the new temporary test script file...
file_put_contents($new_run_file, $new_script);
shell_exec('chmod +x ' . $new_run_file);
// Do the actual execution of the script... Albeit the script we modified, not the original test profile script
//echo 'cd ' . $test_directory . ' && ' . $shell . ' ' . $new_run_file . ' ' . $pass_argument . ' 2>&1';
$this_result = pts_client::shell_exec('cd ' . $test_directory . ' && ' . $shell . ' ' . $new_run_file . ' ' . $pass_argument . ' 2>&1', $extra_vars);
// Remove the temporary script...
unlink($new_run_file);
// Return the result back to pts-core
return $this_result;
}
}
?>

View File

@@ -158,7 +158,7 @@ class pts_concise_display_mode implements pts_display_mode_interface
}
echo PHP_EOL;
if($test_install_request->test_profile->get_status() != 'Verified')
if($test_install_request->test_profile->get_status() != 'Verified' && $test_install_request->test_profile->get_status() != '')
{
echo $this->tab . $this->tab . 'Test Profile Status: ' . pts_client::cli_just_bold($test_install_request->test_profile->get_status()) . PHP_EOL;
}
@@ -202,10 +202,10 @@ class pts_concise_display_mode implements pts_display_mode_interface
$expected_time = is_numeric($expected_time) && $expected_time > 0 ? pts_strings::format_time($expected_time, 'SECONDS', false, 60) : null;
// TODO: handle if file-name is too long for terminal width
$download_string = $this->tab . $this->tab . $process_string . ': ' . $pts_test_file_download->get_filename();
$download_string = $this->tab . $this->tab . pts_client::cli_just_bold($process_string) . ': ' . $pts_test_file_download->get_filename();
$download_size_string = $pts_test_file_download->get_filesize() > 0 ? ' [' . self::bytes_to_download_size($pts_test_file_download->get_filesize()) . 'MB]' : null;
$offset_length = pts_client::terminal_width() > 1 ? pts_client::terminal_width() : pts_test_file_download::$longest_file_name_length;
$offset_length = $offset_length - strlen($download_string) - strlen($download_size_string) - 2;
$offset_length = $offset_length - strlen(pts_user_io::strip_ansi_escape_sequences($download_string)) - strlen($download_size_string) - 2;
if($offset_length < 2)
{
@@ -219,7 +219,7 @@ class pts_concise_display_mode implements pts_display_mode_interface
$this->progress_line_prefix = $expected_time != null ? 'Estimated Download Time: ' . $expected_time : $progress_prefix;
$this->progress_last_float = -1;
$this->progress_tab_count = 2;
$this->progress_string_length = strlen($download_string);
$this->progress_string_length = strlen(pts_user_io::strip_ansi_escape_sequences($download_string));
}
public function display_interrupt_message($message, $prefix_tag = 'NOTICE', $text_color = 'gray')
{
@@ -325,6 +325,12 @@ class pts_concise_display_mode implements pts_display_mode_interface
$estimated_length = $test_result->test_profile->get_estimated_run_time();
$display_table = array();
if($test_result->test_profile->get_status() != 'Verified' && $test_result->test_profile->get_status() != '')
{
array_push($display_table, array($this->tab . 'Test Profile Status:', pts_client::cli_just_italic($test_result->test_profile->get_status())));
}
array_push($display_table, array($this->tab . 'Estimated Trial Run Count:', $this->expected_trial_run_count));
if($estimated_length > 1 && $estimated_length != $remaining_length)
@@ -545,7 +551,7 @@ class pts_concise_display_mode implements pts_display_mode_interface
}
public function triggered_system_error($level, $message, $file, $line)
{
$error_msg = PHP_EOL . '[' . $level . '] ';
$error_msg = PHP_EOL . $this->tab . '[' . $level . '] ';
if(strpos($message, PHP_EOL) === false)
{
$error_msg .= $message . ' ';

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2009 - 2017, Phoronix Media
Copyright (C) 2009 - 2017, Michael Larabel
Copyright (C) 2009 - 2018, Phoronix Media
Copyright (C) 2009 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -44,7 +44,7 @@ class pts_argument_check
{
return $this->function_return_key;
}
public function __toString()
public function get_function_check_type()
{
if($this->get_function_check() == array('pts_types', 'is_result_file'))
{
@@ -86,11 +86,67 @@ class pts_argument_check
{
$type = 'Unknown Object';
}
return $type;
}
public function __toString()
{
$type = $this->get_function_check_type();
$type = '[' . $type . ']' . (($this->get_argument_index() === 'VARIABLE_LENGTH') ? ' ...' : null);
return $type;
}
protected static function available_tests()
{
$ob_tests = pts_openbenchmarking::available_tests(false);
$base_tests = array();
foreach($ob_tests as $t)
{
$base_tests[] = substr($t, strpos($t, '/') + 1);
}
return array_merge($base_tests, $ob_tests);
}
public function possible_values()
{
$possible_values = array();
if($this->get_function_check() == array('pts_types', 'is_result_file'))
{
$possible_values = pts_client::saved_test_results();
}
else if($this->get_function_check() == array('pts_types', 'identifier_to_object'))
{
$possible_values = array_merge(self::available_tests(), pts_client::saved_test_results(), pts_tests::all_suites(), array_keys(pts_openbenchmarking::result_uploads_from_this_ip()));
}
else if($this->get_function_check() == array('pts_types', 'is_test_or_suite'))
{
$possible_values = array_merge(self::available_tests(), pts_tests::all_suites());
}
else if($this->get_function_check() == array('pts_test_profile', 'is_test_profile'))
{
$possible_values = self::available_tests();
}
else if($this->get_function_check() == array('pts_test_suite', 'is_suite'))
{
$possible_values = pts_tests::all_suites();
}
else if($this->get_function_check() == array('pts_openbenchmarking', 'is_openbenchmarking_result_id'))
{
$possible_values = array_keys(pts_openbenchmarking::result_uploads_from_this_ip());
}
else if($this->get_function_check() == array('pts_result_file', 'is_test_result_file'))
{
$possible_values = pts_client::saved_test_results();
}
else if($this->get_function_check() == array('pts_module', 'is_module'))
{
$possible_values = pts_module_manager::available_modules();
}
return $possible_values;
}
}
?>

View File

@@ -30,6 +30,8 @@ class pts_client
protected static $phoromatic_servers = array();
protected static $debug_mode = false;
protected static $full_output = false;
protected static $override_pts_env_vars = array();
protected static $sent_command = null;
public static function create_lock($lock_file)
{
@@ -47,6 +49,25 @@ class pts_client
chmod($lock_file, 0644);
return self::$lock_pointers[$lock_file] != false && flock(self::$lock_pointers[$lock_file], LOCK_EX | LOCK_NB);
}
public static function possible_sub_commands()
{
static $options = null;
if(empty($options))
{
$options = array();
foreach(pts_file_io::glob(PTS_COMMAND_PATH . '*.php') as $option_php)
{
$name = str_replace('_', '-', basename($option_php, '.php'));
if(!in_array(pts_strings::first_in_string($name, '-'), array('dump', 'debug', 'task')))
{
$options[] = $name;
}
}
}
return $options;
}
public static function is_locked($lock_file)
{
$fp = fopen($lock_file, 'w');
@@ -247,6 +268,7 @@ class pts_client
'PTS_LAUNCHER' => getenv('PTS_LAUNCHER'),
'PHP_BIN' => PHP_BIN,
'NUM_CPU_CORES' => phodevi::read_property('cpu', 'core-count'),
'NUM_CPU_PHYSICAL_CORES' => phodevi::read_property('cpu', 'physical-core-count'),
'NUM_CPU_NODES' => phodevi::read_property('cpu', 'node-count'),
'NUM_CPU_JOBS' => (phodevi::read_property('cpu', 'core-count') * 2),
'SYS_MEMORY' => phodevi::read_property('memory', 'capacity'),
@@ -259,11 +281,13 @@ class pts_client
'OPERATING_SYSTEM' => phodevi::read_property('system', 'vendor-identifier'),
'OS_VERSION' => phodevi::read_property('system', 'os-version'),
'OS_ARCH' => phodevi::read_property('system', 'kernel-architecture'),
'OS_TYPE' => phodevi::operating_system(),
'OS_TYPE' => phodevi::os_under_test(),
'THIS_RUN_TIME' => PTS_INIT_TIME,
'DEBUG_REAL_HOME' => pts_core::user_home_directory(),
'DEBUG_PATH' => pts_client::get_path(),
'SYSTEM_TYPE_ID' => phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()),
'SYSTEM_TYPE' => phodevi_base::system_type_to_string(phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software()))
'SYSTEM_TYPE' => phodevi_base::system_type_to_string(phodevi_base::determine_system_type(phodevi::system_hardware(), phodevi::system_software())),
'TERMINAL_WIDTH' => pts_client::terminal_width(),
);
if(!pts_client::executable_in_path('cc') && pts_client::executable_in_path('gcc') && getenv('CC') == false)
@@ -273,7 +297,18 @@ class pts_client
}
}
return $env_variables;
return array_merge($env_variables, self::$override_pts_env_vars);
}
public static function override_pts_env_var($name, $value)
{
self::$override_pts_env_vars[$name] = $value;
}
public static function unset_pts_env_var_override($name)
{
if(isset(self::$override_pts_env_vars[$name]))
{
unset(self::$override_pts_env_vars[$name]);
}
}
public static function test_install_root_path()
{
@@ -344,6 +379,12 @@ class pts_client
return $supported;
}
public static function hex_color_to_string($hex)
{
$colors = array();
list($colors['red'], $colors['green'], $colors['blue']) = sscanf($hex, "#%02x%02x%02x");
return array_search(max($colors), $colors);
}
public static function cli_colored_text($str, $color, $bold = false)
{
if(!self::supports_colored_text_output() || empty($color))
@@ -356,10 +397,12 @@ class pts_client
'black' => $attribute . ';30',
'gray' => '1;30', // gray not bold doesn't look good in all consoles
'blue' => $attribute . ';34',
'magenta' => $attribute . ';35',
'green' => $attribute . ';32',
'yellow' => $attribute . ';33',
'red' => $attribute . ';31',
'cyan' => $attribute . ';36',
'white' => $attribute . ';37',
);
if(!isset($colors[$color]))
@@ -378,6 +421,15 @@ class pts_client
return "\033[1m$str\033[0m";
}
public static function cli_just_italic($str)
{
if(!self::supports_colored_text_output())
{
return $str;
}
return "\e[3m$str\e[23m";
}
public static function save_test_result($save_to = null, $save_results = null, $render_graphs = true, $result_identifier = null)
{
// Saves PTS result file
@@ -483,7 +535,7 @@ class pts_client
if(($command_bin = pts_client::executable_in_path($command[0])))
{
$cmd_output = shell_exec('cd ' . dirname($command_bin) . ' && ./' . $command_string . ' 2>&1');
$cmd_output = shell_exec('cd "' . dirname($command_bin) . '" && ./' . basename($command_bin) . ' 2>&1');
if(strlen($cmd_output) > 900000)
{
@@ -827,8 +879,10 @@ class pts_client
foreach($ob_relay as $s)
{
$local_ip = pts_network::get_local_ip();
$local_ip_segments = explode('.', $local_ip);
$s_segments = explode('.', $s[0]);
if(substr($local_ip, 0, strrpos($local_ip, '.')) == substr($s[0], 0, strrpos($s[0], '.')))
if($s_segments[0] == $local_ip_segments[0] && $s_segments[1] == $local_ip_segments[1])
{
$possible_servers[] = array($s[0], $s[1]);
}
@@ -1326,12 +1380,11 @@ class pts_client
}
else
{
trigger_error('Phoronix Test Suite Argument Missing.', E_USER_ERROR);
trigger_error('Phoronix Test Suite Argument Missing', E_USER_ERROR);
}
echo PHP_EOL . pts_client::cli_just_bold('CORRECT SYNTAX:') . PHP_EOL . 'phoronix-test-suite ' . str_replace('_', '-', $command_alias) . ' ' . implode(' ', $argument_checks) . PHP_EOL . PHP_EOL;
//sort($pass_args);
pts_tests::invalid_command_helper($pass_args);
echo PHP_EOL . pts_client::cli_just_bold('CORRECT SYNTAX:') . PHP_EOL . 'phoronix-test-suite ' . str_replace('_', '-', $command_alias) . ' ' . pts_client::cli_just_italic(implode(' ', $argument_checks)) . PHP_EOL . PHP_EOL;
pts_tests::invalid_command_helper($pass_args, $argument_checks);
return false;
}
@@ -1371,8 +1424,13 @@ class pts_client
pts_module_manager::module_process('__post_option_process', $command);
}
public static function get_sent_command()
{
return self::$sent_command;
}
public static function handle_sent_command(&$sent_command, &$argv, &$argc)
{
self::$sent_command = $sent_command;
if(is_file(PTS_PATH . 'pts-core/commands/' . $sent_command . '.php') == false)
{
$replaced = false;
@@ -1409,6 +1467,12 @@ class pts_client
$sent_command = 'help';
}
}
else
{
$replaced = true;
}
return $replaced;
}
public static function current_command()
{
@@ -1427,7 +1491,7 @@ class pts_client
// Powershell defaults to 120
$terminal_width = trim(shell_exec('powershell "(get-host).UI.RawUI.MaxWindowSize.width"'));
}
else if(pts_client::read_env('TERMINAL_WIDTH') != false && is_numeric(pts_client::read_env('TERMINAL_WIDTH')) >= 80)
else if(pts_client::read_env('TERMINAL_WIDTH') != false && is_numeric(pts_client::read_env('TERMINAL_WIDTH')) >= 20)
{
$terminal_width = pts_client::read_env('TERMINAL_WIDTH');
}
@@ -1461,13 +1525,51 @@ class pts_client
return $terminal_width;
}
public static function terminal_height()
{
static $terminal_height = null;
if($terminal_height == null)
{
$terminal_height = 12;
if(phodevi::is_windows())
{
$terminal_height = trim(shell_exec('powershell "(get-host).UI.RawUI.MaxWindowSize.height"'));
}
else if(pts_client::executable_in_path('stty'))
{
$th = explode(' ', trim(shell_exec('stty size 2>&1')));
if(count($th) == 2 && is_numeric($th[0]) && $th[0] >= 1)
{
$terminal_height = $th[1];
}
}
else if(pts_client::executable_in_path('tput'))
{
$th = trim(shell_exec('tput lines 2>&1'));
if(is_numeric($th) && $th > 1)
{
$terminal_height = $th;
}
}
}
return $terminal_height;
}
public static function is_process_running($process)
{
$running = null;
if(phodevi::is_linux() && pts_client::executable_in_path('ps'))
{
// Checks if process is running on the system
$running = shell_exec('ps -C ' . strtolower($process) . ' 2>&1');
$running = trim(str_replace(array('PID', 'TTY', 'TIME', 'CMD'), '', $running));
$ps = shell_exec('ps -C ' . strtolower($process) . ' 2>&1');
if(strpos($ps, 'unrecognized option') === false)
{
$running = trim(str_replace(array('PID', 'TTY', 'TIME', 'CMD'), '', $ps));
}
}
else if(phodevi::is_solaris())
{
@@ -1479,11 +1581,10 @@ class pts_client
{
// Checks if process is running on the system
$ps = shell_exec('ps -ax 2>&1');
$running = strpos($ps, strtolower($process)) != false ? 'TRUE' : null;
}
else
{
$running = null;
if(strpos($ps, 'unrecognized option') === false)
{
$running = strpos($ps, strtolower($process)) != false ? 'TRUE' : null;
}
}
return !empty($running);
@@ -1632,6 +1733,10 @@ class pts_client
}
return $path;
}
public static function get_path_separator()
{
return phodevi::is_windows() ? ';' : ':';
}
public static function executable_in_path($executable, $ignore_paths_with = false)
{
static $cache = null;
@@ -1639,7 +1744,7 @@ class pts_client
if(!isset($cache[$executable]) || empty($cache[$executable]) || $ignore_paths_with)
{
$path = pts_client::get_path();
$paths = pts_strings::trim_explode((phodevi::is_windows() ? ';' : ':'), $path);
$paths = pts_strings::trim_explode(pts_client::get_path_separator(), $path);
$executable_path = false;
foreach($paths as $path)
@@ -1676,7 +1781,7 @@ class pts_client
}
public static function display_web_page($URL, $alt_text = null, $default_open = true, $auto_open = false)
{
if((pts_client::read_env('DISPLAY') == false && pts_client::read_env('WAYLAND_DISPLAY') == false && phodevi::is_windows() == false && phodevi::is_macosx() == false) || defined('PHOROMATIC_PROCESS'))
if(!phodevi::is_display_server_active() || defined('PHOROMATIC_PROCESS'))
{
return;
}
@@ -1707,7 +1812,7 @@ class pts_client
$windows_browsers = array(
'C:\Program Files (x86)\Google\Chrome\Application\chrome.exe',
'C:\Program Files (x86)\Mozilla Firefox\firefox.exe',
'C:\Program Files\internet explorer\iexplore.exe'
//'C:\Program Files\internet explorer\iexplore.exe'
);
foreach($windows_browsers as $browser_test)
@@ -1718,13 +1823,31 @@ class pts_client
break;
}
}
$browser = escapeshellarg($browser);
if(!empty($browser))
{
$browser = escapeshellarg($browser);
}
if(substr($URL, 0, 1) == '\\')
{
$URL = 'file:///C:' . str_replace('/', '\\', $URL);
}
else if(substr($URL, 0, 2) == 'C:')
{
$URL = 'file:///' . str_replace('//', '/', str_replace('\\', '/', $URL));
}
shell_exec($browser . ' "' . $URL . '"');
if(empty($browser))
{
// should allow the browser to be opened in Edge
shell_exec('start ' . $URL . '');
}
else
{
shell_exec($browser . ' "' . $URL . '"');
}
return;
}
else

View File

@@ -124,6 +124,7 @@ class pts_config
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/TestResultValidation/StandardDeviationThreshold', $read_config);
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/TestResultValidation/ExportResultsTo', $read_config);
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/TestResultValidation/MinimalTestTime', $read_config);
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/TestResultValidation/DropNoisyResults', $read_config);
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/BatchMode/SaveResults', $read_config);
$config->addXmlNodeFromReader('PhoronixTestSuite/Options/BatchMode/OpenBrowser', $read_config);

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2009 - 2016, Phoronix Media
Copyright (C) 2009 - 2016, Michael Larabel
Copyright (C) 2009 - 2018, Phoronix Media
Copyright (C) 2009 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -48,7 +48,7 @@ class pts_documentation
}
public static function client_commands_array()
{
$options = array('Test Installation' => array(), 'Testing' => array(), 'Batch Testing' => array(), 'OpenBenchmarking.org' => array(), 'System' => array(), 'Information' => array(), 'Asset Creation' => array(), 'Result Management' => array(), 'Result Analytics' => array(), 'Other' => array());
$options = array('System' => array(), 'Test Installation' => array(), 'Testing' => array(), 'Batch Testing' => array(), 'OpenBenchmarking.org' => array(), 'Information' => array(), 'Asset Creation' => array(), 'Result Management' => array(), 'Result Analytics' => array(), 'Other' => array());
foreach(pts_file_io::glob(PTS_COMMAND_PATH . '*.php') as $option_php_file)
{
@@ -89,6 +89,49 @@ class pts_documentation
return $options;
}
public static function client_commands_possible_values()
{
static $commands_possible_values = null;
if(empty($commands_possible_values))
{
foreach(pts_file_io::glob(PTS_COMMAND_PATH . '*.php') as $option_php_file)
{
$option_php = basename($option_php_file, '.php');
$name = str_replace('_', '-', $option_php);
if(!in_array(pts_strings::first_in_string($name, '-'), array('task')))
{
include_once($option_php_file);
$reflect = new ReflectionClass($option_php);
$constants = $reflect->getConstants();
$args = null;
if(method_exists($option_php, 'argument_checks'))
{
$args = call_user_func(array($option_php, 'argument_checks'));
}
$command_aliases = array();
if(method_exists($option_php, 'command_aliases'))
{
$command_aliases = call_user_func(array($option_php, 'command_aliases'));
}
$command_aliases[] = $name;
if(isset($args[0]) && $args[0] instanceof pts_argument_check)
{
$arg_possible_values = $args[0]->possible_values();
foreach($command_aliases as $alias)
{
$commands_possible_values[$alias] = $arg_possible_values;
}
}
}
}
}
return $commands_possible_values;
}
public static function basic_description()
{
return 'The **Phoronix Test Suite** is the most comprehensive testing and benchmarking platform available for Linux, Solaris, OS X, and BSD operating systems. The Phoronix Test Suite allows for carrying out tests in a fully automated manner from test installation to execution and reporting. All tests are meant to be easily reproducible, easy-to-use, and support fully automated execution. The Phoronix Test Suite is open-source under the GNU GPLv3 license and is developed by Phoronix Media in cooperation with partners.';

View File

@@ -392,16 +392,9 @@ class pts_external_dependencies
{
$present = true;
}
else
else if(pts_client::executable_in_path($file))
{
foreach(array('/usr/bin/', '/bin/', '/usr/sbin') as $possible_path)
{
if(is_file($possible_path . $file))
{
$present = true;
break;
}
}
$present = true;
}
if(!$present)
@@ -450,7 +443,7 @@ class pts_external_dependencies
if(substr($file[$i], -2) == '.h' || substr($file[$i], -4) == '.hpp')
{
// May just be a relative header file to look for...
$possible_paths = array('/usr/local/include/', '/usr/target/include/', '/usr/include/', '/usr/include/x86_64-linux-gnu/');
$possible_paths = array('/usr/local/include/', '/usr/target/include/', '/usr/include/', '/usr/include/x86_64-linux-gnu/', '/usr/include/powerpc64le-linux-gnu/');
foreach($possible_paths as $path)
{
if(is_file($path . $file[$i]) || is_link($path . $file[$i]))
@@ -462,7 +455,7 @@ class pts_external_dependencies
else if(strpos($file[$i], '.so') !== false || substr($file[$i], -2) == '.a')
{
// May just be a relative shared library to look for...
$possible_paths = array('/usr/local/lib/', '/usr/lib/', '/usr/lib64/', '/usr/lib/x86_64-linux-gnu/', '/usr/lib/i386-linux-gnu/', '/usr/lib/arm-linux-gnueabihf/');
$possible_paths = array('/usr/local/lib/', '/usr/lib/', '/usr/lib64/', '/usr/lib/x86_64-linux-gnu/', '/usr/lib/i386-linux-gnu/', '/usr/lib/arm-linux-gnueabihf/', '/usr/lib/powerpc64le-linux-gnu/');
if(getenv('LD_LIBRARY_PATH'))
{

View File

@@ -55,7 +55,7 @@ class pts_logger
if(is_writable($log_file))
$this->log_file = $log_file;
}
public function default_log_file_path()
public static function default_log_file_path()
{
if(is_writable('/var/log') && (PTS_MODE == 'WEB_CLIENT' || defined('PHOROMATIC_SERVER') || defined('PTS_IS_DAEMONIZED_SERVER_PROCESS') || getenv('PTS_SERVER_PROCESS')))
$log_file = '/var/log/';
@@ -75,6 +75,7 @@ class pts_logger
if($this->log_file == null)
return;
$message = pts_user_io::strip_ansi_escape_sequences($message);
file_put_contents($this->log_file, ($date_prefix ? '[' . date('M ' . str_pad(date('j'), 2, ' ', STR_PAD_LEFT) . ' H:i:s Y') . '] ' : null) . $message . PHP_EOL, FILE_APPEND);
}
public function get_log_file_size()

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2008 - 2016, Phoronix Media
Copyright (C) 2008 - 2016, Michael Larabel
Copyright (C) 2008 - 2018, Phoronix Media
Copyright (C) 2008 - 2018, Michael Larabel
pts_module_interface.php: The generic Phoronix Test Suite module object that is extended by the specific modules/plug-ins
This program is free software; you can redistribute it and/or modify
@@ -113,12 +113,12 @@ class pts_module_interface
}
public static function __pre_test_install($obj = null)
{
// Passed as the first argument to this function is the test identifier for the name of the test about to be installed
// Passed as the first argument to this function is the test install request for the test about to be installed
return;
}
public static function __post_test_install($obj = null)
{
// Passed as the first argument to this function is the test identifier for the name of the test just installed
// Passed as the first argument to this function is the test install request for the test just installed
return;
}
public static function __post_install_process($obj = null)

View File

@@ -518,6 +518,56 @@ class pts_openbenchmarking_client
return isset($json['openbenchmarking']['gsid']) ? $json['openbenchmarking']['gsid'] : false;
}
public static function compare_test_json_download_counts($a, $b)
{
$a = $a['downloads'];
$b = $b['downloads'];
if($a == $b)
{
return 0;
}
return ($a > $b) ? -1 : 1;
}
public static function most_popular_tests($limit = 10)
{
$only_show_available_cached_tests = pts_network::internet_support_available() == false;
$tests = array();
foreach(pts_openbenchmarking::available_tests(false, false, false, false, $only_show_available_cached_tests) as $identifier)
{
$repo = substr($identifier, 0, strpos($identifier, '/'));
$id = substr($identifier, strlen($repo) + 1);
$repo_index = pts_openbenchmarking::read_repository_index($repo);
if((!empty($repo_index['tests'][$id]['supported_platforms']) && !in_array(phodevi::os_under_test(), $repo_index['tests'][$id]['supported_platforms'])) || empty($repo_index['tests'][$id]['title']))
{
// Don't show unsupported tests
continue;
}
if(!empty($repo_index['tests'][$id]['status']) && $repo_index['tests'][$id]['status'] != 'Verified')
{
// Don't show unsupported tests
continue;
}
if($repo_index['tests'][$id]['last_updated'] < (time() - (60 * 60 * 24 * 365)))
{
// Don't show tests not actively maintained
continue;
}
if($repo_index['tests'][$id]['test_type'] == 'Graphics' && !phodevi::is_display_server_active())
{
// Don't show graphics tests if no display active
continue;
}
$tests[$id] = $repo_index['tests'][$id];
}
uasort($tests, array('pts_openbenchmarking_client', 'compare_test_json_download_counts'));
return array_slice($tests, 0, $limit);
}
}
?>

View File

@@ -121,16 +121,16 @@ class pts_test_execution
{
$execute_binary_prepend = $test_run_request->exec_binary_prepend;
}
else if(getenv('EXECUTE_BINARY_PREPEND') != false)
{
$execute_binary_prepend = getenv('EXECUTE_BINARY_PREPEND') . ' ';
}
else if(getenv('EXECUTE_BINARY_PREPEND') != false)
{
$execute_binary_prepend = getenv('EXECUTE_BINARY_PREPEND') . ' ';
}
if(!$cache_share_present && !$test_run_manager->DEBUG_no_test_execution_just_result_parse && $test_run_request->test_profile->is_root_required())
{
if(phodevi::is_root() == false)
{
pts_client::$display->test_run_error('This test must be run as the root / administrator account.');
pts_client::$display->test_run_error('This test must be run as root / administrator.');
}
$execute_binary_prepend .= ' ' . PTS_CORE_STATIC_PATH . 'root-access.sh ';
@@ -212,6 +212,11 @@ class pts_test_execution
if(!$test_run_manager->DEBUG_no_test_execution_just_result_parse && $restored_from_cache == false)
{
if(!phodevi::is_windows() && is_file($to_execute . '/' . $execute_binary) && !is_executable($to_execute . '/' . $execute_binary) && pts_client::executable_in_path('chmod'))
{
shell_exec('chmod +x ' . $to_execute . '/' . $execute_binary);
}
$test_prepend = getenv('TEST_EXEC_PREPEND') != null ? getenv('TEST_EXEC_PREPEND') . ' ': null;
pts_client::$display->test_run_instance_header($test_run_request);
sleep(1);
@@ -405,10 +410,11 @@ class pts_test_execution
// Dynamically increase run count if needed for statistical significance or other reasons
$first_tr = array_slice($test_run_request->generated_result_buffers, 0, 1);
$first_tr = array_shift($first_tr);
$increase_run_count = $test_run_manager->increase_run_count_check($first_tr->active, $defined_times_to_run, $test_run_time); // XXX maybe check all generated buffers to see if to extend?
$increase_run_count = $test_run_manager->increase_run_count_check($test_run_request, $first_tr->active, $defined_times_to_run); // XXX maybe check all generated buffers to see if to extend?
if($increase_run_count === -1)
{
self::test_run_error($test_run_manager, $test_run_request, 'This run will not be saved due to noisy result.');
$abort_testing = true;
}
else if($increase_run_count == true)

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2010 - 2016, Phoronix Media
Copyright (C) 2010 - 2016, Michael Larabel
Copyright (C) 2010 - 2018, Phoronix Media
Copyright (C) 2010 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -52,14 +52,14 @@ class pts_test_install_manager
return $added;
}
public function generate_download_file_lists()
public function generate_download_file_lists($do_file_checks = true)
{
pts_client::$display->test_install_progress_start('Determining File Requirements');
$test_count = count($this->tests_to_install);
foreach($this->tests_to_install as $i => &$test_install_request)
{
$test_install_request->generate_download_object_list();
$test_install_request->generate_download_object_list($do_file_checks);
pts_client::$display->test_install_progress_update(($i / $test_count));
}
pts_client::$display->test_install_progress_completed();

View File

@@ -71,7 +71,7 @@ class pts_test_install_request
$platforms = $download->get_platform_array();
if(!empty($platforms) && $do_file_checks)
{
if(!in_array(phodevi::operating_system(), $platforms) && !(phodevi::is_bsd() && in_array('Linux', $platforms) && (pts_client::executable_in_path('kldstat') && strpos(shell_exec('kldstat -n linux 2>&1'), 'linux.ko') != false)))
if(!in_array(phodevi::os_under_test(), $platforms) && !(phodevi::is_bsd() && in_array('Linux', $platforms) && (pts_client::executable_in_path('kldstat') && strpos(shell_exec('kldstat -n linux 2>&1'), 'linux.ko') != false)))
{
// This download does not match the operating system
continue;
@@ -91,29 +91,40 @@ class pts_test_install_request
$this->test_files[] = $download;
}
}
public static function test_files_available_locally(&$test_profile, $include_extended_test_profiles = true)
public static function test_files_available_via_cache(&$test_profile, $only_check_local_system = false)
{
static $remote_files, $local_download_caches, $remote_download_caches, $phoromatic_server_caches, $cached = false;
$install_request = new pts_test_install_request($test_profile);
$remote_files = pts_test_install_manager::remote_files_available_in_download_caches();
$local_download_caches = pts_test_install_manager::local_download_caches();
$remote_download_caches = pts_test_install_manager::remote_download_caches();
$phoromatic_server_caches = pts_test_install_manager::phoromatic_download_server_caches();
if($only_check_local_system)
{
$remote_files = false;
$local_download_caches = pts_test_install_manager::local_download_caches();
$remote_download_caches = false;
$phoromatic_server_caches = false;
$cached = false;
}
else if($cached == false)
{
$remote_files = pts_test_install_manager::remote_files_available_in_download_caches();
$local_download_caches = pts_test_install_manager::local_download_caches();
$remote_download_caches = pts_test_install_manager::remote_download_caches();
$phoromatic_server_caches = pts_test_install_manager::phoromatic_download_server_caches();
$cached = true;
}
$install_request->generate_download_object_list();
$install_request->scan_download_caches($local_download_caches, $remote_download_caches, $remote_files, $phoromatic_server_caches);
$all_files_accessible = $install_request->scan_download_caches($local_download_caches, $remote_download_caches, $remote_files, $phoromatic_server_caches, true, true);
foreach($install_request->get_download_objects() as $download_object)
if($all_files_accessible == false)
{
if($download_object->get_download_location_type() == null)
{
return false;
}
return false;
}
foreach($install_request->test_profile->extended_test_profiles() as $extended_test_profile)
{
if(self::test_files_available_locally($extended_test_profile) == false)
if(self::test_files_available_via_cache($extended_test_profile, $only_check_local_system) == false)
{
return false;
}
@@ -121,7 +132,7 @@ class pts_test_install_request
return true;
}
public static function test_files_in_cache(&$test_profile, $include_extended_test_profiles = true, $skip_hash_checks = false)
public static function test_files_available_on_local_system(&$test_profile)
{
// TODO XXX: rework this check into something more versatile for tests that could have files in cache
if(!is_file(PTS_TEST_PROFILE_PATH . $test_profile . '/test-definition.xml'))
@@ -129,33 +140,7 @@ class pts_test_install_request
return false;
}
$install_request = new pts_test_install_request($test_profile);
$remote_files = false;
$local_download_caches = pts_test_install_manager::local_download_caches();
$remote_download_caches = false;
$phoromatic_server_caches = false;
$install_request->generate_download_object_list();
$install_request->scan_download_caches($local_download_caches, $remote_download_caches, $remote_files, $phoromatic_server_caches, $skip_hash_checks);
foreach($install_request->get_download_objects() as $download_object)
{
if($download_object->get_download_location_type() == null)
{
return false;
}
}
foreach($install_request->test_profile->extended_test_profiles() as $extended_test_profile)
{
if(self::test_files_available_locally($extended_test_profile) == false)
{
return false;
}
}
return true;
return self::test_files_available_via_cache($test_profile, true);
}
public static function test_files_in_install_dir(&$test_profile)
{
@@ -173,7 +158,7 @@ class pts_test_install_request
return true;
}
public function scan_download_caches($local_download_caches, $remote_download_caches, $remote_files, $phoromatic_server_caches, $skip_hash_checks = false)
public function scan_download_caches(&$local_download_caches, &$remote_download_caches, &$remote_files, &$phoromatic_server_caches, $skip_extra_checks = false, $only_checking_for_cached_tests = false)
{
$download_location = $this->test_profile->get_install_dir();
$main_download_cache = pts_client::download_cache_path();
@@ -187,7 +172,7 @@ class pts_test_install_request
// File is already there in the test/destination directory, must have been previously downloaded
// Could add an MD5 check here to ensure validity, but if it made it here it was already valid unless user modified it
if($download_package->get_filesize() == 0)
if(!$skip_extra_checks && $download_package->get_filesize() == 0)
{
$download_package->set_filesize(filesize($download_location . $package_filename));
}
@@ -197,7 +182,7 @@ class pts_test_install_request
else if(is_file($main_download_cache . $package_filename))
{
// In main download cache
if($download_package->get_filesize() == 0)
if(!$skip_extra_checks && $download_package->get_filesize() == 0)
{
$download_package->set_filesize(filesize($main_download_cache . $package_filename));
}
@@ -207,7 +192,7 @@ class pts_test_install_request
else if(is_file(PTS_SHARE_PATH . 'download-cache/' . $package_filename))
{
// In system's /usr/share download cache
if($download_package->get_filesize() == 0)
if(!$skip_extra_checks && $download_package->get_filesize() == 0)
{
$download_package->set_filesize(filesize(PTS_SHARE_PATH . 'download-cache/' . $package_filename));
}
@@ -219,9 +204,9 @@ class pts_test_install_request
// Scan the local download caches
foreach($local_download_caches as &$cache_directory)
{
if(is_file($cache_directory . $package_filename) && ($skip_hash_checks || $download_package->check_file_hash($cache_directory . $package_filename)))
if(is_file($cache_directory . $package_filename) && ($skip_extra_checks || $download_package->check_file_hash($cache_directory . $package_filename)))
{
if($download_package->get_filesize() == 0)
if(!$skip_extra_checks && $download_package->get_filesize() == 0)
{
$download_package->set_filesize(filesize($cache_directory . $package_filename));
}
@@ -236,7 +221,7 @@ class pts_test_install_request
$lookaside_copy = pts_test_install_manager::file_lookaside_test_installations($download_package);
if($lookaside_copy)
{
if($download_package->get_filesize() == 0)
if(!$skip_extra_checks && $download_package->get_filesize() == 0)
{
$download_package->set_filesize(filesize($lookaside_copy));
}
@@ -249,7 +234,7 @@ class pts_test_install_request
{
foreach($phoromatic_server_caches as $server_url => $repo)
{
if(isset($repo[$package_filename]) && ($skip_hash_checks || $repo[$package_filename]['md5'] == $download_package->get_md5() || $repo[$package_filename]['sha256'] == $download_package->get_sha256() || ($download_package->get_sha256() == null && $download_package->get_md5() == null)))
if(isset($repo[$package_filename]) && ($skip_extra_checks || $repo[$package_filename]['md5'] == $download_package->get_md5() || $repo[$package_filename]['sha256'] == $download_package->get_sha256() || ($download_package->get_sha256() == null && $download_package->get_md5() == null)))
{
$download_package->set_download_location('REMOTE_DOWNLOAD_CACHE', array($server_url . '/download-cache.php?download=' . $package_filename));
break;
@@ -282,6 +267,16 @@ class pts_test_install_request
}
}
}
if($only_checking_for_cached_tests && $download_package->get_download_location_type() == null)
{
return false;
}
}
if($only_checking_for_cached_tests)
{
return true;
}
}
public function get_arguments_description()

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2010 - 2017, Phoronix Media
Copyright (C) 2010 - 2017, Michael Larabel
Copyright (C) 2010 - 2018, Phoronix Media
Copyright (C) 2010 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -44,6 +44,19 @@ class pts_test_installer
$unknown_tests = array();
$test_profiles = pts_types::identifiers_to_test_profile_objects($items_to_install, true, true, $unknown_tests);
if($force_install == false)
{
foreach($test_profiles as $i => $tp)
{
$valid = pts_test_run_manager::test_profile_system_compatibility_check($tp, true);
if($valid == false)
{
unset($test_profiles[$i]);
}
}
}
// Any external dependencies?
pts_external_dependencies::install_dependencies($test_profiles, $no_prompts, $skip_tests_with_missing_dependencies);
@@ -53,6 +66,12 @@ class pts_test_installer
trigger_error('The test installation directory is not writable.' . PHP_EOL . 'Location: ' . pts_client::test_install_root_path(), E_USER_ERROR);
return false;
}
$mount_options = phodevi::read_property('disk', 'mount-options');
if(isset($mount_options['mount-options']) && strpos($mount_options['mount-options'], 'noexec') !== false)
{
trigger_error('The test installation directory is on a file-system mounted with the \'noexec\' mount option. Re-mount the file-system appropriately or change the Phoronix Test Suite user configuration file to point to an alternative mount point.' . PHP_EOL . 'Location: ' . pts_client::test_install_root_path(), E_USER_ERROR);
return false;
}
pts_test_installer::start_install($test_profiles, $unknown_tests, $force_install, $no_prompts);
pts_client::release_lock($lock_path);
@@ -61,12 +80,6 @@ class pts_test_installer
}
public static function start_install(&$test_profiles, &$unknown_tests = null, $force_install = false, $no_prompts = false)
{
if(count($test_profiles) == 0)
{
trigger_error('No Tests Found For Installation.', E_USER_ERROR);
return false;
}
// Setup the install manager and add the tests
$test_install_manager = new pts_test_install_manager();
$install_table = array();
@@ -99,7 +112,10 @@ class pts_test_installer
{
foreach($unknown_tests as $unknown)
{
$install_table[] = array('Unknown:', $unknown);
if(!empty($unknown))
{
$install_table[] = array('Unknown:', $unknown);
}
}
}
@@ -172,7 +188,7 @@ class pts_test_installer
}
}
}
public static function only_download_test_files(&$test_profiles, $to_dir = null)
public static function only_download_test_files(&$test_profiles, $to_dir = null, $do_file_checks = true)
{
// Setup the install manager and add the tests
$test_install_manager = new pts_test_install_manager();
@@ -191,14 +207,14 @@ class pts_test_installer
}
// Let the pts_test_install_manager make some estimations, etc...
$test_install_manager->generate_download_file_lists();
$test_install_manager->generate_download_file_lists($do_file_checks);
$test_install_manager->check_download_caches_for_files();
// Begin the download process
while(($test_install_request = $test_install_manager->next_in_install_queue()) != false)
{
//pts_client::$display->test_install_start($test_install_request->test_profile->get_identifier());
pts_test_installer::download_test_files($test_install_request, $to_dir);
pts_test_installer::download_test_files($test_install_request, $to_dir, true);
}
}
protected static function download_test_files(&$test_install_request, $download_location = false, $no_prompts = false)
@@ -220,6 +236,8 @@ class pts_test_installer
pts_file_io::mkdir($download_location);
$module_pass = array($identifier, $test_install_request->get_download_objects());
pts_module_manager::module_process('__pre_test_download', $module_pass);
$objects_completed = 0;
$fail_if_no_downloads = false;
foreach($test_install_request->get_download_objects() as $download_package)
{
@@ -246,7 +264,8 @@ class pts_test_installer
{
case 'IN_DESTINATION_DIR':
pts_client::$display->test_install_download_file('FILE_FOUND', $download_package);
continue;
$objects_completed++;
continue 2;
case 'REMOTE_DOWNLOAD_CACHE':
$download_tries = 0;
do
@@ -279,7 +298,8 @@ class pts_test_installer
if(is_file($download_destination))
{
continue;
$objects_completed++;
continue 2;
}
case 'MAIN_DOWNLOAD_CACHE':
case 'LOCAL_DOWNLOAD_CACHE':
@@ -294,6 +314,7 @@ class pts_test_installer
// SymLinkFilesFromCache is disabled by default
pts_client::$display->test_install_download_file('LINK_FROM_CACHE', $download_package);
symlink($download_cache_file, $download_destination);
$objects_completed++;
}
else
{
@@ -329,12 +350,17 @@ class pts_test_installer
if(is_file($download_destination))
{
continue;
$objects_completed++;
continue 2;
}
}
default:
$package_urls = $download_package->get_download_url_array();
if(!is_file($download_destination) && empty($package_urls))
{
self::test_install_error(null, $test_install_request, $package_filename . ' must be manually placed in the Phoronix Test Suite download-cache.');
$fail_if_no_downloads = true;
}
// Download the file
if(!is_file($download_destination) && count($package_urls) > 0 && $package_urls[0] != null)
{
@@ -382,6 +408,7 @@ class pts_test_installer
if(is_file($download_destination_temp))
{
rename($download_destination_temp, $download_destination);
$objects_completed++;
}
if($download_package->get_filesize() > 0 && $download_end != $download_start)
@@ -459,7 +486,7 @@ class pts_test_installer
pts_module_manager::module_process('__post_test_download', $identifier);
return true;
return !$fail_if_no_downloads || $objects_completed > 0;
}
public static function create_compiler_mask(&$test_install_request)
{
@@ -704,7 +731,6 @@ class pts_test_installer
protected static function install_test_process(&$test_install_request, $no_prompts)
{
// Install a test
$identifier = $test_install_request->test_profile->get_identifier();
$test_install_directory = $test_install_request->test_profile->get_install_dir();
pts_file_io::mkdir(dirname($test_install_directory));
pts_file_io::mkdir($test_install_directory);
@@ -733,8 +759,8 @@ class pts_test_installer
if($test_install_request->test_profile->get_file_installer() != false)
{
pts_module_manager::module_process('__pre_test_install', $test_install_request);
self::create_compiler_mask($test_install_request);
pts_module_manager::module_process('__pre_test_install', $identifier);
pts_client::$display->test_install_begin($test_install_request);
$pre_install_message = $test_install_request->test_profile->get_pre_install_message();
@@ -833,7 +859,7 @@ class pts_test_installer
}
}
pts_module_manager::module_process('__post_test_install', $identifier);
pts_module_manager::module_process('__post_test_install', $test_install_request);
$installed = true;
if(pts_config::read_bool_config('PhoronixTestSuite/Options/Installation/RemoveDownloadFiles', 'FALSE'))
@@ -868,7 +894,7 @@ class pts_test_installer
$identifier = $test_install_request->test_profile->get_identifier();
pts_file_io::mkdir($test_install_request->test_profile->get_install_dir());
if($remove_old_files)
if($remove_old_files && $test_install_request->test_profile->do_remove_test_install_directory_on_reinstall())
{
// Remove any (old) files that were installed
$ignore_files = array('pts-install.xml', 'install-failed.log');

View File

@@ -52,6 +52,8 @@ class pts_test_run_manager
protected $dynamic_run_count_export_script;
protected $multi_test_stress_run = false;
protected $allow_test_cache_share = true;
protected $skip_post_execution_options = false;
protected $drop_noisy_results = false;
protected static $test_run_process_active = false;
protected $batch_mode = false;
@@ -65,6 +67,7 @@ class pts_test_run_manager
$this->dynamic_run_count_on_length_or_less = 60; //pts_config::read_user_config('PhoronixTestSuite/Options/TestResultValidation/LimitIncreasingRunCountForTestsOverLength', 60);
$this->dynamic_run_count_std_deviation_threshold = pts_config::read_user_config('PhoronixTestSuite/Options/TestResultValidation/StandardDeviationThreshold', 3.50);
$this->dynamic_run_count_export_script = pts_config::read_user_config('PhoronixTestSuite/Options/TestResultValidation/ExportResultsTo', null);
$this->drop_noisy_results = pts_config::read_bool_config('PhoronixTestSuite/Options/TestResultValidation/DropNoisyResults', 'FALSE');
if($batch_mode)
{
@@ -101,11 +104,22 @@ class pts_test_run_manager
{
$this->auto_upload_to_openbenchmarking = ($do == true);
}
public function increase_run_count_check(&$active_result_buffer, $scheduled_times_to_run, $latest_test_run_time)
public function do_skip_post_execution_options()
{
$this->skip_post_execution_options = true;
}
public function increase_run_count_check(&$test_run_request, &$active_result_buffer, $scheduled_times_to_run)
{
// returning false here will not yield extra test run, returning true will yield additional test run, returning -1 will abort/not-save current test result
// Compute average time taking per test run (in seconds)
$avg_test_run_time = array_sum($test_run_request->test_run_times) / count($test_run_request->test_run_times);
// First make sure this test doesn't take too long to run where we don't want dynamic handling
if(floor($latest_test_run_time / 60) > $this->dynamic_run_count_on_length_or_less)
if(floor($avg_test_run_time / 60) > $this->dynamic_run_count_on_length_or_less)
{
// The default value to not deal with dynamic run counts is when greater than 1 hour (60 minutes)
// For tests taking an enormous amount of time, by default don't increase run count...
return false;
}
@@ -113,30 +127,41 @@ class pts_test_run_manager
$std_dev = pts_math::percent_standard_deviation($active_result_buffer->results);
if($std_dev >= $this->dynamic_run_count_std_deviation_threshold)
{
static $last_run_count = 128; // just a number that should always cause the first check below to be true
static $run_std_devs;
$times_already_ran = count($active_result_buffer->results);
static $test_run_pos; // keeping track of run index for what test in the run queue we are at
static $run_std_devs; // an array of standard deviations up to this point for the current test
$times_already_ran = count($active_result_buffer->results); // times test has ran so far
if($times_already_ran <= $last_run_count)
if($this->test_run_pos != $test_run_pos)
{
// We're now onto a new test so clear out the array
$test_run_pos = $this->test_run_pos;
$run_std_devs = array();
}
$last_run_count = $times_already_ran;
$run_std_devs[$last_run_count] = $std_dev;
$run_std_devs[$times_already_ran] = $std_dev;
if($avg_test_run_time < 120)
{
// If test run time is 2 minutes or less, safely use a 3x multiple for how many times to run for statistical accuracy...
$maximum_times_to_run = $scheduled_times_to_run * 3;
}
else
{
// For longer running tests, just consider going up to 2x original expected run count
$maximum_times_to_run = $scheduled_times_to_run * 2;
}
// If we haven't reached scheduled times to run x 2, increase count straight away
if($times_already_ran < ($scheduled_times_to_run * 2))
if($times_already_ran < $maximum_times_to_run)
{
return true;
}
else if($times_already_ran < ($scheduled_times_to_run * 3))
else if($times_already_ran < ($maximum_times_to_run + $scheduled_times_to_run))
{
// More aggressive determination whether to still keep increasing the run count
$first_and_now_diff = pts_arrays::first_element($run_std_devs) - pts_arrays::last_element($run_std_devs);
// More aggressive determination whether to still keep increasing the run count beyond the expected maximum...
$first_and_last_diff_in_deviation = abs(pts_arrays::first_element($run_std_devs) - pts_arrays::last_element($run_std_devs));
// Increasing the run count at least looks to be helping...
if($first_and_now_diff > (pts_arrays::first_element($run_std_devs) / 2))
// Increasing the run count at least if it looks to be helping...
if($first_and_last_diff_in_deviation < (pts_arrays::first_element($run_std_devs) / 2))
{
// If we are at least making progress in the right direction, increase the run count some more
return true;
@@ -167,6 +192,13 @@ class pts_test_run_manager
}
}
// see if we should be dropping noisy results
if($this->drop_noisy_results && $std_dev > 25.0)
{
// drop the result from being saved as the noise level exceeds threshold
return -1;
}
// No reason to increase the run count with none of the previous checks requesting otherwise
return false;
}
@@ -293,6 +325,7 @@ class pts_test_run_manager
$this->result_file = new pts_result_file($this->file_name);
$this->benchmark_log->log('SAVE IDENTIFIER: ' . $this->file_name);
$this->is_new_result_file = $this->result_file->get_system_count() == 0;
return $this->file_name;
}
public function set_results_identifier($identifier)
{
@@ -302,7 +335,7 @@ class pts_test_run_manager
{
if($this->file_name != null)
{
return;
return $this->file_name;
}
// Prompt to save a file when running a test
@@ -320,7 +353,7 @@ class pts_test_run_manager
// Be of help to the user by showing recently saved test results
if($save_name == null)
{
pts_tests::recently_saved_results();
pts_tests::recently_saved_results(' ');
}
$save_name_length = strlen($save_name);
@@ -336,15 +369,29 @@ class pts_test_run_manager
echo PHP_EOL . 'The name of the saved file must have between 2 and 126 characters in length.' . PHP_EOL;
}
pts_client::$display->generic_prompt(pts_client::cli_just_bold('Enter a name to save these results under: '));
$save_name = pts_user_io::read_user_input();
$prompt = ' Enter a name for the result file: ';
if(function_exists('readline') && function_exists('readline_completion_function'))
{
pts_user_io::$readline_completion_possibilities = pts_tests::test_results_by_date();
readline_completion_function(array('pts_user_io', 'readline_completion_handler'));
$save_name = readline($prompt);
}
else
{
$save_name = pts_user_io::read_user_input($prompt);
}
}
}
$this->set_save_name($save_name);
return $this->set_save_name($save_name);
}
public function prompt_results_identifier()
{
if(!empty($this->results_identifier))
{
return $this->results_identifier;
}
// Prompt for a results identifier
$results_identifier = null;
$show_identifiers = array();
@@ -405,8 +452,18 @@ class pts_test_run_manager
}
else
{
pts_client::$display->generic_prompt(pts_client::cli_just_bold('Enter a unique name to describe this test run / configuration: '));
$results_identifier = self::clean_results_identifier(pts_user_io::read_user_input());
$prompt = ' Enter a unique name to describe this test run / configuration: ';
if(function_exists('readline') && function_exists('readline_completion_function'))
{
pts_user_io::$readline_completion_possibilities = array_map(array('pts_strings', 'trim_search_query'), array_merge(phodevi::system_hardware(false), phodevi::system_software(false)));
readline_completion_function(array('pts_user_io', 'readline_completion_handler'));
$results_identifier = readline($prompt);
}
else
{
$results_identifier = pts_user_io::read_user_input($prompt);
}
$results_identifier = self::clean_results_identifier($results_identifier);
}
$times_tried++;
@@ -426,6 +483,7 @@ class pts_test_run_manager
}
$this->results_identifier = $results_identifier;
return $this->results_identifier;
}
public function auto_generate_results_identifier()
{
@@ -536,6 +594,12 @@ class pts_test_run_manager
$this->test_run_pos = $i;
$continue_test_flag = $this->process_test_run_request($i);
if($continue_test_flag === 'SKIP')
{
$continue_test_flag = true;
continue;
}
if(pts_config::read_bool_config('PhoronixTestSuite/Options/Testing/RemoveTestInstallOnCompletion', 'FALSE'))
{
// Remove the installed test if it's no longer needed in this run queue
@@ -667,7 +731,7 @@ class pts_test_run_manager
else if(pts_file_io::unlink(PTS_USER_PATH . 'skip-test'))
{
// Just skip the current test and do not save the results, but continue testing
return true;
return 'SKIP';
}
else if(pts_client::read_env('LIMIT_ELAPSED_TEST_TIME') > 0 && (PTS_INIT_TIME + (pts_client::read_env('LIMIT_ELAPSED_TEST_TIME') * 60)) > time())
{
@@ -755,6 +819,13 @@ class pts_test_run_manager
return false;
}
$mount_options = phodevi::read_property('disk', 'mount-options');
if(isset($mount_options['mount-options']) && strpos($mount_options['mount-options'], 'noexec') !== false)
{
trigger_error('The test installation directory is on a file-system mounted with the \'noexec\' mount option. Re-mount the file-system appropriately or change the Phoronix Test Suite user configuration file to point to an alternative mount point.' . PHP_EOL . 'Location: ' . pts_client::test_install_root_path(), E_USER_ERROR);
return false;
}
// Cleanup tests to run
if($this->cleanup_tests_to_run($to_run) == false)
{
@@ -762,7 +833,7 @@ class pts_test_run_manager
}
else if(count($to_run) == 0)
{
trigger_error('You must enter at least one test, suite, or result identifier to run.', E_USER_ERROR);
//trigger_error('You must enter at least one test, suite, or result identifier to run.', E_USER_ERROR);
return false;
}
@@ -782,7 +853,8 @@ class pts_test_run_manager
$this->result_file->set_preset_environment_variables($this->get_preset_environment_variables());
// TODO XXX JSON In null and notes
$sys = new pts_result_file_system($this->results_identifier, phodevi::system_hardware(true), phodevi::system_software(true), $this->generate_json_system_attributes(), pts_client::current_user(), null, date('Y-m-d H:i:s'), PTS_VERSION);
$json_attr = $this->generate_json_system_attributes();
$sys = new pts_result_file_system($this->results_identifier, phodevi::system_hardware(true), phodevi::system_software(true), $json_attr, pts_client::current_user(), null, date('Y-m-d H:i:s'), PTS_VERSION);
$this->result_file->add_system($sys);
}
@@ -907,6 +979,10 @@ class pts_test_run_manager
{
$notes['python'] = phodevi::read_property('system', 'python-version');
}
if(in_array('wine', $test_external_dependencies))
{
phodevi_system::$report_wine_override = true;
}
$notes['security'] = phodevi::read_property('system', 'security-features');
@@ -923,7 +999,7 @@ class pts_test_run_manager
public function post_execution_process()
{
$this->benchmark_log->log('Test Run Process Ended');
if($this->do_save_results())
if($this->do_save_results() && !$this->skip_post_execution_options)
{
if($this->result_file->get_test_count() == 0 && $this->is_new_result_file)
{
@@ -955,7 +1031,7 @@ class pts_test_run_manager
}
else
{
if((pts_client::read_env('DISPLAY') == false && pts_client::read_env('WAYLAND_DISPLAY') == false && !phodevi::is_windows() && !phodevi::is_macosx()) && !defined('PHOROMATIC_PROCESS'))
if(!phodevi::is_display_server_active() && !defined('PHOROMATIC_PROCESS'))
{
$txt_results = pts_user_io::prompt_bool_input('Do you want to view the text results of the testing', true);
if($txt_results)
@@ -1165,6 +1241,7 @@ class pts_test_run_manager
if($stop_and_install)
{
pts_test_installer::standard_install($tests_missing);
$to_run_objects = array_merge($to_run_objects, $tests_missing);
$this->cleanup_tests_to_run($to_run_objects);
}
}
@@ -1610,7 +1687,7 @@ class pts_test_run_manager
return strcmp($a_comp, $b_comp);
}
public function test_profile_system_compatibility_check(&$test_profile, $report_errors = false)
public static function test_profile_system_compatibility_check(&$test_profile, $report_errors = false, $is_batch_mode = false)
{
$valid_test_profile = true;
$test_type = $test_profile->get_test_hardware_type();
@@ -1623,20 +1700,30 @@ class pts_test_run_manager
{
$valid_test_profile = false;
}
else if($test_type == 'Graphics' && pts_client::read_env('DISPLAY') == false && pts_client::read_env('WAYLAND_DISPLAY') == false && phodevi::is_windows() == false && phodevi::is_macosx() == false)
else if($test_profile->is_display_required() && !phodevi::is_display_server_active())
{
$report_errors && pts_client::$display->test_run_error('No display server was found, cannot run ' . $test_profile);
$report_errors && pts_client::$display->test_run_error('No display server was found, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if($test_profile->is_network_required() && !pts_network::network_support_available())
{
$report_errors && pts_client::$display->test_run_error('No network connection was found or is disabled, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if($test_profile->is_internet_required() && !pts_network::internet_support_available())
{
$report_errors && pts_client::$display->test_run_error('No Internet connection was found or is disabled, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if($test_type == 'Graphics' && in_array($display_driver, array('vesa', 'nv', 'cirrus')) && stripos($gpu, 'LLVM') === false)
{
// These display drivers end up being in known configurations without 3D hardware support so unless an LLVM-based string is reported as the GPU, don't advertise 3D tests
$report_errors && pts_client::$display->test_run_error('3D acceleration support not available, cannot run ' . $test_profile);
$report_errors && pts_client::$display->test_run_error('3D acceleration support not available, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if($test_type == 'Disk' && stripos(phodevi::read_property('system', 'filesystem'), 'SquashFS') !== false)
{
$report_errors && pts_client::$display->test_run_error('Running on a RAM-based live file-system, cannot run ' . $test_profile);
$report_errors && pts_client::$display->test_run_error('Running on a RAM-based live file-system, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if(pts_client::read_env('NO_' . strtoupper($test_type) . '_TESTS') ||($skip_tests && (in_array($test_profile, $skip_tests) || in_array($test_type, $skip_tests) || in_array($test_profile->get_identifier(false), $skip_tests) || in_array($test_profile->get_identifier_base_name(), $skip_tests))))
@@ -1649,15 +1736,15 @@ class pts_test_run_manager
$report_errors && pts_client::$display->test_run_error('Due to a pre-set environment variable, skipping ' . $test_profile);
$valid_test_profile = false;
}
else if($test_profile->is_root_required() && $this->batch_mode && phodevi::is_root() == false)
else if($test_profile->is_root_required() && $is_batch_mode && phodevi::is_root() == false)
{
$report_errors && pts_client::$display->test_run_error('Cannot run ' . $test_profile . ' in batch mode as root access is required.');
$report_errors && pts_client::$display->test_run_error('Running in batch mode as a user but this test requires root access, skipping ' . $test_profile);
$valid_test_profile = false;
}
if($valid_test_profile == false && pts_client::read_env('SKIP_ALL_TEST_SUPPORT_CHECKS'))
{
$report_errors && pts_client::$display->test_run_error('SKIP_ALL_TEST_SUPPORT_CHECKS is set for ' . $test_profile . '.');
$report_errors && pts_client::$display->test_run_error('SKIP_ALL_TEST_SUPPORT_CHECKS is set for ' . $test_profile);
$valid_test_profile = true;
}
@@ -1671,7 +1758,7 @@ class pts_test_run_manager
{
$valid_test_profile = true;
if($this->test_profile_system_compatibility_check($test_profile, true) == false)
if(self::test_profile_system_compatibility_check($test_profile, true, $this->batch_mode) == false)
{
$valid_test_profile = false;
}

View File

@@ -23,6 +23,8 @@
class pts_tests
{
public static $extra_env_vars = null;
protected static $override_test_script_execution_handler = false;
public static function add_extra_env_var($name, $value)
{
self::$extra_env_vars[$name] = $value;
@@ -77,11 +79,15 @@ class pts_tests
return $local_suites;
}
public static function all_suites()
{
return array_merge(pts_openbenchmarking::available_suites(false), pts_tests::local_suites());
}
public static function scan_for_error($log_file, $strip_string)
{
$error = null;
foreach(array('fatal error', 'error:', 'error while loading', 'undefined reference', 'returned 1 exit status', 'not found', 'child process excited with status', 'error opening archive', 'failed to load', 'fatal', 'illegal argument') as $error_string)
foreach(array('fatal error', 'error:', 'error while loading', 'undefined reference', ': cannot find -l', 'returned 1 exit status', 'not found', 'child process excited with status', 'error opening archive', 'failed to load', 'fatal', 'illegal argument') as $error_string)
{
if(($e = strripos($log_file, $error_string)) !== false)
{
@@ -100,6 +106,7 @@ class pts_tests
if(isset($log_file[8]) && !isset($log_file[144]) && strpos($log_file, PHP_EOL) === false)
{
$error = $log_file;
break;
}
}
}
@@ -169,7 +176,7 @@ class pts_tests
$extra_vars['LC_NUMERIC'] = '';
$extra_vars['LC_CTYPE'] = '';
$extra_vars['LC_MESSAGES'] = '';
$extra_vars['LANG'] = '';
$extra_vars['LANG'] = 'en_US.utf8';
$extra_vars['PHP_BIN'] = PHP_BIN;
// Safe-guards to try to ensure more accurate testing
@@ -186,7 +193,7 @@ class pts_tests
if(is_dir($this_test_profile->get_install_dir()))
{
$extra_vars['PATH'] = $this_test_profile->get_install_dir() . ':' . $extra_vars['PATH'];
$extra_vars['PATH'] = $this_test_profile->get_install_dir() . pts_client::get_path_separator() . $extra_vars['PATH'];
$extra_vars['TEST_' . strtoupper(str_replace('-', '_', $this_test_profile->get_identifier_base_name()))] = $this_test_profile->get_install_dir();
}
}
@@ -200,7 +207,7 @@ class pts_tests
if(isset($extra_vars_append['PATH']))
{
// Special case variable where you likely want the two merged rather than overwriting
$extra_vars['PATH'] = $extra_vars_append['PATH'] . (substr($extra_vars_append['PATH'], -1) != ':' ? ':' : null) . $extra_vars['PATH'];
$extra_vars['PATH'] = $extra_vars_append['PATH'] . (substr($extra_vars_append['PATH'], -1) != pts_client::get_path_separator() ? pts_client::get_path_separator() : null) . $extra_vars['PATH'];
unset($extra_vars_append['PATH']);
}
@@ -212,7 +219,7 @@ class pts_tests
$result = null;
$test_directory = $test_profile->get_install_dir();
pts_file_io::mkdir($test_directory, 0777, true);
$os_postfix = '_' . strtolower(phodevi::operating_system());
$os_postfix = '_' . strtolower(phodevi::os_under_test());
$test_profiles = array($test_profile);
if($use_ctp)
@@ -247,32 +254,41 @@ class pts_tests
pts_client::$display->test_run_message($print_string);
}
if($use_phoroscript || pts_client::read_env('USE_PHOROSCRIPT_INTERPRETER') != false)
if(self::$override_test_script_execution_handler && is_callable(self::$override_test_script_execution_handler))
{
echo PHP_EOL . 'Falling back to experimental PhoroScript code path...' . PHP_EOL;
$phoroscript = new pts_phoroscript_interpreter($run_file, $extra_vars, $test_directory);
$phoroscript->execute_script($pass_argument);
$this_result = null;
$this_result = call_user_func(self::$override_test_script_execution_handler, $test_directory, $sh, $run_file, $pass_argument, $extra_vars, $this_test_profile);
}
else if(phodevi::is_windows())
{
$host_env = $_SERVER;
unset($host_env['argv']);
$descriptorspec = array(0 => array('pipe', 'r'), 1 => array('pipe', 'w'), 2 => array('pipe', 'w'));
$test_process = proc_open($sh . ' ' . $run_file . ' ' . $pass_argument . (phodevi::is_windows() && false ? '' : ' 2>&1'), $descriptorspec, $pipes, $test_directory, array_merge($host_env, pts_client::environmental_variables(), $extra_vars));
if(is_resource($test_process))
{
//echo proc_get_status($test_process)['pid'];
$this_result = stream_get_contents($pipes[1]);
fclose($pipes[1]);
fclose($pipes[2]);
$return_value = proc_close($test_process);
}
}
else
// if override_test_script_execution_handler returned -1, fallback to using normal script handler
if(!isset($this_result) || $this_result == '-1')
{
$this_result = pts_client::shell_exec('cd ' . $test_directory . (phodevi::is_windows() ? '; ' : ' && ') . $sh . ' ' . $run_file . ' ' . $pass_argument . (phodevi::is_windows() ? '' : ' 2>&1'), $extra_vars);
if($use_phoroscript || pts_client::read_env('USE_PHOROSCRIPT_INTERPRETER') != false)
{
echo PHP_EOL . 'Falling back to experimental PhoroScript code path...' . PHP_EOL;
$phoroscript = new pts_phoroscript_interpreter($run_file, $extra_vars, $test_directory);
$phoroscript->execute_script($pass_argument);
$this_result = null;
}
else if(phodevi::is_windows())
{
$host_env = $_SERVER;
unset($host_env['argv']);
$descriptorspec = array(0 => array('pipe', 'r'), 1 => array('pipe', 'w'), 2 => array('pipe', 'w'));
$test_process = proc_open($sh . ' ' . $run_file . ' ' . $pass_argument . (phodevi::is_windows() && false ? '' : ' 2>&1'), $descriptorspec, $pipes, $test_directory, array_merge($host_env, pts_client::environmental_variables(), $extra_vars));
if(is_resource($test_process))
{
//echo proc_get_status($test_process)['pid'];
$this_result = stream_get_contents($pipes[1]);
fclose($pipes[1]);
fclose($pipes[2]);
$return_value = proc_close($test_process);
}
}
else
{
$this_result = pts_client::shell_exec('cd ' . $test_directory . (phodevi::is_windows() ? '; ' : ' && ') . $sh . ' ' . $run_file . ' ' . $pass_argument . (phodevi::is_windows() ? '' : ' 2>&1'), $extra_vars);
}
}
if(trim($this_result) != null)
@@ -284,6 +300,15 @@ class pts_tests
return $result;
}
public static function override_script_test_execution_handler($to_call)
{
if(is_callable($to_call))
{
self::$override_test_script_execution_handler = $to_call;
return true;
}
return false;
}
public static function update_test_install_xml(&$test_profile, $this_duration = 0, $is_install = false, $compiler_data = null, $install_footnote = null)
{
// Refresh/generate an install XML for pts-install.xml
@@ -344,10 +369,52 @@ class pts_tests
$xml_writer->saveXMLFile($test_profile->get_install_dir() . 'pts-install.xml');
}
public static function invalid_command_helper($passed_args)
public static function invalid_command_helper($passed_args, &$argument_checks)
{
$supports_passing_a_test = false;
foreach($argument_checks as $check)
{
if($check->get_function_check_type() == 'Test' || strpos($check->get_function_check_type(), 'Test |') !== false)
{
$supports_passing_a_test = true;
}
}
$showed_recent_results = self::recently_saved_results();
if($supports_passing_a_test)
{
$recommended_tests = array_keys(pts_openbenchmarking_client::most_popular_tests(20));
if(count($recommended_tests) > 3)
{
$longest_test = strlen(pts_strings::find_longest_string($recommended_tests)) + 3;
$terminal_width = pts_client::terminal_width();
$tests_per_line = floor($terminal_width / $longest_test);
shuffle($recommended_tests);
$recommended_tests = array_slice($recommended_tests, 0, min(count($recommended_tests), $tests_per_line * 2));
echo pts_client::cli_just_bold('Popular Tests:') . PHP_EOL;
$i = 0;
foreach($recommended_tests as $test)
{
if($i == 0)
{
echo ' ';
}
echo $test . str_repeat(' ', $longest_test - strlen($test));
$i++;
if($i == $tests_per_line)
{
$i = 0;
echo PHP_EOL;
}
}
echo PHP_EOL;
}
}
if(count($result_uploads = pts_openbenchmarking::result_uploads_from_this_ip()) > 0)
{
echo PHP_EOL . pts_client::cli_just_bold('Recent OpenBenchmarking.org Results From This IP:') . PHP_EOL;
@@ -356,12 +423,12 @@ class pts_tests
{
$t[] = array(pts_client::cli_colored_text($id, 'gray', true), $title);
if(count($t) == 6)
if(count($t) == 5)
{
break;
}
}
echo pts_user_io::display_text_table($t, '- ') . PHP_EOL . PHP_EOL;
echo pts_user_io::display_text_table($t, ' ') . PHP_EOL . PHP_EOL;
}
$similar_tests = array();
@@ -440,7 +507,7 @@ class pts_tests
echo ' phoronix-test-suite install <test-name>' . PHP_EOL . PHP_EOL;
}
}
public static function recently_saved_results()
public static function recently_saved_results($extra_space = null)
{
$recent_results = pts_tests::test_results_by_date();
@@ -455,8 +522,8 @@ class pts_tests
$days = floor(($current_time - $m_time) / 86400);
$recent_result = sprintf('%-' . $res_length . 'ls [%-ls]', $recent_result, ($days == 0 ? 'Today' : pts_strings::days_ago_format_string($days) . ' old'));
}
echo PHP_EOL . pts_client::cli_just_bold('Recently Saved Test Results:') . PHP_EOL;
echo pts_user_io::display_text_list($recent_results) . PHP_EOL;
echo PHP_EOL . $extra_space . pts_client::cli_just_bold('Recently Saved Test Results:') . PHP_EOL;
echo pts_user_io::display_text_list($recent_results, $extra_space . ' ') . PHP_EOL;
return true;
}

View File

@@ -21,6 +21,8 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
// TODO XXX possibly simply a lot of this with xml_parse_into_struct
class nye_XmlReader
{
protected $tag_fallback = false; // Fallback value if tag is not present

View File

@@ -97,7 +97,7 @@ class phodevi_cpu extends phodevi_device_interface
}
else if(phodevi::is_linux())
{
if(is_file('/sys/devices/system/cpu/online'))
if(is_file('/sys/devices/system/cpu/online') && stripos(phodevi::read_property('system', 'system-layer'), 'lxc') === false)
{
$present = pts_file_io::file_get_contents('/sys/devices/system/cpu/online');
@@ -129,15 +129,20 @@ class phodevi_cpu extends phodevi_device_interface
$info = phodevi_osx_parser::read_osx_system_profiler('SPHardwareDataType', 'TotalNumberOfCores');
}
}
else if(phodevi::is_windows())
if(phodevi::is_windows())
{
// Should be hit by the first NUMBER_OF_PROCESSORS env check...
//$info = getenv('NUMBER_OF_PROCESSORS');
$logical_cores = array_sum(phodevi_windows_parser::get_wmi_object('Win32_Processor', 'NumberOfLogicalProcessors', true));
if($logical_cores > $info || !is_numeric($info))
{
$info = $logical_cores;
}
}
if($info == null && isset(phodevi::$vfs->cpuinfo))
{
$info = self::cpuinfo_core_count();
$info = self::cpuinfo_thread_count();
}
return (is_numeric($info) && $info > 0 ? $info : 1);
@@ -149,11 +154,39 @@ class phodevi_cpu extends phodevi_device_interface
if(phodevi::is_linux())
{
$physical_cores = phodevi_cpu::cpuinfo_core_count();
if(empty($physical_cores) || $physical_cores == phodevi::read_property('cpu', 'thread-count'))
{
// Needed for POWER9 at least
if(isset(phodevi::$vfs->lscpu) && ($t = strpos(phodevi::$vfs->lscpu, 'Core(s) per socket:')))
{
$lscpu = substr(phodevi::$vfs->lscpu, $t + strlen('Core(s) per socket:') + 1);
$lscpu = substr($lscpu, 0, strpos($lscpu, PHP_EOL));
$cores_per_socket = trim($lscpu);
if($cores_per_socket > 1 && ($t = strpos(phodevi::$vfs->lscpu, 'Socket(s):')))
{
$lscpu = substr(phodevi::$vfs->lscpu, $t + strlen('Socket(s):') + 1);
$lscpu = substr($lscpu, 0, strpos($lscpu, PHP_EOL));
$sockets = trim($lscpu);
if(is_numeric($sockets) && $sockets >= 1)
{
$physical_cores = $cores_per_socket * $sockets;
}
}
}
}
}
else if(phodevi::is_bsd())
{
// hw.cpu_topology_core_ids works at least on DragonFly BSD
$phys_ids = intval(phodevi_bsd_parser::read_sysctl(array('hw.cpu_topology_phys_ids')));
$physical_cores = intval(phodevi_bsd_parser::read_sysctl(array('hw.cpu_topology_core_ids')));
if($phys_ids > 0 && ($phys_ids * $physical_cores) <= phodevi::read_property('cpu', 'thread-count') && $physical_cores % 2 == 0)
{
$physical_cores = $phys_ids * $physical_cores;
}
}
else if(phodevi::is_macosx())
{
@@ -161,7 +194,7 @@ class phodevi_cpu extends phodevi_device_interface
}
else if(phodevi::is_windows())
{
$physical_cores = phodevi_windows_parser::get_wmi_object('Win32_Processor', 'NumberOfCores');
$physical_cores = array_sum(phodevi_windows_parser::get_wmi_object('Win32_Processor', 'NumberOfCores', true));
}
if(empty($physical_cores) || !is_numeric($physical_cores))
@@ -205,6 +238,16 @@ class phodevi_cpu extends phodevi_device_interface
if(phodevi::is_linux())
{
$cache_size = self::cpuinfo_cache_size();
if(empty($cache_size) && isset(phodevi::$vfs->lscpu) && ($t = strpos(phodevi::$vfs->lscpu, 'L3 cache:')))
{
$lscpu = substr(phodevi::$vfs->lscpu, $t + strlen('L3 cache:') + 1);
$lscpu = substr($lscpu, 0, strpos($lscpu, PHP_EOL));
$lscpu = trim($lscpu);
if(substr($lscpu, -1) == 'K')
{
$cache_size = substr($lscpu, 0, -1);
}
}
}
else if(phodevi::is_macosx())
{
@@ -285,8 +328,10 @@ class phodevi_cpu extends phodevi_device_interface
$info = null;
}
}
if($info == null && isset(phodevi::$vfs->cpuinfo)) // fall back for those without cpufreq
if($info == null && isset(phodevi::$vfs->cpuinfo) && phodevi::read_property('system', 'kernel-architecture') != 'x86_64') // fall back for those without cpufreq
{
// Don't use this code path for x86_64 since for those systems the /sys reporting should work
// and when that isn't the case, CPUFreq not loaded and thus reported here is usually dynamic frequency
$cpu_mhz = self::read_cpuinfo_line('cpu MHz');
$info = $cpu_mhz / 1000;
@@ -465,7 +510,11 @@ class phodevi_cpu extends phodevi_device_interface
else if(phodevi::is_windows())
{
$info = phodevi_windows_parser::get_wmi_object('win32_processor', 'Name');
$cpu_count = count(phodevi_windows_parser::get_wmi_object('Win32_Processor', 'DeviceID', true));
if($cpu_count > 1)
{
$info = $cpu_count . ' x ' . $info;
}
if(!$info)
{
$info = getenv('PROCESSOR_IDENTIFIER');
@@ -476,29 +525,110 @@ class phodevi_cpu extends phodevi_device_interface
{
if(phodevi::is_linux())
{
if(strpos(phodevi::$vfs->dmesg, 'thunderx') !== false)
$implementer = phodevi_linux_parser::read_cpuinfo_single('CPU implementer');
if($implementer == '0x41' || $implementer == '0x50')
{
// Haven't found a better way to detect ThunderX as not exposed via cpuinfo, etc
$info = 'Cavium ThunderX';
}
$isa = phodevi_linux_parser::read_cpuinfo('isa');
$uarch = phodevi_linux_parser::read_cpuinfo('uarch');
if(!empty($isa))
{
$isa = array_pop($isa);
}
if(!empty($uarch))
{
$isa = array_pop($uarch);
$architecture = phodevi_linux_parser::read_cpuinfo_single('CPU architecture');
switch($architecture)
{
case '7':
$info = 'ARMv7';
break;
case '8':
case 'AArch64':
$info = 'ARMv8';
break;
}
$part = phodevi_linux_parser::read_cpuinfo_single('CPU part');
switch($part)
{
case '0xc07':
$info .= ' Cortex-A7';
break;
case '0xc20':
$info .= ' Cortex-M7';
break;
case '0xc09':
$info .= ' Cortex-A9';
break;
case '0xc0f':
$info .= ' Cortex-A15';
break;
case '0xc0e':
$info .= ' Cortex-A12';
break;
case '0xd01':
$info .= ' Cortex-A32';
break;
case '0xd03':
$info .= ' Cortex-A53';
break;
case '0xd05':
$info .= ' Cortex-A55';
break;
case '0xd07':
$info .= ' Cortex-A57';
break;
case '0xd08':
$info .= ' Cortex-A72';
break;
case '0xd09':
$info .= ' Cortex-A73';
break;
case '0xd0a':
$info .= ' Cortex-A75';
break;
case '0xd13':
$info .= ' Cortex-R52';
break;
case '0xd20':
$info .= ' Cortex-M23';
break;
case '0xd21':
$info .= ' Cortex-M33';
break;
}
}
if(stripos($isa, 'rv') !== false && strpos($uarch, 'sifive') !== false)
if(strpos(phodevi::$vfs->dmesg, 'Ampere eMAG') !== false)
{
$info = 'SiFive RISC-V';
// Haven't found a better way to detect Ampere eMAG as not exposed via cpuinfo, etc
$info = 'Ampere eMAG ' . $info;
}
else if(!empty($isa))
else if(strpos(phodevi::$vfs->dmesg, 'thunderx') !== false)
{
$info = $isa;
// Haven't found a better way to detect ThunderX as not exposed via cpuinfo, etc
$info = 'Cavium ThunderX ' . $info;
}
else if(strpos(phodevi::$vfs->dmesg, 'rockchip-cpuinfo') !== false)
{
// Haven't found a better way to detect Rockchip as not exposed via cpuinfo, etc
$info = 'Rockchip ' . $info;
}
else if(is_file('/sys/devices/system/cpu/cpu0/cpufreq/scaling_driver'))
{
$scaling_driver = file_get_contents('/sys/devices/system/cpu/cpu0/cpufreq/scaling_driver');
if(strpos($scaling_driver, 'meson_') !== false)
{
$info = 'Amlogic ' . $info;
}
}
$info = trim($info);
if(empty($info))
{
$isa = phodevi_linux_parser::read_cpuinfo_single('isa');
$uarch = phodevi_linux_parser::read_cpuinfo_single('uarch');
if(!empty($uarch) && stripos($isa, 'rv') !== false && strpos($uarch, 'sifive') !== false)
{
$info = 'SiFive RISC-V';
}
else if(!empty($isa))
{
$info = $isa;
}
}
}
@@ -666,11 +796,6 @@ class phodevi_cpu extends phodevi_device_interface
}
public static function cpuinfo_core_count()
{
if(pts_client::executable_in_path('lscpu'))
{
$lscpu = trim(shell_exec('lscpu -p | egrep -v \'^#\' | sort -u -t, -k 2,4 | wc -l'));
}
$core_count = self::read_cpuinfo_line('cpu cores');
if($core_count == false || !is_numeric($core_count))
@@ -688,9 +813,20 @@ class phodevi_cpu extends phodevi_device_interface
{
$core_count = self::cpuinfo_thread_count();
}
if(is_numeric($lscpu) && $lscpu > $core_count)
else
{
$core_count = $lscpu;
$physical_id = self::read_cpuinfo_line('physical id', false);
$physical_id = (empty($physical_id) || !is_numeric($physical_id) ? 0 : $physical_id) + 1;
$core_count = $physical_id * $core_count;
}
if(pts_client::executable_in_path('lscpu'))
{
$lscpu = trim(shell_exec('lscpu -p | egrep -v \'^#\' | sort -u -t, -k 2,4 | wc -l'));
if(is_numeric($lscpu) && $lscpu > $core_count)
{
$core_count = $lscpu;
}
}
return $core_count;

View File

@@ -148,77 +148,6 @@ class phodevi_gpu extends phodevi_device_interface
break;
}
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$ati_fsaa = phodevi_linux_parser::read_amd_pcsdb('OpenGL,AntiAliasSamples');
$ati_fsaa_filter = phodevi_linux_parser::read_amd_pcsdb('OpenGL,AAF');
if(!empty($ati_fsaa))
{
if($ati_fsaa_filter == '0x00000000')
{
// Filter: Box
switch($ati_fsaa)
{
case '0x00000002':
$aa_level = '2x Box';
break;
case '0x00000004':
$aa_level = '4x Box';
break;
case '0x00000008':
$aa_level = '8x Box';
break;
}
}
else if($ati_fsaa_filter == '0x00000001')
{
// Filter: Narrow-tent
switch($ati_fsaa)
{
case '0x00000002':
$aa_level = '4x Narrow-tent';
break;
case '0x00000004':
$aa_level = '8x Narrow-tent';
break;
case '0x00000008':
$aa_level = '12x Narrow-tent';
break;
}
}
else if($ati_fsaa_filter == '0x00000002')
{
// Filter: Wide-tent
switch($ati_fsaa)
{
case '0x00000002':
$aa_level = '6x Wide-tent';
break;
case '0x00000004':
$aa_level = '8x Wide-tent';
break;
case '0x00000008':
$aa_level = '16x Wide-tent';
break;
}
}
else if($ati_fsaa_filter == '0x00000003')
{
// Filter: Edge-detect
switch($ati_fsaa)
{
case '0x00000004':
$aa_level = '12x Edge-detect';
break;
case '0x00000008':
$aa_level = '24x Edge-detect';
break;
}
}
}
}
else if(phodevi::is_mesa_graphics())
{
$gallium_msaa = getenv('GALLIUM_MSAA');
@@ -264,29 +193,6 @@ class phodevi_gpu extends phodevi_device_interface
break;
}
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$ati_af = phodevi_linux_parser::read_amd_pcsdb('OpenGL,AnisoDegree');
if(!empty($ati_af))
{
switch($ati_af)
{
case '0x00000002':
$af_level = '2x';
break;
case '0x00000004':
$af_level = '4x';
break;
case '0x00000008':
$af_level = '8x';
break;
case '0x00000010':
$af_level = '16x';
break;
}
}
}
else if(getenv('__GL_LOG_MAX_ANISO'))
{
$max_aniso = getenv('__GL_LOG_MAX_ANISO');
@@ -549,18 +455,13 @@ class phodevi_gpu extends phodevi_device_interface
}
}
if(count($available_modes) <= 2)
if(true) // XXX can remove this if it turns out to be fine
{
// Fallback to providing stock modes
$stock_modes = array(
array(800, 600),
array(1024, 768),
array(1280, 800),
array(1280, 1024),
array(1400, 900),
array(1400, 1050),
array(1600, 900),
array(1680, 1050),
array(1600, 1200),
array(1920, 1080),
array(1920, 1200),
@@ -854,15 +755,6 @@ class phodevi_gpu extends phodevi_device_interface
$mem_freq = max($mem_freq, $clock_freqs_current[1]);
}
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux()) // ATI GPU
{
$od_clocks = phodevi_linux_parser::read_ati_overdrive('CurrentPeak');
if(is_array($od_clocks) && count($od_clocks) >= 2) // ATI OverDrive
{
list($core_freq, $mem_freq) = $od_clocks;
}
}
else if(phodevi::is_linux()) // More liberally attempt open-source freq detection than phodevi::is_mesa_graphics()
{
if(is_file('/sys/class/drm/card0/device/performance_level'))
@@ -1112,51 +1004,7 @@ class phodevi_gpu extends phodevi_device_interface
$info = phodevi_parser::read_glx_renderer();
$video_ram = phodevi::read_property('gpu', 'memory-capacity');
if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$crossfire_status = phodevi_linux_parser::read_amd_pcsdb('SYSTEM/Crossfire/chain/*,Enable');
$crossfire_status = pts_arrays::to_array($crossfire_status);
$crossfire_card_count = 0;
for($i = 0; $i < count($crossfire_status); $i++)
{
if($crossfire_status[$i] == '0x00000001')
{
$crossfire_card_count += 2; // For now assume each chain is 2 cards, but proper way would be NumSlaves + 1
}
}
$adapters = phodevi_linux_parser::read_amd_graphics_adapters();
if(count($adapters) > 0)
{
$video_ram = $video_ram > 64 ? ' ' . $video_ram . 'MB' : null; // assume more than 64MB of vRAM
if($crossfire_card_count > 1 && $crossfire_card_count <= count($adapters))
{
$unique_adapters = array_unique($adapters);
if(count($unique_adapters) == 1)
{
if(strpos($adapters[0], 'X2') > 0 && $crossfire_card_count > 1)
{
$crossfire_card_count -= 1;
}
$info = $crossfire_card_count . ' x ' . $adapters[0] . $video_ram . ' CrossFire';
}
else
{
$info = implode(', ', $unique_adapters) . ' CrossFire';
}
}
else
{
$info = $adapters[0] . $video_ram;
}
}
}
else if(phodevi::is_macosx())
if(phodevi::is_macosx())
{
$system_profiler_info = implode(' + ', phodevi_osx_parser::read_osx_system_profiler('SPDisplaysDataType', 'ChipsetModel', true));
@@ -1479,7 +1327,18 @@ class phodevi_gpu extends phodevi_device_interface
if(!empty($info) && $video_ram > 64 && strpos($info, $video_ram) == false) // assume more than 64MB of vRAM
{
$info .= ' ' . $video_ram . 'MB';
if($video_ram < 1024)
{
$info .= ' ' . $video_ram . 'MB';
}
else
{
$video_ram = round($video_ram / 1024) . 'GB';
if(strpos($info, $video_ram) == false)
{
$info .= ' ' . $video_ram;
}
}
}
if(empty($info) && is_dir('/sys/class/drm/card0/device/driver/pvrsrvkm'))

View File

@@ -201,19 +201,6 @@ class phodevi_monitor extends phodevi_device_interface
break;
}
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$amdpcsdb_enabled_monitors = phodevi_linux_parser::read_amd_pcsdb('SYSTEM/BUSID-*/DDX,EnableMonitor');
$amdpcsdb_enabled_monitors = pts_arrays::to_array($amdpcsdb_enabled_monitors);
foreach($amdpcsdb_enabled_monitors as $enabled_monitor)
{
foreach(pts_strings::comma_explode($enabled_monitor) as $monitor_connection)
{
$monitor_count++;
}
}
}
else
{
$monitor_count = 1;
@@ -251,35 +238,6 @@ class phodevi_monitor extends phodevi_device_interface
array_push($monitor_layout, ($hit_0_0 ? 'LOWER' : 'UPPER'));
}
}
if(count($monitor_layout) == 1)
{
// Something went wrong with xdpy information, go to fallback support
if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$amdpcsdb_monitor_layout = phodevi_linux_parser::read_amd_pcsdb('SYSTEM/BUSID-*/DDX,DesktopSetup');
$amdpcsdb_monitor_layout = pts_arrays::to_array($amdpcsdb_monitor_layout);
foreach($amdpcsdb_monitor_layout as $card_monitor_configuration)
{
switch($card_monitor_configuration)
{
case 'horizontal':
array_push($monitor_layout, 'RIGHT');
break;
case 'horizontal,reverse':
array_push($monitor_layout, 'LEFT');
break;
case 'vertical':
array_push($monitor_layout, 'ABOVE');
break;
case 'vertical,reverse':
array_push($monitor_layout, 'BELOW');
break;
}
}
}
}
}
return implode(',', $monitor_layout);

View File

@@ -54,7 +54,7 @@ class phodevi_network extends phodevi_device_interface
$network = phodevi_windows_parser::get_wmi_object_multi('Win32_NetworkAdapter', 'Name');
foreach($network as $i => &$n)
{
if(stripos($n, 'debug') !== false || stripos($n, 'pseudo') !== false || strpos($n, 'WAN ') !== false)
if(stripos($n, 'debug') !== false || stripos($n, 'pseudo') !== false || stripos($n, ' virtual') !== false || strpos($n, 'WAN ') !== false)
{
unset($network[$i]);
}

View File

@@ -23,6 +23,8 @@
class phodevi_system extends phodevi_device_interface
{
public static $report_wine_override = false;
public static function properties()
{
return array(
@@ -51,7 +53,7 @@ class phodevi_system extends phodevi_device_interface
'kernel-string' => new phodevi_device_property('sw_kernel_string', phodevi::smart_caching),
'kernel-parameters' => new phodevi_device_property('sw_kernel_parameters', phodevi::std_caching),
'compiler' => new phodevi_device_property('sw_compiler', phodevi::no_caching),
'system-layer' => new phodevi_device_property('sw_system_layer', phodevi::std_caching),
'system-layer' => new phodevi_device_property('sw_system_layer', phodevi::no_caching),
'environment-variables' => new phodevi_device_property('sw_environment_variables', phodevi::std_caching),
'security-features' => new phodevi_device_property('sw_security_features', phodevi::std_caching)
);
@@ -79,6 +81,10 @@ class phodevi_system extends phodevi_device_interface
{
$layer = $wine;
}
else if((getenv('USE_WINE') || getenv('WINE_VERSION') || self::$report_wine_override) && ($wine = phodevi::read_property('system', 'wine-version')))
{
$layer = $wine;
}
else
{
// Report virtualization
@@ -316,7 +322,8 @@ class phodevi_system extends phodevi_device_interface
$fs_checks = array(
'squashfs' => 'SquashFS',
'aufs' => 'AuFS',
'unionfs' => 'UnionFS'
'unionfs' => 'UnionFS',
'overlay' => 'overlayfs',
);
foreach($fs_checks as $fs_module => $fs_name)
@@ -478,6 +485,18 @@ class phodevi_system extends phodevi_device_interface
}
}
if(empty($virtualized))
{
if(is_file('/.dockerenv'))
{
$virtualized = 'Docker';
}
else if(is_file('/dev/lxc/console'))
{
$virtualized = 'lxc';
}
}
return $virtualized;
}
public static function sw_environment_variables()
@@ -539,7 +558,7 @@ class phodevi_system extends phodevi_device_interface
// Spectre
foreach(array('spectre_v1', 'spectre_v2', 'spec_store_bypass') as $vulns)
foreach(array('spectre_v1', 'spectre_v2', 'spec_store_bypass', 'l1tf') as $vulns)
{
if(is_file('/sys/devices/system/cpu/vulnerabilities/' . $vulns))
{
@@ -576,7 +595,7 @@ class phodevi_system extends phodevi_device_interface
}
}
return !empty($security) ? implode(' + ', $security) . ' Protection' : null;
return !empty($security) ? implode(' + ', $security) : null;
}
public static function sw_compiler()
{
@@ -1329,7 +1348,7 @@ class phodevi_system extends phodevi_device_interface
}
else if(pts_client::is_process_running('lxsession') || $desktop_session == 'lxde')
{
$lx_output = trim(shell_exec('lxpanel --version'));
$lx_output = trim(shell_exec('lxpanel --version 2>&1'));
$version = substr($lx_output, strpos($lx_output, ' ') + 1);
$desktop_environment = 'LXDE';
@@ -1464,21 +1483,23 @@ class phodevi_system extends phodevi_device_interface
if($pos === false || getenv('DISPLAY') == false)
{
$info = null;
$version = null;
}
else if(($pos = strrpos($info, '(')) === false)
else if(($pos = strrpos($info, '(')) === false && strrpos($info, 'Server') === false)
{
$info = trim(substr($info, strrpos($info, ' ')));
$version = trim(substr($info, strrpos($info, ' ')));
}
else
{
$info = trim(substr($info, strrpos($info, 'Server') + 6));
$version = trim(substr($info, strrpos($info, 'Server') + 6));
if(!pts_strings::is_version($version))
{
$version = null;
}
}
if($info != null)
{
array_push($display_servers, 'X Server ' . $info);
}
array_push($display_servers, trim('X Server ' . $version));
}
if(pts_client::is_process_running('surfaceflinger'))
{
@@ -1524,11 +1545,7 @@ class phodevi_system extends phodevi_device_interface
if(empty($display_driver))
{
if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$display_driver = 'fglrx';
}
else if(phodevi::is_nvidia_graphics() || is_file('/proc/driver/nvidia/version'))
if(phodevi::is_nvidia_graphics() || is_file('/proc/driver/nvidia/version'))
{
$display_driver = 'nvidia';
}
@@ -1656,18 +1673,6 @@ class phodevi_system extends phodevi_device_interface
if(!empty($driver_version) && $with_version && $driver_version != '0.0.0')
{
$display_driver .= ' ' . $driver_version;
// XXX: The below check is disabled since the Catalyst Version no longer seems reliably reported (circa Catalyst 13.x)
if(false && phodevi::is_ati_graphics() && strpos($display_driver, 'fglrx') !== false)
{
$catalyst_version = phodevi_linux_parser::read_amd_pcsdb('AMDPCSROOT/SYSTEM/LDC,Catalyst_Version');
if($catalyst_version != null && $catalyst_version > 10.1 && $catalyst_version != 10.5 && $catalyst_version != 11.8)
{
// This option was introduced around Catalyst 10.5 but seems to not be updated properly until Catalyst 10.11/10.12
$display_driver .= ' Catalyst ' . $catalyst_version . '';
}
}
}
}
@@ -1727,6 +1732,16 @@ class phodevi_system extends phodevi_device_interface
$info = substr(phodevi::$vfs->vulkaninfo, $pos + 20);
$info = trim(substr($info, 0, strpos($info, "\n")));
}
else if(($pos = strpos(phodevi::$vfs->vulkaninfo, 'apiVersion')) !== false)
{
$apiv = substr(phodevi::$vfs->vulkaninfo, $pos);
$apiv = trim(substr($apiv, 0, strpos($apiv, ")\n")));
$apiv = trim(substr($apiv, strpos($apiv, '(') + 1));
if(pts_strings::is_version($apiv))
{
$info = $apiv;
}
}
}
/*
if($info == null)
@@ -2000,7 +2015,11 @@ class phodevi_system extends phodevi_device_interface
{
$wine_version = null;
if(pts_client::executable_in_path('wine') != false)
if((($use_wine = getenv('USE_WINE')) !== false || ($use_wine = getenv('WINE_VERSION')) !== false) && (is_executable($use_wine) || ($use_wine = pts_client::executable_in_path($use_wine)) !== false))
{
$wine_version = trim(shell_exec($use_wine . ' --version 2>&1'));
}
else if(pts_client::executable_in_path('wine') != false)
{
$wine_version = trim(shell_exec('wine --version 2>&1'));
}

View File

@@ -160,7 +160,7 @@ class phodevi_linux_parser
if((phodevi::is_root() || is_readable('/dev/mem')) && pts_client::executable_in_path('dmidecode'))
{
$ignore = pts_arrays::to_array($ignore);
$ignore = array_map('strtolower', pts_arrays::to_array($ignore));
$dmidecode = shell_exec('dmidecode --type ' . $type . ' 2>&1');
$sub_type = "\n" . $sub_type . "\n";
@@ -181,7 +181,7 @@ class phodevi_linux_parser
{
$dmidecode_r = pts_strings::colon_explode($dmidecode_elements[$i]);
if($dmidecode_r[0] == $object && isset($dmidecode_r[1]) && !in_array($dmidecode_r[1], $ignore))
if($dmidecode_r[0] == $object && isset($dmidecode_r[1]) && !in_array(strtolower($dmidecode_r[1]), $ignore))
{
array_push($value, $dmidecode_r[1]);
$found_in_section = true;
@@ -264,239 +264,6 @@ class phodevi_linux_parser
return $dmi;
}
public static function read_ati_overdrive($attribute, $adapter = 0)
{
// Read ATI OverDrive information
// OverDrive supported in fglrx 8.52+ drivers
$value = false;
if(($amdconfig = self::find_amdconfig()))
{
if($attribute == 'Temperature')
{
$info = shell_exec($amdconfig . ' --adapter=' . $adapter . ' --od-gettemperature 2>&1');
if(($start = strpos($info, 'Temperature -')) !== false)
{
$info = substr($info, $start + 14);
$value = substr($info, 0, strpos($info, ' C'));
}
}
else if($attribute == 'FanSpeed')
{
// Right now there is no standardized interface to get the fan speed through besides the pplib command
$info = shell_exec($amdconfig . ' --adapter=' . $adapter . ' --pplib-cmd \'get fanspeed 0\' 2>&1');
if(($start = strpos($info, 'Fan Speed:')) !== false)
{
$info = substr($info, $start + 11);
$info = substr($info, 0, strpos($info, '%'));
if(is_numeric($info))
{
$value = $info;
}
}
}
else
{
$info = shell_exec($amdconfig . ' --adapter=' . $adapter . ' --od-getclocks 2>&1');
if(strpos($info, 'GPU') !== false)
{
foreach(explode("\n", $info) as $line)
{
$line_r = pts_strings::colon_explode($line);
if(count($line_r) == 2)
{
$od_option = str_replace(' ', null, $line_r[0]);
if($od_option == $attribute)
{
$od_value = pts_strings::trim_spaces($line_r[1]);
$od_value = str_replace(array('%'), null, $od_value);
$od_value_r = explode(' ', $od_value);
$value = (count($od_value_r) == 1 ? $od_value_r[0] : $od_value_r);
}
}
}
}
}
}
return $value;
}
public static function read_amd_pcsdb($attribute)
{
// Read AMD's AMDPCSDB, AMD Persistent Configuration Store Database
static $try_aticonfig = true;
static $is_first_read = true;
$ati_info = null;
if($try_aticonfig)
{
if(($amdconfig = self::find_amdconfig()))
{
$info = shell_exec($amdconfig . ' --get-pcs-key=' . $attribute . ' 2>&1');
if($is_first_read && strpos($info, 'No supported adapters') != false)
{
$try_aticonfig = false;
}
else
{
if(($pos = strpos($info, ':')) > 0 && strpos($info, 'Error') === false)
{
$ati_info = substr($info, $pos + 2);
$ati_info = substr($ati_info, 0, strpos($ati_info, ' '));
}
}
}
else
{
$try_aticonfig = false;
}
$is_first_read = false;
}
if($ati_info == null && is_file('/etc/ati/amdpcsdb'))
{
// Using aticonfig --get-pcs-key failed, switch to the PTS direct parser of AMDPCSDB
$ati_info = phodevi_linux_parser::read_amd_pcsdb_direct_parser($attribute);
}
return $ati_info;
}
public static function read_amd_pcsdb_direct_parser($attribute, $find_once = false)
{
// Read AMD's AMDPCSDB, AMD Persistent Configuration Store Database but using our own internal parser instead of relying upon aticonfig/amdconfig
$amdpcsdb_file = null;
$last_found_section_count = -1;
$this_section_count = 0;
$attribute_values = array();
$attribute = pts_strings::comma_explode($attribute);
if(count($attribute) == 2)
{
$attribute_prefix = array_reverse(explode('/', $attribute[0]));
$attribute_key = $attribute[1];
$is_in_prefix = false;
if(is_file('/etc/ati/amdpcsdb'))
{
$amdpcsdb_file = explode("\n", file_get_contents('/etc/ati/amdpcsdb'));
}
for($l = 0; $l < count($amdpcsdb_file) && ($find_once == false || $last_found_section_count == -1); $l++)
{
$line = trim($amdpcsdb_file[$l]);
if(substr($line, 0, 1) == '[' && substr($line, -1) == ']')
{
// AMDPCSDB Header
$prefix_matches = true;
$header = array_reverse(explode('/', substr($line, 1, -1)));
for($i = 0; $i < count($attribute_prefix) && $i < count($header) && $prefix_matches; $i++)
{
if($attribute_prefix[$i] != $header[$i] && pts_strings::proximity_match($attribute_prefix[$i], $header[$i]) == false)
{
$prefix_matches = false;
}
}
if($prefix_matches)
{
$is_in_prefix = true;
$this_section_count++;
}
else
{
$is_in_prefix = false;
}
}
else if($is_in_prefix && $this_section_count != $last_found_section_count && count(($key_components = explode('=', $line))) == 2)
{
// AMDPCSDB Value
if($key_components[0] == $attribute_key)
{
$value_type = substr($key_components[1], 0, 1);
$value = substr($key_components[1], 1);
switch($value_type)
{
case 'V':
// Value
if(is_numeric($value) && strlen($value) < 9)
{
$value = dechex($value);
$value = '0x' . str_repeat(0, 8 - strlen($value)) . strtoupper($value);
}
break;
case 'R':
// Raw
break;
case 'S':
// String
break;
}
array_push($attribute_values, $value);
$last_found_section_count = $this_section_count;
}
}
}
}
if(count($attribute_values) == 0)
{
$attribute_values = null;
}
else if(count($attribute_values) == 1)
{
$attribute_values = $attribute_values[0];
}
return $attribute_values;
}
public static function find_amdconfig()
{
$amdconfig = false;
if(($t = pts_client::executable_in_path('aticonfig')))
{
$amdconfig = $t;
}
else if(($t = pts_client::executable_in_path('amdconfig')))
{
$amdconfig = $t;
}
return $amdconfig;
}
public static function read_amd_graphics_adapters()
{
// Read ATI/AMD graphics hardware using aticonfig
$adapters = array();
if(($amdconfig = self::find_amdconfig()))
{
$info = trim(shell_exec($amdconfig . ' --list-adapters 2>&1'));
foreach(explode("\n", $info) as $line)
{
if(($last_point = strrpos($line, '.')) > 0)
{
array_push($adapters, substr($line, $last_point + 3));
}
}
}
return $adapters;
}
public static function read_cpuinfo($attribute, $cpuinfo = false)
{
// Read CPU information
@@ -544,6 +311,15 @@ class phodevi_linux_parser
return $cpuinfo_matches;
}
public static function read_cpuinfo_single($attribute, $cpuinfo = false)
{
$cpuinfo = self::read_cpuinfo($attribute, $cpuinfo);
if(!empty($cpuinfo))
{
return array_pop($cpuinfo);
}
return null;
}
public static function read_lsb_distributor_id()
{
$vendor = phodevi_linux_parser::read_lsb('Distributor ID');

View File

@@ -24,11 +24,15 @@
class phodevi_windows_parser
{
public static function get_wmi_object($object, $name)
public static function get_wmi_object($object, $name, $to_array = false)
{
$wmi_output = trim(shell_exec('powershell "$obj = Get-WmiObject ' . $object . '; echo $obj.' . $name . '"'));
$wmi_output = strpos($wmi_output, 'Invalid') == false ? trim($wmi_output) : null;
if(($x = strpos($wmi_output, "\n")) !== false)
if($to_array)
{
$wmi_output = explode("\n", $wmi_output);
}
else if(($x = strpos($wmi_output, "\n")) !== false)
{
$wmi_output = substr($wmi_output, 0, $x);
}

View File

@@ -185,6 +185,37 @@ class phodevi extends phodevi_base
$sensor = array($sensor_object->get_type(), $sensor_object->get_sensor(), get_class($sensor_object));
return self::read_sensor_unit($sensor);
}
public static function read_sensor_object_unit_short(&$sensor_object)
{
$sensor_unit = self::read_sensor_object_unit($sensor_object);
switch($sensor_unit)
{
case 'Celsius':
$sensor_unit = 'C';
break;
case 'Percent':
$sensor_unit = '%';
break;
case 'Megabytes':
$sensor_unit = 'MB';
break;
case 'Megahertz':
$sensor_unit = 'MHz';
break;
case 'Volts':
$sensor_unit = 'V';
break;
case 'Kilobytes/seconds':
$sensor_unit = 'KBps';
break;
case 'Millivolts':
$sensor_unit = 'mV';
break;
}
return $sensor_unit;
}
public static function read_sensor_unit($sensor)
{
return call_user_func(array(self::$sensors[$sensor[0]][$sensor[1]], 'get_unit'));
@@ -371,7 +402,7 @@ class phodevi extends phodevi_base
public static function system_id_string()
{
$extra = null;
foreach(array('CC', 'CXX', 'CFLAGS', 'CPPFLAGS', 'CXXFLAGS') as $env)
foreach(array('CC', 'CXX', 'CFLAGS', 'CPPFLAGS', 'CXXFLAGS', 'USE_WINE') as $env)
{
$val = getenv($env);
@@ -541,7 +572,7 @@ class phodevi extends phodevi_base
}
// OpenGL / graphics detection
$graphics_detection = array('NVIDIA', array('ATI', 'AMD', 'fglrx'), array('Mesa', 'SGI'));
$graphics_detection = array('NVIDIA', array('Mesa', 'SGI'), array('AMD'));
$opengl_driver = phodevi::read_property('system', 'opengl-vendor') . ' ' . phodevi::read_property('system', 'opengl-driver') . ' ' . phodevi::read_property('system', 'dri-display-driver');
$opengl_driver = trim(str_replace('Corporation', null, $opengl_driver)); // Prevents a possible false positive for ATI being in CorporATIon
@@ -748,6 +779,21 @@ class phodevi extends phodevi_base
{
return phodevi::is_vendor_string($product) && !pts_strings::has_in_istring($product, array('VBOX', 'QEMU', 'Virtual', 'Family', '440BX', 'VMware', ' Gen', 'Core IGP'));
}
public static function os_under_test($force_override = false, $force_value = null)
{
static $os_under_test = null;
if($force_override && !empty($force_value))
{
$os_under_test = $force_value;
}
else if($os_under_test == null)
{
$os_under_test = self::operating_system();
}
// The operating system under test
return $os_under_test;
}
public static function operating_system()
{
return self::$operating_system;
@@ -785,12 +831,6 @@ class phodevi extends phodevi_base
self::detect_graphics();
return self::$graphics['mesa'];
}
public static function is_ati_graphics()
{
// Detection for fglrx / old AMD blob driver, newer AMDGPU-PRO / AMDGPU should go to is_mesa_graphics
self::detect_graphics();
return self::$graphics['ati'] && pts_client::executable_in_path('amdcccle');;
}
public static function is_nvidia_graphics()
{
self::detect_graphics();
@@ -798,7 +838,17 @@ class phodevi extends phodevi_base
}
public static function is_root()
{
return phodevi::read_property('system', 'username') == 'root';
return phodevi::read_property('system', 'username') == 'root' || is_writable('/root');
}
public static function is_display_server_active()
{
if(phodevi::read_property('system', 'system-layer') == 'Docker')
{
// hopefully temp workaround XXX TODO
return false;
}
return pts_client::read_env('DISPLAY') != false || pts_client::read_env('WAYLAND_DISPLAY') != false || phodevi::is_windows() || phodevi::is_macosx();
}
}

View File

@@ -24,6 +24,8 @@ class cpu_power extends phodevi_sensor
{
const SENSOR_TYPE = 'cpu';
const SENSOR_SENSES = 'power';
static $cpu_energy = 0;
static $last_time = 0;
public function read_sensor()
{
@@ -75,6 +77,43 @@ class cpu_power extends phodevi_sensor
$cpu_power = $in_power1_input;
}
}
else if(is_readable('/sys/class/powercap/intel-rapl/intel-rapl:0/energy_uj'))
{
$rapl_base_path = "/sys/class/powercap/intel-rapl/intel-rapl:";
$total_energy = 0;
for($x = 0; $x <= 128; $x++)
{
$rapl_base_path_1 = $rapl_base_path . $x;
if(is_readable($rapl_base_path_1))
{
$energy_uj = pts_file_io::file_get_contents($rapl_base_path_1 . '/energy_uj');
if(is_numeric($energy_uj))
{
$total_energy += $energy_uj;
}
}
else
{
break;
}
}
if($total_energy > 1)
{
if(self::$cpu_energy == 0)
{
self::$cpu_energy = $total_energy;
self::$last_time = time();
$cpu_power = 0;
}
else
{
$cpu_power = ($total_energy - self::$cpu_energy) / (time() - self::$last_time) / 1000000;
}
self::$last_time = time();
self::$cpu_energy = $total_energy;
}
}
return $cpu_power;
}

View File

@@ -38,10 +38,6 @@ class gpu_fanspeed extends phodevi_sensor
// nvidia-settings --describe GPUFanTarget
$fan_speed = phodevi_parser::read_nvidia_extension('[fan:0]/GPUCurrentFanSpeed');
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$fan_speed = phodevi_linux_parser::read_ati_overdrive('FanSpeed');
}
return $fan_speed;
}

View File

@@ -42,16 +42,6 @@ class gpu_freq extends phodevi_sensor
$core_freq = isset($nv_freq[0]) ? $nv_freq[0] : 0;
$mem_freq = isset($nv_freq[1]) ? $nv_freq[1] : 0;
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux()) // ATI GPU
{
$od_clocks = phodevi_linux_parser::read_ati_overdrive('CurrentClocks');
if(is_array($od_clocks) && count($od_clocks) >= 2) // ATI OverDrive
{
$core_freq = array_shift($od_clocks);
$mem_freq = array_pop($od_clocks);
}
}
else if(phodevi::is_linux())
{
if(isset(phodevi::$vfs->radeon_pm_info))

View File

@@ -35,10 +35,6 @@ class gpu_temp extends phodevi_sensor
{
$temp_c = phodevi_parser::read_nvidia_extension('GPUCoreTemp');
}
else if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$temp_c = phodevi_linux_parser::read_ati_overdrive('Temperature');
}
if($temp_c == -1 || empty($temp_c))
{

View File

@@ -28,7 +28,6 @@ class gpu_usage extends phodevi_sensor
const SENSOR_SENSES = 'usage';
const SENSOR_UNIT = 'Percent';
private $probe_ati_overdrive = false;
private $probe_radeontop = false;
private $probe_nvidia_smi = false;
private $probe_nvidia_settings = false;
@@ -50,11 +49,7 @@ class gpu_usage extends phodevi_sensor
{
$gpu_usage = -1;
if($this->probe_ati_overdrive)
{
$gpu_usage = self::ati_overdrive_core_usage();
}
else if($this->probe_nvidia_settings)
if($this->probe_nvidia_settings)
{
$gpu_usage = self::read_nvidia_settings_gpu_utilization();
}
@@ -72,11 +67,7 @@ class gpu_usage extends phodevi_sensor
private function set_probe_mode()
{
if(phodevi::is_ati_graphics() && phodevi::is_linux())
{
$this->probe_ati_overdrive = true;
}
else if(phodevi::is_mesa_graphics() && pts_client::executable_in_path('radeontop'))
if(phodevi::is_mesa_graphics() && pts_client::executable_in_path('radeontop'))
{
$this->probe_radeontop = true;
}
@@ -119,12 +110,6 @@ class gpu_usage extends phodevi_sensor
return false;
}
private static function ati_overdrive_core_usage()
{
return phodevi_linux_parser::read_ati_overdrive('GPUload');
}
private static function nvidia_core_usage()
{
$nvidia_smi = shell_exec(escapeshellarg(pts_client::executable_in_path('nvidia-smi')) . ' -a');

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2009 - 2017, Phoronix Media
Copyright (C) 2009 - 2017, Michael Larabel
Copyright (C) 2009 - 2018, Phoronix Media
Copyright (C) 2009 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -30,12 +30,13 @@ class sys_power extends phodevi_sensor
private static $tegra_power = false;
private static $wattsup_meter = false;
private static $ipmitool = false;
private static $windows_battery = false;
public static function get_unit()
{
$unit = null;
if(self::$battery_sys || self::$tegra_power)
if(self::$battery_sys || self::$tegra_power || self::$windows_battery)
{
$unit = 'Milliwatts';
}
@@ -52,6 +53,14 @@ class sys_power extends phodevi_sensor
}
public function support_check()
{
if(phodevi::is_windows())
{
if(self::windows_wmi_battery_status_discharge() > 0)
{
self::$windows_battery = true;
}
return true;
}
$test = self::sys_battery_power();
if(is_numeric($test) && $test != -1)
{
@@ -122,6 +131,22 @@ class sys_power extends phodevi_sensor
{
return phodevi_linux_parser::read_ipmitool_sensor('Node Power');
}
else if(self::$windows_battery)
{
return self::windows_wmi_battery_status_discharge();
}
}
private static function windows_wmi_battery_status_discharge()
{
$output = trim(shell_exec('powershell (Get-WmiObject -Namespace "root\wmi" BatteryStatus).DischargeRate'));
if(!empty($output) && is_numeric($output) && $output > 0)
{
return $output;
}
else
{
return -1;
}
}
private static function watts_up_power_meter()
{

View File

@@ -182,6 +182,7 @@ abstract class pts_graph_core
$this->results = array();
if($this->i['is_multi_way_comparison'])
{
$this->test_result->test_result_buffer->adjust_precision();
foreach($this->test_result->test_result_buffer->buffer_items as $i => &$buffer_item)
{
if($buffer_item->get_result_value() === null)
@@ -208,8 +209,7 @@ abstract class pts_graph_core
$date = $identifier[0];
break;
default:
continue;
break;
continue 2;
}
/*if(in_array($buffer_item->get_result_identifier(), $this->graph_identifiers))
{
@@ -237,6 +237,7 @@ abstract class pts_graph_core
}
else if(isset($this->test_result->test_result_buffer))
{
$this->test_result->test_result_buffer->adjust_precision();
foreach($this->test_result->test_result_buffer->buffer_items as $i => &$buffer_item)
{
if($buffer_item->get_result_value() === null)
@@ -441,45 +442,12 @@ abstract class pts_graph_core
}
protected function identifier_to_branded_color($identifier, $fallback_color = null)
{
if($this->i['support_color_branding'] == false || !isset($identifier[6]))
if($this->i['support_color_branding'] == false || !isset($identifier[5]))
{
return $fallback_color;
}
// See if the result identifier matches something to be color-coded better
$identifier = strtolower($identifier) . ' ';
if(strpos($identifier, 'geforce') !== false || strpos($identifier, 'nvidia') !== false || strpos($identifier, 'quadro') !== false)
{
$paint_color = '#77b900';
}
else if(strpos($identifier, 'radeon') !== false || strpos($identifier, 'amd ') !== false || stripos($identifier, 'EPYC') !== false || strpos($identifier, 'opteron ') !== false || strpos($identifier, 'fx-') !== false || strpos($identifier, 'firepro ') !== false || strpos($identifier, 'ryzen ') !== false || strpos($identifier, 'threadripper ') !== false || strpos($identifier, 'a10-') !== false)
{
$paint_color = '#f1052d';
}
else if(strpos($identifier, 'intel ') !== false || strpos($identifier, 'xeon ') !== false || strpos($identifier, 'core i') !== false || strpos($identifier, 'pentium') !== false || strpos($identifier, 'celeron') !== false)
{
$paint_color = '#0b5997';
}
else if(strpos($identifier, 'bsd') !== false)
{
$paint_color = '#850000';
}
else if(stripos($identifier, 'windows ') !== false || stripos($identifier, 'Microsoft') !== false)
{
$paint_color = '#373277';
}
else if(stripos($identifier, 'ec2 ') !== false || stripos($identifier, 'Amazon') !== false)
{
$paint_color = '#ff9900';
}
else if(stripos($identifier, 'google') !== false)
{
$paint_color = '#4885ed';
}
else
{
$paint_color = $fallback_color;
}
$paint_color = pts_render::identifier_to_brand_color($identifier, $fallback_color);
if($paint_color != $fallback_color && strpos($identifier, ' - '))
{
@@ -847,7 +815,13 @@ abstract class pts_graph_core
$tick_width = round(($left_end - $left_start) / $this->i['mark_count']);
$display_value = $this->i['graph_min_value'];
$g = $this->svg_dom->make_g(array('font-size' => self::$c['size']['tick_mark'], 'fill' => self::$c['color']['text'], 'text-anchor' => 'middle'));
$tick_font_size = self::$c['size']['tick_mark'];
while($this->i['graph_max_value'] > 100000 && self::text_string_width($this->i['graph_max_value'], $tick_font_size) + 4 > $tick_width)
{
$tick_font_size--;
}
$g = $this->svg_dom->make_g(array('font-size' => $tick_font_size, 'fill' => self::$c['color']['text'], 'text-anchor' => 'middle'));
$g_lines = $this->svg_dom->make_g(array('stroke' => self::$c['color']['body'], 'stroke-width' => 1));
for($i = 0; $i < $this->i['mark_count']; $i++)
{

View File

@@ -55,9 +55,9 @@ class pts_graph_horizontal_bars extends pts_graph_core
$middle_of_vert += $this->i['identifier_height'];
if($this->i['is_multi_way_comparison'])
{
foreach(explode(' - ', $identifier) as $i => $identifier_line)
foreach(array_reverse(explode(' - ', $identifier)) as $i => $identifier_line)
{
$x = 8;
$x = 8 + ($i * (1.2 * $this->i['identifier_size']));
$this->svg_dom->add_text_element($identifier_line, array('x' => $x, 'y' => $middle_of_vert, 'text-anchor' => 'middle', 'transform' => 'rotate(90 ' . $x . ' ' . $middle_of_vert . ')'), $g);
}
}

View File

@@ -96,6 +96,12 @@ class pts_graph_vertical_bars extends pts_graph_core
$bar_count = count($this->results);
$separator_width = ($a = (8 - (floor($bar_count / 2) * 2))) > 0 ? $a : 0;
$bar_width = floor(($this->i['identifier_width'] - $separator_width - ($bar_count * $separator_width)) / $bar_count);
$bar_font_size_ratio = 1;
while(floor($bar_width * 0.8) < self::text_string_width($this->i['graph_max_value'] + 0.01, floor(self::$c['size']['bars'] * $bar_font_size_ratio)) && $bar_font_size_ratio >= 0.6)
{
$bar_font_size_ratio -= 0.1;
}
$i_o = 0;
foreach($this->results as $identifier => &$group)
@@ -140,13 +146,13 @@ class pts_graph_vertical_bars extends pts_graph_core
*/
$this->svg_dom->add_element('rect', array('x' => ($px_bound_left + 1), 'y' => $value_plot_top, 'width' => $bar_width, 'height' => ($this->i['graph_top_end'] - $value_plot_top), 'fill' => $this->adjust_color($buffer_item->get_result_identifier(), $paint_color), 'stroke' => self::$c['color']['body_light'], 'stroke-width' => 1, 'xlink:title' => $title_tooltip));
if(($px_bound_right - $px_bound_left) > 18)
if(($px_bound_right - $px_bound_left) > 10)
{
// The bars are too skinny to be able to plot anything on them
if($bar_width > self::text_string_width($value, floor(self::$c['size']['bars'] * 0.9)))
if($bar_font_size_ratio >= 0.6)
{
$x = $px_bound_left + (($px_bound_right - $px_bound_left) / 2);
$this->svg_dom->add_text_element($value, array('x' => $x, 'y' => ($value_plot_top + 2), 'font-size' => floor(self::$c['size']['bars'] * 0.9), 'fill' => self::$c['color']['body_text'], 'text-anchor' => 'middle', 'dominant-baseline' => 'text-before-edge'));
$this->svg_dom->add_text_element($value, array('x' => $x, 'y' => ($value_plot_top + 2), 'font-size' => floor(self::$c['size']['bars'] * $bar_font_size_ratio), 'fill' => self::$c['color']['body_text'], 'text-anchor' => 'middle', 'dominant-baseline' => 'text-before-edge'));
}
}
$i++;

View File

@@ -30,8 +30,9 @@ class pts_element_node
protected $documentation;
protected $default_value;
protected $flags;
protected $path;
public function __construct($name, $value = null, $input_type_restrictions = null, $api = null, $documentation = null, $api_setter = null, $default_value = null, $flags = null)
public function __construct($name, $value = null, $input_type_restrictions = null, $api = null, $documentation = null, $api_setter = null, $default_value = null, $flags = null, $path = null)
{
$this->name = $name;
$this->value = $value;
@@ -41,6 +42,7 @@ class pts_element_node
$this->api_setter = $api_setter;
$this->default_value = $default_value;
$this->flags = $flags;
$this->path = $path;
}
public function get_name()
{
@@ -78,5 +80,13 @@ class pts_element_node
{
return explode(' ', $this->flags);
}
public function set_path($path)
{
$this->path = $path;
}
public function get_path()
{
return $this->path;
}
}
?>

View File

@@ -71,6 +71,10 @@ class pts_input_type_restrictions
{
return $this->enums;
}
public function is_enums_empty()
{
return empty($this->enums);
}
public function set_enums($enums)
{
$this->enums = $enums;

View File

@@ -501,6 +501,20 @@ class pts_network
}
}
if(empty($local_ip) && function_exists('net_get_interfaces'))
{
// The below code should work as of net_get_interfaces() as of PHP 7.3 in cross-platform manner
$net_interfaces = net_get_interfaces();
foreach($net_interfaces as $interface => $interface_info)
{
if(isset($interface_info['unicast'][1]['address']) && !empty($interface_info['unicast'][1]['address']) && $interface_info['unicast'][1]['address'] != '127.0.0.1')
{
$local_ip = $interface_info['unicast'][1]['address'];
break;
}
}
}
return $local_ip;
}
public static function get_network_mac()

View File

@@ -336,26 +336,29 @@ class pts_openbenchmarking
$repo_index = json_decode(file_get_contents($index_file), true);
$generated_time = $repo_index['main']['generated'];
// Refreshing the indexes once every few days should be suffice
// Refresh approximately every three days by default
$index_cache_ttl = 3;
if(PTS_IS_CLIENT && ($config_ttl = pts_config::read_user_config('PhoronixTestSuite/Options/OpenBenchmarking/IndexCacheTTL')))
if($force_refresh == false)
{
if($config_ttl === 0)
// Refreshing the indexes once every few days should be suffice
// Refresh approximately every three days by default
$index_cache_ttl = 3;
if(PTS_IS_CLIENT && ($config_ttl = pts_config::read_user_config('PhoronixTestSuite/Options/OpenBenchmarking/IndexCacheTTL')))
{
// if the value is 0, only rely upon manual refreshes
if($config_ttl === 0)
{
// if the value is 0, only rely upon manual refreshes
continue;
}
else if(is_numeric($config_ttl) && $config_ttl >= 1)
{
$index_cache_ttl = $config_ttl;
}
}
if($generated_time > (time() - (86400 * $index_cache_ttl)) && (!defined('FIRST_RUN_ON_PTS_UPGRADE') || FIRST_RUN_ON_PTS_UPGRADE == false))
{
// The index is new enough
continue;
}
else if(is_numeric($config_ttl) && $config_ttl >= 1)
{
$index_cache_ttl = $config_ttl;
}
}
if($generated_time > (time() - (86400 * $index_cache_ttl)) && $force_refresh == false && (!defined('FIRST_RUN_ON_PTS_UPGRADE') || FIRST_RUN_ON_PTS_UPGRADE == false))
{
// The index is new enough
continue;
}
$old_index = $repo_index;
@@ -498,6 +501,10 @@ class pts_openbenchmarking
return $index_file;
}
public static function is_test_profile_downloaded($qualified_identifier)
{
return is_file(PTS_TEST_PROFILE_PATH . $qualified_identifier . '/test-definition.xml');
}
public static function download_test_profile($qualified_identifier, $download_location = null, $cache_check = false)
{
if(empty($download_location))
@@ -646,7 +653,7 @@ class pts_openbenchmarking
return null;
}
public static function available_tests($download_tests = true, $all_versions = false, $append_versions = false, $show_deprecated_tests = false)
public static function available_tests($download_tests = true, $all_versions = false, $append_versions = false, $show_deprecated_tests = false, $only_show_available_cached_tests = false)
{
$available_tests = array();
@@ -684,6 +691,21 @@ class pts_openbenchmarking
}
}
if($only_show_available_cached_tests)
{
if(!pts_openbenchmarking::is_test_profile_downloaded($identifier . '-' . $version))
{
// Without Internet, won't be able to download test, so don't show it
continue;
}
$test_profile = new pts_test_profile($identifier . '-' . $version);
if(pts_test_install_request::test_files_available_via_cache($test_profile) == false)
{
// Without Internet, only show tests where files are local or in an available cache
continue;
}
}
$available_tests[] = $repo . '/' . $identifier . ($append_versions ? '-' . $version : null);
}
}

View File

@@ -155,7 +155,7 @@ class pts_render
$result_identifiers = $result_object->test_result_buffer->get_identifiers();
// COMPACT PROCESS
if(!isset($extra_attributes['compact_to_scalar']) && $result_object->test_profile->get_display_format() == 'LINE_GRAPH' && ($result_file->get_system_count() > 6 || $result_file->is_multi_way_comparison($result_identifiers, $extra_attributes)))
if(!isset($extra_attributes['compact_to_scalar']) && $result_object->test_profile->get_display_format() == 'LINE_GRAPH' && ($result_file->get_system_count() > 7 || $result_file->is_multi_way_comparison($result_identifiers, $extra_attributes)))
{
// If there's too many lines being plotted on line graph, likely to look messy, so convert to scalar automatically
$extra_attributes['compact_to_scalar'] = true;
@@ -225,7 +225,7 @@ class pts_render
$result_object->test_profile->set_display_format('BAR_GRAPH');
}
else if($big_data_set > 0 && pts_graph_core::get_graph_config('style', 'allow_box_plots'))
else if($big_data_set > 0 && pts_graph_core::get_graph_config('style', 'allow_box_plots') && !isset($extra_attributes['no_box_plots']))
{
$result_object->test_profile->set_display_format('HORIZONTAL_BOX_PLOT');
}
@@ -298,6 +298,54 @@ class pts_render
return $graph;
}
public static function identifier_to_brand_color($identifier, $fallback_color = null)
{
static $cache;
if(isset($cache[$identifier]))
{
return $cache[$identifier] != null ? $cache[$identifier] : $fallback_color;
}
// See if the result identifier matches something to be color-coded better
$i = strtolower($identifier) . ' ';
if(strpos($i, 'geforce') !== false || strpos($i, 'nvidia') !== false || strpos($i, 'quadro') !== false || strpos($i, 'rtx ') !== false || strpos($i, 'gtx ') !== false)
{
$paint_color = '#77b900';
}
else if(strpos($i, 'radeon') !== false || strpos($i, 'amd ') !== false || stripos($i, 'EPYC') !== false || strpos($i, 'opteron ') !== false || strpos($i, 'fx-') !== false || strpos($i, 'firepro ') !== false || strpos($i, 'ryzen ') !== false || strpos($i, 'threadripper ') !== false || strpos($i, 'a10-') !== false || strpos($i, 'athlon ') !== false || strpos($i, 'r9 ') !== false || strpos($i, 'r7 ') !== false || strpos($i, 'hd 7') !== false || strpos($i, 'rx ') !== false)
{
$paint_color = '#f1052d';
}
else if(strpos($i, 'intel ') !== false || strpos($i, 'xeon ') !== false || strpos($i, 'core i') !== false || strpos($i, 'pentium') !== false || strpos($i, 'celeron') !== false)
{
$paint_color = '#0b5997';
}
else if(strpos($i, 'bsd') !== false)
{
$paint_color = '#850000';
}
else if(stripos($i, 'windows ') !== false || stripos($i, 'Microsoft') !== false)
{
$paint_color = '#373277';
}
else if(stripos($i, 'ec2 ') !== false || stripos($i, 'Amazon') !== false)
{
$paint_color = '#ff9900';
}
else if(stripos($i, 'google') !== false)
{
$paint_color = '#4885ed';
}
else
{
$paint_color = $fallback_color;
}
$cache[$identifier] = $paint_color != $fallback_color ? $paint_color : null;
return $paint_color;
}
public static function report_system_notes_to_table(&$result_file, &$table)
{
$identifier_count = 0;

View File

@@ -3,8 +3,8 @@
/*
Phoronix Test Suite
URLs: http://www.phoronix.com, http://www.phoronix-test-suite.com/
Copyright (C) 2010 - 2016, Phoronix Media
Copyright (C) 2010 - 2016, Michael Larabel
Copyright (C) 2010 - 2018, Phoronix Media
Copyright (C) 2010 - 2018, Michael Larabel
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -101,7 +101,7 @@ class pts_result_file_analyzer
pts_result_file_analyzer::compact_result_table_data($data, $identifiers, true);
$desc = pts_result_file_analyzer::analyze_system_component_changes($data, $rows, array(
array('Memory', 'Graphics', 'Display Driver', 'OpenGL'),
array('Graphics', 'Display Driver', 'OpenGL', 'Vulkan'), array('Graphics', 'Display Driver', 'OpenGL', 'OpenCL', 'Vulkan'), array('Graphics', 'Display Driver', 'OpenCL'), array('Graphics', 'Monitor', 'Kernel', 'Display Driver', 'OpenGL'), array('Graphics', 'Monitor', 'Display Driver', 'OpenGL'), array('Graphics', 'Kernel', 'Display Driver', 'OpenGL'), array('Graphics', 'Display Driver', 'OpenGL'), array('Graphics', 'OpenGL'), array('Graphics', 'Kernel'), array('Graphics', 'Display Driver') // All potential graphics comparisons
array('Graphics', 'Display Driver', 'OpenGL', 'Vulkan'), array('Graphics', 'Kernel', 'Display Driver', 'OpenGL', 'Vulkan'), array('Graphics', 'Display Driver', 'OpenGL', 'OpenCL', 'Vulkan'), array('Graphics', 'Display Driver', 'OpenCL'), array('Graphics', 'Monitor', 'Kernel', 'Display Driver', 'OpenGL'), array('Graphics', 'Monitor', 'Display Driver', 'OpenGL'), array('Graphics', 'Kernel', 'Display Driver', 'OpenGL'), array('Graphics', 'Display Driver', 'OpenGL'), array('Graphics', 'OpenGL'), array('Graphics', 'Kernel'), array('Graphics', 'Display Driver') // All potential graphics comparisons
), $return_all_changed_indexes);
}

Some files were not shown because too many files have changed in this diff Show More