diff --git a/.github/workflows/benchmark_asterinas.yml b/.github/workflows/benchmark_asterinas.yml index 69ab50fe..3be77fa6 100644 --- a/.github/workflows/benchmark_asterinas.yml +++ b/.github/workflows/benchmark_asterinas.yml @@ -38,6 +38,7 @@ jobs: # Signal-related benchmarks - lmbench-signal - lmbench-signal-install + - lmbench-signal-prot # File-related benchmarks - lmbench-file-rd-bandwidth - lmbench-select-file diff --git a/test/benchmark/lmbench-signal-prot/config.json b/test/benchmark/lmbench-signal-prot/config.json new file mode 100644 index 00000000..0b65b293 --- /dev/null +++ b/test/benchmark/lmbench-signal-prot/config.json @@ -0,0 +1,7 @@ +{ + "alert_threshold": "125%", + "alert_tool": "customSmallerIsBetter", + "search_pattern": "Protection fault:", + "result_index": "3", + "description": "The latency to catch a protection fault on a single processor." +} diff --git a/test/benchmark/lmbench-signal-prot/result_template.json b/test/benchmark/lmbench-signal-prot/result_template.json new file mode 100644 index 00000000..dbb1a152 --- /dev/null +++ b/test/benchmark/lmbench-signal-prot/result_template.json @@ -0,0 +1,14 @@ +[ + { + "name": "Average protection fault latency on Linux", + "unit": "µs", + "value": 0, + "extra": "linux_avg" + }, + { + "name": "Average protection fault latency on Asterinas", + "unit": "µs", + "value": 0, + "extra": "aster_avg" + } +] \ No newline at end of file diff --git a/test/benchmark/lmbench-signal-prot/run.sh b/test/benchmark/lmbench-signal-prot/run.sh new file mode 100644 index 00000000..319b52d0 --- /dev/null +++ b/test/benchmark/lmbench-signal-prot/run.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +# SPDX-License-Identifier: MPL-2.0 + +set -e + +echo "*** Running the LMbench protection fault latency test ***" + +dd if=/dev/zero of=/ext2/test_file bs=1M count=256 +/benchmark/bin/lmbench/lat_sig prot /ext2/test_file \ No newline at end of file