CPUStats

Monitor and validate CPU statistics on the DUT. The DUT needs sudo and turbostat.

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

Values that describe the machine as a whole.

AttributeTypeRequiredDefaultDescription
optionstringNogeneralName of the option
valuestringNogeneralValue of the option

option must be one of:

OptionUnitDescription
CPUsLogicalcountLogical CPUs the machine reports
CPUsPhysicalcountPhysical cores the machine reports
ProfileACPI platform profile, for example balanced
CurPowerConsumptionwattsPackage power drawn during the sample
PowerLimit1wattsSustained package power limit
PowerLimit2wattsShort-term package power limit

Individual Object

Values measured per core. Cores that are switched off do not appear in the sample, and naming one fails the step rather than matching a different core.

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

option must be one of:

OptionUnitDescription
BusypercentShare of the sample the core spent executing
AverageFrequencyMHzMean frequency over the whole sample, idle time included
BusyFrequencyMHzMean frequency while the core was executing
CStatespercentIdle-state residency, written as C1E,C6,C10:>95

CStates takes one or more state names separated by commas, then a colon and the bound their residencies must add up to. Every other option compares a single number.

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"