| 1 | metadata: |
| 2 | format: Lava-Test Test Definition 1.0 |
| 3 | name: babeltrace 2.0 benchmark |
| 4 | description: "Run benchmark for babeltrace" |
| 5 | params: |
| 6 | TRACE_LOCATION: "https://obj.internal.efficios.com/lava/traces/benchmark/babeltrace/babeltrace_benchmark_trace.tar.gz" |
| 7 | COMMIT: "invalid" |
| 8 | GIT_URL: "https://github.com/efficios/babeltrace.git" |
| 9 | run: |
| 10 | steps: |
| 11 | - apt install -y time |
| 12 | - git clone ${GIT_URL} babeltrace |
| 13 | - pushd babeltrace |
| 14 | - git checkout ${COMMIT} |
| 15 | - ./bootstrap |
| 16 | - ./configure --disable-man-pages |
| 17 | - make -j |
| 18 | - make install |
| 19 | - ldconfig |
| 20 | - if [ -a /usr/local/bin/babeltrace ] ; then echo "Running bt1"; else ln -s /usr/local/bin/babeltrace2 /usr/local/bin/babeltrace; fi |
| 21 | - popd |
| 22 | - apt install -y curl python3 |
| 23 | - git clone https://github.com/lttng/lttng-ci ci |
| 24 | - export TMPDIR="/tmp" |
| 25 | - mkdir -p /tmp/coredump |
| 26 | - echo "/tmp/coredump/core.%e.%p.%h.%t" > /proc/sys/kernel/core_pattern |
| 27 | - ulimit -c unlimited |
| 28 | - mkdir /tmp/ram_disk |
| 29 | - mount -t tmpfs -o size=10024m new_ram_disk /tmp/ram_disk |
| 30 | - curl -o /tmp/trace.tar.gz "${TRACE_LOCATION}" |
| 31 | - mkdir /tmp/ram_disk/trace |
| 32 | - tar xvf /tmp/trace.tar.gz --directory /tmp/ram_disk/trace/ |
| 33 | - python3 ./ci/scripts/babeltrace-benchmark/time.py --output=result_dummy_sink --command "babeltrace /tmp/ram_disk/trace/ -o dummy" --iteration 5 |
| 34 | - python3 ./ci/scripts/babeltrace-benchmark/time.py --output=result_text_sink --command "babeltrace /tmp/ram_disk/trace/" --iteration 5 |
| 35 | - ./ci/lava/upload_artifact.sh result_dummy_sink results/benchmarks/babeltrace/dummy/${COMMIT} |
| 36 | - ./ci/lava/upload_artifact.sh result_text_sink results/benchmarks/babeltrace/text/${COMMIT} |
| 37 | |