[PATCH] Test case for BZ 19329

Florian Weimer fweimer@redhat.com
Thu Nov 24 18:54:00 GMT 2016


On 11/24/2016 02:41 PM, Joseph Myers wrote:
> On Thu, 24 Nov 2016, Szabolcs Nagy wrote:
>
>> Test concurrent dlopen and pthread_create when the loaded
>> modules have TLS.  This triggers dl-tls assertion failures
>> more reliably than the tst-stack4 test.
>>
>> The dlopened module has 100 DT_NEEDED dependencies and
>> for me about 4000 concurrent thread creations are needed
>> to see failures on x86_64.
>
> I'd be concerned about 4000 threads exceeding task or memory limits,
> possibly interfering with other things the same user is doing that also
> try to create tasks.

Yes, reducing the number of threads which are created in parallel is 
strongly recommended.

> (I rountinely see tst-eintr1 failing with "pthread_create failed: Resource
> temporarily unavailable", sometimes terminating the test run because make
> fails to fork to run evaluate-test.sh, apparently not all threads having
> properly terminated by the time the test does.  I don't know how many
> threads that is creating.)

As far as I can tell, tst-eintr1 creates only twenty threads at most: 
ten outer threads, and each outer thread creates one inner thread.

It's likely you are running into a kernel bug, where task exit is 
reported before the kernel has deallocated the resources used by the task:

   https://bugzilla.kernel.org/show_bug.cgi?id=154011

Florian



More information about the Libc-alpha mailing list