summaryrefslogtreecommitdiff
path: root/vp9/decoder
diff options
context:
space:
mode:
authorJingning Han <jingning@google.com>2015-07-07 11:36:05 -0700
committerJingning Han <jingning@google.com>2015-07-07 11:36:05 -0700
commitcccad1c5de41e29d6cc64c6e11a1d91c8486d090 (patch)
treed160b83e82fb7d38fbfe93e62cff9c06adc719c8 /vp9/decoder
parent0ede9f52b796b6d8e02046b24f68a3db8b9f5920 (diff)
downloadlibvpx-cccad1c5de41e29d6cc64c6e11a1d91c8486d090.tar
libvpx-cccad1c5de41e29d6cc64c6e11a1d91c8486d090.tar.gz
libvpx-cccad1c5de41e29d6cc64c6e11a1d91c8486d090.tar.bz2
libvpx-cccad1c5de41e29d6cc64c6e11a1d91c8486d090.zip
Reduce dqcoeff array size in decoder
The decoding process handles detokenization and reconstruction per transform block sequentially. There is no need to offset the dqcoeff buffer according to the transform block index. This allows to reduce the memory spill and improve cache performance. Change-Id: Ibb8bfe532a7a08fcabaf6d42cbec1e986901d32d
Diffstat (limited to 'vp9/decoder')
-rw-r--r--vp9/decoder/vp9_decodeframe.c2
-rw-r--r--vp9/decoder/vp9_detokenize.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/vp9/decoder/vp9_decodeframe.c b/vp9/decoder/vp9_decodeframe.c
index e81fa0478..6ddfcbb4b 100644
--- a/vp9/decoder/vp9_decodeframe.c
+++ b/vp9/decoder/vp9_decodeframe.c
@@ -188,7 +188,7 @@ static void inverse_transform_block(MACROBLOCKD* xd, int plane, int block,
struct macroblockd_plane *const pd = &xd->plane[plane];
if (eob > 0) {
TX_TYPE tx_type = DCT_DCT;
- tran_low_t *const dqcoeff = BLOCK_OFFSET(pd->dqcoeff, block);
+ tran_low_t *const dqcoeff = pd->dqcoeff;
#if CONFIG_VP9_HIGHBITDEPTH
if (xd->cur_buf->flags & YV12_FLAG_HIGHBITDEPTH) {
if (xd->lossless) {
diff --git a/vp9/decoder/vp9_detokenize.c b/vp9/decoder/vp9_detokenize.c
index 3304e64b2..2e2605903 100644
--- a/vp9/decoder/vp9_detokenize.c
+++ b/vp9/decoder/vp9_detokenize.c
@@ -217,7 +217,7 @@ int vp9_decode_block_tokens(MACROBLOCKD *xd,
pd->left_context + y);
const scan_order *so = get_scan(xd, tx_size, pd->plane_type, block);
const int eob = decode_coefs(xd, pd->plane_type,
- BLOCK_OFFSET(pd->dqcoeff, block), tx_size,
+ pd->dqcoeff, tx_size,
dequant, ctx, so->scan, so->neighbors, r);
vp9_set_contexts(xd, pd, plane_bsize, tx_size, eob > 0, x, y);
return eob;