Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Xiph.Org
aom-rav1e
Commits
b8dcfc5a
Commit
b8dcfc5a
authored
Aug 22, 2017
by
Tom Finegan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Silence unused function warning in subtract_test.cc.
Change-Id: I65f2f5d797ac11a0e270ac44146bba78b2e8e569
parent
71efd848
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
22 deletions
+20
-22
test/subtract_test.cc
test/subtract_test.cc
+20
-22
No files found.
test/subtract_test.cc
View file @
b8dcfc5a
...
...
@@ -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
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment