You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since a long time we have seldomly a deadlock during the deallocation of threads and fork after perfoming a job. But it seems that since we add more threads in our job the case is more present.
What is our deadlock? Thanks to gdb we have the backtraces :
This one for all threads :
If we focus on the main thread we can see that it stuck during the free of a dynamic library of the fork :
And in the backtrace of a thread we can see that is locked during its deallocation of memory stack :
Hi,
Since a long time we have seldomly a deadlock during the deallocation of threads and fork after perfoming a job. But it seems that since we add more threads in our job the case is more present.
What is our deadlock? Thanks to gdb we have the backtraces :
This one for all threads :
If we focus on the main thread we can see that it stuck during the free of a dynamic library of the fork :
And in the backtrace of a thread we can see that is locked during its deallocation of memory stack :
All threads wait the mutex that is kept by this function of the glibc/nptl : https://sourceware.org/git/?p=glibc.git;a=blob;f=nptl/allocatestack.c;h=110ba18f5dbdb3054ee0b9545a76757a3ae74568;hb=9ea3686266dca3f004ba874745a4087a89682617#l1214
And this function is stuck during the tentative to lock the mutex here https://sourceware.org/git/?p=glibc.git;a=blob;f=nptl/allocatestack.c;h=110ba18f5dbdb3054ee0b9545a76757a3ae74568;hb=9ea3686266dca3f004ba874745a4087a89682617#l1239
Last clue, when I do a x/3 on the memory pointer of the stuck mutex I have "2 0 0" as if the mutex is still considered as locked but no trace of pid
Either this gscope_flagp is already free and so the futex_wait_simple stuck or other stuff.
Is it something already seen?
The text was updated successfully, but these errors were encountered: