[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Libunwind-devel] Commit 32202619c42f58a9dac6eee3b9a4c231f1ce394a is mis

From: Paul Pluzhnikov
Subject: [Libunwind-devel] Commit 32202619c42f58a9dac6eee3b9a4c231f1ce394a is misleading
Date: Fri, 26 Oct 2012 10:35:31 -0700


This commit:

commit 32202619c42f58a9dac6eee3b9a4c231f1ce394a
Author: Arun Sharma <address@hidden>
Date:   Sat Aug 4 17:58:24 2012 -0700

    Fix a test failure

    The test contains hints to users of unw_backtrace() and friends
    on how to ensure correctness in a multi-threaded program

is (IMHO) misguided.

The original intent of the test was to prove that unw_backtrace() currently
calls calloc under certain conditions, and thus isn't safe if used from
e.g. tcmalloc.

Above change simply hid the brokenness, without actually fixing the problem,
which still exists today.

The hint to call unw_backtrace early in thread creation is not very useful
to tcmalloc users, as they have little control over exactly when
calloc is called during thread creation, or when tcmalloc decides to
record a stack trace.

I would prefer the test to fail while unw_backtrace() remains calloc-unsafe.

If the flood of "Ltest-nocalloc is failing" messages from end-users is
too distracting, perhaps there should be a "currently known to fail"
set of tests that only maintainers would know how to run?

Alternatively, just deleting the test is (IMHO) better than the false
security it currently provides.

Paul Pluzhnikov

reply via email to

[Prev in Thread] Current Thread [Next in Thread]