From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 9D50349238 for ; Thu, 11 Jul 2024 13:09:02 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E81F368DB03; Thu, 11 Jul 2024 16:08:59 +0300 (EEST) Received: from mail-lf1-f49.google.com (mail-lf1-f49.google.com [209.85.167.49]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3B78368DA7C for ; Thu, 11 Jul 2024 16:08:53 +0300 (EEST) Received: by mail-lf1-f49.google.com with SMTP id 2adb3069b0e04-52e9944764fso864183e87.3 for ; Thu, 11 Jul 2024 06:08:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=martin-st.20230601.gappssmtp.com; s=20230601; t=1720703332; x=1721308132; darn=ffmpeg.org; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to; bh=5GejpSrVjuaDvWcY3fVyg/joPBFEQ5RqLkj1ET6QLwQ=; b=ScbS+IbmaxWE7IwXPMmtlZU85b5gVWOGazkNFFbusdtRLuO10oiSOIC/0mmjeAYT1R gKgXDIMW55mi+X5giwCM6WD6S2H7Fh+AxFYBGub8nIxEE8QcBqXbL7DGshEN0BoMenc6 s75KskQFwkDMT5PMPn9vl1TftrhxtfV+LWbblBZ5FyOUrPUcW6n44CvOmven6sZdXuWg tuFuPHLD7vZ5LBybuIVrlIxbT99wlywO4hBFZZ0RwiG6q3GrswRJ8DKAhaRNFO9lHbD2 igBjTV3hngMvtEdByPzhSDRm5imnhWNiv93NHINsMqPN9ApFRbiUslm0Z/vaP64nwfnB iaAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720703332; x=1721308132; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=5GejpSrVjuaDvWcY3fVyg/joPBFEQ5RqLkj1ET6QLwQ=; b=k6sASZGOqK5NGK86JwJUHl4Qmc2N7uNy+tCplebfRif+cwCkQrBUTa6wEg9lZuMmSE NmChcSV1Ypw5sRiauxrb5dg+1UCmK8w/7CnldKHSHLMs9MnvP3Ah7nWodiiSC4+j0WUW EnJW5W36OF/Fj8Lswv2yUaKvASnJNXuqbMdJEkCrhcLaQ/OH/+hzTJMXkZjLQuSFJmBr h1g6NFbM+VA/f1qkz3kqQrEsQ1YMCERKCAyOFH9DVo53rPNOmbY9oMPTfTHHI1W6rrBP Zw853kJKs6VPoqORpJC6cKfOjprRz1YbztIjdxyvRlYb6nJJz29POsFCSwH6y5dD5NW3 Qd/A== X-Gm-Message-State: AOJu0YyApjyWam57hkWt4d2Q6QAHZNL0i6G8aCAoLhSaH6FEW/ZQx0NT 1pqe03aDvPOr5RWoXjaNBtSJU9shFTuflbyrWvs41WEKrY6+XdwB9RRO9VyyI/FHPy6zh8ntl++ f+w== X-Google-Smtp-Source: AGHT+IEH1jc4rklDA5p4bxVlKbKn3H2l3N+PNOkeWkpg49k/+wBWVkfx1mSBgdRuL5JsxOjVIZk7jw== X-Received: by 2002:a05:6512:312e:b0:52c:9f24:a253 with SMTP id 2adb3069b0e04-52eb99d273emr4205353e87.64.1720703331997; Thu, 11 Jul 2024 06:08:51 -0700 (PDT) Received: from tunnel335574-pt.tunnel.tserv24.sto1.ipv6.he.net (tunnel335574-pt.tunnel.tserv24.sto1.ipv6.he.net. [2001:470:27:11::2]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-52eb8e496d7sm986513e87.80.2024.07.11.06.08.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 11 Jul 2024 06:08:51 -0700 (PDT) Date: Thu, 11 Jul 2024 16:08:48 +0300 (EEST) From: =?ISO-8859-15?Q?Martin_Storsj=F6?= To: ffmpeg-devel@ffmpeg.org In-Reply-To: <20240710162641.7B606412682@natalya.videolan.org> Message-ID: References: <20240710162641.7B606412682@natalya.videolan.org> MIME-Version: 1.0 Subject: Re: [FFmpeg-devel] [FFmpeg-cvslog] x86/intreadwrite: use intrinsics instead of inline asm for AV_COPY128 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: ffmpeg-cvslog@ffmpeg.org Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On Wed, 10 Jul 2024, James Almer wrote: > ffmpeg | branch: master | James Almer | Wed Jul 10 13:00:20 2024 -0300| [bd1bcb07e0f29c135103a402d71b343a09ad1690] | committer: James Almer > > x86/intreadwrite: use intrinsics instead of inline asm for AV_COPY128 > > This has the benefit of removing any SSE -> AVX penalty that may happen when > the compiler emits VEX encoded instructions. > > Signed-off-by: James Almer > >> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=bd1bcb07e0f29c135103a402d71b343a09ad1690 > --- > > configure | 5 ++++- > libavutil/x86/intreadwrite.h | 20 +++++++------------- > 2 files changed, 11 insertions(+), 14 deletions(-) > > diff --git a/configure b/configure > index f84fefeaab..7151ed1de3 100755 > --- a/configure > +++ b/configure > @@ -2314,6 +2314,7 @@ HEADERS_LIST=" > > INTRINSICS_LIST=" > intrinsics_neon > + intrinsics_sse > intrinsics_sse2 > " > > @@ -2744,7 +2745,8 @@ armv6t2_deps="arm" > armv8_deps="aarch64" > neon_deps_any="aarch64 arm" > intrinsics_neon_deps="neon" > -intrinsics_sse2_deps="sse2" > +intrinsics_sse_deps="sse" > +intrinsics_sse2_deps="sse2 intrinsics_sse" > vfp_deps="arm" > vfpv3_deps="vfp" > setend_deps="arm" > @@ -6446,6 +6448,7 @@ elif enabled loongarch; then > fi > > check_cc intrinsics_neon arm_neon.h "int16x8_t test = vdupq_n_s16(0)" > +check_cc intrinsics_sse immintrin.h "__m128 test = _mm_setzero_ps()" > check_cc intrinsics_sse2 emmintrin.h "__m128i test = _mm_setzero_si128()" > > check_ldflags -Wl,--as-needed > diff --git a/libavutil/x86/intreadwrite.h b/libavutil/x86/intreadwrite.h > index 9bbef00dba..6546eb016c 100644 > --- a/libavutil/x86/intreadwrite.h > +++ b/libavutil/x86/intreadwrite.h > @@ -22,29 +22,25 @@ > #define AVUTIL_X86_INTREADWRITE_H > > #include > +#if HAVE_INTRINSICS_SSE > +#include > +#endif This change seems to have broken builds for x86 with Clang 16 or newer. (Clang 15 and lower seems to be fine.) See e.g. http://fate.ffmpeg.org/log.cgi?slot=i686-mingw32-clang-trunk&time=20240711035948&log=compile for an example of the error. The issue is that a clang internal intrinsics header contains "_mm_comige_sh(__m128h A,", i.e. a parameter with the name "A" (which toolchain provided headers shouldn't use). This clashes with libavcodec/huffuyv.h, which has a "#define A 3". This is obviously a Clang intrinsics header bug, but we can't fix the existing Clang 16-18 releases that are out there, so I guess what we can do is change our "define A" to something more elaborate. (IIRC there are some similar issues with names with ncurses and/or android headers too.) // Martin _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".