一、UnixBench 简介
- UnixBench 原本叫做 BYTE UNIX benchmark suite。软件为 Unix 类的系统提供了一些基本的性能指标。通过不同的测试来测试系统不同方面的性能(2D,3D,CPU,内存等等)。这些测试的结果将和一些标准的系统来做比较,从而得出一些性能指数,比原始 的测试数据容容易理解。
- UnixBench一个基于系统的基准测试工具,不单纯是CPU 内存 或者磁盘测试工具。测试结果不仅仅取决于硬件,也取决于系统、开发库、甚至是编译器。
- UnixBench测试执行完大约需要10-30分钟。
备注:UnixBench性能测试工具新版本改动研究
1.1 UnixBench 测试项目
- Dhrystone 2 using register variables
- Double-Precision Whetstone
- Execl Throughput
- File Copy 1024 bufsize 2000 maxblocks
- File Copy 256 bufsize 500 maxblocks
- File Copy 4096 bufsize 8000 maxblocks
- Pipe Throughput
- Pipe-based Context Switching
- Process Creation
- System Call Overhead
- Shell Scripts
二、UnixBench 测试
2.1 获取UnixBench
git clone https://github.com/kdlucas/byte-unixbench
2.2 编译
cd byte-unixbench/UnixBench
make
2.3 运行
./Run
三、测试结果
硬件龙芯平台
- 硬件ls3a6000+7a2000
- 系统loonnix20.5
3.1 运行截图
UnixBench# ./Run
make all
make[1]: Entering directory '/home/test/work/tools/byte-unixbench/UnixBench'
make distr
make[2]: Entering directory '/home/test/work/tools/byte-unixbench/UnixBench'
Checking distribution of files
./pgms exists
./src exists
./testdir exists
./tmp exists
./results exists
make[2]: Leaving directory '/home/test/work/tools/byte-unixbench/UnixBench'
make programs
make[2]: Entering directory '/home/test/work/tools/byte-unixbench/UnixBench'
make[2]: Nothing to be done for'programs'.
make[2]: Leaving directory '/home/test/work/tools/byte-unixbench/UnixBench'
make[1]: Leaving directory '/home/test/work/tools/byte-unixbench/UnixBench'
sh:1:3dinfo: not found
# # # # # # # ##### ###### # # #### # #
# # ## # # # # # # # ## # # # # #
# # # # # # ## ##### ##### # # # # ######
# # # # # # ## # # # # # # # # #
# # # ## # # # # # # # ## # # # #
#### # # # # # ##### ###### # # #### # #
Version 5.1.3 Based on the Byte Magazine Unix Benchmark
Multi-CPU version Version 5 revisions by Ian Smith,
Sunnyvale, CA, USA
January 13,2011 johantheghost at yahoo period com
------------------------------------------------------------------------------
Use directories for:* File I/O tests(named fs***)=/home/test/work/tools/byte-unixbench/UnixBench/tmp
* Results =/home/test/work/tools/byte-unixbench/UnixBench/results
------------------------------------------------------------------------------1 x Dhrystone 2 using register variables 123456789101 x Double-Precision Whetstone 123456789101 x Execl Throughput 1231 x File Copy 1024 bufsize 2000 maxblocks 1231 x File Copy 256 bufsize 500 maxblocks 1231 x File Copy 4096 bufsize 8000 maxblocks 1231 x Pipe Throughput 123456789101 x Pipe-based Context Switching 123456789101 x Process Creation 1231 x System Call Overhead 123456789101 x Shell Scripts(1 concurrent)1231 x Shell Scripts(8 concurrent)123
Wide character in printf at ./Run line 1574.8 x Dhrystone 2 using register variables 123456789108 x Double-Precision Whetstone 123456789108 x Execl Throughput 1238 x File Copy 1024 bufsize 2000 maxblocks 1238 x File Copy 256 bufsize 500 maxblocks 1238 x File Copy 4096 bufsize 8000 maxblocks 1238 x Pipe Throughput 123456789108 x Pipe-based Context Switching 123456789108 x Process Creation 1238 x System Call Overhead 123456789108 x Shell Scripts(1 concurrent)12^[338 x Shell Scripts(8 concurrent)123
Wide character in printf at ./Run line 1574.========================================================================
BYTE UNIX Benchmarks(Version 5.1.3)
System: test-pc: GNU/Linux
OS: GNU/Linux --4.19.0-19-loongson-3-- #1 SMP 4.19.190.8.14 Thu Aug 2408:54:20 UTC 2023
Machine:loongarch64(loongarch64)
Language: en_US.utf8(charmap="UTF-8", collate="UTF-8")
CPU 0: Loongson-3A6000 (5000.0 bogomips)
CPU 1: Loongson-3A6000 (5000.0 bogomips)
CPU 2: Loongson-3A6000 (5000.0 bogomips)
CPU 3: Loongson-3A6000 (5000.0 bogomips)
CPU 4: Loongson-3A6000 (5000.0 bogomips)
CPU 5: Loongson-3A6000 (5000.0 bogomips)
CPU 6: Loongson-3A6000 (5000.0 bogomips)
CPU 7: Loongson-3A6000 (5000.0 bogomips)15:53:56 up 3 days,20:28,1 user, load average:0.36,0.41,0.37; runlevel 2023-11-02------------------------------------------------------------------------
3.2 单任务性能
Benchmark Run: 一 11月 06202315:53:56-16:21:558 CPUs in system; running 1 parallel copy of tests
Dhrystone 2 using register variables 41104135.1lps(10.0 s,7 samples)
Double-Precision Whetstone 4882.6MWIPS(9.3 s,7 samples)
Execl Throughput 7143.9lps(30.0 s,2 samples)
File Copy 1024 bufsize 2000 maxblocks 1133161.1KBps(30.0 s,2 samples)
File Copy 256 bufsize 500 maxblocks 314827.5KBps(30.0 s,2 samples)
File Copy 4096 bufsize 8000 maxblocks 2770273.0KBps(30.0 s,2 samples)
Pipe Throughput 2130688.7lps(10.0 s,7 samples)
Pipe-based Context Switching 353227.4lps(10.0 s,7 samples)
Process Creation 15592.5lps(30.0 s,2 samples)
Shell Scripts(1 concurrent)14861.6lpm(60.0 s,2 samples)
Shell Scripts(8 concurrent)6354.0lpm(60.0 s,2 samples)
System Call Overhead 2581924.8lps(10.0 s,7 samples)
System Benchmarks Index Values BASELINE RESULT INDEX
Dhrystone 2 using register variables 116700.041104135.13522.2
Double-Precision Whetstone 55.04882.6887.7
Execl Throughput 43.07143.91661.4
File Copy 1024 bufsize 2000 maxblocks 3960.01133161.12861.5
File Copy 256 bufsize 500 maxblocks 1655.0314827.51902.3
File Copy 4096 bufsize 8000 maxblocks 5800.02770273.04776.3
Pipe Throughput 12440.02130688.71712.8
Pipe-based Context Switching 4000.0353227.4883.1
Process Creation 126.015592.51237.5
Shell Scripts(1 concurrent)42.414861.63505.1
Shell Scripts(8 concurrent)6.06354.010590.1
System Call Overhead 15000.02581924.81721.3========
System Benchmarks Index Score 2242.3------------------------------------------------------------------------
3.3 多任务性能
Benchmark Run: 一 11月 06202316:21:55-16:49:588 CPUs in system; running 8 parallel copies of tests
Dhrystone 2 using register variables 220723621.0lps(10.0 s,7 samples)
Double-Precision Whetstone 36175.1MWIPS(9.4 s,7 samples)
Execl Throughput 38363.4lps(29.9 s,2 samples)
File Copy 1024 bufsize 2000 maxblocks 5597370.6KBps(30.0 s,2 samples)
File Copy 256 bufsize 500 maxblocks 1731731.2KBps(30.0 s,2 samples)
File Copy 4096 bufsize 8000 maxblocks 10649295.0KBps(30.0 s,2 samples)
Pipe Throughput 11214848.7lps(10.0 s,7 samples)
Pipe-based Context Switching 1985885.8lps(10.0 s,7 samples)
Process Creation 75309.7lps(30.0 s,2 samples)
Shell Scripts(1 concurrent)50164.3lpm(60.0 s,2 samples)
Shell Scripts(8 concurrent)7509.6lpm(60.0 s,2 samples)
System Call Overhead 18562375.6lps(10.0 s,7 samples)
System Benchmarks Index Values BASELINE RESULT INDEX
Dhrystone 2 using register variables 116700.0220723621.018913.8
Double-Precision Whetstone 55.036175.16577.3
Execl Throughput 43.038363.48921.7
File Copy 1024 bufsize 2000 maxblocks 3960.05597370.614134.8
File Copy 256 bufsize 500 maxblocks 1655.01731731.210463.6
File Copy 4096 bufsize 8000 maxblocks 5800.010649295.018360.9
Pipe Throughput 12440.011214848.79015.2
Pipe-based Context Switching 4000.01985885.84964.7
Process Creation 126.075309.75977.0
Shell Scripts(1 concurrent)42.450164.311831.2
Shell Scripts(8 concurrent)6.07509.612516.0
System Call Overhead 15000.018562375.612374.9========
System Benchmarks Index Score 10330.6
本文转载自: https://blog.csdn.net/tongxin1101124/article/details/134248060
版权归原作者 大、猫 所有, 如有侵权,请联系我们删除。
版权归原作者 大、猫 所有, 如有侵权,请联系我们删除。