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

Valgrind finds problems in tests in release mode #45

Open
purpleposeidon opened this issue Jul 19, 2018 · 0 comments
Open

Valgrind finds problems in tests in release mode #45

purpleposeidon opened this issue Jul 19, 2018 · 0 comments

Comments

@purpleposeidon
Copy link

$ valgrind target/release/deps/test-7db46c3c67811ea2 --test-threads 1 
==30187== Memcheck, a memory error detector
==30187== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==30187== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
==30187== Command: target/release/deps/test-7db46c3c67811ea2 --test-threads 1
==30187== 

running 11 tests
test issue_14 ... ok
test issue_16 ... ok
test issue_17 ... ok
test issue_26 ... ok
test issue_30_realworld ... ==30187== Thread 2 issue_30_realwor:
==30187== Conditional jump or move depends on uninitialised value(s)
==30187==    at 0x1587A3: inflate::DynHuffman16::new (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x15DFD6: inflate::InflateStream::next_state (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x165D32: inflate::InflateStream::update (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x166BDD: inflate::utils::inflate (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x166DE2: inflate::utils::inflate_bytes_zlib (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x1191DC: test::issue_30_realworld (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x1185C5: core::ops::function::FnOnce::call_once (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x11B8FE: {{closure}} (lib.rs:1451)
==30187==    by 0x11B8FE: call_once<closure,()> (function.rs:223)
==30187==    by 0x11B8FE: <F as alloc::boxed::FnBox<A>>::call_box (boxed.rs:640)
==30187==    by 0x1868D9: __rust_maybe_catch_panic (lib.rs:105)
==30187==    by 0x13CA6D: try<(),std::panic::AssertUnwindSafe<alloc::boxed::Box<FnBox<()>>>> (panicking.rs:289)
==30187==    by 0x13CA6D: catch_unwind<std::panic::AssertUnwindSafe<alloc::boxed::Box<FnBox<()>>>,()> (panic.rs:392)
==30187==    by 0x13CA6D: {{closure}} (lib.rs:1406)
==30187==    by 0x13CA6D: std::sys_common::backtrace::__rust_begin_short_backtrace (backtrace.rs:136)
==30187==    by 0x13D4E4: {{closure}}<closure,()> (mod.rs:409)
==30187==    by 0x13D4E4: call_once<(),closure> (panic.rs:313)
==30187==    by 0x13D4E4: _ZN3std9panicking3try7do_call17hc8dd9c603c8ee86aE.llvm.1944736062225378994 (panicking.rs:310)
==30187==    by 0x1868D9: __rust_maybe_catch_panic (lib.rs:105)
==30187== 
ok
test issue_30_small ... ok
test issue_38_inflate ... ok
test issue_38_update_bits ... ok
test issue_38_update_lendist ... ok
test issue_38_update_no_progress ... ok
test no_checksum ... ==30187== Conditional jump or move depends on uninitialised value(s)
==30187==    at 0x1587A3: inflate::DynHuffman16::new (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x15DFD6: inflate::InflateStream::next_state (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x165D32: inflate::InflateStream::update (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x1192CD: test::no_checksum (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x118595: core::ops::function::FnOnce::call_once (in /media/media/tmp/inflate/target/release/deps/test-7db46c3c67811ea2)
==30187==    by 0x11B8FE: {{closure}} (lib.rs:1451)
==30187==    by 0x11B8FE: call_once<closure,()> (function.rs:223)
==30187==    by 0x11B8FE: <F as alloc::boxed::FnBox<A>>::call_box (boxed.rs:640)
==30187==    by 0x1868D9: __rust_maybe_catch_panic (lib.rs:105)
==30187==    by 0x13CA6D: try<(),std::panic::AssertUnwindSafe<alloc::boxed::Box<FnBox<()>>>> (panicking.rs:289)
==30187==    by 0x13CA6D: catch_unwind<std::panic::AssertUnwindSafe<alloc::boxed::Box<FnBox<()>>>,()> (panic.rs:392)
==30187==    by 0x13CA6D: {{closure}} (lib.rs:1406)
==30187==    by 0x13CA6D: std::sys_common::backtrace::__rust_begin_short_backtrace (backtrace.rs:136)
==30187==    by 0x13D4E4: {{closure}}<closure,()> (mod.rs:409)
==30187==    by 0x13D4E4: call_once<(),closure> (panic.rs:313)
==30187==    by 0x13D4E4: _ZN3std9panicking3try7do_call17hc8dd9c603c8ee86aE.llvm.1944736062225378994 (panicking.rs:310)
==30187==    by 0x1868D9: __rust_maybe_catch_panic (lib.rs:105)
==30187==    by 0x130E96: try<(),std::panic::AssertUnwindSafe<closure>> (panicking.rs:289)
==30187==    by 0x130E96: catch_unwind<std::panic::AssertUnwindSafe<closure>,()> (panic.rs:392)
==30187==    by 0x130E96: {{closure}}<closure,()> (mod.rs:408)
==30187==    by 0x130E96: <F as alloc::boxed::FnBox<A>>::call_box (boxed.rs:640)
==30187==    by 0x16940A: call_once<(),()> (boxed.rs:650)
==30187==    by 0x16940A: std::sys_common::thread::start_thread (thread.rs:24)
==30187== 
ok

test result: ok. 11 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

==30187== 
==30187== HEAP SUMMARY:
==30187==     in use at exit: 32 bytes in 1 blocks
==30187==   total heap usage: 52 allocs, 51 frees, 3,728 bytes allocated
==30187== 
==30187== LEAK SUMMARY:
==30187==    definitely lost: 0 bytes in 0 blocks
==30187==    indirectly lost: 0 bytes in 0 blocks
==30187==      possibly lost: 0 bytes in 0 blocks
==30187==    still reachable: 32 bytes in 1 blocks
==30187==         suppressed: 0 bytes in 0 blocks
==30187== Rerun with --leak-check=full to see details of leaked memory
==30187== 
==30187== For counts of detected and suppressed errors, rerun with: -v
==30187== Use --track-origins=yes to see where uninitialised values come from
==30187== ERROR SUMMARY: 168 errors from 2 contexts (suppressed: 0 from 0)
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

1 participant