[FFmpeg-devel] [PATCH 0/7] convert most of the remaining files to stdatomic

Marton Balint cus at passwd.hu
Thu Mar 23 02:39:55 EET 2017


On Wed, 22 Mar 2017, James Almer wrote:

> This set deals with most of the remaining cases of libavutil/atomic.h usage.
> "make fate THREADS=4" passes here on mingw-w64, but I'm not 100% sure fate
> has proper coverage of some of these functions.
>
> Only ones remaining are Decklink (It's C++98 and I'm not sure how wise would
> it be to include a C11 header in there, so i'm leaving that to someone else),

Well, I did some testing with DeckLink and it indeed is a mess to include 
stdatomic.h in C++ code. For some compiler/platform combinations it works, 
for others it does not. Maybe the cleanest solution is to simply use the 
C++11 std::atomic<int>.

Actually there was a thread about this:
https://ffmpeg.org/pipermail/ffmpeg-devel/2016-June/195902.html

And there is also a GCC bugzilla entry:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60932

Regards,
Marton


More information about the ffmpeg-devel mailing list