summaryrefslogtreecommitdiff
path: root/ubuntu/hackbench.yaml
blob: c7098f9363df11d8e4be518cb717f5cbb581bcae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
metadata:
    name: hackbench
    format: "Lava-Test-Shell Test Definition 1.0"
    description: "Test hackbench (rt-tests version) on Ubuntu. Hackbench works by creating multiple
                  pairs of threads or processes, that pass data between themselves over pipes."
    maintainer:
        - milosz.wasilewski@linaro.org
    scope:
        - functional
        - virtualization
    os:
        - ubuntu
    devices:
        - arndale
        - vexpress-tc2
        - juno

install:
    deps:
        - rt-tests
        - python-numpy
        - coreutils

params:
    TARGET: 'host'
    # Sends the data via a pipe instead of the socket (default)
    USE_PIPE: 'false'
    # Sets the amount of data to send in each message
    DATASIZE: 100
    # How many messages each sender/receiver pair should send
    LOOPS: 100
    # Defines how many groups of senders and receivers should be started
    GRPS: 10
    # Defines how many file descriptors each child should use.  Note that the
    # effective number will be twice the amount you set here, as the sender
    # and receiver children will each open the given amount of file descriptors.
    FDS: 20
    # Each sender/receiver child will be a POSIX thread of the parent.
    # The default is to run in process mode (-P)
    USE_THREADS: 'false'
    # Number of cycles hackbench is called (for loop repetitions)
    REPEAT: 1000

run:
    steps:
        - OPTIONS="-s $DATASIZE -l $LOOPS -g $GRPS -f $FDS"
        - if [ "$USE_PIPE" != "false" ]; then OPTIONS=${OPTIONS}" -p"; fi
        - if [ "$USE_THREADS" != "false" ]; then OPTIONS=${OPTIONS}" -T"; fi
        - echo $OPTIONS
        - i=1
        - while [ $i -le $REPEAT ]; do timeout 10s hackbench ${OPTIONS} | tee -a hackbench_res_$TARGET.txt; true $(( i++ )); done
        - ./common/scripts/min_max_avg_parse.py hackbench_res_$TARGET.txt "Time:" "Seconds"

parse:
    pattern: '^(?P<test_case_id>[^:]+):\s*(?P<measurement>[0-9.]+)\s+(?P<units>\w+)\s+(?P<result>\w+)'