Commit 236ceb9598 for aom
commit 236ceb95988432b13ce456636ec96a95e86e3b14
Author: Yunqing Wang <yunqingwang@google.com>
Date: Fri Apr 24 16:28:20 2026 -0700
Remove unused FAST_HEX motion search method
Change-Id: I07c838639e82fba9cd84f37ac4545d8d20d03a6b
diff --git a/av1/encoder/mcomp.c b/av1/encoder/mcomp.c
index 480eb55047..c745955134 100644
--- a/av1/encoder/mcomp.c
+++ b/av1/encoder/mcomp.c
@@ -576,7 +576,7 @@ static void init_motion_compensation_bigdia(search_site_config *cfg, int stride,
cfg->num_search_steps = MAX_PATTERN_SCALES;
}
-// Search site initialization for HEX / FAST_HEX search methods.
+// Search site initialization for HEX search method.
static void init_motion_compensation_hex(search_site_config *cfg, int stride,
int level) {
(void)level;
@@ -1262,16 +1262,6 @@ static int bigdia_search(const FULLPEL_MV start_mv,
cost_list, best_mv, best_mv_stats);
}
-static int fast_hex_search(const FULLPEL_MV start_mv,
- const FULLPEL_MOTION_SEARCH_PARAMS *ms_params,
- const int search_step, const int do_init_search,
- int *cost_list, FULLPEL_MV *best_mv,
- FULLPEL_MV_STATS *best_mv_stats) {
- return hex_search(start_mv, ms_params,
- AOMMAX(MAX_MVSEARCH_STEPS - 2, search_step), do_init_search,
- cost_list, best_mv, best_mv_stats);
-}
-
static int vfast_dia_search(const FULLPEL_MV start_mv,
const FULLPEL_MOTION_SEARCH_PARAMS *ms_params,
const int search_step, const int do_init_search,
@@ -1815,15 +1805,10 @@ int av1_full_pixel_search(const FULLPEL_MV start_mv,
var = fast_dia_search(start_mv, ms_params, step_param, 0, cost_list,
best_mv, best_mv_stats);
break;
- case FAST_HEX:
- var = fast_hex_search(start_mv, ms_params, step_param, 0, cost_list,
- best_mv, best_mv_stats);
- break;
case HEX:
var = hex_search(start_mv, ms_params, step_param, 1, cost_list, best_mv,
best_mv_stats);
break;
-
case BIGDIA:
var = bigdia_search(start_mv, ms_params, step_param, 1, cost_list,
best_mv, best_mv_stats);
diff --git a/av1/encoder/mcomp.h b/av1/encoder/mcomp.h
index 5747de0886..53f1aae44d 100644
--- a/av1/encoder/mcomp.h
+++ b/av1/encoder/mcomp.h
@@ -172,7 +172,6 @@ static const SEARCH_METHODS search_method_lookup[NUM_SEARCH_METHODS] = {
CLAMPED_DIAMOND, // CLAMPED_DIAMOND
HEX, // HEX
BIGDIA, // BIGDIA
- HEX, // FAST_HEX
BIGDIA, // FAST_DIAMOND
BIGDIA, // FAST_BIGDIA
BIGDIA // VFAST_DIAMOND
diff --git a/av1/encoder/mcomp_structs.h b/av1/encoder/mcomp_structs.h
index 9bb03b05f0..28cc2c7d8f 100644
--- a/av1/encoder/mcomp_structs.h
+++ b/av1/encoder/mcomp_structs.h
@@ -72,14 +72,12 @@ enum {
// up to 11 search stages. First stage consists of 4 search
// points and the rest with 8 search points each.
BIGDIA = 5,
- // HEX search with up to 2 stages.
- FAST_HEX = 6,
// BIGDIA search with up to 2 stages.
- FAST_DIAMOND = 7,
+ FAST_DIAMOND = 6,
// BIGDIA search with up to 3 stages.
- FAST_BIGDIA = 8,
+ FAST_BIGDIA = 7,
// BIGDIA search with up to 1 stage.
- VFAST_DIAMOND = 9,
+ VFAST_DIAMOND = 8,
// Total number of search methods.
NUM_SEARCH_METHODS,
// Number of distinct search methods.
diff --git a/av1/encoder/motion_search_facade.h b/av1/encoder/motion_search_facade.h
index 87a18cb961..402fdf16e8 100644
--- a/av1/encoder/motion_search_facade.h
+++ b/av1/encoder/motion_search_facade.h
@@ -99,16 +99,15 @@ static inline SEARCH_METHODS av1_get_faster_search_method(
// 1. NSTEP
// 2. DIAMOND
// 3. BIGDIA
- // 4. HEX.
- // 5. FAST_HEX \approx FAST_DIAMOND
+ // 4. HEX
+ // 5. FAST_DIAMOND
switch (search_method) {
case NSTEP: return DIAMOND;
case NSTEP_8PT: return DIAMOND;
case DIAMOND: return BIGDIA;
case CLAMPED_DIAMOND: return BIGDIA;
case BIGDIA: return HEX;
- case HEX: return FAST_HEX;
- case FAST_HEX: return FAST_HEX;
+ case HEX: return FAST_DIAMOND;
case FAST_DIAMOND: return VFAST_DIAMOND;
case FAST_BIGDIA: return FAST_BIGDIA;
case VFAST_DIAMOND: return VFAST_DIAMOND;