[x264-devel] commit: r940 broke threads (Loren Merritt )
git version control
git at videolan.org
Thu Aug 21 02:58:36 CEST 2008
x264 | branch: master | Loren Merritt <pengvado at akuvian.org> | Wed Aug 20 19:00:52 2008 -0600| [ae8da3e5c85562d1018b9f85c601884022f070a3] | committer: Loren Merritt
r940 broke threads
> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=ae8da3e5c85562d1018b9f85c601884022f070a3
---
common/common.h | 6 ++++++
encoder/encoder.c | 1 -
2 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/common/common.h b/common/common.h
index dde1b10..6158295 100644
--- a/common/common.h
+++ b/common/common.h
@@ -262,6 +262,8 @@ struct x264_t
int i_frame_size;
} out;
+ /**** thread synchronization starts here ****/
+
/* frame number/poc */
int i_frame;
@@ -404,6 +406,10 @@ struct x264_t
int i_mb_prev_xy;
int i_mb_top_xy;
+ /**** thread synchronization ends here ****/
+ /* subsequence variables are either thread-local or constant,
+ * and won't be copied from one thread to another */
+
/* mb table */
int8_t *type; /* mb type */
int8_t *qp; /* mb qp */
diff --git a/encoder/encoder.c b/encoder/encoder.c
index 89309ee..ab45238 100644
--- a/encoder/encoder.c
+++ b/encoder/encoder.c
@@ -1258,7 +1258,6 @@ static void x264_thread_sync_context( x264_t *dst, x264_t *src )
// copy everything except the per-thread pointers and the constants.
memcpy( &dst->i_frame, &src->i_frame, offsetof(x264_t, mb.type) - offsetof(x264_t, i_frame) );
- memcpy( &dst->mb.i_type, &src->mb.i_type, offsetof(x264_t, rc) - offsetof(x264_t, mb.i_type) );
dst->stat = src->stat;
}
More information about the x264-devel
mailing list