aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick/benchmark/scenarios/compute
diff options
context:
space:
mode:
authorrexlee8776 <limingjiang@huawei.com>2017-11-16 08:49:16 +0000
committerrexlee8776 <limingjiang@huawei.com>2017-12-13 02:46:28 +0000
commit7bd43b239b7be6f478399526a177922d4482bcc2 (patch)
tree6203df4e3a3d18fcc769c82e768bc5213b281151 /yardstick/benchmark/scenarios/compute
parentce52059f5f78912eeff2d97235c1028c218bf960 (diff)
bugfix: tc078 fails in some situations
1. make "SPECint_benchmark, runspec_iterations, runspec_tune, runspec_size, runspec_rate" parameterized and change the default value "int^429" to "int" 2. remove "become: true" in some roles since it does not need root privilege JIRA: YARDSTICK-852 Change-Id: Icb384bddc12911e2681a981d0504e0e142d1a8ec Signed-off-by: rexlee8776 <limingjiang@huawei.com>
Diffstat (limited to 'yardstick/benchmark/scenarios/compute')
-rw-r--r--yardstick/benchmark/scenarios/compute/spec_cpu.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/yardstick/benchmark/scenarios/compute/spec_cpu.py b/yardstick/benchmark/scenarios/compute/spec_cpu.py
index df361cd94..0294f524d 100644
--- a/yardstick/benchmark/scenarios/compute/spec_cpu.py
+++ b/yardstick/benchmark/scenarios/compute/spec_cpu.py
@@ -10,6 +10,7 @@ from __future__ import absolute_import
import logging
import pkg_resources
+import os
import yardstick.ssh as ssh
from yardstick.benchmark.scenarios import base
@@ -66,6 +67,7 @@ class SpecCPU(base.Scenario):
default: na
"""
__scenario_type__ = "SpecCPU2006"
+ CPU2006_DIR = "~/cpu2006"
def __init__(self, scenario_cfg, context_cfg):
self.scenario_cfg = scenario_cfg
@@ -87,8 +89,9 @@ class SpecCPU(base.Scenario):
"yardstick.resources", 'files/' + self.runspec_config)
# copy SPEC CPU2006 config file to host if given
- self.client._put_file_shell(self.runspec_config_file,
- '/usr/cpu2006/config/yardstick_spec_cpu2006.cfg')
+ cfg_path = os.path.join(self.CPU2006_DIR,
+ 'config/yardstick_spec_cpu2006.cfg')
+ self.client._put_file_shell(self.runspec_config_file, cfg_path)
else:
self.runspec_config = "Example-linux64-amd64-gcc43+.cfg"
@@ -100,7 +103,8 @@ class SpecCPU(base.Scenario):
if not self.setup_done:
self.setup()
- cmd = "cd /usr/cpu2006/ && . ./shrc && runspec --config %s" % self.runspec_config
+ cmd = "cd %s && . ./shrc && runspec --config %s" % (
+ self.CPU2006_DIR, self.runspec_config)
cmd_args = ""
if "rate" in self.options: