@@ -52,13 +52,20 @@ jobs:
52
52
- uses : actions/checkout@v4
53
53
with :
54
54
submodules : ' true'
55
- - run : ./.github/scripts/install_dependencies.sh
55
+
56
+ - name : Get number of CPU cores
57
+ uses : SimenB/github-actions-cpu-cores@v2
58
+ id : cpu-cores
59
+
60
+ - name : Install dependencies
61
+ run : ./.github/scripts/install_dependencies.sh
56
62
57
63
-
uses :
hendrikmuhs/[email protected]
58
64
59
65
- name : Test
60
66
env :
61
67
BUILD_TYPE : ${{ matrix.build_type }}
68
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
62
69
run : |
63
70
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
64
71
./.github/scripts/build.sh VERBOSE=${{ matrix.verbose }}
80
87
with :
81
88
python-version : 3.10.10
82
89
- uses : actions/checkout@v4
83
- - run : ./.github/scripts/install_dependencies.sh
90
+
91
+ - name : Install dependencies
92
+ run : ./.github/scripts/install_dependencies.sh
84
93
85
94
- name : Test
86
95
run : ./dev/${{ matrix.script }}
@@ -97,11 +106,18 @@ jobs:
97
106
- uses : actions/checkout@v4
98
107
with :
99
108
submodules : ' true'
100
- - run : ./.github/scripts/install_dependencies.sh
109
+
110
+ - name : Get number of CPU cores
111
+ uses : SimenB/github-actions-cpu-cores@v2
112
+ id : cpu-cores
113
+
114
+ - name : Install dependencies
115
+ run : ./.github/scripts/install_dependencies.sh
101
116
102
117
- name : Test
103
118
env :
104
119
CMAKE_PARAMS : " -DVTR_ASSERT_LEVEL=3 -DWITH_BLIFEXPLORER=on"
120
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
105
121
run : ./.github/scripts/unittest.sh
106
122
107
123
@@ -116,7 +132,13 @@ jobs:
116
132
- uses : actions/checkout@v4
117
133
with :
118
134
submodules : ' true'
119
- - run : ./.github/scripts/install_dependencies.sh
135
+
136
+ - name : Get number of CPU cores
137
+ uses : SimenB/github-actions-cpu-cores@v2
138
+ id : cpu-cores
139
+
140
+ - name : Install dependencies
141
+ run : ./.github/scripts/install_dependencies.sh
120
142
121
143
-
uses :
hendrikmuhs/[email protected]
122
144
@@ -125,6 +147,7 @@ jobs:
125
147
# In order to get compilation warnings produced per source file, we must do a non-IPO build
126
148
# We also turn warnings into errors for this target by doing a strict compile
127
149
CMAKE_PARAMS : " -DVTR_ASSERT_LEVEL=3 -DWITH_BLIFEXPLORER=on -DVTR_ENABLE_STRICT_COMPILE=on -DVTR_IPO_BUILD=off"
150
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
128
151
run : |
129
152
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
130
153
./.github/scripts/build.sh
@@ -214,6 +237,10 @@ jobs:
214
237
with :
215
238
submodules : ' true'
216
239
240
+ - name : Get number of CPU cores
241
+ uses : SimenB/github-actions-cpu-cores@v2
242
+ id : cpu-cores
243
+
217
244
- name : Install dependencies
218
245
run : ./.github/scripts/install_dependencies.sh
219
246
@@ -226,10 +253,11 @@ jobs:
226
253
- name : Test
227
254
env :
228
255
CMAKE_PARAMS : ${{ matrix.params }}
256
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
229
257
run : |
230
258
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
231
259
./.github/scripts/build.sh
232
- ./run_reg_test.py ${{ matrix.suite }} -show_failures -j2
260
+ ./run_reg_test.py ${{ matrix.suite }} -show_failures -j${{ steps.cpu-cores.outputs.count}}
233
261
234
262
- name : Upload regression run files
235
263
if : ${{ !cancelled() }}
@@ -277,7 +305,12 @@ jobs:
277
305
with :
278
306
submodules : ' true'
279
307
280
- - run : ./.github/scripts/install_dependencies.sh
308
+ - name : Get number of CPU cores
309
+ uses : SimenB/github-actions-cpu-cores@v2
310
+ id : cpu-cores
311
+
312
+ - name : Install dependencies
313
+ run : ./.github/scripts/install_dependencies.sh
281
314
282
315
-
uses :
hendrikmuhs/[email protected]
283
316
@@ -291,12 +324,13 @@ jobs:
291
324
# depends on LLVM and all CI tests where VTR_ENABLE_SANITIZE is enabled fail. For a temporary
292
325
# fix, we manually reduce the entropy. This quick fix should be removed in the future
293
326
# when github deploys a more stable Ubuntu image.
327
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
294
328
run : |
295
329
sudo sysctl -w vm.mmap_rnd_bits=28
296
330
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
297
331
./.github/scripts/build.sh
298
332
# We skip QoR since we are only checking for errors in sanitizer runs
299
- ./run_reg_test.py ${{ matrix.suite }} -show_failures -j2 -skip_qor
333
+ ./run_reg_test.py ${{ matrix.suite }} -show_failures -j${{ steps.cpu-cores.outputs.count }} -skip_qor
300
334
301
335
302
336
Parmys :
@@ -310,18 +344,25 @@ jobs:
310
344
- uses : actions/checkout@v4
311
345
with :
312
346
submodules : ' true'
313
- - run : ./.github/scripts/install_dependencies.sh
347
+
348
+ - name : Get number of CPU cores
349
+ uses : SimenB/github-actions-cpu-cores@v2
350
+ id : cpu-cores
351
+
352
+ - name : Install dependencies
353
+ run : ./.github/scripts/install_dependencies.sh
314
354
315
355
-
uses :
hendrikmuhs/[email protected]
316
356
317
357
- name : Test
318
358
env :
319
359
CMAKE_PARAMS : ' -DVTR_IPO_BUILD=off'
320
360
BUILD_TYPE : debug
361
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
321
362
run : |
322
363
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
323
364
./.github/scripts/build.sh
324
- ./run_reg_test.py parmys_reg_basic -show_failures -j2
365
+ ./run_reg_test.py parmys_reg_basic -show_failures -j${{ steps.cpu-cores.outputs.count }}
325
366
326
367
327
368
ODINII :
@@ -335,19 +376,26 @@ jobs:
335
376
- uses : actions/checkout@v4
336
377
with :
337
378
submodules : ' true'
338
- - run : ./.github/scripts/install_dependencies.sh
379
+
380
+ - name : Get number of CPU cores
381
+ uses : SimenB/github-actions-cpu-cores@v2
382
+ id : cpu-cores
383
+
384
+ - name : Install dependencies
385
+ run : ./.github/scripts/install_dependencies.sh
339
386
340
387
-
uses :
hendrikmuhs/[email protected]
341
388
342
389
- name : Test
343
390
env :
344
391
CMAKE_PARAMS : ' -DVTR_ASSERT_LEVEL=3 -DVTR_ENABLE_SANITIZE=on -DVTR_IPO_BUILD=off -DWITH_BLIFEXPLORER=on -DWITH_PARMYS=OFF -DWITH_ODIN=on'
345
392
BUILD_TYPE : debug
393
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
346
394
run : |
347
395
sudo sysctl -w vm.mmap_rnd_bits=28
348
396
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
349
397
./.github/scripts/build.sh
350
- ./run_reg_test.py odin_reg_basic -show_failures -j2
398
+ ./run_reg_test.py odin_reg_basic -show_failures -j${{ steps.cpu-cores.outputs.count }}
351
399
352
400
353
401
VQM2BLIF :
@@ -361,13 +409,20 @@ jobs:
361
409
- uses : actions/checkout@v4
362
410
with :
363
411
submodules : ' true'
364
- - run : ./.github/scripts/install_dependencies.sh
412
+
413
+ - name : Get number of CPU cores
414
+ uses : SimenB/github-actions-cpu-cores@v2
415
+ id : cpu-cores
416
+
417
+ - name : Install dependencies
418
+ run : ./.github/scripts/install_dependencies.sh
365
419
366
420
-
uses :
hendrikmuhs/[email protected]
367
421
368
422
- name : Test
369
423
env :
370
424
BUILD_TYPE : release
425
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
371
426
run : |
372
427
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
373
428
./.github/scripts/build.sh
@@ -396,7 +451,13 @@ jobs:
396
451
- uses : actions/checkout@v4
397
452
with :
398
453
submodules : ' true'
399
- - run : ./.github/scripts/install_dependencies.sh
454
+
455
+ - name : Get number of CPU cores
456
+ uses : SimenB/github-actions-cpu-cores@v2
457
+ id : cpu-cores
458
+
459
+ - name : Install dependencies
460
+ run : ./.github/scripts/install_dependencies.sh
400
461
401
462
-
uses :
hendrikmuhs/[email protected]
402
463
@@ -405,6 +466,7 @@ jobs:
405
466
CMAKE_PARAMS : " -DVTR_ASSERT_LEVEL=3 -DWITH_BLIFEXPLORER=on -DWITH_ODIN=on"
406
467
MATRIX_EVAL : ${{ matrix.eval }}
407
468
BUILD_TYPE : release
469
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
408
470
run : |
409
471
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
410
472
./.github/scripts/build.sh
@@ -431,13 +493,20 @@ jobs:
431
493
- uses : actions/checkout@v4
432
494
with :
433
495
submodules : ' true'
434
- - run : ./.github/scripts/install_dependencies.sh
496
+
497
+ - name : Get number of CPU cores
498
+ uses : SimenB/github-actions-cpu-cores@v2
499
+ id : cpu-cores
500
+
501
+ - name : Install dependencies
502
+ run : ./.github/scripts/install_dependencies.sh
435
503
436
504
-
uses :
hendrikmuhs/[email protected]
437
505
438
506
- name : Test
439
507
env :
440
508
CMAKE_PARAMS : ' -DVTR_ASSERT_LEVEL=3 -DWITH_BLIFEXPLORER=on'
509
+ NUM_PROC : ${{ steps.cpu-cores.outputs.count }}
441
510
_COVERITY_URL : ' https://scan.coverity.com/download/linux64'
442
511
_COVERITY_MD5 : ' d0d7d7df9d6609e578f85096a755fb8f'
443
512
run : |
0 commit comments