Le maanantaina 27. huhtikuuta 2026, 18.12.43 Itä-Euroopan kesäaika Nicolas 
George via ffmpeg-devel a écrit :
> Before somebody considers adding one, like inter-filter threading in
> lavfi, I hope we will discuss unifying all that into a single
> multi-threaded event loop and tasks scheduler.
> 
> We also need that for non-trivial network protocols.

Those are two different problems, or rather, we have no choice but to treat 
them as such. You can't properly unify a main loop for intra-process inter-
thread synchronisation (as with frame threading and slice threading) and one 
for external events (as for network protocols).

There are simply no portable ways to multiplex waiting on a condition variable 
or another thread synchronisation primitive versus on a file descriptor (or a 
socket/HANDLE on Windows). And if you only care about Linux, then the relevant 
but broken-by-design support for FUTEX_FD was dropped in 2.6.25.

And sure, some people would probably point that you can use anonymous pipes, 
or Linux-specific event file descriptors, as a thread signaling. But that's 
much 
slower than using futeces, especially on the fast paths.

-- 
Rémi Denis-Courmont
https://www.remlab.net/



_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to