Page MenuHomePhabricator

ci: ubsan report_error_type=1 and add suppressions
ClosedPublic

Authored by PiRK on Dec 7 2022, 16:43.

Details

Reviewers
sdulfari
Fabien
Group Reviewers
Restricted Project
Commits
rABCeae5b5155723: ci: ubsan report_error_type=1 and add suppressions
Summary
Test Plan

With UBSAN:

ninja && ninja check

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

PiRK requested review of this revision.Dec 7 2022, 16:43

@bot build-ubsan

Tail of the build log:

[522/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/transactionview.cpp.o
[523/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/walletframe.cpp.o
[524/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/transactiontablemodel.cpp.o
[525/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/paymentrequestplus.cpp.o
[526/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/walletcontroller.cpp.o
[527/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/sendcoinsdialog.cpp.o
[528/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/walletview.cpp.o
[529/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/walletmodel.cpp.o
[530/535] Linking CXX static library src/qt/libbitcoin-qt-base.a
[531/535] Automatic MOC for target bitcoin-qt
[532/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt.dir/bitcoin-qt_autogen/mocs_compilation.cpp.o
[533/535] Building CXX object src/qt/CMakeFiles/bitcoin-qt.dir/main.cpp.o
[534/535] Linking CXX executable src/qt/bitcoin-qt
[534/535] Install the project...
-- Install configuration: "RelWithDebInfo"
-- Installing: /results/artifacts/lib/libbitcoinconsensus.so.0.26.8
-- Installing: /results/artifacts/lib/libbitcoinconsensus.so.0
-- Installing: /results/artifacts/lib/libbitcoinconsensus.so
-- Installing: /results/artifacts/include/bitcoinconsensus.h
-- Installing: /results/artifacts/bin/bitcoin-wallet
-- Installing: /results/artifacts/bin/bitcoin-seeder
-- Installing: /results/artifacts/bin/bitcoin-cli
-- Installing: /results/artifacts/bin/bitcoin-tx
-- Installing: /results/artifacts/bin/bitcoind
-- Installing: /results/artifacts/bin/bitcoin-qt
[1/481] Generating data/base58_encode_decode.json.h
[2/481] Generating data/key_io_invalid.json.h
[3/481] Generating data/blockfilters.json.h
[4/481] Generating data/key_io_valid.json.h
[5/481] Generate ASMAP header from data/asmap.raw
[6/481] Generating data/tx_invalid.json.h
[7/481] Generating data/tx_valid.json.h
[8/481] Generating data/script_tests.json.h
[9/481] Generating data/sighash.json.h
[10/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/fixture.cpp.o
[11/481] Building CXX object src/test/CMakeFiles/test_bitcoin.dir/fixture.cpp.o
[12/481] Building CXX object src/test/CMakeFiles/test_bitcoin.dir/jsonutil.cpp.o
[13/481] Building C object src/secp256k1/CMakeFiles/secp256k1-exhaustive_tests.dir/src/tests_exhaustive.c.o
[14/481] Linking C executable src/secp256k1/secp256k1-exhaustive_tests
[15/481] Building CXX object src/test/CMakeFiles/test_bitcoin.dir/sigutil.cpp.o
[16/481] secp256k1: testing secp256k1-exhaustive_tests
FAILED: src/secp256k1/CMakeFiles/check-secp256k1-secp256k1-exhaustive_tests 
cd /work/abc-ci-builds/build-ubsan/src/secp256k1 && /usr/bin/cmake -E make_directory /work/abc-ci-builds/build-ubsan/test/junit && /usr/bin/cmake -E make_directory /work/abc-ci-builds/build-ubsan/test/log && /usr/bin/cmake -E env UBSAN_OPTIONS=suppressions=/work/test/sanitizer_suppressions/ubsan:print_stacktrace=1:halt_on_error=1:report_error_type=1log_path=stdout /work/cmake/utils/log-and-print-on-failure.sh /work/abc-ci-builds/build-ubsan/test/log/secp256k1-secp256k1-exhaustive_tests.log /work/abc-ci-builds/build-ubsan/src/secp256k1/secp256k1-exhaustive_tests
ERROR: Invalid value for bool option: '1log_path=stdout'
UndefinedBehaviorSanitizer: ERROR: Flag parsing failed.
[17/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/init_tests.cpp.o
[18/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/proofcomparator_tests.cpp.o
[19/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/delegation_tests.cpp.o
[20/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/util.cpp.o
[21/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/voterecord_tests.cpp.o
[22/481] Building CXX object src/test/CMakeFiles/test_bitcoin.dir/scriptflags.cpp.o
[23/481] Building CXX object src/test/CMakeFiles/test_bitcoin.dir/__/wallet/test/init_test_fixture.cpp.o
[24/481] Building C object src/secp256k1/CMakeFiles/secp256k1-tests.dir/src/tests.c.o
[25/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/compactproofs_tests.cpp.o
[26/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/proof_tests.cpp.o
[27/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/proofpool_tests.cpp.o
[28/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/peermanager_tests.cpp.o
[29/481] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/processor_tests.cpp.o
ninja: build stopped: subcommand failed.
Build build-ubsan failed with exit code 1
sdulfari requested changes to this revision.Dec 7 2022, 19:13
sdulfari added a subscriber: sdulfari.

back to you

This revision now requires changes to proceed.Dec 7 2022, 19:13
Fabien added inline comments.
cmake/modules/Sanitizers.cmake
54 ↗(On Diff #37067)
PiRK edited the summary of this revision. (Show Details)

fix UBSAN_OPTIONS

The backport is correct but please follow up with suppressions removal and investigations.

test/sanitizer_suppressions/ubsan
41 ↗(On Diff #37098)

I don't like that at all, please take care to keep on with PR21000 to make it include path agnostic

56 ↗(On Diff #37098)

This one is a bit worrying, do you know what it's for ?

64 ↗(On Diff #37098)

Can you investigate on that one ? We're about to make changes there, I'd rather have the sanitizer not dismiss the file completely.

66 ↗(On Diff #37098)

Please backport asap PR23795 as a follow up

This revision is now accepted and ready to land.Dec 8 2022, 17:19