From nobody Wed Oct 23 18:30:44 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XYd045KmJz5ZX9P; Wed, 23 Oct 2024 18:30:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XYd043pjmz59R1; Wed, 23 Oct 2024 18:30:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729708244; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9dCqA/CVEg0CAo4I9lW9iptkPZUsAEIAd1XVJiiqYHg=; b=xJpgmJe/1yijCFxNG5qGHKVS6NXytDiWVjz78R0x4kZGDu6usLGZ2vf9GRvL74mUBLtAO9 o4sN+6JbwNICMZOmdthzRhEoZJbpOfRgt2nBx2xwHNZlcvJ3ZoxorDMnJInM+8Um5a2FwK aIhDw8WlDDXDouSgDzNegFoY06gFztL44Zp5Pv1esBSCeHb/+GvNjAfCcX9RATnYBBcq88 XX1Z5FABJCqprJkg1hzwvpZL0znNDhgFdL/Mo6O4gWjIShop6IaHkK27XWP5YaRiWh+Ag8 2TwjOlNIH/ElMawQ1HUWd2CcmZ8cr16pO7qpEiREcVKQt5GIKUbHgUdTFl9ttA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729708244; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9dCqA/CVEg0CAo4I9lW9iptkPZUsAEIAd1XVJiiqYHg=; b=o678ZE/7KRFTiy1pPQgG+dFxyFCSTklG85VNR/6XcAtVBV/S1+ahn13WT6FydbGRhK7jz1 qruvpJ07QFaK8id9EmUIN8Ea0rF/VeLiu1WKqPAZGkSoSsvSYlNlwUJcgubwtFn7zKbYxU /+nCL0eIleUEzZ0Jub9JySagf9z/bf696vHNaxq9xAalMQ7ruDxh24AFp2h/z4Mxie6ct/ 7lqdle3YrigYwSYtlvJ9cINinpED+F54BonFJbO72cWxsVFBIMxPkM0xOXgzGet6Sdfywk lgaBPM3PiUrVUovn7CMU1rKttVcrO+4JyBQM+192t+b3DNJmnXHsOsvFU81vkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1729708244; a=rsa-sha256; cv=none; b=oh0Z6JJwRlP48v4bpwsOH0V8f5Ss2+SwRMxlLeaUF0CLebLeDal69Mz3DIGgGc2Z8S52fl sugERay5RAIPT2oHvYFYDG+kxVk575H1d6ubr19FRSWIIqvNyorYwyV35RX5HQSTjHFKoy JaugNEwTWhPMD/NQGwfg/0cSed2eCuRQt9d3ND9SA//+F8ROVqqK85WmFbuOsskf5EsqBc wNmomlJ0PLt2a0PjN225F0BPkm4tdaoFS9OnFXqhZTQW683BsAf1U9X2lOlGMC7m/BXRAR eRkx8j3gKVH7P5qnQYFS0x8yxqWS4Ir4rHFOcFofFg96rHbBE/fJ7Tkco8N6YA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XYd043PRHz18RY; Wed, 23 Oct 2024 18:30:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 49NIUipw070867; Wed, 23 Oct 2024 18:30:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 49NIUiGg070864; Wed, 23 Oct 2024 18:30:44 GMT (envelope-from git) Date: Wed, 23 Oct 2024 18:30:44 GMT Message-Id: <202410231830.49NIUiGg070864@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dimitry Andric Subject: git: 072b5fb698ab - main - libcxx-compat: revert llvmorg-19-init-4003-g55357160d0e1: List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 072b5fb698abd61ab30bea70135758336b0de999 Auto-Submitted: auto-generated The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=072b5fb698abd61ab30bea70135758336b0de999 commit 072b5fb698abd61ab30bea70135758336b0de999 Author: Dimitry Andric AuthorDate: 2024-08-05 20:27:51 +0000 Commit: Dimitry Andric CommitDate: 2024-10-23 18:26:47 +0000 libcxx-compat: revert llvmorg-19-init-4003-g55357160d0e1: [libc++] Use GCC type traits builtins for remove_cv and remove_cvref (#81386) They have been added recently to GCC without support for mangling. This patch uses them in structs and adds aliases to these structs instead of the builtins directly. PR: 280562 MFC after: 1 month --- .../llvm-project/libcxx/include/__type_traits/remove_cv.h | 11 ++++++++--- .../libcxx/include/__type_traits/remove_cvref.h | 15 +++++---------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__type_traits/remove_cv.h b/contrib/llvm-project/libcxx/include/__type_traits/remove_cv.h index 8e1c04336432..c4bf612794bd 100644 --- a/contrib/llvm-project/libcxx/include/__type_traits/remove_cv.h +++ b/contrib/llvm-project/libcxx/include/__type_traits/remove_cv.h @@ -19,17 +19,22 @@ _LIBCPP_BEGIN_NAMESPACE_STD +#if __has_builtin(__remove_cv) && !defined(_LIBCPP_COMPILER_GCC) template struct remove_cv { using type _LIBCPP_NODEBUG = __remove_cv(_Tp); }; -#if defined(_LIBCPP_COMPILER_GCC) template -using __remove_cv_t = typename remove_cv<_Tp>::type; +using __remove_cv_t = __remove_cv(_Tp); #else template -using __remove_cv_t = __remove_cv(_Tp); +struct _LIBCPP_TEMPLATE_VIS remove_cv { + typedef __remove_volatile_t<__remove_const_t<_Tp> > type; +}; + +template +using __remove_cv_t = __remove_volatile_t<__remove_const_t<_Tp> >; #endif // __has_builtin(__remove_cv) #if _LIBCPP_STD_VER >= 14 diff --git a/contrib/llvm-project/libcxx/include/__type_traits/remove_cvref.h b/contrib/llvm-project/libcxx/include/__type_traits/remove_cvref.h index 55f894dbd1d8..e8e8745ab096 100644 --- a/contrib/llvm-project/libcxx/include/__type_traits/remove_cvref.h +++ b/contrib/llvm-project/libcxx/include/__type_traits/remove_cvref.h @@ -20,26 +20,21 @@ _LIBCPP_BEGIN_NAMESPACE_STD -#if defined(_LIBCPP_COMPILER_GCC) +#if __has_builtin(__remove_cvref) && !defined(_LIBCPP_COMPILER_GCC) template -struct __remove_cvref_gcc { - using type = __remove_cvref(_Tp); -}; - -template -using __remove_cvref_t _LIBCPP_NODEBUG = typename __remove_cvref_gcc<_Tp>::type; +using __remove_cvref_t _LIBCPP_NODEBUG = __remove_cvref(_Tp); #else template -using __remove_cvref_t _LIBCPP_NODEBUG = __remove_cvref(_Tp); +using __remove_cvref_t _LIBCPP_NODEBUG = __remove_cv_t<__libcpp_remove_reference_t<_Tp> >; #endif // __has_builtin(__remove_cvref) template -using __is_same_uncvref = _IsSame<__remove_cvref_t<_Tp>, __remove_cvref_t<_Up> >; +struct __is_same_uncvref : _IsSame<__remove_cvref_t<_Tp>, __remove_cvref_t<_Up> > {}; #if _LIBCPP_STD_VER >= 20 template struct remove_cvref { - using type _LIBCPP_NODEBUG = __remove_cvref(_Tp); + using type _LIBCPP_NODEBUG = __remove_cvref_t<_Tp>; }; template