Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
db7d8fb4
Commit
db7d8fb4
authored
Jun 20, 2012
by
Mans Rullgard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dct-test: use emms_c() from libavutil instead of duplicating it
parent
f1f37c70
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
dct-test.c
libavcodec/dct-test.c
+3
-11
No files found.
libavcodec/dct-test.c
View file @
db7d8fb4
...
...
@@ -181,14 +181,6 @@ static void idct_mmx_init(void)
DECLARE_ALIGNED
(
16
,
static
DCTELEM
,
block
)[
64
];
DECLARE_ALIGNED
(
8
,
static
DCTELEM
,
block1
)[
64
];
static
inline
void
mmx_emms
(
void
)
{
#if HAVE_MMX
if
(
cpu_flags
&
AV_CPU_FLAG_MMX
)
__asm__
volatile
(
"emms
\n\t
"
);
#endif
}
static
void
init_block
(
DCTELEM
block
[
64
],
int
test
,
int
is_idct
,
AVLFG
*
prng
)
{
int
i
,
j
;
...
...
@@ -263,7 +255,7 @@ static int dct_error(const struct algo *dct, int test, int is_idct, int speed)
permute
(
block
,
block1
,
dct
->
format
);
dct
->
func
(
block
);
mmx_emms
();
emms_c
();
if
(
dct
->
format
==
SCALE_PERM
)
{
for
(
i
=
0
;
i
<
64
;
i
++
)
{
...
...
@@ -330,7 +322,7 @@ static int dct_error(const struct algo *dct, int test, int is_idct, int speed)
it1
+=
NB_ITS_SPEED
;
ti1
=
gettime
()
-
ti
;
}
while
(
ti1
<
1000000
);
mmx_emms
();
emms_c
();
printf
(
"%s %s: %0.1f kdct/s
\n
"
,
is_idct
?
"IDCT"
:
"DCT"
,
dct
->
name
,
(
double
)
it1
*
1000
.
0
/
(
double
)
ti1
);
...
...
@@ -472,7 +464,7 @@ static void idct248_error(const char *name,
it1
+=
NB_ITS_SPEED
;
ti1
=
gettime
()
-
ti
;
}
while
(
ti1
<
1000000
);
mmx_emms
();
emms_c
();
printf
(
"%s %s: %0.1f kdct/s
\n
"
,
1
?
"IDCT248"
:
"DCT248"
,
name
,
(
double
)
it1
*
1000
.
0
/
(
double
)
ti1
);
...
...
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