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
7edaf4ed
Commit
7edaf4ed
authored
May 06, 2013
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x86: rnd_template: Eliminate pointless OP_AVG macro indirection
parent
db9aee6c
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
12 deletions
+8
-12
dsputil_mmx.c
libavcodec/x86/dsputil_mmx.c
+0
-2
hpeldsp_init.c
libavcodec/x86/hpeldsp_init.c
+0
-2
hpeldsp_rnd_template.c
libavcodec/x86/hpeldsp_rnd_template.c
+6
-6
rnd_template.c
libavcodec/x86/rnd_template.c
+2
-2
No files found.
libavcodec/x86/dsputil_mmx.c
View file @
7edaf4ed
...
...
@@ -106,7 +106,6 @@ void ff_put_no_rnd_mpeg4_qpel8_v_lowpass_mmxext(uint8_t *dst, uint8_t *src,
#define SET_RND MOVQ_WTWO
#define PAVGBP(a, b, c, d, e, f) PAVGBP_MMX(a, b, c, d, e, f)
#define PAVGB(a, b, c, e) PAVGB_MMX(a, b, c, e)
#define OP_AVG(a, b, c, e) PAVGB_MMX(a, b, c, e)
#include "rnd_template.c"
...
...
@@ -114,7 +113,6 @@ void ff_put_no_rnd_mpeg4_qpel8_v_lowpass_mmxext(uint8_t *dst, uint8_t *src,
#undef SET_RND
#undef PAVGBP
#undef PAVGB
#undef OP_AVG
/***********************************/
/* standard MMX */
...
...
libavcodec/x86/hpeldsp_init.c
View file @
7edaf4ed
...
...
@@ -91,7 +91,6 @@ void ff_avg_pixels8_xy2_3dnow(uint8_t *block, const uint8_t *pixels,
#define SET_RND MOVQ_WONE
#define PAVGBP(a, b, c, d, e, f) PAVGBP_MMX_NO_RND(a, b, c, d, e, f)
#define PAVGB(a, b, c, e) PAVGB_MMX_NO_RND(a, b, c, e)
#define OP_AVG(a, b, c, e) PAVGB_MMX(a, b, c, e)
#include "hpeldsp_rnd_template.c"
...
...
@@ -113,7 +112,6 @@ void ff_avg_pixels8_xy2_3dnow(uint8_t *block, const uint8_t *pixels,
#undef SET_RND
#undef PAVGBP
#undef PAVGB
#undef OP_AVG
#endif
/* HAVE_INLINE_ASM */
...
...
libavcodec/x86/hpeldsp_rnd_template.c
View file @
7edaf4ed
...
...
@@ -144,13 +144,13 @@ static void DEF(avg, pixels16_x2)(uint8_t *block, const uint8_t *pixels, ptrdiff
"movq 1%1, %%mm1
\n\t
"
"movq %0, %%mm3
\n\t
"
PAVGB
(
%%
mm0
,
%%
mm1
,
%%
mm2
,
%%
mm6
)
OP_AVG
(
%%
mm3
,
%%
mm2
,
%%
mm0
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm2
,
%%
mm0
,
%%
mm6
)
"movq %%mm0, %0
\n\t
"
"movq 8%1, %%mm0
\n\t
"
"movq 9%1, %%mm1
\n\t
"
"movq 8%0, %%mm3
\n\t
"
PAVGB
(
%%
mm0
,
%%
mm1
,
%%
mm2
,
%%
mm6
)
OP_AVG
(
%%
mm3
,
%%
mm2
,
%%
mm0
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm2
,
%%
mm0
,
%%
mm6
)
"movq %%mm0, 8%0
\n\t
"
:
"+m"
(
*
block
)
:
"m"
(
*
pixels
)
...
...
@@ -172,9 +172,9 @@ static void DEF(avg, pixels8_y2)(uint8_t *block, const uint8_t *pixels, ptrdiff_
"movq (%1, %%"
REG_a
"), %%mm2
\n\t
"
PAVGBP
(
%%
mm1
,
%%
mm0
,
%%
mm4
,
%%
mm2
,
%%
mm1
,
%%
mm5
)
"movq (%2), %%mm3
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm4
,
%%
mm0
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm4
,
%%
mm0
,
%%
mm6
)
"movq (%2, %3), %%mm3
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm5
,
%%
mm1
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm5
,
%%
mm1
,
%%
mm6
)
"movq %%mm0, (%2)
\n\t
"
"movq %%mm1, (%2, %3)
\n\t
"
"add %%"
REG_a
", %1
\n\t
"
...
...
@@ -184,9 +184,9 @@ static void DEF(avg, pixels8_y2)(uint8_t *block, const uint8_t *pixels, ptrdiff_
"movq (%1, %%"
REG_a
"), %%mm0
\n\t
"
PAVGBP
(
%%
mm1
,
%%
mm2
,
%%
mm4
,
%%
mm0
,
%%
mm1
,
%%
mm5
)
"movq (%2), %%mm3
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm4
,
%%
mm2
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm4
,
%%
mm2
,
%%
mm6
)
"movq (%2, %3), %%mm3
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm5
,
%%
mm1
,
%%
mm6
)
PAVGB_MMX
(
%%
mm3
,
%%
mm5
,
%%
mm1
,
%%
mm6
)
"movq %%mm2, (%2)
\n\t
"
"movq %%mm1, (%2, %3)
\n\t
"
"add %%"
REG_a
", %1
\n\t
"
...
...
libavcodec/x86/rnd_template.c
View file @
7edaf4ed
...
...
@@ -132,7 +132,7 @@ static void DEF(avg, pixels8_xy2)(uint8_t *block, const uint8_t *pixels, ptrdiff
"packuswb %%mm5, %%mm4
\n\t
"
"pcmpeqd %%mm2, %%mm2
\n\t
"
"paddb %%mm2, %%mm2
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm4
,
%%
mm5
,
%%
mm2
)
PAVGB_MMX
(
%%
mm3
,
%%
mm4
,
%%
mm5
,
%%
mm2
)
"movq %%mm5, (%2, %%"
REG_a
")
\n\t
"
"add %3, %%"
REG_a
"
\n\t
"
...
...
@@ -156,7 +156,7 @@ static void DEF(avg, pixels8_xy2)(uint8_t *block, const uint8_t *pixels, ptrdiff
"packuswb %%mm1, %%mm0
\n\t
"
"pcmpeqd %%mm2, %%mm2
\n\t
"
"paddb %%mm2, %%mm2
\n\t
"
OP_AVG
(
%%
mm3
,
%%
mm0
,
%%
mm1
,
%%
mm2
)
PAVGB_MMX
(
%%
mm3
,
%%
mm0
,
%%
mm1
,
%%
mm2
)
"movq %%mm1, (%2, %%"
REG_a
")
\n\t
"
"add %3, %%"
REG_a
"
\n\t
"
...
...
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