Re: [DynInst_API:] Hung process


Date: Tue, 03 Feb 2015 09:12:23 -0800
From: Josh Stone <jistone@xxxxxxxxxx>
Subject: Re: [DynInst_API:] Hung process
On 02/03/2015 07:22 AM, Gerard wrote:
> Hello,
> 
> I'm experiencing a strange issue while instrumenting a multithreaded
> application. In essence this application sends data to other processes
> through TCP/IP connections using multiple threads (one per connection).
> The problem is that after 39~41 successful connections (always the
> same), the whole process hangs and I don't know why this happens or how
> to make it to continue.
> 
> Without Dyninst instrumentation the process works correctly so I don't
> know if it is a problem with how I'm using Dyninst or a problem that
> appears due to using it. If I remove the use of threads the application
> never hangs and all the data is sent correctly so I guess it is related.
> 
> Any tips why this could happen?

There is a compiled constant MAX_THREADS, just 32.  If anything, I'm
surprised that you got up around 40 before seeing issues. :)

In dyninstAPI_RT, it's used for DYNINST_max_num_threads, and it looks
like there's code to initialize larger counts dynamically, but I don't
see anywhere that actually tries to set it higher.  It would have to be
done as part of process init though.
[← Prev in Thread] Current Thread [Next in Thread→]