Skip to content

Instantly share code, notes, and snippets.

@fanquake
Created December 14, 2018 08:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fanquake/79a9a12286d3cd2e4cb961c32a32dee3 to your computer and use it in GitHub Desktop.
Save fanquake/79a9a12286d3cd2e4cb961c32a32dee3 to your computer and use it in GitHub Desktop.
sanitizers=thread macOS (10.14.2)

master at 7a30e0f6c54443616fdc28b7080dcbc9b630ac77

./autogen.sh
./configure --with-sanitizers=thread
make


  CXXLD    libbitcoinconsensus.la
Undefined symbols for architecture x86_64:
  "___tsan_unaligned_read2", referenced from:
      CScriptNum::CScriptNum(std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > const&, bool, unsigned long) in libbitcoinconsensus_la-interpreter.o
      CScript::GetSigOpCount(bool) const in libbitcoinconsensus_la-script.o
      CScript::GetSigOpCount(CScript const&) const in libbitcoinconsensus_la-script.o
      CScript::IsPushOnly(prevector<28u, unsigned char, unsigned int, int>::const_iterator) const in libbitcoinconsensus_la-script.o
      CScript::IsPushOnly() const in libbitcoinconsensus_la-script.o
      CScript::HasValidOps() const in libbitcoinconsensus_la-script.o
      GetScriptOp(prevector<28u, unsigned char, unsigned int, int>::const_iterator&, prevector<28u, unsigned char, unsigned int, int>::const_iterator, opcodetype&, std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >*) in libbitcoinconsensus_la-script.o
      ...
  "___tsan_vptr_read", referenced from:
      std::__1::basic_stringbuf<char, std::__1::char_traits<char>, std::__1::allocator<char> >::seekpos(std::__1::fpos<__mbstate_t>, unsigned int) in libbitcoinconsensus_la-block.o
      std::__1::basic_stringbuf<char, std::__1::char_traits<char>, std::__1::allocator<char> >::overflow(int) in libbitcoinconsensus_la-block.o
      std::__1::basic_ostream<char, std::__1::char_traits<char> >& std::__1::__put_character_sequence<char, std::__1::char_traits<char> >(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, char const*, unsigned long) in libbitcoinconsensus_la-block.o
      std::__1::ostreambuf_iterator<char, std::__1::char_traits<char> > std::__1::__pad_and_output<char, std::__1::char_traits<char> >(std::__1::ostreambuf_iterator<char, std::__1::char_traits<char> >, char const*, char const*, char const*, std::__1::ios_base&, char) in libbitcoinconsensus_la-block.o
      tinyformat::detail::formatImpl(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, char const*, tinyformat::detail::FormatArg const*, int) in libbitcoinconsensus_la-block.o
      tinyformat::detail::streamStateFromFormat(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, bool&, int&, char const*, tinyformat::detail::FormatArg const*, int&, int) in libbitcoinconsensus_la-block.o
      std::__1::basic_stringbuf<char, std::__1::char_traits<char>, std::__1::allocator<char> >::overflow(int) in libbitcoinconsensus_la-transaction.o
      ...
  "___tsan_vptr_update", referenced from:
      base_uint<256u>::operator/=(base_uint<256u> const&) in libbitcoinconsensus_la-arith_uint256.o
      void std::__1::vector<uint256, std::__1::allocator<uint256> >::__push_back_slow_path<uint256 const&>(uint256 const&&&) in libbitcoinconsensus_la-merkle.o
      std::__1::vector<uint256, std::__1::allocator<uint256> >::__append(unsigned long) in libbitcoinconsensus_la-merkle.o
      std::__1::basic_stringstream<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_stringstream() in libbitcoinconsensus_la-block.o
      non-virtual thunk to std::__1::basic_stringstream<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_stringstream() in libbitcoinconsensus_la-block.o
      virtual thunk to std::__1::basic_stringstream<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_stringstream() in libbitcoinconsensus_la-block.o
      std::__1::basic_stringstream<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_stringstream() in libbitcoinconsensus_la-block.o
      ...
  "___tsan_unaligned_read8", referenced from:
      (anonymous namespace)::sha512::Transform(unsigned long long*, unsigned char const*) in libbitcoinconsensus_la-sha512.o
      CTxIn::CTxIn(COutPoint, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxIn::CTxIn(uint256, unsigned int, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxIn::ToString() const in libbitcoinconsensus_la-transaction.o
      CTxOut::CTxOut(long long const&, CScript) in libbitcoinconsensus_la-transaction.o
      CTxOut::CTxOut(long long const&, CScript) in libbitcoinconsensus_la-transaction.o
      CTxOut::ToString() const in libbitcoinconsensus_la-transaction.o
      ...
  "___tsan_atomic8_load", referenced from:
      EvalScript(std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >&, CScript const&, unsigned int, BaseSignatureChecker const&, SigVersion, ScriptError_t*) in libbitcoinconsensus_la-interpreter.o
      uint256 SignatureHash<CTransaction>(CScript const&, CTransaction const&, unsigned int, int, long long const&, SigVersion, PrecomputedTransactionData const*) in libbitcoinconsensus_la-interpreter.o
      uint256 SignatureHash<CMutableTransaction>(CScript const&, CMutableTransaction const&, unsigned int, int, long long const&, SigVersion, PrecomputedTransactionData const*) in libbitcoinconsensus_la-interpreter.o
      VerifyScript(CScript const&, CScript const&, CScriptWitness const*, unsigned int, BaseSignatureChecker const&, ScriptError_t*) in libbitcoinconsensus_la-interpreter.o
      CountWitnessSigOps(CScript const&, CScript const&, CScriptWitness const*, unsigned int) in libbitcoinconsensus_la-interpreter.o
  "___tsan_read8", referenced from:
      CRIPEMD160::Write(unsigned char const*, unsigned long) in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Finalize(unsigned char*) in libbitcoinconsensus_la-ripemd160.o
      CSHA1::Write(unsigned char const*, unsigned long) in libbitcoinconsensus_la-sha1.o
      CSHA1::Finalize(unsigned char*) in libbitcoinconsensus_la-sha1.o
      SHA256AutoDetect() in libbitcoinconsensus_la-sha256.o
      CSHA256::Write(unsigned char const*, unsigned long) in libbitcoinconsensus_la-sha256.o
      CSHA256::Finalize(unsigned char*) in libbitcoinconsensus_la-sha256.o
      ...
  "___tsan_unaligned_read4", referenced from:
      ChaCha20::SetKey(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      (anonymous namespace)::ripemd160::Transform(unsigned int*, unsigned char const*) in libbitcoinconsensus_la-ripemd160.o
      (anonymous namespace)::sha1::Transform(unsigned int*, unsigned char const*) in libbitcoinconsensus_la-sha1.o
      (anonymous namespace)::sha256::Transform(unsigned int*, unsigned char const*, unsigned long) in libbitcoinconsensus_la-sha256.o
      (anonymous namespace)::sha256::TransformD64(unsigned char*, unsigned char const*) in libbitcoinconsensus_la-sha256.o
      ...
  "___tsan_write16", referenced from:
      AES256CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES128CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      CSHA512::CSHA512() in libbitcoinconsensus_la-sha512.o
      CSHA512::CSHA512() in libbitcoinconsensus_la-sha512.o
      CSHA512::Reset() in libbitcoinconsensus_la-sha512.o
      CTransaction::CTransaction(CMutableTransaction&&) in libbitcoinconsensus_la-transaction.o
      std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >::__append(unsigned long) in libbitcoinconsensus_la-bitcoinconsensus.o
      ...
  "___tsan_unaligned_write8", referenced from:
      SHA256AutoDetect() in libbitcoinconsensus_la-sha256.o
      CSHA512::Finalize(unsigned char*) in libbitcoinconsensus_la-sha512.o
      CTxIn::CTxIn(COutPoint, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxIn::CTxIn(uint256, unsigned int, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxOut::CTxOut(long long const&, CScript) in libbitcoinconsensus_la-transaction.o
      CTxOut::CTxOut(long long const&, CScript) in libbitcoinconsensus_la-transaction.o
      CTransaction::CTransaction(CMutableTransaction const&) in libbitcoinconsensus_la-transaction.o
      ...
  "___tsan_read1", referenced from:
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      AES_encrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      AES_decrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      AES256CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES256CBCDecrypt::Decrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES128CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES128CBCDecrypt::Decrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      ...
  "___tsan_unaligned_write4", referenced from:
      ChaCha20::Output(unsigned char*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      CRIPEMD160::Finalize(unsigned char*) in libbitcoinconsensus_la-ripemd160.o
      CSHA1::Finalize(unsigned char*) in libbitcoinconsensus_la-sha1.o
      CSHA256::Finalize(unsigned char*) in libbitcoinconsensus_la-sha256.o
      CTxIn::CTxIn(COutPoint, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxIn::CTxIn(uint256, unsigned int, CScript, unsigned int) in libbitcoinconsensus_la-transaction.o
      CTxOut::CTxOut(long long const&, CScript) in libbitcoinconsensus_la-transaction.o
      ...
  "___tsan_write1", referenced from:
      AES256CBCEncrypt::AES256CBCEncrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      AES256CBCEncrypt::AES256CBCEncrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      AES256CBCDecrypt::AES256CBCDecrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      AES256CBCDecrypt::AES256CBCDecrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      AES256CBCDecrypt::Decrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES128CBCEncrypt::AES128CBCEncrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      AES128CBCEncrypt::AES128CBCEncrypt(unsigned char const*, unsigned char const*, bool) in libbitcoinconsensus_la-aes.o
      ...
  "___tsan_read2", referenced from:
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      AES_decrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      SubBytes(AES_state*, int) in libbitcoinconsensus_la-aes.o
      MixColumns(AES_state*, int) in libbitcoinconsensus_la-aes.o
      SaveBytes(unsigned char*, AES_state const*) in libbitcoinconsensus_la-aes.o
      unsigned long long ReadCompactSize<(anonymous namespace)::TxInputStream>((anonymous namespace)::TxInputStream&) in libbitcoinconsensus_la-bitcoinconsensus.o
  "___tsan_write2", referenced from:
      SubBytes(AES_state*, int) in libbitcoinconsensus_la-aes.o
      MixColumns(AES_state*, int) in libbitcoinconsensus_la-aes.o
      void WriteCompactSize<CHashWriter>(CHashWriter&, unsigned long long) in libbitcoinconsensus_la-transaction.o
      void WriteCompactSize<CHashWriter>(CHashWriter&, unsigned long long) in libbitcoinconsensus_la-interpreter.o
  "___tsan_write8", referenced from:
      CRIPEMD160::CRIPEMD160() in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::CRIPEMD160() in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Write(unsigned char const*, unsigned long) in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Finalize(unsigned char*) in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Reset() in libbitcoinconsensus_la-ripemd160.o
      CSHA1::CSHA1() in libbitcoinconsensus_la-sha1.o
      CSHA1::CSHA1() in libbitcoinconsensus_la-sha1.o
      ...
  "___tsan_read4", referenced from:
      ChaCha20::SetKey(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::Output(unsigned char*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      (anonymous namespace)::ripemd160::Transform(unsigned int*, unsigned char const*) in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Finalize(unsigned char*) in libbitcoinconsensus_la-ripemd160.o
      (anonymous namespace)::sha1::Transform(unsigned int*, unsigned char const*) in libbitcoinconsensus_la-sha1.o
      ...
  "___tsan_unaligned_read16", referenced from:
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      AES_encrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      AES_decrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      AES256CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      AES128CBCEncrypt::Encrypt(unsigned char const*, int, unsigned char*) const in libbitcoinconsensus_la-aes.o
      ChaCha20::Output(unsigned char*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      (anonymous namespace)::sha1::Transform(unsigned int*, unsigned char const*) in libbitcoinconsensus_la-sha1.o
      ...
  "___tsan_unaligned_write16", referenced from:
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      ChaCha20::Output(unsigned char*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      CRIPEMD160::CRIPEMD160() in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::CRIPEMD160() in libbitcoinconsensus_la-ripemd160.o
      CRIPEMD160::Reset() in libbitcoinconsensus_la-ripemd160.o
      CSHA1::CSHA1() in libbitcoinconsensus_la-sha1.o
      CSHA1::CSHA1() in libbitcoinconsensus_la-sha1.o
      ...
  "___tsan_write4", referenced from:
      ChaCha20::SetKey(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::ChaCha20(unsigned char const*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::SetIV(unsigned long long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::Seek(unsigned long long) in libbitcoinconsensus_la-chacha20.o
      ChaCha20::Output(unsigned char*, unsigned long) in libbitcoinconsensus_la-chacha20.o
      CRIPEMD160::CRIPEMD160() in libbitcoinconsensus_la-ripemd160.o
      ...
  "___tsan_read16", referenced from:
      CTransaction::CTransaction(CMutableTransaction&&) in libbitcoinconsensus_la-transaction.o
      std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >::__append(unsigned long) in libbitcoinconsensus_la-bitcoinconsensus.o
      EvalScript(std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >&, CScript const&, unsigned int, BaseSignatureChecker const&, SigVersion, ScriptError_t*) in libbitcoinconsensus_la-interpreter.o
      std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >::insert(std::__1::__wrap_iter<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > const*>, std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > const&) in libbitcoinconsensus_la-interpreter.o
      void std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >::__push_back_slow_path<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > const&>(std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > const&&&) in libbitcoinconsensus_la-interpreter.o
      void std::__1::vector<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >, std::__1::allocator<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > > >::__push_back_slow_path<std::__1::vector<unsigned char, std::__1::allocator<unsigned char> > >(std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >&&) in libbitcoinconsensus_la-interpreter.o
      std::__1::vector<bool, std::__1::allocator<bool> >::reserve(unsigned long) in libbitcoinconsensus_la-interpreter.o
      ...
  "___tsan_func_entry", referenced from:
      _AES128_init in libbitcoinconsensus_la-aes.o
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      _AES128_encrypt in libbitcoinconsensus_la-aes.o
      AES_encrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      _AES128_decrypt in libbitcoinconsensus_la-aes.o
      AES_decrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      _AES192_init in libbitcoinconsensus_la-aes.o
      ...
  "___tsan_init", referenced from:
      _tsan.module_ctor in libbitcoinconsensus_la-aes.o
      _tsan.module_ctor in libbitcoinconsensus_la-chacha20.o
      _tsan.module_ctor in libbitcoinconsensus_la-hmac_sha256.o
      _tsan.module_ctor in libbitcoinconsensus_la-hmac_sha512.o
      _tsan.module_ctor in libbitcoinconsensus_la-ripemd160.o
      _tsan.module_ctor in libbitcoinconsensus_la-sha1.o
      _tsan.module_ctor in libbitcoinconsensus_la-sha256.o
      ...
  "___tsan_func_exit", referenced from:
      _AES128_init in libbitcoinconsensus_la-aes.o
      AES_setup(AES_state*, unsigned char const*, int, int) in libbitcoinconsensus_la-aes.o
      _AES128_encrypt in libbitcoinconsensus_la-aes.o
      AES_encrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      _AES128_decrypt in libbitcoinconsensus_la-aes.o
      AES_decrypt(AES_state const*, int, unsigned char*, unsigned char const*) in libbitcoinconsensus_la-aes.o
      _AES192_init in libbitcoinconsensus_la-aes.o
      ...
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [libbitcoinconsensus.la] Error 1
make[1]: *** [all-recursive] Error 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment