From nobody Sun Dec 01 12:54:32 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 4Y1Rh84wYZz5fbNj; Sun, 01 Dec 2024 12:54:32 +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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y1Rh827P1z4PgQ; Sun, 1 Dec 2024 12:54:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733057672; 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=c3sPTk1uFVhkSInUryISIIgLUDpUlhcuWA7T35/Nwpw=; b=PRgAQSFOwoA24PdUm+UmRvY4hg1iNoDN+ZwcjinF9briYOppzs5C2PGZ8HaJ3B3pgeqMlf NM5pa/ZUTk1AhP0Btqbg2ZFcIkEp39BSdkX4mpd2SaWVHVtgpsAo2/reykBQNDmdxR0JKu riyVHsOBaYdX+wIF0O8FrAM9o+UvNqN+zYRzOcqXK1yRk/zF15DWL01FRlDOXHYlWhu0Fh Fh+EPupEbMGYCotIgQ6DbNgcqjUhVbQz3y3jMY0OTq48iQs5s+FtuF4GWRheusjRpzV/Ch m5p03fuCUZ3+joUag9NzIWcDMMsMbsHuHtMnUa1nkLitp/EfareruDb4bEqzyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733057672; 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=c3sPTk1uFVhkSInUryISIIgLUDpUlhcuWA7T35/Nwpw=; b=OLTcc1L+f7ofL53+B7JsjnLIgp4IcSBwv+XJSB4UhoFLRBpvNLGraON5SxjkhhIzKewKTy pcxszLCo+DWpP1of4Dm+9qzHwovjBPJzUzK8jTuCcUTSYOVZjZb82yPRtl23c4mZxwnzk9 bv+kXtSalvEijA3rBH3QAb58BxD6quOo670jtEki3yvvKPdd9AbIZmDnY3fa0+KkByImod Lyz4MpXILIqjG11vwAwqURvhdrwFHbB3/lKSf6oyWhj7DDTNbGDcmLCvecWI8crZjE6zSV LZQ3dBcH0EINAfaeS4fFziD7BhzN8r19uT5iT6LpH8InOsOgI+ZnWUSJy7zbXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733057672; a=rsa-sha256; cv=none; b=ZcQvj+NtgSdU11me6dHDUFFkVhKkh5f9lChSWodhxTHpYQPKnERwSwYFu6MFa3J/JrPisP 9RSv0Z1tPOCGjb+jRCOMAxU/TwWTosBf8gSxtCPPVLewney5hw9mO3hGmj68BsoocAnW4Y MTyUZXnekoKHEhqt4UKo/3OMSknf2Zq0yEQr6EV53j4JJc2ZMsImJFSAmOGEUp9xrwnRms 4d8mgRNUiSrimMcoPN1c4ZiR8mRlFDqFWXND0uXXCqicHCjl9p7tgYJtFidtsYCMehiAc5 /Rs7q9yaCwE9aRPXRbMQGVzIkWNH2mL5hpxouUxmlziRFogBrst9vc7WVJGuhA== 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 4Y1Rh81kp4ztQC; Sun, 1 Dec 2024 12:54:32 +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 4B1CsWNw094511; Sun, 1 Dec 2024 12:54:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B1CsWKk094508; Sun, 1 Dec 2024 12:54:32 GMT (envelope-from git) Date: Sun, 1 Dec 2024 12:54:32 GMT Message-Id: <202412011254.4B1CsWKk094508@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: 22a5f765704b - stable/13 - Apply workaround for building llvm-project with WITHOUT_LLVM_ASSERTIONS 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/stable/13 X-Git-Reftype: branch X-Git-Commit: 22a5f765704b96aa97074685d17a7216c6233c6e Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=22a5f765704b96aa97074685d17a7216c6233c6e commit 22a5f765704b96aa97074685d17a7216c6233c6e Author: Dimitry Andric AuthorDate: 2024-10-24 07:02:54 +0000 Commit: Dimitry Andric CommitDate: 2024-12-01 12:32:46 +0000 Apply workaround for building llvm-project with WITHOUT_LLVM_ASSERTIONS Some internal checking functions should only be declared when both NDEBUG and LLVM_ENABLE_ABI_BREAKING_CHECKS are undefined, otherwise you would get compile errors similar to: /usr/src/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:921:13: error: no member named 'VerifyDAGDivergence' in 'llvm::SelectionDAG' 921 | CurDAG->VerifyDAGDivergence(); | ~~~~~~ ^ Adjust the conditions for declaring and using these functions. This has also been reported upstream. Reported by: cy PR: 280562 MFC after: 1 month (cherry picked from commit a5b1eecbed07519c637095e3291b9cbd9748e823) --- .../llvm/include/llvm/CodeGen/SelectionDAG.h | 2 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 2 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 2 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 18 +++++++++--------- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAG.h b/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAG.h index 16ec65f2e7da..9c0220055f38 100644 --- a/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAG.h +++ b/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAG.h @@ -582,7 +582,7 @@ public: return Root; } -#ifndef NDEBUG +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS void VerifyDAGDivergence(); #endif diff --git a/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAGISel.h b/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAGISel.h index aa0efa5d9bf5..0c23e80a0ac5 100644 --- a/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAGISel.h +++ b/contrib/llvm-project/llvm/include/llvm/CodeGen/SelectionDAGISel.h @@ -55,7 +55,7 @@ public: AssumptionCache *AC = nullptr; GCFunctionInfo *GFI = nullptr; SSPLayoutInfo *SP = nullptr; -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS TargetTransformInfo *TTI = nullptr; #endif CodeGenOptLevel OptLevel; diff --git a/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 02d44cd36ae5..63213e276d22 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -11623,7 +11623,7 @@ void SelectionDAG::CreateTopologicalOrder(std::vector &Order) { } } -#ifndef NDEBUG +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS void SelectionDAG::VerifyDAGDivergence() { std::vector TopoOrder; CreateTopologicalOrder(TopoOrder); diff --git a/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index b961d3bb1fec..74bd1fdb887c 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -916,7 +916,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -936,7 +936,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -958,7 +958,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -982,7 +982,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -1000,7 +1000,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -1016,7 +1016,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -1036,7 +1036,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -1056,7 +1056,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif @@ -1076,7 +1076,7 @@ void SelectionDAGISel::CodeGenAndEmitDAG() { << "'\n"; CurDAG->dump()); -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if !defined(NDEBUG) && LLVM_ENABLE_ABI_BREAKING_CHECKS if (TTI->hasBranchDivergence()) CurDAG->VerifyDAGDivergence(); #endif