[x264-devel] x86-64: fix trellis asm with interlacing

Jason Garrett-Glaser git at videolan.org
Wed Feb 27 00:18:02 CET 2013


x264 | branch: master | Jason Garrett-Glaser <jason at x264.com> | Sun Feb 10 16:12:34 2013 -0800| [637005ebef9f36b816a9777183660ea17f5b249d] | committer: Jason Garrett-Glaser

x86-64: fix trellis asm with interlacing

Regression in r2145.
Assembly assumed array was [2][64] when it was actually [2][63].
Tiny (~0.1%) compression improvement.

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=637005ebef9f36b816a9777183660ea17f5b249d
---

 encoder/cabac.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/encoder/cabac.c b/encoder/cabac.c
index 11d5b22..8bd86f7 100644
--- a/encoder/cabac.c
+++ b/encoder/cabac.c
@@ -659,11 +659,12 @@ static const uint16_t coeff_abs_level_m1_offset[14] =
     227+0, 227+10, 227+20, 227+30, 227+39, 426, 952+0, 952+10, 952+20, 708, 982+0, 982+10, 982+20, 766
 };
 #if RDO_SKIP_BS
-extern const uint8_t x264_significant_coeff_flag_offset_8x8[2][63];
+extern const uint8_t x264_significant_coeff_flag_offset_8x8[2][64];
 extern const uint8_t x264_last_coeff_flag_offset_8x8[63];
 extern const uint8_t x264_coeff_flag_offset_chroma_422_dc[7];
 #else
-const uint8_t x264_significant_coeff_flag_offset_8x8[2][63] =
+/* Padded to [64] for easier addressing */
+const uint8_t x264_significant_coeff_flag_offset_8x8[2][64] =
 {{
     0, 1, 2, 3, 4, 5, 5, 4, 4, 3, 3, 4, 4, 4, 5, 5,
     4, 4, 4, 4, 3, 3, 6, 7, 7, 7, 8, 9,10, 9, 8, 7,



More information about the x264-devel mailing list