From 863694a4363deedf88a7ac7d12e5cecb76a464df Mon Sep 17 00:00:00 2001 From: Jingning Han Date: Wed, 21 Dec 2016 09:42:24 -0800 Subject: [PATCH] Avoid divisions at decoder side in supertx Change-Id: I3c52a4759780d987d045bb7b34a27ee9f7f55117 --- av1/decoder/decodeframe.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/av1/decoder/decodeframe.c b/av1/decoder/decodeframe.c index 3f1c14795..354a41b29 100644 --- a/av1/decoder/decodeframe.c +++ b/av1/decoder/decodeframe.c @@ -832,7 +832,7 @@ static void dec_extend_dir(AV1Decoder *const pbi, MACROBLOCKD *const xd, if (mi_width > unit) { int i; assert(!b_sub8x8); - for (i = 0; i < mi_width / unit - 1; i++) { + for (i = 0; i < mi_width; i += unit) { mi_col_pred += unit; dec_predict_b_extend(pbi, xd, tile, block, mi_row, mi_col, mi_row_pred, mi_col_pred, mi_row_top, mi_col_top, dst_buf, @@ -853,7 +853,7 @@ static void dec_extend_dir(AV1Decoder *const pbi, MACROBLOCKD *const xd, if (mi_height > unit) { int i; - for (i = 0; i < mi_height / unit - 1; i++) { + for (i = 0; i < mi_height; i += unit) { mi_row_pred += unit; dec_predict_b_extend(pbi, xd, tile, block, mi_row, mi_col, mi_row_pred, mi_col_pred, mi_row_top, mi_col_top, dst_buf,