[CFL] Sub8x8 Validation Code Rewrite
Sub8x8 Validation code is changed to be more robust. The scope of the
validation is narrowed to validating that all of the required content in
the storage buffer was stored between CfL predictions. The early
termination used in the current mode decision code does not allow to
validate more than that.
This change does not change encoder output
BUG=aomedia:925
Change-Id: I7f1ed84da5037dcfaaf5da9cf33b4b8d664d2352
diff --git a/av1/common/blockd.h b/av1/common/blockd.h
index 277ec46..0d8b108 100644
--- a/av1/common/blockd.h
+++ b/av1/common/blockd.h
@@ -647,10 +647,12 @@
int is_chroma_reference;
#if CONFIG_DEBUG
- // The prediction used for sub8x8 blocks originates from multiple luma blocks,
- // this array is used to validate that cfl_store() is called only once for
- // each luma block
- uint8_t sub8x8_val[CFL_SUB8X8_VAL_MI_SQUARE];
+ // Validation buffer is usually 2x2, except for 16x4 and 4x16 in that case it
+ // is 4x2 and 2x4 respectively. To simplify accessing the buffer we use a
+ // stride of CFL_SUB8X8_VAL_MI_SIZE resulting in a square of 16.
+ uint16_t sub8x8_val[CFL_SUB8X8_VAL_MI_SQUARE];
+ uint16_t store_counter;
+ uint16_t last_compute_counter;
#endif // CONFIG_DEBUG
} CFL_CTX;
#endif // CONFIG_CFL