From 10178e6161c9126a6178eadad122309f8372fb0d Mon Sep 17 00:00:00 2001 From: James Zern Date: Thu, 16 Jun 2022 18:43:44 -0700 Subject: [PATCH] vp9_encode_sb_row: remove a branch w/CONFIG_REALTIME_ONLY replace the check on use_nonrd_pick_mode with an assert. this is only a start, there are many branches that could be removed that check mode == REALTIME, etc. with this configuration. Bug: webm:1773 Change-Id: I38cf9f83e7c085eb8e87d5cf6db7dc75359b611b (cherry picked from commit 08b86d76224453ef9cbab4b10a48617715d9a14e) --- vp9/encoder/vp9_encodeframe.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c index 5f08fa6..a9f392b 100644 --- a/vp9/encoder/vp9_encodeframe.c +++ b/vp9/encoder/vp9_encodeframe.c @@ -5856,9 +5856,12 @@ void vp9_encode_sb_row(VP9_COMP *cpi, ThreadData *td, int tile_row, get_start_tok(cpi, tile_row, tile_col, mi_row, &tok); cpi->tplist[tile_row][tile_col][tile_sb_row].start = tok; +#if CONFIG_REALTIME_ONLY + assert(cpi->sf.use_nonrd_pick_mode); + encode_nonrd_sb_row(cpi, td, this_tile, mi_row, &tok); +#else if (cpi->sf.use_nonrd_pick_mode) encode_nonrd_sb_row(cpi, td, this_tile, mi_row, &tok); -#if !CONFIG_REALTIME_ONLY else encode_rd_sb_row(cpi, td, this_tile, mi_row, &tok); #endif -- 2.7.4