Tims_0day_notes 

Fuego 1.0 wiki

Login

Tims 0day notes

0day is a performance and regression test system developed by Fengguan Wu of Intel's open source development center.

Puts each test (named a 'job') into a yaml file

lkp is a command line tool for executing a test

some command line options are:

  • lkp install <test_package>
    • ls $LKP_SRC/jobs to see available jobs
  • lkp split-job <test_package>
  • lkp run
  • lkp result <testname>

Here's what a test looks like:

From the file tbench.yaml

    suite: tbench
    testcase: tbench
    category: benchmark
    
    # upto 40% CPU cycles may be used by latency stats
    disable_latency_stats: 1
    
    nr_threads: 100%
    
    cluster: cs-localhost
    
    if role server:
      tbench-server:
    
    if role client:
      tbench:

In the 'linpack' directory are some PKGBUILD files. This appears to be the package file format for Arch Linux.

Each test has a 'maker script' that tells how to build and install the test program. See pack/ebizzy for an example.

directory structure [edit section]

Here is the directory structure for lkp-tests:
  • allot
  • bin
  • cluster
  • daemon
  • distro
  • doc
  • etc
  • filters
  • hosts
  • include
  • jobs - has parameters for a particular execution of the test program (similar to fuegos specs and plans)
  • lib
  • lkp-exec
  • monitors
  • pack - has the maker script which does the fetch, build, install for a test program
  • params
  • pkg
  • plot
  • repo
  • rootfs
  • sbin
  • setup
  • spec
  • stats - has the results parser for each test - output is JSON
  • tests - has the main test script for each test
  • tmp
  • tools

dependency processing [edit section]

  • in lkp-tests/tests/pack-dep - check_shared_package

  • in jobs/ftrace_onoff.yaml:need_memory: 2G
  • in jobs/phoronix-test-suite-neex.yaml:need_x true
  • in include/ndctl:need_kernel_headers: true
  • in include/ltp:need_kconfig: CONFIG_BLK_DEV_LOOP
  • in filters/need_cpu: if (( need_cpu > nr_cpu )); then
  • in jobs/README.md: need_*

The file include/kernel_selftests has the following content:

    need_kernel_headers: true
    need_kconfig:
    - CONFIG_TEST_FIRMWARE
    - CONFIG_TEST_BPF
    - CONFIG_TEST_USER_COPY
    - CONFIG_MEMORY_NOTIFIER_ERROR_INJECT
    - CONFIG_MEMORY_HOTPLUG_SPARSE=y
    - CONFIG_NOTIFIER_ERROR_INJECTION
    - CONFIG_FTRACE=y

test execution [edit section]

job.yaml files are converted into job.sh files for execution by sbin/job2sh.

Items in the yaml file are converted either to environment variables, or to references to setup scripts or test scripts.

See jobs/README.md for details.

TBWiki engine 1.9.2 by Tim Bird