Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions common/generate_combined_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -284,10 +284,10 @@ def generate_combined_report(results_dir):
if os.path.exists(cpu_stress_marker_file):
with open(cpu_stress_marker_file, 'r') as f:
marker_content = f.read()
if 'CPU_STRESS=RUNNING' in marker_content or 'PID=' in marker_content:
cpu_stress_status = 'success' # Assume success if marker exists
elif 'STATUS=FAILED' in marker_content:
if 'STATUS=FAILED' in marker_content:
cpu_stress_status = 'failed'
elif 'CPU_STRESS=RUNNING' in marker_content or 'PID=' in marker_content:
cpu_stress_status = 'success'

# Read CPU stress log content
cpu_stress_log_file = os.path.join(results_dir, 'cpu_stress.log')
Expand All @@ -304,10 +304,10 @@ def generate_combined_report(results_dir):
if os.path.exists(gpu_stress_marker_file):
with open(gpu_stress_marker_file, 'r') as f:
marker_content = f.read()
if 'GPU_STRESS=RUNNING' in marker_content or 'PID=' in marker_content:
gpu_stress_status = 'success' # Assume success if marker exists
elif 'STATUS=FAILED' in marker_content:
if 'STATUS=FAILED' in marker_content:
gpu_stress_status = 'failed'
elif 'GPU_STRESS=RUNNING' in marker_content or 'PID=' in marker_content:
gpu_stress_status = 'success'

# Read GPU stress log content
gpu_stress_log_file = os.path.join(results_dir, 'gpu_stress.log')
Expand Down
8 changes: 8 additions & 0 deletions cpu/cpu_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,14 @@ echo "CPU stress test started (PID: $STRESS_PID)"
# Update marker file with PID for the main script to kill later
echo "PID=${STRESS_PID}" >> "${RESULTS_DIR}/cpu_stress_marker.txt"

# stress-ng can exit straight away (unsupported option, cgroup limit, no memory).
# Record that so the report doesn't count a test that never ran as a pass.
sleep 1
if ! kill -0 "${STRESS_PID}" 2>/dev/null; then
echo "STATUS=FAILED" >> "${RESULTS_DIR}/cpu_stress_marker.txt"
echo "CPU stress test exited immediately, see cpu_stress.log"
fi

# Keep running until killed by main script
wait $STRESS_PID 2>/dev/null

Expand Down
14 changes: 14 additions & 0 deletions gpu/gpu_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,20 @@ echo "PIDs: $PID_LIST"
# Update marker file with PIDs for the main script to kill later
echo "PID=${PID_LIST}" >> "${RESULTS_DIR}/gpu_stress_marker.txt"

# glmark2 exits straight away without a working GL context. Record that so the
# report doesn't count a test that never ran as a pass.
sleep 1
GPU_STRESS_ALIVE=false
for PID in $PID_LIST; do
if kill -0 "$PID" 2>/dev/null; then
GPU_STRESS_ALIVE=true
fi
done
if [ "$GPU_STRESS_ALIVE" = false ]; then
echo "STATUS=FAILED" >> "${RESULTS_DIR}/gpu_stress_marker.txt"
echo "GPU stress processes exited immediately, see gpu_stress.log"
fi

# Show countdown dialog using yad if available
if [ "$YAD_AVAILABLE" = true ]; then
# Calculate timeout in seconds
Expand Down