script: de-dupe and update valgrind suppressions #18178

pull jonatack wants to merge 2 commits into bitcoin:master from jonatack:add-valgrind-suppressions changing 1 files +104 −15
  1. jonatack commented at 2:19 pm on February 19, 2020: member

    This PR de-dupes the current suppressions, then reduces the additional ones currently generated down to the minimal entries needed to run valgrind 3.16.0 with --exit-on-first-error=yes. Tested on Debian 4.19 x86/64. Feedback welcome.

    These suppressions allow running valgrind without errors on current master for…

    test_bitcoin:

    0  valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
    1           --gen-suppressions=all --error-limit=no -s \
    2           --suppressions=contrib/valgrind.supp \
    3           src/test/test_bitcoin --log_level=test_suite
    

    bench_bitcoin:

    0  valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
    1           --gen-suppressions=all --error-limit=no -s \
    2           --suppressions=contrib/valgrind.supp \
    3           src/bench/bench_bitcoin -evals=1
    

    test_bitcoin-qt:

    0  valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
    1           --gen-suppressions=all --error-limit=no -s \
    2           --suppressions=contrib/valgrind.supp \
    3           src/qt/test/test_bitcoin-qt --log_level=test_suite
    

    and with make check-valgrind in PR #17639 which runs them all.

  2. valgrind: remove duplicate suppressions 5731a80def
  3. valgrind: add suppressions for unit/bench/qt tests
    This commit began with the suppressions generated by valgrind and reduced
    them by ~4x to the minimum necessary so that running valgrind with
    --exit-on-first-error can pass.
    
    All tested with valgrind 3.16.0 on Debian 4.19 x86/64.
    
    These suppressions enable running valgrind on current master for the
    
    unit tests
    
      valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
               --gen-suppressions=all --error-limit=no -s \
               --suppressions=contrib/valgrind.supp \
               src/test/test_bitcoin --log_level=test_suite
    
    bench
    
      valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
               --gen-suppressions=all --error-limit=no -s \
               --suppressions=contrib/valgrind.supp \
               src/bench/bench_bitcoin -evals=1
    
    qt tests
    
      valgrind --leak-check=full --show-leak-kinds=all --show-reachable=yes \
               --gen-suppressions=all --error-limit=no -s \
               --suppressions=contrib/valgrind.supp \
               src/qt/test/test_bitcoin-qt --log_level=test_suite
    
    as well as with `make check-valgrind` in PR 17639
    4dc8b2816f
  4. practicalswift commented at 2:26 pm on February 19, 2020: contributor

    @jonatack

    Are you able to reproduce this one reliably?

    0{
    1   Suppress rest_blockhash_by_height Conditional jump or move depends on uninitialised value(s)
    2   Memcheck:Cond
    3   fun:_ZL24rest_blockhash_by_heightP11HTTPRequestRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
    4}
    

    If so, can you try minimising the test case to find the root cause?

    It looks like the use of an uninitialised value, which would be a very valuable find!

  5. jonatack commented at 2:58 pm on February 19, 2020: member
    @practicalswift which test or test suite are you seeing fail without that suppression?
  6. jonatack commented at 3:01 pm on February 19, 2020: member
    Lone travis failure in “scheduler_tests/mockforward” is unrelated.
  7. practicalswift commented at 3:59 pm on February 19, 2020: contributor
    @jonatack I haven’t seen that failure - I quoted the diff :)
  8. DrahtBot added the label Scripts and tools on Feb 19, 2020
  9. DrahtBot added the label Tests on Feb 19, 2020
  10. jonatack commented at 4:38 pm on February 19, 2020: member

    @jonatack I haven’t seen that failure - I quoted the diff :)

    Oh ok, that appears to be worth looking into but is unrelated to this PR; that suppression was introduced in 2d23082 by @michiboo. Once this PR is merged it will be easier for me to look into individual errors without seeing a hundred other warnings or maintaining a custom suppressions file.

  11. jonatack renamed this:
    test: update valgrind suppressions
    script: de-dupe and update valgrind suppressions
    on Feb 25, 2020
  12. jonatack commented at 1:33 pm on February 26, 2020: member
    No reviews or interest in this, closing.
  13. jonatack closed this on Feb 26, 2020

  14. jonatack deleted the branch on Feb 26, 2020
  15. DrahtBot locked this on Feb 15, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-09-29 01:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me