-
Notifications
You must be signed in to change notification settings - Fork 468
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
106 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,19 @@ | ||
#!/bin/bash | ||
|
||
cd "$(dirname "$0")"/../crossbeam-deque | ||
set -ex | ||
|
||
script_dir="$(cd "$(dirname "$0")" && pwd)" | ||
cd "$script_dir"/../crossbeam-deque | ||
|
||
export RUSTFLAGS="-D warnings" | ||
|
||
cargo check --bins --examples --tests | ||
cargo test | ||
|
||
if [[ "$RUST_VERSION" == "nightly"* ]]; then | ||
RUSTDOCFLAGS=-Dwarnings cargo doc --no-deps --all-features | ||
|
||
# Run sanitizers | ||
export TSAN_OPTIONS="suppressions=$script_dir/tsan" | ||
"$script_dir"/san.sh | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,18 @@ | ||
#!/bin/bash | ||
|
||
cd "$(dirname "$0")"/../crossbeam-queue | ||
set -ex | ||
|
||
script_dir="$(cd "$(dirname "$0")" && pwd)" | ||
cd "$script_dir"/../crossbeam-queue | ||
|
||
export RUSTFLAGS="-D warnings" | ||
|
||
cargo check --bins --examples --tests | ||
cargo test | ||
|
||
if [[ "$RUST_VERSION" == "nightly"* ]]; then | ||
RUSTDOCFLAGS=-Dwarnings cargo doc --no-deps --all-features | ||
|
||
# Run sanitizers | ||
"$script_dir"/san.sh --features nightly | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
#!/bin/bash | ||
|
||
set -ex | ||
|
||
if [[ "$OSTYPE" != "linux"* ]]; then | ||
exit 0 | ||
fi | ||
|
||
rustup component add rust-src | ||
|
||
# Run address sanitizer | ||
cargo clean | ||
RUSTFLAGS="-Z sanitizer=address" \ | ||
cargo test --release --target x86_64-unknown-linux-gnu --tests "$@" | ||
|
||
# Run leak sanitizer (when memory leak detection is enabled) | ||
if [[ "$ASAN_OPTIONS" != *"detect_leaks=0"* ]]; then | ||
cargo clean | ||
RUSTFLAGS="-Z sanitizer=leak" \ | ||
cargo test --release --target x86_64-unknown-linux-gnu --tests "$@" | ||
fi | ||
|
||
# Run memory sanitizer | ||
cargo clean | ||
RUSTFLAGS="-Z sanitizer=memory" \ | ||
cargo test -Zbuild-std --release --target x86_64-unknown-linux-gnu --tests "$@" | ||
|
||
# Run thread sanitizer | ||
cargo clean | ||
RUSTFLAGS="-Z sanitizer=thread" \ | ||
cargo test -Zbuild-std --release --target x86_64-unknown-linux-gnu --tests "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# TSAN suppressions file for crossbeam | ||
|
||
# The epoch-based GC uses fences. | ||
race:crossbeam_epoch | ||
|
||
# Push and steal operations in crossbeam-deque may cause data races, but such | ||
# data races are safe. If a data race happens, the value read by `steal` is | ||
# forgotten and the steal operation is then retried. | ||
race:crossbeam_deque*push | ||
race:crossbeam_deque*steal | ||
|
||
# AtomicCell::compare_exchange uses fences if it is not lock-free. | ||
race:crossbeam_utils::atomic::atomic_cell::AtomicCell<T>::compare_exchange |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters