lavu: add support for atomic operations.

These could be used for reference counting, or for keeping track of
decoding progress in references in multithreaded decoders.

Support is provided by gcc/msvc/suncc intrinsics, with a fallback using
pthread mutexes.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
Ronald S. Bultje
2012-12-02 14:34:50 -08:00
committed by Anton Khirnov
parent eae0879d96
commit 65f1d45dcc
8 changed files with 359 additions and 0 deletions

View File

@@ -54,6 +54,7 @@ BUILT_HEADERS = avconfig.h
OBJS = adler32.o \
aes.o \
atomic.o \
audio_fifo.o \
avstring.o \
base64.o \
@@ -100,6 +101,7 @@ SKIPHEADERS = old_pix_fmts.h
TESTPROGS = adler32 \
aes \
atomic \
avstring \
base64 \
blowfish \