[FFmpeg-devel] Discussion related to the use of a global thread pool rather than the current threading model

Michael Niedermayer michael at niedermayer.cc
Fri Jan 8 12:38:36 CET 2016


On Fri, Jan 08, 2016 at 01:35:02PM +0300, Andrey Turkin wrote:
> 2016-01-08 12:42 GMT+03:00 Carl Eugen Hoyos <cehoyos at ag.or.at>:
> 
> >
> > I may have misunderstood myself but I believe the
> > issue actually only happens on Windows XP;-)
> >
> >
> I've encountered this issue a while back when trying to do about 20
> simultaneous transcodings with some video filters. It was on a high-end CPU
> with a lot of cores so every codec and MT-enabled video filter would spawn
> a lot of threads - can't remember exact number but hundreds of them. The
> threads' stacks would eat up all of the process' address space causing OOM.
> It was on Windows 7, and it's something you probably can call real-world
> example. I ended up disabling MT everywhere I can to fix that (which was a
> right thing to do anyway since my program was already multithreaded and it
> could use all the cores anyway). This thread-pool idea sounds reasonable to
> me; more reasonable than 8-16 threads per codec anyway.

I think this problem and the effects of the thread number should at
least be documented better. So other users running into this who
maybe are not as knowledgable know what to tweak

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

When you are offended at any man's fault, turn to yourself and study your
own failings. Then you will forget your anger. -- Epictetus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160108/7bfc2f06/attachment.sig>


More information about the ffmpeg-devel mailing list