Fix Clang 15.0.0 -Wunused-but-set-variable warning
Change-Id: I53973daea41ca57001ae6c3d00712b4dfac2a671
diff --git a/av1/encoder/allintra_vis.c b/av1/encoder/allintra_vis.c
index 068daab..ef6dd70 100644
--- a/av1/encoder/allintra_vis.c
+++ b/av1/encoder/allintra_vis.c
@@ -242,7 +242,6 @@
const int use_hbd = cpi->source->flags & YV12_FLAG_HIGHBITDEPTH;
double vote = 0.0;
- int sb_count = 0;
for (int mi_row = 0; mi_row < cpi->frame_info.mi_rows; mi_row += mb_step) {
for (int mi_col = 0; mi_col < cpi->frame_info.mi_cols; mi_col += mb_step) {
const uint8_t *mb_buffer =
@@ -293,7 +292,6 @@
} else {
vote += 1.0;
}
- ++sb_count;
}
}
diff --git a/av1/encoder/partition_search.c b/av1/encoder/partition_search.c
index daaec87..b7af41e 100644
--- a/av1/encoder/partition_search.c
+++ b/av1/encoder/partition_search.c
@@ -4065,11 +4065,10 @@
// Write partition type with BFS order.
const PC_TREE *tree_node_queue[NUM_NODES] = { NULL };
int q_idx = 0;
- int depth = 0;
int last_idx = 1;
int num_nodes = 1;
- // First traversal to get number of leaf nodes and depth.
+ // First traversal to get number of leaf nodes.
tree_node_queue[q_idx] = pc_tree;
while (num_nodes > 0) {
const PC_TREE *node = tree_node_queue[q_idx];
@@ -4078,7 +4077,6 @@
tree_node_queue[last_idx] = node->split[i];
++last_idx;
}
- ++depth;
num_nodes += 4;
}
--num_nodes;
@@ -4089,7 +4087,6 @@
// Write partitions for each node.
q_idx = 0;
- depth = 0;
last_idx = 1;
num_nodes = 1;
tree_node_queue[q_idx] = pc_tree;
@@ -4101,7 +4098,6 @@
tree_node_queue[last_idx] = node->split[i];
++last_idx;
}
- ++depth;
num_nodes += 4;
}
--num_nodes;
@@ -4129,11 +4125,10 @@
// Write partition type with BFS order.
const PC_TREE *tree_node_queue[NUM_NODES] = { NULL };
int q_idx = 0;
- int depth = 0;
int last_idx = 1;
int num_nodes = 1;
- // First traversal to get number of leaf nodes and depth.
+ // First traversal to get number of leaf nodes.
tree_node_queue[q_idx] = pc_tree;
while (num_nodes > 0) {
const PC_TREE *node = tree_node_queue[q_idx];
@@ -4142,7 +4137,6 @@
tree_node_queue[last_idx] = node->split[i];
++last_idx;
}
- ++depth;
num_nodes += 4;
}
--num_nodes;
@@ -4153,7 +4147,6 @@
// Write partitions for each node.
q_idx = 0;
- depth = 0;
last_idx = 1;
num_nodes = 1;
tree_node_queue[q_idx] = pc_tree;
@@ -4166,7 +4159,6 @@
tree_node_queue[last_idx] = node->split[i];
++last_idx;
}
- ++depth;
num_nodes += 4;
}
}