diff --git a/.github/workflows/benchmark_asterinas.yml b/.github/workflows/benchmark_asterinas.yml index 5101beb6e..4dab27dc9 100644 --- a/.github/workflows/benchmark_asterinas.yml +++ b/.github/workflows/benchmark_asterinas.yml @@ -60,6 +60,7 @@ jobs: - lmbench-tcp-bandwidth-localhost - lmbench-tcp-connect-latency - lmbench-tcp-latency-localhost + - lmbench-udp-latency-localhost fail-fast: false timeout-minutes: 60 container: diff --git a/test/benchmark/lmbench-udp-latency-localhost/config.json b/test/benchmark/lmbench-udp-latency-localhost/config.json new file mode 100644 index 000000000..a9bdd7d8b --- /dev/null +++ b/test/benchmark/lmbench-udp-latency-localhost/config.json @@ -0,0 +1,7 @@ +{ + "alert_threshold": "125%", + "alert_tool": "customSmallerIsBetter", + "search_pattern": "UDP latency using 127.0.0.1:", + "result_index": "5", + "description": "The latency of UDP on localhost." +} diff --git a/test/benchmark/lmbench-udp-latency-localhost/result_template.json b/test/benchmark/lmbench-udp-latency-localhost/result_template.json new file mode 100644 index 000000000..b45911523 --- /dev/null +++ b/test/benchmark/lmbench-udp-latency-localhost/result_template.json @@ -0,0 +1,14 @@ +[ + { + "name": "Average UDP latency on Linux", + "unit": "µs", + "value": 0, + "extra": "linux_avg" + }, + { + "name": "Average UDP latency on Asterinas", + "unit": "µs", + "value": 0, + "extra": "aster_avg" + } +] \ No newline at end of file diff --git a/test/benchmark/lmbench-udp-latency-localhost/run.sh b/test/benchmark/lmbench-udp-latency-localhost/run.sh new file mode 100644 index 000000000..77bcd13d6 --- /dev/null +++ b/test/benchmark/lmbench-udp-latency-localhost/run.sh @@ -0,0 +1,11 @@ +#!/bin/sh + +# SPDX-License-Identifier: MPL-2.0 + +set -e + +echo "*** Running lmbench UDP latency test ***" + +/benchmark/bin/lmbench/lat_udp -s +/benchmark/bin/lmbench/lat_udp -P 1 127.0.0.1 +/benchmark/bin/lmbench/lat_udp -S 127.0.0.1