Skip to content

Commit e17fb86

Browse files
committed
Merge bitcoin/bitcoin#32888: ci: Use optimized Debug build type in test-each-commit
faa3171 ci: Use optimized Debug build type in test-each-commit (MarcoFalke) fa21c34 ci: [doc] reword debug log message (MarcoFalke) Pull request description: An optimized debug build is mostly as fast as a release build, because hot loops of heavy debug-only code are rare. So use that setting in the test-each-commit CI, to enable more checks almost "for free". ACKs for top commit: Prabhat1308: re-ACK [`faa3171`](bitcoin/bitcoin@faa3171) willcl-ark: crACK faa3171 Tree-SHA512: ca041cf7f79d7abb6f93e17b58b2aea730f3bb9fc51256c1ca1b9f7ce7e7188d18fd99d3754cdbe3f504f4e08d560e72d4b7a75409c214ee2c3771c9a8ba7f96
2 parents fd3d80c + faa3171 commit e17fb86

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

.github/ci-test-each-commit-exec.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,25 @@ def run(cmd, **kwargs):
1717

1818

1919
def main():
20-
print("Running test-one-commit on ...")
20+
print("Running tests on commit ...")
2121
run(["git", "log", "-1"])
2222

2323
num_procs = int(run(["nproc"], stdout=subprocess.PIPE).stdout)
2424

25-
# Use clang++, because it is a bit faster and uses less memory than g++
2625
run([
2726
"cmake",
2827
"-B",
2928
"build",
3029
"-Werror=dev",
30+
# Use clang++, because it is a bit faster and uses less memory than g++
3131
"-DCMAKE_C_COMPILER=clang",
3232
"-DCMAKE_CXX_COMPILER=clang++",
33+
# Use mold, because it is faster than the default linker
34+
"-DCMAKE_EXE_LINKER_FLAGS=-fuse-ld=mold",
35+
# Use Debug build type for more debug checks, but enable optimizations
36+
"-DAPPEND_CXXFLAGS='-O3 -g2'",
37+
"-DAPPEND_CFLAGS='-O3 -g2'",
38+
"-DCMAKE_BUILD_TYPE=Debug",
3339
"-DWERROR=ON",
3440
"-DWITH_ZMQ=ON",
3541
"-DBUILD_GUI=ON",

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ jobs:
7777
git config user.name "CI"
7878
- run: |
7979
sudo apt-get update
80-
sudo apt-get install clang ccache build-essential cmake ninja-build pkgconf python3-zmq libevent-dev libboost-dev libsqlite3-dev systemtap-sdt-dev libzmq3-dev qt6-base-dev qt6-tools-dev qt6-l10n-tools libqrencode-dev -y
80+
sudo apt-get install clang mold ccache build-essential cmake ninja-build pkgconf python3-zmq libevent-dev libboost-dev libsqlite3-dev systemtap-sdt-dev libzmq3-dev qt6-base-dev qt6-tools-dev qt6-l10n-tools libqrencode-dev -y
8181
- name: Compile and run tests
8282
run: |
8383
# Run tests on commits after the last merge commit and before the PR head commit

0 commit comments

Comments
 (0)