[libav-devel] [PATCH 7/7] configure: Drop unused helper function test_cflags_cpp()

2018-03-20 Thread Diego Biurrun
---
 configure | 13 -
 1 file changed, 13 deletions(-)

diff --git a/configure b/configure
index 830f754412..6689858d57 100755
--- a/configure
+++ b/configure
@@ -1042,19 +1042,6 @@ check_cpp_condition(){
 test_cpp_condition "$@" && enable $name
 }
 
-test_cflags_cpp(){
-log test_cflags_cpp "$@"
-flags=$1
-condition=$2
-shift 2
-set -- $($cflags_filter "$flags")
-test_cpp "$@" 

[libav-devel] [PATCH 4/7] configure: Use indirection for -o assembler flag also for x86asm

2018-03-20 Thread Diego Biurrun
---
 configure | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/configure b/configure
index dbc5759df4..e3c5dcae1e 100755
--- a/configure
+++ b/configure
@@ -808,12 +808,16 @@ test_as(){
 test_cmd $as $CPPFLAGS $ASFLAGS "$@" $AS_C $(as_o $TMPO) $TMPS
 }
 
+x86asm_o(){
+eval printf '%s\\n' $X86ASM_O
+}
+
 test_x86asm(){
 log test_x86asm "$@"
 echo "$1" > $TMPASM
 log_file $TMPASM
 shift 1
-test_cmd $x86asmexe $X86ASMFLAGS "$@" -o $TMPO $TMPASM
+test_cmd $x86asmexe $X86ASMFLAGS "$@" $(x86asm_o $TMPO) $TMPASM
 }
 
 check_cmd(){
-- 
2.11.0

___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

[libav-devel] [PATCH 2/7] configure: Add check_x86asm() helper function to simplify some expressions

2018-03-20 Thread Diego Biurrun
---
 configure | 32 
 1 file changed, 20 insertions(+), 12 deletions(-)

diff --git a/configure b/configure
index d8c3b555cc..ce0d791c1b 100755
--- a/configure
+++ b/configure
@@ -808,6 +808,14 @@ test_as(){
 test_cmd $as $CPPFLAGS $ASFLAGS "$@" $AS_C $(as_o $TMPO) $TMPS
 }
 
+test_x86asm(){
+log test_x86asm "$@"
+echo "$1" > $TMPS
+log_file $TMPS
+shift 1
+test_cmd $x86asmexe $X86ASMFLAGS "$@" -o $TMPO $TMPS
+}
+
 check_cmd(){
 log check_cmd "$@"
 cmd=$1
@@ -844,12 +852,12 @@ check_insn(){
 check_as ${1}_external "$2"
 }
 
-test_x86asm(){
-log test_x86asm "$@"
-echo "$1" > $TMPS
-log_file $TMPS
-shift 1
-test_cmd $x86asmexe $X86ASMFLAGS "$@" -o $TMPO $TMPS
+check_x86asm(){
+log check_x86asm "$@"
+name=$1
+shift
+disable $name
+test_x86asm "$@" && enable $name
 }
 
 ld_o(){
@@ -4421,7 +4429,7 @@ EOF
 X86ASMDEP='$(DEPX86ASM) $(X86ASMFLAGS) -M $(X86ASM_O) $< > 
$(@:.o=.d)'
 X86ASM_DEPFLAGS=
 fi
-test_x86asm "movbe ecx, [5]" && enable x86asm
+check_x86asm x86asm "movbe ecx, [5]"
 }
 
 if ! disabled_any asm mmx x86asm; then
@@ -4437,11 +4445,11 @@ EOF
 elf*) enabled debug && append X86ASMFLAGS $x86asm_debug ;;
 esac
 
-test_x86asm "vextracti128 xmm0, ymm0, 0"  || disable avx2_external
-test_x86asm "vpmacsdd xmm0, xmm1, xmm2, xmm3" || disable xop_external
-test_x86asm "vfmadd132ps ymm0, ymm1, ymm2"|| disable fma3_external
-test_x86asm "vfmaddps ymm0, ymm1, ymm2, ymm3" || disable fma4_external
-test_x86asm "CPU amdnop"  || disable cpunop
+check_x86asm avx2_external "vextracti128 xmm0, ymm0, 0"
+check_x86asm  xop_external "vpmacsdd xmm0, xmm1, xmm2, xmm3"
+check_x86asm fma3_external "vfmadd132ps ymm0, ymm1, ymm2"
+check_x86asm fma4_external "vfmaddps ymm0, ymm1, ymm2, ymm3"
+check_x86asm cpunop"CPU amdnop"
 fi
 
 case "$cpu" in
-- 
2.11.0

___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

[libav-devel] [PATCH 5/7] configure: Simplify vararg check

2018-03-20 Thread Diego Biurrun
---
 configure | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/configure b/configure
index e3c5dcae1e..9257b94631 100755
--- a/configure
+++ b/configure
@@ -4240,12 +4240,11 @@ od -t x1 $TMPO | grep -q '42 *49 *47 *45' && enable 
bigendian
 check_gas() {
 log "check_gas using '$as' as AS"
 # :vararg is used on aarch64, arm and ppc altivec
-test_as 

[libav-devel] [PATCH 1/7] configure: Document available options for the --toolchain parameter

2018-03-20 Thread Diego Biurrun
---
 configure | 4 
 1 file changed, 4 insertions(+)

diff --git a/configure b/configure
index 78a2065208..d8c3b555cc 100755
--- a/configure
+++ b/configure
@@ -260,6 +260,10 @@ Toolchain options:
   --target-path=DIRpath to view of build directory on target
   --target-samples=DIR path to samples directory on target
   --toolchain=NAME set tool defaults according to NAME
+   (gcc-asan, clang-asan, gcc-msan, clang-msan,
+   gcc-tsan, clang-tsan, gcc-usan, clang-usan,
+   valgrind-massif, valgrind-memcheck,
+   msvc, icl, gcov, llvm-cov, hardened)
   --nm=NM  use nm tool
   --ar=AR  use archive tool AR [$ar_default]
   --as=AS  use assembler AS [$as_default]
-- 
2.11.0

___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

[libav-devel] [PATCH 6/7] configure: Simplify vfp_args check

2018-03-20 Thread Diego Biurrun
---
 configure | 5 +
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/configure b/configure
index 9257b94631..830f754412 100755
--- a/configure
+++ b/configure
@@ -4303,10 +4303,7 @@ elif enabled arm; then
 elif ! test_cpp_condition stddef.h "defined __ARM_PCS || defined 
__SOFTFP__" && [ $target_os != darwin ]; then
 case "${cross_prefix:-$cc}" in
 *hardfloat*) enable vfp_args; fpabi=vfp ;;
-*) check_ld vfp_args 

[libav-devel] [PATCH 3/7] configure: Use a more sensible suffix for x86 assembly tempfiles

2018-03-20 Thread Diego Biurrun
---
 configure | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/configure b/configure
index ce0d791c1b..dbc5759df4 100755
--- a/configure
+++ b/configure
@@ -810,10 +810,10 @@ test_as(){
 
 test_x86asm(){
 log test_x86asm "$@"
-echo "$1" > $TMPS
-log_file $TMPS
+echo "$1" > $TMPASM
+log_file $TMPASM
 shift 1
-test_cmd $x86asmexe $X86ASMFLAGS "$@" -o $TMPO $TMPS
+test_cmd $x86asmexe $X86ASMFLAGS "$@" -o $TMPO $TMPASM
 }
 
 check_cmd(){
-- 
2.11.0

___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

[libav-devel] the big configure cleanup (act VII)

2018-03-20 Thread Diego Biurrun
Today: a bit of documentation, x86asm simplicity and consistency, other
simplifications and cruft cleanup.
___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Re: [libav-devel] [PATCH 2/2] lavu/hwcontext_qsv: Add support for pix_fmt RGB32.

2018-03-20 Thread Li, Zhong
> From: libav-devel [mailto:libav-devel-boun...@libav.org] On Behalf Of
> Maxym Dmytrychenko
> Sent: Monday, March 19, 2018 5:56 PM
> To: libav development 
> Cc: Liu, ChaoX A 
> Subject: Re: [libav-devel] [PATCH 2/2] lavu/hwcontext_qsv: Add support for
> pix_fmt RGB32.
> 
> indentation can be adjusted ,

It is to support RGB format overlay (e.g. lena-rgba.png). 

> AV_PIX_FMT_YUYV422  - we add it but dont use?

If the overlay input movie format is 4:2:2, it will be used. But I prefer to 
remove it in this patch to make it clearer. 
How do you think?
___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Re: [libav-devel] [PATCH 1/2] lavc/qsvdec: set complete_frame flags for non-interlaced frames.

2018-03-20 Thread Li, Zhong
> From: libav-devel [mailto:libav-devel-boun...@libav.org] On Behalf Of
> Maxym Dmytrychenko
> Sent: Monday, March 19, 2018 5:59 PM
> To: libav development 
> Subject: Re: [libav-devel] [PATCH 1/2] lavc/qsvdec: set complete_frame flags
> for non-interlaced frames.
> 
>  MFX_BITSTREAM_COMPLETE_FRAME support can be added as a param
> or can be only such if() conditions sufficient for all cases and streams ?

Yes, I think this flag is a common flag for all codecs (Not only for VC1.). 
According to the comments of MFX_BITSTREAM_COMPLETE_FRAME and grep it in MSDK 
sample_utils.cpp.
I have run the full decoding test internally for all codecs. 
Everything is ok but expect h264. Some interlace videos is treated as 
AV_FIELD_UNKNOWN(see 
https://github.com/libav/libav/blob/master/libavcodec/h264_parser.c#L463 ) thus 
making some h264 clips decoding failed.
I will update this patch. Thanks for your review!
___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel