CPU Operations

CPU performance monitoring, profiling, and testing commands.

CPULoad

Run a CPU-Load test on the DUT.

AttributeTypeRequiredDefaultDescription
cmdconstYescpuloadCommand Name
namestringYesName to uniquely identify the teststep. This name will show up in reports, logs and the WebUI
transportTransportObjectNoAdditional transport options
optionsOptionsObjectNoAdditional command options
parametersCPULoadOptionsNoparameterscpuload Options

CPULoad Options

AttributeTypeRequiredDefaultDescription
args[]stringYesArray of strings with arguments passed into the cpuload tool.
cpus[]integerYesArray of CPUs that should be put under load.
durationstringYesDuration of the load. Format: ^((\\d+h)?(\\d+m)?(\\d+s)?)?$
expectCPUExpectOptionsYesExpected values

CPULoad Example

cmd: cpuload
name: Check cpu frequencies with load
transport: *transport
options:
  timeout: 2m
parameters:
  duration: 1m
  expect:
    individual:
      - cpus: [0, 1, 2, 3, 4, 5, 6, 7]
        option: AverageFrequency
        value: ">1500"
      - cpus: [8, 9, 10, 11, 12, 13, 14, 15]
        option: AverageFrequency
        value: ">1200"

CPUSet

Set cpu profiles on the DUT.

AttributeTypeRequiredDefaultDescription
cmdconstYescpusetCommand Name
namestringYesName to uniquely identify the teststep. This name will show up in reports, logs and the WebUI
transportTransportObjectNoAdditional transport options
optionsOptionsObjectNoAdditional command options
parametersCPUSetOptionsYesOptions passed into the cpuset cmd

CPUSet Options

AttributeTypeRequiredDefaultDescription
commandstringYesCommand to run. Available options: core, or profile.
cores[]integerNoArray of Cores where the command should be applied to. If not set apply to all
argstringYesValue of the command option

CPUSet Example

cmd: cpuset
name: Set ACPI Platform Profile to low-power
transport: *transport
parameters:
  command: profile
  arg: low-power

CPUStats

Monitor and validate CPU statistics on the DUT.

AttributeTypeRequiredDefaultDescription
cmdconstYescpustatsCommand Name
namestringYesName to uniquely identify the teststep. This name will show up in reports, logs and the WebUI
transportTransportObjectNoAdditional transport options
optionsOptionsObjectNoAdditional command options
parametersCPUStatsOptionsYesparameterscpustats Options

CPUStats Options

AttributeTypeRequiredDefaultDescription
intervalstringNoTesting interval time
expectCPUExpectOptionsYesExpected values

CPU Expect Options

AttributeTypeRequiredDefaultDescription
general[]GeneralObjectNoexpectGeneral Expected Values
individual[]IndividualObjectNoIndividual CPU Expected Values

General Object

AttributeTypeRequiredDefaultDescription
optionstringNogeneralName of the option
valuestringNogeneralValue of the option

Individual Object

AttributeTypeRequiredDefaultDescription
cpus[]integerYesindividualArray of CPUs where the option should be applied to
optionstringYesindividualName of the option
valuestringYesindividualValue of the option

CPUStats Example

cmd: cpustats
name: Check cpu frequencies in idle
transport: *transport
parameters:
  interval: 10s
  expect:
    individual:
      - cpus: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]
        option: AverageFrequency
        value: "<500"

SysBench

Run SysBench on the DUT.

AttributeTypeRequiredDefaultDescription
cmdconstYessysbenchCommand Name
namestringYesName to uniquely identify the teststep. This name will show up in reports, logs and the WebUI
transportTransportObjectYesAdditional transport options
optionsOptionsObjectNoAdditional command options
parametersSysBenchOptionsYesOptions passed into the sysbench cmd

SysBench Options

AttributeTypeRequiredDefaultDescription
args[]stringNoArguments to pass to sysbench.
expect[]ExpectOptionsYesExpectations to check against the output of sysbench.

SysBench Expect Options

AttributeTypeRequiredDefaultDescription
optionstringYesOption to check
valuestringYesExpected value

SysBench Example

cmd: sysbench
name: Benchmark
transport: *transport
parameters:
  args: [cpu, --cpu-max-prime=20000, --threads=18, --time=60, run]
  expect:
    - option: EventsPerSecond
      value: <4500