]> git.apps.os.sepia.ceph.com Git - teuthology.git/commit
teuthology/task/install/valgrind.supp: add suppression for Boost.Thread 1213/head
authorKefu Chai <kchai@redhat.com>
Wed, 26 Sep 2018 07:45:45 +0000 (15:45 +0800)
committerKefu Chai <kchai@redhat.com>
Wed, 26 Sep 2018 07:58:32 +0000 (15:58 +0800)
commit25bd7bc72c4e03384d119058fc497398170ac264
tree6f293a49c4246f0cdf0886a694d5e8e94dfcf059
parentf1b3aa2dfb252e83f37fcf9fd381d0b53aa8632a
teuthology/task/install/valgrind.supp: add suppression for Boost.Thread

Boost.Thread passes `tls_destructor` to `pthread_key_create()` in hope
to free the allocated memory stored in TLS key `current_thread_tls_key`,
but neither Boost.Thread nor us uses `pthread_exit()` for calling the
cleanup functions. and Boost.Thread is against `pthread_exit()`, see [0,1].

but Boost.Thread offers a preprocessor macro to define a global variable
whose destructor calls `tls_destructor()`, but per [2], this macro is
not defined by default. and per [3], this macro could cause assertion
failure in Boost. so it might be advisable to not define it, even we
could do so in BuildBoost.cmake.

and since this `Leak_StillReachable` leak is a one-shot thing. i am
adding it to the suppression file.

---
[0] https://www.boost.org/doc/libs/1_68_0/doc/html/thread/thread_management.html#thread.thread_management.tutorial.native_from._code__phrase_role__identifier__pthread_exit__phrase___code__posix_limitation
[1] https://svn.boost.org/trac10/ticket/5013
[2] https://svn.boost.org/trac10/ticket/3926
[3] https://svn.boost.org/trac10/ticket/12049

Fixes: http://tracker.ceph.com/issues/22052
Signed-off-by: Kefu Chai <kchai@redhat.com>
teuthology/task/install/valgrind.supp