[parsec-users] Pthread creation: vips and x264
cbienia at CS.Princeton.EDU
Fri Aug 14 15:33:57 EDT 2009
X264 spawns one thread per frame to encode, but no more than the number of
threads you specify are running at once. In other words, the number of
threads you pass to the program determines the maximum number of threads
that exist at any time, but the number of threads that exist over the
lifetime of the program is determined by the input video.
Vips uses glib for its thread management, which in turn uses pthreads on
Unix platforms. So you need to look for the correct glib function calls.
Here is the documentation for the glib threading API for the latest version
of the library:
From: parsec-users-bounces at lists.cs.princeton.edu
[mailto:parsec-users-bounces at lists.cs.princeton.edu] On Behalf Of Vivek Rane
Sent: Friday, August 14, 2009 2:50 PM
To: PARSEC Users
Subject: [parsec-users] Pthread creation: vips and x264
I'm trying to track where threads are created in each benchmark so I
can add a magic breakpoint (simics-related). I'm using the
In x264, this seems to be this method (in the file encoder.c):
static int x264_slices_write( x264_t *h )
For some reason, despite specifying 2 threads, I can see that 8
threads (all with different TIDs) are being created. Is this expected?
I suppose it could be the case that only 2 are active at a time?
In vips, I the only pthread_create call is in this method (in the file
static void* _events_thread(void *arg)
There is a Windows version of the method too, so I was expecting the
other method will be called for thread creation but this doesn't seem
to be happening. Is there any other place that threads are being
created? A find reveals no other pthread_create calls.
Thanks for your time and help!
parsec-users mailing list
parsec-users at lists.cs.princeton.edu
More information about the parsec-users