Created
June 29, 2026 16:18
-
-
Save NotYusta/95de96b2ceb653f24ff214cd2031a62e to your computer and use it in GitHub Desktop.
benchmark_geekbench_loop
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -uo pipefail | |
| RUNS=8 | |
| OUTPUT_DIR="results" | |
| mkdir -p "$OUTPUT_DIR" | |
| for i in $(seq 1 $RUNS); do | |
| timestamp=$(date +"%Y%m%d_%H%M%S") | |
| logfile="$OUTPUT_DIR/run_${i}_${timestamp}.log" | |
| echo "==================================================" | tee -a "$logfile" | |
| echo "Run $i/$RUNS - $(date)" | tee -a "$logfile" | |
| echo "==================================================" | tee -a "$logfile" | |
| ./geekbench6 2>&1 | tee -a "$logfile" | |
| exitcode=${PIPESTATUS[0]} | |
| echo "" >> "$logfile" | |
| echo "Exit code: $exitcode" >> "$logfile" | |
| echo "Finished: $(date)" >> "$logfile" | |
| if [ "$exitcode" -ne 0 ]; then | |
| echo "Run $i exited with code $exitcode" | |
| fi | |
| sleep 5 | |
| done | |
| echo "Done." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment