tests: speed up builds with single-binary test bundles - #14772
tests: speed up builds with single-binary test bundles#14772vszakats wants to merge 143 commits into
Conversation
251a405 to
8ff4573
Compare
|
Analysis of PR #14772 at 2bdff798: Test 500 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 504 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 501 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 502 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 507 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 508 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). Test 510 failed, which has NOT been flaky recently, so there could be a real issue in the PR. Note that this test has failed in 9 different CI jobs (the link just goes to one of them). There are more failures, but that's enough from Gha. Generated by Testclutch |
a09ae03 to
3741f97
Compare
3df946f to
3a3a268
Compare
|
This is ready now for the most part. Remains is to set it up in CI without enabling these features by default. It may make building and running tests more "accessible". |
4c20cb4 to
d84875b
Compare
073d0b5 to
89fa5f4
Compare
098c2f0 to
089782c
Compare
318e04d to
2f8f53e
Compare
- `.gitignore`: delete, dedupe and move rules upwards. Ref: 6389ba8 #13311 - `.gitignore`: fix generated test sources. Follow-up to 71cf0d1 #14772 - `.gitignore`: replace exe listings with a wildcard. - lib: move `setup-*.h` from `EXTRA_DIST` to `CURL_HFILES`. - `makedebug.bat`: uppercase an argument to match docs. - GHA/non-native: delete stray env. Follow-up to 12a6de2 #16043 - sort source lists. Closes #16093
Necessary to catch rare cases when `checksrc` hits these files when they are not populated yet: ``` ./curltool_unity.c:1:1: error: Missing copyright statement (COPYRIGHT) ^ ``` https://github.com/curl/curl/actions/runs/12995546740/job/36242556713?pr=16094#step:37:123 Follow-up to 71cf0d1 #14772 Closes #16102
Before this patch curl code was redefining `getaddrinfo` and `freeaddrinfo` system symbols to plug in its debug wrappers. This was causing pains to avoid applying the redefinitions to system headers defining these functions, and to the local debug wrappers. Especially in unity builds. It also required workarounds for systems where these symbols are already macros. Introduce curl-namespaced macros for these functions and use them. This allows to drop all workarounds and makes it work in all envs, local targets and unity/bundle combinations. Ref: curl#16272 Ref: 71cf0d1 curl#14772 Ref: 3efba94 curl#14765 Ref: f7d5f47 curl#14399 Closes curl#16274
Before this patch curl code was redefining `getaddrinfo` and `freeaddrinfo` system symbols to plug in its debug wrappers. This was causing pains to avoid applying the redefinitions to system headers defining these functions, and to the local debug wrappers. Especially in unity builds. It also required workarounds for systems where these symbols are already macros. Introduce curl-namespaced macros for these functions and use them. This allows to drop all workarounds and makes it work in all envs, local targets and unity/bundle combinations. Ref: curl#16272 Ref: 71cf0d1 curl#14772 Ref: 3efba94 curl#14765 Ref: f7d5f47 curl#14399 Closes curl#16274
Before this patch curl code was redefining `getaddrinfo` and `freeaddrinfo` system symbols to plug in its debug wrappers. This was causing pains to avoid applying the redefinitions to system headers defining these functions, and to the local debug wrappers. Especially in unity builds. It also required workarounds for systems where these symbols are already macros. Introduce curl-namespaced macros for these functions and use them. This allows to drop all workarounds and makes it work in all envs, local targets and unity/bundle combinations. Also drop GHA/windows workaround and use the same unity batch across all jobs. Follow-up to 29e4eda #16272 Ref: #16272 Ref: 71cf0d1 #14772 Ref: 3efba94 #14765 Ref: f7d5f47 #14399 Closes #16274
Extend existing `--enable-test-bundles` and `-DCURL_TEST_BUNDLES=ON` options to also bundle test server programs into a single binary. With autotools, also bundle auxiliary libcurl sources for a "unity"-style build. It saves almost 10 minutes per run, across all CI jobs. On average it makes `build tests` steps 25% faster. With CMake, it brings down `testdeps` build steps to 32 to 37, from 45 to 64 before this patch, with unity. Without unity it brings it down from 400-420 to 280-300. For comparison, without unity and bundles, the number of build steps is around 1850. With autotools the gain is possibly larger because this patch does unity and bundle for test servers. The total reduction of build steps / log lines is 12000. It's 44% of reduction on average across all CI jobs. Follow-up to 77401af #16695 Follow-up to 71cf0d1 #14772 Comparison of 'build tests' targets in S(econds) and L(ines/steps), between before and after this patch: CI job |BefS|AftS|Gain|BefL|AftL|Gain| Comments :---------------------------------------- | -: | -: | -: | --:| --:| --:| :------- GHA/windows | | | | | | | Cygwin AM |110 | 95 | 15 | 237| 88| 149| l(ines) Cygwin CM | 34 | 27 | 7 | 63| 36| 27| s(teps, with Ninja) msys2, AM x86_64 !proxy | 35 | 21 | 14 | 255| 108| 147| l msys2, AM x86_64 default | 35 | 22 | 13 | 255| 108| 147| l msys2, CM x86_64 default | 14 | 11 | 3 | 63| 36| 27| s msys2, AM x86_64 default R | 41 | 29 | 12 | 245| 96| 149| l mingw, AM x86_64 default | 69 | 33 | 36 | 331| 156| 175| l mingw, AM x86_64 c-ares U | 69 | 33 | 36 | 331| 156| 175| l mingw, CM x86_64 schannel c-ares U | 32 | 24 | 8 | 63| 36| 27| s mingw, CM clang-x86_64 gnutls | 9 | 6 | 3 | 63| 36| 27| s mingw, CM ucrt-x86_64 schannel R TrackMem | 43 | 35 | 8 | 64| 37| 27| s mingw, CM clang-x86_64 openssl | 20 | 18 | 2 | 63| 36| 27| s mingw, CM ucrt-x86_64 schannel uwp | 36 | 34 | 2 | 47| 34| 13| s mingw, CM x86_64 schannel dev debug | 32 | 24 | 8 | 64| 37| 27| s mingw, CM i686 schannel R | 38 | 37 | 1 | 47| 34| 13| s dl-mingw, CM 9.5.0-x86_64 schan |102 | 94 | 8 | 63| 36| 27| s dl-mingw, CM 7.3.0-x86_64 schan mbedtls U | 32 | 24 | 8 | 94| 60| 34| l dl-mingw, CM 6.4.0-i686 schannel !unity | 42 | 31 | 11 | 427| 297| 130| l (no unity, yes bundle) linux-mingw, AM gcc | - | - | | -| -| | linux-mingw, CM gcc | 12 | 10 | 2 | 46| 33| 13| s mingw32ce, AM 4.4.0-arm schannel | - | - | | -| -| | mingw32ce, CM 4.4.0-arm schannel | 30 | 31 | -1 | 81| 61| 20| l msvc, CM x64-uwp openssl +examples | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows openssl | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows schannel MultiSSL U | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows libressl | 14 | 13 | 1 | 102| 68| 34| l msvc, CM x64-windows boringssl | 11 | 11 | 0 | 84| 64| 20| l msvc, CM x64-windows wolfssl +examples | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows mbedtls libssh | 14 | 10 | 4 | 102| 68| 34| l GHA/old-linux: | | | | | | | linux (cmake & autoconf) AM | 14 | 11 | 3 | 217| 75| 142| l linux (cmake & autoconf) CM | 15 | 13 | 2 | 545| 380| 165| l GHA/non-native: | | | | | | | AmigaOS, AM gcc AmiSSL m68k | - | - | | -| -| | AmigaOS, CM gcc AmiSSL m68k | 8 | 7 | 1 | 78| 58| 20| l Android 21, AM openssl arm64 | 7 | 5 | 2 | 222| 80| 142| l Android 21, CM openssl arm64 | 4 | 5 | -1 | 81| 61| 20| l Android 35, AM openssl arm64 | 7 | 5 | 2 | 222| 80| 142| l Android 35, CM boringssl !zstd arm64 | 4 | 3 | 1 | 81| 61| 20| l Android 35, CM openssl arm64 | 5 | 4 | 1 | 81| 61| 20| l FreeBSD, AM clang openssl arm64 | - | - | | -| -| | FreeBSD, AM clang openssl x86_64 | 7 | 3 | 4 | 513| 133| 380| l FreeBSD, CM clang openssl !unity !bundle..| 49 | 47 | 2 |1841|1841| | s (no unity, no bundle) FreeBSD, CM clang openssl arm64 | - | - | | -| -| | MS-DOS, AM djgpp openssl i586 | - | - | | -| -| | MS-DOS, CM djgpp openssl i586 | 6 | 7 | -1 | 45| 32| 13| s NetBSD, CM clang openssl x86_64 | 15 | 13 | 2 | 62| 35| 27| s OmniOS, AM gcc openssl amd64 | 20 | 11 | 9 | 216| 74| 142| l OpenBSD, CM clang libressl x86_64 | 9 | 7 | 2 | 62| 35| 27| s iOS, AM libressl arm64 | 6 | 3 | 3 | 217| 68| 149| l iOS, CM libressl arm64 | 10 | 10 | 0 | 236| 175| 61| l iOS, CM-Xcode libressl arm64 | 13 | 8 | 5 | 899| 627| 272| l GHA/linux: | | | | | | | AM bearssl | 9 | 8 | 1 | 258| 111| 147| l AM bearssl clang | 6 | 4 | 2 | 258| 111| 147| l AM libressl heimdal | 11 | 8 | 3 | 267| 120| 147| l CM libressl heimdal valgrind | 8 | 5 | 3 | 62| 35| 27| s AM libressl clang | 7 | 4 | 3 | 258| 111| 147| l AM wolfssl-all | 11 | 8 | 3 | 258| 111| 147| l AM wolfssl-opensslextra valgrind | 11 | 7 | 4 | 258| 111| 147| l AM mbedtls valgrind | 10 | 7 | 3 | 258| 111| 147| l AM mbedtls clang | 6 | 3 | 3 | 258| 111| 147| l CM mbedtls | 7 | 6 | 1 | 62| 35| 27| s CM mbedtls-pkg | 7 | 7 | 0 | 62| 35| 27| s CM mbedtls-pkg !pc | - | - | | -| -| | AM msh3 | 10 | 7 | 3 | 258| 111| 147| l CM msh3 | 7 | 7 | 0 | 62| 35| 27| s AM awslc | 18 | 15 | 3 | 247| 98| 149| l CM awslc | 13 | 11 | 2 | 400| 277| 123| s (no unity, yes bundle) AM openssl default | 10 | 7 | 3 | 258| 111| 147| l AM openssl libssh2 sync-resolver valgrind | 10 | 7 | 3 | 258| 111| 147| l AM openssl | 11 | 7 | 4 | 258| 111| 147| l AM openssl -O3 valgrind | 26 | 21 | 5 | 258| 111| 147| l AM openssl clang krb5 | 7 | 3 | 4 | 265| 118| 147| l CM openssl clang krb5 LTO | - | - | | -| -| | AM openssl !ipv6 !--libcurl | 10 | 7 | 3 | 258| 111| 147| l AM openssl https-only | 11 | 8 | 3 | 258| 111| 147| l CM openssl torture !FTP | 7 | 6 | 1 | 62| 35| 27| s CM openssl torture FTP | 8 | 6 | 2 | 62| 35| 27| s AM openssl i686 | 12 | 9 | 3 | 258| 111| 147| l AM !ssl !http !smtp !imap | 10 | 7 | 3 | 258| 111| 147| l AM clang-tidy | - | - | | -| -| | AM scanbuild | - | - | | -| -| | AM address-sanitizer | 10 | 6 | 4 | 258| 111| 147| l AM thread-sanitizer | 7 | 4 | 3 | 258| 111| 147| l AM memory-sanitizer | 10 | 6 | 4 | 258| 111| 147| l AM event-based | 10 | 7 | 3 | 253| 106| 147| l AM duphandle | 10 | 8 | 2 | 253| 106| 147| l AM rustls valgrind | 10 | 8 | 2 | 258| 111| 147| l CM rustls | 7 | 5 | 2 | 62| 35| 27| s AM IntelC openssl | 18 | 14 | 4 | 572| 282| 290| l AM Slackware openssl gssapi gcc | 17 | 14 | 3 | 252| 103| 149| l AM Alpine MUSL https-rr | 15 | 11 | 4 | 266| 119| 147| l AM Alpine MUSL c-ares https-rr | 15 | 11 | 4 | 266| 119| 147| l GHA/linux-http3: | | | | | | | AM quictls | 12 | 8 | 4 | 258| 111| 147| l AM gnutls | 11 | 8 | 3 | 257| 110| 147| l AM wolfssl | 11 | 9 | 2 | 257| 110| 147| l CM wolfssl | 8 | 7 | 1 | 62| 35| 27| s AM openssl-quic | 11 | 8 | 3 | 257| 110| 147| l AM quiche | 11 | 9 | 2 | 257| 110| 147| l CM quiche | 8 | 6 | 2 | 62| 35| 27| s GHA/macos: | | | | | | | AM clang !ssl !debug brotli zstd | 5 | 3 | 2 | 218| 69| 149| l AM clang !ssl | 4 | 5 | -1 | 227| 80| 147| l AM clang !ssl libssh2 AppleIDN | 5 | 1 | 4 | 227| 80| 147| l AM clang OpenSSL libssh c-ares | 4 | 2 | 2 | 227| 80| 147| l AM clang !ssl c-ares | 4 | 5 | -1 | 227| 80| 147| l AM clang !ssl HTTP-only | 4 | 2 | 2 | 222| 75| 147| l AM clang SecureTransport libssh2 | 3 | 3 | 0 | 227| 80| 147| l AM clang SecureTransport libssh2 10.12 | 4 | 2 | 2 | 227| 80| 147| l AM clang LibreSSL +examples | 5 | 2 | 3 | 227| 80| 147| l AM clang OpenSSL | 6 | 1 | 5 | 227| 80| 147| l AM clang OpenSSL event-based | 5 | 3 | 2 | 227| 80| 147| l AM clang quictls libssh2 !ldap 10.15 | 4 | 2 | 2 | 227| 80| 147| l CM clang OpenSSL gsasl rtmp AppleIDN | 2 | 2 | 0 | 45| 32| 13| s CM clang OpenSSL AppleIDN clang-tidy +e |150 | 76 | 74 | 400| 277| 123| s (clang-tidy) CM clang quictls +static libssh +examples | 2 | 2 | 0 | 45| 32| 13| s CM clang SecureTransport debug | 2 | 2 | 0 | 62| 35| 27| s CM clang LibreSSL !ldap heimdal c-ares +e | 4 | 2 | 2 | 45| 32| 13| s CM clang wolfSSL !ldap brotli zstd | 1 | 2 | -1 | 45| 32| 13| s CM clang mbedTLS openldap brotli zstd | 1 | 2 | -1 | 45| 32| 13| s CM clang GnuTLS !ldap krb5 | 0 | 1 | 0 | 45| 32| 13| s CM clang OpenSSL torture !FTP | 2 | 1 | 1 | 61| 34| 27| s CM clang OpenSSL torture FTP | 2 | 1 | 1 | 61| 34| 27| s AM llvm@15 OpenSSL libssh | 5 | 4 | 1 | 227| 80| 147| l CM llvm@15 OpenSSL gsasl rtmp AppleIDN | 3 | 2 | 1 | 45| 32| 13| s CM llvm@15 quictls +static libssh +e | 2 | 2 | 0 | 45| 32| 13| s CM llvm@15 SecureTransport debug | 3 | 2 | 1 | 62| 35| 27| s CM llvm@15 LibreSSL !ldap heimdal c-ares..| 3 | 1 | 2 | 45| 32| 13| s CM llvm@15 wolfSSL !ldap brotli zstd | 3 | 2 | 1 | 45| 32| 13| s CM llvm@15 mbedTLS openldap brotli zstd | 2 | 2 | 0 | 45| 32| 13| s CM llvm@15 GnuTLS !ldap krb5 | 2 | 1 | 1 | 45| 32| 13| s AM gcc-12 !ssl !debug | 18 | 12 | 6 | 218| 69| 149| l AM gcc-12 SecureTransport libssh2 | 13 | 6 | 7 | 227| 80| 147| l CM gcc-12 OpenSSL gsasl rtmp AppleIDN | 7 | 5 | 2 | 45| 32| 13| s CM gcc-12 quictls +static libssh +e | 8 | 6 | 2 | 45| 32| 13| s CM gcc-12 SecureTransport debug | 8 | 6 | 2 | 62| 35| 27| s CM gcc-12 LibreSSL !ldap heimdal c-ares...| 7 | 6 | 1 | 45| 32| 13| s CM gcc-12 wolfSSL !ldap brotli zstd | 16 | 6 | 10 | 45| 32| 13| s CM gcc-12 mbedTLS openldap brotli zstd | 11 | 6 | 5 | 45| 32| 13| s CM gcc-12 GnuTLS !ldap krb5 | 7 | 5 | 2 | 45| 32| 13| s AppVeyor: | | | | | | | VS2008 D x86 OpenSSL + Schannel SH +e | 56 | 39 | 17 | 21| 14| 7| s (VCBuild) VS2010 D x64 Schannel SH +e | 14 | 12 | 2 | 105| 78| 27| l VS2012 R x86 OpenSSL + Schannel SH | 23 | 21 | 2 | 84| 64| 20| l VS2013 D x64 OpenSSL SH Build-only | - | - | | -| -| | (no build tests) VS2015 D x64 OpenSSL ST Build-only | - | - | | -| -| | (no build tests) VS2017 D x64 OpenSSL SH Build-only | - | - | | -| -| | (no build tests) VS2019 D x64 OpenSSL + Schannel SH | 33 | 26 | 7 | 81| 61| 20| l VS2022 D x64 !SSL ST | 32 | 25 | 7 | 79| 59| 20| l VS2022 D x64 !SSL ST HTTP-only | 33 | 22 | 11 | 79| 59| 20| l VS2022 R arm64 Schannel ST | 74 | 69 | 5 | 79| 59| 20| l VS2022 R x64 Schannel SH U DBGBLD !CURLDBG| 66 | 61 | 5 | 78| 58| 20| l VS2022 D x64 Schannel ST U | 34 | 25 | 9 | 79| 59| 20| l VS2022 D x64 Schannel ST U clang-cl +e | 42 | 34 | 8 | 53| 40| 13| l VS2022 R x64 OpenSSL SH | 60 | 58 | 2 | 83| 63| 20| l Total |2394|1807|-587| 26k| 14k|-12k| in % | | |-24%| | |-45%| in minutes | | |9m47| | | | Before: GHA/windows: https://github.com/curl/curl/actions/runs/13854983424 GHA/old-linux: https://github.com/curl/curl/actions/runs/13854983399 GHA/non-native: https://github.com/curl/curl/actions/runs/13854983427 GHA/linux-http3: https://github.com/curl/curl/actions/runs/13854983409 GHA/linux: https://github.com/curl/curl/actions/runs/13854983406 GHA/macos: https://github.com/curl/curl/actions/runs/13854983401 Appveyor: https://ci.appveyor.com/project/curlorg/curl/builds/51703551 After: GHA/windows: https://github.com/curl/curl/actions/runs/13860433850?pr=15000 GHA/old-linux: https://github.com/curl/curl/actions/runs/13860433809?pr=15000 GHA/non-native: https://github.com/curl/curl/actions/runs/13860433828?pr=15000 GHA/linux-http3: https://github.com/curl/curl/actions/runs/13860433806?pr=15000 GHA/linux: https://github.com/curl/curl/actions/runs/13860433848?pr=15000 GHA/macos: https://github.com/curl/curl/actions/runs/13860433835?pr=15000 Appveyor: https://ci.appveyor.com/project/curlorg/curl/builds/51704222 Closes #15000
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Also fix to append executable extension to `libtests` and `units` executables when launching them. Follow-up to f4f2550 curl#15000 Follow-up to 71cf0d1 curl#14772
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Also fix to append executable extension to `libtests` and `units` executables when launching them. Follow-up to f4f2550 curl#15000 Follow-up to 71cf0d1 curl#14772
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Also fix to append executable extension to `libtests` and `units` executables when launching them. Follow-up to f4f2550 curl#15000 Follow-up to 71cf0d1 curl#14772
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Also fix to append executable extension to `libtests` and `units` executables when launching them. Follow-up to f4f2550 curl#15000 Follow-up to 71cf0d1 curl#14772
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Note: Make sure to "make clean" before changing the test bundle build setting. Also fix to append executable extension to all libtest and unit test executables when launching them. This should make it a tiny bit faster on Windows. Follow-up to f4f2550 #15000 Follow-up to 71cf0d1 #14772 Closes #16750
Or no-HTTP, no-HSTS builds, also MSH3 builds. CMake, VS2022, Debug, x64, no SSL, Static, Build-only: ``` C:\projects\curl\tests\unit\unit1660.c(46,1): error C2220: the following warning is treated as an error C:\projects\curl\tests\unit\unit1660.c(46,1): warning C4702: unreachable code ``` Ref: https://ci.appveyor.com/project/curlorg/curl/builds/50531210/job/cjewvo9agavthr3o#L216 Required-by: curl#14922 Cherry-picked from curl#14772 Closes curl#14971
Add support for single-block binaries that contain all libtests and unit tests respectively. Enable with: - autotools: `--enable-test-bundles` - cmake: `-DCURL_TEST_BUNDLES=ON` (They are compatible with `--enable-unity` and `-DCMAKE_UNITY_BUILD=ON` options, for further speed-up.) Makes libtests and unit tests build _fast_, needing little disk space even in static mode. Similar to CMake unity mode, but with a custom script, also supporting autotools builds. The price is having to deal with symbols/macros colliding between `lib*.c` and `unit*.c` sources. Maybe with naming conventions or other solutions this can be improved gradually and reduce the need for manual intervention by `mk-bundle.mk`. I've included a script that does the bulk of detecting name collisions. Also: - CI: enable test bundles. - CI: build tests in more jobs. - lib2305: fix FILE handle leak. - unit1661: fix memleak found by torture test by releasing the `bufref` structure in `unit_stop()` that was allocated in `unit_setup()`. ``` test 1661...[bufref unit tests] Leak detected: memory still allocated: 13 bytes allocated by /home/runner/work/curl/curl/tests/unit/unit1661.c:70 1661: torture FAILED: function number 1 in test. ``` Ref: https://github.com/curl/curl/actions/runs/10967279334/job/30456745290?pr=14772#step:8:41 Similar test suite builds with autotools default and cmake+bundle+unity: - GHA/Linux: 33s vs 7s https://github.com/curl/curl/actions/runs/10705668823/job/29681617374 - GHA/macOS 34s vs 2s https://github.com/curl/curl/actions/runs/10705668813/job/29681632885 - GHA/FreeBSD: 15m25 vs 6m21 (full workflow time, ~qemu) https://github.com/curl/curl/actions/runs/10705668811/job/29681607915 - GHA/Cygwin: 9m52 vs 32s https://github.com/curl/curl/actions/runs/10705668809/job/29681609965 - GHA/MSYS2: 3m52 vs 14s https://github.com/curl/curl/actions/runs/10705668808/job/29681624295 - GHA/mingw-w64: 5m45 vs 30s https://github.com/curl/curl/actions/runs/10705668808/job/29681628787 Autotools test suite builds compared between master -> `--enable-test-bundles`: - GHA/Linux: 33s -> 9s (run tests: 22m23 -> 20m44) https://github.com/curl/curl/actions/runs/10710030193/job/29695932185 https://github.com/curl/curl/actions/runs/10967831456/job/30458220344 - GHA/macOS: 25s -> 4s (run tests: 2m58 -> 2m24) https://github.com/curl/curl/actions/runs/10710030195/job/29695938444 https://github.com/curl/curl/actions/runs/10967831452/job/30458225762 - GHA/non-native (FreeBSD): 4m8 -> 3m12 (full workflow time, ~qemu) https://github.com/curl/curl/actions/runs/10710030198/job/29695928401 https://github.com/curl/curl/actions/runs/10967831458/job/30458212692 - GHA/Cygwin: 9m25 -> 1m9 (run tests: 9m19 -> 3m28) https://github.com/curl/curl/actions/runs/10710030212/job/29695928213 https://github.com/curl/curl/actions/runs/10967831453/job/30458213268 - GHA/MSYS2: 3m54 -> 32s (run tests: 6m3 -> 3m59) https://github.com/curl/curl/actions/runs/10710030190/job/29704850591 https://github.com/curl/curl/actions/runs/10967831449/job/30459280005 - GHA/mingw-w64: 5m42 -> 1m5 (run tests: 7m41 -> 5m36) https://github.com/curl/curl/actions/runs/10710030190/job/29704852058 https://github.com/curl/curl/actions/runs/10967831449/job/30459280862 - Azure MSYS2 mingw64 openssl: 38m55 -> 11m58 https://dev.azure.com/daniel0244/curl/_build/results?buildId=25546&view=logs&j=b58b8c59-0f61-52e9-0f9e-fad562a1e77f&t=0f9230a7-3b10-53ca-9938-700ece377c5e https://dev.azure.com/daniel0244/curl/_build/results?buildId=25547&view=logs&jobId=39473db1-3945-55d5-deb5-c218fad88dce&j=b58b8c59-0f61-52e9-0f9e-fad562a1e77f&t=0f9230a7-3b10-53ca-9938-700ece377c5e - Azure Ubuntu default: 2m15 -> 55s (all build) https://dev.azure.com/daniel0244/curl/_build/results?buildId=25546&view=logs&j=9d58b9ac-e1e6-53b6-f83a-1f9f1d912522&t=a6b38d83-e7cf-5a9b-c762-a178412717b7 https://dev.azure.com/daniel0244/curl/_build/results?buildId=25547&view=logs&jobId=39473db1-3945-55d5-deb5-c218fad88dce&j=9d58b9ac-e1e6-53b6-f83a-1f9f1d912522&t=a6b38d83-e7cf-5a9b-c762-a178412717b7 Cmake test suite builds compared between master -> `-DCURL_TEST_BUNDLES=ON` + unity: - GHA/Linux: 29s -> 7s (run tests: 4m50 -> 4m57, 20m43 -> 20m45) https://github.com/curl/curl/actions/runs/10710030193/job/29695941814 https://github.com/curl/curl/actions/runs/10705668823/job/29681622201 - GHA/Linux old: 44s -> 13s (bundle+no unity) (run tests: 5m5 -> 5m6) https://github.com/curl/curl/actions/runs/10718264094/job/29719794727 https://github.com/curl/curl/actions/runs/10718653175/job/29721009613 - GHA/macOS: 32s -> 2s (run tests: 2m43 -> 2m40) https://github.com/curl/curl/actions/runs/10710030195/job/29695931956 https://github.com/curl/curl/actions/runs/10705668813/job/29681638937 - GHA/non-native (*BSD): inconclusive (full workflow time, ~qemu) https://github.com/curl/curl/actions/runs/10710030198 https://github.com/curl/curl/actions/runs/10705668811 - GHA/Cygwin: 3m9 -> 32s https://github.com/curl/curl/actions/runs/10710030212/job/29695929075 https://github.com/curl/curl/actions/runs/10705668809/job/29681609965 - GHA/MSYS2: 2m24 -> 14s https://github.com/curl/curl/actions/runs/10710030190/job/29704850996 https://github.com/curl/curl/actions/runs/10705668808/job/29681624295 - GHA/mingw-w64: 3m56 -> 30s (run tests: 4m2 -> 3m52) https://github.com/curl/curl/actions/runs/10710030190/job/29704852219 https://github.com/curl/curl/actions/runs/10705668808/job/29681631393 - GHA/mingw-w64-old: 7m19 -> 1m44 (run tests: 3m30 -> 2m53) https://github.com/curl/curl/actions/runs/10710030190/job/29704849763 https://github.com/curl/curl/actions/runs/10705668808/job/29681622329 - GHA/MSVC: 3m22 -> 13s (run tests: 9m43 -> 4m22) https://github.com/curl/curl/actions/runs/10710030190/job/29704850411 https://github.com/curl/curl/actions/runs/10705668808/job/29681623313 - AppVeyor CI MSVC 2008: 4m3 -> 45s (full build) - AppVeyor CI MSVC 2010: 2m56 -> 1m8 (full build) - AppVeyor CI MSVC 2022: 10m19 -> 2m23 (full build) https://ci.appveyor.com/project/curlorg/curl/builds/50538455 https://ci.appveyor.com/project/curlorg/curl/builds/50536558 - AppVeyor CI total build time: 10m30 (master) -> 6m48 (unity) -> 4m5 (bundle) -> 3m24 (bundle+unity) -> 5m7 (bundle+unity+all jobs building tests) Closes curl#14772
They are still slow in these jobs/combinations. - non-native/FreeBSD/arm64 autotools +36s - non-native/FreeBSD/arm64 cmake +1m - windows/linux-cross-mingw-w64 autotools +33s These ones remain: - linux/aws-lc cmake +6s - windows/linux-cross-mingw-w64 cmake +12s Follow-up to 71cf0d1 curl#14772
Disable dependency tracking and enable unity + test bundles for the `configure-libssh` job that was missed in earlier commits. Follow-up to 71cf0d1 curl#14772 Follow-up to dff6619 curl#14975 Closes curl#15010
…ilds
- lib557: suppress `-Wformat-overflow` warning in source.
Fixes:
```
lib557.c: In function ‘test_float_formatting’:
lib557.c:1408:37: error: ‘%*f’ directive output of 2147483648 bytes exceeds ‘INT_MAX’ [-Werror=format-overflow=]
1408 | curl_msnprintf(buf, sizeof(buf), "%*f", INT_MIN, 9.1);
| ^~~
lib557.c:1408:3: note: ‘curl_msnprintf’ output 2147483649 bytes
1408 | curl_msnprintf(buf, sizeof(buf), "%*f", INT_MIN, 9.1);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
Ref: https://app.circleci.com/pipelines/github/curl/curl/10226/workflows/87642ee9-cda6-4916-8206-c82aac5f595e/jobs/107669?invite=true#step-106-40996_46
The root cause of why this option gets enabled remains undiscovered.
Reported-by: Daniel Stenberg
Fixes curl#15008
Follow-up to 71cf0d1 curl#14772
- build: drop `-Wno-format-overflow` from picky warning list.
These options only get used with picky warnings enabled.
Follow-up to 145f87b curl#14598
- unit1652: suppress in source (and not rely on picky warnings anymore.)
Closes curl#15012
Test build step speed-up (3x): 18s -> 6s Follow-up to 71cf0d1 curl#14772 Closes curl#15022
- appveyor: add build-only job for clang-cl. - cmake: `-pedantic-errors` enables `-Werror,-Wlanguage-extension-token` automatically, which makes `__int64` detection fail. Explictly disable this compiler warning for clang-cl to make the feature detection work and to accept `__int64` in the source code. - cmake: disable `-Wlanguage-extension-token` warning for clang-cl to fix these when encountering `__int64`: ``` lib/formdata.c(797,29): error : extension used [-Werror,-Wlanguage-extension-token] lib/warnless.c(117,33): error : extension used [-Werror,-Wlanguage-extension-token] lib/warnless.c(60,28): message : expanded from macro 'CURL_MASK_SCOFFT' lib/warnless.c(59,38): message : expanded from macro 'CURL_MASK_UCOFFT' include\curl/system.h(352,40): message : expanded from macro 'CURL_TYPEOF_CURL_OFF_T' ``` - make `__GNUC__` warning suppressions apply to `__clang__` too. Necessary for clang-cl, which defines the latter, but not the former. (Regular clang defines both.) - examples: fix clang-cl compiler warning in `http2-upload.c`. ``` docs\examples\http2-upload.c(56,5): error : no previous prototype for function 'my_gettimeofday' [-Werror,-Wmissing-prototypes] docs\examples\http2-upload.c(56,1): message : declare 'static' if the function is not intended to be used outside of this translation unit ``` - unit2604: add missing `#pragma GCC diagnostic pop`. Follow-up to e53523f curl#14859 - unit1652: limit compiler warning suppression to GCC. They do not affect clang builds. Follow-up to 71cf0d1 curl#14772 Closes curl#15449
- `.gitignore`: delete, dedupe and move rules upwards. Ref: 6389ba8 curl#13311 - `.gitignore`: fix generated test sources. Follow-up to 71cf0d1 curl#14772 - `.gitignore`: replace exe listings with a wildcard. - lib: move `setup-*.h` from `EXTRA_DIST` to `CURL_HFILES`. - `makedebug.bat`: uppercase an argument to match docs. - GHA/non-native: delete stray env. Follow-up to 12a6de2 curl#16043 - sort source lists. Closes curl#16093
Necessary to catch rare cases when `checksrc` hits these files when they are not populated yet: ``` ./curltool_unity.c:1:1: error: Missing copyright statement (COPYRIGHT) ^ ``` https://github.com/curl/curl/actions/runs/12995546740/job/36242556713?pr=16094#step:37:123 Follow-up to 71cf0d1 curl#14772 Closes curl#16102
Before this patch curl code was redefining `getaddrinfo` and `freeaddrinfo` system symbols to plug in its debug wrappers. This was causing pains to avoid applying the redefinitions to system headers defining these functions, and to the local debug wrappers. Especially in unity builds. It also required workarounds for systems where these symbols are already macros. Introduce curl-namespaced macros for these functions and use them. This allows to drop all workarounds and makes it work in all envs, local targets and unity/bundle combinations. Also drop GHA/windows workaround and use the same unity batch across all jobs. Follow-up to 29e4eda curl#16272 Ref: curl#16272 Ref: 71cf0d1 curl#14772 Ref: 3efba94 curl#14765 Ref: f7d5f47 curl#14399 Closes curl#16274
Extend existing `--enable-test-bundles` and `-DCURL_TEST_BUNDLES=ON` options to also bundle test server programs into a single binary. With autotools, also bundle auxiliary libcurl sources for a "unity"-style build. It saves almost 10 minutes per run, across all CI jobs. On average it makes `build tests` steps 25% faster. With CMake, it brings down `testdeps` build steps to 32 to 37, from 45 to 64 before this patch, with unity. Without unity it brings it down from 400-420 to 280-300. For comparison, without unity and bundles, the number of build steps is around 1850. With autotools the gain is possibly larger because this patch does unity and bundle for test servers. The total reduction of build steps / log lines is 12000. It's 44% of reduction on average across all CI jobs. Follow-up to 77401af curl#16695 Follow-up to 71cf0d1 curl#14772 Comparison of 'build tests' targets in S(econds) and L(ines/steps), between before and after this patch: CI job |BefS|AftS|Gain|BefL|AftL|Gain| Comments :---------------------------------------- | -: | -: | -: | --:| --:| --:| :------- GHA/windows | | | | | | | Cygwin AM |110 | 95 | 15 | 237| 88| 149| l(ines) Cygwin CM | 34 | 27 | 7 | 63| 36| 27| s(teps, with Ninja) msys2, AM x86_64 !proxy | 35 | 21 | 14 | 255| 108| 147| l msys2, AM x86_64 default | 35 | 22 | 13 | 255| 108| 147| l msys2, CM x86_64 default | 14 | 11 | 3 | 63| 36| 27| s msys2, AM x86_64 default R | 41 | 29 | 12 | 245| 96| 149| l mingw, AM x86_64 default | 69 | 33 | 36 | 331| 156| 175| l mingw, AM x86_64 c-ares U | 69 | 33 | 36 | 331| 156| 175| l mingw, CM x86_64 schannel c-ares U | 32 | 24 | 8 | 63| 36| 27| s mingw, CM clang-x86_64 gnutls | 9 | 6 | 3 | 63| 36| 27| s mingw, CM ucrt-x86_64 schannel R TrackMem | 43 | 35 | 8 | 64| 37| 27| s mingw, CM clang-x86_64 openssl | 20 | 18 | 2 | 63| 36| 27| s mingw, CM ucrt-x86_64 schannel uwp | 36 | 34 | 2 | 47| 34| 13| s mingw, CM x86_64 schannel dev debug | 32 | 24 | 8 | 64| 37| 27| s mingw, CM i686 schannel R | 38 | 37 | 1 | 47| 34| 13| s dl-mingw, CM 9.5.0-x86_64 schan |102 | 94 | 8 | 63| 36| 27| s dl-mingw, CM 7.3.0-x86_64 schan mbedtls U | 32 | 24 | 8 | 94| 60| 34| l dl-mingw, CM 6.4.0-i686 schannel !unity | 42 | 31 | 11 | 427| 297| 130| l (no unity, yes bundle) linux-mingw, AM gcc | - | - | | -| -| | linux-mingw, CM gcc | 12 | 10 | 2 | 46| 33| 13| s mingw32ce, AM 4.4.0-arm schannel | - | - | | -| -| | mingw32ce, CM 4.4.0-arm schannel | 30 | 31 | -1 | 81| 61| 20| l msvc, CM x64-uwp openssl +examples | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows openssl | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows schannel MultiSSL U | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows libressl | 14 | 13 | 1 | 102| 68| 34| l msvc, CM x64-windows boringssl | 11 | 11 | 0 | 84| 64| 20| l msvc, CM x64-windows wolfssl +examples | 13 | 10 | 3 | 102| 68| 34| l msvc, CM x64-windows mbedtls libssh | 14 | 10 | 4 | 102| 68| 34| l GHA/old-linux: | | | | | | | linux (cmake & autoconf) AM | 14 | 11 | 3 | 217| 75| 142| l linux (cmake & autoconf) CM | 15 | 13 | 2 | 545| 380| 165| l GHA/non-native: | | | | | | | AmigaOS, AM gcc AmiSSL m68k | - | - | | -| -| | AmigaOS, CM gcc AmiSSL m68k | 8 | 7 | 1 | 78| 58| 20| l Android 21, AM openssl arm64 | 7 | 5 | 2 | 222| 80| 142| l Android 21, CM openssl arm64 | 4 | 5 | -1 | 81| 61| 20| l Android 35, AM openssl arm64 | 7 | 5 | 2 | 222| 80| 142| l Android 35, CM boringssl !zstd arm64 | 4 | 3 | 1 | 81| 61| 20| l Android 35, CM openssl arm64 | 5 | 4 | 1 | 81| 61| 20| l FreeBSD, AM clang openssl arm64 | - | - | | -| -| | FreeBSD, AM clang openssl x86_64 | 7 | 3 | 4 | 513| 133| 380| l FreeBSD, CM clang openssl !unity !bundle..| 49 | 47 | 2 |1841|1841| | s (no unity, no bundle) FreeBSD, CM clang openssl arm64 | - | - | | -| -| | MS-DOS, AM djgpp openssl i586 | - | - | | -| -| | MS-DOS, CM djgpp openssl i586 | 6 | 7 | -1 | 45| 32| 13| s NetBSD, CM clang openssl x86_64 | 15 | 13 | 2 | 62| 35| 27| s OmniOS, AM gcc openssl amd64 | 20 | 11 | 9 | 216| 74| 142| l OpenBSD, CM clang libressl x86_64 | 9 | 7 | 2 | 62| 35| 27| s iOS, AM libressl arm64 | 6 | 3 | 3 | 217| 68| 149| l iOS, CM libressl arm64 | 10 | 10 | 0 | 236| 175| 61| l iOS, CM-Xcode libressl arm64 | 13 | 8 | 5 | 899| 627| 272| l GHA/linux: | | | | | | | AM bearssl | 9 | 8 | 1 | 258| 111| 147| l AM bearssl clang | 6 | 4 | 2 | 258| 111| 147| l AM libressl heimdal | 11 | 8 | 3 | 267| 120| 147| l CM libressl heimdal valgrind | 8 | 5 | 3 | 62| 35| 27| s AM libressl clang | 7 | 4 | 3 | 258| 111| 147| l AM wolfssl-all | 11 | 8 | 3 | 258| 111| 147| l AM wolfssl-opensslextra valgrind | 11 | 7 | 4 | 258| 111| 147| l AM mbedtls valgrind | 10 | 7 | 3 | 258| 111| 147| l AM mbedtls clang | 6 | 3 | 3 | 258| 111| 147| l CM mbedtls | 7 | 6 | 1 | 62| 35| 27| s CM mbedtls-pkg | 7 | 7 | 0 | 62| 35| 27| s CM mbedtls-pkg !pc | - | - | | -| -| | AM msh3 | 10 | 7 | 3 | 258| 111| 147| l CM msh3 | 7 | 7 | 0 | 62| 35| 27| s AM awslc | 18 | 15 | 3 | 247| 98| 149| l CM awslc | 13 | 11 | 2 | 400| 277| 123| s (no unity, yes bundle) AM openssl default | 10 | 7 | 3 | 258| 111| 147| l AM openssl libssh2 sync-resolver valgrind | 10 | 7 | 3 | 258| 111| 147| l AM openssl | 11 | 7 | 4 | 258| 111| 147| l AM openssl -O3 valgrind | 26 | 21 | 5 | 258| 111| 147| l AM openssl clang krb5 | 7 | 3 | 4 | 265| 118| 147| l CM openssl clang krb5 LTO | - | - | | -| -| | AM openssl !ipv6 !--libcurl | 10 | 7 | 3 | 258| 111| 147| l AM openssl https-only | 11 | 8 | 3 | 258| 111| 147| l CM openssl torture !FTP | 7 | 6 | 1 | 62| 35| 27| s CM openssl torture FTP | 8 | 6 | 2 | 62| 35| 27| s AM openssl i686 | 12 | 9 | 3 | 258| 111| 147| l AM !ssl !http !smtp !imap | 10 | 7 | 3 | 258| 111| 147| l AM clang-tidy | - | - | | -| -| | AM scanbuild | - | - | | -| -| | AM address-sanitizer | 10 | 6 | 4 | 258| 111| 147| l AM thread-sanitizer | 7 | 4 | 3 | 258| 111| 147| l AM memory-sanitizer | 10 | 6 | 4 | 258| 111| 147| l AM event-based | 10 | 7 | 3 | 253| 106| 147| l AM duphandle | 10 | 8 | 2 | 253| 106| 147| l AM rustls valgrind | 10 | 8 | 2 | 258| 111| 147| l CM rustls | 7 | 5 | 2 | 62| 35| 27| s AM IntelC openssl | 18 | 14 | 4 | 572| 282| 290| l AM Slackware openssl gssapi gcc | 17 | 14 | 3 | 252| 103| 149| l AM Alpine MUSL https-rr | 15 | 11 | 4 | 266| 119| 147| l AM Alpine MUSL c-ares https-rr | 15 | 11 | 4 | 266| 119| 147| l GHA/linux-http3: | | | | | | | AM quictls | 12 | 8 | 4 | 258| 111| 147| l AM gnutls | 11 | 8 | 3 | 257| 110| 147| l AM wolfssl | 11 | 9 | 2 | 257| 110| 147| l CM wolfssl | 8 | 7 | 1 | 62| 35| 27| s AM openssl-quic | 11 | 8 | 3 | 257| 110| 147| l AM quiche | 11 | 9 | 2 | 257| 110| 147| l CM quiche | 8 | 6 | 2 | 62| 35| 27| s GHA/macos: | | | | | | | AM clang !ssl !debug brotli zstd | 5 | 3 | 2 | 218| 69| 149| l AM clang !ssl | 4 | 5 | -1 | 227| 80| 147| l AM clang !ssl libssh2 AppleIDN | 5 | 1 | 4 | 227| 80| 147| l AM clang OpenSSL libssh c-ares | 4 | 2 | 2 | 227| 80| 147| l AM clang !ssl c-ares | 4 | 5 | -1 | 227| 80| 147| l AM clang !ssl HTTP-only | 4 | 2 | 2 | 222| 75| 147| l AM clang SecureTransport libssh2 | 3 | 3 | 0 | 227| 80| 147| l AM clang SecureTransport libssh2 10.12 | 4 | 2 | 2 | 227| 80| 147| l AM clang LibreSSL +examples | 5 | 2 | 3 | 227| 80| 147| l AM clang OpenSSL | 6 | 1 | 5 | 227| 80| 147| l AM clang OpenSSL event-based | 5 | 3 | 2 | 227| 80| 147| l AM clang quictls libssh2 !ldap 10.15 | 4 | 2 | 2 | 227| 80| 147| l CM clang OpenSSL gsasl rtmp AppleIDN | 2 | 2 | 0 | 45| 32| 13| s CM clang OpenSSL AppleIDN clang-tidy +e |150 | 76 | 74 | 400| 277| 123| s (clang-tidy) CM clang quictls +static libssh +examples | 2 | 2 | 0 | 45| 32| 13| s CM clang SecureTransport debug | 2 | 2 | 0 | 62| 35| 27| s CM clang LibreSSL !ldap heimdal c-ares +e | 4 | 2 | 2 | 45| 32| 13| s CM clang wolfSSL !ldap brotli zstd | 1 | 2 | -1 | 45| 32| 13| s CM clang mbedTLS openldap brotli zstd | 1 | 2 | -1 | 45| 32| 13| s CM clang GnuTLS !ldap krb5 | 0 | 1 | 0 | 45| 32| 13| s CM clang OpenSSL torture !FTP | 2 | 1 | 1 | 61| 34| 27| s CM clang OpenSSL torture FTP | 2 | 1 | 1 | 61| 34| 27| s AM llvm@15 OpenSSL libssh | 5 | 4 | 1 | 227| 80| 147| l CM llvm@15 OpenSSL gsasl rtmp AppleIDN | 3 | 2 | 1 | 45| 32| 13| s CM llvm@15 quictls +static libssh +e | 2 | 2 | 0 | 45| 32| 13| s CM llvm@15 SecureTransport debug | 3 | 2 | 1 | 62| 35| 27| s CM llvm@15 LibreSSL !ldap heimdal c-ares..| 3 | 1 | 2 | 45| 32| 13| s CM llvm@15 wolfSSL !ldap brotli zstd | 3 | 2 | 1 | 45| 32| 13| s CM llvm@15 mbedTLS openldap brotli zstd | 2 | 2 | 0 | 45| 32| 13| s CM llvm@15 GnuTLS !ldap krb5 | 2 | 1 | 1 | 45| 32| 13| s AM gcc-12 !ssl !debug | 18 | 12 | 6 | 218| 69| 149| l AM gcc-12 SecureTransport libssh2 | 13 | 6 | 7 | 227| 80| 147| l CM gcc-12 OpenSSL gsasl rtmp AppleIDN | 7 | 5 | 2 | 45| 32| 13| s CM gcc-12 quictls +static libssh +e | 8 | 6 | 2 | 45| 32| 13| s CM gcc-12 SecureTransport debug | 8 | 6 | 2 | 62| 35| 27| s CM gcc-12 LibreSSL !ldap heimdal c-ares...| 7 | 6 | 1 | 45| 32| 13| s CM gcc-12 wolfSSL !ldap brotli zstd | 16 | 6 | 10 | 45| 32| 13| s CM gcc-12 mbedTLS openldap brotli zstd | 11 | 6 | 5 | 45| 32| 13| s CM gcc-12 GnuTLS !ldap krb5 | 7 | 5 | 2 | 45| 32| 13| s AppVeyor: | | | | | | | VS2008 D x86 OpenSSL + Schannel SH +e | 56 | 39 | 17 | 21| 14| 7| s (VCBuild) VS2010 D x64 Schannel SH +e | 14 | 12 | 2 | 105| 78| 27| l VS2012 R x86 OpenSSL + Schannel SH | 23 | 21 | 2 | 84| 64| 20| l VS2013 D x64 OpenSSL SH Build-only | - | - | | -| -| | (no build tests) VS2015 D x64 OpenSSL ST Build-only | - | - | | -| -| | (no build tests) VS2017 D x64 OpenSSL SH Build-only | - | - | | -| -| | (no build tests) VS2019 D x64 OpenSSL + Schannel SH | 33 | 26 | 7 | 81| 61| 20| l VS2022 D x64 !SSL ST | 32 | 25 | 7 | 79| 59| 20| l VS2022 D x64 !SSL ST HTTP-only | 33 | 22 | 11 | 79| 59| 20| l VS2022 R arm64 Schannel ST | 74 | 69 | 5 | 79| 59| 20| l VS2022 R x64 Schannel SH U DBGBLD !CURLDBG| 66 | 61 | 5 | 78| 58| 20| l VS2022 D x64 Schannel ST U | 34 | 25 | 9 | 79| 59| 20| l VS2022 D x64 Schannel ST U clang-cl +e | 42 | 34 | 8 | 53| 40| 13| l VS2022 R x64 OpenSSL SH | 60 | 58 | 2 | 83| 63| 20| l Total |2394|1807|-587| 26k| 14k|-12k| in % | | |-24%| | |-45%| in minutes | | |9m47| | | | Before: GHA/windows: https://github.com/curl/curl/actions/runs/13854983424 GHA/old-linux: https://github.com/curl/curl/actions/runs/13854983399 GHA/non-native: https://github.com/curl/curl/actions/runs/13854983427 GHA/linux-http3: https://github.com/curl/curl/actions/runs/13854983409 GHA/linux: https://github.com/curl/curl/actions/runs/13854983406 GHA/macos: https://github.com/curl/curl/actions/runs/13854983401 Appveyor: https://ci.appveyor.com/project/curlorg/curl/builds/51703551 After: GHA/windows: https://github.com/curl/curl/actions/runs/13860433850?pr=15000 GHA/old-linux: https://github.com/curl/curl/actions/runs/13860433809?pr=15000 GHA/non-native: https://github.com/curl/curl/actions/runs/13860433828?pr=15000 GHA/linux-http3: https://github.com/curl/curl/actions/runs/13860433806?pr=15000 GHA/linux: https://github.com/curl/curl/actions/runs/13860433848?pr=15000 GHA/macos: https://github.com/curl/curl/actions/runs/13860433835?pr=15000 Appveyor: https://ci.appveyor.com/project/curlorg/curl/builds/51704222 Closes curl#15000
If libtests, units and servers binaries are all present, auto-enable bundle mode. Drop manual runtests option. Note: Make sure to "make clean" before changing the test bundle build setting. Also fix to append executable extension to all libtest and unit test executables when launching them. This should make it a tiny bit faster on Windows. Follow-up to f4f2550 curl#15000 Follow-up to 71cf0d1 curl#14772 Closes curl#16750
Some tests make a hard-coded call to the libtest binary in the precheck step. With bundle builds the binary changed name and calling convention. Before this patch these tests failed the pre-check and did not run for the 5 affected tests: 518, 537, 678, 1517, 1960 Fixing, e.g.: ``` test 1517 SKIPPED: precheck command error ``` https://github.com/curl/curl/actions/runs/16611990422/job/46996698437?pr=18039#step:13:4832 It also fixes builds with a custom `CURL_DIRSUFFIX` set. Follow-up to 2c27a67 #17590 Follow-up to 71cf0d1 #14772 Closes #18099
Add support for single-block binaries that contain all libtests and
unit tests respectively.
Enable with:
--enable-test-bundles-DCURL_TEST_BUNDLES=ON(They are compatible with
--enable-unityand-DCMAKE_UNITY_BUILD=ONoptions, for further speed-up.)
Makes libtests and unit tests build fast, needing little disk space
even in static mode. Similar to CMake unity mode, but with a custom
script, also supporting autotools builds.
The price is having to deal with symbols/macros colliding between
lib*.candunit*.csources. Maybe with naming conventions or othersolutions this can be improved gradually and reduce the need for manual
intervention by
mk-bundle.mk. I've included a script that does the bulkof detecting name collisions.
Also:
bufrefstructure in
unit_stop()that was allocated inunit_setup().Similar test suite builds with autotools default and cmake+bundle+unity:
https://github.com/curl/curl/actions/runs/10705668823/job/29681617374
https://github.com/curl/curl/actions/runs/10705668813/job/29681632885
https://github.com/curl/curl/actions/runs/10705668811/job/29681607915
https://github.com/curl/curl/actions/runs/10705668809/job/29681609965
https://github.com/curl/curl/actions/runs/10705668808/job/29681624295
https://github.com/curl/curl/actions/runs/10705668808/job/29681628787
Autotools test suite builds compared between master →
--enable-test-bundles:https://github.com/curl/curl/actions/runs/10710030193/job/29695932185
https://github.com/curl/curl/actions/runs/10967831456/job/30458220344
https://github.com/curl/curl/actions/runs/10710030195/job/29695938444
https://github.com/curl/curl/actions/runs/10967831452/job/30458225762
https://github.com/curl/curl/actions/runs/10710030198/job/29695928401
https://github.com/curl/curl/actions/runs/10967831458/job/30458212692
https://github.com/curl/curl/actions/runs/10710030212/job/29695928213
https://github.com/curl/curl/actions/runs/10967831453/job/30458213268
https://github.com/curl/curl/actions/runs/10710030190/job/29704850591
https://github.com/curl/curl/actions/runs/10967831449/job/30459280005
https://github.com/curl/curl/actions/runs/10710030190/job/29704852058
https://github.com/curl/curl/actions/runs/10967831449/job/30459280862
https://dev.azure.com/daniel0244/curl/_build/results?buildId=25546&view=logs&j=b58b8c59-0f61-52e9-0f9e-fad562a1e77f&t=0f9230a7-3b10-53ca-9938-700ece377c5e
https://dev.azure.com/daniel0244/curl/_build/results?buildId=25547&view=logs&jobId=39473db1-3945-55d5-deb5-c218fad88dce&j=b58b8c59-0f61-52e9-0f9e-fad562a1e77f&t=0f9230a7-3b10-53ca-9938-700ece377c5e
https://dev.azure.com/daniel0244/curl/_build/results?buildId=25546&view=logs&j=9d58b9ac-e1e6-53b6-f83a-1f9f1d912522&t=a6b38d83-e7cf-5a9b-c762-a178412717b7
https://dev.azure.com/daniel0244/curl/_build/results?buildId=25547&view=logs&jobId=39473db1-3945-55d5-deb5-c218fad88dce&j=9d58b9ac-e1e6-53b6-f83a-1f9f1d912522&t=a6b38d83-e7cf-5a9b-c762-a178412717b7
Cmake test suite builds compared between master →
-DCURL_TEST_BUNDLES=ON+ unity:https://github.com/curl/curl/actions/runs/10710030193/job/29695941814
https://github.com/curl/curl/actions/runs/10705668823/job/29681622201
https://github.com/curl/curl/actions/runs/10718264094/job/29719794727
https://github.com/curl/curl/actions/runs/10718653175/job/29721009613
https://github.com/curl/curl/actions/runs/10710030195/job/29695931956
https://github.com/curl/curl/actions/runs/10705668813/job/29681638937
https://github.com/curl/curl/actions/runs/10710030198
https://github.com/curl/curl/actions/runs/10705668811
https://github.com/curl/curl/actions/runs/10710030212/job/29695929075
https://github.com/curl/curl/actions/runs/10705668809/job/29681609965
https://github.com/curl/curl/actions/runs/10710030190/job/29704850996
https://github.com/curl/curl/actions/runs/10705668808/job/29681624295
https://github.com/curl/curl/actions/runs/10710030190/job/29704852219
https://github.com/curl/curl/actions/runs/10705668808/job/29681631393
https://github.com/curl/curl/actions/runs/10710030190/job/29704849763
https://github.com/curl/curl/actions/runs/10705668808/job/29681622329
https://github.com/curl/curl/actions/runs/10710030190/job/29704850411
https://github.com/curl/curl/actions/runs/10705668808/job/29681623313
https://ci.appveyor.com/project/curlorg/curl/builds/50538455
https://ci.appveyor.com/project/curlorg/curl/builds/50536558
Curl_cmalloc()in test code?runtests.pl -bundleoption with something automatic? This would allow running it directly without having to add-bundlemanually to match such build. [→ FUTURE]cmake build-onlyjob.linux-mingw, AM/CM gccjobs.tests/server. + mergemk-bundle.pl,mk-bundle-server.pl? and perhapsmk-unity.pl? [→ SEPARATE PR](to give a speed boost for building
tests/servers)getaddrinfo()unwanted override yet again.