cb4x4: Elide special cases cb4x4 doesn't need These conditions in has_top_right() are never true when cb4x4 is enabled. The corresponding check in has_bottom_left() is already behind a similar #if. This is needed by a subsequent patch to move sub-4x4 block sizes behind their own configuration flag, since that changes the value of bw_unit, which might cause the condition to become true when it should not be. Encoder and decoder output should remain unchanged. Change-Id: I648654dfc265f911d83668d94dc927ebc0c70771
diff --git a/av1/common/reconintra.c b/av1/common/reconintra.c index c9b7edb..b8cb2ff 100644 --- a/av1/common/reconintra.c +++ b/av1/common/reconintra.c
@@ -447,8 +447,10 @@ const int plane_bw_unit = AOMMAX(bw_unit >> ss_x, 1); const int top_right_count_unit = tx_size_wide_unit[txsz]; +#if !CONFIG_CB4X4 // Special handling for block sizes 4x8 and 4x4. if (ss_x == 0 && bw_unit < 2 && col_off == 0) return 1; +#endif if (row_off > 0) { // Just need to check if enough pixels on the right. return col_off + top_right_count_unit < plane_bw_unit;