vp9-rtc: Some speedups to speed 5 real-time mode
authorMarco Paniconi <marpan@google.com>
Fri, 24 Apr 2020 18:16:15 +0000 (11:16 -0700)
committerMarco Paniconi <marpan@google.com>
Fri, 24 Apr 2020 21:51:51 +0000 (14:51 -0700)
Disable checking rectangular partitions in
nonrd_pick_partition, and enable use_source_sad.

~3-4% speedup for HD clip on x86.
bdrate loss of ~0.2% on rtc set.

Change-Id: Ibef8f100f1f623482d47510cb4ec9278ba777d7c

vp9/encoder/vp9_encodeframe.c
vp9/encoder/vp9_speed_features.c

index 617750f..7905bf3 100644 (file)
@@ -5069,8 +5069,8 @@ static void nonrd_pick_partition(VP9_COMP *cpi, ThreadData *td,
 
   (void)*tp_orig;
 
-  // Avoid checking for rectangular partitions for speed >= 6.
-  if (cpi->oxcf.speed >= 6) do_rect = 0;
+  // Avoid checking for rectangular partitions for speed >= 5.
+  if (cpi->oxcf.speed >= 5) do_rect = 0;
 
   assert(num_8x8_blocks_wide_lookup[bsize] ==
          num_8x8_blocks_high_lookup[bsize]);
index 2cd5dee..4e6370b 100644 (file)
@@ -632,6 +632,7 @@ static void set_rt_speed_feature_framesize_independent(
       sf->use_compound_nonrd_pickmode = 1;
     }
     if (cm->width * cm->height > 1280 * 720) sf->cb_pred_filter_search = 1;
+    if (!cpi->external_resize) sf->use_source_sad = 1;
   }
 
   if (speed >= 6) {
@@ -644,8 +645,6 @@ static void set_rt_speed_feature_framesize_independent(
     sf->mv.reduce_first_step_size = 1;
     sf->skip_encode_sb = 0;
 
-    if (!cpi->external_resize) sf->use_source_sad = 1;
-
     if (sf->use_source_sad) {
       sf->adapt_partition_source_sad = 1;
       sf->adapt_partition_thresh =