Skip to content

Commit 6d0394e

Browse files
Update benchmarks.yml
1 parent e0f6662 commit 6d0394e

File tree

1 file changed

+64
-63
lines changed

1 file changed

+64
-63
lines changed

.github/workflows/benchmarks.yml

Lines changed: 64 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,12 @@ jobs:
6565
uses: actions/checkout@v3
6666
with:
6767
repository: openxla/xla
68+
ref: dev # Specify the dev branch
6869

69-
- name: Create results directory
70-
working-directory: xla
71-
run:
72-
mkdir results
70+
# - name: Create results directory
71+
# working-directory: xla
72+
# run:
73+
# mkdir results
7374

7475
# - name: Run setup.sh for E2E benchmarks flax_2b
7576
# working-directory: xla/backends/cpu/benchmarks/e2e/gemma2/flax_2b
@@ -84,53 +85,53 @@ jobs:
8485
# bash run.sh | tee -a ../../../../../../results/flax_2b.log
8586

8687
# TODO(juliagmt): Re-enable once the build is fixed.
87-
- name: Build run_hlo_module
88-
working-directory: xla
89-
run: bazel build -c opt --dynamic_mode=off //xla/tools:run_hlo_module
88+
# - name: Build run_hlo_module
89+
# working-directory: xla
90+
# run: bazel build -c opt --dynamic_mode=off //xla/tools:run_hlo_module
9091

91-
- name: Run HLO Module Benchmarks
92-
working-directory: xla
93-
continue-on-error: true
94-
run: |
95-
for file in tests/fuzz/*.hlo; do
96-
filename=$(basename "$file")
97-
# Skip expected failed hlo files.
98-
if [[ "$filename" == "rand_000060.hlo" || "$filename" == "rand_000067.hlo" || "$filename" == "rand_000072.hlo" ]]; then
99-
echo "Skipping benchmark on $file"
100-
continue
101-
fi
102-
echo "Running benchmark on $file"
103-
./bazel-bin/xla/tools/run_hlo_module --input_format=hlo --platform=CPU "$file"
104-
done
92+
# - name: Run HLO Module Benchmarks
93+
# working-directory: xla
94+
# continue-on-error: true
95+
# run: |
96+
# for file in tests/fuzz/*.hlo; do
97+
# filename=$(basename "$file")
98+
# # Skip expected failed hlo files.
99+
# if [[ "$filename" == "rand_000060.hlo" || "$filename" == "rand_000067.hlo" || "$filename" == "rand_000072.hlo" ]]; then
100+
# echo "Skipping benchmark on $file"
101+
# continue
102+
# fi
103+
# echo "Running benchmark on $file"
104+
# ./bazel-bin/xla/tools/run_hlo_module --input_format=hlo --platform=CPU "$file"
105+
# done
105106

106-
- name: Build CPU Benchmarks
107-
working-directory: xla
108-
run: bazel build -c opt --dynamic_mode=off //xla/backends/cpu/benchmarks:*
107+
# - name: Build CPU Benchmarks
108+
# working-directory: xla
109+
# run: bazel build -c opt --dynamic_mode=off //xla/backends/cpu/benchmarks:*
109110

110-
- name: Run CPU benchmarks
111-
working-directory: xla
112-
continue-on-error: true
113-
run: |
114-
find ./bazel-bin/xla/backends/cpu/benchmarks/ -maxdepth 1 -type f -executable -name "*_test" -print0 | while IFS= read -r -d $'\0' benchmark; do
115-
benchmark_name=$(basename "$benchmark" | sed 's/_test$//')
116-
echo "Running benchmark: $benchmark_name"
111+
# - name: Run CPU benchmarks
112+
# working-directory: xla
113+
# continue-on-error: true
114+
# run: |
115+
# find ./bazel-bin/xla/backends/cpu/benchmarks/ -maxdepth 1 -type f -executable -name "*_test" -print0 | while IFS= read -r -d $'\0' benchmark; do
116+
# benchmark_name=$(basename "$benchmark" | sed 's/_test$//')
117+
# echo "Running benchmark: $benchmark_name"
117118

118-
# Run the benchmark with default parameters.
119-
$benchmark --benchmark_filter=".*"
120-
$benchmark --benchmark_filter=".*" > "results/$benchmark_name.log" 2>&1
119+
# # Run the benchmark with default parameters.
120+
# $benchmark --benchmark_filter=".*"
121+
# $benchmark --benchmark_filter=".*" > "results/$benchmark_name.log" 2>&1
121122

122-
# Check the exit code of the benchmark
123-
if [ $? -ne 0 ]; then
124-
echo "Error: Benchmark '$benchmark_name' failed. Check the log file: results/$benchmark_name.log"
125-
else
126-
echo "Benchmark '$benchmark_name' completed successfully."
127-
fi
128-
done
129-
- name: Upload Results ${{ matrix.build_target }}
130-
uses: actions/upload-artifact@v4
131-
with:
132-
name: cpu-xla-benchmarks-${{ matrix.job_info.os }}
133-
path: xla/results
123+
# # Check the exit code of the benchmark
124+
# if [ $? -ne 0 ]; then
125+
# echo "Error: Benchmark '$benchmark_name' failed. Check the log file: results/$benchmark_name.log"
126+
# else
127+
# echo "Benchmark '$benchmark_name' completed successfully."
128+
# fi
129+
# done
130+
# - name: Upload Results ${{ matrix.build_target }}
131+
# uses: actions/upload-artifact@v4
132+
# with:
133+
# name: cpu-xla-benchmarks-${{ matrix.job_info.os }}
134+
# path: xla/results
134135

135136
# build-xla-gpu-and-test:
136137
# runs-on: "linux-x86-n2-16" #linux-x86-g2-48-l4-4gpu # Use a GPU-enabled runner
@@ -149,25 +150,25 @@ jobs:
149150
# # repository: juliagmt-google/xla
150151
# # path: xla
151152

152-
# - name: Print machine specs
153-
# run: |
154-
# lscpu
155-
# free -h # Memory information
156-
# df -h # Disk space information
157-
# uname -a # Kernel information
153+
- name: Print machine specs
154+
run: |
155+
lscpu
156+
free -h # Memory information
157+
df -h # Disk space information
158+
uname -a # Kernel information
158159
159-
# - name: Create results directory
160-
# working-directory: xla
161-
# run: mkdir results
160+
- name: Create results directory
161+
working-directory: xla
162+
run: mkdir results
162163

163-
# - name: Wait For Connection
164-
# uses: google-ml-infra/actions/ci_connection@main
165-
# with:
166-
# halt-dispatch-input: ${{ inputs.halt-for-connection }}
167-
# # - name: Set up Python 3.10 # Choose your desired Python version
168-
# # uses: actions/setup-python@v4
169-
# # with:
170-
# # python-version: '3.10'
164+
- name: Wait For Connection
165+
uses: google-ml-infra/actions/ci_connection@main
166+
with:
167+
halt-dispatch-input: ${{ inputs.halt-for-connection }}
168+
# - name: Set up Python 3.10 # Choose your desired Python version
169+
# uses: actions/setup-python@v4
170+
# with:
171+
# python-version: '3.10'
171172

172173
# # - name: Create and activate virtual environment
173174
# # shell: bash # Force the use of bash

0 commit comments

Comments
 (0)