Skip to content

Commit 29b337e

Browse files
authored
perf: update to gcc 14 and llvm 18 (#468)
Signed-off-by: l.feng <43399351+msclock@users.noreply.github.com>
1 parent afae29e commit 29b337e

File tree

6 files changed

+88
-102
lines changed

6 files changed

+88
-102
lines changed

.github/workflows/cd.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ jobs:
3939
~/vcpkg
4040
~/.cache/pip
4141
~/.cache/vcpkg
42-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
43-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
42+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
43+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
4444

4545
- uses: aminya/setup-cpp@v1
4646
with:
47-
compiler: gcc-13
47+
compiler: gcc-14
4848
cmake: true
4949
ninja: true
5050
ccache: true

.github/workflows/ci.yml

Lines changed: 38 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ jobs:
7777
strategy:
7878
matrix:
7979
triplet: [x64-linux]
80-
compiler: [gcc-13, llvm-17]
80+
compiler: [gcc-14, llvm-18]
8181
std: [20]
8282
build_type: [Debug, RelWithDebInfo]
8383

@@ -154,7 +154,7 @@ jobs:
154154
strategy:
155155
matrix:
156156
triplet: [arm64-osx]
157-
compiler: [gcc@13, llvm@17]
157+
compiler: [gcc@14, llvm@18]
158158
std: [20]
159159
build_type: [Debug, RelWithDebInfo]
160160

@@ -176,7 +176,7 @@ jobs:
176176

177177
- name: Install compilers and tools
178178
run: |
179-
brew install ${{ matrix.compiler }} cmake ninja ccache
179+
brew install ${{ matrix.compiler }} cmake ninja ccache lcov
180180
181181
- name: Prepare PATH for compilers
182182
run: echo "PATH=/usr/local/opt/${{ matrix.compiler }}/bin:$PATH" >> $GITHUB_ENV
@@ -196,13 +196,6 @@ jobs:
196196
gcov_version=${compiler##*@}
197197
echo "GCOV=$(which gcov-$gcov_version)" >> $GITHUB_ENV
198198
199-
- name: Prepare for lcov
200-
if: contains(matrix.compiler, 'gcc')
201-
run: |
202-
curl -o /tmp/lcov.rb https://raw.githubusercontent.com/Homebrew/homebrew-core/e92d2ae54954ebf485b484d8522104700b144fee/Formula/lcov.rb
203-
HOMEBREW_NO_AUTO_UPDATE=1 brew install --formula /tmp/lcov.rb
204-
brew pin lcov
205-
206199
- name: Configure CMake
207200
run: >
208201
cmake -S . --preset=default
@@ -239,7 +232,7 @@ jobs:
239232
strategy:
240233
matrix:
241234
triplet: [x64-windows]
242-
compiler: [msvc-2022, llvm-17]
235+
compiler: [msvc-2022, llvm-18]
243236
std: [20]
244237
build_type: [Debug, RelWithDebInfo]
245238

@@ -389,12 +382,12 @@ jobs:
389382
path: |
390383
~/vcpkg
391384
~/.cache/vcpkg
392-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
393-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
385+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
386+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
394387

395388
- uses: aminya/setup-cpp@v1
396389
with:
397-
compiler: gcc-13
390+
compiler: gcc-14
398391
cmake: true
399392
ninja: true
400393
ccache: true
@@ -436,12 +429,12 @@ jobs:
436429
path: |
437430
~/vcpkg
438431
~/.cache/vcpkg
439-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
440-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
432+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
433+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
441434

442435
- uses: aminya/setup-cpp@v1
443436
with:
444-
compiler: gcc-13
437+
compiler: gcc-14
445438
cmake: true
446439
ninja: true
447440
ccache: true
@@ -497,12 +490,12 @@ jobs:
497490
path: |
498491
~/vcpkg
499492
~/.cache/vcpkg
500-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
501-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
493+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
494+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
502495

503496
- uses: aminya/setup-cpp@v1
504497
with:
505-
compiler: gcc-13
498+
compiler: gcc-14
506499
cmake: true
507500
ninja: true
508501
ccache: true
@@ -545,12 +538,12 @@ jobs:
545538
path: |
546539
~/vcpkg
547540
~/.cache/vcpkg
548-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
549-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
541+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
542+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
550543

551544
- uses: aminya/setup-cpp@v1
552545
with:
553-
compiler: gcc-13
546+
compiler: gcc-14
554547
cmake: true
555548
ninja: true
556549
ccache: true
@@ -594,12 +587,12 @@ jobs:
594587
~/vcpkg
595588
~/.cache/pip
596589
~/.cache/vcpkg
597-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
598-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
590+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
591+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
599592

600593
- uses: aminya/setup-cpp@v1
601594
with:
602-
compiler: gcc-13
595+
compiler: gcc-14
603596
cmake: true
604597
ninja: true
605598
ccache: true
@@ -641,20 +634,20 @@ jobs:
641634
path: |
642635
~/vcpkg
643636
~/.cache/vcpkg
644-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
645-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
637+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
638+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
646639

647640
- uses: aminya/setup-cpp@v1
648641
with:
649-
compiler: gcc-13
642+
compiler: gcc-14
650643
cmake: true
651644
ninja: true
652645
ccache: true
653646

654647
- name: Prepare for lcov
655648
run: |
656649
sudo apt-get update; sudo apt-get install lcov -y
657-
gcc_compiler=gcc-13
650+
gcc_compiler=gcc-14
658651
gcov_version=${gcc_compiler##*-}
659652
sudo update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-$gcov_version 100
660653
@@ -699,12 +692,12 @@ jobs:
699692
path: |
700693
~/vcpkg
701694
~/.cache/vcpkg
702-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
703-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
695+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
696+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
704697

705698
- uses: aminya/setup-cpp@v1
706699
with:
707-
compiler: gcc-13
700+
compiler: gcc-14
708701
cmake: true
709702
ninja: true
710703
ccache: true
@@ -747,12 +740,12 @@ jobs:
747740
path: |
748741
~/vcpkg
749742
~/.cache/vcpkg
750-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
751-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
743+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
744+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
752745

753746
- uses: aminya/setup-cpp@v1
754747
with:
755-
compiler: gcc-13
748+
compiler: gcc-14
756749
cmake: true
757750
ninja: true
758751
ccache: true
@@ -797,12 +790,12 @@ jobs:
797790
path: |
798791
~/vcpkg
799792
~/.cache/vcpkg
800-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
801-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
793+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
794+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
802795

803796
- uses: aminya/setup-cpp@v1
804797
with:
805-
compiler: gcc-13
798+
compiler: gcc-14
806799
cmake: true
807800
ninja: true
808801
ccache: true
@@ -843,12 +836,12 @@ jobs:
843836
path: |
844837
~/vcpkg
845838
~/.cache/vcpkg
846-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
847-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
839+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
840+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
848841

849842
- uses: aminya/setup-cpp@v1
850843
with:
851-
compiler: gcc-13
844+
compiler: gcc-14
852845
cmake: true
853846
ninja: true
854847
ccache: true
@@ -895,12 +888,12 @@ jobs:
895888
~/vcpkg
896889
~/.cache/pip
897890
~/.cache/vcpkg
898-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
899-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
891+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
892+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
900893

901894
- uses: aminya/setup-cpp@v1
902895
with:
903-
compiler: gcc-13
896+
compiler: gcc-14
904897
cmake: true
905898
ninja: true
906899
ccache: true

.github/workflows/codeql.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,12 @@ jobs:
6161
path: |
6262
~/vcpkg
6363
~/.cache/vcpkg
64-
key: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
65-
restore-keys: x64-linux-gcc-13-${{ hashFiles('vcpkg.json') }}
64+
key: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
65+
restore-keys: x64-linux-gcc-14-${{ hashFiles('vcpkg.json') }}
6666

6767
- uses: aminya/setup-cpp@v1
6868
with:
69-
compiler: gcc-13
69+
compiler: gcc-14
7070
cmake: true
7171
ninja: true
7272
ccache: true

template/[% if repo_platform == 'github' %].github[% endif %]/workflows/[% if use_codeql == true %]codeql.yml[% endif %].jinja

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,12 @@ jobs:
6161
path: |
6262
~/vcpkg
6363
~/.cache/vcpkg
64-
key: x64-linux-gcc-13-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
65-
restore-keys: x64-linux-gcc-13-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
64+
key: x64-linux-gcc-14-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
65+
restore-keys: x64-linux-gcc-14-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
6666

6767
- uses: aminya/setup-cpp@v1
6868
with:
69-
compiler: gcc-13
69+
compiler: gcc-14
7070
cmake: true
7171
ninja: true
7272
ccache: true

template/[% if repo_platform == 'github' %].github[% endif %]/workflows/cd.yml.jinja

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ jobs:
3939
~/vcpkg
4040
~/.cache/pip
4141
~/.cache/vcpkg
42-
key: x64-linux-gcc-13-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
43-
restore-keys: x64-linux-gcc-13-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
42+
key: x64-linux-gcc-14-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
43+
restore-keys: x64-linux-gcc-14-{{ '${{ hashFiles(\'vcpkg.json\') }}' }}
4444

4545
- uses: aminya/setup-cpp@v1
4646
with:
47-
compiler: gcc-13
47+
compiler: gcc-14
4848
cmake: true
4949
ninja: true
5050
ccache: true

0 commit comments

Comments
 (0)