Skip to content

Commit

Permalink
[DOC] Update the sanitizer documentation
Browse files Browse the repository at this point in the history
Summary:
Passing the suppressions manually is no longer needed when using the
`check-*` targets (since D5689). Update the documentation to reflect
this.

Test Plan: Read the doc and try the examples.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D5760
  • Loading branch information
Fabcien authored and ftrader committed Nov 27, 2020
1 parent 5f5c916 commit b7e0828
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions doc/developer-notes.md
Expand Up @@ -295,7 +295,10 @@ build configuration.

There are a number of known problems for which suppressions files are provided
under `test/sanitizer_suppressions`. These files are intended to be used with
the `suppressions` option from the sanitizers.
the `suppressions` option from the sanitizers. If you are using the `check-*`
targets to run the tests, the suppression options are automatically set.
Otherwise they need to be set manually using environment variables; refer to
your compiler manual for the correct syntax.

The address sanitizer is known to fail in
[sha256_sse4::Transform](/src/crypto/sha256_sse4.cpp) which makes it unusable
Expand All @@ -317,9 +320,6 @@ Build and run the test suite with the address sanitizer enabled:
mkdir build_asan
cd build_asan

export ASAN_OPTIONS="malloc_context_size=0"
export LSAN_OPTIONS="suppressions=${PWD}/../test/sanitizer_suppressions/lsan"

cmake -GNinja .. \
-DCMAKE_BUILD_TYPE=Debug \
-DENABLE_SANITIZERS=address \
Expand All @@ -335,8 +335,6 @@ very long time to complete):
mkdir build_tsan
cd build_tsan

export TSAN_OPTIONS="suppressions=${PWD}/../test/sanitizer_suppressions/tsan"

cmake -GNinja .. \
-DCMAKE_BUILD_TYPE=Debug \
-DENABLE_SANITIZERS=thread
Expand All @@ -350,8 +348,6 @@ Build and run the test suite with the undefined sanitizer enabled:
mkdir build_ubsan
cd build_ubsan

export UBSAN_OPTIONS="suppressions=${PWD}/../test/sanitizer_suppressions/ubsan"

cmake -GNinja .. \
-DCMAKE_BUILD_TYPE=Debug \
-DENABLE_SANITIZERS=undefined
Expand Down

0 comments on commit b7e0828

Please sign in to comment.