[FFmpeg-devel] avfilter/vf_blend : add 16 bit simd version for basic blend mode

Martin Vignali martin.vignali at gmail.com
Thu Feb 8 23:13:43 EET 2018


>
> breaks build on x86-32 linux
>
> X86ASM  libavfilter/x86/vf_blend.o
> src/libavfilter/x86/vf_blend.asm:389: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:390: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:391: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:392: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:393: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:399: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:400: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:421: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:422: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:423: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:424: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:425: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:426: error: invalid combination of
> opcode and operands
> src/libavfilter/x86/vf_blend.asm:427: error: invalid combination of
> opcode and operands
> make: *** [libavfilter/x86/vf_blend.o] Error 1
>
>
Ok, find a way to reproduce it on x86_32 osX

The problem is inside this macro :

%macro BLEND_INIT 2-3
%if ARCH_X86_64
cglobal blend_%1, 6, 9, %2, top, top_linesize, bottom, bottom_linesize,
dst, dst_linesize, width, end, x
    mov    widthd, dword widthm
%else
cglobal blend_%1, 5, 7, %2, top, top_linesize, bottom, bottom_linesize,
dst, end, x
%define dst_linesizeq r5mp
%define widthq r6mp
%endif
%if %0 == 3; is 16 bit
    add    widthq, widthq ; <==== This new line doesn't compile on x86_32
%endif
    mov      endd, dword r7m
    add      topq, widthq
    add   bottomq, widthq
    add      dstq, widthq
    neg    widthq
%endmacro


Anyone have an idea ?
Otherwise, i can limit the 16 bit asm version to x86_64.

Martin


More information about the ffmpeg-devel mailing list