avcodec/x86/pngdsp: Remove obsolete ff_add_bytes_l2_mmx()
It is overridden by ff_add_bytes_l2_sse2() on any non-ancient CPU. Reviewed-by: Henrik Gramner <henrik@gramner.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
39a538f430
commit
cddb25c848
@ -29,9 +29,8 @@ cextern pw_255
|
|||||||
|
|
||||||
SECTION .text
|
SECTION .text
|
||||||
|
|
||||||
; %1 = nr. of xmm registers used
|
INIT_XMM sse2
|
||||||
%macro ADD_BYTES_FN 1
|
cglobal add_bytes_l2, 4, 6, 2, dst, src1, src2, wa, w, i
|
||||||
cglobal add_bytes_l2, 4, 6, %1, dst, src1, src2, wa, w, i
|
|
||||||
%if ARCH_X86_64
|
%if ARCH_X86_64
|
||||||
movsxd waq, wad
|
movsxd waq, wad
|
||||||
%endif
|
%endif
|
||||||
@ -53,7 +52,6 @@ cglobal add_bytes_l2, 4, 6, %1, dst, src1, src2, wa, w, i
|
|||||||
cmp iq, waq
|
cmp iq, waq
|
||||||
jl .loop_v
|
jl .loop_v
|
||||||
|
|
||||||
%if mmsize == 16
|
|
||||||
; vector loop
|
; vector loop
|
||||||
mov waq, wq
|
mov waq, wq
|
||||||
and waq, ~7
|
and waq, ~7
|
||||||
@ -66,7 +64,6 @@ cglobal add_bytes_l2, 4, 6, %1, dst, src1, src2, wa, w, i
|
|||||||
.end_l:
|
.end_l:
|
||||||
cmp iq, waq
|
cmp iq, waq
|
||||||
jl .loop_l
|
jl .loop_l
|
||||||
%endif
|
|
||||||
|
|
||||||
; scalar loop for leftover
|
; scalar loop for leftover
|
||||||
jmp .end_s
|
jmp .end_s
|
||||||
@ -79,15 +76,6 @@ cglobal add_bytes_l2, 4, 6, %1, dst, src1, src2, wa, w, i
|
|||||||
cmp iq, wq
|
cmp iq, wq
|
||||||
jl .loop_s
|
jl .loop_s
|
||||||
REP_RET
|
REP_RET
|
||||||
%endmacro
|
|
||||||
|
|
||||||
%if ARCH_X86_32
|
|
||||||
INIT_MMX mmx
|
|
||||||
ADD_BYTES_FN 0
|
|
||||||
%endif
|
|
||||||
|
|
||||||
INIT_XMM sse2
|
|
||||||
ADD_BYTES_FN 2
|
|
||||||
|
|
||||||
%macro ADD_PAETH_PRED_FN 1
|
%macro ADD_PAETH_PRED_FN 1
|
||||||
cglobal add_png_paeth_prediction, 5, 7, %1, dst, src, top, w, bpp, end, cntr
|
cglobal add_png_paeth_prediction, 5, 7, %1, dst, src, top, w, bpp, end, cntr
|
||||||
|
@ -20,7 +20,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include "config.h"
|
|
||||||
#include "libavutil/attributes.h"
|
#include "libavutil/attributes.h"
|
||||||
#include "libavutil/x86/cpu.h"
|
#include "libavutil/x86/cpu.h"
|
||||||
#include "libavcodec/pngdsp.h"
|
#include "libavcodec/pngdsp.h"
|
||||||
@ -29,8 +28,6 @@ void ff_add_png_paeth_prediction_mmxext(uint8_t *dst, uint8_t *src,
|
|||||||
uint8_t *top, int w, int bpp);
|
uint8_t *top, int w, int bpp);
|
||||||
void ff_add_png_paeth_prediction_ssse3(uint8_t *dst, uint8_t *src,
|
void ff_add_png_paeth_prediction_ssse3(uint8_t *dst, uint8_t *src,
|
||||||
uint8_t *top, int w, int bpp);
|
uint8_t *top, int w, int bpp);
|
||||||
void ff_add_bytes_l2_mmx (uint8_t *dst, uint8_t *src1,
|
|
||||||
uint8_t *src2, int w);
|
|
||||||
void ff_add_bytes_l2_sse2(uint8_t *dst, uint8_t *src1,
|
void ff_add_bytes_l2_sse2(uint8_t *dst, uint8_t *src1,
|
||||||
uint8_t *src2, int w);
|
uint8_t *src2, int w);
|
||||||
|
|
||||||
@ -38,10 +35,6 @@ av_cold void ff_pngdsp_init_x86(PNGDSPContext *dsp)
|
|||||||
{
|
{
|
||||||
int cpu_flags = av_get_cpu_flags();
|
int cpu_flags = av_get_cpu_flags();
|
||||||
|
|
||||||
#if ARCH_X86_32
|
|
||||||
if (EXTERNAL_MMX(cpu_flags))
|
|
||||||
dsp->add_bytes_l2 = ff_add_bytes_l2_mmx;
|
|
||||||
#endif
|
|
||||||
if (EXTERNAL_MMXEXT(cpu_flags))
|
if (EXTERNAL_MMXEXT(cpu_flags))
|
||||||
dsp->add_paeth_prediction = ff_add_png_paeth_prediction_mmxext;
|
dsp->add_paeth_prediction = ff_add_png_paeth_prediction_mmxext;
|
||||||
if (EXTERNAL_SSE2(cpu_flags))
|
if (EXTERNAL_SSE2(cpu_flags))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user