基于RedHatEnterpriseLinux V7(RHEL7)下SPEC CPU 2006环境搭建以及测试流程(之二)——测试准备以及基准值测试,


延续上一篇博文,本文主要讲述具体测试的一个过程。

四、测试准备以及基准值测试

1 、运行脚本

运行脚本放在SPECCPU2006安装目录下/cpu2006.

. ./shrc

?#设置环境变量,shrc即为设置脚本

. ./numa-detection.sh

?#numa检测代码,确认是否为numa架构以及cpu、内存信息

ulimit -s unlimited

??#设置线程栈大小没有限制

a=`cat /proc/cpuinfo | grep processor |wc -l`

??#查看逻辑核数

rm -rf topo.txt

?

specperl nhmtopology.pl?#执行nhmtopology.pl脚本,返回结果physcialfirst或者physicallogical,分别表示是否开启超线程,一般现在返回的均为physicalfirst

?

b=`cat topo.txt`

?

c=`expr $a / 2`

?#物理核数量

echo"****************************************************************"

?

echo Running rate with $a copies on anAVX2 system with a topology of $b

?

echo"****************************************************************"

?

?echo 1 >??????/proc/sys/vm/drop_caches

?#清空cache缓存内容,

???numactl --interleave=all runspec --define invoke_with_interleave--define default-platform-flags --rate $a -c?cpu2006-1.2-ic16.0u2-lin64-ws-avx2-rate-20160328.cfg --define smt--define cores=$c --define $b --define invoke_with_interleave --define drop_caches--define THP_enabled -T all -o all fp

?#运行浮点测试,这个runspec进程使用interleav=all的内存分配策略,可以在所有的内存和cpu上进行负载均衡策略。--rate?表示运行copy的数量为192;-T all表示测试所有的集合(base和peak),同时-o all表示测试集的大小为(test、ref)。

???numactl --interleave=all runspec --define invoke_with_interleave--define default-platform-flags --rate $a -c?cpu2006-1.2-ic16.0u2-lin64-ws-avx2-rate-20160328.cfg --define smt--define cores=$c --define $b --define invoke_with_interleave --definedrop_caches --define THP_enabled? -T all-o all int

?#同fp一样的测试脚本

2、BIOS准备工作

上述准备工作完成后,需要配置BIOS相关内容。必须设置的几项,如下图所示

Energy Performance Tuning

BIOS

Energy Performance BIAS

Performance

Workload Configuration

Balanced

Hyper-Threading

Enable

Intel Virtualization Technology

Disable

Power Technology

Custom

Package C Sstate limit

C0/C1 state

CPU C3 report

Disable

CPU C6 report

Enable

Enhanced Halt State(C1E)

Disable

EIST(P-State)

Enable

ACPI T-State

Disable

VMSE Lockstep mode

2:1 mode

Memory Interleaving

2-way Node Interleave

Channel /Rank Interleaving

Auto

COD Enable

Enable

?BIOS是十分重要的一个环节,它对于最终结果的影响十分大,因此合理的BIOS设置十分重要。上表中列出常用的几个选项,更加深入的可以研究memory interleave和channel/rank interleaving相关选项,这些选项和numa架构相关,影响重大。

基准测试

问题:选择最小化安装的操作系统,(一般首先使用redhat进行测试得到一个基准值,用来和Neokylin进行比较,作为后续基准值)

本次测试直接利用Neokylin作为测试系统,进行基准测试。

出现问题:最初利用GUI测试,但是具体的细节不能记忆很清楚,没有记录下来checklist,导致不可重复性。?

后续利用最小化安装(具体如安装操作系统准备处),关闭有些服务。安装完成编译器和SPECPU2006,并利用运行脚本开始测试。测试中base结果为测试的重点目标,而且测试脚本中我们会将iterations设置为1,来减少测试时间。?

测试结果:?

SPECfp(R)_rate_base2006????????? 2270

SPECint(R)_rate_base2006????????? 3410

?

相关内容