Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sanitizer errors #34

Open
jwinarske opened this issue Oct 11, 2022 · 6 comments
Open

Sanitizer errors #34

jwinarske opened this issue Oct 11, 2022 · 6 comments

Comments

@jwinarske
Copy link

RUSTFLAGS="-Z sanitizer=memory" cargo bench --bench uuid --features uuid --target x86_64-unknown-linux-gnu

Generates

==645733==WARNING: MemorySanitizer: use-of-uninitialized-value
    #0 0x561346a35b2d in std::sys_common::once::futex::Once::call::ha1b7ce84c30f3f69 (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0x2cb2d) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #1 0x561346b8dc8b in _$LT$criterion..Criterion$u20$as$u20$core..default..Default$GT$::default::h496c49941cd756f4 (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0x184c8b) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #2 0x561346ada341 in uuid::main::hd193fa060419cf1a (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0xd1341) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #3 0x561346aed462 in std::sys_common::backtrace::__rust_begin_short_backtrace::h5647b6428466359c (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0xe4462) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #4 0x561346b2650b in std::rt::lang_start::_$u7b$$u7b$closure$u7d$$u7d$::h5d19866072bdbf27 (.llvm.14944981500331809237) (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0x11d50b) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #5 0x561346f3f6ea in core::ops::function::impls::_$LT$impl$u20$core..ops..function..FnOnce$LT$A$GT$$u20$for$u20$$RF$F$GT$::call_once::hcf0f452e35b42714 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:286:13
    #6 0x561346f3f6ea in std::panicking::try::do_call::h9076463b86fc98c2 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40
    #7 0x561346f3f6ea in std::panicking::try::h59a38c38fab81132 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19
    #8 0x561346f3f6ea in std::panic::catch_unwind::h024c7f29e5fae637 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14
    #9 0x561346f3f6ea in std::rt::lang_start_internal::_$u7b$$u7b$closure$u7d$$u7d$::h1bc9c4aefbf9b583 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:48
    #10 0x561346f3f6ea in std::panicking::try::do_call::hf630db2c23823f3c /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40
    #11 0x561346f3f6ea in std::panicking::try::h5c6c892f05382366 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19
    #12 0x561346f3f6ea in std::panic::catch_unwind::h893ebad4c00d9e60 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14
    #13 0x561346f3f6ea in std::rt::lang_start_internal::h2fa3ed5bcd048bb3 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:20
    #14 0x561346adadf7 in main (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0xd1df7) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)
    #15 0x7f3cd0fcfb74 in __libc_start_main (/lib64/libc.so.6+0x27b74) (BuildId: 08df60634339b221bb854d4e10b7278cafde70c4)
    #16 0x561346a5cbdd in _start (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0x53bdd) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b)

SUMMARY: MemorySanitizer: use-of-uninitialized-value (/b/allo-isolate/target/x86_64-unknown-linux-gnu/release/deps/uuid-057c435e97cecd96+0x2cb2d) (BuildId: 8f7ad90da4aa620babb32b2e687b840b40299b6b) in std::sys_common::once::futex::Once::call::ha1b7ce84c30f3f69
Exiting
gnuRUSTFLAGS="-Z sanitizer=memory" cargo test --target x86_64-unknown-linux-gnu

Generates

     Running unittests src/lib.rs (target/x86_64-unknown-linux-gnu/debug/deps/allo_isolate-e78f1fbba8eee840)
Uninitialized bytes in MemcmpInterceptorCommon at offset 0 inside [0x708000000081, 3)
==650316==WARNING: MemorySanitizer: use-of-uninitialized-value
    #0 0x557aff1fb68d in bcmp /rustc/llvm/src/llvm-project/compiler-rt/lib/msan/../sanitizer_common/sanitizer_common_interceptors.inc:978:10
    #1 0x557aff2b1ca0 in _$LT$std..path..Component$u20$as$u20$core..cmp..PartialEq$GT$::eq::hca69560419389308 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/path.rs
    #2 0x557aff2ad6c7 in core::cmp::impls::_$LT$impl$u20$core..cmp..PartialEq$LT$$RF$B$GT$$u20$for$u20$$RF$A$GT$::eq::h85b3b6b1f9b934b5 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/path.rs:292:43
    #3 0x557aff2ad6c7 in std::path::iter_after::h9743549dd819bdf2 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/path.rs:292:43
    #4 0x557aff2ad6c7 in std::path::Path::_starts_with::h1e354f9bbbd5797a /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/path.rs:2307:9
    #5 0x557aff2a6fb7 in std::path::Path::starts_with::h15703652269aa2f9 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/path.rs:2303:9
    #6 0x557aff2a6fb7 in std::sys::unix::thread::cgroups::quota_v2::he02b771439b16a7b /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys/unix/thread.rs:481:19
    #7 0x557aff2a6fb7 in std::sys::unix::thread::cgroups::quota::h3f141d9dbf7bcfda /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys/unix/thread.rs:452:31
    #8 0x557aff2a6fb7 in std::sys::unix::thread::available_parallelism::h194b1eac50ae29db /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys/unix/thread.rs:294:29
    #9 0x557aff2a6fb7 in std::thread::available_parallelism::h2eebd5ecaf5da702 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/thread/mod.rs:1655:5
    #10 0x557aff271fa3 in test::helpers::concurrency::get_concurrency::h87ad303fc8483364 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/test/src/helpers/concurrency.rs:12:9
    #11 0x557aff2683f4 in core::ops::function::FnOnce::call_once::hbde7220a563542ac /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:251:5
    #12 0x557aff2683f4 in core::option::Option$LT$T$GT$::unwrap_or_else::hb273e30f102261ab /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/test/src/console.rs:269:28
    #13 0x557aff2683f4 in test::console::run_tests_console::h9a3d180b51e649a8 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/test/src/console.rs:269:28
    #14 0x557aff27d68c in test::test_main::h65a820c41c08cb2f /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/test/src/lib.rs:114:15
    #15 0x557aff27e653 in test::test_main_static::he901575514289151 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/test/src/lib.rs:133:5
    #16 0x557aff2521a1 in allo_isolate::main::h60aeada2def2916a /b/allo-isolate/src/lib.rs:1:1
    #17 0x557aff2527ec in core::ops::function::FnOnce::call_once::h7f928e1e99b1730d /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:251:5
    #18 0x557aff252372 in std::sys_common::backtrace::__rust_begin_short_backtrace::h2ed475e7e98b249d /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys_common/backtrace.rs:122:18
    #19 0x557aff2525c1 in std::rt::lang_start::_$u7b$$u7b$closure$u7d$$u7d$::hfc48b97e61d99b42 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:166:18
    #20 0x557aff2a53da in core::ops::function::impls::_$LT$impl$u20$core..ops..function..FnOnce$LT$A$GT$$u20$for$u20$$RF$F$GT$::call_once::hcf0f452e35b42714 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:286:13
    #21 0x557aff2a53da in std::panicking::try::do_call::h9076463b86fc98c2 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40
    #22 0x557aff2a53da in std::panicking::try::h59a38c38fab81132 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19
    #23 0x557aff2a53da in std::panic::catch_unwind::h024c7f29e5fae637 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14
    #24 0x557aff2a53da in std::rt::lang_start_internal::_$u7b$$u7b$closure$u7d$$u7d$::h1bc9c4aefbf9b583 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:48
    #25 0x557aff2a53da in std::panicking::try::do_call::hf630db2c23823f3c /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40
    #26 0x557aff2a53da in std::panicking::try::h5c6c892f05382366 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19
    #27 0x557aff2a53da in std::panic::catch_unwind::h893ebad4c00d9e60 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14
    #28 0x557aff2a53da in std::rt::lang_start_internal::h2fa3ed5bcd048bb3 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:20
    #29 0x557aff252495 in std::rt::lang_start::h2717c68b38bf1baa /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:165:17
    #30 0x557aff252209 in main (/b/allo-isolate/target/x86_64-unknown-linux-gnu/debug/deps/allo_isolate-e78f1fbba8eee840+0x81209) (BuildId: 8278091c6966f0ea2a3174ad8efd3574c1f327a9)
    #31 0x7f74a3936b74 in __libc_start_main (/lib64/libc.so.6+0x27b74) (BuildId: 08df60634339b221bb854d4e10b7278cafde70c4)
    #32 0x557aff1ec73d in _start (/b/allo-isolate/target/x86_64-unknown-linux-gnu/debug/deps/allo_isolate-e78f1fbba8eee840+0x1b73d) (BuildId: 8278091c6966f0ea2a3174ad8efd3574c1f327a9)

SUMMARY: MemorySanitizer: use-of-uninitialized-value /rustc/llvm/src/llvm-project/compiler-rt/lib/msan/../sanitizer_common/sanitizer_common_interceptors.inc:978:10 in bcmp
Exiting
@jwinarske jwinarske changed the title Memory Sanitizer errors Sanitizer errors Oct 11, 2022
@jwinarske
Copy link
Author

jwinarske commented Oct 11, 2022

RUSTFLAGS="-Z sanitizer=thread" cargo test --target x86_64-unknown-linux-gnu

Generates

running 1 test
==================
WARNING: ThreadSanitizer: data race (pid=656544)
  Read of size 8 at 0x7b440000ff48 by main thread:
    #0 memcpy /rustc/llvm/src/llvm-project/compiler-rt/lib/tsan/rtl/../../sanitizer_common/sanitizer_common_interceptors.inc:899:5 (containers-95dfae78259d34e8+0x2bbce) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #1 core::mem::maybe_uninit::MaybeUninit$LT$T$GT$::assume_init::h7baa46083098b9c1 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/mem/mod.rs:918:22 (containers-95dfae78259d34e8+0xfb814) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #2 core::ptr::read::ha43e8013e7942876 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ptr/mod.rs:1119:9 (containers-95dfae78259d34e8+0xfb814)
    #3 core::mem::replace::h262549728b00dc7e /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/mem/mod.rs:918:22 (containers-95dfae78259d34e8+0xfb814)
    #4 core::option::Option$LT$T$GT$::take::hac5d89d859cc5556 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:96:27 (containers-95dfae78259d34e8+0xfb814)
    #5 std::sync::mpsc::mpsc_queue::Queue$LT$T$GT$::pop::hc87cfb6facd10966 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:96:27 (containers-95dfae78259d34e8+0xfb814)
    #6 core::ops::function::FnOnce::call_once::h0850fbae2694fbcc /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:251:5 (containers-95dfae78259d34e8+0xf0a8e) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #7 std::sys_common::backtrace::__rust_begin_short_backtrace::h79c71d051db4cf07 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys_common/backtrace.rs:122:18 (containers-95dfae78259d34e8+0xf46d1) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #8 std::rt::lang_start::_$u7b$$u7b$closure$u7d$$u7d$::h1311a497100d83e7 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:166:18 (containers-95dfae78259d34e8+0xe85be) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #9 core::ops::function::impls::_$LT$impl$u20$core..ops..function..FnOnce$LT$A$GT$$u20$for$u20$$RF$F$GT$::call_once::hcf0f452e35b42714 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:286:13 (containers-95dfae78259d34e8+0x15dc0a) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #10 std::panicking::try::do_call::h9076463b86fc98c2 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40 (containers-95dfae78259d34e8+0x15dc0a)
    #11 std::panicking::try::h59a38c38fab81132 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19 (containers-95dfae78259d34e8+0x15dc0a)
    #12 std::panic::catch_unwind::h024c7f29e5fae637 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14 (containers-95dfae78259d34e8+0x15dc0a)
    #13 std::rt::lang_start_internal::_$u7b$$u7b$closure$u7d$$u7d$::h1bc9c4aefbf9b583 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:48 (containers-95dfae78259d34e8+0x15dc0a)
    #14 std::panicking::try::do_call::hf630db2c23823f3c /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40 (containers-95dfae78259d34e8+0x15dc0a)
    #15 std::panicking::try::h5c6c892f05382366 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19 (containers-95dfae78259d34e8+0x15dc0a)
    #16 std::panic::catch_unwind::h893ebad4c00d9e60 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14 (containers-95dfae78259d34e8+0x15dc0a)
    #17 std::rt::lang_start_internal::h2fa3ed5bcd048bb3 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:20 (containers-95dfae78259d34e8+0x15dc0a)
    #18 main <null> (containers-95dfae78259d34e8+0xadc2c) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)

  Previous write of size 8 at 0x7b440000ff48 by thread T1:
    #0 memcpy /rustc/llvm/src/llvm-project/compiler-rt/lib/tsan/rtl/../../sanitizer_common/sanitizer_common_interceptors.inc:899:5 (containers-95dfae78259d34e8+0x2bbce) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #1 std::sync::mpsc::mpsc_queue::Node$LT$T$GT$::new::h794c6c797f182eb0 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:56:80 (containers-95dfae78259d34e8+0xfbdaa) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #2 std::sync::mpsc::mpsc_queue::Queue$LT$T$GT$::push::h9b783077498e467d /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:71:21 (containers-95dfae78259d34e8+0xfbdaa)
    #3 std::sync::mpsc::shared::Packet$LT$T$GT$::send::h83d999d53debc6e7 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/shared.rs:167:9 (containers-95dfae78259d34e8+0xfbdaa)
    #4 std::sync::mpsc::Sender$LT$T$GT$::send::h908fe1b76313dabc /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mod.rs:830:45 (containers-95dfae78259d34e8+0xfbdaa)

  Location is heap block of size 264 at 0x7b440000ff00 allocated by thread T1:
    #0 malloc /rustc/llvm/src/llvm-project/compiler-rt/lib/tsan/rtl/tsan_interceptors_posix.cpp:667:5 (containers-95dfae78259d34e8+0x206b1) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #1 alloc::alloc::alloc::h078c1608a61bbb7e /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/alloc/src/alloc.rs:177:73 (containers-95dfae78259d34e8+0xfbd5c) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #2 alloc::alloc::Global::alloc_impl::h2da59902eb29a0d4 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/alloc/src/alloc.rs:177:73 (containers-95dfae78259d34e8+0xfbd5c)
    #3 _$LT$alloc..alloc..Global$u20$as$u20$core..alloc..Allocator$GT$::allocate::h8982b6cfb9978320 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/alloc/src/alloc.rs:326:11 (containers-95dfae78259d34e8+0xfbd5c)
    #4 alloc::alloc::exchange_malloc::h422ed970359c9d8a /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/alloc/src/alloc.rs:326:11 (containers-95dfae78259d34e8+0xfbd5c)
    #5 std::sync::mpsc::mpsc_queue::Node$LT$T$GT$::new::h794c6c797f182eb0 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:56:23 (containers-95dfae78259d34e8+0xfbd5c)
    #6 std::sync::mpsc::mpsc_queue::Queue$LT$T$GT$::push::h9b783077498e467d /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mpsc_queue.rs:71:21 (containers-95dfae78259d34e8+0xfbd5c)
    #7 std::sync::mpsc::shared::Packet$LT$T$GT$::send::h83d999d53debc6e7 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/shared.rs:167:9 (containers-95dfae78259d34e8+0xfbd5c)
    #8 std::sync::mpsc::Sender$LT$T$GT$::send::h908fe1b76313dabc /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sync/mpsc/mod.rs:830:45 (containers-95dfae78259d34e8+0xfbd5c)

  Thread T1 'tests::can_run_valgrind_main' (tid=656547, finished) created by main thread at:
    #0 pthread_create /rustc/llvm/src/llvm-project/compiler-rt/lib/tsan/rtl/tsan_interceptors_posix.cpp:1022:3 (containers-95dfae78259d34e8+0x21a7d) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #1 std::sys::unix::thread::Thread::new::h045c7dac122bb76d /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys/unix/thread.rs:87:19 (containers-95dfae78259d34e8+0x16d920) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #2 core::ops::function::FnOnce::call_once::h0850fbae2694fbcc /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:251:5 (containers-95dfae78259d34e8+0xf0a8e) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #3 std::sys_common::backtrace::__rust_begin_short_backtrace::h79c71d051db4cf07 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/sys_common/backtrace.rs:122:18 (containers-95dfae78259d34e8+0xf46d1) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #4 std::rt::lang_start::_$u7b$$u7b$closure$u7d$$u7d$::h1311a497100d83e7 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:166:18 (containers-95dfae78259d34e8+0xe85be) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #5 core::ops::function::impls::_$LT$impl$u20$core..ops..function..FnOnce$LT$A$GT$$u20$for$u20$$RF$F$GT$::call_once::hcf0f452e35b42714 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/ops/function.rs:286:13 (containers-95dfae78259d34e8+0x15dc0a) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)
    #6 std::panicking::try::do_call::h9076463b86fc98c2 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40 (containers-95dfae78259d34e8+0x15dc0a)
    #7 std::panicking::try::h59a38c38fab81132 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19 (containers-95dfae78259d34e8+0x15dc0a)
    #8 std::panic::catch_unwind::h024c7f29e5fae637 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14 (containers-95dfae78259d34e8+0x15dc0a)
    #9 std::rt::lang_start_internal::_$u7b$$u7b$closure$u7d$$u7d$::h1bc9c4aefbf9b583 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:48 (containers-95dfae78259d34e8+0x15dc0a)
    #10 std::panicking::try::do_call::hf630db2c23823f3c /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:464:40 (containers-95dfae78259d34e8+0x15dc0a)
    #11 std::panicking::try::h5c6c892f05382366 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panicking.rs:428:19 (containers-95dfae78259d34e8+0x15dc0a)
    #12 std::panic::catch_unwind::h893ebad4c00d9e60 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/panic.rs:137:14 (containers-95dfae78259d34e8+0x15dc0a)
    #13 std::rt::lang_start_internal::h2fa3ed5bcd048bb3 /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/std/src/rt.rs:148:20 (containers-95dfae78259d34e8+0x15dc0a)
    #14 main <null> (containers-95dfae78259d34e8+0xadc2c) (BuildId: 6990138284dae2b99720eab3ad5e608927e4a2e1)

SUMMARY: ThreadSanitizer: data race /rustc/8796e7a9cfd4c5c4f1de15ec1c53994ddf288665/library/core/src/mem/mod.rs:918:22 in core::mem::maybe_uninit::MaybeUninit$LT$T$GT$::assume_init::h7baa46083098b9c1
==================
test tests::can_run_valgrind_main ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.07s

ThreadSanitizer: reported 1 warnings

@shekohex
Copy link
Owner

shekohex commented Oct 12, 2022

Any idea @fzyzcjy about sanitizers here? also @jwinarske please note that our test dart VM is not actual VM we just mimic the behaviour of the actual VM. Nonetheless, looks like most of these errors are from running that test here https://github.com/sunshine-protocol/allo-isolate/blob/master/tests/containers.rs#L243-L245 and not sure where we spawn new threads or using channels?

@jwinarske
Copy link
Author

I think an improvement would be to use Dart SDK for the tests. It's a matter of fetching the stable flutter SDK and adding it to the path. I'll look into a PR for this next week.

@fzyzcjy
Copy link
Contributor

fzyzcjy commented Oct 12, 2022

Not sure, maybe we should create a minimal reproducible sample, probably without allo-isolate and with only a few lines of Rust code, first?

@shekohex
Copy link
Owner

shekohex commented Nov 2, 2022

Hello @jwinarske, did you find any new updates on that?

@jwinarske
Copy link
Author

@shekohex I'm busy with something else right now. I'll get back to it at some point in the near future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants