@@ -4,8 +4,16 @@ name: benchmark_documentation
44on :
55 workflow_dispatch :
66 inputs :
7- run-benchmarks :
8- description : " Run benchmarks"
7+ run-cpu-benchmarks :
8+ description : " Run CPU benchmarks"
9+ type : boolean
10+ default : true
11+ run-gpu-benchmarks :
12+ description : " Run GPU benchmarks"
13+ type : boolean
14+ default : true
15+ run-hpu-benchmarks :
16+ description : " Run HPU benchmarks"
917 type : boolean
1018 default : true
1119 generate-svgs :
2533 run-benchmarks-cpu-integer :
2634 name : benchmark_documentation/run-benchmarks-cpu-integer
2735 uses : ./.github/workflows/benchmark_cpu_common.yml
36+ if : inputs.run-cpu-benchmarks
2837 with :
2938 command : integer
3039 op_flavor : fast_default
4352 run-benchmarks-gpu-integer :
4453 name : benchmark_documentation/run-benchmarks-gpu-integer
4554 uses : ./.github/workflows/benchmark_gpu_common.yml
55+ if : inputs.run-gpu-benchmarks
4656 with :
4757 profile : l40
4858 hardware_name : n3-L40x1
6373 run-benchmarks-hpu-integer :
6474 name : benchmark_documentation/run-benchmarks-hpu-integer
6575 uses : ./.github/workflows/benchmark_hpu_common.yml
76+ if : inputs.run-hpu-benchmarks
6677 with :
6778 command : integer
6879 op_flavor : default
8495 run-benchmarks-cpu-core-crypto :
8596 name : benchmark_documentation/run-benchmarks-cpu-core-crypto
8697 uses : ./.github/workflows/benchmark_cpu_common.yml
98+ if : inputs.run-cpu-benchmarks
8799 with :
88100 command : pbs, ks_pbs
89101 bench_type : latency
@@ -101,6 +113,7 @@ jobs:
101113 run-benchmarks-gpu-core-crypto :
102114 name : benchmark_documentation/run-benchmarks-gpu-core-crypto
103115 uses : ./.github/workflows/benchmark_gpu_common.yml
116+ if : inputs.run-gpu-benchmarks
104117 with :
105118 profile : l40
106119 hardware_name : n3-L40x1
@@ -119,22 +132,28 @@ jobs:
119132
120133 generate-svgs-with-benchmarks-run :
121134 name : benchmark-documentation/generate-svgs-with-benchmarks-run
122- if : inputs.run-benchmarks && inputs.generate-svgs
135+ if : ${{ always() &&
136+ (inputs.run-cpu-benchmarks || inputs.run-gpu-benchmarks ||inputs.run-hpu-benchmarks) &&
137+ inputs.generate-svgs }}
123138 needs : [
124139 run-benchmarks-cpu-integer, run-benchmarks-gpu-integer, run-benchmarks-hpu-integer,
125140 run-benchmarks-cpu-core-crypto, run-benchmarks-gpu-core-crypto
126141 ]
127142 uses : ./.github/workflows/generate_svgs.yml
128143 with :
129- time_span_days : 1 # This ensures extraction is performed on the last values stored in database/
144+ time_span_days : 5
145+ generate-cpu-svgs : ${{ inputs.run-cpu-benchmarks }}
146+ generate-gpu-svgs : ${{ inputs.run-gpu-benchmarks }}
147+ generate-hpu-svgs : ${{ inputs.run-hpu-benchmarks }}
130148 secrets :
131149 DATA_EXTRACTOR_DATABASE_USER : ${{ secrets.DATA_EXTRACTOR_DATABASE_USER }}
132150 DATA_EXTRACTOR_DATABASE_HOST : ${{ secrets.DATA_EXTRACTOR_DATABASE_HOST }}
133151 DATA_EXTRACTOR_DATABASE_PASSWORD : ${{ secrets.DATA_EXTRACTOR_DATABASE_PASSWORD }}
134152
135153 generate-svgs-without-benchmarks-run :
136154 name : benchmark-documentation/generate-svgs-without-benchmarks-run
137- if : ${{ !inputs.run-benchmarks && inputs.generate-svgs }}
155+ if : ${{ !(inputs.run-cpu-benchmarks || inputs.run-gpu-benchmarks || inputs.run-hpu-benchmarks) &&
156+ inputs.generate-svgs }}
138157 uses : ./.github/workflows/generate_svgs.yml
139158 with :
140159 time_span_days : 60
0 commit comments