Commit b8dcfc5a authored by Tom Finegan's avatar Tom Finegan

Silence unused function warning in subtract_test.cc.

Change-Id: I65f2f5d797ac11a0e270ac44146bba78b2e8e569
parent 71efd848
......@@ -147,8 +147,8 @@ class AV1HBDSubtractBlockTest : public ::testing::TestWithParam<Params> {
}
protected:
void RunForSpeed();
void CheckResult();
void RunForSpeed();
private:
ACMRandom rnd_;
......@@ -161,24 +161,6 @@ class AV1HBDSubtractBlockTest : public ::testing::TestWithParam<Params> {
int16_t *diff_;
};
void AV1HBDSubtractBlockTest::RunForSpeed() {
const int test_num = 200000;
const int max_width = 128;
const int max_block_size = max_width * max_width;
const int mask = (1 << bit_depth_) - 1;
int i, j;
for (j = 0; j < max_block_size; ++j) {
CONVERT_TO_SHORTPTR(src_)[j] = rnd_.Rand16() & mask;
CONVERT_TO_SHORTPTR(pred_)[j] = rnd_.Rand16() & mask;
}
for (i = 0; i < test_num; ++i) {
func_(block_height_, block_width_, diff_, block_width_, src_, block_width_,
pred_, block_width_, bit_depth_);
}
}
void AV1HBDSubtractBlockTest::CheckResult() {
const int test_num = 100;
const int max_width = 128;
......@@ -208,9 +190,25 @@ void AV1HBDSubtractBlockTest::CheckResult() {
TEST_P(AV1HBDSubtractBlockTest, CheckResult) { CheckResult(); }
#if USE_SPEED_TEST
TEST_P(AV1HBDSubtractBlockTest, CheckSpeed) { RunForSpeed(); }
#endif // USE_SPEED_TEST
void AV1HBDSubtractBlockTest::RunForSpeed() {
const int test_num = 200000;
const int max_width = 128;
const int max_block_size = max_width * max_width;
const int mask = (1 << bit_depth_) - 1;
int i, j;
for (j = 0; j < max_block_size; ++j) {
CONVERT_TO_SHORTPTR(src_)[j] = rnd_.Rand16() & mask;
CONVERT_TO_SHORTPTR(pred_)[j] = rnd_.Rand16() & mask;
}
for (i = 0; i < test_num; ++i) {
func_(block_height_, block_width_, diff_, block_width_, src_, block_width_,
pred_, block_width_, bit_depth_);
}
}
TEST_P(AV1HBDSubtractBlockTest, DISABLED_Speed) { RunForSpeed(); }
#if HAVE_SSE2
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment