Skip to content

Commit

Permalink
Use sudo
Browse files Browse the repository at this point in the history
  • Loading branch information
larseggert committed Feb 9, 2024
1 parent 93d3929 commit 5c0afc9
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,23 +48,23 @@ jobs:
- name: Prepare machine
run: |
# Disable turboboost
echo 1 > /sys/devices/system/cpu/intel_pstate/no_turbo
echo 1 > sudo tee /sys/devices/system/cpu/intel_pstate/no_turbo
# Disable hyperthreading
echo off > /sys/devices/system/cpu/smt/control
echo off > sudo tee /sys/devices/system/cpu/smt/control
# Use performance governor
cpupower frequency-set -g performance
sudo cpupower frequency-set -g performance
- name: Benchmark
run: nice -n -10 taskset -c 0 cargo +$TOOLCHAIN bench --features ci,bench | tee output.txt
run: sudo nice -n -10 taskset -c 0 cargo +$TOOLCHAIN bench --features ci,bench | tee output.txt

- name: Restore machine
run: |
# Enable turboboost
echo 0 > /sys/devices/system/cpu/intel_pstate/no_turbo
echo 0 > sudo tee /sys/devices/system/cpu/intel_pstate/no_turbo
# Enable hyperthreading
echo on > /sys/devices/system/cpu/smt/control
echo on > sudo tee /sys/devices/system/cpu/smt/control
# Use powersave governor
cpupower frequency-set -g powersave
sudo cpupower frequency-set -g powersave
- name: Download previous benchmark results
uses: actions/cache@v4
Expand Down

0 comments on commit 5c0afc9

Please sign in to comment.