Skip to content

Commit e45ccf8

Browse files
Update benchmarks.yml
1 parent fe26440 commit e45ccf8

File tree

1 file changed

+40
-52
lines changed

1 file changed

+40
-52
lines changed

.github/workflows/benchmarks.yml

Lines changed: 40 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -50,72 +50,60 @@ jobs:
5050
- name: Check TF_CPP_MAX_VLOG_LEVEL
5151
working-directory: xla
5252
run: echo "$TF_CPP_MAX_VLOG_LEVEL"
53-
- name: Wait For Connection
54-
uses: google-ml-infra/actions/ci_connection@main
55-
with:
56-
halt-dispatch-input: ${{ inputs.halt-for-connection }}
57-
- name: Wait For Connection
58-
uses: google-ml-infra/actions/ci_connection@main
59-
with:
60-
halt-dispatch-input: ${{ inputs.halt-for-connection }}
6153

62-
# - name: Build hlo_runner_main
63-
# working-directory: xla
64-
# run: bazel build -c opt --config=cuda --dynamic_mode=off //xla/tools/multihost_hlo_runner:hlo_runner_main
54+
- name: Build hlo_runner_main
55+
working-directory: xla
56+
run: bazel build -c opt --config=cuda --dynamic_mode=off //xla/tools/multihost_hlo_runner:hlo_runner_main
6557

6658
# - name: Wait For Connection
6759
# uses: google-ml-infra/actions/ci_connection@main
6860
# with:
6961
# halt-dispatch-input: ${{ inputs.halt-for-connection }}
7062

71-
# - name: Create gpu_hlo_backend.hlo
72-
# working-directory: xla
73-
# run: |
74-
# cat << EOF > gpu_hlo_backend.hlo
75-
# HloModule module
76-
# // CHECK: is_scheduled=true
63+
- name: Create gpu_hlo_backend.hlo
64+
working-directory: xla
65+
run: |
66+
cat << EOF > gpu_hlo_backend.hlo
67+
HloModule module
68+
// CHECK: is_scheduled=true
7769
78-
# ENTRY computation {
79-
# p = f32[5000,6000]{1,0} parameter(0)
80-
# e = f32[5000,6000]{1,0} sqrt(p)
81-
# c = f32[6000,5000] transpose(p), dimensions={1,0}
82-
# r = f32[300,20,5000] reshape(c)
83-
# ROOT out = (f32[5000,6000], f32[300,20,5000]) tuple(e,r)
84-
# }
85-
# EOF
70+
ENTRY computation {
71+
p = f32[5000,6000]{1,0} parameter(0)
72+
e = f32[5000,6000]{1,0} sqrt(p)
73+
c = f32[6000,5000] transpose(p), dimensions={1,0}
74+
r = f32[300,20,5000] reshape(c)
75+
ROOT out = (f32[5000,6000], f32[300,20,5000]) tuple(e,r)
76+
}
77+
EOF
8678
87-
# - name: Wait For Connection
88-
# uses: google-ml-infra/actions/ci_connection@main
89-
# with:
90-
# halt-dispatch-input: ${{ inputs.halt-for-connection }}
79+
- name: Wait For Connection
80+
uses: google-ml-infra/actions/ci_connection@main
81+
with:
82+
halt-dispatch-input: ${{ inputs.halt-for-connection }}
9183

92-
# - name: Run an HLO file
93-
# working-directory: xla
94-
# run: |
95-
# nvidia-smi --query-gpu=utilization.gpu --format=csv -l 1 > results/gpu_utilization_gpu_backend.log & ./bazel-bin/xla/tools/multihost_hlo_runner/hlo_runner_main --device_type=gpu --log_output=True --use_spmd_partitioning gpu_hlo_backend.hlo
96-
97-
# cd results
98-
# ls
99-
# cat gpu_hlo_backend.hlo.log
84+
- name: Run an HLO file
85+
working-directory: xla
86+
run: |
87+
./bazel-bin/xla/tools/multihost_hlo_runner/hlo_runner_main --device_type=gpu --log_output=True --use_spmd_partitioning gpu_hlo_backend.hlo &> results/gpu_hlo_backend.log
10088
101-
# - name: Wait For Connection
102-
# uses: google-ml-infra/actions/ci_connection@main
103-
# with:
104-
# halt-dispatch-input: ${{ inputs.halt-for-connection }}
89+
- name: Wait For Connection
90+
uses: google-ml-infra/actions/ci_connection@main
91+
with:
92+
halt-dispatch-input: ${{ inputs.halt-for-connection }}
10593

106-
# - name: Download parse_xla_logs.py
107-
# working-directory: xla
108-
# run: wget https://raw.githubusercontent.com/juliagmt-google/xla/main/.github/workflows/parse_xla_logs.py
94+
- name: Download parse_xla_logs.py
95+
working-directory: xla
96+
run: wget https://raw.githubusercontent.com/juliagmt-google/xla/main/.github/workflows/parse_xla_logs.py
10997

110-
# - name: Parse XLA logs
111-
# working-directory: xla
112-
# run: python parse_xla_logs.py results/gpu_hlo_backend.hlo.log
98+
- name: Parse XLA logs
99+
working-directory: xla
100+
run: python parse_xla_logs.py results/gpu_hlo_backend.hlo.log
113101

114-
# - name: Upload Results
115-
# uses: actions/upload-artifact@v4
116-
# with:
117-
# name: gpu-xla-benchmarks
118-
# path: xla/results
102+
- name: Upload Results
103+
uses: actions/upload-artifact@v4
104+
with:
105+
name: gpu-xla-benchmarks
106+
path: xla/results
119107
# # jax-build-and-test:
120108
# # runs-on: linux-x86-g2-48-l4-4gpu # Use a GPU-enabled runner
121109
# # container:

0 commit comments

Comments
 (0)