Skip to content

Commit

Permalink
Setup valgrind and parallel builds
Browse files Browse the repository at this point in the history
  • Loading branch information
EmilDohne committed Jan 26, 2025
1 parent d8d886a commit 110896f
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cmake-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,5 +85,5 @@ jobs:
CXX: ${{ matrix.compilercxx }}
CFLAGS: ${{ matrix.cflags }}
CXXFLAGS: ${{ matrix.cxxflags }}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $(nproc || echo $NUMBER_OF_PROCESSORS)

6 changes: 3 additions & 3 deletions .github/workflows/cmake-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ jobs:
os: windows-latest
compiler: msvc
compilercxx: msvc
cflags: "/fsanitize=address"
cxxflags: "/fsanitize=address"
cflags: ""
cxxflags: ""
- name: MacOS ARM GCC
os: macos-latest
compiler: gcc-13
Expand Down Expand Up @@ -83,7 +83,7 @@ jobs:
CXX: ${{ matrix.compilercxx }}
CFLAGS: ${{ matrix.cflags }}
CXXFLAGS: ${{ matrix.cxxflags }}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $(nproc || echo $NUMBER_OF_PROCESSORS)

# On windows we need to copy the test files differently as it generates sub-folders
# for the copied test files
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/cmake-valgrind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
push:
branches:
- dev
- 57-add-support-for-adjustment-layers
pull_request:
branches:
- master
Expand Down Expand Up @@ -53,7 +54,7 @@ jobs:
env:
CC: ${{ matrix.compiler }}
CXX: ${{ matrix.compilercxx }}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $(nproc || echo $NUMBER_OF_PROCESSORS)

- name: Run Valgrind
if: matrix.os == 'ubuntu-24.04'
Expand Down
14 changes: 14 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,20 @@
"CMAKE_BUILD_TYPE": "Debug"
}
},
{
"name": "x64-debug-asan",
"displayName": "x64 Debug with ASan",
"inherits": "windows-base",
"architecture": {
"value": "x64",
"strategy": "external"
},
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_C_FLAGS": "/fsanitize=address",
"CMAKE_CXX_FLAGS": "/fsanitize=address",
}
},
{
"name": "x64-release",
"displayName": "x64 Release",
Expand Down

0 comments on commit 110896f

Please sign in to comment.