[FFmpeg-devel] [PATCH 1/2] vp8: mark lockless thread synchronization variables as volatile
Michael Niedermayer
michaelni at gmx.at
Tue Jul 17 16:33:59 CEST 2012
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
---
libavcodec/vp8.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavcodec/vp8.h b/libavcodec/vp8.h
index 23d62af..51550c5 100644
--- a/libavcodec/vp8.h
+++ b/libavcodec/vp8.h
@@ -99,8 +99,8 @@ typedef struct {
pthread_cond_t cond;
#endif
int thread_nr;
- int thread_mb_pos; // (mb_y << 16) | (mb_x & 0xFFFF)
- int wait_mb_pos; // What the current thread is waiting on.
+ volatile int thread_mb_pos; // (mb_y << 16) | (mb_x & 0xFFFF)
+ volatile int wait_mb_pos; // What the current thread is waiting on.
uint8_t *edge_emu_buffer;
/**
* For coeff decode, we need to know whether the above block had non-zero
--
1.7.9.5
More information about the ffmpeg-devel
mailing list