commit d5cc2cc2fafc2e7cd2d2d755f310ad59aae60bf8 from: Sergey Bronnikov date: Tue Jul 16 12:43:31 2024 UTC ci: enable BENCH_CMD The patch enable environment variable `BENCH_CMD` introduced in a previous commit. The `taskset` alone will pin all the process threads into a single (random) isolated CPU, there's a ticket [1] about this in the Linux kernel bugtracker. The workaround is using realtime scheduler for the isolated task using `chrt` [2], e. g.: `taskset 0xef chrt 50`. 1. https://bugzilla.kernel.org/show_bug.cgi?id=116701 2. https://www.man7.org/linux/man-pages/man1/chrt.1.html NO_CHANGELOG=performance testing NO_DOC=performance testing NO_TEST=performance testing commit - 861046e20e8499b58e3e7a6e4ba21921226827da commit + d5cc2cc2fafc2e7cd2d2d755f310ad59aae60bf8 blob - ed0f168571b38cf16505046be7a5966854a4ec39 blob + db02b82180d9bd22898a3762b8b3f5e5299feeb8 --- .github/actions/install-deps-debian/action.yml +++ .github/actions/install-deps-debian/action.yml @@ -19,7 +19,8 @@ runs: libbenchmark-dev \ autoconf \ automake \ - libtool + libtool \ + util-linux luarocks install luacheck 0.26.1 gem install coveralls-lcov blob - 26bd3929ad5e5e0ecec605d15c21b81a0543d95c blob + 9eea3245ae09f143c8f3013575ef2a5de6bcb3e2 --- .github/workflows/perf_micro.yml +++ .github/workflows/perf_micro.yml @@ -78,6 +78,16 @@ jobs: run: sh ./perf/tools/setup_env.sh - name: test run: make -f .test.mk test-perf + env: + # The taskset alone will pin all the process threads + # into a single (random) isolated CPU, see + # https://bugzilla.kernel.org/show_bug.cgi?id=116701. + # The workaround is using realtime scheduler for the + # isolated task using chrt, e. g.: + # sudo taskset 0xef chrt 50. + # But this makes the process use non-standard, real-time + # round-robin scheduling mechanism. + BENCH_CMD: "taskset 0xfe chrt 50" - name: Aggregate benchmark results run: make -f .test.mk test-perf-aggregate - name: Send statistics to InfluxDB blob - 601666fe9f765839fe0fc2b62f6acd957ab9119c blob + 8ce0875cb8aa036c557980f1b42bf2066f065eda --- .test.mk +++ .test.mk @@ -74,6 +74,7 @@ test-release: CMAKE_PARAMS = -DCMAKE_BUILD_TYPE=RelWit test-release: build run-luajit-test run-test .PHONY: test-perf +test-perf: CMAKE_ENV = BENCH_CMD="${BENCH_CMD}" test-perf: CMAKE_PARAMS = -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DENABLE_WERROR=ON \ -DTEST_BUILD=ON