From nobody Mon Apr 15 04:02:02 2024 X-Original-To: dev-commits-src-branches@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 4VHtlv0Vs7z5HgJ0; Mon, 15 Apr 2024 04:02:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VHtlt4bDJz4Skh; Mon, 15 Apr 2024 04:02:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153722; 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=0jX4CJrczXkMH4KhBGCwxCzW3APabeSaUmqeCf9/W6w=; b=b0F8Y4ms6jvsfCWG7Ndc5guFOm8mof0lwW7UshrvzqF7WSoK658oaVVwNp7vF6IA7QF0oh Lmq+zJIlxMivW7GK0UoWKO0fXk4JLhn7X/URe6dJoqPSWtFY++nMxYuq9lKBfRUoFm51hV MpdaFRf2oRxy2Dapn+GOa1yBKoBfAYs+91mdglbFEKpuDV8f7OKI8y46EiDOfvXZlfPEak C1I9xA7IMDBCc2DWetOsC2HN2XXKDkxllO9HhDtJNa38cjdbM0502hasBywssfTofJ8mm2 y+utxkNJGfiLOEfQgbx04SC1j9JXaI2r26Nk5pjNX37xOOvZNPnN2gA5Y1YX3w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713153722; a=rsa-sha256; cv=none; b=DBk1+LsnvIQ8hrYtbs9coNrMPPAPUKeIINPbtEQyL+a2sIrjeT67xrK3R8Uj/pSasxN5U/ twQOrzt7pc+DaX/AJif5SgUmchA8YA86qZ+i/434VZPDIXhuzCqOwb9lCxr1qQwAjTkkN8 NZl2IdwZ6Es4KBc6ZzrQweSELv1osic58PkoA8R898T/uME5AXaq/zhB2VXJX57b5uZjiM noMLypyAep/p1lwW7W90wZRoRn0CF+jl59mMkFMAf/Jo2t9c4NyhuK/pTQOTDpFAE+RTd+ vR+queQ/WkQDEMx+tP+3AprytFaxVnzNThORbR5dsSiFnL5dmfW+kUkORG9udg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153722; 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=0jX4CJrczXkMH4KhBGCwxCzW3APabeSaUmqeCf9/W6w=; b=iEiK0dBXGfSz5sZ/CaxnZnQ4q1TCo5xQYnO9/yzu70AUFwCXjVjzPzoejv3DTcdXhoeDHf 7OcbbwUJugcdv6G2yYb9RJydi+BkLSOADCP/3NCx2/DBhXfK4Q86he4vFWfp2QGFPIkM7G 1vR6v/xI8X7Tk1Ia6qGKzOJ9dPMM3NgXcKova06OEVWPyS36c5SnsyBw4nm4bIh8B19INK g8hbsmbfAUZ5UKqa7JfCdRnGhZFDGhZVSCDrofl2Mrsi0eufIYmLGUSEbCwfxFEjYMTTnN sPw5OaRxIyKxtx314OI/WnyiAEwUfrkicuxObMjjqAf09UgzK4pM+SY3Etz99A== 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 4VHtlt48zgzlKh; Mon, 15 Apr 2024 04:02:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43F422dW050511; Mon, 15 Apr 2024 04:02:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43F422Mi050508; Mon, 15 Apr 2024 04:02:02 GMT (envelope-from git) Date: Mon, 15 Apr 2024 04:02:02 GMT Message-Id: <202404150402.43F422Mi050508@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 4d65728d55a7 - stable/14 - ethernet: Fix logging of frame length List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4d65728d55a754f2529ca2cfb87c9588146563d0 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=4d65728d55a754f2529ca2cfb87c9588146563d0 commit 4d65728d55a754f2529ca2cfb87c9588146563d0 Author: Zhenlei Huang AuthorDate: 2024-04-08 16:44:33 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-15 04:00:37 +0000 ethernet: Fix logging of frame length Both the mbuf length and the total packet length are signed. While here, update a stall comment to reflect the current practice. Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D42390 (cherry picked from commit e7102929bf4fea4bf22855d2d6031edf6c413608) --- sys/net/if_ethersubr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index 4a726831a3db..4d82bb0cfdca 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -536,10 +536,10 @@ ether_input_internal(struct ifnet *ifp, struct mbuf *m) return; } #endif - if (m->m_len < ETHER_HDR_LEN) { - /* XXX maybe should pullup? */ + if (__predict_false(m->m_len < ETHER_HDR_LEN)) { + /* Drivers should pullup and ensure the mbuf is valid */ if_printf(ifp, "discard frame w/o leading ethernet " - "header (len %u pkt len %u)\n", + "header (len %d pkt len %d)\n", m->m_len, m->m_pkthdr.len); if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); m_freem(m); From nobody Mon Apr 15 04:02:03 2024 X-Original-To: dev-commits-src-branches@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 4VHtlw0r8Dz5HgG4; Mon, 15 Apr 2024 04:02:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VHtlv5Qtjz4ShP; Mon, 15 Apr 2024 04:02:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153723; 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=9PmF6zFFXlmrOyzi/yGQtOeMDoaTsLs0Xf6TniYhPF0=; b=QWczVDXTFcAE2NIg+cQnMyAfM6cb0R6nV6OtJfQcY0d30wR+HF7+nA55Gga9d9XIq9scFI Cu0ZC6hSnaVj7o1dG/C50g8sjAwFvekYQb3WOT0YitybTK+Z70wl6Ql4YUeXBYQz+tCCsz CgVysgRwb03Ck/LAw7WIKk7J2eTJrNoh8l/+WuSjySCeI5P9i5Y/mh/fAgFt7Sv4hEMbSe rWF42LQu5w984ITAXLu+DeJKwL7O0FWhDJMHC/A1deIxmrpKUP1IT+GzejMVfLCUXxTKCM 96MnO93+XGzF5twbch2sOmIxkDavDCv11WIxBKR4pv8bfVGcsM1f0XPi6zHEpA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713153723; a=rsa-sha256; cv=none; b=WI63xp/D1F+AxJFklVcT1ik+dmVZW3vmoHRCJPAah32dAVl7UdnS3rvdWghg+XV3Qksr++ 5/GCYz8Qx1e47e/2ZMkWPVicoUY7dbvFQazvaFrQULerSy/9856RBjokeg4g56dq7QTuEG HXr5M9y/AT8Ht8e4nbervhuq0c2KZJLJ3QX/NEu0fsaviOFljek0+yCyFLGQotHrnxdRmj Yxdof+WwOefp+S/WyEXQfYy4hmLQ5Q7CPM1w+gPIlrcCHSTHKxIzMqozeEITiR+rJPyMB1 A8yqRUASL94LsTECQYoGOA/896Om48PG8qmBEq+2AbY34rn+gWTS3OM24mLj+w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153723; 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=9PmF6zFFXlmrOyzi/yGQtOeMDoaTsLs0Xf6TniYhPF0=; b=FDcPHE/IcEkbF8qrhnzVCk3mPax4WsD4M4hLgoELgLjQFzhWpQR+a+YsXvwcHp7sfAKXbR odoBYcv/YyDB9ktfhuv9b9U46n5P6sPyOaMSBixAyTd8GuTJIwUUAkePfBdm6jQgugdDJD 0GU3n1bJ3uBIQpKxkzjDIH5H/39Qu4cGUNDdk7mUiQheqZMEUc01jxK79ylMbAq9tW/r1f 1TwHBf/xzx9lNmAoVWzWGbz69f0Rc073v1V24IAXnaZssJa8c+HwONEoPuu1+jbgZoQokl jdBOgt8YGTII4ua7O/oDthK0GtPhyo3fQFHttlaN2FkTDG3kzVTs4oEwW9srEA== 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 4VHtlv52hdzl28; Mon, 15 Apr 2024 04:02:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43F423rK050558; Mon, 15 Apr 2024 04:02:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43F423AK050555; Mon, 15 Apr 2024 04:02:03 GMT (envelope-from git) Date: Mon, 15 Apr 2024 04:02:03 GMT Message-Id: <202404150402.43F423AK050555@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 800bd7da4c20 - stable/14 - debugnet: Fix logging of frame length List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 800bd7da4c20ff0ad7b24879c03b1add4b583da7 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=800bd7da4c20ff0ad7b24879c03b1add4b583da7 commit 800bd7da4c20ff0ad7b24879c03b1add4b583da7 Author: Zhenlei Huang AuthorDate: 2024-04-08 16:47:06 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-15 04:00:50 +0000 debugnet: Fix logging of frame length MFC after: 1 week (cherry picked from commit 6fe4d8395bc5ec51a5ec68b5f1176b4710676b7c) --- sys/net/debugnet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/debugnet.c b/sys/net/debugnet.c index c54c1a3904ec..c6f57ec84618 100644 --- a/sys/net/debugnet.c +++ b/sys/net/debugnet.c @@ -566,7 +566,7 @@ debugnet_input_one(struct ifnet *ifp, struct mbuf *m) } if (m->m_len < ETHER_HDR_LEN) { DNETDEBUG_IF(ifp, - "discard frame without leading eth header (len %u pktlen %u)\n", + "discard frame without leading eth header (len %d pktlen %d)\n", m->m_len, m->m_pkthdr.len); goto done; } From nobody Mon Apr 15 04:03:37 2024 X-Original-To: dev-commits-src-branches@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 4VHtnk1crwz5HgPS; Mon, 15 Apr 2024 04:03:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VHtnk15F2z4TNQ; Mon, 15 Apr 2024 04:03:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153818; 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=J5Gi5o8X4JUP9vHHD7ISZxYT8pvN7Ky5giwMmgPp3LY=; b=SFCG8I/FlXYB96slQO61jdVvCUvLpz12NTgMefrDybea5B8vD2FCEu6ko1OY+DB392bu99 Gy7bT9J8htTDV8n+Bnild8c731CXFXpdAP+FjklIhAQgIFE4c7lbhBjNU6LO3sUSg73Qjk NeKr8dzWjwPAQ8pUq/TyWOqhN6w3JnYZHJrgOR8vcfNSnlbRmpCCZ5nMnpfZ93R24n6ugy yemdbmP+vd8lNorrnNZN2qjqSyIXodsUKytOf690MaWPLcPCF4+rlBCyJoOmWHWVVWZiP3 cuifHWu76q3ZcOMrmi3+cA1Z9Boyk71YAzJP4D2sR/Kz+jMlKedc2gzdnLNdJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713153818; a=rsa-sha256; cv=none; b=Ty/iOW8IfCkwyFH5Q74E3lkfYRwLvDyZ6J6HMREIV41inqnSC/qQY2OzCPkow+TPG2ZRoX DPcz3D6tdawpJ/Nm5SPTztWDn0XhCbvU2uje373IE86NMR4il2GTt4UiWHQqEA2omgPu53 ewU1Ob1c0Tw9d0SwsBBmqMu9rw/BT7Tjkg84Hcb7VPBpZtrR8dBLW1qZuDvWsEjkdbDQG1 GSIZsolSbrrdgKUAwf9gB5efNLwD2hf4u0H10dk/O+UMg1+t6aiO8ZwwtJMy++WU6E6LTl 9j8PLqoCJ88elZKk/oVTrHmAOOBtMqQdCtZH8CZKCd9Zh3Ol6BzSY7J21rUqeA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153818; 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=J5Gi5o8X4JUP9vHHD7ISZxYT8pvN7Ky5giwMmgPp3LY=; b=SIeGn77QuxLU9NnfDkUO6fDwDtv+d6bzG1FmSTs7Ag3hwmGkmvlc2THkMXNWFXFFVpYnv3 1HPK0/xB5U1PRUAkwxKQOrbL1xRfZ9EhmfO+8RoC0QmS0KMcdPjvaWSyZcqrZwltHaGpat k+fvOTce2Mhg3w1SdUpt266zD3HdYhp1PxLQU32N57Mls6mzYELOA+59WGHDFQUFB9FEy+ r2hakvHTzNDjPHKmDKt7i0HWCVFeKVcbiIbqUibeSpcTz7zszTnsXy65BsaBvXG+0qLlyF pnP3ljhiD7Yvw4pTybbUGa5XXXXCQVvs4rustJD0NksU2KSgeOm5gfkygevy0g== 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 4VHtnk0h0lzlKx; Mon, 15 Apr 2024 04:03:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43F43bbr051828; Mon, 15 Apr 2024 04:03:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43F43bp3051825; Mon, 15 Apr 2024 04:03:37 GMT (envelope-from git) Date: Mon, 15 Apr 2024 04:03:37 GMT Message-Id: <202404150403.43F43bp3051825@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 65212656f845 - stable/13 - ethernet: Fix logging of frame length List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 65212656f845088417881219b5bd0f6355dd50fe Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=65212656f845088417881219b5bd0f6355dd50fe commit 65212656f845088417881219b5bd0f6355dd50fe Author: Zhenlei Huang AuthorDate: 2024-04-08 16:44:33 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-15 04:02:57 +0000 ethernet: Fix logging of frame length Both the mbuf length and the total packet length are signed. While here, update a stall comment to reflect the current practice. Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D42390 (cherry picked from commit e7102929bf4fea4bf22855d2d6031edf6c413608) (cherry picked from commit 4d65728d55a754f2529ca2cfb87c9588146563d0) --- sys/net/if_ethersubr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index b361af2fe428..c0b2b4f3f448 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -529,10 +529,10 @@ ether_input_internal(struct ifnet *ifp, struct mbuf *m) return; } #endif - if (m->m_len < ETHER_HDR_LEN) { - /* XXX maybe should pullup? */ + if (__predict_false(m->m_len < ETHER_HDR_LEN)) { + /* Drivers should pullup and ensure the mbuf is valid */ if_printf(ifp, "discard frame w/o leading ethernet " - "header (len %u pkt len %u)\n", + "header (len %d pkt len %d)\n", m->m_len, m->m_pkthdr.len); if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); m_freem(m); From nobody Mon Apr 15 04:03:39 2024 X-Original-To: dev-commits-src-branches@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 4VHtnl2Zdnz5Hg2f; Mon, 15 Apr 2024 04:03:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VHtnl25Phz4TFh; Mon, 15 Apr 2024 04:03:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153819; 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=7ZXJ0loHR1fdGbfXh/MrJ9+uZaZ3pV9fRqMwMPwg1es=; b=WNtchfqbvstjtBF29MBKtcg8b/rQQAOkj2/B8H0mY4fNteEJNinHLPlSU0mzZH2Y+n6CEM f1ziIl+3wK/HI3AM1BNiXIP8Yp89mNydmXArymIctiupsqUmwHWH/I+BIV3birtMYCzG8n uLP8XKisT2CK0dJeXfVm2gCGVulvq5+cxq3Fg1ZPIp3aEMGXlM3n7dpK6h1OIK63HIv252 T8jOx0i01LeIV2wBVW2bAw18t5LsnxPmW4A/WtYdxdUO48qDOyZG34/2cHQOZf2vjUj+R3 2sVhgc5vKjsuicq1hu/uT/uU9d1b3MBD2jLWwr7nm4UtMLVVHPHZKsk1h9z74g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713153819; a=rsa-sha256; cv=none; b=gCqSytP8Y5otFPyXwpfrdM9FXrYdOlAxHveaKOdVRmDmARYOoss+//UbQJiPTlZjn9LB81 crmCPBoJ5uoARh4eW59Vboc4gfQEugOvae8YH9+N6fO9lXG8ZAiUjenQDw4pVtT23rYyrG UD8ZpwLKoI0UJW4jhwl+568sWghshMZFH+bGG4FJBd5ZyQLUM1w1JICXIy5Utv2MGeA3En nx8RyZbm3f29KuUzdypN+1BjeXUDJLdS9Cj7g2EePNS2dbshubxgSbeKM4N1cbQV3B7b9e cerm2nvQjDtUGT45CktneoFdsHlxPuHbkt2rM/JiYrC5IfaI5xaKlCjqYQL9RQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713153819; 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=7ZXJ0loHR1fdGbfXh/MrJ9+uZaZ3pV9fRqMwMPwg1es=; b=pRVp5SkoqDdi9kbjkzT1isSM/l//eYUFtug2QxEPMTdUGdO9KiAJWEQbzoO7BNODYihDqD C8QOScxBPBUyiDpirD/WeIbIiDDzBHUIcaDCPCL/6Ft3yo03oXSLdiC/7F7AUoyaK06HF9 PQ6j4xEue+9S3rQHb4L9sYuGUJ7qqkQVrgjAS3McVHF/2EiJWtVl5/gamGb794KM0DrnIO cltQfMnKPb2kAKfOSnP3DPMdCre2g33683I8PBOCp1Oupdpc4ih1E8Uz7Sf1uvOzy0HqVU V+BczSdW0UX/493dQadjnJwmBElvhqzkIzW1Qkn2PC21TkrWqV+9RCQ1id/Yzg== 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 4VHtnl1hlbzl2J; Mon, 15 Apr 2024 04:03:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43F43dqN051873; Mon, 15 Apr 2024 04:03:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43F43dnc051870; Mon, 15 Apr 2024 04:03:39 GMT (envelope-from git) Date: Mon, 15 Apr 2024 04:03:39 GMT Message-Id: <202404150403.43F43dnc051870@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 41e4389a3d0d - stable/13 - debugnet: Fix logging of frame length List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 41e4389a3d0df7c31fbe2c80e2f00219c1b5bd6b Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=41e4389a3d0df7c31fbe2c80e2f00219c1b5bd6b commit 41e4389a3d0df7c31fbe2c80e2f00219c1b5bd6b Author: Zhenlei Huang AuthorDate: 2024-04-08 16:47:06 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-15 04:03:06 +0000 debugnet: Fix logging of frame length MFC after: 1 week (cherry picked from commit 6fe4d8395bc5ec51a5ec68b5f1176b4710676b7c) (cherry picked from commit 800bd7da4c20ff0ad7b24879c03b1add4b583da7) --- sys/net/debugnet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/debugnet.c b/sys/net/debugnet.c index 30cfb5ab141a..6336b9127cc1 100644 --- a/sys/net/debugnet.c +++ b/sys/net/debugnet.c @@ -534,7 +534,7 @@ debugnet_input_one(struct ifnet *ifp, struct mbuf *m) } if (m->m_len < ETHER_HDR_LEN) { DNETDEBUG_IF(ifp, - "discard frame without leading eth header (len %u pktlen %u)\n", + "discard frame without leading eth header (len %d pktlen %d)\n", m->m_len, m->m_pkthdr.len); goto done; } From nobody Mon Apr 15 10:57:02 2024 X-Original-To: dev-commits-src-branches@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 4VJ3yl1C8sz5G5Nt; Mon, 15 Apr 2024 10:57:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ3yl0kscz46Cr; Mon, 15 Apr 2024 10:57:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713178623; 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=5/LCI0SWDDE2PfvhanweaZYFYMAfzQrkPIu3qq76zes=; b=Lz5v3wA4krR+v/oxkmNPg61HzqvYBPzrHPJSgInTUtBbCY6Hjtg5Oyw4CmEcrJmqLRlSKK d1p91V5UH9VFg0i3FNIe5R+TAOmHfHn/vyFn1ZoH1qkhMrwzdQlkMzy0wuBorexT5mJNFA Q/7RjmxOPmKMzOiNMreO01Z2eX5ssHWceC7CfBotPhv5glcqZa/TJMI8rrbCBRXMC7RDAk ud6PTmvrB/pMBPHtceAEOYEy3bJCVE02bIRTxi5bSajXn12n5iReLfVWGYkcfW75967WkR aTPkrfk3U0uYYGP705rEAd9Yai9agtCAcdfCI4rhEHhWzQKU7dvpNbibk2VduQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713178623; a=rsa-sha256; cv=none; b=YHeXXUsUcoqiqyLV4A6VwG1XTS2gWX5dTkvItWlkAn0u9uoi+pbRSvJwUHEiOFrAnbWTUA XNx2xknUngaL9kUyspKqBmJAml+xHqNBiV9LDLQt75a05pYFsrcRxLlNw6V7q8kfVHXEsS /JAE3XS2tDEVX02N3/HXjMu2pznAMrfyVvNDUAa05KnNEY7m0NCtMWTDBGtFfdHuQDYcdZ mQZ0mU2WAjAJa+MDzvwFRMrlPqMBMcK52UzS/IOGLmxi3q8BNat9TBEqv1RqTrYPFx8EKi 4sVRrsVI1haGqK82DqiFKmI6uhpY55YEIWst2XyBKn6HewfwxN8qFxIspuZ4TQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713178623; 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=5/LCI0SWDDE2PfvhanweaZYFYMAfzQrkPIu3qq76zes=; b=TuRZ7myvvmYgzpSWoAw7q+1KvWFwqfI6b08IrRRoaPFqgu/4XN5PfHTmsvU39RF/EBO2sW OrMCZKlzveoswD+lmXNVyGhpPt74IZlEyKlX13yk0APq7RE837S/UI6Bg1fJUAVVCMcCVo Seghn/UaAycG1KzL9/QW4Angkrnn/7KBbXdzlxqFYh5xSQ0cMLMcp7zpwr37+322ISSzLy rY7Tn5oLH44gaIB5pK/8sgGaAXShIjNnY1/2WeO1+CVy/NgHMbU9XVxF0FHA9+9u8Vco6i q2uKs3ywmReReJ+qTkQ+Ox9kbk4nIlf7kyrqz5RPUH1dslCTxd5OgU7Ke3tjSQ== 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 4VJ3yl0LSCzx4Q; Mon, 15 Apr 2024 10:57:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FAv2gK047187; Mon, 15 Apr 2024 10:57:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FAv26W047184; Mon, 15 Apr 2024 10:57:02 GMT (envelope-from git) Date: Mon, 15 Apr 2024 10:57:02 GMT Message-Id: <202404151057.43FAv26W047184@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 43e0ae562921 - stable/14 - sys/queue.h: Add {LIST,TAILQ}_REPLACE(). List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 43e0ae5629213db428a017d5d57afca652d4c53c Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=43e0ae5629213db428a017d5d57afca652d4c53c commit 43e0ae5629213db428a017d5d57afca652d4c53c Author: Dag-Erling Smørgrav AuthorDate: 2024-04-08 18:16:40 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-04-15 10:54:59 +0000 sys/queue.h: Add {LIST,TAILQ}_REPLACE(). MFC after: 1 week Obtained from: NetBSD Sponsored by: Klara, Inc. Reviewed by: cperciva, imp Differential Revision: https://reviews.freebsd.org/D44679 (cherry picked from commit 7f479dee48973541da8c869b888b953161301c3b) sys/queue.h: Whitespace cleanup. MFC after: 1 week Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44678 (cherry picked from commit 69fd60f1ead5a86eeb0b18847dd71f7ae3fce4a0) --- share/man/man3/Makefile | 2 ++ share/man/man3/queue.3 | 34 ++++++++++++++++-- sys/sys/queue.h | 94 +++++++++++++++++++++++++++++++++---------------- 3 files changed, 98 insertions(+), 32 deletions(-) diff --git a/share/man/man3/Makefile b/share/man/man3/Makefile index 7fff5eedd5fb..2b2d7516c11f 100644 --- a/share/man/man3/Makefile +++ b/share/man/man3/Makefile @@ -216,6 +216,7 @@ MLINKS+= queue.3 LIST_CLASS_ENTRY.3 \ queue.3 LIST_NEXT.3 \ queue.3 LIST_PREV.3 \ queue.3 LIST_REMOVE.3 \ + queue.3 LIST_REPLACE.3 \ queue.3 LIST_SWAP.3 \ queue.3 SLIST_CLASS_ENTRY.3 \ queue.3 SLIST_CLASS_HEAD.3 \ @@ -284,6 +285,7 @@ MLINKS+= queue.3 LIST_CLASS_ENTRY.3 \ queue.3 TAILQ_NEXT.3 \ queue.3 TAILQ_PREV.3 \ queue.3 TAILQ_REMOVE.3 \ + queue.3 TAILQ_REPLACE.3 \ queue.3 TAILQ_SWAP.3 MLINKS+= stats.3 stats_tpl_alloc.3 \ stats.3 stats_tpl_fetch_allocid.3 \ diff --git a/share/man/man3/queue.3 b/share/man/man3/queue.3 index 3dc21be032ea..ea395d7ffe7f 100644 --- a/share/man/man3/queue.3 +++ b/share/man/man3/queue.3 @@ -27,7 +27,7 @@ .\" .\" @(#)queue.3 8.2 (Berkeley) 1/24/94 .\" -.Dd September 8, 2016 +.Dd April 8, 2024 .Dt QUEUE 3 .Os .Sh NAME @@ -92,6 +92,7 @@ .Nm LIST_NEXT , .Nm LIST_PREV , .Nm LIST_REMOVE , +.Nm LIST_REPLACE , .Nm LIST_SWAP , .Nm TAILQ_CLASS_ENTRY , .Nm TAILQ_CLASS_HEAD , @@ -118,6 +119,7 @@ .Nm TAILQ_NEXT , .Nm TAILQ_PREV , .Nm TAILQ_REMOVE , +.Nm TAILQ_REPLACE , .Nm TAILQ_SWAP .Nd implementations of singly-linked lists, singly-linked tail queues, lists and tail queues @@ -187,6 +189,7 @@ lists and tail queues .Fn LIST_NEXT "TYPE *elm" "LIST_ENTRY NAME" .Fn LIST_PREV "TYPE *elm" "LIST_HEAD *head" "TYPE" "LIST_ENTRY NAME" .Fn LIST_REMOVE "TYPE *elm" "LIST_ENTRY NAME" +.Fn LIST_REPLACE "TYPE *elm" "TYPE *new" "LIST_ENTRY NAME" .Fn LIST_SWAP "LIST_HEAD *head1" "LIST_HEAD *head2" "TYPE" "LIST_ENTRY NAME" .\" .Fn TAILQ_CLASS_ENTRY "CLASSTYPE" @@ -214,6 +217,7 @@ lists and tail queues .Fn TAILQ_NEXT "TYPE *elm" "TAILQ_ENTRY NAME" .Fn TAILQ_PREV "TYPE *elm" "HEADNAME" "TAILQ_ENTRY NAME" .Fn TAILQ_REMOVE "TAILQ_HEAD *head" "TYPE *elm" "TAILQ_ENTRY NAME" +.Fn TAILQ_REPLACE "TAILQ_HEAD *head" "TYPE *elm" "TYPE *new" "TAILQ_ENTRY NAME" .Fn TAILQ_SWAP "TAILQ_HEAD *head1" "TAILQ_HEAD *head2" "TYPE" "TAILQ_ENTRY NAME" .\" .Sh DESCRIPTION @@ -965,6 +969,17 @@ removes the element from the list. .Pp The macro +.Fn LIST_REPLACE +replaces the element +.Fa elm +with +.Fa new +in the list. +The element +.Fa new +must not already be on a list. +.Pp +The macro .Nm LIST_SWAP swaps the contents of .Fa head1 @@ -1223,6 +1238,17 @@ removes the element from the tail queue. .Pp The macro +.Fn TAILQ_REPLACE +replaces the element +.Fa elm +with +.Fa new +in the tail queue. +The element +.Fa new +must not already be on a list. +.Pp +The macro .Nm TAILQ_SWAP swaps the contents of .Fa head1 @@ -1237,7 +1263,7 @@ struct entry { ... TAILQ_ENTRY(entry) entries; /* Tail queue. */ ... -} *n1, *n2, *n3, *np; +} *n1, *n2, *n3, *n4, *np; TAILQ_INIT(&head); /* Initialize the queue. */ @@ -1255,6 +1281,10 @@ TAILQ_INSERT_BEFORE(n2, n3, entries); TAILQ_REMOVE(&head, n2, entries); /* Deletion. */ free(n2); + +n4 = malloc(sizeof(struct entry)); /* Replacement. */ +TAILQ_REPLACE(&head, n3, n4, entries); +free(n3); /* Forward traversal. */ TAILQ_FOREACH(np, &head, entries) np-> ... diff --git a/sys/sys/queue.h b/sys/sys/queue.h index 47d85121e317..9bdfd497b165 100644 --- a/sys/sys/queue.h +++ b/sys/sys/queue.h @@ -112,6 +112,7 @@ * _REMOVE_AFTER + - + - * _REMOVE_HEAD + + + + * _REMOVE s + s + + * _REPLACE - + - + * _SWAP + + + + * */ @@ -395,9 +396,9 @@ struct { \ (head)->stqh_last = &STAILQ_NEXT((elm), field); \ } while (0) -#define STAILQ_LAST(head, type, field) \ - (STAILQ_EMPTY((head)) ? NULL : \ - __containerof((head)->stqh_last, \ +#define STAILQ_LAST(head, type, field) \ + (STAILQ_EMPTY((head)) ? NULL : \ + __containerof((head)->stqh_last, \ QUEUE_TYPEOF(type), field.stqe_next)) #define STAILQ_NEXT(elm, field) ((elm)->field.stqe_next) @@ -500,7 +501,7 @@ struct { \ if (LIST_NEXT((elm), field) != NULL && \ LIST_NEXT((elm), field)->field.le_prev != \ &((elm)->field.le_next)) \ - panic("Bad link elm %p next->prev != elm", (elm)); \ + panic("Bad link elm %p next->prev != elm", (elm)); \ } while (0) /* @@ -518,21 +519,21 @@ struct { \ #define QMD_LIST_CHECK_PREV(elm, field) #endif /* (_KERNEL && INVARIANTS) */ -#define LIST_CONCAT(head1, head2, type, field) do { \ - QUEUE_TYPEOF(type) *curelm = LIST_FIRST(head1); \ - if (curelm == NULL) { \ - if ((LIST_FIRST(head1) = LIST_FIRST(head2)) != NULL) { \ - LIST_FIRST(head2)->field.le_prev = \ - &LIST_FIRST((head1)); \ - LIST_INIT(head2); \ - } \ - } else if (LIST_FIRST(head2) != NULL) { \ - while (LIST_NEXT(curelm, field) != NULL) \ - curelm = LIST_NEXT(curelm, field); \ - LIST_NEXT(curelm, field) = LIST_FIRST(head2); \ - LIST_FIRST(head2)->field.le_prev = &LIST_NEXT(curelm, field); \ - LIST_INIT(head2); \ - } \ +#define LIST_CONCAT(head1, head2, type, field) do { \ + QUEUE_TYPEOF(type) *curelm = LIST_FIRST(head1); \ + if (curelm == NULL) { \ + if ((LIST_FIRST(head1) = LIST_FIRST(head2)) != NULL) { \ + LIST_FIRST(head2)->field.le_prev = \ + &LIST_FIRST((head1)); \ + LIST_INIT(head2); \ + } \ + } else if (LIST_FIRST(head2) != NULL) { \ + while (LIST_NEXT(curelm, field) != NULL) \ + curelm = LIST_NEXT(curelm, field); \ + LIST_NEXT(curelm, field) = LIST_FIRST(head2); \ + LIST_FIRST(head2)->field.le_prev = &LIST_NEXT(curelm, field);\ + LIST_INIT(head2); \ + } \ } while (0) #define LIST_EMPTY(head) ((head)->lh_first == NULL) @@ -590,12 +591,12 @@ struct { \ #define LIST_NEXT(elm, field) ((elm)->field.le_next) -#define LIST_PREV(elm, head, type, field) \ - ((elm)->field.le_prev == &LIST_FIRST((head)) ? NULL : \ - __containerof((elm)->field.le_prev, \ +#define LIST_PREV(elm, head, type, field) \ + ((elm)->field.le_prev == &LIST_FIRST((head)) ? NULL : \ + __containerof((elm)->field.le_prev, \ QUEUE_TYPEOF(type), field.le_next)) -#define LIST_REMOVE_HEAD(head, field) \ +#define LIST_REMOVE_HEAD(head, field) \ LIST_REMOVE(LIST_FIRST(head), field) #define LIST_REMOVE(elm, field) do { \ @@ -604,13 +605,28 @@ struct { \ QMD_LIST_CHECK_NEXT(elm, field); \ QMD_LIST_CHECK_PREV(elm, field); \ if (LIST_NEXT((elm), field) != NULL) \ - LIST_NEXT((elm), field)->field.le_prev = \ + LIST_NEXT((elm), field)->field.le_prev = \ (elm)->field.le_prev; \ *(elm)->field.le_prev = LIST_NEXT((elm), field); \ TRASHIT(*oldnext); \ TRASHIT(*oldprev); \ } while (0) +#define LIST_REPLACE(elm, elm2, field) do { \ + QMD_SAVELINK(oldnext, (elm)->field.le_next); \ + QMD_SAVELINK(oldprev, (elm)->field.le_prev); \ + QMD_LIST_CHECK_NEXT(elm, field); \ + QMD_LIST_CHECK_PREV(elm, field); \ + LIST_NEXT((elm2), field) = LIST_NEXT((elm), field); \ + if (LIST_NEXT((elm2), field) != NULL) \ + LIST_NEXT((elm2), field)->field.le_prev = \ + &(elm2)->field.le_next; \ + (elm2)->field.le_prev = (elm)->field.le_prev; \ + *(elm2)->field.le_prev = (elm2); \ + TRASHIT(*oldnext); \ + TRASHIT(*oldprev); \ +} while (0) + #define LIST_SWAP(head1, head2, type, field) do { \ QUEUE_TYPEOF(type) *swap_tmp = LIST_FIRST(head1); \ LIST_FIRST((head1)) = LIST_FIRST((head2)); \ @@ -681,7 +697,7 @@ struct { \ */ #define QMD_TAILQ_CHECK_TAIL(head, field) do { \ if (*(head)->tqh_last != NULL) \ - panic("Bad tailq NEXT(%p->tqh_last) != NULL", (head)); \ + panic("Bad tailq NEXT(%p->tqh_last) != NULL", (head)); \ } while (0) /* @@ -763,7 +779,7 @@ struct { \ (var) && ((tvar) = TAILQ_PREV((var), headname, field), 1); \ (var) = (tvar)) -#define TAILQ_FOREACH_REVERSE_FROM_SAFE(var, head, headname, field, tvar) \ +#define TAILQ_FOREACH_REVERSE_FROM_SAFE(var, head, headname, field, tvar)\ for ((var) = ((var) ? (var) : TAILQ_LAST((head), headname)); \ (var) && ((tvar) = TAILQ_PREV((var), headname, field), 1); \ (var) = (tvar)) @@ -777,7 +793,7 @@ struct { \ #define TAILQ_INSERT_AFTER(head, listelm, elm, field) do { \ QMD_TAILQ_CHECK_NEXT(listelm, field); \ if ((TAILQ_NEXT((elm), field) = TAILQ_NEXT((listelm), field)) != NULL)\ - TAILQ_NEXT((elm), field)->field.tqe_prev = \ + TAILQ_NEXT((elm), field)->field.tqe_prev = \ &TAILQ_NEXT((elm), field); \ else { \ (head)->tqh_last = &TAILQ_NEXT((elm), field); \ @@ -832,7 +848,7 @@ struct { \ * the previous element. FAST is very useful for instances when * you may want to prefetch the last data element. */ -#define TAILQ_LAST_FAST(head, type, field) \ +#define TAILQ_LAST_FAST(head, type, field) \ (TAILQ_EMPTY(head) ? NULL : __containerof((head)->tqh_last, QUEUE_TYPEOF(type), field.tqe_next)) #define TAILQ_NEXT(elm, field) ((elm)->field.tqe_next) @@ -844,7 +860,7 @@ struct { \ ((elm)->field.tqe_prev == &(head)->tqh_first ? NULL : \ __containerof((elm)->field.tqe_prev, QUEUE_TYPEOF(type), field.tqe_next)) -#define TAILQ_REMOVE_HEAD(head, field) \ +#define TAILQ_REMOVE_HEAD(head, field) \ TAILQ_REMOVE(head, TAILQ_FIRST(head), field) #define TAILQ_REMOVE(head, elm, field) do { \ @@ -853,7 +869,7 @@ struct { \ QMD_TAILQ_CHECK_NEXT(elm, field); \ QMD_TAILQ_CHECK_PREV(elm, field); \ if ((TAILQ_NEXT((elm), field)) != NULL) \ - TAILQ_NEXT((elm), field)->field.tqe_prev = \ + TAILQ_NEXT((elm), field)->field.tqe_prev = \ (elm)->field.tqe_prev; \ else { \ (head)->tqh_last = (elm)->field.tqe_prev; \ @@ -865,6 +881,24 @@ struct { \ QMD_TRACE_ELEM(&(elm)->field); \ } while (0) +#define TAILQ_REPLACE(head, elm, elm2, field) do { \ + QMD_SAVELINK(oldnext, (elm)->field.tqe_next); \ + QMD_SAVELINK(oldprev, (elm)->field.tqe_prev); \ + QMD_TAILQ_CHECK_NEXT(elm, field); \ + QMD_TAILQ_CHECK_PREV(elm, field); \ + TAILQ_NEXT((elm2), field) = TAILQ_NEXT((elm), field); \ + if (TAILQ_NEXT((elm2), field) != TAILQ_END(head)) \ + TAILQ_NEXT((elm2), field)->field.tqe_prev = \ + &(elm2)->field.tqe_next; \ + else \ + (head)->tqh_last = &(elm2)->field.tqe_next; \ + (elm2)->field.tqe_prev = (elm)->field.tqe_prev; \ + *(elm2)->field.tqe_prev = (elm2); \ + TRASHIT(*oldnext); \ + TRASHIT(*oldprev); \ + QMD_TRACE_ELEM(&(elm)->field); \ +} while (0) + #define TAILQ_SWAP(head1, head2, type, field) do { \ QUEUE_TYPEOF(type) *swap_first = (head1)->tqh_first; \ QUEUE_TYPEOF(type) **swap_last = (head1)->tqh_last; \ From nobody Mon Apr 15 14:05:24 2024 X-Original-To: dev-commits-src-branches@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 4VJ8844HrSz5GfX2; Mon, 15 Apr 2024 14:05:24 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8843lc3z4Vd7; Mon, 15 Apr 2024 14:05:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189924; 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=2Bsy8Vaj4+S7XIB3/CxvJcQHF2igqlVqDx4FBcJBgOo=; b=yIbS+p/8SsAfuzwXz8MiAyninj1NXDAiBr4QxF6j0q7EEOoJOt1ZtxUTfmEF/MuC7Ui2jp rRtzeUVjX6DISuLUADCWq4/7VqR7YdjzIggeO9EF2XuZGF1jN014JcLSV6sdE3MAX2KBrT Mj1R6Wmw5QKILGD7O4FcKJysgA8ecOHyJW4w9LOUW3oSELRoCoAkwUMq/svrNRwzAWb5mI 5WUgTfDjdm1Z1X84jZq45acECB7nHlbOKM2BbT/uPBQmQgajhtNNzqG+UobKv3AEyjN/Ux wGt3EQsens4+4oSj1KeWQ8ARFgHTs4QyYt0iQvbk1rLc3FIXhNLU00jjN+cI1g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189924; a=rsa-sha256; cv=none; b=kw6b2TqBZx+sTIQvuDXpOtgSmGRqOWnH/ZRRLDCSRSGe349WVxgdBJ0I9Gye1lZE2Bk6XO f4kKpL+dTLEXZPvAxr3UmYTx3NPmf3xVL42KrcxCtCIFkRWFo0LVRv2RF2dOq6+AKocO1V nBv+o1MNKRfzJQ7+eoRihUK0Kz6zaYNMD4Fa//aKpOXXyDmPZzXr0KgQmltCWrzR7sqmI+ xMrHEHuYjU00lC5OtrQtx/mCZhVovo+BklHWckib83kPRzxGzTNkr4qaIZhZuxxB4wuQZe dFW8lp6C6o+tHPVjtkfvARZNcnabTvIzeh4bVfGfTBTS0a+2NfKWAa+nBrLEaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189924; 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=2Bsy8Vaj4+S7XIB3/CxvJcQHF2igqlVqDx4FBcJBgOo=; b=Lm4e/SsPUDD1q5okSkwWHASk50h3Yp1j0ApMkmcL8W0nM6uJOpGLz24jhQAj+TYhor6Ty8 YM7FPWJG6oLYNXRjHb4G6rePt0AjGE8e6e/wqmQTZbsg6hqAkg8K3RBm7hoToHuLlCKUtv 1En6wOBz9CojdI1jYDXECVVYIKgG3/V+T5n1UMMl5JxarBwdnEpm4GCBAToZMSqtfEyyh3 xgg6BxWbG5zejr1ZufPAVd5ffJOstA18346CikGHtSx0VWCY7Mxv319kP9BC4U8T0TFers E80RC8zAk88h/OK3vV65hkOlsDi5+3dTuuto8COuguL/+b4ZmOnwSbJek9XZgw== 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 4VJ8843D5Gz12qQ; Mon, 15 Apr 2024 14:05:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5OvS069710; Mon, 15 Apr 2024 14:05:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5O61069707; Mon, 15 Apr 2024 14:05:24 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:24 GMT Message-Id: <202404151405.43FE5O61069707@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 99ac8acf886b - stable/14 - build: Do not pass -fno-sanitize-memory-param-retval to subr_coverage.c List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 99ac8acf886bcccfb73e4695a2febb8869a29ec3 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=99ac8acf886bcccfb73e4695a2febb8869a29ec3 commit 99ac8acf886bcccfb73e4695a2febb8869a29ec3 Author: Mark Johnston AuthorDate: 2023-12-23 00:24:48 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 build: Do not pass -fno-sanitize-memory-param-retval to subr_coverage.c In the absence of -fsanitize=kernel-memory, the presence of this flag results in a -Wunused-command-line-argument warning. MFC after: 1 week (cherry picked from commit 2ae32f1f8fcc97c3e9c16effa2ee5e41a1a6c364) --- sys/conf/files | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/files b/sys/conf/files index b6a85d6a86a2..0bfced5287ec 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -3847,7 +3847,7 @@ kern/subr_clock.c standard kern/subr_compressor.c standard \ compile-with "${NORMAL_C} -I$S/contrib/zstd/lib/freebsd" kern/subr_coverage.c optional coverage \ - compile-with "${NORMAL_C:N-fsanitize*}" + compile-with "${NORMAL_C:N-fsanitize*:N-fno-sanitize*}" kern/subr_counter.c standard kern/subr_csan.c optional kcsan \ compile-with "${NORMAL_C:N-fsanitize*:N-fstack-protector*}" From nobody Mon Apr 15 14:05:25 2024 X-Original-To: dev-commits-src-branches@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 4VJ8855HQmz5Gfgr; Mon, 15 Apr 2024 14:05:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8854j1lz4W0q; Mon, 15 Apr 2024 14:05:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189925; 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=c4fzJPhJARFEXOD6IuOgKN8QnE8v0N+F8+Oy5CnWgb4=; b=fOKDWml/DjoUSBCAyB66U1Mo+OY0dIZRecS0/lm9WJGNsBb9Db1GcshLZSGx2sF0iH/VQQ g8Ip6jdUD9taJjkZaYnnrFrPSNAdBVQa1sZeQU7M1ppfRi/RdxIyhvAAlgEyYBfBtqLvQ5 Eb/t7hd9DbatQsKooTQt6CoZt9g9WqYk0QlDvlnMMMyoMqPP3G9DgV8dbEwWMlYWTZp7N5 dpnT9tHpLO0sdYN9t7MK/6wVsj4FU8p05xpavQMZ8o+bolSJjzNV254bGADmuXQmpITIOE GX19aO762cH65Zq8WdtOCnDB9jNVVdvih8zra1pjyy55ObMcPdScB085zXfQwA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189925; a=rsa-sha256; cv=none; b=RTivs4Qo9GYU6jf8qvLFGLJ1ziW2GXEgRsqB49pTgqxH9ZgpjSxtGGfr/OZTHN100UIVp2 FGUHVvPHjk8jhOXxQ6A6xC6rDypsXhwQq0XNqmSu+v8QxKeljn97r6UYDQ9By48cCaE/WX Q+5P6DhBEaN2MOZkSAVijEuF377xfcLszCaOr1R2MNIRgXjqaJttKmddpRb39KJ25FGriH Eri9lXNgzoVUpu4kCTb8oBQe5PlnwrCJbCc8DfvJqhNPWJISVl1NU6BKJE4N4wbEj2Vr2T Gqv5lwbPyafPQWyMWtfbJtfkBCxPMhrfkQ2I1NXyfXhGtvrapeA7tyE6Zxc+gg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189925; 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=c4fzJPhJARFEXOD6IuOgKN8QnE8v0N+F8+Oy5CnWgb4=; b=riHlr8LXTXiomouNKm/LLUmJPH1i1C6Mzre8hT6ruoCDd2iN3UD0uoSXGBHDiPWxSZMhiT U8nv6v8f1r7nKsRb1UiOYerYEamYH55z7twI94a3AglDoKoLU+4/01DZNURAFYRiSkl5e2 87o1pGJMTjnhMeQrVBU1Q1d5IvA7KsOaAkG5RpFGneaV03xnQLPx65MkLXn2CRESN+iqaz DqM4ZyRPFQGU/E1f3UyfW67GH5BpK3gGXY5ecsk9HJIcQIcEVnSs+WNQYkJXYkE5RE/W+V ZkPB5e2GOC+QV2cwOvFi5NKoyyZKHWsvtvdYv4163fF31jvkDnvjwM4q5keMnQ== 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 4VJ8854JqBz12qR; Mon, 15 Apr 2024 14:05:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5PVE069758; Mon, 15 Apr 2024 14:05:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5Pix069755; Mon, 15 Apr 2024 14:05:25 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:25 GMT Message-Id: <202404151405.43FE5Pix069755@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 21aa4bf198da - stable/14 - sdt: Use designated initializers for various definitions List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 21aa4bf198da60abf584210c5cbca2bcb3621147 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=21aa4bf198da60abf584210c5cbca2bcb3621147 commit 21aa4bf198da60abf584210c5cbca2bcb3621147 Author: Mark Johnston AuthorDate: 2024-04-03 18:41:29 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 sdt: Use designated initializers for various definitions No functional change intended. MFC after: 1 week (cherry picked from commit 3b795e641db7c1759d72aab9a77db8f87c8fbc45) --- sys/sys/sdt.h | 46 ++++++++++++++++++++++++++++------------------ 1 file changed, 28 insertions(+), 18 deletions(-) diff --git a/sys/sys/sdt.h b/sys/sys/sdt.h index e059921b0e9e..ba3dcfa15762 100644 --- a/sys/sys/sdt.h +++ b/sys/sys/sdt.h @@ -147,22 +147,26 @@ SET_DECLARE(sdt_providers_set, struct sdt_provider); SET_DECLARE(sdt_probes_set, struct sdt_probe); SET_DECLARE(sdt_argtypes_set, struct sdt_argtype); -#define SDT_PROVIDER_DEFINE(prov) \ - struct sdt_provider sdt_provider_##prov[1] = { \ - { #prov, { NULL, NULL }, 0, 0 } \ - }; \ - DATA_SET(sdt_providers_set, sdt_provider_##prov); +#define SDT_PROVIDER_DEFINE(_prov) \ + struct sdt_provider sdt_provider_##_prov[1] = { \ + [0] = { .name = #_prov }, \ + }; \ + DATA_SET(sdt_providers_set, sdt_provider_##_prov); #define SDT_PROVIDER_DECLARE(prov) \ extern struct sdt_provider sdt_provider_##prov[1] -#define SDT_PROBE_DEFINE(prov, mod, func, name) \ - struct sdt_probe sdt_##prov##_##mod##_##func##_##name[1] = { \ - { sizeof(struct sdt_probe), sdt_provider_##prov, \ - { NULL, NULL }, { NULL, NULL }, #mod, #func, #name, 0, 0, \ - NULL } \ - }; \ - DATA_SET(sdt_probes_set, sdt_##prov##_##mod##_##func##_##name); +#define SDT_PROBE_DEFINE(_prov, _mod, _func, _name) \ + struct sdt_probe sdt_##_prov##_##_mod##_##_func##_##_name[1] = {\ + [0] = { \ + .version = sizeof(struct sdt_probe), \ + .prov = sdt_provider_##_prov, \ + .mod = #_mod, \ + .func = #_func, \ + .name = #_name, \ + }, \ + }; \ + DATA_SET(sdt_probes_set, sdt_##_prov##_##_mod##_##_func##_##_name) #define SDT_PROBE_DECLARE(prov, mod, func, name) \ extern struct sdt_probe sdt_##prov##_##mod##_##func##_##name[1] @@ -178,12 +182,18 @@ SET_DECLARE(sdt_argtypes_set, struct sdt_argtype); } \ } while (0) -#define SDT_PROBE_ARGTYPE(prov, mod, func, name, num, type, xtype) \ - static struct sdt_argtype sdta_##prov##_##mod##_##func##_##name##num[1] \ - = { { num, type, xtype, { NULL, NULL }, \ - sdt_##prov##_##mod##_##func##_##name } \ - }; \ - DATA_SET(sdt_argtypes_set, sdta_##prov##_##mod##_##func##_##name##num); +#define SDT_PROBE_ARGTYPE(_prov, _mod, _func, _name, _num, _type, _xtype) \ + static struct sdt_argtype \ + sdta_##_prov##_##_mod##_##_func##_##_name##_num[1] = { \ + [0] = { \ + .ndx = _num, \ + .type = _type, \ + .xtype = _xtype, \ + .probe = sdt_##_prov##_##_mod##_##_func##_##_name, \ + }, \ + }; \ + DATA_SET(sdt_argtypes_set, \ + sdta_##_prov##_##_mod##_##_func##_##_name##_num); #define SDT_PROBE_DEFINE0(prov, mod, func, name) \ SDT_PROBE_DEFINE(prov, mod, func, name) From nobody Mon Apr 15 14:05:26 2024 X-Original-To: dev-commits-src-branches@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 4VJ8866PWRz5GfXB; Mon, 15 Apr 2024 14:05:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8865js2z4VjZ; Mon, 15 Apr 2024 14:05:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189926; 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=+GtwuQkah5DmT+FsA45wqxq0tICD7Phg0TNR64pYu14=; b=k1h0i0bHp6StE7/TjbsAiw8VvG6odg1oXwKLhXPVlvnAMLZrfShWX8GRio3X1zAHRMehhZ 3oonwlT3RJQD6owU6qCqE2ynFuCbPcYCzaF0+WjGU1OkD8GbyJ+Gz32qj+4RfnJZcXR7Tv hd2fvJF+zG+3kILNgnnxGUP5TzYJWZ/FPQd0Rs5ciQYaIkt0uCc0NRHOv24X+cvpI3Zbgv lA0j5C/YPUBh/Swwb3dJ6eLVkPGMAcCjgAHfPvwQMqXLHoNzyQn9gUt9wi3I8xFb0oaX/L MqLGIyaijL/k8M4sGB/JXNVZpXvijlrUHZSe+aQpVHnTsME44w3YigHBGYKUqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189926; a=rsa-sha256; cv=none; b=Wa/6QnVaSXaoo4F+wwyu6V7Re/y2X8Iu6DjQWZZR5PSHEa4O61guDhQdr5+VXktNryVJ4f H4mpNqyLHhFHdPiWT8NduEgoMabZAZq++Vp2+rTTQoZP89uyk6pjMVQji2xuU3WQ+xG/aM O/LDty1PpJmfjrtLJzjLaXDzqSvrB/+O5MEJYQgPLCRY8R63TeysAQbMMnfbg5uEBh5GSb gdFDrg4+nZF5tZPDKUQ8KnnmHOGZLMIO1sB448wzy5fjANv5K3yBtqVXJtAdg2hAvl0Exn Cjxhi3w72PGDjqJm2aNf9W5yHpY5KCFJ+XbYXnsBBRrH0VhKiDAoblQuxcoDbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189926; 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=+GtwuQkah5DmT+FsA45wqxq0tICD7Phg0TNR64pYu14=; b=LxcdodN1OdZy6+6ksEGLzUZCJ8e4YivwAVbafN2UiFeZDIuGnZNbsZmZUKDFHeh8Fx8fhY 6HAq9aJ1D1CrdOLcawVVe7RArezS0GCeujRXJSt3v9j02dP7a5vI9zjt+P5cTVhlzNGqkv y/UbXAX/SsUQ4tbijYok1poNgIdrnVZSKSoSigD42UJFZY/lDWh1+GeAyHLOodBNZslFBr AiYe0rlIbxZcqMPbM8EQoSafKaxgLFF243mNSizdLiPceGV/w8O1JXwnmuIHuaYg3oRZT/ Rkesz7K4ABn26MPC6Jgl1EdfUAJhZRfc6tEH71GjUNhe3LeHYywFk6Qogg4kHA== 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 4VJ8865L8Xz12qS; Mon, 15 Apr 2024 14:05:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5Qfi069806; Mon, 15 Apr 2024 14:05:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5Qiu069803; Mon, 15 Apr 2024 14:05:26 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:26 GMT Message-Id: <202404151405.43FE5Qiu069803@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: a006c6a0d452 - stable/14 - tarfs: Inherit mnt_iosize_max from the lower vnode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a006c6a0d45232d9bde1c50984462a69b058a313 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=a006c6a0d45232d9bde1c50984462a69b058a313 commit a006c6a0d45232d9bde1c50984462a69b058a313 Author: Mark Johnston AuthorDate: 2024-04-04 14:54:06 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 tarfs: Inherit mnt_iosize_max from the lower vnode There is no obvious reason to use a value smaller than that. Reviewed by: des, kib MFC after: 1 week Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44627 (cherry picked from commit 91eca18551554b7aca80fcfd3c648f524b321252) --- sys/fs/tarfs/tarfs_vfsops.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/fs/tarfs/tarfs_vfsops.c b/sys/fs/tarfs/tarfs_vfsops.c index 365234113168..a534b18ebf34 100644 --- a/sys/fs/tarfs/tarfs_vfsops.c +++ b/sys/fs/tarfs/tarfs_vfsops.c @@ -881,6 +881,8 @@ tarfs_alloc_mount(struct mount *mp, struct vnode *vp, VOP_UNLOCK(vp); mtime = va.va_mtime.tv_sec; + mp->mnt_iosize_max = vp->v_mount->mnt_iosize_max; + /* Allocate and initialize tarfs mount structure */ tmp = malloc(sizeof(*tmp), M_TARFSMNT, M_WAITOK | M_ZERO); TARFS_DPF(ALLOC, "%s: Allocated mount structure\n", __func__); From nobody Mon Apr 15 14:05:27 2024 X-Original-To: dev-commits-src-branches@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 4VJ8880lxGz5GfZB; Mon, 15 Apr 2024 14:05:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8876Tgdz4VgW; Mon, 15 Apr 2024 14:05:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189927; 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=btDocriZbILGRyHEyLF9te/S65ItlTvb4d2fYgDSzGE=; b=KKfQHPYjfXc+2gtpQvV+VxOUC0xNlNp2cHRn8wmWoKwHFMQnQ4Kqg/YKnZvZTbcF2hu4ZP 9nm6tjijKV9itMUU5YykhtyiIyxHe8kNaLlXQ8mw+i9vCuee8F3R4RxP/U+YhlSwtoMDDm uF0VjxgmH0jNCsgDHbuBYBbAcXYH2HUCR1h/qRL8rlkHVbGNT6TmbbF5VTknh6pn2z7nAh fCvpIPrHWZqvAhFDUir22kHEju8YCOP7e2LXMoE/zRjklpC3JiZbkI/1EpiAofjRj7XwE/ Vp7Un6P8FVN1HQmA4P+1V8f5ogdibO6/fUEZ9lLG/EQK4TAWahI7yj3jwY6JhQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189927; a=rsa-sha256; cv=none; b=jAmkkvNPVRN0rCxjbaIgz7GWPeCF0ckaRIf8YcCXBL91Sm7Ti9UH3capbqWvr7a2Hjm9EP RKLhn0p/ofpNbvWzscyI7AkRcr4rsHzANEQhQaIxYSHGeBY7w0Ob8p8438qGKdnN5GJnpS 5wW830Bx8Evr8eyegLkMa+0GQHgAEP3mpiXDkp++ZScwCQjjJ6DIrCa4aMUfplojYSCGZL mTUCSSdDXx/Y3I/akS4rDuu5IS8Zzkq8bK+RLer8CLAHOSMn53ZhWWZ2BIe3QANFsTToX/ lTg1FYVI2mXPypfujCZB6Peqi6AmNHDpI4Ym+Sot6T+g/69KSMvesPt86mIMSQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189927; 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=btDocriZbILGRyHEyLF9te/S65ItlTvb4d2fYgDSzGE=; b=VibEKMEOSt53o0SqZG897Qb37zJht4LHuqHf05O8YiY67ONyFkTK9rvCXYAC1U2yZ09+D5 RfD2Q3I7jjIys5htU/5zsD3gdLpeKc7HWTZbl6JJ1Ve8zPKu0icoMf8lVsfCksXTG0kV6x /W9qUkk4lbWFSMDwAutinkSk4AMJtfoED5g9NuJaiDsOm/Violu+X1Ya2MKauAJnv1Btxz FXy5TzgKpm54qbQqnJmaeiae8iIIoAW9jwFszOwy9T63YRXeLrBh7wBWc3jxyIEgOy3QKQ EaceQAx71TFBNR8a6wJDe3Z4pTu8s7Qa1TF7bYmS5o91xq5ubXlQnuDrJlnOwg== 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 4VJ88765yyz12n8; Mon, 15 Apr 2024 14:05:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5RsY069854; Mon, 15 Apr 2024 14:05:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5RVu069851; Mon, 15 Apr 2024 14:05:27 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:27 GMT Message-Id: <202404151405.43FE5RVu069851@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: f97a19fc0129 - stable/14 - tarfs.5: Document the importance of zstd framing List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f97a19fc012939360b4c2467823246b7a7f34ac2 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=f97a19fc012939360b4c2467823246b7a7f34ac2 commit f97a19fc012939360b4c2467823246b7a7f34ac2 Author: Mark Johnston AuthorDate: 2024-04-04 14:54:25 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 tarfs.5: Document the importance of zstd framing Reviewed by: des, kib MFC after: 1 week Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44628 (cherry picked from commit d1801babad495be2a3eb1d974e1daf9714c5b0fd) --- share/man/man5/tarfs.5 | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/share/man/man5/tarfs.5 b/share/man/man5/tarfs.5 index 29999b8066f7..5378491b9c9f 100644 --- a/share/man/man5/tarfs.5 +++ b/share/man/man5/tarfs.5 @@ -61,6 +61,19 @@ sysctl setting and tunable. Setting it to 0 will reset it to its default value. Note that changes to this setting only apply to filesystems mounted after the change. +.Pp +When the backing tar file is compressed with +.Xr zstd 1 , +I/O performance can be improved by ensuring that compressed data is +broken up into multiple frames. +This helps minimize unnecessary decompression work. +When using +.Xr bsdtar 1 +to create the tar file, this can be achieved using the +.Cm zstd:max-frame-size +and +.Cm ztsd:frame-per-file +options. .Sh DIAGNOSTICS If enabled by the .Dv TARFS_DEBUG From nobody Mon Apr 15 14:05:28 2024 X-Original-To: dev-commits-src-branches@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 4VJ88944d7z5GfRc; Mon, 15 Apr 2024 14:05:29 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8890P2Hz4Vvr; Mon, 15 Apr 2024 14:05:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189929; 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=75F6IuLOFWqxPUNNUICWW+ePQaQbkCnAvwW89/0EKbM=; b=kYArAhDnmBrqCu9Fa5CI1uMpL2JbR9STYTPY8R/y2kzFdjfqrIr6BUzTcPUi0BVFn/DSmL ahMEBAQaVTmXd47TdCxXdKM9sl1vBj/1kt8tJkmqqtKjNUMIRP+pVl6P+KNUawFxJNsnQM 0J/sZ53MlPgOu/uCfvO1BeGl4ul+O84Fn3hca8EWU4NlRtMotiIdbLhWYNaC5T6VSVsrVw +2v5VW8LRqZihQMZJaRn9FjgPiD8CfNiALX/Jr9MHb8kMwprfes5ljiu6XdEAAudfpc9nY RDICxoit4uaXfuK98nEYvfkYPBCssY9Z5J7ghXgkaDDZnRQhWvYfgWT9+cZlNg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189929; a=rsa-sha256; cv=none; b=fB3XAKsYVq4F6pdCurtMpoSt2dJEyVqU1ggPcOaETwU7afQ1RhwYQCgluYqHNynBsVfGv0 ggmEVWfTbW/exN5p14lTg7odXn/ygb4BKHeFj7YNf99ojOAowwPKG8iHJoldiFH4R9mlFG r8RTsxr+5A115MEpJ5rYUynLKqA6vc9+KXuTdp/NFbbb8rBFoK+cMpF2ujuUFzMd6ptKaD VdWH7zDZudD8RnQPsuf1c+xpclKbwMCzEiCgWJIgVajhXcBDFXsoZJFkfbDC0x/8cWw8uL 1UsiISsZHW+T17AR2KwX5HNXcnc81XFwM/q2+Kgzvagu9Ood+P2CE95wtCt8eA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189929; 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=75F6IuLOFWqxPUNNUICWW+ePQaQbkCnAvwW89/0EKbM=; b=MwbByFTYYtqdIA7FHbNhD8lyaPd6KVH46e2eMLUGqQR9N07u2Ic4beDlQRT/NPgc/2v7zx Y3GFUIs4f4spIpvrIIdD4OCvLtMiBXo7kKtDB+ERzvtioTe8GTQCznVnic7FTCfPYCMPFV kEdtd8GKlvnbEyUwgEeMWuA6WH4Aq7ZT8Qc7QpQUjJxbQJqVry24At+6B16FipF1EpVz4A gUrgxZ52C9EfWunZJ+o4vDSNWuBJX1aIVu7LJ2mLDBYaDY7haVDERwbIJXVjy4+ecL00Td rCiRjm/y2SFKwijlk4lswNgIUonP3/9WJQDmDzWKjhuEZLHash3UqwdCloxHgw== 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 4VJ88873Whz12sT; Mon, 15 Apr 2024 14:05:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5SHv069893; Mon, 15 Apr 2024 14:05:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5SRC069890; Mon, 15 Apr 2024 14:05:28 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:28 GMT Message-Id: <202404151405.43FE5SRC069890@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 9e901b721722 - stable/14 - VOP_BMAP.9: Typo List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9e901b721722a0cfddf7940addb10118bd59b7dd Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=9e901b721722a0cfddf7940addb10118bd59b7dd commit 9e901b721722a0cfddf7940addb10118bd59b7dd Author: Mark Johnston AuthorDate: 2024-04-05 15:14:28 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 VOP_BMAP.9: Typo MFC after: 1 week Sponsored by: Klara, Inc. (cherry picked from commit 663a704a58455087f83b4ab51ad7a572e6f03d5f) --- share/man/man9/VOP_BMAP.9 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man9/VOP_BMAP.9 b/share/man/man9/VOP_BMAP.9 index 8db1d724e810..82dda716fd70 100644 --- a/share/man/man9/VOP_BMAP.9 +++ b/share/man/man9/VOP_BMAP.9 @@ -58,7 +58,7 @@ Return storage for the number of succeeding logical blocks that may be efficiently read at the same time as the requested block. This will usually be the number of logical blocks whose physical blocks are contiguously allocated. -However a file system is free to define "efficient" as it see fit. +However a file system is free to define "efficient" as it sees fit. .It Fa runb Like .Fa runp From nobody Mon Apr 15 14:05:30 2024 X-Original-To: dev-commits-src-branches@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 4VJ88B3KW8z5GfXG; Mon, 15 Apr 2024 14:05:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88B1Nc2z4WG3; Mon, 15 Apr 2024 14:05:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189930; 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=C8CNp6WK36rVcROQEBVgS3tn2TRM9bXxoku1dlC1RXo=; b=tOUR6ZaSlqBS3krOj+NFrR4wi6petxJ4jKII9tpTSrSGSbqJxgz9AeO9UWFZiHfo1QK3+C uolR2Y9VFTmodIEvC/7+MXhxa6CNmICITbB8CfwldHOs3QN7T+uNh4ufNNAkHf3mnJODsh cI16NrVCQAtd82odwWZWIbPyxi2idcKOJTgv1ACIUOhrmiCE8DtI+adOeGWNbcELdBhSep 1WKA4d/N2M/KdA4GOnCBXTOIIVUNHqtSa8Br7S325bV8wCoXPj7Q10LFmcWVin57TyvPSq OgQmSbgg3xM6TfrJ6EbSPyv6DHH/zoWUHbpiEPqCoT+YvQqfFD/uoeTQs4Qyrw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189930; a=rsa-sha256; cv=none; b=MKjXAH0R9nS6FXwW1SOdYJJW8vJrq7Xi/sYF7vQ+/Eh4GLw19x3//Ru3HWW6frvC0T+NkB PEhpETsgllKbbgbtN68DNasxVIVK4G5j73g1tMoOySdxaer3ZquNaQnzQ4fmXS320sJG65 5HljRPFT4QRFv6Zpe0DqV7wTByHY69Vy2QvBksugEM0fFeDuVKTniIJcURFFNT5LTX2QJY iybNUjtC8M+kUJubOqweywpnxKL24MdZ7lv/a9OEmyqrvDa/YLbQ1cWjjJAfZNORB5U3BE Nf427rgOFGnlAwczrwbbfmgp/oHmGHpUlcbjkbbvLjBiMPjd7huKh7DpHIYZIw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189930; 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=C8CNp6WK36rVcROQEBVgS3tn2TRM9bXxoku1dlC1RXo=; b=mZdSflDj8gaeGL0Zvmwl49bITFWTJLdSBdp1MPHqXTnuKieuzgUiaydA9jT7CMMxFu72Pu NUeHk1Dnm6KwUupLGVNoLaY59Ca0caB4UIPKFzzmMpnqi4fZw0F9lfbEAbFnA/PmOHVauX KVkCxmsvuPSdXN8u7d5rWOba9fMKIQApFeZfOfbIxDzzsOrg/Mgc5G84KQPDL5Umcpga+M 6LIZIpfc6/MEuiVMSVoKkllgBzyNUI7f8vwKu4D55Fz5mVjAhSj8uvwvkZXy9UUahDzAJ8 dGHwPm6W8BDjJP3iWCOdcm27mzGl82vFkycx11vdcM0rwoIZNE59NmXcsGJNig== 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 4VJ88B0vv7z12kp; Mon, 15 Apr 2024 14:05:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5UPY069944; Mon, 15 Apr 2024 14:05:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5UVF069941; Mon, 15 Apr 2024 14:05:30 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:30 GMT Message-Id: <202404151405.43FE5UVF069941@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 342a51f11018 - stable/14 - which: Use size_t instead of ssize_t for pathlen List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 342a51f11018a386643402c5b79a6f1768defb29 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=342a51f11018a386643402c5b79a6f1768defb29 commit 342a51f11018a386643402c5b79a6f1768defb29 Author: Collin Funk AuthorDate: 2024-02-11 04:26:38 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 which: Use size_t instead of ssize_t for pathlen The "pathlen" variable is the return value of strlen(3) and is then passed as an argument to malloc(3) and memcpy(3). The size_t type matches the prototype for these functions. The size_t type is unsigned so it can fit larger $PATH values than ssize_t. However, in practice ssize_t should be larger enough so this change is just for clarity. Signed-off-by: Collin Funk MFC after: 1 week Pull Request: https://github.com/freebsd/freebsd-src/pull/1113 (cherry picked from commit 8268a31bcceb9ebe32d380cab792c89c5d897d15) --- usr.bin/which/which.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.bin/which/which.c b/usr.bin/which/which.c index f6ee25f60cce..dc22efb815d8 100644 --- a/usr.bin/which/which.c +++ b/usr.bin/which/which.c @@ -45,7 +45,7 @@ int main(int argc, char **argv) { char *p, *path; - ssize_t pathlen; + size_t pathlen; int opt, status; status = EXIT_SUCCESS; From nobody Mon Apr 15 14:05:31 2024 X-Original-To: dev-commits-src-branches@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 4VJ88C43k8z5GfTG; Mon, 15 Apr 2024 14:05:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88C359Rz4WGK; Mon, 15 Apr 2024 14:05:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189931; 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=/DdehPnhF4Otd2PoYjeSKkkPLmk6kyfIigvwvYIV0iE=; b=Qy1/fMT3XNVPJGSHJvKkA2piJvWcIHCMwiJev1TKAKL+NCV1V/phqICP9KhqmXKbCn4PmD Xc/1vh1NHZqywdMJIM3z80L1c8RzOoc/sQ4tffPARGaSBbLD3h+1V/b4+XTo6hEIUlqIVy i0xB4kdad4nEqEHDnuLKXT6SDHGgeNl6Gwhprk3i05D8C7CfjlaN3ABAt+6eGyBuj595X1 chbYuGNDDnUf5saSgkqlwnb6hvW6YNZyN6Vj4YGTkB4zK1jFixwbZcWYWX1v1AKQBrhhRS KzEX7b3+V98hv+o/RaGny74fcm4SJ9Eb+7XbcIq3n1Al+YB4e4t/87GHOmozXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189931; a=rsa-sha256; cv=none; b=jWLQYhEHH893UYnyA+/fchX+Ovc2EFhfUx/CV0aEZ8NqLJzi7m6D8H4TSuCBIsQSWApPER zpT8SD9zvYyIVSdJQxIEiDX8Lo9TeSAGaN1groHkH4Hb0s9Twb0GwShH9O00OpoDLydyYO cskM9NWrGIHfsysmpZ2nu4ZUiD63k9lrm7bbVxAPeaK6KQ6IC1NXQ0b9DPemRvLj8u9sLU ha6ZJVbcYpLbkGYH7DP3l7LxcE1+bfbR3DNG9c8oKqg19u4cewn6cMFPKZjuETu3/bH/FH f0pHsDreBuycTq7VBXkusSfHQJ1aRp9hHEWvgfSe+UZPJ7m57eFEjxe6YVJH3A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189931; 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=/DdehPnhF4Otd2PoYjeSKkkPLmk6kyfIigvwvYIV0iE=; b=lUt/qntQl1lRZOfIqPFWuzYxKo9r7Y0ISnJN6ke0pd8a7oN9DtKsvRRv5x9+Ds6ns1k2L8 e/AgadsFZ4CxuxhNKKqCby3lSX1otmWwpElHUv44+AzOxLpyFXbpMkeFf4MDyM/wZBuBUp ZVXz6srVu7x78wKigZIe4R9Fv1DeEKzOa6mallr3ao02fTF/Lb+QUjH+KOH6nkDa4ZCeNg 52ByneijHeJ0vw/eqjqZrolYcQGFoLBikoVTZ64Rm6O/pw78yT+YPw+p7LLYxKFwTYndgL 8dewdKGkBjQcgYtuuWhvr6dEwQFpw7SRFLuY1cL0moC8gv4KgCSiykJBx8rk7w== 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 4VJ88C1yt8z12vw; Mon, 15 Apr 2024 14:05:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5VEY069989; Mon, 15 Apr 2024 14:05:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5V7d069986; Mon, 15 Apr 2024 14:05:31 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:31 GMT Message-Id: <202404151405.43FE5V7d069986@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: aef4504139a4 - stable/14 - dtrace: Add the 'oformat' libdtrace option List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: aef4504139a4d0557f1a1059dd43cb1cbcd612d5 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=aef4504139a4d0557f1a1059dd43cb1cbcd612d5 commit aef4504139a4d0557f1a1059dd43cb1cbcd612d5 Author: Domagoj Stolfa AuthorDate: 2024-01-03 14:58:01 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 dtrace: Add the 'oformat' libdtrace option This option can be used to specify a format to use in DTrace output. The following formats are supported: - json - xml - html - none (default DTrace output) This is implemented using libxo and integrated into libdtrace. Client code only works with the following API: - dtrace_oformat_setup(dtrace_hdl_t *) -- to be called when output is starting. - dtrace_oformat_teardown(dtrace_hdl_t *) -- to be called when output is finished - dtrace_oformat(dtrace_hdl_t *) -- check if oformat is enabled. - dtrace_set_outfp(FILE *) -- sets the output file for oformat. - Ensure that oformat is correctly checked in the drop handler and record processing callbacks. This commit also adds tests which check if the generated output is valid (JSON, XML) and extends the dtrace(1) describing the structured output. Reviewed by: markj Discussed with: phil MFC after: 2 months Sponsored by: Innovate UK Differential Revision: https://reviews.freebsd.org/D41745 (cherry picked from commit 93f27766a7e1af009c5b1e4ca538632857c91aa1) --- Makefile.inc1 | 3 + cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 | 416 +++++- cddl/contrib/opensolaris/cmd/dtrace/dtrace.c | 72 +- .../dtrace/test/tst/common/oformat/tst.agg.avg.ksh | 66 + .../test/tst/common/oformat/tst.agg.count.ksh | 66 + .../test/tst/common/oformat/tst.agg.llquantize.ksh | 73 + .../test/tst/common/oformat/tst.agg.lquantize.ksh | 73 + .../dtrace/test/tst/common/oformat/tst.agg.max.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.agg.min.ksh | 66 + .../test/tst/common/oformat/tst.agg.quantize.ksh | 73 + .../test/tst/common/oformat/tst.agg.stddev.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.agg.sum.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.aggmod.ksh | 66 + .../test/tst/common/oformat/tst.aggstack.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.aggsym.ksh | 66 + .../test/tst/common/oformat/tst.aggustack.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.aggusym.ksh | 66 + .../dtrace/test/tst/common/oformat/tst.drop.ksh | 61 + .../cmd/dtrace/test/tst/common/oformat/tst.mod.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.print.ksh | 60 + .../dtrace/test/tst/common/oformat/tst.printf.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.printm.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.stack.ksh | 61 + .../cmd/dtrace/test/tst/common/oformat/tst.sym.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.trace.ksh | 66 + .../test/tst/common/oformat/tst.tracemem.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.umod.ksh | 57 + .../dtrace/test/tst/common/oformat/tst.ustack.ksh | 61 + .../dtrace/test/tst/common/oformat/tst.usym.ksh | 57 + .../lib/libdtrace/common/dt_aggregate.c | 17 +- .../opensolaris/lib/libdtrace/common/dt_consume.c | 1540 +++++++++++++++++--- .../opensolaris/lib/libdtrace/common/dt_handle.c | 37 +- .../opensolaris/lib/libdtrace/common/dt_impl.h | 7 + .../opensolaris/lib/libdtrace/common/dt_oformat.h | 34 + .../opensolaris/lib/libdtrace/common/dt_open.c | 3 + .../opensolaris/lib/libdtrace/common/dt_options.c | 14 + .../opensolaris/lib/libdtrace/common/dt_print.c | 266 +++- .../opensolaris/lib/libdtrace/common/dt_printf.h | 6 + .../opensolaris/lib/libdtrace/common/dt_subr.c | 42 + .../opensolaris/lib/libdtrace/common/dtrace.h | 22 + cddl/lib/libdtrace/Makefile | 2 +- cddl/usr.sbin/dtrace/Makefile | 2 +- cddl/usr.sbin/dtrace/tests/common/Makefile | 1 + cddl/usr.sbin/dtrace/tests/common/oformat/Makefile | 42 + cddl/usr.sbin/dtrace/tests/dtrace.test.mk | 2 +- etc/mtree/BSD.tests.dist | 2 + share/mk/src.libnames.mk | 2 +- 47 files changed, 3906 insertions(+), 279 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 58a9b1fd4f3e..d317e3acdd7f 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -3150,6 +3150,7 @@ _prebuild_libs= ${_kerberos5_lib_libasn1} \ ${_cddl_lib_libctf} ${_cddl_lib_libzfsbootenv} \ lib/libufs \ lib/libutil lib/libpjdlog ${_lib_libypclnt} lib/libz lib/msun \ + lib/libxo \ ${_secure_lib_libcrypto} ${_secure_lib_libssl} \ ${_lib_libldns} ${_secure_lib_libssh} @@ -3206,6 +3207,7 @@ _generic_libs+= ${_DIR} .endfor lib/libtacplus__L: lib/libmd__L lib/libpam/libpam__L +lib/libxo__L: lib/libutil__L .if ${MK_CDDL} != "no" _cddl_lib_libumem= cddl/lib/libumem @@ -3246,6 +3248,7 @@ lib/libbe__L: cddl/lib/libzfs__L cddl/lib/libzfsbootenv__L _cddl_lib_libctf= cddl/lib/libctf _cddl_lib= cddl/lib cddl/lib/libctf__L: lib/libz__L cddl/lib/libspl__L +cddl/lib/libdtrace__L: lib/libxo__L .endif # cddl/lib/libdtrace requires lib/libproc and lib/librtld_db _prebuild_libs+= lib/libprocstat lib/libproc lib/librtld_db diff --git a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 index 1745519c2c1a..ab8c672a95a1 100644 --- a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 +++ b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 @@ -18,7 +18,9 @@ .\" CDDL HEADER END .\" Copyright (c) 2006, Sun Microsystems, Inc. All Rights Reserved. .\" -.Dd February 24, 2023 +.\" $FreeBSD$ +.\" +.Dd September 8, 2023 .Dt DTRACE 1 .Os .Sh NAME @@ -27,7 +29,8 @@ .Sh SYNOPSIS .Nm .Op Fl 32 | Fl 64 -.Op Fl aACdeFGhHlqSvVwZ +.Op Fl aACdeFGhHlOqSvVwZ +.Op Fl -libxo .Op Fl b Ar bufsz .Op Fl c Ar cmd .Op Fl D Ar name Op Ns = Ns value @@ -355,6 +358,11 @@ writing D programs. The specified .Ar path is added after the default library search path. +.It Fl -libxo +Generate output via +.Xr libxo 3 . +This option is the same as specifying +.Sy oformat . .It Fl m Oo Ar provider : Oc Ar module Oo Oo Ar predicate Oc Ar action Oc Specify module name to trace or list .Fl ( l @@ -398,6 +406,14 @@ argument can be suffixed with an optional D probe clause. More than one .Fl n option can be specified on the command line at a time. +.It Fl O +This option causes +.Nm +to print all the aggregations upon exiting if +.Sy oformat +or +.Fl -libxo +are specified. .It Fl o Ar output Specify the .Ar output @@ -650,6 +666,32 @@ Number of whitespace characters to use when indenting and .Fn ustack output. +.It Sy oformat Ns = Ns Ar format +Specify the format to use for output. +Setting +.Sy oformat +to +.Ql text +makes +.Nm +use regular human-readable output which is its default behavior. +The options passed to +.Sy oformat +are directly forwarded to +.Xr libxo 3 . +Some of the supported formatters include +.Ql json , +.Ql xml +and +.Ql html . +Note that this option will cause +.Nm +to not produce any output unless printing functions are explicitly called, +or the +.Fl O +flag is specified. +For more information see +.Sx STRUCTURED OUTPUT . .It Sy statusrate Ns = Ns Ar time Rate of status checking. .It Sy switchrate Ns = Ns Ar time @@ -776,6 +818,376 @@ or .Fl i options) contain descriptions that do not match any known probes. .El +.Sh STRUCTURED OUTPUT +.Nm +supports structured output using +.Xr libxo 3 . +The output will always have a top-level object called +.Dq dtrace , +followed by a list of objects +.Dq probes . +Each of the probe objects will to have a timestamp which is generated at +output time rather than probe firing time, an identifier for the CPU on +which the probe was executed, and the probe's full specification: +.Bd -literal +{ + "dtrace": { + "probes": [ + { + "timestamp": ..., + "cpu": ..., + "id": ..., + "provider": ..., + "module": ..., + "function": ..., + "name": ..., + "output": [ + ... (script-specific output) + ] + } + ] + } +} + + + + + ... + ... + ... + ... + ... + ... + ... + + ... (script-specific output) + + + +.Ed +.Pp +It is also possible for XML output to take the following form if some +of the fields are empty (in this example, module and function values +are absent): +.Bd -literal + + + + ... + + + ... + + ... (script-specific output) + + + +.Ed +.Pp +Similarly, +.Sy oformat +can be used to generate HTML: +.Bd -literal +
+
...
+
+
...
+
+
...
+
+
...
+
+
...
+
+
...
+
+
...
+
...
+
+.Ed +.Pp +Unlike JSON and XML, the +.Dq output +array is not present. +Instead, data is simply formatted into a div of class +.Dq data +and a data-tag is associated with each of the keys. +.Pp +The +.Dq output +array's contents depend on the probes' actions and is explained below. +The examples here are presented in JSON form as opposed to XML or HTML, +however the conversion explained above applies for all output formats. +.Pp +Any scalar output, such as output produced by the +.Fn trace +action is of form: +.Bd -literal +{ + "value": ... +} +.Ed +.Pp +The +.Fn printf +action begins with an object containing the formatted output of the +.Fn printf +action. +Subsequent objects contains the value of each of the arguments to +.Fn printf +in its raw form as if the +.Fn trace +action was used instead. +A +.Fn printf +statement which contains no arguments other than the message will only have +one object following the message object and its value will always be 0. +This is an artefact of the implementation and can safely be ignored. +.Bd -literal +# dtrace --libxo json,pretty -n 'BEGIN { printf("... %Y, ..", walltimestamp); }' + +{ + "message": "... 2023 Sep 7 16:49:02, .." +}, +{ + "value": 1694105342633402400 +}, +{ + ... +} +.Ed +.Pp +Scalar aggregations are aggregations which produce a single value for a given +key. +These aggregations include +.Fn count , +.Fn min , +.Fn max , +.Fn stddev +and +.Fn sum . +Each one of them is represented by the key containing their name. +For example, the output of a +.Fn stddev +aggregation will contain a key +.Dq stddev +inside an +.Dq aggregation-data +object: +.Bd -literal +{ + "aggregation-data": [ + { + "keys": [ + ... + ], + "stddev": ... + } + ], + "aggregation-name": ... +} +.Ed +.Pp +The +.Dq keys +field remains consistent across all aggregations, however +.Fn quantize , +.Fn lquantize +and +.Fn llquantize +need to be treated differently. +.Sy oformat +will create a new array of objects called +.Dq buckets . +Each of the objects contains a +.Dq value +and a +.Dq count +field which are +the left-hand side and the right-hand side of human-readable +.Nm +output respectively. +The full object has the following format: +.Bd -literal +{ + "aggregation-data": [ + ... + { + "keys": [ + ... + ], + "buckets": [ + { + "value": 32, + "count": 0 + }, + { + "value": 64, + "count": 17 + }, + ... + ], + }, + ... + ] + "aggregation-name": ... +} +.Ed +.Pp +Similar to scalar aggregations, named scalar actions such as +.Fn mod , +.Fn umod , +.Fn usym , +.Fn tracemem +and +.Fn printm +will output an object with the key being equal to the +name of the action. +For example, +.Fn printm +output would produce the following object: +.Bd -literal +{ + "printm": "0x4054171100" +} +.Ed +.Pp +.Fn sym +is slightly different. +While it will create a +.Dq sym +field which contains its value, in some cases it will also create additional +fields +.Dq object , +.Dq name +and +.Dq offset : +.Bd -literal +# dtrace -x oformat=json,pretty -On 'BEGIN { sym((uintptr_t)&`prison0); }' + +{ + "sym": "kernel`prison0", + "object": "kernel", + "name": "prison0" +} + +# dtrace --libxo json,pretty -On 'BEGIN { sym((uintptr_t)curthread); }' + +{ + "sym": "0xfffffe00c18d2000", + "offset": "0xfffffe00c18d2000" +} +.Ed +.Pp +.Fn stack +and +.Fn ustack +actions unroll each of the stack frames into its own object in an array. +The only real difference between them is that the +.Fn stack +action will produce a list called +.Dq stack-frames +while +.Fn ustack +will produce one called +.Dq ustack-frames . +The following is an example of their +.Sy oformat +output: +.Bd -literal +{ + "stack-frames": [ + { + "symbol": "dtrace.ko`dtrace_dof_create+0x35", + "module": "dtrace.ko", + "name": "dtrace_dof_create", + "offset": "0x35" + }, + { + "symbol": "dtrace.ko`dtrace_ioctl+0x81c", + "module": "dtrace.ko", + "name": "dtrace_ioctl", + "offset": "0x81c" + }, + ... + ] +} + +{ + "ustack-frames": [ + { + "symbol": "libc.so.7`ioctl+0xa", + "module": "libc.so.7", + "name": "ioctl", + "offset": "0xa" + }, + { + "symbol": "libdtrace.so.2`dtrace_go+0xf3", + "module": "libdtrace.so.2", + "name": "dtrace_go", + "offset": "0xf3" + }, + ... + ] +} +.Ed +.Pp +The +.Fn print +action produces a +.Dq type +list in the following form: +.Bd -literal +{ + "type": [ + { + "object-name": "kernel", + "name": "struct thread", + "ctfid": 2372 + }, + { + "member-name": "td_lock", + "name": "struct mtx *volatile", + "ctfid": 2035, + "value": "0xffffffff82158440" + }, + ... +} +.Ed +.Pp +If the type is invalid, a +.Dq warning +object will be produced containing the diagnostic message as well as two +possible optional fields: +.Dq type-identifier +which contains the CTF identifier of the type and +.Dq size containing the size of an integer, enum or float. +The fields generated will depend on the kind of error that was encountered +while processing the trace data. +.Pp +Finally, +.Sy oformat +provides a special pseudo-probe to represent drops. +As +.Nm +polls for various kinds of drops +.Sy oformat +will produce output similar to the following in order to represent drops: +.Bd -literal +{ + "cpu": -1, + "id": -1, + "provider": "dtrace", + "module": "INTERNAL", + "function": "INTERNAL", + "name": "DROP", + "timestamp": ..., + "count": ..., + "total": ..., + "kind": 2, + "msg": "... dynamic variable drops\n" +} +.Ed .Sh OPERANDS You can specify zero or more additional arguments on the .Nm diff --git a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c index cdc476a43b08..dc68c6ef5f72 100644 --- a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c +++ b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c @@ -26,6 +26,7 @@ /* * Copyright (c) 2012 by Delphix. All rights reserved. * Copyright (c) 2013, Joyent, Inc. All rights reserved. + * Copyright (c) 2023, Domagoj Stolfa. All rights reserved. */ #include @@ -55,6 +56,9 @@ #include #endif +#undef NORETURN /* needed because libxo redefines it */ +#include + typedef struct dtrace_cmd { void (*dc_func)(struct dtrace_cmd *); /* function to compile arg */ dtrace_probespec_t dc_spec; /* probe specifier context */ @@ -77,7 +81,7 @@ typedef struct dtrace_cmd { #define E_USAGE 2 static const char DTRACE_OPTSTR[] = - "3:6:aAb:Bc:CdD:ef:FGhHi:I:lL:m:n:o:p:P:qs:SU:vVwx:X:Z"; + "3:6:aAb:Bc:CdD:ef:FGhHi:I:lL:m:n:o:Op:P:qs:SU:vVwx:X:Z"; static char **g_argv; static int g_argc; @@ -167,6 +171,7 @@ usage(FILE *fp) "\t-m enable or list probes matching the specified module name\n" "\t-n enable or list probes matching the specified probe name\n" "\t-o set output file\n" + "\t-O print output upon exiting (specific to oformat)\n" "\t-p grab specified process-ID and cache its symbol tables\n" "\t-P enable or list probes matching the specified provider name\n" "\t-q set quiet mode (only output explicitly traced data)\n" @@ -907,7 +912,10 @@ errhandler(const dtrace_errdata_t *data, void *arg) static int drophandler(const dtrace_dropdata_t *data, void *arg) { - error(data->dtdda_msg); + if (!dtrace_oformat(g_dtp)) { + error(data->dtdda_msg); + } + return (DTRACE_HANDLE_OK); } @@ -1126,7 +1134,9 @@ chew(const dtrace_probedata_t *data, void *arg) } if (!g_flowindent) { - if (!g_quiet) { + if (dtrace_oformat(g_dtp)) { + dtrace_oformat_probe(g_dtp, data, cpu, pd); + } else if (!g_quiet) { char name[DTRACE_FUNCNAMELEN + DTRACE_NAMELEN + 2]; (void) snprintf(name, sizeof (name), "%s:%s", @@ -1313,7 +1323,8 @@ main(int argc, char *argv[]) g_ofp = stdout; int done = 0, mode = 0; - int err, i, c; + int err, i, c, new_argc, libxo_specified; + int print_upon_exit = 0; char *p, **v; struct ps_prochandle *P; pid_t pid; @@ -1336,6 +1347,15 @@ main(int argc, char *argv[]) (g_psv = malloc(sizeof (struct ps_prochandle *) * argc)) == NULL) fatal("failed to allocate memory for arguments"); + new_argc = xo_parse_args(argc, argv); + if (new_argc < 0) + return (usage(stderr)); + + if (new_argc != argc) + libxo_specified = 1; + + argc = new_argc; + g_argv[g_argc++] = argv[0]; /* propagate argv[0] to D as $0/$$0 */ argv[0] = g_pname; /* rewrite argv[0] for getopt errors */ @@ -1532,6 +1552,10 @@ main(int argc, char *argv[]) } else if (g_mode == DMODE_ANON) (void) dtrace_setopt(g_dtp, "linkmode", "primary"); + + if (libxo_specified) + dtrace_oformat_configure(g_dtp); + /* * Now that we have libdtrace open, make a second pass through argv[] * to perform any dtrace_setopt() calls and change any compiler flags. @@ -1624,6 +1648,10 @@ main(int argc, char *argv[]) dcp->dc_arg = optarg; break; + case 'O': + print_upon_exit = 1; + break; + case 'q': if (dtrace_setopt(g_dtp, "quiet", 0) != 0) dfatal("failed to set -q"); @@ -1765,6 +1793,11 @@ main(int argc, char *argv[]) (void) dtrace_getopt(g_dtp, "quiet", &opt); g_quiet = opt != DTRACEOPT_UNSET; + if (dtrace_oformat(g_dtp)) { + if (dtrace_setopt(g_dtp, "quiet", 0) != 0) + dfatal("failed to set quiet (caused by oformat)"); + } + /* * Now make a fifth and final pass over the options that have been * turned into programs and saved in g_cmdv[], performing any mode- @@ -1777,6 +1810,9 @@ main(int argc, char *argv[]) if (g_ofile != NULL && (g_ofp = fopen(g_ofile, "a")) == NULL) fatal("failed to open output file '%s'", g_ofile); + if (dtrace_oformat(g_dtp)) + dtrace_set_outfp(g_ofp); + for (i = 0; i < g_cmdc; i++) exec_prog(&g_cmdv[i]); @@ -1811,6 +1847,9 @@ main(int argc, char *argv[]) if ((g_ofp = fopen(g_ofile, "a")) == NULL) fatal("failed to open output file '%s'", g_ofile); + if (dtrace_oformat(g_dtp)) + dtrace_set_outfp(g_ofp); + for (i = 0; i < g_cmdc; i++) { anon_prog(&g_cmdv[i], dtrace_dof_create(g_dtp, g_cmdv[i].dc_prog, 0), i); @@ -1971,12 +2010,21 @@ main(int argc, char *argv[]) g_pslive = g_psc; /* count for prochandler() */ + dtrace_oformat_setup(g_dtp); do { if (!g_intr && !done) dtrace_sleep(g_dtp); #ifdef __FreeBSD__ - if (g_siginfo) { + /* + * XXX: Supporting SIGINFO with oformat makes little sense, as + * it can't really produce sensible DTrace output. + * + * If needed, we could support it by having an imaginary + * "SIGINFO" probe that we can construct in the output but leave + * it out for now. + */ + if (g_siginfo && !dtrace_oformat(g_dtp)) { (void)dtrace_aggregate_print(g_dtp, g_ofp, NULL); g_siginfo = 0; } @@ -2013,14 +2061,24 @@ main(int argc, char *argv[]) clearerr(g_ofp); } while (!done); - oprintf("\n"); + if (!dtrace_oformat(g_dtp)) + oprintf("\n"); - if (!g_impatient) { + /* + * Since there is no way to format a probe here and machine-readable + * output makes little sense without explicitly asking for it, we print + * nothing upon Ctrl-C if oformat is specified. If the user wishes to + * get output upon exit, they must write an explicit dtrace:::END probe + * to do so. + */ + if ((!g_impatient && !dtrace_oformat(g_dtp)) || + (!g_impatient && print_upon_exit)) { if (dtrace_aggregate_print(g_dtp, g_ofp, NULL) == -1 && dtrace_errno(g_dtp) != EINTR) dfatal("failed to print aggregations"); } + dtrace_oformat_teardown(g_dtp); dtrace_close(g_dtp); return (g_status); } diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.avg.ksh b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.avg.ksh new file mode 100644 index 000000000000..daf5c7f4e9bb --- /dev/null +++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.avg.ksh @@ -0,0 +1,66 @@ +#!/usr/bin/ksh +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright (c) 2023 Domagoj Stolfa +# + +bname=`basename $0` +dtraceout=/tmp/dtrace.$bname + +script() +{ + $dtrace -o $dtraceout.$1 -x oformat=$1 -s /dev/stdin <<__EOF__ +syscall:::entry +{ + @[probefunc] = avg(tid); +} + +tick-5s +{ + exit(0); +} + +END +{ + printa(@); +} +__EOF__ +} + +if [ $# != 1 ]; then + echo expected one argument: '<'dtrace-path'>' + exit 2 +fi + +dtrace=$1 + +script json +jq . $dtraceout.json + +if [ $? != 0 ]; then + echo $bname: failed to produce valid JSON. see $dtraceout.json + exit 1 +fi + +script xml +xmllint $dtraceout.xml + +if [ $? != 0 ]; then + echo $bname: failed to produce valid XML. see $dtraceout.xml + exit 1 +fi + +rm $dtraceout.json +rm $dtraceout.xml + +exit 0 diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.count.ksh b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.count.ksh new file mode 100644 index 000000000000..ab7c5fa28471 --- /dev/null +++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.count.ksh @@ -0,0 +1,66 @@ +#!/usr/bin/ksh +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright (c) 2023 Domagoj Stolfa +# + +bname=`basename $0` +dtraceout=/tmp/dtrace.$bname + +script() +{ + $dtrace -o $dtraceout.$1 -x oformat=$1 -s /dev/stdin <<__EOF__ +syscall:::entry +{ + @[execname] = count(); +} + +tick-5s +{ + exit(0); +} + +END +{ + printa(@); +} +__EOF__ +} + +if [ $# != 1 ]; then + echo expected one argument: '<'dtrace-path'>' + exit 2 +fi + +dtrace=$1 + +script json +jq . $dtraceout.json + +if [ $? != 0 ]; then + echo $bname: failed to produce valid JSON. see $dtraceout.json + exit 1 +fi + +script xml +xmllint $dtraceout.xml + +if [ $? != 0 ]; then + echo $bname: failed to produce valid XML. see $dtraceout.xml + exit 1 +fi + +rm $dtraceout.json +rm $dtraceout.xml + +exit 0 diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.llquantize.ksh b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.llquantize.ksh new file mode 100644 index 000000000000..380335de000a --- /dev/null +++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/oformat/tst.agg.llquantize.ksh @@ -0,0 +1,73 @@ +#!/usr/bin/ksh +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright (c) 2023 Domagoj Stolfa +# + +bname=`basename $0` +dtraceout=/tmp/dtrace.$bname + +script() +{ + $dtrace -o $dtraceout.$1 -x oformat=$1 -s /dev/stdin <<__EOF__ +syscall:::entry +{ + self->ts = timestamp; +} + +syscall:::return +/self->ts/ +{ + @[probefunc] = llquantize(timestamp - self->ts, 2, 1, 32, 32); + self->ts = 0; +} + +tick-5s +{ + exit(0); +} + +END +{ + printa(@); +} +__EOF__ +} + +if [ $# != 1 ]; then + echo expected one argument: '<'dtrace-path'>' + exit 2 +fi + +dtrace=$1 + +script json +jq . $dtraceout.json + +if [ $? != 0 ]; then + echo $bname: failed to produce valid JSON. see $dtraceout.json + exit 1 +fi + +script xml +xmllint $dtraceout.xml + +if [ $? != 0 ]; then *** 4643 LINES SKIPPED *** From nobody Mon Apr 15 14:05:32 2024 X-Original-To: dev-commits-src-branches@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 4VJ88D6Wr0z5Gfgy; Mon, 15 Apr 2024 14:05: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88D31qdz4W4P; Mon, 15 Apr 2024 14:05:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189932; 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=y+DoC4sH10jWeIpgm1Uk5j3A56WG4I2SPFsGYCorOuc=; b=geqZryifnFZz+pe4XggcfW1J7+TVb/8WEt+F+BGi6uWtUG8zM9xXwpcb2q2pVTBTdfsJMs LzC9AFjnKHdVt+U+fy3IlIvlNG4QCSRmxCqhYPSPc27E7ZGHEqaIZrQYr8svKuJrmB0fqD XfIWQtNx4Enqi8y/Tz1OguxRYd4Cwl4UH7/dtJ5LoPjU1iiyZFHVfK62aF4eesW0Titr1C 5JyjNJBrihih2DxwnQoRKO71mewRDdn3fT5SvWIvKE/aTblK9n4P2LdXhidd2YVAUAvHSS KU85Rwn18df1SntsOm5bSwRd7byabrpYOHbBNDJHwn3IDuScIvuEfO+Rgvsq7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189932; a=rsa-sha256; cv=none; b=weSaAZ++wBD7jUABmNfWQEmvbYKI+UwDIOBdp76Ijqn5XSfboocMKXkRVLXzZqSzwmcmM1 3wjxWUHKGzuZnE+1SM4k5rRhf80St7pHTMoQTq7aeLqawpqrFt4YiMlC43OMNgSJwSnE9q yECQvVHRGl6dKVgUTW57xzHRNtGUxb47ZFBO7XRCsZhdjSQzHMdE11jzZAux2pw4pmB/XM MlRA+xwi4/KGIaBSoqASGKu5w3BZvBmFiIUGOl+EzHFfZ4QLfmZk8CkqVsEybpkEuGSgFb 8k5PXsrcH4gwObdU30lRZXXF1eL3/j8lXjj8Jbapnu654sJO7j17hmQ6VAUBng== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189932; 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=y+DoC4sH10jWeIpgm1Uk5j3A56WG4I2SPFsGYCorOuc=; b=KvHCRZwvaGN4h0RZLzzL7KVjng6AVGvqO6ZQxYVJe5tYjJYEL7bvHCubFwJ28xrsCipO60 Qephi5UpBCF21lz+7+Cr6e2UUs9JMbc8219kW7j+HAEOihb+f8pvF1oNP7hc/2mXPH/9u2 3C18lo2j/plqqNi7cl+g/tJRVAcQQFK+HC44UykWcnlvqyhncfM9TiPnDXOLetfff++nAw LMqqwVyVFuiv7iVQ+CCmEBqO8nn5BKmjCxuCN9rHrxDN1paBdIMnyT5rKoIWaZ6L3tZzky XLBm6TFSH9yjy9ggAnx7g/HtnLrXBqfHVfeer0f3QfQHhpUOtJvNOdejf9twOA== 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 4VJ88D2bxSz12h3; Mon, 15 Apr 2024 14:05:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5WDD070045; Mon, 15 Apr 2024 14:05:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5WUi070042; Mon, 15 Apr 2024 14:05:32 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:32 GMT Message-Id: <202404151405.43FE5WUi070042@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 19621b977df3 - stable/14 - kern linker: Don't invoke dtors without having invoked ctors List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 19621b977df3aa11ace8d2f79d3e3e56d9ceaf76 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=19621b977df3aa11ace8d2f79d3e3e56d9ceaf76 commit 19621b977df3aa11ace8d2f79d3e3e56d9ceaf76 Author: Mark Johnston AuthorDate: 2024-03-31 18:14:02 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 kern linker: Don't invoke dtors without having invoked ctors I have a kernel module which fails to load because of an unrecognized relocation type. link_elf_load_file() fails before the module's ctors are invoked and it calls linker_file_unload(), which causes the module's dtors to be executed, resulting in a kernel panic. Add a flag to the linker file to ensure that dtors are not invoked if unloading due to an error prior to ctors being invoked. At the moment I only implemented this for link_elf_obj.c since link_elf.c doesn't invoke dtors, but I refactored link_elf.c to make them more similar. Fixes: 9e575fadf491 ("link_elf_obj: Invoke fini callbacks") Reviewed by: zlei, kib MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D44559 (cherry picked from commit 7ef5c19b219e47684afd9d8d9126df39edc8d885) --- sys/kern/kern_linker.c | 1 + sys/kern/link_elf.c | 15 +++++++++++++-- sys/kern/link_elf_obj.c | 30 +++++++++++++++++++++++++++--- sys/sys/linker.h | 5 +++++ 4 files changed, 46 insertions(+), 5 deletions(-) diff --git a/sys/kern/kern_linker.c b/sys/kern/kern_linker.c index c9e31437c7c6..15fd7e8c30fb 100644 --- a/sys/kern/kern_linker.c +++ b/sys/kern/kern_linker.c @@ -629,6 +629,7 @@ linker_make_file(const char *pathname, linker_class_t lc) return (NULL); lf->ctors_addr = 0; lf->ctors_size = 0; + lf->ctors_invoked = LF_NONE; lf->dtors_addr = 0; lf->dtors_size = 0; lf->refs = 1; diff --git a/sys/kern/link_elf.c b/sys/kern/link_elf.c index 5be2db9d32bf..c7871e8e2e0d 100644 --- a/sys/kern/link_elf.c +++ b/sys/kern/link_elf.c @@ -345,7 +345,7 @@ link_elf_error(const char *filename, const char *s) } static void -link_elf_invoke_ctors(caddr_t addr, size_t size) +link_elf_invoke_cbs(caddr_t addr, size_t size) { void (**ctor)(void); size_t i, cnt; @@ -360,6 +360,17 @@ link_elf_invoke_ctors(caddr_t addr, size_t size) } } +static void +link_elf_invoke_ctors(linker_file_t lf) +{ + KASSERT(lf->ctors_invoked == LF_NONE, + ("%s: file %s ctor state %d", + __func__, lf->filename, lf->ctors_invoked)); + + link_elf_invoke_cbs(lf->ctors_addr, lf->ctors_size); + lf->ctors_invoked = LF_CTORS; +} + /* * Actions performed after linking/loading both the preloaded kernel and any * modules; whether preloaded or dynamicly loaded. @@ -390,7 +401,7 @@ link_elf_link_common_finish(linker_file_t lf) #endif /* Invoke .ctors */ - link_elf_invoke_ctors(lf->ctors_addr, lf->ctors_size); + link_elf_invoke_ctors(lf); return (0); } diff --git a/sys/kern/link_elf_obj.c b/sys/kern/link_elf_obj.c index b853ca284f7d..2718a92d7864 100644 --- a/sys/kern/link_elf_obj.c +++ b/sys/kern/link_elf_obj.c @@ -648,6 +648,30 @@ link_elf_invoke_cbs(caddr_t addr, size_t size) } } +static void +link_elf_invoke_ctors(linker_file_t lf) +{ + KASSERT(lf->ctors_invoked == LF_NONE, + ("%s: file %s ctor state %d", + __func__, lf->filename, lf->ctors_invoked)); + + link_elf_invoke_cbs(lf->ctors_addr, lf->ctors_size); + lf->ctors_invoked = LF_CTORS; +} + +static void +link_elf_invoke_dtors(linker_file_t lf) +{ + KASSERT(lf->ctors_invoked != LF_DTORS, + ("%s: file %s ctor state %d", + __func__, lf->filename, lf->ctors_invoked)); + + if (lf->ctors_invoked == LF_CTORS) { + link_elf_invoke_cbs(lf->dtors_addr, lf->dtors_size); + lf->ctors_invoked = LF_DTORS; + } +} + static int link_elf_link_preload_finish(linker_file_t lf) { @@ -674,7 +698,7 @@ link_elf_link_preload_finish(linker_file_t lf) /* Apply protections now that relocation processing is complete. */ link_elf_protect(ef); - link_elf_invoke_cbs(lf->ctors_addr, lf->ctors_size); + link_elf_invoke_ctors(lf); return (0); } @@ -1230,7 +1254,7 @@ link_elf_load_file(linker_class_t cls, const char *filename, #endif link_elf_protect(ef); - link_elf_invoke_cbs(lf->ctors_addr, lf->ctors_size); + link_elf_invoke_ctors(lf); *result = lf; out: @@ -1250,7 +1274,7 @@ link_elf_unload_file(linker_file_t file) elf_file_t ef = (elf_file_t) file; u_int i; - link_elf_invoke_cbs(file->dtors_addr, file->dtors_size); + link_elf_invoke_dtors(file); /* Notify MD code that a module is being unloaded. */ elf_cpu_unload_file(file); diff --git a/sys/sys/linker.h b/sys/sys/linker.h index b94cd9f27405..461a32d5529b 100644 --- a/sys/sys/linker.h +++ b/sys/sys/linker.h @@ -82,6 +82,11 @@ struct linker_file { size_t size; /* size of file */ caddr_t ctors_addr; /* address of .ctors/.init_array */ size_t ctors_size; /* size of .ctors/.init_array */ + enum { + LF_NONE = 0, + LF_CTORS, + LF_DTORS, + } ctors_invoked; /* have we run ctors yet? */ caddr_t dtors_addr; /* address of .dtors/.fini_array */ size_t dtors_size; /* size of .dtors/.fini_array */ int ndeps; /* number of dependencies */ From nobody Mon Apr 15 14:05:33 2024 X-Original-To: dev-commits-src-branches@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 4VJ88F6DVyz5Gflf; Mon, 15 Apr 2024 14:05:33 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88F4PFPz4WGl; Mon, 15 Apr 2024 14:05:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189933; 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=FyoANJ/YO59USUCZGA/9ojt1L/neg6OX5ymrHmxW288=; b=ZSe3lkNV5m04unYY+uQZpdhWmzcG1fY82pLcEGeLb06kfH1qK6oxtNA41jhJkpDHsg47bn Xbd4miPmk2lpQmiNYLsVXo9EKUlxNihCfeRQeEbt3lP66roWsrvFHZcRBca6ISBBNVLjJr 8nMR6RAwfLXjA1QUz02YjOdYRn2sd+fVL+AmKingDFvJsKw4827lwIuWK6Ln5cDpf4iRta aNdT0JKP9+yWOWh/ljmUYFErvysReSJ+j9Brs/TV3OffjiE+D1XWxjqsHiVstytKgo4I6m KEOGa1uaImBoU+XvPdEzn9r/mMV9674Y1ifOsnyKgbPuIqPQwPhc8AI/5aI9Ew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189933; a=rsa-sha256; cv=none; b=i3Jn7Z6JCjFb+Q2sRff6vhqAlorNvwCupuFVlLHPMgd90kN+nIORctre9EXNz9RdadF6bZ f+n7k+FR7SL9x1h+AOPd0E96XiH11Hf+hu9UO7U4drsYCofrMaz2LnVTp5sw7Qqd0PFpwk OBP42WzQqCDlgO0t/mlV2+PdvJC9lMtT9d46avANc73cXHcf20i2kU3cV+3BrQP+WXz8pY IAhhdaVtT585/PJT8HsnCeUoyJ1kZL4i5iBB9ba/fSiWGgCbCKLfqIrF9m52GWEjTGvNPl 95OxDHUkzrQv+ghloPI4577dnTagi4mrwCDeooPjwppC/KOtUBOwx+qGLLhxEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189933; 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=FyoANJ/YO59USUCZGA/9ojt1L/neg6OX5ymrHmxW288=; b=L6tFw6z5j3parl7Jm3h86Es8AuIq7Euwit0KKprbhacUNZ28sJ6XtqbEoXX16kdE/1ESmM OLDjMVg5+ZKiwKl9pF+7GZeqove+t13ZAxteuS3kss0uFuMDm3mRNynstbnn70BwhKrpwp Ft+roXR3zdWn9hXEf8SrRThlH84eOxammvl4EPEMIe3SkUN8atQWypB1ynn1E5gDadr4mP xnmLy1Nhsfr3kMZzM+QYNY3G14+miy9ZUOmNIWruSFt9QuMOusD2gFThg3QjU6n0dpdojo WXi+I7Ux/2qUPI/HPcmd7eh9VUBWNqrFWrKwn4jUj8eHx3+TZzjsR2tkkYGX7Q== 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 4VJ88F3jvgz136Y; Mon, 15 Apr 2024 14:05:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5X7N070109; Mon, 15 Apr 2024 14:05:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5Xm1070106; Mon, 15 Apr 2024 14:05:33 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:33 GMT Message-Id: <202404151405.43FE5Xm1070106@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 16f6ce3f826b - stable/14 - ptrace tests: Add a test using PROC_REAP_KILL to kill a traced debuggee List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 16f6ce3f826b402390459ece55df719737695abb Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=16f6ce3f826b402390459ece55df719737695abb commit 16f6ce3f826b402390459ece55df719737695abb Author: Mark Johnston AuthorDate: 2024-03-31 18:11:47 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 ptrace tests: Add a test using PROC_REAP_KILL to kill a traced debuggee This exercises the bug fix in commit 9241ebc796c1 ("thread_single(9): decline external requests for traced or debugger-stopped procs"). Reviewed by: kib MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D44564 (cherry picked from commit 43b4da44118e4fe29e9d7456db4390c9cbb53636) --- tests/sys/kern/ptrace_test.c | 47 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/tests/sys/kern/ptrace_test.c b/tests/sys/kern/ptrace_test.c index 5666215f9377..5152affa0e8b 100644 --- a/tests/sys/kern/ptrace_test.c +++ b/tests/sys/kern/ptrace_test.c @@ -4369,6 +4369,52 @@ ATF_TC_BODY(ptrace__PT_SC_REMOTE_getpid, tc) ATF_REQUIRE(ptrace(PT_DETACH, fpid, (caddr_t)1, 0) != -1); } +/* + * Ensure that procctl(PROC_REAP_KILL) won't block forever waiting for a target + * process that stopped to report its status to a debugger. + */ +ATF_TC_WITHOUT_HEAD(ptrace__reap_kill_stopped); +ATF_TC_BODY(ptrace__reap_kill_stopped, tc) +{ + struct procctl_reaper_kill prk; + pid_t debuggee, wpid; + int error, status; + + REQUIRE_EQ(procctl(P_PID, getpid(), PROC_REAP_ACQUIRE, NULL), 0); + + debuggee = fork(); + ATF_REQUIRE(debuggee >= 0); + if (debuggee == 0) { + trace_me(); + for (;;) + sleep(10); + _exit(0); + } + wpid = waitpid(debuggee, &status, 0); + REQUIRE_EQ(wpid, debuggee); + ATF_REQUIRE(WIFSTOPPED(status)); + REQUIRE_EQ(WSTOPSIG(status), SIGSTOP); + + /* Resume the child and ask it to stop during syscall exits. */ + ATF_REQUIRE(ptrace(PT_TO_SCX, debuggee, (caddr_t)1, 0) != -1); + + /* Give the debuggee some time to go to sleep. */ + usleep(100000); + + /* + * Kill the child process. procctl() may attempt to stop the target + * process to prevent it from adding new children to the reaper subtree, + * and this should not conflict with the child stopping itself for the + * debugger. + */ + memset(&prk, 0, sizeof(prk)); + prk.rk_sig = SIGTERM; + error = procctl(P_PID, getpid(), PROC_REAP_KILL, &prk); + REQUIRE_EQ(error, 0); + REQUIRE_EQ(1, prk.rk_killed); + REQUIRE_EQ(-1, prk.rk_fpid); +} + ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, ptrace__parent_wait_after_trace_me); @@ -4435,6 +4481,7 @@ ATF_TP_ADD_TCS(tp) ATF_TP_ADD_TC(tp, ptrace__procdesc_wait_child); ATF_TP_ADD_TC(tp, ptrace__procdesc_reparent_wait_child); ATF_TP_ADD_TC(tp, ptrace__PT_SC_REMOTE_getpid); + ATF_TP_ADD_TC(tp, ptrace__reap_kill_stopped); return (atf_no_error()); } From nobody Mon Apr 15 14:05:34 2024 X-Original-To: dev-commits-src-branches@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 4VJ88H0PjSz5GfXM; Mon, 15 Apr 2024 14:05:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88G4lR5z4WLr; Mon, 15 Apr 2024 14:05:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189934; 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=9sK50jesC3F6HnNkVEsTS0MQnYTws+in5EoHILmF4Is=; b=ybfhhBwudNTEK1gnOOYF+BgKr/wJRImafN7HSmqWp6+Ncu4qo2wqiwexId4LUICmtlrKE9 nT3V5+03byI4/PBsiXJD0OxI8chhePvUgqYXpHrmmY+zpXZCvc24EDsQqsnIAguNPi5d7Y mDZxXLQglUffbTgSI5/K+95Lr3hCBROoE7keN3MlBr+J3RZK+gpUcp4DCHoT1/i41GEqWU QPJ2RqsWoTsYjQDOdawjayXst9puTUrhNXB6d4KYU7nPQyFMDnowS3j0k/u3SMQFcca5EM QrzQmibqkpkNO6Rx5x6yMKVQSpH4iRLRpMN3wT2YnVF2G9t0hptE4fffIvC4rQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189934; a=rsa-sha256; cv=none; b=gXp7aFAwKVCxVpJBSuOyVFhUbGyCvbaE0/NX7N+JPmdjFjZphZFBBww2QyB/BYRz9lx4Bv ixTFulhdXHOHwHkXaYi5vhWSDgRvmXiQd7GndIS+uy/sFyh3l3yhO8PAZkp9cqGg3hJ6xY PeuNnki0VHFi81EiBc/wh3x5GP7lR58oec7gLtkBkSe5zYy7vE5Jt1eegHFJXmUzF0ChU+ Vbjpw78mIiAPD5iWd/U1FifD1jMQCVstRAKsIBC1EX/REoS4bq5VccRrJjtPj6u+KjNc3U rESKbGm3SJlII2o86L7KKQGEY+7AGgmBotTf6SFPGCT4KnzEXIQtq/r5bHkZcQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189934; 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=9sK50jesC3F6HnNkVEsTS0MQnYTws+in5EoHILmF4Is=; b=bwDcAuk1Y+VkP9KvXQs0Slz5Hk+GJH6Vnv5r75nQExWTSA+W0p/+2W7vxL+TuXVZ0g8C1V gxVjpqFLM/YDX2Ev+kTd2qOsWHPPFA56J71paqMl4YQS9idOIxxfMHsuWvhsGVq5uMuezn WGfY03PK/iVTfkDOO3vL8H1rMYQvQzsdy/aX07t8maVhxWBccCTWbjTquKOS6I+uctAkIK Ff+9hbNUQyj8A406vGwy4bMIKb8Z/DqrHWGh8cqdWYW0D4ONctMs1E2R54gd0enl6GHslv H0ol3yXAV2pdPgGanlv40+jCKIMNJlfmNAQeduP+WTAEBHAKXMy9hcWWXX/FkQ== 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 4VJ88G4MGQz12sV; Mon, 15 Apr 2024 14:05:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5Y4q070157; Mon, 15 Apr 2024 14:05:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5YZB070154; Mon, 15 Apr 2024 14:05:34 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:34 GMT Message-Id: <202404151405.43FE5YZB070154@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 615bd9d0a056 - stable/14 - ptrace tests: Fix a signed/unsigned integer comparison List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 615bd9d0a056331bbd375a34f0ae87521a4073b2 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=615bd9d0a056331bbd375a34f0ae87521a4073b2 commit 615bd9d0a056331bbd375a34f0ae87521a4073b2 Author: Mark Johnston AuthorDate: 2024-04-01 23:10:36 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 ptrace tests: Fix a signed/unsigned integer comparison Reported by: Jenkins Fixes: 43b4da44118e ("ptrace tests: Add a test using PROC_REAP_KILL to kill a traced debuggee") (cherry picked from commit 77c3e564b4b65443a9d3298e0aec4c1387acd55e) --- tests/sys/kern/ptrace_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/sys/kern/ptrace_test.c b/tests/sys/kern/ptrace_test.c index 5152affa0e8b..40a9beda3006 100644 --- a/tests/sys/kern/ptrace_test.c +++ b/tests/sys/kern/ptrace_test.c @@ -4411,7 +4411,7 @@ ATF_TC_BODY(ptrace__reap_kill_stopped, tc) prk.rk_sig = SIGTERM; error = procctl(P_PID, getpid(), PROC_REAP_KILL, &prk); REQUIRE_EQ(error, 0); - REQUIRE_EQ(1, prk.rk_killed); + REQUIRE_EQ(1u, prk.rk_killed); REQUIRE_EQ(-1, prk.rk_fpid); } From nobody Mon Apr 15 14:05:35 2024 X-Original-To: dev-commits-src-branches@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 4VJ88J0gR2z5Gfjx; Mon, 15 Apr 2024 14:05:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88H5Xw4z4WRT; Mon, 15 Apr 2024 14:05:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189935; 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=yNtm4apWSn4DwdDGmJdMjwCIFP7dHIPvUZFmxzzMu6k=; b=xUUoHH275wbLcdL2XHIfjaxiQ5+rLXCtaRJeRTLMXj6vIzpFHZWM5p6Ht8IemANYcS/QUz uzm/I5xP0s6tyVc7iGxLEAZJ0smzuCT7qH1gp+YUGH5rvHfL9mjyQoADTYd/bIWfRKIPIz mnSP+VsCNGn36BWkLdOn/PqEvKGWxVXRm90PkKZvVqA0ytMyVrMNI0Qb3JcRLV49mwsjhl Dz8xbX0uxS8V4yLK12jEloIzPZB7nCHPL6dNe1I+4dJst19VqjCwww+dZNvf41k7yoMix7 ueoeEiRB+Taq5/rNQc6qS8MzsJItD5b/lWpL01a9G/QtbCeucmfDsIkltSrG7g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189935; a=rsa-sha256; cv=none; b=O4shBYzEQVA2++tzijkCBQ+ppkisTG/5felHyMfZ6OmFv1jCw3MgfuwXysDp6WJV7aBuM6 jLJO/ui1fN2pRUBVQDMrT9srjOzSlZTU0bZa6oiIo9HdGMDuUrOP5kz0LlmxrnXCEWoiTQ SAwSxnjwuyy41XAaB34zSsWAgs/B6zjVxq2U4FPzG989t4v0GEzakUwjfUuM4y3l2EvFQd BrCkGdtGqK62BoL5szy6pG3QoY0OPBCBT2hcOOn/ty7NAVLsGL2rUfjgiZcBPK5smrudkh nmdxJOPfhzdIIfvx+7UemHGXhWedxoehGcHf8fA6upCow+QVE42nIocnhxGKCA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189935; 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=yNtm4apWSn4DwdDGmJdMjwCIFP7dHIPvUZFmxzzMu6k=; b=mIRCnrc9t7a85WuDMql+vxCknGjs6nmRlQQCy3bpPS0amFIczMGQ6E02tOU+2/OABh2qzp SzxRBzBq3yfV/rmTFMHxuFvNfSsmFiPk+HElfi49hPSNmVn2kNWSipZ+pStuGDk+wY4L5E Y+AhJ+03MeUP3yoabrs9ciKYRcA4O92M3q3wxQj7z70lZ/psV8+RQQhxkQRoMSvkOhaTak 4uA4Acr9uI+YAJ76feUQTauYFnwszkkNhb1P41No+kglcN+T4zPZgGPIN5lvlbkoemOZGc eUvc5XRRxjFahAJBjk8lD8ja0waVpvvGA35moFUQdDAuOJVsT7rRNZc5GKAzGg== 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 4VJ88H55fxz12sW; Mon, 15 Apr 2024 14:05:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5ZxP070205; Mon, 15 Apr 2024 14:05:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5Z6u070202; Mon, 15 Apr 2024 14:05:35 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:35 GMT Message-Id: <202404151405.43FE5Z6u070202@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: a65d02d1d772 - stable/14 - bhyvectl: generate usage from options table List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a65d02d1d77275c2c91db07a7f031986251118ae Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=a65d02d1d77275c2c91db07a7f031986251118ae commit a65d02d1d77275c2c91db07a7f031986251118ae Author: Rob Norris AuthorDate: 2024-04-08 13:07:32 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 bhyvectl: generate usage from options table The usage text had fallen out of sync with the actually available options. Rather than keep them in sync by hand, just generate usage from the available options. Signed-off-by: Rob Norris Reviewed by: markj MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44641 (cherry picked from commit b9fa1500cb2265b95927e19b9d2119ca26d65be3) --- usr.sbin/bhyvectl/bhyvectl.c | 245 +++++++++++-------------------------------- 1 file changed, 63 insertions(+), 182 deletions(-) diff --git a/usr.sbin/bhyvectl/bhyvectl.c b/usr.sbin/bhyvectl/bhyvectl.c index 843e7a7b9dd5..050d72f013df 100644 --- a/usr.sbin/bhyvectl/bhyvectl.c +++ b/usr.sbin/bhyvectl/bhyvectl.c @@ -72,184 +72,6 @@ static const char *progname; -static void -usage(bool cpu_intel) -{ - - (void)fprintf(stderr, - "Usage: %s --vm=\n" - " [--cpu=]\n" - " [--create]\n" - " [--destroy]\n" -#ifdef BHYVE_SNAPSHOT - " [--checkpoint= | --suspend=]\n" -#endif - " [--get-all]\n" - " [--get-stats]\n" - " [--set-desc-ds]\n" - " [--get-desc-ds]\n" - " [--set-desc-es]\n" - " [--get-desc-es]\n" - " [--set-desc-gs]\n" - " [--get-desc-gs]\n" - " [--set-desc-fs]\n" - " [--get-desc-fs]\n" - " [--set-desc-cs]\n" - " [--get-desc-cs]\n" - " [--set-desc-ss]\n" - " [--get-desc-ss]\n" - " [--set-desc-tr]\n" - " [--get-desc-tr]\n" - " [--set-desc-ldtr]\n" - " [--get-desc-ldtr]\n" - " [--set-desc-gdtr]\n" - " [--get-desc-gdtr]\n" - " [--set-desc-idtr]\n" - " [--get-desc-idtr]\n" - " [--run]\n" - " [--capname=]\n" - " [--getcap]\n" - " [--setcap=<0|1>]\n" - " [--desc-base=]\n" - " [--desc-limit=]\n" - " [--desc-access=]\n" - " [--set-cr0=]\n" - " [--get-cr0]\n" - " [--set-cr2=]\n" - " [--get-cr2]\n" - " [--set-cr3=]\n" - " [--get-cr3]\n" - " [--set-cr4=]\n" - " [--get-cr4]\n" - " [--set-dr0=]\n" - " [--get-dr0]\n" - " [--set-dr1=]\n" - " [--get-dr1]\n" - " [--set-dr2=]\n" - " [--get-dr2]\n" - " [--set-dr3=]\n" - " [--get-dr3]\n" - " [--set-dr6=]\n" - " [--get-dr6]\n" - " [--set-dr7=]\n" - " [--get-dr7]\n" - " [--set-rsp=]\n" - " [--get-rsp]\n" - " [--set-rip=]\n" - " [--get-rip]\n" - " [--get-rax]\n" - " [--set-rax=]\n" - " [--get-rbx]\n" - " [--get-rcx]\n" - " [--get-rdx]\n" - " [--get-rsi]\n" - " [--get-rdi]\n" - " [--get-rbp]\n" - " [--get-r8]\n" - " [--get-r9]\n" - " [--get-r10]\n" - " [--get-r11]\n" - " [--get-r12]\n" - " [--get-r13]\n" - " [--get-r14]\n" - " [--get-r15]\n" - " [--set-rflags=]\n" - " [--get-rflags]\n" - " [--set-cs]\n" - " [--get-cs]\n" - " [--set-ds]\n" - " [--get-ds]\n" - " [--set-es]\n" - " [--get-es]\n" - " [--set-fs]\n" - " [--get-fs]\n" - " [--set-gs]\n" - " [--get-gs]\n" - " [--set-ss]\n" - " [--get-ss]\n" - " [--get-tr]\n" - " [--get-ldtr]\n" - " [--set-x2apic-state=]\n" - " [--get-x2apic-state]\n" - " [--unassign-pptdev=]\n" - " [--set-mem=]\n" - " [--get-lowmem]\n" - " [--get-highmem]\n" - " [--get-gpa-pmap]\n" - " [--assert-lapic-lvt=]\n" - " [--inject-nmi]\n" - " [--force-reset]\n" - " [--force-poweroff]\n" - " [--get-rtc-time]\n" - " [--set-rtc-time=]\n" - " [--get-rtc-nvram]\n" - " [--set-rtc-nvram=]\n" - " [--rtc-nvram-offset=]\n" - " [--get-active-cpus]\n" - " [--get-debug-cpus]\n" - " [--get-suspended-cpus]\n" - " [--get-intinfo]\n" - " [--get-eptp]\n" - " [--set-exception-bitmap]\n" - " [--get-exception-bitmap]\n" - " [--get-tsc-offset]\n" - " [--get-guest-pat]\n" - " [--get-io-bitmap-address]\n" - " [--get-msr-bitmap]\n" - " [--get-msr-bitmap-address]\n" - " [--get-guest-sysenter]\n" - " [--get-exit-reason]\n" - " [--get-cpu-topology]\n", - progname); - - if (cpu_intel) { - (void)fprintf(stderr, - " [--get-vmcs-pinbased-ctls]\n" - " [--get-vmcs-procbased-ctls]\n" - " [--get-vmcs-procbased-ctls2]\n" - " [--get-vmcs-entry-interruption-info]\n" - " [--set-vmcs-entry-interruption-info=]\n" - " [--get-vmcs-guest-physical-address\n" - " [--get-vmcs-guest-linear-address\n" - " [--get-vmcs-host-pat]\n" - " [--get-vmcs-host-cr0]\n" - " [--get-vmcs-host-cr3]\n" - " [--get-vmcs-host-cr4]\n" - " [--get-vmcs-host-rip]\n" - " [--get-vmcs-host-rsp]\n" - " [--get-vmcs-cr0-mask]\n" - " [--get-vmcs-cr0-shadow]\n" - " [--get-vmcs-cr4-mask]\n" - " [--get-vmcs-cr4-shadow]\n" - " [--get-vmcs-cr3-targets]\n" - " [--get-vmcs-apic-access-address]\n" - " [--get-vmcs-virtual-apic-address]\n" - " [--get-vmcs-tpr-threshold]\n" - " [--get-vmcs-vpid]\n" - " [--get-vmcs-instruction-error]\n" - " [--get-vmcs-exit-ctls]\n" - " [--get-vmcs-entry-ctls]\n" - " [--get-vmcs-link]\n" - " [--get-vmcs-exit-qualification]\n" - " [--get-vmcs-exit-interruption-info]\n" - " [--get-vmcs-exit-interruption-error]\n" - " [--get-vmcs-interruptibility]\n" - ); - } else { - (void)fprintf(stderr, - " [--get-vmcb-intercepts]\n" - " [--get-vmcb-asid]\n" - " [--get-vmcb-exit-details]\n" - " [--get-vmcb-tlb-ctrl]\n" - " [--get-vmcb-virq]\n" - " [--get-avic-apic-bar]\n" - " [--get-avic-backing-page]\n" - " [--get-avic-table]\n" - ); - } - exit(1); -} - static int get_rtc_time, set_rtc_time; static int get_rtc_nvram, set_rtc_nvram; static int rtc_nvram_offset; @@ -1567,6 +1389,65 @@ setup_options(bool cpu_intel) return (all_opts); } +static void +usage(const struct option *opts) +{ + static const char *set_desc[] = { + [VCPU] = "vcpu_number", + [SET_MEM] = "memory in units of MB", + [SET_EFER] = "EFER", + [SET_CR0] = "CR0", + [SET_CR2] = "CR2", + [SET_CR3] = "CR3", + [SET_CR4] = "CR4", + [SET_DR0] = "DR0", + [SET_DR1] = "DR1", + [SET_DR2] = "DR2", + [SET_DR3] = "DR3", + [SET_DR6] = "DR6", + [SET_DR7] = "DR7", + [SET_RSP] = "RSP", + [SET_RIP] = "RIP", + [SET_RAX] = "RAX", + [SET_RFLAGS] = "RFLAGS", + [DESC_BASE] = "BASE", + [DESC_LIMIT] = "LIMIT", + [DESC_ACCESS] = "ACCESS", + [SET_CS] = "CS", + [SET_DS] = "DS", + [SET_ES] = "ES", + [SET_FS] = "FS", + [SET_GS] = "GS", + [SET_SS] = "SS", + [SET_TR] = "TR", + [SET_LDTR] = "LDTR", + [SET_X2APIC_STATE] = "state", + [SET_CAP] = "0|1", + [CAPNAME] = "capname", + [UNASSIGN_PPTDEV] = "bus/slot.func", + [GET_GPA_PMAP] = "gpa", + [ASSERT_LAPIC_LVT] = "pin", + [SET_RTC_TIME] = "secs", + [SET_RTC_NVRAM] = "val", + [RTC_NVRAM_OFFSET] = "offset", +#ifdef BHYVE_SNAPSHOT + [SET_CHECKPOINT_FILE] = "filename", + [SET_SUSPEND_FILE] = "filename", +#endif + }; + (void)fprintf(stderr, "Usage: %s --vm=\n", progname); + for (const struct option *o = opts; o->name; o++) { + if (strcmp(o->name, "vm") == 0) + continue; + if (o->has_arg == REQ_ARG) + (void)fprintf(stderr, " [--%s=<%s>]\n", + o->name, set_desc[o->val]); + else + (void)fprintf(stderr, " [--%s]\n", o->name); + } + exit(1); +} + static const char * wday_str(int idx) { @@ -1916,7 +1797,7 @@ main(int argc, char *argv[]) case UNASSIGN_PPTDEV: unassign_pptdev = 1; if (sscanf(optarg, "%d/%d/%d", &bus, &slot, &func) != 3) - usage(cpu_intel); + usage(opts); break; case ASSERT_LAPIC_LVT: assert_lapic_lvt = atoi(optarg); @@ -1925,21 +1806,21 @@ main(int argc, char *argv[]) case SET_CHECKPOINT_FILE: case SET_SUSPEND_FILE: if (checkpoint_file != NULL) - usage(cpu_intel); + usage(opts); checkpoint_file = optarg; vm_suspend_opt = (ch == SET_SUSPEND_FILE); break; #endif default: - usage(cpu_intel); + usage(opts); } } argc -= optind; argv += optind; if (vmname == NULL) - usage(cpu_intel); + usage(opts); error = 0; From nobody Mon Apr 15 14:05:36 2024 X-Original-To: dev-commits-src-branches@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 4VJ88K0qJCz5GfdH; Mon, 15 Apr 2024 14:05:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88J6TCkz4WMS; Mon, 15 Apr 2024 14:05:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189936; 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=CWtdVI95IYfwbhqqHNvBKay+c0/C6TiBQ8GmRIFPf5w=; b=D/myBkGqv0SgCcW+najOBzz5F/EeGp6EhFgYGcvfhD3/Gjs77M5cQc3kXkDrQVXMFt54HQ Mks3Jywv9ITjMivsQIii85nQxZZHNe0uXAK/2VYfHNBgPQzbP8eoXo32CudNbXZ/G9uZv3 zIlZhzUuNj77xb++rCSAXV5tiV7kEC8HFvzNr4F0n5sMvt9f9O04uuVgMj0uRRlORsHIl6 dJwfX7HkmGGCJ5EDtMvHUf4KkJffaZpnpqKkEFHZ2WdxBUM6obMGfL2kGndzE9kwS/WYmn TlUoQrazJgvsg6jNJ7jt4CTWpkq8XOFYH60TdpHehGm4bcwgdvuuJxexQWj4zw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189936; a=rsa-sha256; cv=none; b=OM6ZFsRgrLc7T2E3VCwoyr5IgJ21RLDkBB9wb87wOp5j0V8ID95gOg20GMzMR7LvDfEjmQ cR0fbUiZN3KP+kT2J3M1cR/jmd6zdy01AP9pCdkFrJcu/QS4amJw/aCaY4JRL+VRtFVv9d sip1LVZoXPofQRuYDEPsfkuygrs0KpYKKQCOyAfV/tvgFiEbaCG0yAJOU9RzznjE3Q1hEQ Tt5GpxFfWxM6/o0jVJnHyiBxn7QZFY+j/DC0dNLx+UM/alHMn7H+UnDqcLav/YBZ8LNtsd mOvCgET+WhnsB37+s5QPpWFMxcCYzC4LhLDS6GCZNmzjdDbvC0XQsTQRfoCnPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189936; 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=CWtdVI95IYfwbhqqHNvBKay+c0/C6TiBQ8GmRIFPf5w=; b=Gxspps9YfS3LWD5nrb4dpMTqD+rCVZdAICODPGGs543SjHr3KpnGKHy7enH18G3OuD6eNQ Fsmu05moTNOle1y5bzUoNPutpwD9q+K8uSGeSx9bw4CGcqa2FgfZHAkw5ASuCehEZ9xYXR 23w3wL0w4qzF17rxnHLuTKuFxw99bZ7zp08yLSg+ZFssjkdyxmk9UK2uWPmpkeW8L1tA+q TM9eu3z5+RkzUevYhnNRyqZN0yLL556/Vbu6UgPSEv7YNtarXR1b5qHuExgKZYeVFFOrRW IUq7tXoienJR+yVvlUkXeVAQ9lcezNak6rgNFq+3B2AJnEsoCUelxWlHK3KZrA== 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 4VJ88J65clz12JK; Mon, 15 Apr 2024 14:05:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5aGJ070248; Mon, 15 Apr 2024 14:05:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5aid070245; Mon, 15 Apr 2024 14:05:36 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:36 GMT Message-Id: <202404151405.43FE5aid070245@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: f26c227c421f - stable/14 - libvmmapi: add missing capability strings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f26c227c421f783c23ad2878719623e2861459f3 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=f26c227c421f783c23ad2878719623e2861459f3 commit f26c227c421f783c23ad2878719623e2861459f3 Author: Rob Norris AuthorDate: 2024-04-08 13:08:20 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 libvmmapi: add missing capability strings Signed-off-by: Rob Norris Reviewed by: markj MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44642 (cherry picked from commit b6c7ff583fdb11bf611d58022aea15461c6158e9) --- lib/libvmmapi/vmmapi.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/libvmmapi/vmmapi.c b/lib/libvmmapi/vmmapi.c index d1470a4aed6e..e053950a2c5f 100644 --- a/lib/libvmmapi/vmmapi.c +++ b/lib/libvmmapi/vmmapi.c @@ -918,6 +918,11 @@ static const char *capstrmap[] = { [VM_CAP_UNRESTRICTED_GUEST] = "unrestricted_guest", [VM_CAP_ENABLE_INVPCID] = "enable_invpcid", [VM_CAP_BPT_EXIT] = "bpt_exit", + [VM_CAP_RDPID] = "rdpid", + [VM_CAP_RDTSCP] = "rdtscp", + [VM_CAP_IPI_EXIT] = "ipi_exit", + [VM_CAP_MASK_HWINTR] = "mask_hwintr", + [VM_CAP_RFLAGS_TF] = "rflags_tf", }; int From nobody Mon Apr 15 14:05:37 2024 X-Original-To: dev-commits-src-branches@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 4VJ88L4Wlzz5GfdQ; Mon, 15 Apr 2024 14:05:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88L0j8Gz4WY2; Mon, 15 Apr 2024 14:05:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189938; 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=GGKPlGkIAMuzz3LWzLjjvoOZNT1TlIQuL4if/jhN5sU=; b=KI66ZOPnlGDzhXv58AS55shzGXRV8tS7VHQlMpfLEjxYGcRiqTPGTJ85GrojNVRggtiEnR 9KegSQruFxcMyWGUu7B3oCiFeSBlb4PSmKKPTwiVhTBMrorrwGOe2aBJScrZo1OnXr/LMw dQ+TrIMHAOEkSI40vdjjkeC8Ooqta0XsZB+X482xliz5yDimEKT4MMpSqBj5TaLROR9kwI BvgQeepntUsTh43lVI7SmLhkYExt/OkGmJGiV57QHivr5AOF9/Bu9MSIHx7CFATZmLHWYl 4EfNIXurClMWLn+OiRX7XfD4qAkByGU5CQH80R1SmFHPCfc0u+wG2efqf63MRg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189938; a=rsa-sha256; cv=none; b=wpLTouXc8uzDTFxY5J70otApqiTW/GryqzVzxDDT0E4xeLYQBOrQi8Z2lsCey02Fzq8/me IrqNLEnfLBFW74C2bjU5d52zT1RXKMuxJw5oedjpWuno1FKjWLjVuBKWGQn+o49RaYoiDA BaGxefNm0eD/xtNUaHjyHvjd+1kGWerbZOTYf15BXusvV+El71r32DjW3LbAf4j1qxEdYt 3AKgYsWu7TLMyJD2DjRWIthosfFG85vCQJYyQzrKEemj+oSmBSujc1+fzq79w0W8kZy4UV I/fwG3iNi1DrIgKlZPS0VpvUjb/9A9W+ovSauKJmtXFO9OsL6QwaHCUvyPCErQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189938; 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=GGKPlGkIAMuzz3LWzLjjvoOZNT1TlIQuL4if/jhN5sU=; b=Br+4EOUjaPf0FaNI0caC9X4E2b2lwAIjydsWF+iu6dAcos/9rEnfJD5vzQt3CG5smGUR5b EfCGDCYS3YTWBea37952X8TKgNdTPHAPmP29EKV7+nB2TQjqWZ6UsOVFYDgvzHybGifgpF Ym+MJzr2JCrc37UtHIgyjhO0BafsUSkcn4eD36ch4XaODgf/ExBaPX/9D9eOEcLpXQJipV aacYqq2ScgI7KamR5PDH616I+LD3Qxize8P9/ow4yyJG3yiGiJBQ0KcwTx0cYHRfHw5sek BIx7LDzrhLbXTiMrYDM2o3f5bVo2+ULMZmi/UURTp+DbgWiH5gB+AKuZi0IBaw== 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 4VJ88L0KM3z136Z; Mon, 15 Apr 2024 14:05:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5bN9070302; Mon, 15 Apr 2024 14:05:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5blB070299; Mon, 15 Apr 2024 14:05:37 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:37 GMT Message-Id: <202404151405.43FE5blB070299@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 14148b5c5cd6 - stable/14 - wg: Use ENETUNREACH when transmitting to a non-existent peer List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 14148b5c5cd602f57a7536fe295632173939380e Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=14148b5c5cd602f57a7536fe295632173939380e commit 14148b5c5cd602f57a7536fe295632173939380e Author: Mark Johnston AuthorDate: 2024-04-01 17:20:55 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 wg: Use ENETUNREACH when transmitting to a non-existent peer The old errno value used is specifically for Capsicum and shouldn't be co-opted in this way. It has special handling in the generic syscall layer (see syscallret()). OpenBSD returns ENETUNREACH in this case; let's do the same thing. Reviewed by: kevans, imp MFC after: 2 weeks Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44582 (cherry picked from commit 63613e3ba1e188e9fece43e1613bd697f04b345e) --- sys/dev/wg/if_wg.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/dev/wg/if_wg.c b/sys/dev/wg/if_wg.c index 25fa53c2e672..bf4eef31c0b3 100644 --- a/sys/dev/wg/if_wg.c +++ b/sys/dev/wg/if_wg.c @@ -251,9 +251,6 @@ struct wg_softc { #define MAX_LOOPS 8 #define MTAG_WGLOOP 0x77676c70 /* wglp */ -#ifndef ENOKEY -#define ENOKEY ENOTCAPABLE -#endif #define GROUPTASK_DRAIN(gtask) \ gtaskqueue_drain((gtask)->gt_taskqueue, &(gtask)->gt_task) @@ -2113,7 +2110,7 @@ wg_xmit(if_t ifp, struct mbuf *m, sa_family_t af, uint32_t mtu) BPF_MTAP2_AF(ifp, m, pkt->p_af); if (__predict_false(peer == NULL)) { - rc = ENOKEY; + rc = ENETUNREACH; goto err_xmit; } From nobody Mon Apr 15 14:05:39 2024 X-Original-To: dev-commits-src-branches@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 4VJ88M3H2Rz5Gfk4; Mon, 15 Apr 2024 14:05:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ88M1lH7z4WVP; Mon, 15 Apr 2024 14:05:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189939; 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=nmi08Sr7rrPzZJOfSdN7m0HWOJnD1YscZOpr9gmYec8=; b=oNCprz15lZlWlfvooBbvwgQUnZArR1nryfGEQQfF8EttOSClaVavcffZVROQSfwYtmXreM gZRy/30GBvXOiN1dk38pJd7mKUWrD+Zk67E4NI5G0CdO8QFz0Kmsc7p2omejLYqMR6jSx6 JzvRQc9f9IHYIcyDZL4g/RjyZxSQYTXZVqUixvUWivxIX8STt75ler2BFMlzNAlgryLvlH 3aw9EsQwOSs5/zEg4sv43ZQibJFII9KeSREuNeoTwr0O/MDn/1ymgk7p1aU3o0LaYBZh4g HfUz/zPktrq87lERfIR/zOZ5ihp++6aJ7gmGVD3FQfmtXsYt6FrpYLTYwpz1Qw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713189939; a=rsa-sha256; cv=none; b=AMZjgpQ+Kh8e0S//exRcm3Vnne+M8RpNcA8sd48cqIN5pF4Rwi2fvVLDnCHdFT8wbNQH5u PRp6raHnH5uSHGTpnbFI0us7Q70p60BgTxfj5m3NXzoL4lRkFhbCeoudfkz0Tjq6fOsSbX vcGd6TFxSKUTKJCtwSyL/4jx807wpIr8bW+s//t8It8PQDNbVGN7fUqoj8yp5PI1HR/LFm IDH1Y4lI2ov/UQVgWwriq+KJQwlOmJ8rssGQrPa6Yqe3cwVTJe0nRO+AAvinByk4yxvyNe L65BmpJPHH8uIplYlh+hlG5o4roCyRkXtpzC4DfF2XoAXmvKNgFSl9smo4T5RA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713189939; 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=nmi08Sr7rrPzZJOfSdN7m0HWOJnD1YscZOpr9gmYec8=; b=azddM5I2guml985YUTPCK4vflz6oFStqrdiVeNqjE8eF3YO4J0gQ16hD+G0wV7ciBNWR2U LkLodiI4820KljgGLZoZi7jlOfPBSkLkM3RqLYT8ssuloNB4k5/BgLdo4cG8BoZBatUlEa Gb/M8lk5onA4TkIWOYkPjXkLDzr2UxFnEYFH+H+0qMXQudaK75KXuIA1choRBULL5+x7ko lHZYu+ZlFfA54lj3+UIkeSQkRdBedEc50QMND4NoaQUm12wDHOnKQUmYCU1vwWHzAnqtz7 Dcs+qm7HajN75ZhDBJstbTGbNgOspxy0RHlHQ1LNuLXgvVfyIiiWIr8x1Sykpg== 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 4VJ88M1MJnz12JL; Mon, 15 Apr 2024 14:05:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE5d0I070353; Mon, 15 Apr 2024 14:05:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE5dev070350; Mon, 15 Apr 2024 14:05:39 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:05:39 GMT Message-Id: <202404151405.43FE5dev070350@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 5128c8948b4e - stable/14 - swap_pager: Unbusy readahead pages after an I/O error List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5128c8948b4e56d20dfd623aeb030fb39c8f95b0 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=5128c8948b4e56d20dfd623aeb030fb39c8f95b0 commit 5128c8948b4e56d20dfd623aeb030fb39c8f95b0 Author: Mark Johnston AuthorDate: 2024-04-08 13:02:48 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:05:13 +0000 swap_pager: Unbusy readahead pages after an I/O error The swap pager itself allocates readahead pages, so should take care to unbusy them after a read error, just as it does in the non-error case. PR: 277538 Reviewed by: olce, dougm, alc, kib MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44646 (cherry picked from commit 4696650782e2e5cf7ae5823f1de04550c05b5b75) --- sys/vm/swap_pager.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/vm/swap_pager.c b/sys/vm/swap_pager.c index 38151b3be96f..c8b08e0e8315 100644 --- a/sys/vm/swap_pager.c +++ b/sys/vm/swap_pager.c @@ -1686,6 +1686,9 @@ swp_pager_async_iodone(struct buf *bp) * getpages so don't play cute tricks here. */ vm_page_invalid(m); + if (i < bp->b_pgbefore || + i >= bp->b_npages - bp->b_pgafter) + vm_page_free_invalid(m); } else { /* * If a write error occurs, reactivate page From nobody Mon Apr 15 14:07:56 2024 X-Original-To: dev-commits-src-branches@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 4VJ8C106wrz5Gfdm; Mon, 15 Apr 2024 14:07:57 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJ8C06PDRz4bg4; Mon, 15 Apr 2024 14:07:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713190076; 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=gPlVrnA7qvDKnv24R+hDNCCRwmIK4fzmeu5m2Qb2pIg=; b=dd8f+bVXHI4sLxBWDp99KqM+7uJE4uC0YTe1CRnUjcZD1TrBeILGo0kotFBvXnvToFdYPp VGmRuilLk0QcxYUcFFZH2uEUIBZC6/AKLRd07mT5uPGOeS6tZofObLrrgfOkOQIsVOYB+1 wjQmBBHN9ynIH8CDvxoyLGMpnWnxav5+3dKo26Lz8HJk9uSmOA8hhIsz9F8HFs35hFNF+6 KRwazQW0XEfhj6GVEiIa99KxCA82k6oZy/+/52MYdWwz9A2lTouHwTDzBhbxpZfbGSSyDI oPMyTj3SBxYEa9vdPwyVSTI647Eq9IlmkRBEwWicuoUpbW3Bzsxvm/tPrCJ54w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713190076; a=rsa-sha256; cv=none; b=pCs2bqVMcDQRDicuVNg7sYN7GrN5Nh8V6w0jBG4I833Si1Ur/gMygho2/io6Ya5SHS2Mw+ iuKVPNpAPsGw3P904Cdt9SEpgs5NXzvD20u/Nnr+9KZDvWB2rKMx2ni01Emn7lvdoqPtrE BJrAkCx6oRpmxa1e0spJwUWb95cGxYW3UUmcX7RRqLDYtZROIjdyvnjnHVVFdVd+CbRR2/ sPVjYiiNQtJj+kk6KxQmg+ObA6D1XS++IdK3yXQvCrvYY+tof0qYLWsdWpo7icqi3sznD2 Lhz0b43CycSUGhckN5lGy4848r40mM7PKMOFGT9wDK5zaJuxLvoilSlfMrQGOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713190076; 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=gPlVrnA7qvDKnv24R+hDNCCRwmIK4fzmeu5m2Qb2pIg=; b=MpAv2KMLVa9VB7/mY4Fz58zRzOjurjYDg7wfDZHG1LRE55lz98cPBENBIY/0QI22P1OQP9 uU5VpZexovJ1X1RaZ1eeiakbNnXsNuZs3+Ut9+yH6h5fzfZ9AxaxvIb31DbVK15qm3YmFR SZlABSMfjXtQXT9yqM7aW8EykT44kBt+dCCiIJKhqztGz1N6s6EensJvgPfSRH0UBEGc94 mf51aonLJ16aRLhYQxDPqvCWUp/k77LtRpDvhmx+l38PimaX2qL9K1DGH/uk1vLIhRjQrO cD8Qia2V3tldb5TnLr02nNV2Wi8Rlobpa0BE3U9fgS15L481+ST5KpQ7xEf/NA== 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 4VJ8C05jk1z12vy; Mon, 15 Apr 2024 14:07:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FE7uf3070875; Mon, 15 Apr 2024 14:07:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FE7uuE070872; Mon, 15 Apr 2024 14:07:56 GMT (envelope-from git) Date: Mon, 15 Apr 2024 14:07:56 GMT Message-Id: <202404151407.43FE7uuE070872@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 268afe724791 - stable/14 - tarfs: Implement VOP_BMAP List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 268afe724791468118a3c12838489b0b9460e623 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=268afe724791468118a3c12838489b0b9460e623 commit 268afe724791468118a3c12838489b0b9460e623 Author: Mark Johnston AuthorDate: 2024-04-05 15:14:36 +0000 Commit: Mark Johnston CommitDate: 2024-04-15 14:06:12 +0000 tarfs: Implement VOP_BMAP This lets tarfs provide readahead/behind hints to the VFS, which helps memory-mapped I/O performance, important when running faulting in executables out of a tarfs mount as one might if tarfs is used to back the root filesystem, for example. The improvement is particularly noticeable when the backing tarball is zstd-compressed. The implementation simply returns the extent of the virtual block containing the target offset, clamped by the maximum I/O size. This is perhaps simplistic; it effectively just chooses values that would correspond to a single VOP_READ call in tarfs_read_file(). Reviewed by: des, kib MFC after: 1 month Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44626 (cherry picked from commit a0895e394d3fec374e61a207bdfa0245dae86f53) --- sys/fs/tarfs/tarfs_vnops.c | 55 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/sys/fs/tarfs/tarfs_vnops.c b/sys/fs/tarfs/tarfs_vnops.c index 7a04f891350e..f2828c60f8a7 100644 --- a/sys/fs/tarfs/tarfs_vnops.c +++ b/sys/fs/tarfs/tarfs_vnops.c @@ -125,6 +125,60 @@ tarfs_access(struct vop_access_args *ap) return (error); } +static int +tarfs_bmap(struct vop_bmap_args *ap) +{ + struct tarfs_node *tnp; + struct vnode *vp; + off_t off; + uint64_t iosize; + int ra, rb, rmax; + + vp = ap->a_vp; + iosize = vp->v_mount->mnt_stat.f_iosize; + + if (ap->a_bop != NULL) + *ap->a_bop = &vp->v_bufobj; + if (ap->a_bnp != NULL) + *ap->a_bnp = ap->a_bn * btodb(iosize); + if (ap->a_runp == NULL) + return (0); + + tnp = VP_TO_TARFS_NODE(vp); + off = ap->a_bn * iosize; + + ra = rb = 0; + for (u_int i = 0; i < tnp->nblk; i++) { + off_t bs, be; + + bs = tnp->blk[i].o; + be = tnp->blk[i].o + tnp->blk[i].l; + if (off > be) + continue; + else if (off < bs) { + /* We're in a hole. */ + ra = bs - off < iosize ? + 0 : howmany(bs - (off + iosize), iosize); + rb = howmany(off - (i == 0 ? + 0 : tnp->blk[i - 1].o + tnp->blk[i - 1].l), + iosize); + break; + } else { + /* We'll be reading from the backing file. */ + ra = be - off < iosize ? + 0 : howmany(be - (off + iosize), iosize); + rb = howmany(off - bs, iosize); + break; + } + } + + rmax = vp->v_mount->mnt_iosize_max / iosize - 1; + *ap->a_runp = imin(ra, rmax); + if (ap->a_runb != NULL) + *ap->a_runb = imin(rb, rmax); + return (0); +} + static int tarfs_getattr(struct vop_getattr_args *ap) { @@ -629,6 +683,7 @@ struct vop_vector tarfs_vnodeops = { .vop_default = &default_vnodeops, .vop_access = tarfs_access, + .vop_bmap = tarfs_bmap, .vop_cachedlookup = tarfs_lookup, .vop_close = tarfs_close, .vop_getattr = tarfs_getattr, From nobody Mon Apr 15 18:41:27 2024 X-Original-To: dev-commits-src-branches@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 4VJGGc0tYNz5H6R9; Mon, 15 Apr 2024 18:41:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJGGc0GfNz4LMy; Mon, 15 Apr 2024 18:41:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713206488; 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=yj4zTPtqPivl573XoBhw4a0dXU5MBFN6k5Lx2g5GsxI=; b=wc3qj0Tu/Ku9eoz16KhUMfaMz2zoivRPv6O98J2LR/ZCJc6YZPUZHZulFLJe25TOjRnQIL UEkJ2tZE1B+k5qqeIrRyIk/WW/uMyam/xN+r40PVqOMJ+JBQ/NBq8KlM3gdn6LmQ2SXj+Y J0yrfgkT7NagJl7t6wyArwAumS+eFvA0SaceX4EnlTkHbOWSM0B3iDJRM3/YMvNXu6oVcp oXN60X0+8eTdpMu+Cy+W6t+a/Ryk3hloht6UuFXBJOSJUCPrkvwCXpj/G2i+CortiMHL1V vlsmtoXwiZcCBCmq3f/qtdpEteW+X+FjfFtjkoezAk5xPXQxOhT3GUSRqFR8Sg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713206488; a=rsa-sha256; cv=none; b=Lb6F5H7hx0v36EhffYD3I0QV5rrZPAHAAV1wegGfQk8uUE2CL7hilS4tDAiB32ptj6LQ6Z Q6dQWwwNIs3XK4E5cAAaVM25C8qXKcH/yWhDWK6XDeeyPOsFj5TaRjkazd9Kkjf/W5OBgI fYdGRbYy8gA3bgNtiq/gg3PLuKILw/BDOs7dYGIB/Wb86B3nS0/bZoUYUF56wWg3Ib/BJm UTL+qFdnn4nA4xXNqpdPyrDi9fTF2v/TP4H6E5tNzEcyEfNnaCCFE6Df3vYdk3i1sxv9Qi 80jlyc5UIcYF0GmMa5/7TdCOEX3IxtXxXfoqKYnwRWVF7AZqhCHjmYJ/VKQQSg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713206488; 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=yj4zTPtqPivl573XoBhw4a0dXU5MBFN6k5Lx2g5GsxI=; b=xMaDcCCxZvh7RXaTqma0x7ubF47n5i6VP24VMxaCL8NZZcCUFdOCoyisi0hjLtFoOGoz1A iIr2oXGQVknrNfEI2uIICjZQs8v/X9En7q+NRFM6Uzd3f9c9ngY+k+vCjh+h8FGiEqM/8C 5hf8F+lyHDHWSKaLKuA9PYcF/nu2UjovONg6PsHUkIw6ooE27Yir/0sKm+ZGxpVeHP58VT doHoAxQrUshTrIFq94WTV75XVG75mDPzIhvlMwWAZP7gwV8UtrARTNVzgA/PpvXP5uXlF8 sxHnWNEebbXgCpD/1TP8zVYIw4jYoVyZBMaHg0jBQHJzmwvQM2FFMLrBMzmW1A== 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 4VJGGb6xgBz19b4; Mon, 15 Apr 2024 18:41:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FIfR3U038242; Mon, 15 Apr 2024 18:41:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FIfR6I038239; Mon, 15 Apr 2024 18:41:27 GMT (envelope-from git) Date: Mon, 15 Apr 2024 18:41:27 GMT Message-Id: <202404151841.43FIfR6I038239@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 11f154ca86a0 - stable/14 - linuxkpi: Annotate an unused variable as such List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 11f154ca86a007eefc5212e27e31ad0ff65a884e Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=11f154ca86a007eefc5212e27e31ad0ff65a884e commit 11f154ca86a007eefc5212e27e31ad0ff65a884e Author: Mark Johnston AuthorDate: 2023-12-27 15:11:33 +0000 Commit: John Baldwin CommitDate: 2024-04-15 18:00:35 +0000 linuxkpi: Annotate an unused variable as such This addresses a -Wunused-but-set-variable warning in the gcc builds. No functional change intended. Reported by: Jenkins (cherry picked from commit 344a04ad2c5e62b2905bc2f8b6f992ae590403fd) --- sys/compat/linuxkpi/common/include/linux/build_bug.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/build_bug.h b/sys/compat/linuxkpi/common/include/linux/build_bug.h index 59d1fc228afc..6a026376cfc8 100644 --- a/sys/compat/linuxkpi/common/include/linux/build_bug.h +++ b/sys/compat/linuxkpi/common/include/linux/build_bug.h @@ -48,7 +48,7 @@ #define _O__CTASSERT(x, y) _O___CTASSERT(x, y) #define _O___CTASSERT(x, y) while (0) { \ typedef char __assert_line_ ## y[(x) ? 1 : -1]; \ - __assert_line_ ## y _x; \ + __assert_line_ ## y _x __unused; \ _x[0] = '\0'; \ } From nobody Mon Apr 15 18:41:28 2024 X-Original-To: dev-commits-src-branches@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 4VJGGd3D2qz5H6cq; Mon, 15 Apr 2024 18:41:29 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJGGd159fz4LB5; Mon, 15 Apr 2024 18:41:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713206489; 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=2fYmz9ij3rpMnEZ3KGIpkitpSvV9IBCZ32t8mVOE+7s=; b=LvFAoCPUPYbieqfPfyFPIJABGM8Qpqi0ThK1FlHsTuxjR/L4jYo2hguYzbU++n+XhARRFd YzG6BMZ521Qt1ZgpWgZbKk2lbWEQfjvs1qVstix2pScgCY5r+B/wxFwC7rZEWHRqNYnKbO ovFtX9+wHSuw64AMupHjgQIICXSObMVoer3jpVqvyCgDuP1ZDkmbZus6nFxIfWnvPz8zPN Zfi+icog+z44VjeHWHEvALQquK54l4TNsOK8apZ2u54g42QoaoTfmPcqHnWM5feoVX2I89 yP4pxlDbasfuxfjFvIq6bANDJieA6ITGp+79TXIUEvzQxlSodP7qijliWxnAsA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713206489; a=rsa-sha256; cv=none; b=ca3BvmUowN8NmCiVgmWFzuQhjGA1rGPaiWueAVMTt+f2I0K2snmFwDGoPrGOLi3AJhNF2U vXiZpcUjZKC6g09DrEqNFwhyDnquV6SdF77FRJZdCYMR7+dmyMQ27/oiHomhAW2Vl/tJjk 0X/91yAstc93D+/lv5hTsA2kogT5WiP4So5s2fX23e5a5sLV0Tb6e1008wpMloprQlYqhK TmozKaCBPEM/3AtPHSZp7flCT6QAJs+JtVEonRt/jTIIuJs+vx+zNWmdEav3EJVAvIjupK HYAglqSJYTp9+ROcQlvaMMWgUKFjRCwFCAFqG3ZOAUhFWwfN6cIcd0+QCT654A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713206489; 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=2fYmz9ij3rpMnEZ3KGIpkitpSvV9IBCZ32t8mVOE+7s=; b=x0Jo3Y6ldflt5dibKndYur14JDhULJJks6mcDD4cnji2NEHDvaS0BMQQsXSIhLZtQTZwwu 9QTJp+8EWoNN5vZzT7hojpZopR6UySygVvDHeze1UGD7noJttk5YyHNdgRVXWYrc70XuMy LHbDZT6KNK/geMDegS88oNoi+0WnfL4FsDAjoqBNCGB4V5Y3a/iP3tTohmivML3qXgBw4L OY3lowU7pVsk4P2aHrIqYgeTisfr+4OZBYlniVYiLPb3RJHsMRI+ywokf3MY0ROKq+8KVN jwj5Lc+U30N8UtYRBOWNtvcpt4ciPmrEzmElfqI4bqYY3kW2PQSXDHo4xSLH6g== 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 4VJGGd0hX3z19NM; Mon, 15 Apr 2024 18:41:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FIfSfd038290; Mon, 15 Apr 2024 18:41:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FIfSHa038287; Mon, 15 Apr 2024 18:41:28 GMT (envelope-from git) Date: Mon, 15 Apr 2024 18:41:28 GMT Message-Id: <202404151841.43FIfSHa038287@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 89dd0612d933 - stable/14 - netinet: The tailq_hash code doesn't reference tcpoutflags List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 89dd0612d933783ae9f41e81e0c00f1bd03194fe Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=89dd0612d933783ae9f41e81e0c00f1bd03194fe commit 89dd0612d933783ae9f41e81e0c00f1bd03194fe Author: Warner Losh AuthorDate: 2023-10-27 14:39:31 +0000 Commit: John Baldwin CommitDate: 2024-04-15 18:03:28 +0000 netinet: The tailq_hash code doesn't reference tcpoutflags Don't define TCPOUTFLAGS to get the static definition from tcp_fsm.h. tailq_hash.c doesn't refernce tcpoutflag. Only files that reference this should define TCPOUTFLAGS. clang is fine with it, but gcc12 complained. Sponsored by: Netflix (cherry picked from commit afd155c72bf65c056d19473569cc78c6e5807b3b) --- sys/netinet/tcp_stacks/tailq_hash.c | 1 - 1 file changed, 1 deletion(-) diff --git a/sys/netinet/tcp_stacks/tailq_hash.c b/sys/netinet/tcp_stacks/tailq_hash.c index 0792905e0128..5977bf874950 100644 --- a/sys/netinet/tcp_stacks/tailq_hash.c +++ b/sys/netinet/tcp_stacks/tailq_hash.c @@ -58,7 +58,6 @@ #include #include #include -#define TCPOUTFLAGS #include #include #include From nobody Mon Apr 15 23:02:05 2024 X-Original-To: dev-commits-src-branches@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 4VJN3L0qwJz5HGxk; Mon, 15 Apr 2024 23:02:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJN3K6jLXz4s2q; Mon, 15 Apr 2024 23:02:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713222125; 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=OVBwp2J0VYJ1Xu/lAXU9cIoAhZqqnESYMQ+LrbQXsK8=; b=WWPusqiRfyv7V8wJto5nGkxH7Tqm6LN0+Rege7gALQCGDavLek+2FTNFpeCIQO03UVa52C iHeUFGlYtyFULaRPJHUOl/I/aS2S0+w+0r9nOC9cSaKd8zu69B2s/fyLvIiP9iIDC+bUc/ IhmRznfe7PSwoqZpiKk7i6HM7OsrrlXaOA3h1ymNyMnAJKF78ICqc/uy8XfzRKP62sVLKK krulLXVDBRwguwnvXELfURbtw7mu6V/MdhCmqlgiAinh1rWeEt7ryX7m3fwVMCPG6lR9ut VYWvgSwC450LTGgsB7HNVwAvCMp3rUiZV6QXlmcmxZBl5O/dvwdqWIpl3bJIwA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713222125; a=rsa-sha256; cv=none; b=MsjsQdqB0J5utIb4D0IBWnCYEA9iXf0pMn6iG41NRpYMOrpzsruT9jkU8NvHHSAyla3W/8 S/+hgaMYBfXtIBAy0JbcAo/EwDZrpLTkY5VkOl7kWEnNCNIjNC2SblM5V9jRZgd1AkZgy5 pZoRPrV4EK94vzZWg2dB6SKLk/wD7/CrjFCJBNc4R4+YxQm/Q7GZnUIeW1RIYPHmPHHbfE ZRhl/Jm7ydjGHR4seimYhqfLI+mCWPgwvBY9r8lzMoYr6GLxHB4/9DJdvEAENZn2Rbj4lc yi2M+PldzHTkqkUoPEQmFhLyMdMIgGO8WZ5MhZkCzIwI6rVz//ftZjUSbix1YA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713222125; 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=OVBwp2J0VYJ1Xu/lAXU9cIoAhZqqnESYMQ+LrbQXsK8=; b=MQ6m0x/nbYQZvMBp3qHsJu6pGbhNgLqN0Y3betHURZ0lpX/tTIxm47CFB61Pp9Jo6NjMbE dQUk57dhEhnsMNmX12vkjuyM1sgLvHc5xEH3gxV4MVJabZpgLiwXAZBxuX5+rPN3YnnZ35 LFbmXFvfumYME/82LkgqMZab5DeQWYgh/+1jAYNfN5UKTYMZmGCCFAfwbnh45DTe+9ufBg 26gF1zpHZdKAHiMSBsZAMCcWgrGHYtlyi7W8dm3xepV5dOGQ0+UekPNl4Aeej7CgdVzN+w U1bybpt/UgJmvEAOr+uOFWzKhWQohoY8nG04R9ggx2dSqtp+mDkwzhTxnOAwHA== 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 4VJN3K6K5zzJ4Y; Mon, 15 Apr 2024 23:02:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43FN25ct080053; Mon, 15 Apr 2024 23:02:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43FN25m0080050; Mon, 15 Apr 2024 23:02:05 GMT (envelope-from git) Date: Mon, 15 Apr 2024 23:02:05 GMT Message-Id: <202404152302.43FN25m0080050@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 770e04e65fbb - stable/14 - awk: revert upstream's attempt to disallow hex strings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 770e04e65fbbb8e8a21830fe043522907a1702c3 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=770e04e65fbbb8e8a21830fe043522907a1702c3 commit 770e04e65fbbb8e8a21830fe043522907a1702c3 Author: Warner Losh AuthorDate: 2024-04-15 22:59:28 +0000 Commit: Warner Losh CommitDate: 2024-04-15 22:59:28 +0000 awk: revert upstream's attempt to disallow hex strings Upstream one-true-awk decided to disallow hex strings as numbers. This is in line with awk's behavior prior to C99, and allowed by the POSIX standard. The standard, however, allows them to be treated as numbers because that's what the standard said in the 2001 through 2004 editions. Since 2001, the nawk in FreeBSD has treated them as numbers, so restore that behavior, allowed by prior standards, but not the latest POSIX standard. A number of scripts in the FreeBSD tree depend on this interpretation, including scripts to build the kernel which had mysteriously started failing for some people and not others. By re-allowing 0x hex numbers, this fixes those scripts and restores POLA. Upstream issue: https://github.com/onetrueawk/awk/issues/126 Sponsored by: Netflix Reviewed by: kevans MFC After: asap due to regression alrady merged to stable Differential Revision: https://reviews.freebsd.org/D31199 Note: This is re-done in stable/14 because the release notes say 15 and newer will have this restriction, implying stable/14 will not, but the OTA 2nd edition merge neglected to have this, breaking kernel.bin in arm*. (cherry picked from commit d4d252c49976de33d0a2926df733744d0b8d95fa) --- contrib/one-true-awk/lib.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/contrib/one-true-awk/lib.c b/contrib/one-true-awk/lib.c index 0dac1f929cf2..e6fb99c744b5 100644 --- a/contrib/one-true-awk/lib.c +++ b/contrib/one-true-awk/lib.c @@ -886,9 +886,18 @@ bool is_valid_number(const char *s, bool trailing_stuff_ok, while (isspace((int) *s)) s++; +/* + * This test, while allowed by newer POSIX standards, represents a regression + * where hex strings were treated as numbers in nawk the whole time it has been + * in FreeBSD (since 2001). The POSIX 2001 through 2004 standards mandated this + * behavior and the current standard allows it. Deviate from upstream by restoring + * the prior FreeBSD behavior. + */ +#if 0 /* no hex floating point, sorry */ if (s[0] == '0' && tolower(s[1]) == 'x') return false; +#endif /* allow +nan, -nan, +inf, -inf, any other letter, no */ if (s[0] == '+' || s[0] == '-') { From nobody Tue Apr 16 01:48:03 2024 X-Original-To: dev-commits-src-branches@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 4VJRkq5Jrwz5HWRR; Tue, 16 Apr 2024 01:48:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJRkq4r4Lz4Bnq; Tue, 16 Apr 2024 01:48:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713232083; 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=0eSAM7leZEq3Xb1SsCHjt5MJty3cstjSMmuSkhOYW/w=; b=Zyf9h42JF/eBL9umXe0NZvbNAQUARE9wv3f2QrjBPcb/Er/p4kO086J1Nl+dQWL/tg5Hfb 8sxCju2GSSli+hlu//58mFjA5xcTbXeXoDaPIk7uRx2JXt7ePzuuPKKS4OPN02pPnfe0Of 19J+96SK+ww07vK0rbGGN30AOQG/zqSiYFrDTPnIBkSAfnkOC23Z78TdzHn7HwRckJasSi UPOZSYymqpKMCkZPBSOnNzCZFxUGil5cDtmXm79tLG4dfCRUW0urpoOiSpfXJ0n/rwrwx6 2laRnHLFQpzsdPW91MO+pu+zgMZJQXAyGDYbA4cJ8H/pn1TM4HrrXjfCgWjeqA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713232083; a=rsa-sha256; cv=none; b=O6Yojqnv2FpKTRQxWwWoHOcF5G+RM/HRM8k7SFGRg+TcfPOf03ob90GRMhSRWGjJS6pYex m7L1frM99OQJdUD20okOwGvCGDA4gU+YBrQ7donVUr8z8cwOstWzcsOD4vN+nnC35o//Pb FuI6tUVA+D1gqeLeDdTMRY+8IWw6P+pU7CFBy5zo1bUMzLvnNcwTntdLht8avHxYTTP3We jS0fqAn/a/6AQxZJcHJZ769e6m6pe5GYRoyEvgusRnu9fjKiDLXSqspKPf/5PtlYFfMdRL fxZM1Aqaa+inLNEbKiZzOnIaNNvF3apjwVo5DaL8854WYqfcza1vIm+7q+d3rA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713232083; 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=0eSAM7leZEq3Xb1SsCHjt5MJty3cstjSMmuSkhOYW/w=; b=CJKAcAFVhazfLy+NbGJwtNoJCb8DWK15PLVHLxRs2udNEAbPY2NRwEYBKj6QEK0X894Dgm rQS0OKKTW6a19tXygf86zvjTWJN8wEr3uuyg5Z1PmfHsV7PIHe+Moq/42zz32ZTMsf21Wb KMH1B4gG7SZqnw4QJF+pq5NtgUwW90fCiRwdWeVDIef6n2NulJ3+FPn6U0ZgSktO/WIg1d voRpkbIvqllza86qWALyewPJEbK24/TLmhKJ/askvVAKCNRbg9KN/hniOCnYkf0i8eAMRE iZhoaWwI03bBUlM4ZBO3r3g8xfsWDo+o/QPSmA6Hn2jmXK9abCB1T+xEQNZaBg== 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 4VJRkq4Jp0zNyJ; Tue, 16 Apr 2024 01:48:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G1m3QZ052462; Tue, 16 Apr 2024 01:48:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G1m3ox052459; Tue, 16 Apr 2024 01:48:03 GMT (envelope-from git) Date: Tue, 16 Apr 2024 01:48:03 GMT Message-Id: <202404160148.43G1m3ox052459@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 72eb6d65ede2 - stable/14 - sound: Move sndstat_prepare_pcm() to pcm/sndstat.c and remove sndstat_entry->handler List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 72eb6d65ede22a235886bfa610217a33247f3de8 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=72eb6d65ede22a235886bfa610217a33247f3de8 commit 72eb6d65ede22a235886bfa610217a33247f3de8 Author: Christos Margiolis AuthorDate: 2024-04-02 16:56:39 +0000 Commit: Christos Margiolis CommitDate: 2024-04-16 01:47:57 +0000 sound: Move sndstat_prepare_pcm() to pcm/sndstat.c and remove sndstat_entry->handler Since all sndstat_entry->handler fields point to sndstat_prepare_pcm(), we can just call the function directly, without assigning it to a function pointer and calling it indirectly. While here, move sndstat_prepare_pcm() to pcm/sndstat.c, as it is more suitable there. No functional change intended. Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Reviewed by: dev_submerge.ch, markj Differential Revision: https://reviews.freebsd.org/D44571 (cherry picked from commit 9da3b645dbaaad724d524727d003fed7be05ff7c) --- sys/dev/sound/pcm/sndstat.c | 152 +++++++++++++++++++++++++++++++++++++++++--- sys/dev/sound/pcm/sound.c | 138 +--------------------------------------- sys/dev/sound/pcm/sound.h | 3 +- 3 files changed, 145 insertions(+), 148 deletions(-) diff --git a/sys/dev/sound/pcm/sndstat.c b/sys/dev/sound/pcm/sndstat.c index 32b47b8ee105..0279060181b3 100644 --- a/sys/dev/sound/pcm/sndstat.c +++ b/sys/dev/sound/pcm/sndstat.c @@ -49,6 +49,8 @@ #include #include +#include "feeder_if.h" + #define SS_TYPE_PCM 1 #define SS_TYPE_MIDI 2 #define SS_TYPE_SEQUENCER 3 @@ -73,7 +75,6 @@ struct sndstat_entry { TAILQ_ENTRY(sndstat_entry) link; device_t dev; char *str; - sndstat_handler handler; int type, unit; }; @@ -1050,7 +1051,7 @@ fail: /************************************************************************/ int -sndstat_register(device_t dev, char *str, sndstat_handler handler) +sndstat_register(device_t dev, char *str) { struct sndstat_entry *ent; struct sndstat_entry *pre; @@ -1073,7 +1074,6 @@ sndstat_register(device_t dev, char *str, sndstat_handler handler) ent->str = str; ent->type = type; ent->unit = unit; - ent->handler = handler; SNDSTAT_LOCK(); /* sorted list insertion */ @@ -1119,6 +1119,142 @@ sndstat_unregister(device_t dev) /************************************************************************/ +static int +sndstat_prepare_pcm(struct sbuf *s, device_t dev, int verbose) +{ + struct snddev_info *d; + struct pcm_channel *c; + struct pcm_feeder *f; + + d = device_get_softc(dev); + PCM_BUSYASSERT(d); + + if (CHN_EMPTY(d, channels.pcm)) { + sbuf_printf(s, " (mixer only)"); + return (0); + } + + if (verbose < 1) { + sbuf_printf(s, " (%s%s%s", + d->playcount ? "play" : "", + (d->playcount && d->reccount) ? "/" : "", + d->reccount ? "rec" : ""); + } else { + sbuf_printf(s, " (%dp:%dv/%dr:%dv", + d->playcount, d->pvchancount, + d->reccount, d->rvchancount); + } + sbuf_printf(s, "%s)%s", + ((d->playcount != 0 && d->reccount != 0) && + (d->flags & SD_F_SIMPLEX)) ? " simplex" : "", + (device_get_unit(dev) == snd_unit) ? " default" : ""); + + if (verbose <= 1) + return (0); + + sbuf_printf(s, "\n\t"); + sbuf_printf(s, "snddev flags=0x%b", d->flags, SD_F_BITS); + + CHN_FOREACH(c, d, channels.pcm) { + KASSERT(c->bufhard != NULL && c->bufsoft != NULL, + ("hosed pcm channel setup")); + + sbuf_printf(s, "\n\t"); + + sbuf_printf(s, "%s[%s]: ", + (c->parentchannel != NULL) ? + c->parentchannel->name : "", c->name); + sbuf_printf(s, "spd %d", c->speed); + if (c->speed != sndbuf_getspd(c->bufhard)) { + sbuf_printf(s, "/%d", + sndbuf_getspd(c->bufhard)); + } + sbuf_printf(s, ", fmt 0x%08x", c->format); + if (c->format != sndbuf_getfmt(c->bufhard)) { + sbuf_printf(s, "/0x%08x", + sndbuf_getfmt(c->bufhard)); + } + sbuf_printf(s, ", flags 0x%08x, 0x%08x", + c->flags, c->feederflags); + if (c->pid != -1) { + sbuf_printf(s, ", pid %d (%s)", + c->pid, c->comm); + } + sbuf_printf(s, "\n\t"); + + sbuf_printf(s, "interrupts %d, ", c->interrupts); + + if (c->direction == PCMDIR_REC) { + sbuf_printf(s, + "overruns %d, feed %u, hfree %d, " + "sfree %d [b:%d/%d/%d|bs:%d/%d/%d]", + c->xruns, c->feedcount, + sndbuf_getfree(c->bufhard), + sndbuf_getfree(c->bufsoft), + sndbuf_getsize(c->bufhard), + sndbuf_getblksz(c->bufhard), + sndbuf_getblkcnt(c->bufhard), + sndbuf_getsize(c->bufsoft), + sndbuf_getblksz(c->bufsoft), + sndbuf_getblkcnt(c->bufsoft)); + } else { + sbuf_printf(s, + "underruns %d, feed %u, ready %d " + "[b:%d/%d/%d|bs:%d/%d/%d]", + c->xruns, c->feedcount, + sndbuf_getready(c->bufsoft), + sndbuf_getsize(c->bufhard), + sndbuf_getblksz(c->bufhard), + sndbuf_getblkcnt(c->bufhard), + sndbuf_getsize(c->bufsoft), + sndbuf_getblksz(c->bufsoft), + sndbuf_getblkcnt(c->bufsoft)); + } + sbuf_printf(s, "\n\t"); + + sbuf_printf(s, "channel flags=0x%b", c->flags, CHN_F_BITS); + sbuf_printf(s, "\n\t"); + + sbuf_printf(s, "{%s}", + (c->direction == PCMDIR_REC) ? "hardware" : "userland"); + sbuf_printf(s, " -> "); + f = c->feeder; + while (f->source != NULL) + f = f->source; + while (f != NULL) { + sbuf_printf(s, "%s", f->class->name); + if (f->desc->type == FEEDER_FORMAT) { + sbuf_printf(s, "(0x%08x -> 0x%08x)", + f->desc->in, f->desc->out); + } else if (f->desc->type == FEEDER_MATRIX) { + sbuf_printf(s, "(%d.%d -> %d.%d)", + AFMT_CHANNEL(f->desc->in) - + AFMT_EXTCHANNEL(f->desc->in), + AFMT_EXTCHANNEL(f->desc->in), + AFMT_CHANNEL(f->desc->out) - + AFMT_EXTCHANNEL(f->desc->out), + AFMT_EXTCHANNEL(f->desc->out)); + } else if (f->desc->type == FEEDER_RATE) { + sbuf_printf(s, + "(0x%08x q:%d %d -> %d)", + f->desc->out, + FEEDER_GET(f, FEEDRATE_QUALITY), + FEEDER_GET(f, FEEDRATE_SRC), + FEEDER_GET(f, FEEDRATE_DST)); + } else { + sbuf_printf(s, "(0x%08x)", + f->desc->out); + } + sbuf_printf(s, " -> "); + f = f->parent; + } + sbuf_printf(s, "{%s}", + (c->direction == PCMDIR_REC) ? "userland" : "hardware"); + } + + return (0); +} + static int sndstat_prepare(struct sndstat_file *pf_self) { @@ -1149,12 +1285,10 @@ sndstat_prepare(struct sndstat_file *pf_self) sbuf_printf(s, " <%s>", device_get_desc(ent->dev)); if (snd_verbose > 0) sbuf_printf(s, " %s", ent->str); - if (ent->handler) { - /* XXX Need Giant magic entry ??? */ - PCM_ACQUIRE_QUICK(d); - ent->handler(s, ent->dev, snd_verbose); - PCM_RELEASE_QUICK(d); - } + /* XXX Need Giant magic entry ??? */ + PCM_ACQUIRE_QUICK(d); + sndstat_prepare_pcm(s, ent->dev, snd_verbose); + PCM_RELEASE_QUICK(d); sbuf_printf(s, "\n"); } if (k == 0) diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index c03e4fa435e1..5f5fced9b7f0 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -74,142 +74,6 @@ SYSCTL_STRING(_hw_snd, OID_AUTO, version, CTLFLAG_RD, &snd_driver_version, */ struct unrhdr *pcmsg_unrhdr = NULL; -static int -sndstat_prepare_pcm(struct sbuf *s, device_t dev, int verbose) -{ - struct snddev_info *d; - struct pcm_channel *c; - struct pcm_feeder *f; - - d = device_get_softc(dev); - PCM_BUSYASSERT(d); - - if (CHN_EMPTY(d, channels.pcm)) { - sbuf_printf(s, " (mixer only)"); - return (0); - } - - if (verbose < 1) { - sbuf_printf(s, " (%s%s%s", - d->playcount ? "play" : "", - (d->playcount && d->reccount) ? "/" : "", - d->reccount ? "rec" : ""); - } else { - sbuf_printf(s, " (%dp:%dv/%dr:%dv", - d->playcount, d->pvchancount, - d->reccount, d->rvchancount); - } - sbuf_printf(s, "%s)%s", - ((d->playcount != 0 && d->reccount != 0) && - (d->flags & SD_F_SIMPLEX)) ? " simplex" : "", - (device_get_unit(dev) == snd_unit) ? " default" : ""); - - if (verbose <= 1) - return (0); - - sbuf_printf(s, "\n\t"); - sbuf_printf(s, "snddev flags=0x%b", d->flags, SD_F_BITS); - - CHN_FOREACH(c, d, channels.pcm) { - KASSERT(c->bufhard != NULL && c->bufsoft != NULL, - ("hosed pcm channel setup")); - - sbuf_printf(s, "\n\t"); - - sbuf_printf(s, "%s[%s]: ", - (c->parentchannel != NULL) ? - c->parentchannel->name : "", c->name); - sbuf_printf(s, "spd %d", c->speed); - if (c->speed != sndbuf_getspd(c->bufhard)) { - sbuf_printf(s, "/%d", - sndbuf_getspd(c->bufhard)); - } - sbuf_printf(s, ", fmt 0x%08x", c->format); - if (c->format != sndbuf_getfmt(c->bufhard)) { - sbuf_printf(s, "/0x%08x", - sndbuf_getfmt(c->bufhard)); - } - sbuf_printf(s, ", flags 0x%08x, 0x%08x", - c->flags, c->feederflags); - if (c->pid != -1) { - sbuf_printf(s, ", pid %d (%s)", - c->pid, c->comm); - } - sbuf_printf(s, "\n\t"); - - sbuf_printf(s, "interrupts %d, ", c->interrupts); - - if (c->direction == PCMDIR_REC) { - sbuf_printf(s, - "overruns %d, feed %u, hfree %d, " - "sfree %d [b:%d/%d/%d|bs:%d/%d/%d]", - c->xruns, c->feedcount, - sndbuf_getfree(c->bufhard), - sndbuf_getfree(c->bufsoft), - sndbuf_getsize(c->bufhard), - sndbuf_getblksz(c->bufhard), - sndbuf_getblkcnt(c->bufhard), - sndbuf_getsize(c->bufsoft), - sndbuf_getblksz(c->bufsoft), - sndbuf_getblkcnt(c->bufsoft)); - } else { - sbuf_printf(s, - "underruns %d, feed %u, ready %d " - "[b:%d/%d/%d|bs:%d/%d/%d]", - c->xruns, c->feedcount, - sndbuf_getready(c->bufsoft), - sndbuf_getsize(c->bufhard), - sndbuf_getblksz(c->bufhard), - sndbuf_getblkcnt(c->bufhard), - sndbuf_getsize(c->bufsoft), - sndbuf_getblksz(c->bufsoft), - sndbuf_getblkcnt(c->bufsoft)); - } - sbuf_printf(s, "\n\t"); - - sbuf_printf(s, "channel flags=0x%b", c->flags, CHN_F_BITS); - sbuf_printf(s, "\n\t"); - - sbuf_printf(s, "{%s}", - (c->direction == PCMDIR_REC) ? "hardware" : "userland"); - sbuf_printf(s, " -> "); - f = c->feeder; - while (f->source != NULL) - f = f->source; - while (f != NULL) { - sbuf_printf(s, "%s", f->class->name); - if (f->desc->type == FEEDER_FORMAT) { - sbuf_printf(s, "(0x%08x -> 0x%08x)", - f->desc->in, f->desc->out); - } else if (f->desc->type == FEEDER_MATRIX) { - sbuf_printf(s, "(%d.%d -> %d.%d)", - AFMT_CHANNEL(f->desc->in) - - AFMT_EXTCHANNEL(f->desc->in), - AFMT_EXTCHANNEL(f->desc->in), - AFMT_CHANNEL(f->desc->out) - - AFMT_EXTCHANNEL(f->desc->out), - AFMT_EXTCHANNEL(f->desc->out)); - } else if (f->desc->type == FEEDER_RATE) { - sbuf_printf(s, - "(0x%08x q:%d %d -> %d)", - f->desc->out, - FEEDER_GET(f, FEEDRATE_QUALITY), - FEEDER_GET(f, FEEDRATE_SRC), - FEEDER_GET(f, FEEDRATE_DST)); - } else { - sbuf_printf(s, "(0x%08x)", - f->desc->out); - } - sbuf_printf(s, " -> "); - f = f->parent; - } - sbuf_printf(s, "{%s}", - (c->direction == PCMDIR_REC) ? "userland" : "hardware"); - } - - return (0); -} - void * snd_mtxcreate(const char *desc, const char *type) { @@ -1276,7 +1140,7 @@ pcm_register(device_t dev, void *devinfo, int numplay, int numrec) if (numplay > 0 || numrec > 0) d->flags |= SD_F_AUTOVCHAN; - sndstat_register(dev, d->status, sndstat_prepare_pcm); + sndstat_register(dev, d->status); return 0; } diff --git a/sys/dev/sound/pcm/sound.h b/sys/dev/sound/pcm/sound.h index 51d1624b2d7e..e3405a85f3c9 100644 --- a/sys/dev/sound/pcm/sound.h +++ b/sys/dev/sound/pcm/sound.h @@ -341,8 +341,7 @@ void snd_mtxassert(void *m); #define snd_mtxlock(m) mtx_lock(m) #define snd_mtxunlock(m) mtx_unlock(m) -typedef int (*sndstat_handler)(struct sbuf *s, device_t dev, int verbose); -int sndstat_register(device_t dev, char *str, sndstat_handler handler); +int sndstat_register(device_t dev, char *str); int sndstat_unregister(device_t dev); /* usage of flags in device config entry (config file) */ From nobody Tue Apr 16 02:34:32 2024 X-Original-To: dev-commits-src-branches@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 4VJSmS751sz5Hb13; Tue, 16 Apr 2024 02:34: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmS4lVzz4HQt; Tue, 16 Apr 2024 02:34:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234872; 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=8ZV3m5v5a1OlUe89elZ/nwNM+OQjyMkSpuHY28aVZbc=; b=MR0aUgedHDWQ9X7kP2ASGoJbAwBeLn54vStHcF9+rtnvxjmo3yixt7ZXp1o+wCU8QFi+Ac hW9oPEGK3EExShk4vtgTwMAPVimEq2pP6k8OooAkZySS8z2Dxu7Q9bRM1Qvvxzt9UniPs6 oosEeEJ7um9dm62uAMJEmQxUX7x0EU6g/qbF9TYyNMOZ5I7OBOtBQd5SVAPpn47PEKTNi3 q1AUJDxUwREGIhMJ6uoLj/gUOnhdcbTNJy3tobHxU587xEj+VanIJT94G49K0qUalDGLej T/hRyGJjV/3e2UK0jYsfYcKiVdRiwQeEq7Qn1H9W+tdSRCN29A+hVOW854XB5A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234872; a=rsa-sha256; cv=none; b=LYrQmLVNt5eSta/phVlDyRfre+EcPtwAefb63wAoMi/WFgUuTSs0jdzXAo0/olM2rn9Pm6 n/a20mlSaF1p4MvmT7lot1hRHRI6cAYj0NavlubCpHjWDBrGkpacVhyMq9aPXptggl4iWI hcVMJCN1o9bKfmMxxkkpy2dCcBm3Vus/uL4/LzYb6Hj4pbM3hs+vSv0BpjAOqisj99DIJi Iiyquxd1oqR5M9FKWxIHrGeySHuxaOUMWRYg7gNguL+dqM9tko2OcxfpkKC59mlpaFBGZQ 7fKzV8e9lk8JhmHwDN1Vmcz3Zx3mBPOTjtLqRQO4tSwvKOjQLovR3Tc0nepYaQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234872; 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=8ZV3m5v5a1OlUe89elZ/nwNM+OQjyMkSpuHY28aVZbc=; b=kFzQrziSIxS6BvzTj4D4mn9vZ+lu8LvDdgdRPHjeiZEceQsh6fhTNqFAmCEK95PK3mCwKF cDQOCUSV6LyRE1Yk4sznC77hda9Pqioj6x84ZOdnhZFE0n1dhpRN4Kw7O9REugfGkPJUH+ cFEJSdi0l94Vsu26CvR7kuFoEGGZzrp0/8JuJ2NGSWtGE4aArpLBwPDytaOhV6aTn95iw/ F99GTh3erzlDSFz06V3nGqiVDYmg3mE4FXCXcc1m42W3BnInH+Jmp3pD6728czTe8h40Tr vngYEa2CKaASPwdSUnzxqXubgO6qB0unhrmJKVKATkfZjqI6Jr14C7Aa+LoSOg== 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 4VJSmS4MHyzPZY; Tue, 16 Apr 2024 02:34:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YW3t037120; Tue, 16 Apr 2024 02:34:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YWFK037117; Tue, 16 Apr 2024 02:34:32 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:32 GMT Message-Id: <202404160234.43G2YWFK037117@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: ebdd5d72fffc - stable/14 - stand/loader.efi: fix regression with ignoring nvstore List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ebdd5d72fffcc92e1f046a7c5d9855b9566231e3 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ebdd5d72fffcc92e1f046a7c5d9855b9566231e3 commit ebdd5d72fffcc92e1f046a7c5d9855b9566231e3 Author: Gleb Smirnoff AuthorDate: 2023-09-11 18:04:48 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:03 +0000 stand/loader.efi: fix regression with ignoring nvstore To read/update the boot loader nvstore, we always need to call zfs_attach_nvstore() regardless of whether we use bootonce key in nvstore or the bootfs property of the pool. The call was unintentionally left in the block of code that is processed only when bootonce key is present. In particular this fixes broken 'nextboot -k'. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D41795 Fixes: e3e2681d0ec28d6661fef6da76c9479049e2761c (cherry picked from commit d13550f0c9c283e6bf7a2a3ec870f92a882c9f21) --- stand/efi/loader/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 123410f83aa0..ca39c242afc3 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -264,8 +264,8 @@ probe_zfs_currdev(uint64_t guid) printf("zfs bootonce: %s\n", buf); set_currdev(buf); setenv("zfs-bootonce", buf, 1); - (void)zfs_attach_nvstore(&currdev); } + (void)zfs_attach_nvstore(&currdev); return (sanity_check_currdev()); } From nobody Tue Apr 16 02:34:34 2024 X-Original-To: dev-commits-src-branches@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 4VJSmW0TDwz5HZhc; Tue, 16 Apr 2024 02:34:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmV6mw1z4H8S; Tue, 16 Apr 2024 02:34:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234875; 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=gxrtiw4JMavj89rVNggCOMeWRJf0gTfpTULZmZ7HLQ4=; b=njtg3Bloxii8aJ4u8wON2JlyuUuBQrvey8aWM0oywZ3WqQHNSwvfcg+ACMER/vM1zHxnhP BBnebZp3Pi/iw+uxBuZpHckwqaqi3NhXtm0IegcGnatE2YQSnKtBmRLJSKTHJR6iR3Xs8B YWHmG4qZ+aYS4Qv9sNDCmOfNstxhFqlNiXNwmHKuWU+Dwk7aC2g00KEY77XGYaTuu10VTX nRFLPa16xmkChuvzCWgBV7+T98WO/d2Ne0QLMit5kwupXk6RYr4wdfzGC0Xn/CRvEC3WZ/ Vf6hUWNjed0gVAshRCQOaiZkl0wtJsCN2z/2ZLaUcBrNaGgpvyPQVYk1MPC3yA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234875; a=rsa-sha256; cv=none; b=kHka3VwyGre658sg4HQx8BIAnTTEeBxf7ygguK/Ru+5pK1qzbaFoCKzJ9MBfAwwf6GvC8y xim1voZJ0IbEtntSA2rHdjvbFbrl95qYvMU/GrAGXD5T6IhNpE3Ct1amQkPwkGGDkYB502 XfblMuvJpWVCkOWWvkFkT0rA4eG5piGlVDYgutqVF0b+CEa3M9WnTiQyzZd5wH1IwyWSui JmNxKENWj6fCnQC70NZG0YhzD1S/agba5kWDoSnJL6aXEkBiQrfq93ktDcfVtncW1Iuc56 4nCkehOXgyISYp6gy2uXOLVLkscUJwQhbBiPoF2kNPYRbCzhO+1hse5mPHj8Zw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234875; 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=gxrtiw4JMavj89rVNggCOMeWRJf0gTfpTULZmZ7HLQ4=; b=jZaIvmex+zggcMNSvfcPQqszltf6FcfkVEqR7Hw1qoMapJqS0R0+QxVcf05bQmkoFqARWe NHyOrRxICBgTiIWdltWELkiriMKresUjhcIyokjsLcua7KviUSVe1jX9H6BfUDExBld3kc sWmCNfWHOaJbaXKECIGAG3LYDRHuUkp54I6XB+y66XWEHwehyxjUCWy4c+PvZqZ0I8UsHc 4KiQ8p2mAhp3lRqLjWaYMtdxSu1FRMfskLcn7XWyyrzbBVoViKsF4TiReeQ4ezeKAS/JNv cdazQ6eImstT42HOGtm2z7Ql4jYdWxmeZAzu9+blk0a6yWSouPVFxXMUFysq1g== 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 4VJSmV6NT0zPZZ; Tue, 16 Apr 2024 02:34:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YYDJ037217; Tue, 16 Apr 2024 02:34:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YYR0037214; Tue, 16 Apr 2024 02:34:34 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:34 GMT Message-Id: <202404160234.43G2YYR0037214@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: b5cd844a564a - stable/14 - loader: add target for dirdeps build List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b5cd844a564a8c9199a193caa89bd7984a53850b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=b5cd844a564a8c9199a193caa89bd7984a53850b commit b5cd844a564a8c9199a193caa89bd7984a53850b Author: Stephen J. Kiernan AuthorDate: 2023-11-02 23:33:45 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:03 +0000 loader: add target for dirdeps build Update dependencies for the loader variations used for each architecture. Reviewed by: sjg Differential Revision: https://reviews.freebsd.org/D39741 (cherry picked from commit 2008043f386721d58158e37e0d7e50df8095942d) --- share/mk/local.dirdeps-options.mk | 2 ++ share/mk/local.dirdeps.mk | 4 ++++ stand/efi/fdt/Makefile.depend | 3 +-- stand/efi/libefi/Makefile.depend | 1 + stand/efi/loader/Makefile.depend | 3 ++- stand/efi/loader/Makefile.depend.arm | 1 - stand/efi/loader/Makefile.depend.arm64 | 1 - stand/efi/loader/Makefile.depend.options | 7 +++++++ stand/efi/loader/Makefile.depend.riscv | 16 ++++++++++++++++ stand/fdt/Makefile.depend | 3 +-- stand/ficl/Makefile.depend | 1 + stand/i386/libi386/Makefile.depend | 3 ++- stand/i386/loader/Makefile.depend | 1 - stand/i386/loader/Makefile.depend.options | 10 ++++++++++ stand/i386/loader_lua/Makefile.depend | 11 +++++++++++ stand/lua/Makefile.depend | 10 ++++++++++ stand/powerpc/ofw/Makefile.depend | 12 ++++++++++++ stand/uboot/Makefile.depend.options | 9 +++++++++ targets/pseudo/loader/Makefile | 1 + targets/pseudo/loader/Makefile.depend.amd64 | 7 +++++++ targets/pseudo/loader/Makefile.depend.arm | 8 ++++++++ targets/pseudo/loader/Makefile.depend.arm64 | 7 +++++++ targets/pseudo/loader/Makefile.depend.i386 | 7 +++++++ targets/pseudo/loader/Makefile.depend.powerpc | 7 +++++++ targets/pseudo/loader/Makefile.depend.riscv | 7 +++++++ 25 files changed, 133 insertions(+), 9 deletions(-) diff --git a/share/mk/local.dirdeps-options.mk b/share/mk/local.dirdeps-options.mk index 9e7f7bbd963c..4eef5311375e 100644 --- a/share/mk/local.dirdeps-options.mk +++ b/share/mk/local.dirdeps-options.mk @@ -24,4 +24,6 @@ DIRDEPS.OPENSSL.no+= lib/libmd DIRDEPS.PAM_SUPPORT.yes+= lib/libpam/libpam DIRDEPS.TCP_WRAPPERS.yes+= lib/libwrap +MK_FDT.${DEP_MACHINE} ?= yes + .-include diff --git a/share/mk/local.dirdeps.mk b/share/mk/local.dirdeps.mk index 7b4a1fdf426d..76860920a3f1 100644 --- a/share/mk/local.dirdeps.mk +++ b/share/mk/local.dirdeps.mk @@ -5,6 +5,10 @@ .include "${SRCTOP}/share/mk/src.opts.mk" .endif +# Machine-specific MK settings needed for Makefile.dirdeps.options usage +MK_FDT.i386 = no +MK_FDT.amd64 = no + # making universe is special .if defined(UNIVERSE_GUARD) # these should be done by now diff --git a/stand/efi/fdt/Makefile.depend b/stand/efi/fdt/Makefile.depend index 15a1f9c07f7c..18537add9fe3 100644 --- a/stand/efi/fdt/Makefile.depend +++ b/stand/efi/fdt/Makefile.depend @@ -1,8 +1,7 @@ # Autogenerated - do NOT edit! DIRDEPS = \ - include \ - include/xlocale \ + stand/libsa \ .include diff --git a/stand/efi/libefi/Makefile.depend b/stand/efi/libefi/Makefile.depend index 18537add9fe3..8a29d17bb768 100644 --- a/stand/efi/libefi/Makefile.depend +++ b/stand/efi/libefi/Makefile.depend @@ -2,6 +2,7 @@ DIRDEPS = \ stand/libsa \ + usr.bin/awk.host \ .include diff --git a/stand/efi/loader/Makefile.depend b/stand/efi/loader/Makefile.depend index 96a148bee2d7..ae9e6b6efaa4 100644 --- a/stand/efi/loader/Makefile.depend +++ b/stand/efi/loader/Makefile.depend @@ -1,9 +1,10 @@ # Autogenerated - do NOT edit! DIRDEPS = \ + bin/sh.host \ stand/efi/libefi \ - stand/ficl \ stand/libsa \ + usr.bin/awk.host \ .include diff --git a/stand/efi/loader/Makefile.depend.arm b/stand/efi/loader/Makefile.depend.arm index 8eb92e94c6e0..4ba1445d8a5f 100644 --- a/stand/efi/loader/Makefile.depend.arm +++ b/stand/efi/loader/Makefile.depend.arm @@ -1,4 +1,3 @@ -# $FreeBSD$ # Autogenerated - do NOT edit! DIRDEPS = \ diff --git a/stand/efi/loader/Makefile.depend.arm64 b/stand/efi/loader/Makefile.depend.arm64 index 8eb92e94c6e0..4ba1445d8a5f 100644 --- a/stand/efi/loader/Makefile.depend.arm64 +++ b/stand/efi/loader/Makefile.depend.arm64 @@ -1,4 +1,3 @@ -# $FreeBSD$ # Autogenerated - do NOT edit! DIRDEPS = \ diff --git a/stand/efi/loader/Makefile.depend.options b/stand/efi/loader/Makefile.depend.options new file mode 100644 index 000000000000..20292bab9bcd --- /dev/null +++ b/stand/efi/loader/Makefile.depend.options @@ -0,0 +1,7 @@ +# options that impact our dependencies +DIRDEPS_OPTIONS = LOADER_LUA + +DIRDEPS.LOADER_LUA.yes += \ + stand/liblua \ + +.include diff --git a/stand/efi/loader/Makefile.depend.riscv b/stand/efi/loader/Makefile.depend.riscv new file mode 100644 index 000000000000..4ba1445d8a5f --- /dev/null +++ b/stand/efi/loader/Makefile.depend.riscv @@ -0,0 +1,16 @@ +# Autogenerated - do NOT edit! + +DIRDEPS = \ + bin/sh.host \ + stand/efi/fdt \ + stand/efi/libefi \ + stand/fdt \ + stand/libsa \ + usr.bin/awk.host \ + + +.include + +.if ${DEP_RELDIR} == ${_DEP_RELDIR} +# local dependencies - needed for -jN in clean tree +.endif diff --git a/stand/fdt/Makefile.depend b/stand/fdt/Makefile.depend index 15a1f9c07f7c..18537add9fe3 100644 --- a/stand/fdt/Makefile.depend +++ b/stand/fdt/Makefile.depend @@ -1,8 +1,7 @@ # Autogenerated - do NOT edit! DIRDEPS = \ - include \ - include/xlocale \ + stand/libsa \ .include diff --git a/stand/ficl/Makefile.depend b/stand/ficl/Makefile.depend index 18537add9fe3..8a29d17bb768 100644 --- a/stand/ficl/Makefile.depend +++ b/stand/ficl/Makefile.depend @@ -2,6 +2,7 @@ DIRDEPS = \ stand/libsa \ + usr.bin/awk.host \ .include diff --git a/stand/i386/libi386/Makefile.depend b/stand/i386/libi386/Makefile.depend index 18537add9fe3..15a1f9c07f7c 100644 --- a/stand/i386/libi386/Makefile.depend +++ b/stand/i386/libi386/Makefile.depend @@ -1,7 +1,8 @@ # Autogenerated - do NOT edit! DIRDEPS = \ - stand/libsa \ + include \ + include/xlocale \ .include diff --git a/stand/i386/loader/Makefile.depend b/stand/i386/loader/Makefile.depend index 9262a05207b6..c687ef93d84e 100644 --- a/stand/i386/loader/Makefile.depend +++ b/stand/i386/loader/Makefile.depend @@ -1,7 +1,6 @@ # Autogenerated - do NOT edit! DIRDEPS = \ - stand/ficl \ stand/i386/btx/btx \ stand/i386/btx/btxldr \ stand/i386/btx/lib \ diff --git a/stand/i386/loader/Makefile.depend.options b/stand/i386/loader/Makefile.depend.options new file mode 100644 index 000000000000..7527fa4bda17 --- /dev/null +++ b/stand/i386/loader/Makefile.depend.options @@ -0,0 +1,10 @@ +DIRDEPS_OPTIONS = FORTH LOADER_LUA + +DIRDEPS.FORTH.yes += \ + stand/ficl \ + +DIRDEPS.LOADER_LUA.yes += \ + stand/liblua \ + stand/lua \ + +.include diff --git a/stand/i386/loader_lua/Makefile.depend b/stand/i386/loader_lua/Makefile.depend new file mode 100644 index 000000000000..993ab0638f4a --- /dev/null +++ b/stand/i386/loader_lua/Makefile.depend @@ -0,0 +1,11 @@ +# Autogenerated - do NOT edit! + +DIRDEPS = \ + include \ + + +.include + +.if ${DEP_RELDIR} == ${_DEP_RELDIR} +# local dependencies - needed for -jN in clean tree +.endif diff --git a/stand/lua/Makefile.depend b/stand/lua/Makefile.depend new file mode 100644 index 000000000000..11aba52f82cf --- /dev/null +++ b/stand/lua/Makefile.depend @@ -0,0 +1,10 @@ +# Autogenerated - do NOT edit! + +DIRDEPS = \ + + +.include + +.if ${DEP_RELDIR} == ${_DEP_RELDIR} +# local dependencies - needed for -jN in clean tree +.endif diff --git a/stand/powerpc/ofw/Makefile.depend b/stand/powerpc/ofw/Makefile.depend new file mode 100644 index 000000000000..15a1f9c07f7c --- /dev/null +++ b/stand/powerpc/ofw/Makefile.depend @@ -0,0 +1,12 @@ +# Autogenerated - do NOT edit! + +DIRDEPS = \ + include \ + include/xlocale \ + + +.include + +.if ${DEP_RELDIR} == ${_DEP_RELDIR} +# local dependencies - needed for -jN in clean tree +.endif diff --git a/stand/uboot/Makefile.depend.options b/stand/uboot/Makefile.depend.options new file mode 100644 index 000000000000..d70bc7edd168 --- /dev/null +++ b/stand/uboot/Makefile.depend.options @@ -0,0 +1,9 @@ +DIRDEPS_OPTIONS = FORTH LOADER_LUA + +DIRDEPS.FORTH.yes += \ + stand/ficl \ + +DIRDEPS.LOADER_LUA.yes += \ + stand/lua \ + +.include diff --git a/targets/pseudo/loader/Makefile b/targets/pseudo/loader/Makefile new file mode 100644 index 000000000000..01b5f23410c8 --- /dev/null +++ b/targets/pseudo/loader/Makefile @@ -0,0 +1 @@ +.include "../Makefile.inc" diff --git a/targets/pseudo/loader/Makefile.depend.amd64 b/targets/pseudo/loader/Makefile.depend.amd64 new file mode 100644 index 000000000000..8e9a786ba236 --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.amd64 @@ -0,0 +1,7 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/efi/loader \ + + +.include diff --git a/targets/pseudo/loader/Makefile.depend.arm b/targets/pseudo/loader/Makefile.depend.arm new file mode 100644 index 000000000000..d23148b537fe --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.arm @@ -0,0 +1,8 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/efi/loader \ + stand/uboot \ + + +.include diff --git a/targets/pseudo/loader/Makefile.depend.arm64 b/targets/pseudo/loader/Makefile.depend.arm64 new file mode 100644 index 000000000000..8e9a786ba236 --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.arm64 @@ -0,0 +1,7 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/efi/loader \ + + +.include diff --git a/targets/pseudo/loader/Makefile.depend.i386 b/targets/pseudo/loader/Makefile.depend.i386 new file mode 100644 index 000000000000..29a2092b8203 --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.i386 @@ -0,0 +1,7 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/i386/loader \ + + +.include diff --git a/targets/pseudo/loader/Makefile.depend.powerpc b/targets/pseudo/loader/Makefile.depend.powerpc new file mode 100644 index 000000000000..6c481c73d253 --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.powerpc @@ -0,0 +1,7 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/uboot \ + + +.include diff --git a/targets/pseudo/loader/Makefile.depend.riscv b/targets/pseudo/loader/Makefile.depend.riscv new file mode 100644 index 000000000000..8e9a786ba236 --- /dev/null +++ b/targets/pseudo/loader/Makefile.depend.riscv @@ -0,0 +1,7 @@ +# This file is not autogenerated - take care! + +DIRDEPS = \ + stand/efi/loader \ + + +.include From nobody Tue Apr 16 02:34:35 2024 X-Original-To: dev-commits-src-branches@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 4VJSmX3HpLz5HZdk; Tue, 16 Apr 2024 02:34:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmX0fj2z4HMW; Tue, 16 Apr 2024 02:34:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234876; 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=uQBwMvMg89n+y0/f0mfD/JEfdEOjpUg8jXZBwlTXDUg=; b=ItcezH+Z5DbnH6YA1q2gw13j/ka5iVyP6UhELr/fLxUQPBh5eRS56QVbuldqDXSPoQKvAG PLBpHbNa3T9Sj5yeC5+l/yq7u+5Hcw71/14t4cIL7SrHwV4QGKVz0dhGiYXGHcpJ37pLUX wlRODM99dkkyLX5xIhpcRPYY3Sx/mLQ9fYmslGyDaBun8TdImUrDEE3RNIZJ5nooyRR1RM SfgPwlwEcaj/CzPeJTMF8OJ4OKc+JesEjpWm0TfKb5jTagjIAuam/HAum3rHHWXX9zbvod Ew6VnHsC32zsnr+qUh5LRVEeq16N2iWmYEjyy9Vqf3Lvh/gW9VswyuQcXNigCQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234876; a=rsa-sha256; cv=none; b=uOiWUkfoPEP9dCQecw6w4G4Ea9dqgmuvXm1Aa2DYq++bAq6N/vpcWqPMwYk9XSZVh6ahrR Ut9lIJKVe0uzp8Wh56AKun2B6YlMwWmfxtq5oXbPKEiBg5YCnMW3tMnb9y6fJYLwpFT2z5 JcBO8ypNDynKw48EjkxG9UDbFAataN1MSY9UpCk3E5KLpXxJZO4QzPNj1V0s1RAgArXTsE kEOryg7MqfI4WhJJXv3sBDVofV0IA1i+cFukeiSXJ3UbECqi2aAFgJF42KtOVg5M5oFZAI huvXAjIqJTwKmsMWYQIzlTZgYsXaQfdDLYAcsGBY5xIu/hLZon6WIBsQ87qE3w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234876; 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=uQBwMvMg89n+y0/f0mfD/JEfdEOjpUg8jXZBwlTXDUg=; b=jq5VcNuv/Qny1gboB1lOWi+bxTauAWXhU43YbkErVbnjsb2eYKWQEKeC7MpwsPJZ9GElq0 Na0ImzbWVkmMhK0ZI7MXhxupqlsIReNfLP43U9ygapsVdxegBABl9xpcKwEGZ4/kXdvowT f3Um6UtTgWm7+4txi9g+qaSpEOecK+F/EWc/Sq6zl0pQlog2M7H5a0CKlg/YdvL6mh87vA t9PmeHnMxvwAIYM+36v5fAbBSkxwkUkIyidAS3yQotW6SkVSUr+eG52oS1KjKOCnsmUQ+A wu0NJ2o5WwhtXfuhp6nodD0OXoqpNUHPx9Btzc6lCD41QhDN62oND3SOkqpWkA== 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 4VJSmX0G2KzQB9; Tue, 16 Apr 2024 02:34:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YZCV037262; Tue, 16 Apr 2024 02:34:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YZPX037260; Tue, 16 Apr 2024 02:34:35 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:35 GMT Message-Id: <202404160234.43G2YZPX037260@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 25cf4c045208 - stable/14 - Add paragraph documenting loader.env functionlity List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 25cf4c045208aff47ae7fece8ccc2717f0c0ad6a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=25cf4c045208aff47ae7fece8ccc2717f0c0ad6a commit 25cf4c045208aff47ae7fece8ccc2717f0c0ad6a Author: Guido Falsi AuthorDate: 2023-11-06 12:11:26 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:03 +0000 Add paragraph documenting loader.env functionlity Approved by: docs (carlavilla) Differential Revision: https://reviews.freebsd.org/D42476 (cherry picked from commit bce728719e7f57272d99b6d039f10b4c636fa024) --- stand/man/loader.efi.8 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/stand/man/loader.efi.8 b/stand/man/loader.efi.8 index 37f56cf7be3f..16165c68556b 100644 --- a/stand/man/loader.efi.8 +++ b/stand/man/loader.efi.8 @@ -205,6 +205,14 @@ does not implement the probe .Fl P functionality where we use the video console if a keyboard is connected and a serial console otherwise. +.Ss Additional Environment Variables +.Nm +loads some extra variables early in startup from +.Pa /efi/freebsd/loader.env +from the EFI partition. Only simple variables can be set here. It can be useful to specify the root filesystem: +.Bd -literal -offset indent +rootdev=disk0s1a +.Ed .Ss Staging Slop The kernel must parse the firmware memory map tables to know what memory it can use. From nobody Tue Apr 16 02:34:37 2024 X-Original-To: dev-commits-src-branches@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 4VJSmY1r6dz5HZqJ; Tue, 16 Apr 2024 02:34:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmY0wwkz4HSy; Tue, 16 Apr 2024 02:34:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234877; 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=V6FAUu8QARWgDVa8ceQA0R1dV6PlkTnhp0ArSM3d6jU=; b=pzc0Wi7p6PR/kwZOKgGTNVBqp7e8BTS57vA4dlyydpjb2BORaWmh7A9jdskZZqoS7aO6zV uCv2GmYtRv7js0IWVQb11C8LHmmVzECKzFHiWe5fH0Pu81bxKKxJ77STTQMlNjaGDFHKZj RTLUV2GuDLSmaacdamjF6Q2eEv9HI4mbWGetu+eiShJFLZjv5fymxl9dzav7eq/JIutFaq sds0UmkZU/3rA/nUaio8qeomWS0cCNQyXEwMJncOwkuQLvjaHmgY5JfYExwPnBfClzcSD/ QUP76QqvUc3JsDHHaZHUkuPH/EK015GyHl5zFO+CRTUfHUikL2RrSOok6IeAtA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234877; a=rsa-sha256; cv=none; b=VuTq4QechzxqkKd/8HXILfDLaO50uGXtVtZgGlQKfHxEUa0ItCDPpNVvG8XASMhafQJi1Q 1HvJ/w8S68DhBTnE4JX4W2BDPcA9PCL/i8WUBf5ICuiCormTCqUTGAz1DEQTQlVbFEVPEM J3Zc70xg2n5wrIoyw73G9f+IlV608FdBLjfD4aVaZxIWHm8CcyAfEm9W8ekAskKLaG2hvU XxPS7eKHCwjG5Frj8BBXyGTZ7eQmjZjOFybFltLB0o0ZcRMHZ7cT7Cc69lgw9WiJWLMGt7 uQY/h0bDirTurc9+C3jTzn7K2XtTHtzE6izGO4dAdQqIRtsmn0cl9/dmhiw4Ww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234877; 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=V6FAUu8QARWgDVa8ceQA0R1dV6PlkTnhp0ArSM3d6jU=; b=ljYEteaAcwOMKtxUVmpd5NG7DUlp67KQFzhSLEm5ZMZFfaqEN7c5lOZMmyUcZ3xkFyW1vn 3Eu9L5YTAFzU+6Ki2mrR3Xn65xaMOZEnHC0TKjMmxVc9d2DGcUFRAt3EHvBUgjhSUzYXf/ VgUfO4VCO89gOTtjQDj6ICHTZbhnI7s2GC6KeJFvpxyDjKjJd6nbueHe3cp98gwudB9iGz gskMrtqtZ72oQGIsrtp/CjRa2ZNMCsoH5YH65ZebJG1Ab4m77aHx5q3UCflQiUCBmeWU6H cDRhB7EVmdWyQmcJ1NmwI0+3umjg48tBefneFTnf4XJIkE+HP2Jp6GeZdja2Ag== 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 4VJSmY0WC8zQ61; Tue, 16 Apr 2024 02:34:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YbXh037301; Tue, 16 Apr 2024 02:34:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YbNT037298; Tue, 16 Apr 2024 02:34:37 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:37 GMT Message-Id: <202404160234.43G2YbNT037298@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 56b90f8fc980 - stable/14 - loader.efi.8: Fix style warnings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 56b90f8fc980a119a30b301ed55b105f98436388 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=56b90f8fc980a119a30b301ed55b105f98436388 commit 56b90f8fc980a119a30b301ed55b105f98436388 Author: Benedict Reuschling AuthorDate: 2023-11-06 14:45:20 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 loader.efi.8: Fix style warnings This is a follow-up commit to bce728719e7f57272d99b6d039f10b4c636fa024 to address mandoc(1) warnings. (cherry picked from commit 94eca4b5f38baa03446216f585089852d98c283a) --- stand/man/loader.efi.8 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/stand/man/loader.efi.8 b/stand/man/loader.efi.8 index 16165c68556b..827c4ced7f2e 100644 --- a/stand/man/loader.efi.8 +++ b/stand/man/loader.efi.8 @@ -209,7 +209,9 @@ serial console otherwise. .Nm loads some extra variables early in startup from .Pa /efi/freebsd/loader.env -from the EFI partition. Only simple variables can be set here. It can be useful to specify the root filesystem: +from the EFI partition. +Only simple variables can be set here. +It can be useful to specify the root filesystem: .Bd -literal -offset indent rootdev=disk0s1a .Ed From nobody Tue Apr 16 02:34:38 2024 X-Original-To: dev-commits-src-branches@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 4VJSmZ479sz5Hb1G; Tue, 16 Apr 2024 02:34:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmZ2Scgz4H77; Tue, 16 Apr 2024 02:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234878; 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=bXuKyNtkI3Qxiecmhd35RRm0sa/J9T4GiEYdXl6cD9A=; b=e/l38S0qQ07zh/cIppBQlBNxoAiHh7JecNNxS+e/9nH8OwxZlRokQtpHJU3ETtMxFgtwGU jbm//xmE5tH7qsaqfVfNDUApsOPPxnP9dGqaTEKNshD3guvVxHkvdniRdtDaN1QldWQbxB qR00O5BSUbZshbdoEQLZNoKHHGQT+2h975P5HcWCO54PXUsJm2Zg5HZ8ec7cacwlYgfiVQ /k6ZJLpmsebH65Bq/O8q81AF8p9g/bNoasV8TUGmmbzF8T4gMVLNca5rdB0qJEN565q1/V oIdvspdEgoykwR7wXVxm/20liFLyNgu0JRuxRxA/VgdPyQyfJNxU/qyHOI8XEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234878; a=rsa-sha256; cv=none; b=XUpDsDXs8NXTtiyARSsJ0fPpgN9E3ZZ8HK4SfZ6beIT62sZrZdowaZKkeaPwCHOgGjKoaL lU6KD7wRzKfFLHyhb6iE3xdJsx9pMxEOiA5WRDCCQ2yZZ0JjgGuQC9U7v+bcHSX7oto4RG nJJIT93ObnuLbdalSnBouc0cYe3ngNlX2+zDYLSpLms6kmhxFFYQZJy98+Qyf8cMtBuqo4 hHC9jYph7CC/jThlX9jSUZsjnekujCnuft/17I3au/ecjmMwEv1n3Ofwxvd1PAW1D/pfY3 96H8U+QZL09XCxslzJs6nTgBihjg3IkWo7InKhWK217Nk5Web+hwiRLeNbzmUA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234878; 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=bXuKyNtkI3Qxiecmhd35RRm0sa/J9T4GiEYdXl6cD9A=; b=xIdW3/A4/Rm67JnGCb/vI4ZJVum0sRTailHoeO6Zy1pa7zK8Zz4tOkjaG+7pdBNAJZz67y HbLXEiQXN7yADbAii9G+CNeQ5lcLDHFtXwdm0jyQMIweyYerDujpPg+L6DJnbezP0objLA QWoFebWpQBbaA+0Lfb1Xq4ZhnKIx0hmDYn1zuNToUPQmUsUt4IF4z2aO5H/lCRc2tKTny/ yUdwtxVnewix5baKvByo0YFsyEyN6045fKWURW/iZ7WFPLdOfEmS+QweyPjKDmsJMD0cdC /DOa1Qf8mGUFq1/E4wju9K5uCdltdGMJ0lNPI5TofP8foErSYg2fJFpywAcDxw== 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 4VJSmZ1pwhzPlt; Tue, 16 Apr 2024 02:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YcpB037346; Tue, 16 Apr 2024 02:34:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YcBh037343; Tue, 16 Apr 2024 02:34:38 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:38 GMT Message-Id: <202404160234.43G2YcBh037343@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 05cf4dda599a - stable/14 - loader: fix EFI ACPI detection List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 05cf4dda599a920ffbfb39edc6b01c32dd178f46 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=05cf4dda599a920ffbfb39edc6b01c32dd178f46 commit 05cf4dda599a920ffbfb39edc6b01c32dd178f46 Author: R. Christian McDonald AuthorDate: 2023-11-20 17:02:24 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 loader: fix EFI ACPI detection lua was previously unable to determine ACPI presence because this probing was postponed until the final loading and execution of the kernel. This patch resolves that by detecting ACPI early (similar to the order of operations in the legacy i386 loader). Reviewed by: kevans Approved by: kp Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D42459 (cherry picked from commit 0b01d45783c3ee5a544c882d1b147e4a60382c41) --- stand/efi/loader/arch/amd64/elf64_freebsd.c | 44 ----------------------- stand/efi/loader/arch/arm64/exec.c | 54 +---------------------------- stand/efi/loader/main.c | 42 ++++++++++++++++++++++ 3 files changed, 43 insertions(+), 97 deletions(-) diff --git a/stand/efi/loader/arch/amd64/elf64_freebsd.c b/stand/efi/loader/arch/amd64/elf64_freebsd.c index 196efb048064..5a41ea99867e 100644 --- a/stand/efi/loader/arch/amd64/elf64_freebsd.c +++ b/stand/efi/loader/arch/amd64/elf64_freebsd.c @@ -41,17 +41,8 @@ #include "bootstrap.h" -#include "platform/acfreebsd.h" -#include "acconfig.h" -#define ACPI_SYSTEM_XFACE -#include "actypes.h" -#include "actbl.h" - #include "loader_efi.h" -static EFI_GUID acpi_guid = ACPI_TABLE_GUID; -static EFI_GUID acpi20_guid = ACPI_20_TABLE_GUID; - extern int bi_load(char *args, vm_offset_t *modulep, vm_offset_t *kernendp, bool exit_bs); @@ -104,9 +95,6 @@ elf64_exec(struct preloaded_file *fp) Elf_Ehdr *ehdr; vm_offset_t modulep, kernend, trampcode, trampstack; int err, i; - ACPI_TABLE_RSDP *rsdp; - char buf[24]; - int revision; bool copy_auto; copy_auto = copy_staging == COPY_STAGING_AUTO; @@ -114,38 +102,6 @@ elf64_exec(struct preloaded_file *fp) copy_staging = fp->f_kernphys_relocatable ? COPY_STAGING_DISABLE : COPY_STAGING_ENABLE; - /* - * Report the RSDP to the kernel. While this can be found with - * a BIOS boot, the RSDP may be elsewhere when booted from UEFI. - */ - - rsdp = efi_get_table(&acpi20_guid); - if (rsdp == NULL) { - rsdp = efi_get_table(&acpi_guid); - } - if (rsdp != NULL) { - sprintf(buf, "0x%016llx", (unsigned long long)rsdp); - setenv("acpi.rsdp", buf, 1); - revision = rsdp->Revision; - if (revision == 0) - revision = 1; - sprintf(buf, "%d", revision); - setenv("acpi.revision", buf, 1); - strncpy(buf, rsdp->OemId, sizeof(rsdp->OemId)); - buf[sizeof(rsdp->OemId)] = '\0'; - setenv("acpi.oem", buf, 1); - sprintf(buf, "0x%016x", rsdp->RsdtPhysicalAddress); - setenv("acpi.rsdt", buf, 1); - if (revision >= 2) { - /* XXX extended checksum? */ - sprintf(buf, "0x%016llx", - (unsigned long long)rsdp->XsdtPhysicalAddress); - setenv("acpi.xsdt", buf, 1); - sprintf(buf, "%d", rsdp->Length); - setenv("acpi.xsdt_length", buf, 1); - } - } - if ((md = file_findmetadata(fp, MODINFOMD_ELFHDR)) == NULL) return (EFTYPE); ehdr = (Elf_Ehdr *)&(md->md_data); diff --git a/stand/efi/loader/arch/arm64/exec.c b/stand/efi/loader/arch/arm64/exec.c index 09be15b2b6f3..ef410a7d556c 100644 --- a/stand/efi/loader/arch/arm64/exec.c +++ b/stand/efi/loader/arch/arm64/exec.c @@ -40,16 +40,6 @@ #include "loader_efi.h" #include "cache.h" -#include "platform/acfreebsd.h" -#include "acconfig.h" -#define ACPI_SYSTEM_XFACE -#define ACPI_USE_SYSTEM_INTTYPES -#include "actypes.h" -#include "actbl.h" - -static EFI_GUID acpi_guid = ACPI_TABLE_GUID; -static EFI_GUID acpi20_guid = ACPI_20_TABLE_GUID; - static int elf64_exec(struct preloaded_file *amp); static int elf64_obj_exec(struct preloaded_file *amp); @@ -73,52 +63,10 @@ elf64_exec(struct preloaded_file *fp) vm_offset_t clean_addr; size_t clean_size; struct file_metadata *md; - ACPI_TABLE_RSDP *rsdp; Elf_Ehdr *ehdr; - char buf[24]; - int err, revision; + int err; void (*entry)(vm_offset_t); - /* - * Report the RSDP to the kernel. The old code used the 'hints' method - * to communicate this to the kernel, but this is now considered legacy. - * Instead, move to setting different tunables that start with acpi. - * The old 'hints' can be removed before we branch for FreeBSD 15. - */ - - rsdp = efi_get_table(&acpi20_guid); - if (rsdp == NULL) { - rsdp = efi_get_table(&acpi_guid); - } - if (rsdp != NULL) { - sprintf(buf, "0x%016llx", (unsigned long long)rsdp); - setenv("hint.acpi.0.rsdp", buf, 1); - setenv("acpi.rsdp", buf, 1); - revision = rsdp->Revision; - if (revision == 0) - revision = 1; - sprintf(buf, "%d", revision); - setenv("hint.acpi.0.revision", buf, 1); - setenv("acpi.revision", buf, 1); - strncpy(buf, rsdp->OemId, sizeof(rsdp->OemId)); - buf[sizeof(rsdp->OemId)] = '\0'; - setenv("hint.acpi.0.oem", buf, 1); - setenv("acpi.oem", buf, 1); - sprintf(buf, "0x%016x", rsdp->RsdtPhysicalAddress); - setenv("hint.acpi.0.rsdt", buf, 1); - setenv("acpi.rsdt", buf, 1); - if (revision >= 2) { - /* XXX extended checksum? */ - sprintf(buf, "0x%016llx", - (unsigned long long)rsdp->XsdtPhysicalAddress); - setenv("hint.acpi.0.xsdt", buf, 1); - setenv("acpi.xsdt", buf, 1); - sprintf(buf, "%d", rsdp->Length); - setenv("hint.acpi.0.xsdt_length", buf, 1); - setenv("acpi.xsdt_length", buf, 1); - } - } - if ((md = file_findmetadata(fp, MODINFOMD_ELFHDR)) == NULL) return(EFTYPE); diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index ca39c242afc3..4100c0680b7f 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -60,6 +60,12 @@ #include "efizfs.h" #include "framebuffer.h" +#include "platform/acfreebsd.h" +#include "acconfig.h" +#define ACPI_SYSTEM_XFACE +#include "actypes.h" +#include "actbl.h" + #include "loader_efi.h" struct arch_switch archsw; /* MI/MD interface boundary */ @@ -901,6 +907,39 @@ ptov(uintptr_t x) return ((caddr_t)x); } +static void +acpi_detect(void) +{ + ACPI_TABLE_RSDP *rsdp; + char buf[24]; + int revision; + + if ((rsdp = efi_get_table(&acpi20)) == NULL) + if ((rsdp = efi_get_table(&acpi)) == NULL) + return; + + sprintf(buf, "0x%016llx", (unsigned long long)rsdp); + setenv("acpi.rsdp", buf, 1); + revision = rsdp->Revision; + if (revision == 0) + revision = 1; + sprintf(buf, "%d", revision); + setenv("acpi.revision", buf, 1); + strncpy(buf, rsdp->OemId, sizeof(rsdp->OemId)); + buf[sizeof(rsdp->OemId)] = '\0'; + setenv("acpi.oem", buf, 1); + sprintf(buf, "0x%016x", rsdp->RsdtPhysicalAddress); + setenv("acpi.rsdt", buf, 1); + if (revision >= 2) { + /* XXX extended checksum? */ + sprintf(buf, "0x%016llx", + (unsigned long long)rsdp->XsdtPhysicalAddress); + setenv("acpi.xsdt", buf, 1); + sprintf(buf, "%d", rsdp->Length); + setenv("acpi.xsdt_length", buf, 1); + } +} + EFI_STATUS main(int argc, CHAR16 *argv[]) { @@ -947,6 +986,9 @@ main(int argc, CHAR16 *argv[]) /* Get our loaded image protocol interface structure. */ (void) OpenProtocolByHandle(IH, &imgid, (void **)&boot_img); + /* Report the RSDP early. */ + acpi_detect(); + /* * Chicken-and-egg problem; we want to have console output early, but * some console attributes may depend on reading from eg. the boot From nobody Tue Apr 16 02:34:39 2024 X-Original-To: dev-commits-src-branches@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 4VJSmb4XXLz5Hb3p; Tue, 16 Apr 2024 02:34:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmb3Bhbz4HRS; Tue, 16 Apr 2024 02:34:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234879; 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=5JO6XmnnvJKg0UiapjFDpn8IR2JpYowwQLDU8c4VqtQ=; b=ltf00h1pN+kFRFat/dX+CQQk+puMvRleE9p/zs/zPBVlrzL5YRLZexvWG5tuM6qjSRXL3c DR97FkoJR7dkzE36RH3TYRUkmuSKrdy7WYSno7std+iRErTgGNDwCemIRGm7Q/8TRxsznP //0py3MOoU2oyjnHVq8IN1CMNvBekqt5yJzynCu8ofaI2LjJS0yJvEHbUlyOsPoGi5qigv VMkYWrhyMZkT7gyb/zxYqUw4JTG/GuKMc6bd+F4pzXeWjPKlvy6RIRIbJ352dNdgv+IavY WxQcRt4eUgfKCHgMI+6iqDpFZpTg7PyzvxutEA8YJfgzNX+Ulnk1z3acEX36Dg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234879; a=rsa-sha256; cv=none; b=sEepDOcQHE0xbv1OpKqGTszjd5it6a5zT7zdZ2iCVIPMpFAw/mV1WHdByOGyoubzpZxrqF J8A7Z1eVtQN1GlACftUgTL45YkfK9A8b/ezwxfzcyLkll2mlcwDhMc0/Lns0Elp8hVHMGc ASn5GCsMDkRkESTZXyKQPAAgLqG/RhSCsMDZm97Tsq++S9Y812wFomWurh5GvH51czKPvb b3EDQanMqxqZFtA0gJW3zHJXqRk4R12bpUHInAReD3h9MyltVND12syKmkgxgDypFy2sZg zz5H8gDyDdmN2YRwzR+2CgEVRG4nwhQKfZG4U0PKPYycqejKE9ogwNud8Ry+/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234879; 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=5JO6XmnnvJKg0UiapjFDpn8IR2JpYowwQLDU8c4VqtQ=; b=CxWd9/G7qd2Xu8rVrZv7e5FaEl8/Z+42yQ8ij8TjHMcX1HUmV6EuAPy54utL1PkE310m0J LHBzgvp8GXrtH37KCT4S0xteZyGbmLmFPE/cwgmD9DxSu1MK4vEd/gNyFdLHDBDqshZSts g9woKdwNNRHhcpvyXvSb5FoZdW11qjitZLtOQS0rEIMM6hCINoQ8tsL82ahp8jYeZIPpCf MBBzSNE5sVuDkK+WkMU9X2w4T0Oq2JKU272Z8e021px3jQPN/Hj8wgVZPVPZuDB70JaFad 77MoucSmpFBdjKUk95KPvL5tJngSHhckoROV1yZ+pIVmCP17vcd1TDk6/bH2sg== 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 4VJSmb2pSjzPZb; Tue, 16 Apr 2024 02:34:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YdJs037397; Tue, 16 Apr 2024 02:34:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YdwH037394; Tue, 16 Apr 2024 02:34:39 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:39 GMT Message-Id: <202404160234.43G2YdwH037394@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 16c09de80135 - stable/14 - loader: improve lua ACPI detection and handling List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 16c09de801353a3e88addd9c43966fc8e01b2822 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=16c09de801353a3e88addd9c43966fc8e01b2822 commit 16c09de801353a3e88addd9c43966fc8e01b2822 Author: R. Christian McDonald AuthorDate: 2023-11-20 17:13:08 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 loader: improve lua ACPI detection and handling This is a follow-up patch to https://reviews.freebsd.org/D42459 that modifies the loader lua to use the correct loader variables for determining ACPI availability. This also fixes a bug where ACPI can be inadvertently disabled when setting System Defaults at the loader menu. Reviewed by: imp, kevans Approved by: kp Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D42483 (cherry picked from commit e0f3dc82727f236b0bea495d8a4d6e6dc630854d) --- stand/lua/core.lua | 39 +++++++++++++++------------------------ stand/lua/core.lua.8 | 22 +++++++++------------- stand/lua/menu.lua | 2 +- 3 files changed, 25 insertions(+), 38 deletions(-) diff --git a/stand/lua/core.lua b/stand/lua/core.lua index 747f8c1f0fcf..3bbdca3de01e 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -32,6 +32,7 @@ local hook = require("hook") local core = {} +local default_acpi = false local default_safe_mode = false local default_single_user = false local default_verbose = false @@ -46,20 +47,14 @@ local function composeLoaderCmd(cmd_name, argstr) end local function recordDefaults() - -- On i386, hint.acpi.0.rsdp will be set before we're loaded. On !i386, - -- it will generally be set upon execution of the kernel. Because of - -- this, we can't (or don't really want to) detect/disable ACPI on !i386 - -- reliably. Just set it enabled if we detect it and leave well enough - -- alone if we don't. - local boot_acpi = core.isSystem386() and core.getACPIPresent(false) local boot_single = loader.getenv("boot_single") or "no" local boot_verbose = loader.getenv("boot_verbose") or "no" + + default_acpi = core.getACPI() default_single_user = boot_single:lower() ~= "no" default_verbose = boot_verbose:lower() ~= "no" - if boot_acpi then - core.setACPI(true) - end + core.setACPI(default_acpi) core.setSingleUser(default_single_user) core.setVerbose(default_verbose) end @@ -137,18 +132,18 @@ function core.setSingleUser(single_user) core.su = single_user end -function core.getACPIPresent(checking_system_defaults) - local c = loader.getenv("hint.acpi.0.rsdp") +function core.hasACPI() + return loader.getenv("acpi.rsdp") ~= nil +end - if c ~= nil then - if checking_system_defaults then - return true - end - -- Otherwise, respect disabled if it's set - c = loader.getenv("hint.acpi.0.disabled") - return c == nil or tonumber(c) ~= 1 +function core.getACPI() + if not core.hasACPI() then + return false end - return false + + -- Otherwise, respect disabled if it's set + local c = loader.getenv("hint.acpi.0.disabled") + return c == nil or tonumber(c) ~= 1 end function core.setACPI(acpi) @@ -378,7 +373,7 @@ function core.loadEntropy() end function core.setDefaults() - core.setACPI(core.getACPIPresent(true)) + core.setACPI(default_acpi) core.setSafeMode(default_safe_mode) core.setSingleUser(default_single_user) core.setVerbose(default_verbose) @@ -470,10 +465,6 @@ function core.isSerialBoot() return false end -function core.isSystem386() - return loader.machine_arch == "i386" -end - -- Is the menu skipped in the environment in which we've booted? function core.isMenuSkipped() return string.lower(loader.getenv("beastie_disable") or "") == "yes" diff --git a/stand/lua/core.lua.8 b/stand/lua/core.lua.8 index e1752475f942..cb52ae9f1b30 100644 --- a/stand/lua/core.lua.8 +++ b/stand/lua/core.lua.8 @@ -90,7 +90,7 @@ constants. .Ss Exported functions The following functions are exported from .Nm : -.Bl -tag -width core.getACPIPresent -offset indent +.Bl -tag -width core.setSingleUser -offset indent .It Fn core.setVerbose verbose Sets or unsets .Ev boot_verbose . @@ -103,15 +103,14 @@ Sets or unsets If .Fa singleUser is omitted, toggle the current single user setting. -.It Fn core.getACPIPresent checkingSystemDefaults -Check whether ACPI is present. -This will only be accurate for i386-compatible loaders, including non-UEFI -loaders on amd64 systems. -If -.Fa checkingSystemDefaults -is true, ignore the current value of -.Ev hint.acpi.0.disabled . -Otherwise, return true only if ACPI is both present and not disabled. +.It Fn core.getACPI +Return true if ACPI is both present and not explicitly disabled by +.Ev hints.acpi.0.disabled . +.It Fn core.hasACPI +Checks whether ACPI support is present. +This requires the loader to probe the system and set +.Ev acpi.rsdp +early before starting the interpreter. .It Fn core.setACPI acpi Sets or unsets .Ev acpi_load , @@ -209,9 +208,6 @@ This checks .Ev boot_serial , and .Ev boot_multicons . -.It Fn core.isSystem386 -Returns true if this bootloader was compiled as an i386 binary. -This generally applies to i386 loaders as well as non-UEFI loaders on amd64. .It Fn core.deepCopyTable tbl Recursively deep copies .Fa tbl diff --git a/stand/lua/menu.lua b/stand/lua/menu.lua index 7da03ad9e673..4a948acf8241 100644 --- a/stand/lua/menu.lua +++ b/stand/lua/menu.lua @@ -176,7 +176,7 @@ menu.boot_options = { -- acpi { entry_type = core.MENU_ENTRY, - visible = core.isSystem386, + visible = core.hasACPI, name = function() return OnOff(color.highlight("A") .. "CPI :", core.acpi) From nobody Tue Apr 16 02:34:40 2024 X-Original-To: dev-commits-src-branches@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 4VJSmc5yWfz5Hb1H; Tue, 16 Apr 2024 02:34:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmc4TgYz4HTY; Tue, 16 Apr 2024 02:34:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234880; 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=UlgZb+SifwEK3wusaYg0Xut2GvbwAVkt+6TVKfNYA+w=; b=cer3aM39xwz6ScuoUZJ0dWLNjL+2F1fMAyJQ/RNclBcXXHcO1exgweZSCJcngO3xdDosXE i9D80MDTMgqfnuPFTVCpFIfxQ58cMLA227qHLL0hZEtdEHFGxYKfGux9vt8fSitdkkvr6y GGtmEfqREq3OCCxX2/nqA4Hb+TvKs88B4o4uqjLaqDFI4Cy0p2rixReUK9vEwKOARcEgFf 0NVNGn3A+0vusKM2ncxLeW84vLXRPtI0ZEtzS6abQ2I+Gbx8s7shkRa2xhcRCCvRlIGF5c UNDEqs6IKvCgMOSVK3oqXSPKEKtNsdoYbPptjPCKz/JNphQe/RM/IjX2wfMejQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234880; a=rsa-sha256; cv=none; b=xF9CjtN8ieOFjgMB1Xv4RpvSUwvdBdUDhft9nsmPQEwdyjJyfNrP7topu3MzSZvFylTLeY kX5uuIQd/6GMmAOiCD3Am+02o25umg0j5WVTiHPBBxSo+QOIDZa9l5aDDi++Doq5ATf2+t 2RuqbU/jMa5iD22hI3Z4rxXZfFpznPVdu3WelRtB89tmyHkehORd4Yn79vEkIW6duYTXbY c1kMOoq21roaOYeg/SLopBMbyxslGh46vV+irtuBJHOkNO5dfKlrSW+BsKU3pXTwMCjQjW s5SoPjHVZWQd2PBWMgjvKQZg8OmJnedgSJioll8dqDSxhIUf+ms4nDtjBShagA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234880; 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=UlgZb+SifwEK3wusaYg0Xut2GvbwAVkt+6TVKfNYA+w=; b=NlqIX6r+LvIW84z3cKUByjLmp9RMGc4qVdyCsjpRNMbdJxOIUe7TgiF+6Jv0Rs3PDLjNf/ BKFQgy2YEpe8IBcem8PeMcrhAeO7C4DhEf+0JehTXpWmp75UYp79wcVLAmz9sLEC8waEws 1Oghq+0V9hjqF+G/qUWc03UFsBZVtz31uRnnxlC+Zlr9Er1PaX6zFeH4fGLlZXTWRVU/xa huj6jy3KpMF8q282gbh3MB+y7P1CDqiRNvI5ZkY42xT2yxxscEnYgQ4I9SkrLj6sXojId7 FpThdLLTRPJyuaaatLllnXiPQeX/LQMznEyMa2Sq0absBIRJfRJPngF98kGkjA== 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 4VJSmc3q9VzPlv; Tue, 16 Apr 2024 02:34:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YeSh037439; Tue, 16 Apr 2024 02:34:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YeBa037436; Tue, 16 Apr 2024 02:34:40 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:40 GMT Message-Id: <202404160234.43G2YeBa037436@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 9408d0ba3d11 - stable/14 - stand: bandaide for acpi List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9408d0ba3d11ae59420706e0733cbcf0b022db85 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9408d0ba3d11ae59420706e0733cbcf0b022db85 commit 9408d0ba3d11ae59420706e0733cbcf0b022db85 Author: Warner Losh AuthorDate: 2023-11-21 03:30:16 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 stand: bandaide for acpi Old binaries do not set acpi.rsdp early enough. So when we boot with an older loader.efi from an ESP that's not been updated, we assume there's no ACPI on this system. This is unwise. Put a band-aide on this until we can implement a proper 'feature' variable that the binary reports so we can do conditionals for things like this in the future. This is at best a rapid-response stop-gap. Glanced at by: kevans Sponsored by: Netflix (cherry picked from commit 0abe05aeac29d99786401b9078e97dcead35f7f3) --- UPDATING | 11 +++++++++++ stand/lua/core.lua | 7 ++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index ee9fb7a3103b..d211814b0248 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,13 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20240415: + MFC e0f3dc82727f: If you have an arm64 system that uses ACPI, you will + need to update your loader.efi in the ESP when you update past this + point. Detection of ACPI was moved earlier in the binary so the scripts + could use it, but old binaries don't have this, so we default to 'no + ACPI' in this case. + 20240218: MFC of 713db49d06de changed 'struct ieee80211vap' internals in net80211. Given we do not have enough spares and the struct is allocated by @@ -25,6 +32,10 @@ and/or ports. non-compliant MTAs; please see the first 8.18.1 release note in contrib/sendmail/RELEASE_NOTES for mitigations. +20231113: + The WITHOUT_LLD_IS_LD option has been removed. When LLD is enabled + it is always installed as /usr/bin/ld. + 20240119: Commit d34f4baaf138 changed the internal interface between the nfscommon and nfscl modules. As such, both need to be diff --git a/stand/lua/core.lua b/stand/lua/core.lua index 3bbdca3de01e..e7ffdc091c0c 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -136,9 +136,14 @@ function core.hasACPI() return loader.getenv("acpi.rsdp") ~= nil end +function core.isX86() + return loader.machine_arch == "i386" or loader.machine_arch == "amd64" +end + function core.getACPI() if not core.hasACPI() then - return false + -- x86 requires ACPI pretty much + return false or core.isX86() end -- Otherwise, respect disabled if it's set From nobody Tue Apr 16 02:34:41 2024 X-Original-To: dev-commits-src-branches@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 4VJSmf12l4z5Hb41; Tue, 16 Apr 2024 02:34:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmd4sd5z4HTn; Tue, 16 Apr 2024 02:34:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234881; 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=4hqebnUDW/lawMOoGEk4hvpZaYDuhlnt5nYpHbWw0xE=; b=Hh6h6WfljXU6mFM34v5iscSWMRZRPSUudwMBv39fztNbirHauRnhUmV8xR5rFGyUVgv+J5 FtGn+WI6HUTFgeR9pS7B8NAvrb0IOWYy7wTALKvDQMQdueUfouHbNNHBCGIzYPhBaFx6Cp aamUPZFBH3dFt2q3izqBAA2XviDv1dZQez7cxgqH5xVZ2Zn4VhM4yprQ9S72ImtagPh78K OVXpCdPotzKEU9Uim9p+rc1hurCAIUUcoYyP+hLy+Ldm1sbTvkSoUEyOXbJAjjb0nvpGLD U54w4fRfNDhgygijSZxltVqHoHzhvi2YNhg0mD+Dy65Zv9NVSRvG8aT9fM7eIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234881; a=rsa-sha256; cv=none; b=DfXu6Xn8N5o8YLJBJTg2DZfnfRubBuz6EDT67qwF9eMMJDgIIVB3ChVPkxAeA1WUL7S7kp QciRUuNd4kDNfyeBBXghrdLWuhvEGuDnSEPDPj4zIKwusGBwyyHzxTjsbek4xi1DjOZaID 8Vc401HNZ9jji8iIql+IOvag8cY2F0jtN2g4esbkwBGrWX1u7OL+M8w5VoHkHfnqzKG/rM FAaxAinJtPovQsvyzopEBk6XDwWPpQhBRXcDOzNd2t53fMAAarUTXANdMl0mH5Besacu0Z 7ELvrdewJdxCsXzBwLd+Nf1/r5NiZD0IqfG+XKY9k0zIzdWoq4SqAq3ZpoQOYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234881; 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=4hqebnUDW/lawMOoGEk4hvpZaYDuhlnt5nYpHbWw0xE=; b=aUxcZg/PLGVvZTHBbRubOXOyHbvXYZKa2NB1ms6612yfiNTINwar/Lwffp4bPnAJoxWjaY DCG1QHYHpoOYn3afcztQWTjA2IojJvboQ/5NbaKuFpd95LQO0o76GJrhZNr1vvel/pa/ye luh4GOuqfOjxQZEkP1CM6lpa30PCqW04cRGMLCm4pdLkhMB4IQTmOrNU93rm14jkHmulMH idyKPqFsz98Nediesdv4Ei+iQoZ+mz7BKmDxUhzRYV49lxCGryPcxNak88+WnCzf5mUq0P MK8kDX2N34H4fbiQgyFQFf/Y4ZBejffVinRJ5InJ/cNHrWbVtmkjjejuF8BntQ== 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 4VJSmd4T3jzQ62; Tue, 16 Apr 2024 02:34:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YfVi037487; Tue, 16 Apr 2024 02:34:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YfKN037484; Tue, 16 Apr 2024 02:34:41 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:41 GMT Message-Id: <202404160234.43G2YfKN037484@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 58b95f5f8667 - stable/14 - stand/efi: Request ACPI use the system inttypes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 58b95f5f86671c68aa05973e14d842d9151a75a5 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=58b95f5f86671c68aa05973e14d842d9151a75a5 commit 58b95f5f86671c68aa05973e14d842d9151a75a5 Author: Warner Losh AuthorDate: 2023-11-21 15:56:35 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 stand/efi: Request ACPI use the system inttypes With the system inttypes, we build on all platforms again. Suggested by: andrew Fixes: 0b01d45783c3 Sponsored by: Netflix (cherry picked from commit 488bc7e9a77763dde6919d3c83e57d1fc8175ca2) --- stand/efi/loader/main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 4100c0680b7f..73c61f5dac71 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -60,6 +60,7 @@ #include "efizfs.h" #include "framebuffer.h" +#define ACPI_USE_SYSTEM_INTTYPES #include "platform/acfreebsd.h" #include "acconfig.h" #define ACPI_SYSTEM_XFACE From nobody Tue Apr 16 02:34:42 2024 X-Original-To: dev-commits-src-branches@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 4VJSmf6wvYz5HZqQ; Tue, 16 Apr 2024 02:34:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmf5YQ0z4HV9; Tue, 16 Apr 2024 02:34:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234882; 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=4SpBv0zqcTcv9kLco1ePT1isob/Rw8GMyiNzsETwM9A=; b=A3pkoW75SMqZ6rnZ1MYss5OD923BYlGXuYhU8w4cA4VFBsYAQt8v3PiYM/mscUTrp+nknJ SSmIZEt1yo38MsnqXos4KdpWOXX+tW1U6zxcEAafYS0jD2sCDwKFJ5JJnYX++qFnGqewiy h8945BO7M+8SWDv/ZkMqJhd2qmo7FZN6mYZixCDEsm8tbLLlDjUskRDmI14edoomzZPDxU nwgyXsfcMSAG5xw89dSM66yHhCzzirgYZ1LnxSinQgtVSW+c9QfAKCHDukjEpaMtRKepLR wk8Jz/ZWgcdJAS0SQup1k3451Zs+UCkMA3WGeDTfXHsbQRW+53jTNWc+0h3qpg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234882; a=rsa-sha256; cv=none; b=g6PhSeUBL6WXnxr84wpCYFTJ8rDdt8/E3UMm1PAsdExINmvJsGXugH1+6BeSsyc1/Fy9c+ ImyRB/ueFkaEa7XUd15zQce/pJz4yCHLHXOus2kTOusWHfvH+i6y3ed+AhgwoRhrN9jfXU E6C5WflmPlT2i9tTYBSGu6L4voDUcTpdsFoeGYf7C6/Tn7k+9SEB2/RhqgKdb64fz1b6oP tfT42E8KVr8WYKnylJIE2toPzPjq3YfOWTc+8B6jZH4e70NCjHKssd8dWDUQPBv00ZlZWF Zq6J8F6P0B6UULO3VaJ27IK4XTrGaC5s7TvcQNqZWI6TPpvljLX5MHrX4rqHyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234882; 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=4SpBv0zqcTcv9kLco1ePT1isob/Rw8GMyiNzsETwM9A=; b=gxNo8GadsUnZi0Bne0iz2oRriPNl2tn1myNaJvm6uZYR/GFod1OLPHvkyqy8tAe2jDUiZV v7UWnIQKUik4u+//HIoYdWBiZO0oOqYBwZbYLDh/oQapnyVtQCbTwHsXlSlqRHoXaslatT 5Mw4kv4CwW+mFaASBdIbah13TAuImv6r92mb3GgcXwZVWEeTFUZr34rBQ5PNVzrh31tWHT /TQA/ZdvxOAJHu6dZ4Kd4kefcMMtX02fxVuHIll9NYXFrBF0WI24YGVp8KjJg9mOEO6IrE NvKlUpwS3wcKuL3+NkLqx0MdtQCfqqqmnvQKJqPy1Kc+BOsmitMY1TDbd0hioQ== 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 4VJSmf59fwzQ63; Tue, 16 Apr 2024 02:34:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YgN7037542; Tue, 16 Apr 2024 02:34:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2Ygvk037539; Tue, 16 Apr 2024 02:34:42 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:42 GMT Message-Id: <202404160234.43G2Ygvk037539@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: beab67c8f6b2 - stable/14 - stand/efi: Define ACPI_USE_SYSTEM_INTTYPES to be 1 instead of blank List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: beab67c8f6b227c621d059a19d7e45b8e5fab344 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=beab67c8f6b227c621d059a19d7e45b8e5fab344 commit beab67c8f6b227c621d059a19d7e45b8e5fab344 Author: Warner Losh AuthorDate: 2023-11-21 18:36:18 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 stand/efi: Define ACPI_USE_SYSTEM_INTTYPES to be 1 instead of blank To avoid a redefinition warning... This needs to be redone correctly, but this gets amd64 building again... My amd64 environment is polluted with something that caues earlier failures which I ignored... Fixes: 488bc7e9a777 Sponsored by: Netflix (cherry picked from commit e4789047ffd1319be337711ae4b6c594378f31b2) --- stand/efi/loader/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 73c61f5dac71..9b691ce9ae98 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -60,7 +60,7 @@ #include "efizfs.h" #include "framebuffer.h" -#define ACPI_USE_SYSTEM_INTTYPES +#define ACPI_USE_SYSTEM_INTTYPES 1 #include "platform/acfreebsd.h" #include "acconfig.h" #define ACPI_SYSTEM_XFACE From nobody Tue Apr 16 02:34:43 2024 X-Original-To: dev-commits-src-branches@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 4VJSmh10fZz5HZpd; Tue, 16 Apr 2024 02:34: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmh03yhz4HdF; Tue, 16 Apr 2024 02:34:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234884; 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=5SVI7YvFfOp/uI1BEVhxdsPDuBZ/XyKpIdn77dS5yCo=; b=jlbO1PqU2hLgkZmfNWT0fh4p/VjmgIPAmuHXFHPLiBrtUZha47mZtS3gxV41ywLIqzdoah Ma7Zx4GsAGSuriiPvs0RVwj5NMV4xtEWVbef7o4DXNInqyxCFS/b+ccz+APtXVHDtgAfqg AHgrqpFGtuAQai2N/J7QQBeFaYAkzeODdrI1O0NjIvPl5rU3sWysnzXJRczyaAtDVXuZhd c6Ykuhc1u1ErCeqhXFsmZsvgdwI0gdlRuf+kKasHvrlrV1r6dLM8edAVPc5imxmpVYUqHv 6bvRleKBvSo5iEQVg1i6aZVh3uorEivVJxP9k0XEsc+45Tl7jx9nJYNBG+XlrQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234884; a=rsa-sha256; cv=none; b=lAyJDctc8rTBU1ICTMwtBW1LmXCioz8clBqYKRh6I8y5B1OauyIYypVOlbjLyYpaFV3qKk IZjk3PtTIJjKJz29wXS4q+iJKyCqoMumTP0huswFUXzY5QE1/Ux4irauhMWku7Yvx5EuGb JF17rvIsAwFYNS2E8AsgE2/zOXuy8rCrDnxrhIHoSXVCUOSwyUMHRI9Rz+IBHypviMg8Ik ScqIuwzm1biZPNqwkY0p6mCcYyuSr50Ka2OZ6z/iWWifhxLZEA9hRyb/xdjK5Xg9iqUmy4 ZQSmkjU7AnsiglPgw2wue5JF8j7e5XFlWKQ0q+w+cHJa3WxDTK5qyW9+2He4JA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234884; 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=5SVI7YvFfOp/uI1BEVhxdsPDuBZ/XyKpIdn77dS5yCo=; b=vLFHRQU1J61HxJT/QwUP9xlHdY5aVkA81SY7Dw/a8rzIfj1XgpdAO35ew8jDAJOQ73FhgO y6+iCmyh+rgKE7tvHBS0rmhjk+uT5rQbg9msUGcHTyE4RK+jxHEpamPJojr/LBsEdI9TIV +cI/1WjPojF5AxA0bnDGlJITeUYA1hme9dm+I2X/l5tdIV1U1TqsvnayAgAf15Wii/sudg HBNcciDXSevmUVJKThqsW76Umu7EraTW+w5pFygFfFAzgEcVplT59I77AbQzTwi7qo4Qou 2zZs4QbXwZHDxCFrdAkj0sxwBWimaABIzqIayJ/Y+w/Aq8TZ0qxg9+g/Wg+wVg== 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 4VJSmg6VYmzPpk; Tue, 16 Apr 2024 02:34:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2Yh8R037582; Tue, 16 Apr 2024 02:34:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2Yh3w037579; Tue, 16 Apr 2024 02:34:43 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:43 GMT Message-Id: <202404160234.43G2Yh3w037579@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: ac0776ecf4f1 - stable/14 - stand/efi: Consolidate integer types List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ac0776ecf4f185a8ade56d1f8d40fce4b72f9543 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ac0776ecf4f185a8ade56d1f8d40fce4b72f9543 commit ac0776ecf4f185a8ade56d1f8d40fce4b72f9543 Author: Warner Losh AuthorDate: 2023-11-22 02:58:20 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 stand/efi: Consolidate integer types We have no need for 5 different copies of these. Sponsored by: Netflix Reviewed by: rcm, kevans, andrew Differential Revision: https://reviews.freebsd.org/D42699 (cherry picked from commit 7a1bc422d109a7cee56dcfbac616eda613c1c43e) --- stand/efi/include/amd64/efibind.h | 83 --------------------------------------- stand/efi/include/arm/efibind.h | 35 ----------------- stand/efi/include/arm64/efibind.h | 76 ----------------------------------- stand/efi/include/efi.h | 31 +++++++++++++++ stand/efi/include/i386/efibind.h | 83 --------------------------------------- stand/efi/include/riscv/efibind.h | 76 ----------------------------------- stand/efi/loader/main.c | 1 - 7 files changed, 31 insertions(+), 354 deletions(-) diff --git a/stand/efi/include/amd64/efibind.h b/stand/efi/include/amd64/efibind.h index 2f900786fb9d..d005ade221c4 100644 --- a/stand/efi/include/amd64/efibind.h +++ b/stand/efi/include/amd64/efibind.h @@ -26,89 +26,6 @@ Revision History #pragma pack() - -#ifdef __FreeBSD__ -#include -#else -// -// Basic int types of various widths -// - -#if (__STDC_VERSION__ < 199901L ) - - // No ANSI C 1999/2000 stdint.h integer width declarations - - #ifdef _MSC_EXTENSIONS - - // Use Microsoft C compiler integer width declarations - - typedef unsigned __int64 uint64_t; - typedef __int64 int64_t; - typedef unsigned __int32 uint32_t; - typedef __int32 int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - #ifdef UNIX_LP64 - - // Use LP64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long uint64_t; - typedef long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - - // Assume P64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long long uint64_t; - typedef long long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #endif - #endif -#endif -#endif /* __FreeBSD__ */ - -// -// Basic EFI types of various widths -// - -#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine */ -#define ACPI_USE_SYSTEM_INTTYPES 1 /* Tell ACPI we've defined types */ - -typedef uint64_t UINT64; -typedef int64_t INT64; - -#ifndef _BASETSD_H_ - typedef uint32_t UINT32; - typedef int32_t INT32; -#endif - -typedef uint16_t UINT16; -typedef int16_t INT16; -typedef uint8_t UINT8; -typedef int8_t INT8; - -#endif - -#undef VOID -#define VOID void - - -typedef int64_t INTN; -typedef uint64_t UINTN; - #ifdef EFI_NT_EMULATOR #define POST_CODE(_Data) #else diff --git a/stand/efi/include/arm/efibind.h b/stand/efi/include/arm/efibind.h index 8bc9f4b56eb2..a08d26ac84c4 100644 --- a/stand/efi/include/arm/efibind.h +++ b/stand/efi/include/arm/efibind.h @@ -40,41 +40,6 @@ Abstract: #endif -#ifdef __FreeBSD__ -#include -#else -// -// Assume standard IA-32 alignment. -// BugBug: Need to check portability of long long -// -typedef unsigned long long uint64_t; -typedef long long int64_t; -typedef unsigned int uint32_t; -typedef int int32_t; -typedef unsigned short uint16_t; -typedef short int16_t; -typedef unsigned char uint8_t; -typedef signed char int8_t; -#endif - -typedef uint64_t UINT64; -typedef int64_t INT64; -typedef uint32_t UINT32; -typedef int32_t INT32; -typedef uint16_t UINT16; -typedef int16_t INT16; -typedef uint8_t UINT8; -typedef int8_t INT8; - -#undef VOID -#define VOID void - -// -// Native integer size in stdint.h -// -typedef uint32_t UINTN; -typedef int32_t INTN; - #define EFIERR(a) (0x80000000 | a) #define EFI_ERROR_MASK 0x80000000 #define EFIERR_OEM(a) (0xc0000000 | a) diff --git a/stand/efi/include/arm64/efibind.h b/stand/efi/include/arm64/efibind.h index 4fdfd9f21386..417da1b4d4ff 100644 --- a/stand/efi/include/arm64/efibind.h +++ b/stand/efi/include/arm64/efibind.h @@ -26,82 +26,6 @@ Revision History #pragma pack() - -#ifdef __FreeBSD__ -#include -#else -// -// Basic int types of various widths -// - -#if (__STDC_VERSION__ < 199901L ) - - // No ANSI C 1999/2000 stdint.h integer width declarations - - #ifdef _MSC_EXTENSIONS - - // Use Microsoft C compiler integer width declarations - - typedef unsigned __int64 uint64_t; - typedef __int64 int64_t; - typedef unsigned __int32 uint32_t; - typedef __int32 int32_t; - typedef unsigned __int16 uint16_t; - typedef __int16 int16_t; - typedef unsigned __int8 uint8_t; - typedef __int8 int8_t; - #else - #ifdef UNIX_LP64 - - // Use LP64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long uint64_t; - typedef long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - - // Assume P64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long long uint64_t; - typedef long long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #endif - #endif -#endif -#endif /* __FreeBSD__ */ - -// -// Basic EFI types of various widths -// - - -typedef uint64_t UINT64; -typedef int64_t INT64; -typedef uint32_t UINT32; -typedef int32_t INT32; -typedef uint16_t UINT16; -typedef int16_t INT16; -typedef uint8_t UINT8; -typedef int8_t INT8; - - -#undef VOID -#define VOID void - - -typedef int64_t INTN; -typedef uint64_t UINTN; - //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ // BugBug: Code to debug // diff --git a/stand/efi/include/efi.h b/stand/efi/include/efi.h index 20776dcee2fc..b603c3a78205 100644 --- a/stand/efi/include/efi.h +++ b/stand/efi/include/efi.h @@ -39,6 +39,37 @@ Revision History #define EFI_FIRMWARE_MINOR_REVISION 62 #define EFI_FIRMWARE_REVISION ((EFI_FIRMWARE_MAJOR_REVISION <<16) | (EFI_FIRMWARE_MINOR_REVISION)) +// +// Basic EFI types of various widths. +// + +#include +#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine */ +#define ACPI_USE_SYSTEM_INTTYPES 1 /* Tell ACPI we've defined types */ + +typedef uint64_t UINT64; +typedef int64_t INT64; +typedef uint32_t UINT32; +typedef int32_t INT32; +typedef uint16_t UINT16; +typedef int16_t INT16; +typedef uint8_t UINT8; +typedef int8_t INT8; + +#ifdef __LP64__ +typedef int64_t INTN; +typedef uint64_t UINTN; +#else +typedef int32_t INTN; +typedef uint32_t UINTN; +#endif + +#endif + +#undef VOID +#define VOID void + + #include "efibind.h" #include "efidef.h" #include "efidevp.h" diff --git a/stand/efi/include/i386/efibind.h b/stand/efi/include/i386/efibind.h index 6123a98d1b9b..e4cbceae8216 100644 --- a/stand/efi/include/i386/efibind.h +++ b/stand/efi/include/i386/efibind.h @@ -26,89 +26,6 @@ Revision History #pragma pack() - -#ifdef __FreeBSD__ -#include -#else -// -// Basic int types of various widths -// - -#if (__STDC_VERSION__ < 199901L ) - - // No ANSI C 1999/2000 stdint.h integer width declarations - - #ifdef _MSC_EXTENSIONS - - // Use Microsoft C compiler integer width declarations - - typedef unsigned __int64 uint64_t; - typedef __int64 int64_t; - typedef unsigned __int32 uint32_t; - typedef __int32 int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - #ifdef UNIX_LP64 - - // Use LP64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long uint64_t; - typedef long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - - // Assume P64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long long uint64_t; - typedef long long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #endif - #endif -#endif -#endif /* __FreeBSD__ */ - -// -// Basic EFI types of various widths -// - -#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine, use those */ -#define ACPI_USE_SYSTEM_INTTYPES 1 /* Tell ACPI we've defined types */ - -typedef uint64_t UINT64; -typedef int64_t INT64; - -#ifndef _BASETSD_H_ - typedef uint32_t UINT32; - typedef int32_t INT32; -#endif - -typedef uint16_t UINT16; -typedef int16_t INT16; -typedef uint8_t UINT8; -typedef int8_t INT8; - -#endif - -#undef VOID -#define VOID void - - -typedef int32_t INTN; -typedef uint32_t UINTN; - #ifdef EFI_NT_EMULATOR #define POST_CODE(_Data) #else diff --git a/stand/efi/include/riscv/efibind.h b/stand/efi/include/riscv/efibind.h index 4fdfd9f21386..417da1b4d4ff 100644 --- a/stand/efi/include/riscv/efibind.h +++ b/stand/efi/include/riscv/efibind.h @@ -26,82 +26,6 @@ Revision History #pragma pack() - -#ifdef __FreeBSD__ -#include -#else -// -// Basic int types of various widths -// - -#if (__STDC_VERSION__ < 199901L ) - - // No ANSI C 1999/2000 stdint.h integer width declarations - - #ifdef _MSC_EXTENSIONS - - // Use Microsoft C compiler integer width declarations - - typedef unsigned __int64 uint64_t; - typedef __int64 int64_t; - typedef unsigned __int32 uint32_t; - typedef __int32 int32_t; - typedef unsigned __int16 uint16_t; - typedef __int16 int16_t; - typedef unsigned __int8 uint8_t; - typedef __int8 int8_t; - #else - #ifdef UNIX_LP64 - - // Use LP64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long uint64_t; - typedef long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #else - - // Assume P64 programming model from C_FLAGS for integer width declarations - - typedef unsigned long long uint64_t; - typedef long long int64_t; - typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned short uint16_t; - typedef short int16_t; - typedef unsigned char uint8_t; - typedef char int8_t; - #endif - #endif -#endif -#endif /* __FreeBSD__ */ - -// -// Basic EFI types of various widths -// - - -typedef uint64_t UINT64; -typedef int64_t INT64; -typedef uint32_t UINT32; -typedef int32_t INT32; -typedef uint16_t UINT16; -typedef int16_t INT16; -typedef uint8_t UINT8; -typedef int8_t INT8; - - -#undef VOID -#define VOID void - - -typedef int64_t INTN; -typedef uint64_t UINTN; - //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ // BugBug: Code to debug // diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 9b691ce9ae98..4100c0680b7f 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -60,7 +60,6 @@ #include "efizfs.h" #include "framebuffer.h" -#define ACPI_USE_SYSTEM_INTTYPES 1 #include "platform/acfreebsd.h" #include "acconfig.h" #define ACPI_SYSTEM_XFACE From nobody Tue Apr 16 02:34:44 2024 X-Original-To: dev-commits-src-branches@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 4VJSmj3gS1z5HZbm; Tue, 16 Apr 2024 02:34:45 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmj0Z1Vz4Hm2; Tue, 16 Apr 2024 02:34:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234885; 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=Erv/PdBnEyzRFT81uUiIJuGuBQpGCreP5yu94lUPXK4=; b=guYZ275CwIyOLljT81WHT0tcOs1uVfsUDiabOXgPrFPu171MvXptwhaP/O7SY94YPQcqiy tgg8z3gbqYtdL346OtvwNvatwRIIifVEJcxi95NHLjMeebM5g3E0OvsRRwrkSAmoGWabbu XnNZS6334PJX0B/sbf6aIb0ISnVGRVJaZxJWSrrWi/9ZsKp2bwZzzgqcXENMaS4lzxWGc4 vb/QfAci77qsgZ+rZcusZbGKIEfrDApGdRJ8UnZPfTcAlKd62+N/XYrjrmmuhxlbLad3Pi 7VGdOXFtVWATvRdtQTakrk7aPSV1rbF3YAthGnMNxdatb4O+oTP9TMmnDATiDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234885; a=rsa-sha256; cv=none; b=CNaTj/fcbJsxaUw0YeTdfl6mjoIHT9H+hsN829BmVBwBviZVEDz6wmkMQCYKD6J2/d9qFm 3aus4xZJM+BikQnU8KIWO07patY/6oI7cvkMSm+h64cQdI41XLilkRIySeeRIk9Ad6HEiC Qg1coxjlPYOFsTOqnca5+WUdwHoz866Pu+1DEp71gWPxAmhhEvnXnw195vtXlR6R+19Rc1 tWsXL0rK3m06EK/cmgIvqsNhS1rk69pQxp0KrC6okqzeRi/wlCSgSyXN/EdBDC4t984obY 6Wb9loQazqByov6DHCwnSZpK5JmfllwSolnD4FpwgkciCq6MrWVJFpkFfLTHDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234885; 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=Erv/PdBnEyzRFT81uUiIJuGuBQpGCreP5yu94lUPXK4=; b=E5oFoa8DIuCO1pBrTPBjsSWj43BN2QBtET3r8SXOl7Kywl1jnuqf43e3F8vq9nWPIl1cqq DICcNxrjVy8T7B4pEHULX5iSJylTXVvvg3LcYB1h15KBgW+FCwFHBEZhKuCOJbToBsXVk0 SbY+YkHKH4EXwFRAirP5SKxvR4AEbjYGMWLnND9oWtWlaE1T1ZgZCLT4NivhV8ptqC9qEQ iGWE+7hOGkFOGarUdQoGy4QSj2YzW91SgprtwkF3msye8A9En6SjAPcWrrHunvTDuz/NFv GjnhF6hnGLKUe4zqST0r+G1LDzgR10PAU0lldIog952cMPEFuhAAWtKWBh3RKA== 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 4VJSmh73XczQ64; Tue, 16 Apr 2024 02:34:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2Yi3U037623; Tue, 16 Apr 2024 02:34:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YiKV037620; Tue, 16 Apr 2024 02:34:44 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:44 GMT Message-Id: <202404160234.43G2YiKV037620@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 82b2c7ac7d41 - stable/14 - loader.efi.8: Fix a typo List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 82b2c7ac7d4127bd16716ca9fbe6b2bee76eb7d1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=82b2c7ac7d4127bd16716ca9fbe6b2bee76eb7d1 commit 82b2c7ac7d4127bd16716ca9fbe6b2bee76eb7d1 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-11-22 12:24:41 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:04 +0000 loader.efi.8: Fix a typo MFC after: 3 days Sponsored by: Klara, Inc. (cherry picked from commit 8ec79e8ae07d34a371eeb09329ad32993aecd906) --- stand/man/loader.efi.8 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/man/loader.efi.8 b/stand/man/loader.efi.8 index 827c4ced7f2e..cc24b25594f9 100644 --- a/stand/man/loader.efi.8 +++ b/stand/man/loader.efi.8 @@ -30,7 +30,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 4, 2022 +.Dd November 22, 2023 .Dt LOADER.EFI 8 .Os .Sh NAME @@ -352,7 +352,7 @@ The default location for the ESP mount point is documented in .Xr hier 7 . .Sh EXAMPLES .Ss Updating loader.efi on the ESP -The following examples shows how to install a new +The following example shows how to install a new .Nm on the ESP. .Pp From nobody Tue Apr 16 02:34:46 2024 X-Original-To: dev-commits-src-branches@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 4VJSmk3FH4z5HZpl; Tue, 16 Apr 2024 02:34:46 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmk1FbVz4HmG; Tue, 16 Apr 2024 02:34:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234886; 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=V+0AOBnI+y1qOGFivfjFCRQxYWy4L/8COSJBtZLfQMA=; b=s+j5zQwvRGcaGkNgQOcMMNMYeavfkoYvVGCO2xFLeqP8Erh6ZtGgtWvzrVpBmKuw3vFepf PK68X5jvlU+h+MliZ/OM4BcUxfyVx+2K9YRlZwSdVhBGUWpd2lC2j+iRo5E1QJPTSNguk9 HuiCwixK3XVA9z2EoqmtjYr7GI5XpvFds7TxxDF8/du+4H450H+8lh6Q7JD8Cm1KVqAE1G kJF1yyoMT4DDhLojrdCKTMqHhhlD6y+EuuE6wRFSu1jPlPa16MBNVVNdjp21VU1wD+bDjY px82B+8QWKQwFzx9uTRsCW2siJnJoh4ZW41rR+wfLS81vPYNcAwdgJ3WuCu/Ug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234886; a=rsa-sha256; cv=none; b=IG8AVFvSnG2JIHxU7OQpBSJ22FBdSB7cHhRVybrKfKr5C22gWTPBBzg+CMPJdO793mhFp3 xiAA4v/6tvytyxaEzlV/AcxLf2f8GlNZW25L6Qa4+oQnVYz2kHYzyHhELF2tJwdfI6O+t+ o0v2OjPoaJ0cdmOyCJZsuEMjkD5YWME70bLv5+FkN4/QUEF8FP+LfDb5zYywisGAjQaQq6 YkfheEYYkW4YMTNDRweqO6801nO04S2nTEHnGxQ/taCJYwrJA+YsKa9OkHhMP3hpDSExZv oxbdJXVcSH4pjsK0xM1fb6BofJztqcnYN8carQOBCUt5uyxTmYYwCfFlis93dA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234886; 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=V+0AOBnI+y1qOGFivfjFCRQxYWy4L/8COSJBtZLfQMA=; b=EfK0fzxXX2sVrbZG3HN8vziZL7IXq3Ch74XR+lDFASlzU3y0hv8IvLs9456F78gUP+N5d5 xL5STLGyEgxXeWHJlTLEIcdfTH27n31DOu2c2k6BVE40ZLAZMm4E4JzqyaZWON6HtEU5u3 /JOoasU23Ago4GBQh0kDu819fS+BwD7jVUeKY6CGXIVgLHo6DIHbqjxLoy3D+mvXhFA6bV V6decnmI54vrIbMGQOanojVqp0968fy996Qewo8mjbp85uCC03HyRZtBF9fbcgkNhhNhPZ DE38SUjZMEt/qT7NeGjFYWIhyNqHTp+iZ/gJfEYkbk4/jNx0UOI2ohge3jj51g== 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 4VJSmk0skbzQ3m; Tue, 16 Apr 2024 02:34:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YkP3037666; Tue, 16 Apr 2024 02:34:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YkiI037663; Tue, 16 Apr 2024 02:34:46 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:46 GMT Message-Id: <202404160234.43G2YkiI037663@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 5417db3a9739 - stable/14 - stand: Retire setting hw.eisa_slots. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5417db3a9739c47520cf3651caeb1e869bb49243 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5417db3a9739c47520cf3651caeb1e869bb49243 commit 5417db3a9739c47520cf3651caeb1e869bb49243 Author: Warner Losh AuthorDate: 2023-11-24 17:58:44 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 stand: Retire setting hw.eisa_slots. When the eisa code was removed in 2017, prior to the stable/12 branch, setting hw.eisa_slots became a nop. The oldest supported branch doesn't have eisa at all. The need to set it manually on boot disappeared largely by 2000... Sponsored by: Netflix (cherry picked from commit 21795c374aceb685dbdb1bd18c7a5c41c3cf0baf) --- stand/forth/menu-commands.4th | 2 -- stand/lua/core.lua | 2 -- stand/lua/core.lua.8 | 1 - 3 files changed, 5 deletions(-) diff --git a/stand/forth/menu-commands.4th b/stand/forth/menu-commands.4th index decf3fdf6fa4..8121272114d0 100644 --- a/stand/forth/menu-commands.4th +++ b/stand/forth/menu-commands.4th @@ -127,7 +127,6 @@ also menu-namespace also menu-command-helpers s" set hw.ata.ata_dma=0" evaluate s" set hw.ata.atapi_dma=0" evaluate s" set hw.ata.wc=0" evaluate - s" set hw.eisa_slots=0" evaluate s" set kern.eventtimer.periodic=1" evaluate s" set kern.geom.part.check_integrity=0" evaluate ; @@ -137,7 +136,6 @@ also menu-namespace also menu-command-helpers s" hw.ata.ata_dma" unsetenv s" hw.ata.atapi_dma" unsetenv s" hw.ata.wc" unsetenv - s" hw.eisa_slots" unsetenv s" kern.eventtimer.periodic" unsetenv s" kern.geom.part.check_integrity" unsetenv ; diff --git a/stand/lua/core.lua b/stand/lua/core.lua index e7ffdc091c0c..85896183d98f 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -177,7 +177,6 @@ function core.setSafeMode(safe_mode) loader.setenv("hw.ata.ata_dma", "0") loader.setenv("hw.ata.atapi_dma", "0") loader.setenv("hw.ata.wc", "0") - loader.setenv("hw.eisa_slots", "0") loader.setenv("kern.eventtimer.periodic", "1") loader.setenv("kern.geom.part.check_integrity", "0") else @@ -185,7 +184,6 @@ function core.setSafeMode(safe_mode) loader.unsetenv("hw.ata.ata_dma") loader.unsetenv("hw.ata.atapi_dma") loader.unsetenv("hw.ata.wc") - loader.unsetenv("hw.eisa_slots") loader.unsetenv("kern.eventtimer.periodic") loader.unsetenv("kern.geom.part.check_integrity") end diff --git a/stand/lua/core.lua.8 b/stand/lua/core.lua.8 index cb52ae9f1b30..b9af93758818 100644 --- a/stand/lua/core.lua.8 +++ b/stand/lua/core.lua.8 @@ -127,7 +127,6 @@ Sets or unsets .Ev hw.ata.ata_dma , .Ev hw.ata.atapi_dma , .Ev hw.ata.wc , -.Ev hw.eisa_slots , .Ev kern.eventtimer.periodic , and .Ev kern.geom.part.check_integrity . From nobody Tue Apr 16 02:34:47 2024 X-Original-To: dev-commits-src-branches@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 4VJSml3KTcz5Hb49; Tue, 16 Apr 2024 02:34:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSml236Dz4Hf3; Tue, 16 Apr 2024 02:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234887; 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=I8L4psh7KrtRO2qE2xxdSOQHb/lYxF1+mVUPwrZSuQI=; b=ZXKaxCy4OsKq3mydLNRrQBRu9fQyse9F+YtYPL50jdIIxFrJDtFTrQ8WM935Ab3uJluUoA a1WZBrWVNWzAfNFEUdsnvMTAMShD5rwxSyL6N5vx+1LnqXLmBjP1B0LrP+g6sHL5FCuurl L3oRwZ6WDbg0DAMzPVA4XKgeI8QSwdERObeduEV5X1I6DcNcKXI/tAaZURTwaUmBDNNtqJ N0PJYVM6N9ijX/T36F2Nq0LejGo93T5fJiluvKJ5y/pgxT5RhnF4uAqh/sIB13boSposbb /dekPUeoTerlmDx1v4a7TeNj90jPMM7msePSgEFh8Xy3XewkWHkxNZMOf9kobw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234887; a=rsa-sha256; cv=none; b=atwU/2wuLeBFLrFukC1WtHEGFrZkH+w+FCDLexi8T8gM/MrBwrkfF27v60ISAz+Ep6eWAO WLPsqWffr40cag8mc6JqFPmc8hBrijYN5Vmn0yxietqIK5abRgz/ODVRAq8RgXTdC1p6dV SYCzU3FRl9HWARbrakdWHD1y3gifefy6KmF9PT+nRT8cZ7cpsz0GCtV/Bc9H8Ib7zD4dR+ SEGTlaLPH1cvtNUQpH1gLUtWBqxJWvEnsFmVmlyTuJ9zfeXMT9rYHcZxw9hQ2OKO4EYQ0L 5FW1VsrYhgWuJZPr36KflXcSavz4J5IOS5V+Exb525KxpNz3ezdX5qRhxCGzQg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234887; 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=I8L4psh7KrtRO2qE2xxdSOQHb/lYxF1+mVUPwrZSuQI=; b=E/sYgzTeibJwPkcM+N1/y+BYwwfWbbOcGm6Bejzna8Y+jZ1PDf5uUnAfiSWDZ1UfRYoal6 SAsH+r6QYo8INrlDdoCERU8jpnopRX4pKtuzpF9cWoSPx8IS8kvTEn0KPLQMg+rrQvCAjp 1+O7vH8gJpf8Jj84ovuxlN/r4SXEig2RqMmFsKHHoKlXzEYceX3swe6927I6BuTKTl/tWe yKC0PboLPZjiZ/r7DSKIh4QD6Nm54DWBR+fQviN6/JM0AkK8A0/vjgviiYsnOS6hA466jN HZJNhFOi76O0uAbrQo7kh7uUv2sJEpwC+bVtzQhhqTIAcEIT6QfkDypO1UXigQ== 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 4VJSml1c2szQDZ; Tue, 16 Apr 2024 02:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YlBt037714; Tue, 16 Apr 2024 02:34:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YlFe037711; Tue, 16 Apr 2024 02:34:47 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:47 GMT Message-Id: <202404160234.43G2YlFe037711@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 5029119797e1 - stable/14 - stand: Retire setting hw.ata.wc: it doesn't exist. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5029119797e1340636952d1a8e7b0defd7b2500b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5029119797e1340636952d1a8e7b0defd7b2500b commit 5029119797e1340636952d1a8e7b0defd7b2500b Author: Warner Losh AuthorDate: 2023-11-24 18:28:44 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 stand: Retire setting hw.ata.wc: it doesn't exist. hw.ata.wc was disconnected as part ot the 2013 cam-ification of ata. No need to continue setting it. It's been unused in FreeBSD 10.x and newer. Sponsored by: Netflix (cherry picked from commit 67d2bd974d34d918255307321107273562f11dde) --- stand/forth/menu-commands.4th | 2 -- stand/lua/core.lua | 2 -- stand/lua/core.lua.8 | 1 - 3 files changed, 5 deletions(-) diff --git a/stand/forth/menu-commands.4th b/stand/forth/menu-commands.4th index 8121272114d0..2c3d787c65e1 100644 --- a/stand/forth/menu-commands.4th +++ b/stand/forth/menu-commands.4th @@ -126,7 +126,6 @@ also menu-namespace also menu-command-helpers s" set kern.smp.disabled=1" evaluate s" set hw.ata.ata_dma=0" evaluate s" set hw.ata.atapi_dma=0" evaluate - s" set hw.ata.wc=0" evaluate s" set kern.eventtimer.periodic=1" evaluate s" set kern.geom.part.check_integrity=0" evaluate ; @@ -135,7 +134,6 @@ also menu-namespace also menu-command-helpers s" kern.smp.disabled" unsetenv s" hw.ata.ata_dma" unsetenv s" hw.ata.atapi_dma" unsetenv - s" hw.ata.wc" unsetenv s" kern.eventtimer.periodic" unsetenv s" kern.geom.part.check_integrity" unsetenv ; diff --git a/stand/lua/core.lua b/stand/lua/core.lua index 85896183d98f..65b91cd8f63e 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -176,14 +176,12 @@ function core.setSafeMode(safe_mode) loader.setenv("kern.smp.disabled", "1") loader.setenv("hw.ata.ata_dma", "0") loader.setenv("hw.ata.atapi_dma", "0") - loader.setenv("hw.ata.wc", "0") loader.setenv("kern.eventtimer.periodic", "1") loader.setenv("kern.geom.part.check_integrity", "0") else loader.unsetenv("kern.smp.disabled") loader.unsetenv("hw.ata.ata_dma") loader.unsetenv("hw.ata.atapi_dma") - loader.unsetenv("hw.ata.wc") loader.unsetenv("kern.eventtimer.periodic") loader.unsetenv("kern.geom.part.check_integrity") end diff --git a/stand/lua/core.lua.8 b/stand/lua/core.lua.8 index b9af93758818..e12f80671c00 100644 --- a/stand/lua/core.lua.8 +++ b/stand/lua/core.lua.8 @@ -126,7 +126,6 @@ Sets or unsets .Ev kern.smp.disabled , .Ev hw.ata.ata_dma , .Ev hw.ata.atapi_dma , -.Ev hw.ata.wc , .Ev kern.eventtimer.periodic , and .Ev kern.geom.part.check_integrity . From nobody Tue Apr 16 02:34:48 2024 X-Original-To: dev-commits-src-branches@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 4VJSmm5ZDCz5HZk3; Tue, 16 Apr 2024 02:34:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmm3vP0z4Hpb; Tue, 16 Apr 2024 02:34:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234888; 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=3zVfNr3ZbMRKAMcObN2LwZ8ggM9qAjl7BjjnhvZFCe0=; b=dg3KIXs3+myIKbQsrwKmqlR7Zb8yALps8A7+TCmzmc9HolSNzrM5N0q/Gf1EvNyhLWK8X1 MPrQSF0ATgcbpL3nm1qkdHYiuSEShMFf+Sp/mFsIVAlDpB+l3otdrHlsv6I2uDGFAUALyh Pb6nYCm3sOQkc9CUwUgYcKzBkJmdoFeG/NOqy1r/GXZ1PEBlbLY0bBMf/BUPM/GLAzdSBz kj2wcqS0CncoIJE26MQvD81VLlyIs7fu7Pj2q6YK4rab8yQK9W3Au1bWXuCfoDMe5V8yfo O0CINBVbt5TghAULPWSjaHTmtjilcLs86XvJR0Dtndj7V8e8fdfw2f4bsF8P5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234888; a=rsa-sha256; cv=none; b=HCzSWvErMbrjbJJZ5Ur1wq45VA1qwWFn6Nusiz+qR9J7dtjMkvb0m+hagIMy0Fhii32ViP +/4CeBKWwzlwz7xX4l/ktjHjSvNf2qM6SiDiWIEBJDfW3/ZF+zk/4bffag3oDptJuIRSYx HUeAQmcmzzPOuyk6dT9P6SzOG/jroNp/b1hJE31r5+1H7AUm/vm3B2yOl2ILs9anKlGMQ9 UFktIcDEwvGLPU2wkLYwPrU9iIrfVDRpGbI6RRv+BpYWqquiiJjVSS+9NXpCC0xvtFspkt YO/TEz0f7fsWIzDf4CjmbjSl0nN/72gRJJCcZYg5U3CW0U9+trKJMYmAKEJudw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234888; 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=3zVfNr3ZbMRKAMcObN2LwZ8ggM9qAjl7BjjnhvZFCe0=; b=elQwh5fxH/j8Kt0SkwwQdoEDsnLbdpQjKPvt0yFcp7VsBCUUVcWhszhPdcrYf5488l/Qeq 7SFG4TGJUTUobSDmNB2VpLQtoMaI9vfbqRjfmz56bsthHbYijzxPrCAuaYtAuzePzVIKmF kbZSzDSKvVatzkshP2WfosizSsmFRLdtXkeANdbDpO+j1t2gOHMxGhVfmczLIK47fthSLO GMCiXkppTguAcB82x84sUVQHB34IZ22UnW0bLSClZt+jXcVUctvjS85d5675LO5ZmUmrQ8 2fmm1K7rt0fL/B+dTOM4FgxuTlb1GOL2FUpjBp74fnD1fJlR5AfY8X26P79Dfg== 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 4VJSmm2f7mzPpl; Tue, 16 Apr 2024 02:34:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YmTc037756; Tue, 16 Apr 2024 02:34:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YmEM037753; Tue, 16 Apr 2024 02:34:48 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:48 GMT Message-Id: <202404160234.43G2YmEM037753@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: aa53b6dd49bd - stable/14 - stand: Remove ancient SCCS tags. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: aa53b6dd49bd7b4810e88d292feaa0e1fbcd678a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=aa53b6dd49bd7b4810e88d292feaa0e1fbcd678a commit aa53b6dd49bd7b4810e88d292feaa0e1fbcd678a Author: Warner Losh AuthorDate: 2023-11-23 17:21:37 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 stand: Remove ancient SCCS tags. Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl script. Sponsored by: Netflix (cherry picked from commit 6e28a6bc2e83d56a5d2d5ee4f5da72d798de2d07) --- stand/common/newvers.sh | 2 -- stand/libsa/amd64/_setjmp.S | 3 --- stand/libsa/arp.c | 2 -- stand/libsa/bootp.c | 2 -- stand/libsa/close.c | 2 -- stand/libsa/dev.c | 2 -- stand/libsa/ether.c | 2 -- stand/libsa/fstat.c | 2 -- stand/libsa/geli/pwgets.c | 2 -- stand/libsa/getopt.c | 3 --- stand/libsa/gets.c | 2 -- stand/libsa/in_cksum.c | 2 -- stand/libsa/inet_ntoa.c | 3 --- stand/libsa/ioctl.c | 2 -- stand/libsa/lseek.c | 2 -- stand/libsa/net.c | 2 -- stand/libsa/nfsv2.h | 2 -- stand/libsa/nullfs.c | 2 -- stand/libsa/open.c | 2 -- stand/libsa/printf.c | 2 -- stand/libsa/random.c | 2 -- stand/libsa/rarp.c | 2 -- stand/libsa/read.c | 2 -- stand/libsa/rpc.c | 2 -- stand/libsa/rpcv2.h | 2 -- stand/libsa/saioctl.h | 2 -- stand/libsa/stand.h | 2 -- stand/libsa/stat.c | 2 -- stand/libsa/strcasecmp.c | 3 --- stand/libsa/strdup.c | 3 --- stand/libsa/twiddle.c | 2 -- stand/libsa/udp.c | 2 -- stand/libsa/write.c | 2 -- 33 files changed, 71 deletions(-) diff --git a/stand/common/newvers.sh b/stand/common/newvers.sh index 610999bf7ace..916fecb98334 100755 --- a/stand/common/newvers.sh +++ b/stand/common/newvers.sh @@ -28,8 +28,6 @@ # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. -# -# @(#)newvers.sh 8.1 (Berkeley) 4/20/94 tempfile=$(mktemp tmp.XXXXXX) || exit trap "rm -f $tempfile" EXIT INT TERM diff --git a/stand/libsa/amd64/_setjmp.S b/stand/libsa/amd64/_setjmp.S index 077f080faa7e..62683be11946 100644 --- a/stand/libsa/amd64/_setjmp.S +++ b/stand/libsa/amd64/_setjmp.S @@ -30,9 +30,6 @@ * SUCH DAMAGE. */ -#if defined(LIBC_SCCS) && !defined(lint) - .asciz "@(#)_setjmp.s 5.1 (Berkeley) 4/23/90" -#endif /* LIBC_SCCS and not lint */ #include /* * C library -- _setjmp, _longjmp diff --git a/stand/libsa/arp.c b/stand/libsa/arp.c index caca08d4cc89..e461d9322e7e 100644 --- a/stand/libsa/arp.c +++ b/stand/libsa/arp.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: arp.c,v 1.5 93/07/15 05:52:26 leres Exp (LBL) */ #include diff --git a/stand/libsa/bootp.c b/stand/libsa/bootp.c index 2dc823027234..fea516d4b97d 100644 --- a/stand/libsa/bootp.c +++ b/stand/libsa/bootp.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: bootp.c,v 1.4 93/09/11 03:13:51 leres Exp (LBL) */ #include diff --git a/stand/libsa/close.c b/stand/libsa/close.c index 523578996483..0fb1c136664d 100644 --- a/stand/libsa/close.c +++ b/stand/libsa/close.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)close.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. diff --git a/stand/libsa/dev.c b/stand/libsa/dev.c index e83af5d2e6a0..ea81e0f92115 100644 --- a/stand/libsa/dev.c +++ b/stand/libsa/dev.c @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)dev.c 8.1 (Berkeley) 6/11/93 */ #include diff --git a/stand/libsa/ether.c b/stand/libsa/ether.c index 304983295eb2..e9dae723e99d 100644 --- a/stand/libsa/ether.c +++ b/stand/libsa/ether.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: net.c,v 1.9 93/08/06 19:32:15 leres Exp (LBL) */ #include diff --git a/stand/libsa/fstat.c b/stand/libsa/fstat.c index a0bdd8fe8605..b1e99a075880 100644 --- a/stand/libsa/fstat.c +++ b/stand/libsa/fstat.c @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)stat.c 8.1 (Berkeley) 6/11/93 */ #include diff --git a/stand/libsa/geli/pwgets.c b/stand/libsa/geli/pwgets.c index 5b3c85861786..f7eece5d0d5c 100644 --- a/stand/libsa/geli/pwgets.c +++ b/stand/libsa/geli/pwgets.c @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)gets.c 8.1 (Berkeley) 6/11/93 */ #include diff --git a/stand/libsa/getopt.c b/stand/libsa/getopt.c index 22c8b2b7fe0a..0e49664f8721 100644 --- a/stand/libsa/getopt.c +++ b/stand/libsa/getopt.c @@ -28,9 +28,6 @@ */ #include -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)getopt.c 8.3 (Berkeley) 4/27/95"; -#endif /* LIBC_SCCS and not lint */ #include "stand.h" #include diff --git a/stand/libsa/gets.c b/stand/libsa/gets.c index 04775f6f5280..6d5968f1d6c2 100644 --- a/stand/libsa/gets.c +++ b/stand/libsa/gets.c @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)gets.c 8.1 (Berkeley) 6/11/93 */ #include diff --git a/stand/libsa/in_cksum.c b/stand/libsa/in_cksum.c index cdc1110fa4a1..f4d5a91b1b5a 100644 --- a/stand/libsa/in_cksum.c +++ b/stand/libsa/in_cksum.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: in_cksum.c,v 1.1 92/09/11 01:15:55 leres Exp (LBL) */ #include diff --git a/stand/libsa/inet_ntoa.c b/stand/libsa/inet_ntoa.c index 6c32c020557c..e696d4c67ffe 100644 --- a/stand/libsa/inet_ntoa.c +++ b/stand/libsa/inet_ntoa.c @@ -28,9 +28,6 @@ */ #include -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)inet_ntoa.c 8.1 (Berkeley) 6/4/93"; -#endif /* LIBC_SCCS and not lint */ #include #include diff --git a/stand/libsa/ioctl.c b/stand/libsa/ioctl.c index 26d817dbaefd..366c97309c1b 100644 --- a/stand/libsa/ioctl.c +++ b/stand/libsa/ioctl.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)ioctl.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. diff --git a/stand/libsa/lseek.c b/stand/libsa/lseek.c index eb063394a144..73448d4a4c03 100644 --- a/stand/libsa/lseek.c +++ b/stand/libsa/lseek.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)lseek.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. diff --git a/stand/libsa/net.c b/stand/libsa/net.c index 5125f89aaa9f..20731d90b6aa 100644 --- a/stand/libsa/net.c +++ b/stand/libsa/net.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: net.c,v 1.9 93/08/06 19:32:15 leres Exp (LBL) */ #include diff --git a/stand/libsa/nfsv2.h b/stand/libsa/nfsv2.h index 165517760eca..bcae55b06b1d 100644 --- a/stand/libsa/nfsv2.h +++ b/stand/libsa/nfsv2.h @@ -30,8 +30,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)nfsv2.h 8.1 (Berkeley) 6/10/93 */ /* diff --git a/stand/libsa/nullfs.c b/stand/libsa/nullfs.c index 157c8a3178ec..bb11286a4579 100644 --- a/stand/libsa/nullfs.c +++ b/stand/libsa/nullfs.c @@ -30,8 +30,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)open.c 8.1 (Berkeley) 6/11/93 * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University diff --git a/stand/libsa/open.c b/stand/libsa/open.c index fc70e2c3904a..66866dd5c0f2 100644 --- a/stand/libsa/open.c +++ b/stand/libsa/open.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)open.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. diff --git a/stand/libsa/printf.c b/stand/libsa/printf.c index 4d4696828988..313cf79fdffa 100644 --- a/stand/libsa/printf.c +++ b/stand/libsa/printf.c @@ -30,8 +30,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)subr_prf.c 8.3 (Berkeley) 1/21/94 */ #include diff --git a/stand/libsa/random.c b/stand/libsa/random.c index 8570c9d514c1..a6d903ed2e02 100644 --- a/stand/libsa/random.c +++ b/stand/libsa/random.c @@ -25,8 +25,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)random.c 8.1 (Berkeley) 6/10/93 */ #include diff --git a/stand/libsa/rarp.c b/stand/libsa/rarp.c index 38a936a8833e..9c5daad5cd42 100644 --- a/stand/libsa/rarp.c +++ b/stand/libsa/rarp.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: arp.c,v 1.5 93/07/15 05:52:26 leres Exp (LBL) */ #include diff --git a/stand/libsa/read.c b/stand/libsa/read.c index 3f928f8e6916..df150f8f0fbe 100644 --- a/stand/libsa/read.c +++ b/stand/libsa/read.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)read.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. diff --git a/stand/libsa/rpc.c b/stand/libsa/rpc.c index c1fecd422610..108601f6629e 100644 --- a/stand/libsa/rpc.c +++ b/stand/libsa/rpc.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: rpc.c,v 1.12 93/09/28 08:31:56 leres Exp (LBL) */ #include diff --git a/stand/libsa/rpcv2.h b/stand/libsa/rpcv2.h index fb6df3595bb7..4973b3918110 100644 --- a/stand/libsa/rpcv2.h +++ b/stand/libsa/rpcv2.h @@ -30,8 +30,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)rpcv2.h 8.1 (Berkeley) 6/10/93 */ /* diff --git a/stand/libsa/saioctl.h b/stand/libsa/saioctl.h index 281527aa4fcf..2ad35443e367 100644 --- a/stand/libsa/saioctl.h +++ b/stand/libsa/saioctl.h @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)saioctl.h 8.1 (Berkeley) 6/11/93 */ /* ioctl's -- for disks just now */ diff --git a/stand/libsa/stand.h b/stand/libsa/stand.h index e4e7c76fea7a..f500a8f47847 100644 --- a/stand/libsa/stand.h +++ b/stand/libsa/stand.h @@ -52,8 +52,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)stand.h 8.1 (Berkeley) 6/11/93 */ #ifndef STAND_H diff --git a/stand/libsa/stat.c b/stand/libsa/stat.c index fb79723ad03f..50065db6858b 100644 --- a/stand/libsa/stat.c +++ b/stand/libsa/stat.c @@ -27,8 +27,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)stat.c 8.1 (Berkeley) 6/11/93 */ #include diff --git a/stand/libsa/strcasecmp.c b/stand/libsa/strcasecmp.c index 6c149e1fa5da..9a4ddbcf9cb3 100644 --- a/stand/libsa/strcasecmp.c +++ b/stand/libsa/strcasecmp.c @@ -32,9 +32,6 @@ #include #include "stand.h" -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)strcasecmp.c 8.1 (Berkeley) 6/4/93"; -#endif /* LIBC_SCCS and not lint */ int strcasecmp(const char *s1, const char *s2) diff --git a/stand/libsa/strdup.c b/stand/libsa/strdup.c index f256bb95afff..f4506f424c2f 100644 --- a/stand/libsa/strdup.c +++ b/stand/libsa/strdup.c @@ -28,9 +28,6 @@ */ #include -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)strdup.c 8.1 (Berkeley) 6/4/93"; -#endif /* LIBC_SCCS and not lint */ #include "stand.h" #include diff --git a/stand/libsa/twiddle.c b/stand/libsa/twiddle.c index 682e66424cf6..43cdca25a367 100644 --- a/stand/libsa/twiddle.c +++ b/stand/libsa/twiddle.c @@ -30,8 +30,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#)subr_prf.c 8.3 (Berkeley) 1/21/94 */ #include diff --git a/stand/libsa/udp.c b/stand/libsa/udp.c index ae7989c17451..7a5942bbef95 100644 --- a/stand/libsa/udp.c +++ b/stand/libsa/udp.c @@ -31,8 +31,6 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - * - * @(#) Header: net.c,v 1.9 93/08/06 19:32:15 leres Exp (LBL) */ #include diff --git a/stand/libsa/write.c b/stand/libsa/write.c index 2827f986974f..16a6fc7eaa60 100644 --- a/stand/libsa/write.c +++ b/stand/libsa/write.c @@ -31,8 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)write.c 8.1 (Berkeley) 6/11/93 - * * * Copyright (c) 1989, 1990, 1991 Carnegie Mellon University * All Rights Reserved. From nobody Tue Apr 16 02:34:49 2024 X-Original-To: dev-commits-src-branches@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 4VJSmn6bB5z5Hb63; Tue, 16 Apr 2024 02:34:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmn4MKQz4HhJ; Tue, 16 Apr 2024 02:34:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234889; 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=dyaeFYGKu1FNHnI28lUjiyVTTdDkumR+4Ot8ziJaZGU=; b=dTT+trwqy7sS1CwgGFIsWBtvtjq/9JjOiZMS3DDYOWLjIl/NXLv59x5P+hs453ccVrrBhS mkQmD9icdQFBRQP4xhEMbWAwSodEQtFrt4ne8Nl5xOdPT1jScWLxEhIlKLzVNvkTfu+Zlr nsSIGkgZBiozojN58C5BzcdQ0NvFjiXrTwEuC6JJXZdsP0e7/pNl4J1PV3CzkL5E2oDyLS EOG1JSU4sy5cP0SB8uj/Hy8wUDWhiCjURwLyEuD5FKFVaJ2Ok546XcK+jBef2WQIA8mlqH qeQrpxXGTONmiJoNBqkrfqSuBhEs0ajvClKkOtK8bHxWSbJlX6wwXTAgLcZx8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234889; a=rsa-sha256; cv=none; b=nDOqGf4E2c6FmYw4HhJPBHRdyJqLbK935iHp3WwyBGhJXHSL3Ieiyq3Z8tfkS95GEZPyaK wK2gd8KJ4LHCydEOzC91V8GRI6Txe2fEgq6EE9pEhvELcow2Pbwvek+rYhebOoYRzO+2CX 4si4F7KZvju3TvkHKLi2WQH7viE2HjhFFuolAYP+lsaE5wyvDDX3LwgvLanibgi7f1dIqd WdTf0vmvSf0veXO8zLRNtjm5vwuptvFAgTpJ8rzV5R4rLNrejzD29dEdcSvS9tK7cejGrf i/IwZ/rX3FAMgIYcbyESVxoMNPZI6nJDtXw/ZjJFaFVOu2v1/ZRRA4KPZ6xo5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234889; 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=dyaeFYGKu1FNHnI28lUjiyVTTdDkumR+4Ot8ziJaZGU=; b=PlMEj9M5+XSP2iPHTTYP8eMd7TUJVetL8VvqEFwrKCN7LJyAdLQEjoQq8hT/QVRoMxe7Bp PKHPhPizXZgCCEEuUH7KZIjLWin6aBQNs2y+TEHYJhZzHzrCC1oeBale/U8tpJ2Ouu9ghP n78mW2qXhf3z43gjHQk721bIErwZTo7HxD7QPhjfQdbGGeisCbfcPaWrHT3CdTVKFBd3vy rWNl0ok++AtaHA+YDbpbwiZUNGxm5dbJeifWDwLNKnhn20GkrNuuLELtEV5+qBjJau2ZF0 6KsUfLyfGOpc1mmVrsBKkdwJE52l7LyL6um2S2SnykLS20j/Sut01T7q8uHFLA== 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 4VJSmn3WKvzQDb; Tue, 16 Apr 2024 02:34:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2Yn1V037807; Tue, 16 Apr 2024 02:34:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YnlT037804; Tue, 16 Apr 2024 02:34:49 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:49 GMT Message-Id: <202404160234.43G2YnlT037804@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 8b9bc8218545 - stable/14 - stand: Automated cleanup of cdefs and other formatting List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8b9bc82185454b66fb9d3fc4fd8d8da11a5f426e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=8b9bc82185454b66fb9d3fc4fd8d8da11a5f426e commit 8b9bc82185454b66fb9d3fc4fd8d8da11a5f426e Author: Warner Losh AuthorDate: 2023-11-24 20:12:57 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 stand: Automated cleanup of cdefs and other formatting Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+.*\n/ Remove /\n+#include\s+.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+\n#include\s+/ Remove /\n+#include\s+\n#include\s+/ Remove /\n+#include\s+\n#include\s+/ Sponsored by: Netflix (cherry picked from commit 7c43148a974877188a930e4078a164f83da8e652) --- stand/arm64/libarm64/cache.c | 1 - stand/common/bcache.c | 1 - stand/common/console.c | 1 - stand/common/gfx_fb.c | 1 - stand/common/install.c | 1 - stand/common/interp_forth.c | 1 - stand/common/load_elf.c | 1 - stand/common/load_elf_obj.c | 1 - stand/common/ls.c | 1 - stand/common/reloc_elf.c | 1 - stand/common/self_reloc.c | 1 - stand/common/tslog.c | 1 - stand/efi/boot1/boot1.c | 1 - stand/efi/boot1/proto.c | 1 - stand/efi/boot1/ufs_module.c | 2 +- stand/efi/boot1/zfs_module.c | 2 +- stand/efi/fdt/efi_fdt.c | 1 - stand/efi/gptboot/proto.c | 1 - stand/efi/libefi/efi_console.c | 1 - stand/efi/libefi/efichar.c | 1 - stand/efi/libefi/efihttp.c | 1 - stand/efi/libefi/efinet.c | 1 - stand/efi/libefi/efizfs.c | 1 - stand/efi/loader/arch/arm/exec.c | 1 - stand/efi/loader/arch/riscv/exec.c | 1 - stand/efi/loader/copy.c | 1 - stand/i386/boot0/boot0.S | 7 ------- stand/i386/boot2/boot2.c | 1 - stand/i386/common/cons.c | 1 - stand/i386/common/drv.c | 1 - stand/i386/gptboot/gptboot.c | 1 - stand/i386/isoboot/isoboot.c | 1 - stand/i386/libi386/elf32_freebsd.c | 1 - stand/i386/libi386/multiboot.c | 1 - stand/kboot/hostcons.c | 1 - stand/kboot/hostdisk.c | 1 - stand/kboot/kbootfdt.c | 1 - stand/liblua/lutils.c | 1 - stand/libofw/ofw_console.c | 1 - stand/libofw/ofw_memory.c | 1 - stand/libofw/ofw_net.c | 1 - stand/libofw/openfirm.h | 1 - stand/libsa/__main.c | 1 - stand/libsa/arp.c | 1 - stand/libsa/bcd.c | 1 - stand/libsa/cd9660read.c | 1 - stand/libsa/dev.c | 1 - stand/libsa/ether.c | 1 - stand/libsa/globals.c | 1 - stand/libsa/gpt.c | 1 - stand/libsa/in_cksum.c | 1 - stand/libsa/ip.c | 1 - stand/libsa/net.c | 1 - stand/libsa/netif.c | 1 - stand/libsa/nfs.c | 1 - stand/libsa/preload.c | 1 - stand/libsa/random.c | 1 - stand/libsa/rarp.c | 1 - stand/libsa/read.c | 1 - stand/libsa/readdir.c | 1 - stand/libsa/tslog.c | 1 - stand/libsa/twiddle.c | 1 - stand/libsa/udp.c | 1 - stand/libsa/write.c | 1 - stand/libsa/zalloc.c | 1 - stand/libsa/zfs/nvlist.c | 1 - stand/powerpc/boot1.chrp/boot1.c | 1 - stand/powerpc/ofw/elf_freebsd.c | 1 - stand/uboot/copy.c | 1 - stand/uboot/elf_freebsd.c | 1 - stand/uboot/glue.c | 1 - stand/uboot/main.c | 1 - stand/uboot/net.c | 1 - stand/uboot/uboot_disk.c | 1 - stand/uboot/uboot_fdt.c | 1 - stand/userboot/userboot/elf32_freebsd.c | 1 - 76 files changed, 2 insertions(+), 82 deletions(-) diff --git a/stand/arm64/libarm64/cache.c b/stand/arm64/libarm64/cache.c index 291b55f3b250..7b74f584ffe3 100644 --- a/stand/arm64/libarm64/cache.c +++ b/stand/arm64/libarm64/cache.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/common/bcache.c b/stand/common/bcache.c index 2b4603525740..f4805cbaa715 100644 --- a/stand/common/bcache.c +++ b/stand/common/bcache.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include /* * Simple hashed block cache diff --git a/stand/common/console.c b/stand/common/console.c index d9d075ef7bde..82cb552b4ef2 100644 --- a/stand/common/console.c +++ b/stand/common/console.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/gfx_fb.c b/stand/common/gfx_fb.c index 27ac66f259b1..c10d227a5fc8 100644 --- a/stand/common/gfx_fb.c +++ b/stand/common/gfx_fb.c @@ -82,7 +82,6 @@ * from VGA colors to console colors, while we are reading RGB data. */ -#include #include #include #include diff --git a/stand/common/install.c b/stand/common/install.c index 418799822e4e..b827b1fe9da2 100644 --- a/stand/common/install.c +++ b/stand/common/install.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/interp_forth.c b/stand/common/interp_forth.c index 0320e081d406..854addb22d5c 100644 --- a/stand/common/interp_forth.c +++ b/stand/common/interp_forth.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include /* to pick up __FreeBSD_version */ #include #include diff --git a/stand/common/load_elf.c b/stand/common/load_elf.c index bd9ab9e7ec5b..8877e5f8b7e0 100644 --- a/stand/common/load_elf.c +++ b/stand/common/load_elf.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/load_elf_obj.c b/stand/common/load_elf_obj.c index 6906e08f5f36..9ff1d238b8c8 100644 --- a/stand/common/load_elf_obj.c +++ b/stand/common/load_elf_obj.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/ls.c b/stand/common/ls.c index daeecfa488da..0cf57f7e281c 100644 --- a/stand/common/ls.c +++ b/stand/common/ls.c @@ -37,7 +37,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/reloc_elf.c b/stand/common/reloc_elf.c index e4b3e961a4f0..e68e59a303a1 100644 --- a/stand/common/reloc_elf.c +++ b/stand/common/reloc_elf.c @@ -27,7 +27,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/common/self_reloc.c b/stand/common/self_reloc.c index 39dad510b0b0..a4faeeace63f 100644 --- a/stand/common/self_reloc.c +++ b/stand/common/self_reloc.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/tslog.c b/stand/common/tslog.c index 6f27b9ebc316..8a17b0ca110c 100644 --- a/stand/common/tslog.c +++ b/stand/common/tslog.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/boot1/boot1.c b/stand/efi/boot1/boot1.c index 19627e870201..908baf400972 100644 --- a/stand/efi/boot1/boot1.c +++ b/stand/efi/boot1/boot1.c @@ -19,7 +19,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/efi/boot1/proto.c b/stand/efi/boot1/proto.c index cec4e2d1942c..6660d39a921b 100644 --- a/stand/efi/boot1/proto.c +++ b/stand/efi/boot1/proto.c @@ -19,7 +19,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/efi/boot1/ufs_module.c b/stand/efi/boot1/ufs_module.c index 6848dd79eec0..0bdd5c018b06 100644 --- a/stand/efi/boot1/ufs_module.c +++ b/stand/efi/boot1/ufs_module.c @@ -32,7 +32,7 @@ #include #include -#include + #include #include #include diff --git a/stand/efi/boot1/zfs_module.c b/stand/efi/boot1/zfs_module.c index 01b95e06e38f..16722b33f0b9 100644 --- a/stand/efi/boot1/zfs_module.c +++ b/stand/efi/boot1/zfs_module.c @@ -26,7 +26,7 @@ #include #include #include -#include + #include #include #include diff --git a/stand/efi/fdt/efi_fdt.c b/stand/efi/fdt/efi_fdt.c index 7010a272d9db..adf830e44182 100644 --- a/stand/efi/fdt/efi_fdt.c +++ b/stand/efi/fdt/efi_fdt.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/gptboot/proto.c b/stand/efi/gptboot/proto.c index 54a229db7bca..e2face6c23e5 100644 --- a/stand/efi/gptboot/proto.c +++ b/stand/efi/gptboot/proto.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/efi_console.c b/stand/efi/libefi/efi_console.c index 1758cd9d4d6d..4a3219ef3017 100644 --- a/stand/efi/libefi/efi_console.c +++ b/stand/efi/libefi/efi_console.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/efichar.c b/stand/efi/libefi/efichar.c index 0703c167de47..86642d325754 100644 --- a/stand/efi/libefi/efichar.c +++ b/stand/efi/libefi/efichar.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #ifdef _STANDALONE diff --git a/stand/efi/libefi/efihttp.c b/stand/efi/libefi/efihttp.c index 081b34336cb0..bcc0f7e4d79e 100644 --- a/stand/efi/libefi/efihttp.c +++ b/stand/efi/libefi/efihttp.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/efinet.c b/stand/efi/libefi/efinet.c index ede8b7297f17..62fc203c83b5 100644 --- a/stand/efi/libefi/efinet.c +++ b/stand/efi/libefi/efinet.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/efizfs.c b/stand/efi/libefi/efizfs.c index 83551596bb32..1c80f1ae26b9 100644 --- a/stand/efi/libefi/efizfs.c +++ b/stand/efi/libefi/efizfs.c @@ -25,7 +25,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/loader/arch/arm/exec.c b/stand/efi/loader/arch/arm/exec.c index 99ee498b1b65..85a8c26ade30 100644 --- a/stand/efi/loader/arch/arm/exec.c +++ b/stand/efi/loader/arch/arm/exec.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/loader/arch/riscv/exec.c b/stand/efi/loader/arch/riscv/exec.c index 686a42028608..3c40517ea968 100644 --- a/stand/efi/loader/arch/riscv/exec.c +++ b/stand/efi/loader/arch/riscv/exec.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/loader/copy.c b/stand/efi/loader/copy.c index 12f7273edacd..3f2d1c6c20b0 100644 --- a/stand/efi/loader/copy.c +++ b/stand/efi/loader/copy.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/i386/boot0/boot0.S b/stand/i386/boot0/boot0.S index 2b7e56c89167..80c7702840c1 100644 --- a/stand/i386/boot0/boot0.S +++ b/stand/i386/boot0/boot0.S @@ -16,18 +16,11 @@ */ /* build options: */ -#ifdef SIO /* use serial console on COM1. */ -#endif #ifdef PXE /* enable PXE/INT18 booting with F6 */ #define SAVE_MORE_MEMORY #endif -#ifdef CHECK_DRIVE /* make sure we boot from a HD. */ -#endif - -#ifdef ONLY_F_KEYS /* Only F1..F6, no digits on console */ -#endif #ifdef VOLUME_SERIAL /* support Volume serial number */ #define B0_BASE 0x1ae /* move the internal data area */ diff --git a/stand/i386/boot2/boot2.c b/stand/i386/boot2/boot2.c index da699b58b3b4..b886c70f3808 100644 --- a/stand/i386/boot2/boot2.c +++ b/stand/i386/boot2/boot2.c @@ -13,7 +13,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/i386/common/cons.c b/stand/i386/common/cons.c index c3a44499b5b4..1007d6965d95 100644 --- a/stand/i386/common/cons.c +++ b/stand/i386/common/cons.c @@ -13,7 +13,6 @@ * purpose. */ -#include #include #include diff --git a/stand/i386/common/drv.c b/stand/i386/common/drv.c index bc8927dc6c5e..394e1b1e8493 100644 --- a/stand/i386/common/drv.c +++ b/stand/i386/common/drv.c @@ -14,7 +14,6 @@ * purpose. */ -#include #include #include diff --git a/stand/i386/gptboot/gptboot.c b/stand/i386/gptboot/gptboot.c index 7cae837f9a56..949c00cdf544 100644 --- a/stand/i386/gptboot/gptboot.c +++ b/stand/i386/gptboot/gptboot.c @@ -13,7 +13,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/i386/isoboot/isoboot.c b/stand/i386/isoboot/isoboot.c index 4c3f7af8537a..4ffe83cdc9fe 100644 --- a/stand/i386/isoboot/isoboot.c +++ b/stand/i386/isoboot/isoboot.c @@ -13,7 +13,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/i386/libi386/elf32_freebsd.c b/stand/i386/libi386/elf32_freebsd.c index 185dc0c08d0f..ae5702e5e65f 100644 --- a/stand/i386/libi386/elf32_freebsd.c +++ b/stand/i386/libi386/elf32_freebsd.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/multiboot.c b/stand/i386/libi386/multiboot.c index 1ac5aefebf38..e11da0444fcd 100644 --- a/stand/i386/libi386/multiboot.c +++ b/stand/i386/libi386/multiboot.c @@ -34,7 +34,6 @@ * http://www.gnu.org/software/grub/manual/multiboot/multiboot.html */ -#include #include #include #include diff --git a/stand/kboot/hostcons.c b/stand/kboot/hostcons.c index 24e26af2ab19..114188adcff2 100644 --- a/stand/kboot/hostcons.c +++ b/stand/kboot/hostcons.c @@ -23,7 +23,6 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include "bootstrap.h" #include "host_syscall.h" diff --git a/stand/kboot/hostdisk.c b/stand/kboot/hostdisk.c index a659c6e63530..552ae68daced 100644 --- a/stand/kboot/hostdisk.c +++ b/stand/kboot/hostdisk.c @@ -24,7 +24,6 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/kboot/kbootfdt.c b/stand/kboot/kbootfdt.c index 34c475f0bb3a..70844820d345 100644 --- a/stand/kboot/kbootfdt.c +++ b/stand/kboot/kbootfdt.c @@ -23,7 +23,6 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 79a3dc9188c2..274d9a39da21 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -25,7 +25,6 @@ * */ -#include #include #include "lua.h" diff --git a/stand/libofw/ofw_console.c b/stand/libofw/ofw_console.c index 76942358e5c5..42ff045e8831 100644 --- a/stand/libofw/ofw_console.c +++ b/stand/libofw/ofw_console.c @@ -26,7 +26,6 @@ * the rights to redistribute these changes. */ -#include #include #include "bootstrap.h" diff --git a/stand/libofw/ofw_memory.c b/stand/libofw/ofw_memory.c index cd95827cba9a..67a4527e07b4 100644 --- a/stand/libofw/ofw_memory.c +++ b/stand/libofw/ofw_memory.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libofw/ofw_net.c b/stand/libofw/ofw_net.c index 15bac848a340..b4bcb7a00fe2 100644 --- a/stand/libofw/ofw_net.c +++ b/stand/libofw/ofw_net.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libofw/openfirm.h b/stand/libofw/openfirm.h index f41fc20cfa7d..35d10c320b57 100644 --- a/stand/libofw/openfirm.h +++ b/stand/libofw/openfirm.h @@ -60,7 +60,6 @@ * Prototypes for Open Firmware Interface Routines */ -#include #include typedef uint32_t ihandle_t; diff --git a/stand/libsa/__main.c b/stand/libsa/__main.c index f65f3a4105b4..2c057104476c 100644 --- a/stand/libsa/__main.c +++ b/stand/libsa/__main.c @@ -30,7 +30,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include void __main(void); diff --git a/stand/libsa/arp.c b/stand/libsa/arp.c index e461d9322e7e..eff8b9f332a3 100644 --- a/stand/libsa/arp.c +++ b/stand/libsa/arp.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libsa/bcd.c b/stand/libsa/bcd.c index 600d2bbff703..2f55bf9eda3c 100644 --- a/stand/libsa/bcd.c +++ b/stand/libsa/bcd.c @@ -3,7 +3,6 @@ * Cannot be copyrighted. */ -#include #include u_char const bcd2bin_data[] = { diff --git a/stand/libsa/cd9660read.c b/stand/libsa/cd9660read.c index 4a4501ada529..6062eb061506 100644 --- a/stand/libsa/cd9660read.c +++ b/stand/libsa/cd9660read.c @@ -32,7 +32,6 @@ /* Originally derived from libsa/cd9660.c: */ /* $NetBSD: cd9660.c,v 1.5 1997/06/26 19:11:33 drochner Exp $ */ -#include #include #include #include diff --git a/stand/libsa/dev.c b/stand/libsa/dev.c index ea81e0f92115..1edc843d508c 100644 --- a/stand/libsa/dev.c +++ b/stand/libsa/dev.c @@ -29,7 +29,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libsa/ether.c b/stand/libsa/ether.c index e9dae723e99d..08ef131e9e0e 100644 --- a/stand/libsa/ether.c +++ b/stand/libsa/ether.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libsa/globals.c b/stand/libsa/globals.c index ca8d190eeeef..2797045d4faf 100644 --- a/stand/libsa/globals.c +++ b/stand/libsa/globals.c @@ -7,7 +7,6 @@ * must be included extraneously. */ -#include #include #include #include diff --git a/stand/libsa/gpt.c b/stand/libsa/gpt.c index 14e9821eef8e..0ba3f0ee1985 100644 --- a/stand/libsa/gpt.c +++ b/stand/libsa/gpt.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libsa/in_cksum.c b/stand/libsa/in_cksum.c index f4d5a91b1b5a..15b2adb6080c 100644 --- a/stand/libsa/in_cksum.c +++ b/stand/libsa/in_cksum.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libsa/ip.c b/stand/libsa/ip.c index 753aeb1bae5e..2c2acf2eda16 100644 --- a/stand/libsa/ip.c +++ b/stand/libsa/ip.c @@ -37,7 +37,6 @@ * once we will implement the support for tcp. */ -#include #include #include #include diff --git a/stand/libsa/net.c b/stand/libsa/net.c index 20731d90b6aa..76b31c50d1e7 100644 --- a/stand/libsa/net.c +++ b/stand/libsa/net.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libsa/netif.c b/stand/libsa/netif.c index 30e1528bdfea..d8398b861af0 100644 --- a/stand/libsa/netif.c +++ b/stand/libsa/netif.c @@ -31,7 +31,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libsa/nfs.c b/stand/libsa/nfs.c index 1cc8fb009944..ee6af8a726c7 100644 --- a/stand/libsa/nfs.c +++ b/stand/libsa/nfs.c @@ -28,7 +28,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libsa/preload.c b/stand/libsa/preload.c index 9ca80e2c6ab2..499075c0efac 100644 --- a/stand/libsa/preload.c +++ b/stand/libsa/preload.c @@ -24,7 +24,6 @@ * */ -#include #include #include "stand.h" diff --git a/stand/libsa/random.c b/stand/libsa/random.c index a6d903ed2e02..d17d636e1597 100644 --- a/stand/libsa/random.c +++ b/stand/libsa/random.c @@ -27,7 +27,6 @@ * SUCH DAMAGE. */ -#include #include static long randseed = 1; diff --git a/stand/libsa/rarp.c b/stand/libsa/rarp.c index 9c5daad5cd42..20bbd56de6e6 100644 --- a/stand/libsa/rarp.c +++ b/stand/libsa/rarp.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/libsa/read.c b/stand/libsa/read.c index df150f8f0fbe..e610f8a0779c 100644 --- a/stand/libsa/read.c +++ b/stand/libsa/read.c @@ -58,7 +58,6 @@ * rights to redistribute these changes. */ -#include #include #include "stand.h" diff --git a/stand/libsa/readdir.c b/stand/libsa/readdir.c index 56c2b880d214..558ff99b265c 100644 --- a/stand/libsa/readdir.c +++ b/stand/libsa/readdir.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include "stand.h" diff --git a/stand/libsa/tslog.c b/stand/libsa/tslog.c index 4501746474ea..7a92ee6c23f3 100644 --- a/stand/libsa/tslog.c +++ b/stand/libsa/tslog.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #if defined(__amd64__) || defined(__i386__) diff --git a/stand/libsa/twiddle.c b/stand/libsa/twiddle.c index 43cdca25a367..9ecfbeac3389 100644 --- a/stand/libsa/twiddle.c +++ b/stand/libsa/twiddle.c @@ -32,7 +32,6 @@ * SUCH DAMAGE. */ -#include #include #include "stand.h" diff --git a/stand/libsa/udp.c b/stand/libsa/udp.c index 7a5942bbef95..a0a662a19976 100644 --- a/stand/libsa/udp.c +++ b/stand/libsa/udp.c @@ -33,7 +33,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/libsa/write.c b/stand/libsa/write.c index 16a6fc7eaa60..06b9bfc63ac2 100644 --- a/stand/libsa/write.c +++ b/stand/libsa/write.c @@ -58,7 +58,6 @@ * rights to redistribute these changes. */ -#include #include #include "stand.h" diff --git a/stand/libsa/zalloc.c b/stand/libsa/zalloc.c index 3bee66c02201..98738cf1f357 100644 --- a/stand/libsa/zalloc.c +++ b/stand/libsa/zalloc.c @@ -27,7 +27,6 @@ * SUCH DAMAGE. */ -#include #include /* diff --git a/stand/libsa/zfs/nvlist.c b/stand/libsa/zfs/nvlist.c index e6634ec969d4..6cb496a57b26 100644 --- a/stand/libsa/zfs/nvlist.c +++ b/stand/libsa/zfs/nvlist.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/powerpc/boot1.chrp/boot1.c b/stand/powerpc/boot1.chrp/boot1.c index 2804a2a2befd..cdacb05c31ce 100644 --- a/stand/powerpc/boot1.chrp/boot1.c +++ b/stand/powerpc/boot1.chrp/boot1.c @@ -15,7 +15,6 @@ * purpose. */ -#include #include #include #include diff --git a/stand/powerpc/ofw/elf_freebsd.c b/stand/powerpc/ofw/elf_freebsd.c index 5cd8a974cfb6..21ab834f76fa 100644 --- a/stand/powerpc/ofw/elf_freebsd.c +++ b/stand/powerpc/ofw/elf_freebsd.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/uboot/copy.c b/stand/uboot/copy.c index cc12cfaeef35..e5e985c85b27 100644 --- a/stand/uboot/copy.c +++ b/stand/uboot/copy.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/uboot/elf_freebsd.c b/stand/uboot/elf_freebsd.c index 42ed4080c363..6c764d143881 100644 --- a/stand/uboot/elf_freebsd.c +++ b/stand/uboot/elf_freebsd.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/uboot/glue.c b/stand/uboot/glue.c index 782636817001..8d8e2a57d1fc 100644 --- a/stand/uboot/glue.c +++ b/stand/uboot/glue.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/uboot/main.c b/stand/uboot/main.c index 0106243a0e1e..6147757ced71 100644 --- a/stand/uboot/main.c +++ b/stand/uboot/main.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/uboot/net.c b/stand/uboot/net.c index e703afcadca4..969724ea02df 100644 --- a/stand/uboot/net.c *** 45 LINES SKIPPED *** From nobody Tue Apr 16 02:34:50 2024 X-Original-To: dev-commits-src-branches@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 4VJSmq0crmz5Hb8l; Tue, 16 Apr 2024 02:34:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmp52v4z4HqD; Tue, 16 Apr 2024 02:34:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234890; 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=rGrs7ecFDdB5jffnqAKzFFAhh3Iijyp2l/JVSfXipCY=; b=si4u3g43QKtkqgMnZvnApThGMsRYKjzU7OPDNzP+QgQkd2M+xnrSW+CBLNPnENwTdVYd/X NhqPLZZAXQw3PQY30dmh5aFXtVuLpkaP1DWH/S+EMlqXb1J/YYUF1W/609crehqL1vF2r7 Nt8rU/oiSyalOsocMosixX/uulQTLs5rjzsjq1bX+jC2FR20bVs+7jbESC8eh5O1OyXBzQ TbOoCmer6Hvebskeh10g46acVzVvnpW3vcTFevLycuJ5KZuSwsw+eknUTuZtKPkFR0srzG JsPpk+BhYbDZIlt5zEKM3jw6F8HIkdC2Wl011i30Ua52ASLduDNyEAOLSKz8rQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234890; a=rsa-sha256; cv=none; b=vB5vJM88ejSb4GZPSaQHttYf7l/e5dj7/xrxgT2TVu+3hLSMc5jFqMucJvTwjHFXuI903H begUp3zooKXAxDBVpDCpmSaLHctzZPnUfKy7DvgnhzjFHZQrZfOql2gGSNXU/DBPa0U0Jt cSXuZ0VUSSpMYeERjtUdzhmSe+3VvBbdLV7SrrikgPA5izyQf4a9be2dTpOuCHrMrRhSGX +SQYv95/LJcVW+NdhTGm9BDEAO/exp7qjuG/Z9jaUFdPEqq7lK7p6xm6WTkE5ReXMQ52gR /eOoFNrOUaKcCQNG1/G9QU/WO4MNjnO7aq3YoHXK8TYSnOFF2+hgg+yeYQKXPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234890; 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=rGrs7ecFDdB5jffnqAKzFFAhh3Iijyp2l/JVSfXipCY=; b=kUk/AJFfSUCzZuSA/9s6ubCdzXuWVPD7Jj2Ops4ePLEFsz6oA6b44wOTz+jkbXuYPrAfbK TxVUI4vKXlYw66INF3+rUEimAeWIpLBI+0bU3+vRjBmWoIxTGfymsZeulH+GTgfiguswz0 7PPNJqDW+84IvZPya85GsjTvVEEY7zCXSDSgDwCd3sHiWmOt4t7L+UBwCD+IrmEZ2ymwuN 7O71/yAoeTXVJWM0RvRzpMIXljzec2pvLOk2VCgS/67qVC3aqeIfD7oy/YOgHpn2YpMTRM J0T/uADSB4IroOciWN1S38yxCiy9P1qaiY94F/1+pzlcR2FdyZnD/wNYIGiI3g== 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 4VJSmp4gG6zQ65; Tue, 16 Apr 2024 02:34:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YoCE037866; Tue, 16 Apr 2024 02:34:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2Yo5E037863; Tue, 16 Apr 2024 02:34:50 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:50 GMT Message-Id: <202404160234.43G2Yo5E037863@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 49028a1db2de - stable/14 - pmbr: Only load the first 545k rather than error out List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 49028a1db2de089482d203d5792f2abe7dc1449e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=49028a1db2de089482d203d5792f2abe7dc1449e commit 49028a1db2de089482d203d5792f2abe7dc1449e Author: Warner Losh AuthorDate: 2023-11-27 22:40:40 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 pmbr: Only load the first 545k rather than error out It would be nice to have larger boot partitions for ESPs to live in one day. It's trivial to carve out 5M 10M or 200M when provisioning, but logistical issues may make it hard to do it after the fact. So only warn when the partition is > 545k. If we ever grow the boot loader larger than that, then it will be responsible for loading the rest anyway. Sponsored by: Netflix Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D42774 (cherry picked from commit c596126a5d3d2ee015ee6807b4041efa5b9d9b07) --- stand/i386/pmbr/pmbr.S | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/stand/i386/pmbr/pmbr.S b/stand/i386/pmbr/pmbr.S index c61acbe261bd..60b26df15720 100644 --- a/stand/i386/pmbr/pmbr.S +++ b/stand/i386/pmbr/pmbr.S @@ -155,8 +155,10 @@ next_boot: addl $1,(%si) # Next LBA mov %es,%ax # Adjust segment for next addw $SECSIZE/16,%ax # sector cmp $0x9000,%ax # Don't load past 0x90000, - jae err_big # 545k should be enough for - mov %ax,%es # any boot code. :) + jb sz_ok # 545k should be enough for + call err_big # any boot code, but warn + mov $0x9000-SECSIZE/16,%ax # and truncate +sz_ok: mov %ax,%es jmp load_boot # # Move to the next partition. If we walk off the end of the sector, load @@ -203,17 +205,21 @@ getdrvparams: # # Various error message entry points. # -err_big: movw $msg_big,%si # "Boot loader too - jmp putstr # large" +err_big: movw $msg_big,%si # "Truncated + call putstr # to 545k" + ret err_pt: movw $msg_pt,%si # "Invalid partition - jmp putstr # table" + call putstr # table" +err_pt.1: jmp err_pt.1 # Await reset err_rd: movw $msg_rd,%si # "I/O error loading - jmp putstr # boot loader" + call putstr # boot loader" + jmp err_pt.1 err_noboot: movw $msg_noboot,%si # "Missing boot - jmp putstr # loader" + call putstr # loader" + jmp err_pt.1 # # Output an ASCIZ string to the console via the BIOS. # @@ -223,9 +229,9 @@ putstr.0: movw $0x7,%bx # Page:attribute putstr: lodsb # Get character testb %al,%al # End of string? jnz putstr.0 # No -putstr.1: jmp putstr.1 # Await reset + ret -msg_big: .asciz "Boot loader too large" +msg_big: .asciz "Loaded only 545k" msg_pt: .asciz "Invalid partition table" msg_rd: .asciz "I/O error loading boot loader" msg_noboot: .asciz "Missing boot loader" From nobody Tue Apr 16 02:34:51 2024 X-Original-To: dev-commits-src-branches@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 4VJSmr0nVWz5HbC8; Tue, 16 Apr 2024 02:34:52 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSmq69jVz4HcD; Tue, 16 Apr 2024 02:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234891; 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=ln/v3kCC9zKapMySvHKlhMoB2jEt5UpExxSPsuAl3x4=; b=ArG+DrDqayq1u+SYOxeINlr8cGs7ACn+2/UF5AJjIR/coknG7LAMd5tOaYbXm1Cv0bTbyl y0jqeEZzd9IyrkeVHa5yI6tFO8bjuNgBMXvYRqrpZRKBNyl4c/Q8A7QQ8dyo93ANXqWaN6 WNV//xNqNlSBIC8p3N4mGHADp0HWONgq1N+R6AVjatVbsg+MWrtJsUwC1WclAOwy0kSlDu PvfefkR8Nuw+CYcUNEjY//QNsRy8/yVcDmU1TInGeZVkLbR+wHz9lutTLMwI4Z5dGIOnzN qpehiTXjYL4F4Eh2B5+aXektTtWxAuFO6yn12SVD/OEhwNHc89mMbADVUUckbQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234891; a=rsa-sha256; cv=none; b=KYyEzy89Ghx7czHFxxz3z/r7N8/T7yjgJVUcHqlINb5a3JbrEjAwVTGShweMBx9GKyaeTE gktpadsoewBNhU6VlpyuSqydkEcmI1mAbHtBecSnWOERw2xEOHAkYXHbE1V2yRzCMKTKjS Dspmg5YCf85ViH/NDcJ3fzqic9WNUt0htoY4VZ0Dk4rUF6SSNf7G0zoU7c5VtxUypHv/ja H3xdIkBlN4O2csCL592JKafoBKaZhY5Y165Gyb0boyqNv+QNj4kDWZmKiWNRoRteFAhcGE 5EXfQYQRYf7RPNJNJmmPrzqoh8fkDD7buzB9CQJu5Pe9iTHMmAyOv1PCtuGpkA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234891; 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=ln/v3kCC9zKapMySvHKlhMoB2jEt5UpExxSPsuAl3x4=; b=bI5vceXwxxxB1ZRe8PsSXBKsyrwUkGtuhCaj/cibSNqGydZQBVS8v+rBxUKuQVRJpdPGqA 7XapSp89KsG4Z/y2PACkXlkMUjH0p/NcE2GBAuCmxDHeFLH3u/e7xDy8SNfrl5HCrz5XQV Y2SHy7w+SQBvIqzMMKGs/PBuvXGEgwzrsdOktWdexEO+SSBSxmryPQB5qtEizlVrfGG+Q8 3ZmLHaB+IxizjUCOy2qkaxhRDLwgI+Zfnvk03D4mFYgd+DVPl1OIrxWBw+rFFJZaSCVfAE pa5M7rc8gmS1ePxP3ufo+RbkOxiFAZXpfafYIV8n7CHFZKLjxT3zwhD7B/xUBQ== 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 4VJSmq5p5WzPZc; Tue, 16 Apr 2024 02:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YpuD037934; Tue, 16 Apr 2024 02:34:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YpgG037931; Tue, 16 Apr 2024 02:34:51 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:51 GMT Message-Id: <202404160234.43G2YpgG037931@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 77d298ea3fb1 - stable/14 - loader: lua: assume late ACPI detection if the feature isn't enabled List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 77d298ea3fb1ba6789afe6cd0c4946a4c392a66c Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=77d298ea3fb1ba6789afe6cd0c4946a4c392a66c commit 77d298ea3fb1ba6789afe6cd0c4946a4c392a66c Author: Kyle Evans AuthorDate: 2023-12-08 21:36:06 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 loader: lua: assume late ACPI detection if the feature isn't enabled While we're here, enable the feature in the places we detect ACPI. This lets us side-step the existing issues and provide a path forward for folks upgrading from previous releases that haven't updated their ESP yet. Let's also fix core.setACPI: the hint already indicates that the user's disabled it more consistently than loader.acpi_disabled_by_user. Even more, the latter is wrong because we set it by default if we did not detect ACPI. The ACPI hint remains even when we're setting defaults because ACPI loaded into the kernel will make some noise if it's not hinted off, even when we didn't detect it. imp notes that this will result in some relatively harmless noise on platforms that don't support ACPI but aren't using the UEFI loader, as we would enable the ACPI module for loading on them and then loader would not be able to find it. These are non-fatal, but should probably be fixed by just declaring support for EARLY_ACPI in those loaders since we know they won't have ACPI early on -- punting on this for the time being, though, in favor of providing a safer upgrade path sooner. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D42727 (cherry picked from commit e183039f0882009c455c3b59fe1ab58a4fd25a5e) --- stand/efi/loader/main.c | 1 + stand/i386/libi386/biosacpi.c | 2 ++ stand/lua/core.lua | 21 +++++++++++---------- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 4100c0680b7f..d7cffe5f6df9 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -914,6 +914,7 @@ acpi_detect(void) char buf[24]; int revision; + feature_enable(FEATURE_EARLY_ACPI); if ((rsdp = efi_get_table(&acpi20)) == NULL) if ((rsdp = efi_get_table(&acpi)) == NULL) return; diff --git a/stand/i386/libi386/biosacpi.c b/stand/i386/libi386/biosacpi.c index f94e8684c970..fcad64d81549 100644 --- a/stand/i386/libi386/biosacpi.c +++ b/stand/i386/libi386/biosacpi.c @@ -54,6 +54,8 @@ biosacpi_detect(void) char buf[24]; int revision; + feature_enable(FEATURE_EARLY_ACPI); + /* locate and validate the RSDP */ if ((rsdp = biosacpi_find_rsdp()) == NULL) return; diff --git a/stand/lua/core.lua b/stand/lua/core.lua index 65b91cd8f63e..9226de564348 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -133,17 +133,20 @@ function core.setSingleUser(single_user) end function core.hasACPI() - return loader.getenv("acpi.rsdp") ~= nil -end + -- We can't trust acpi.rsdp to be set if the loader binary doesn't do + -- ACPI detection early enough. UEFI loader historically didn't, so + -- we'll fallback to assuming ACPI is enabled if this binary does not + -- declare that it probes for ACPI early enough + if loader.getenv("acpi.rsdp") ~= nil then + return true + end -function core.isX86() - return loader.machine_arch == "i386" or loader.machine_arch == "amd64" + return not core.hasFeature("EARLY_ACPI") end function core.getACPI() if not core.hasACPI() then - -- x86 requires ACPI pretty much - return false or core.isX86() + return false end -- Otherwise, respect disabled if it's set @@ -157,13 +160,11 @@ function core.setACPI(acpi) end if acpi then - loader.setenv("acpi_load", "YES") + config.enableModule("acpi") loader.setenv("hint.acpi.0.disabled", "0") - loader.unsetenv("loader.acpi_disabled_by_user") else - loader.unsetenv("acpi_load") + config.disableModule("acpi") loader.setenv("hint.acpi.0.disabled", "1") - loader.setenv("loader.acpi_disabled_by_user", "1") end core.acpi = acpi end From nobody Tue Apr 16 02:34:52 2024 X-Original-To: dev-commits-src-branches@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 4VJSms2Qf5z5HZpw; Tue, 16 Apr 2024 02:34:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJSms0C7Yz4Hvq; Tue, 16 Apr 2024 02:34:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234893; 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=0Tvx3gKm8scIsUkJBV7x7nWOf2dGKB1pTiL77BHCm2M=; b=PuZ6HmckxeLWHi5h/AsQf5s4pwmgGmyYUxCVqZbR90F1X/3WzCTmghO+sR8H58nxXIL67J 4dQpL0Qdg5e+g+ctnPwq7oXGyibnouNEhigbCZhhCHP8nKUUcKcHN33JjouocS2ym8cVRb IjFsmBGBm8Zw1SI35686sm0BPezJdGdn5rp48HdItDXLuQUcMsQFHg/Wm6I6RLo+9EzZji rH2rfl/pCxqXjZIyPzXzA2+l3JoJAxxTEGMXnydz4CXS9Q9BS7orcj+ryjIkK2GtP6vqyh bISS6nmgZrkYu9H0mltR3KnS4Hh7lupTRarpvbHrSyyoy06ZBkxFvCwUdGxyTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713234893; a=rsa-sha256; cv=none; b=UeSN2zbqtawR60j3dH+APidKOag8lgJSApM4HJUMQuYPqOiC3gOvFhGc+GXwp2yJHVuotd un7Zd2Mv7gLxbMCQQS0ySjJbZ1V9wCiDTwkv7KWEDt8DFOUAN2ReqEA6uft4tJSyvack5s 8LsPe+r/duMNjmgnqfDX3u6CCoPwMDIyrF6mEpyOeAO3HpGMhfFAe8jSL1x7C3JQLR9Jqc 3fMYhLAo9QhH0ZuI71AofEGnzJF/tCfJH7MHLNjSOkU2MDViU8LJt6H4xTchoBXVrChp+K vODRnM8o4PIwaHQUrOXIYhjNB81CctOYD1JTRT7gbX7NQeWBIJzeOB3EcGF4MQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713234893; 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=0Tvx3gKm8scIsUkJBV7x7nWOf2dGKB1pTiL77BHCm2M=; b=GePbn92pFIuZH0ATK6IvGr5fQIZkMK7WEZzciaa6+RgAzFFVfpglyv8+EyQha1SHi2AW3l 4RPhLQa9oTXScUKRgvEv9cNQEU4uuXCaINI4osTRbrGwifD6tnj94/iEdxRfAYrF9UjIDI J2x+nJgP04RhaCR1XQiVcgvspbfjOMrc0DiI3M0ck83p3/OdROA+Lppe/2Qp8zaEc84yNe lo1YgwvFbV5X9gRGR+9ibzK0CMpn/A/4HQNnjzmyLdNEYz/zn4Jw+nbz3aWpGBwN9YWF0b fBvjnVisFw6C0LpGT/Jz9AmNUzYEYZSvBxk7M1du9ZG1fk3wE4Un/+oMwv4flg== 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 4VJSmr6RKMzPpm; Tue, 16 Apr 2024 02:34:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G2YqLS037978; Tue, 16 Apr 2024 02:34:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G2YqtB037975; Tue, 16 Apr 2024 02:34:52 GMT (envelope-from git) Date: Tue, 16 Apr 2024 02:34:52 GMT Message-Id: <202404160234.43G2YqtB037975@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: a0456d357896 - stable/14 - stand: Fix typo (triple S) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a0456d357896da6c9e0c9b507ce8ad9930012d7e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=a0456d357896da6c9e0c9b507ce8ad9930012d7e commit a0456d357896da6c9e0c9b507ce8ad9930012d7e Author: Jose Luis Duran AuthorDate: 2023-12-28 03:17:16 +0000 Commit: Warner Losh CommitDate: 2024-04-16 02:32:05 +0000 stand: Fix typo (triple S) Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/955 (cherry picked from commit ed76a9506aaa81426ded64bb0e1f96c6509c32ea) --- stand/efi/include/eficon.h | 2 +- stand/kboot/arch/aarch64/tramp.S | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/efi/include/eficon.h b/stand/efi/include/eficon.h index 39855b8b0725..3196ef4b4bf5 100644 --- a/stand/efi/include/eficon.h +++ b/stand/efi/include/eficon.h @@ -485,7 +485,7 @@ EFI_STATUS Returns: EFI_SUCCESS - The notification function was registered successfully. - EFI_OUT_OF_RESOURCES - Unable to allocate resources for necesssary data structures. + EFI_OUT_OF_RESOURCES - Unable to allocate resources for necessary data structures. EFI_INVALID_PARAMETER - KeyData or NotifyHandle is NULL. --*/ diff --git a/stand/kboot/arch/aarch64/tramp.S b/stand/kboot/arch/aarch64/tramp.S index 9304ca325299..32616f239c50 100644 --- a/stand/kboot/arch/aarch64/tramp.S +++ b/stand/kboot/arch/aarch64/tramp.S @@ -37,7 +37,7 @@ * location with the needed alignment, etc. It does this, and then we take over. * * The linux kernel will helpfully turn off the MMU, flush the caches, disables - * them, etc. It calls the tramp with two args: FDT blob addresss in x0 and the + * them, etc. It calls the tramp with two args: FDT blob address in x0 and the * EL2 vectors in x1. Currently, we make use of neither of these parameters: we * pass whatever dtb we think we need as part of the module data and we're a bit * weak on hypervisor support at the moment. _start's requirements are all From nobody Tue Apr 16 03:02:06 2024 X-Original-To: dev-commits-src-branches@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 4VJTNH2Lhbz5HdD2; Tue, 16 Apr 2024 03:02:07 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJTNG5wxNz4PD2; Tue, 16 Apr 2024 03:02:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713236526; 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=1ioUW2dJqf5Vtj1LIWUXuBsKGleIvx0rUCwnigxOKPI=; b=wBFfVqZcZemYzdE5irr5zmUrVus+/CuGu3Z9H3A8Do9axe+ky+Mo0DMlZ8LNdyHM5k8+fQ HhbbMH1rkBq8+HeikD+MZ1Nj7MlKiBkhXNL7hV7C4R6jN8/NGbhpOVsVSSfb8taDrsVL7i CMDJvyNSAYu9VRCmxc9kBFTx8OmGWr/vuHPk792xokATfNWVVvDSSC4nq4250KiOfLgrj9 i6goFlbY+kSLWFO36dyNNHBZb7CjWiSaUSOA3G5+SbIE/0yXFGJYKH6n32Dl2KtmSkvknO eMcK79QToDyjt1+MlPKMZSwajv0xfsivcn3pT2RtJHUUu3n77kH93rsC4zWHVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713236526; a=rsa-sha256; cv=none; b=wa2nNF3RJPMplQaKyzeUFHh4TxtnHrWcBzrjFE1HR5GNTaJNLULMjcXBYI9hLvmGCFamrC SDgYen4jEgOvKrL/4hjDj+cPcwLV20sLp69brhCQLPWVciDqEMQvzQ3ZX6oeWj13QUVhAo 0iT18ooZAXWvsbY9DvT8TTYJfYZwMHiFMIF+241u7AAJzlYrWikvH27ICk7UyaRdCQktsR XWP2AgLPGIIGCFdkDYx50qHBsuf/SYKwESyAoBC2SqjAZa6RWs33TiaFg8SPMFyiwFnLyp Ki1ome4q02oxIS5nBurB2v7sx5EPgEx+ACBKE3Mxg+Y5AOndWckM2S1K29FSyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713236526; 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=1ioUW2dJqf5Vtj1LIWUXuBsKGleIvx0rUCwnigxOKPI=; b=Yl1PISPg8LKmaL1N0PJ5cjvux5gXl1tYiFfRj7LLfaRVMvJcL/33kQm1VPhDdirBycw2j9 owYwhdFrUJxXP4rLmTf3CUdG5ceXViQa/Xq/Sr8dXAwhq/dl/UDKWoZtkg+Kexj0Vy4THs kf9DAWbcHF3ethv9TTYWQf34gV1qo8mrkeB486ZskyyJYr+8645a4nJsNDvgHI1H4Z0YBO zMxODtsJydUxqZ+NOLfO1LIirZdC7Q936BDQQsWjg3AqeOLrgLrW62QfTbLvhy/WkOAQOj lgta4SJeTgkOfolYcIEZd/UR5d2zd1ICaMUCJpqVa0BaLFCknfKAtJ1ipQSrcg== 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 4VJTNG5XSVzQn0; Tue, 16 Apr 2024 03:02:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G3269X088646; Tue, 16 Apr 2024 03:02:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G326Al088643; Tue, 16 Apr 2024 03:02:06 GMT (envelope-from git) Date: Tue, 16 Apr 2024 03:02:06 GMT Message-Id: <202404160302.43G326Al088643@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Rick Macklem Subject: git: 936c6d5c9618 - stable/14 - mountd.8: Document the new -A mountd option List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 936c6d5c9618610ff4f3a39349f3d16ecd3169c1 Auto-Submitted: auto-generated The branch stable/14 has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=936c6d5c9618610ff4f3a39349f3d16ecd3169c1 commit 936c6d5c9618610ff4f3a39349f3d16ecd3169c1 Author: Rick Macklem AuthorDate: 2024-04-09 01:58:40 +0000 Commit: Rick Macklem CommitDate: 2024-04-16 03:01:13 +0000 mountd.8: Document the new -A mountd option Commit fefb7c399b39 added warning messages noting that administrative controls that exported directories that are not local server file system mount points actually export the entire local server file system. This commit also added a new command line option "-A' that silences these warnings. This patch documents the new "-A' mountd option. This is a content change. (cherry picked from commit cce11997a052549933ca1c4d7412bf51137e4d0b) --- usr.sbin/mountd/mountd.8 | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/usr.sbin/mountd/mountd.8 b/usr.sbin/mountd/mountd.8 index a8fa14d5df04..3eff5d598fe7 100644 --- a/usr.sbin/mountd/mountd.8 +++ b/usr.sbin/mountd/mountd.8 @@ -27,7 +27,7 @@ .\" .\" @(#)mountd.8 8.4 (Berkeley) 4/28/95 .\" -.Dd March 18, 2023 +.Dd April 8, 2024 .Dt MOUNTD 8 .Os .Sh NAME @@ -37,7 +37,7 @@ mount requests .Sh SYNOPSIS .Nm -.Op Fl 2delnRrS +.Op Fl 2AdelnRrS .Op Fl h Ar bindip .Op Fl p Ar port .Op Ar exportsfile ... @@ -62,6 +62,16 @@ Allow the administrator to force clients to use only the version 2 .Tn NFS protocol to mount file systems from this server. +.It Fl A +Silence the warnings related to +.Dq administrative controls . +These warnings remind users that an exported +.Dq administrative control +directory that is not a local server file system mount point +actually exports the entire local file system and not just +the subtree below the directory exported. +(See +.Xr exports 5 ) .It Fl d Output debugging information. .Nm From nobody Tue Apr 16 04:35:50 2024 X-Original-To: dev-commits-src-branches@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 4VJWSQ38VMz5Hm5P; Tue, 16 Apr 2024 04:35:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJWSQ10HBz4YQc; Tue, 16 Apr 2024 04:35:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713242150; 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=pOJYFXAoKHaJGv2bAyI3JWM3fBJDOn1NCRh28ZPNFIM=; b=m7/cvpgoBVkoh0RRJjT8p6SRhnZ7keXfwBSZ8r6PDkjpkTN+Cv7fYlQTPcbY43BDnXwHY6 RO5G2KOI2FeTPCgy7aKKXI00VBB1jgqdVIfIFyzqca6Oi1jC33LXjfzPGbAsgiCceFUh0V ZJ1RNgMorwIdpuILiZoDBIPs+UkPmVp+xWPWItkIcAfmXCUTyeCjPInRFyyha20U5nww7e /XrecOSOusacBit5ydOZjdA9qea7Fi3etdFq/9LZCcYkwDYbYkiRuK22xoxlm08z2qiy5w cTsKIQ5LNQ+5IAv3bXivzmbfpzU/ceHJ5LU7h+3bLh8beq7FGimQMjKiKNaiAQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713242150; a=rsa-sha256; cv=none; b=ytJPxJfJCL0YNChEj1wrraJB5qD0ywF4WxP3vcKz61sBf/A6UvSCOqzdFM+Cs7z2Bp9y0G E2xujaFqf1ldrPPbqOSCzP7kM7hhDPxN5SF6SOecAMBnET1qssZoy99St6dpDr7AO/Zdal DfQyfScMcZOgv8q9yH+WyZwjliXSkfdM99D6gHoVQu94r0hVOzWBPWmCNJIwwTVq7IVndL FL8a1VAoFwmgLfolzayIapcwUNe6r6JfS8UQ3mrgy3vUpz1aC99Y9mEMDuSCis5t31dNxn Xz6Tbtihohoz4DPW8kZ1MtdaEessR7T5+9IY5yZIhsX2/Ctrpc4ZYWcoW5oB5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713242150; 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=pOJYFXAoKHaJGv2bAyI3JWM3fBJDOn1NCRh28ZPNFIM=; b=YcQ4FfSnRDlPaqWo+fCGN12Bfd2hIlFR7Snub8F3Hz0tRRCBYoqjglp9wLimrvCR8W5zGW Tk83vj6IWHd4RPkC/De2yebl7tUbJ9hh1Tqdz+byTjlJdSr9cfQXAY1j7+C/YZb+EfOamx bcV3Pf2V/KDnDSGs5mjeoBKvfk/QofExbVSRMNG0HaiPJziM+irAQzqw+iK+9KPoE7Ux01 RUpPsY8baMCA3xpc3jXq3Dr7iP+RlIu+MsJ+mXWaPXPDVodj9yRhcQaKAaR4/9TwciEKLN mfecCKnveUhXqAljKz8QyWbIwF/QhPLnxIc+B0vMIl0Px5Gp2EIg4/pgLhrCfw== 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 4VJWSQ0bKrzT3T; Tue, 16 Apr 2024 04:35:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G4ZoCB043097; Tue, 16 Apr 2024 04:35:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G4ZoDZ043094; Tue, 16 Apr 2024 04:35:50 GMT (envelope-from git) Date: Tue, 16 Apr 2024 04:35:50 GMT Message-Id: <202404160435.43G4ZoDZ043094@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 2e8d60c68540 - stable/14 - ng_socket: Treat EEXIST from kern_kldload() as success List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2e8d60c6854006a391491bc2c1c48c459c32e2c4 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=2e8d60c6854006a391491bc2c1c48c459c32e2c4 commit 2e8d60c6854006a391491bc2c1c48c459c32e2c4 Author: Zhenlei Huang AuthorDate: 2024-04-09 10:04:47 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-16 04:34:56 +0000 ng_socket: Treat EEXIST from kern_kldload() as success EEXIST is possible in a race condition. Inspired by: ffc72591b1f5 (Don't worry if a module is already loaded ...) Reviewed by: glebius MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44633 (cherry picked from commit f6f67f58c19db4f25f5c2cf4869efc7054493a55) --- sys/netgraph/ng_socket.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sys/netgraph/ng_socket.c b/sys/netgraph/ng_socket.c index 4afa46c3d0f0..0b38f0176bfc 100644 --- a/sys/netgraph/ng_socket.c +++ b/sys/netgraph/ng_socket.c @@ -285,11 +285,15 @@ ngc_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr, if (ng_findtype(mkp->type) == NULL) { char filename[NG_TYPESIZ + 3]; int fileid; + bool loaded; /* Not found, try to load it as a loadable module. */ snprintf(filename, sizeof(filename), "ng_%s", mkp->type); error = kern_kldload(curthread, filename, &fileid); + loaded = (error == 0); + if (error == EEXIST) + error = 0; if (error != 0) { free(msg, M_NETGRAPH_MSG); goto release; @@ -298,9 +302,10 @@ ngc_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr, /* See if type has been loaded successfully. */ if (ng_findtype(mkp->type) == NULL) { free(msg, M_NETGRAPH_MSG); - (void)kern_kldunload(curthread, fileid, - LINKER_UNLOAD_NORMAL); - error = ENXIO; + if (loaded) + (void)kern_kldunload(curthread, fileid, + LINKER_UNLOAD_NORMAL); + error = ENXIO; goto release; } } From nobody Tue Apr 16 04:36:41 2024 X-Original-To: dev-commits-src-branches@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 4VJWTP4VMwz5Hm5b; Tue, 16 Apr 2024 04:36:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJWTP2Qpyz4Ywx; Tue, 16 Apr 2024 04:36:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713242201; 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=k1YlPZ3+yd1wLELHV165X6r18DPbG3Tg41U/10GRaDg=; b=fei+5vJoAD0fdZ9OFkI4NBv1qLCZB3ImIdoDt4UtHfY9bjIPxRKK3lZ8ckNHHZXiTb4RpO SgHXptTitaRJUxQHHX1SjqFmW0ICEVnJrGvrp28zUmeHGMxZa6wvE4P17zJw/rJJS2BDHp 6CN5LDzUixY0tsQZoATNE/ETanI3U4FAbbk4YGnyDyUfBCWBjEQLFSfhdIlMAG00q0PPzH HKyYMNn1w3aaqhpPFWvdMsypbVuplvRjR72r2+cTV3gPtU9mw04DGbyTNjJeI0e02pwXOC mhG4MWmm4bW7jnCWti37ZXg9r90LlKRiWZb6qTa6I388XviPSoXS1R1o97nL+g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713242201; a=rsa-sha256; cv=none; b=md1vRwL+PBuDEYvw0TBFGYanEaJC3pkM22qoUNfd69D9aevoKupCzkxbYcJWbkZ/UY0ZfG Er9Zz2o2ZIyYZb5x7RjKvUOECDm2lASu7FygodR4gtSMg3+hkX1S9oYk9dSvI8dPAzzl7b k1FAnp5OtZW0DhGB/vN7oKXjPI17gagE1XRrcx3tlLiORZO3H9afokMPgPtvwvAtF90Q3E 2+ePsZVVy4o2XbRGpvswXoPRlORWRGgczinTx/cJXLOLwQFDM4fhulqd9nS4d1afDMpBlZ WSGs6KN4zXsAeR6lcH4RNkVBJ0HspVSa5AdBdiHteOMBeJclZoaQcY/G3qXNQQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713242201; 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=k1YlPZ3+yd1wLELHV165X6r18DPbG3Tg41U/10GRaDg=; b=N0iAN5BLM2Cm7YSlqsDulDbqYRNY0JlBzoCXn9aA1p1RBG2bzpB/o8a5fPffgZ+7GGUawX 8Q5MjsuaNR4UwjPoIRaZfOLndLFTT8YED0W6C2Kd1dFK7lwlCw5AmDn49ncr0aWCsnrWp9 X5R/kQ9WluquiIwHfe4nDRIpw1jHfCQXEwNkMeNk0Z8gJ0ZH5jTD5jZOju8ZjlbDDAjE++ u6Mbfwgnnqrkg2VSbwt1m/hgReI85xjAU7ceHfHQPlP+s5lSvGlCmHR2yr3nEjVN6f0WW/ PS8GZs5ksY/xFtDSPKzd9xZmnHeD8PKpzVEYgVjtX/qLLg+an6dWsrkTAzQokw== 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 4VJWTP22RGzTG4; Tue, 16 Apr 2024 04:36:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G4af10043335; Tue, 16 Apr 2024 04:36:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G4afBd043332; Tue, 16 Apr 2024 04:36:41 GMT (envelope-from git) Date: Tue, 16 Apr 2024 04:36:41 GMT Message-Id: <202404160436.43G4afBd043332@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: d77e45e29f04 - stable/13 - ng_socket: Treat EEXIST from kern_kldload() as success List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d77e45e29f0462ea7a2eb1e56fac8fd850ea460c Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=d77e45e29f0462ea7a2eb1e56fac8fd850ea460c commit d77e45e29f0462ea7a2eb1e56fac8fd850ea460c Author: Zhenlei Huang AuthorDate: 2024-04-09 10:04:47 +0000 Commit: Zhenlei Huang CommitDate: 2024-04-16 04:36:16 +0000 ng_socket: Treat EEXIST from kern_kldload() as success EEXIST is possible in a race condition. Inspired by: ffc72591b1f5 (Don't worry if a module is already loaded ...) Reviewed by: glebius MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44633 (cherry picked from commit f6f67f58c19db4f25f5c2cf4869efc7054493a55) (cherry picked from commit 2e8d60c6854006a391491bc2c1c48c459c32e2c4) --- sys/netgraph/ng_socket.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sys/netgraph/ng_socket.c b/sys/netgraph/ng_socket.c index 63180114ee3f..a6b391400f1c 100644 --- a/sys/netgraph/ng_socket.c +++ b/sys/netgraph/ng_socket.c @@ -285,11 +285,15 @@ ngc_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr, if (ng_findtype(mkp->type) == NULL) { char filename[NG_TYPESIZ + 3]; int fileid; + bool loaded; /* Not found, try to load it as a loadable module. */ snprintf(filename, sizeof(filename), "ng_%s", mkp->type); error = kern_kldload(curthread, filename, &fileid); + loaded = (error == 0); + if (error == EEXIST) + error = 0; if (error != 0) { free(msg, M_NETGRAPH_MSG); goto release; @@ -298,9 +302,10 @@ ngc_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr, /* See if type has been loaded successfully. */ if (ng_findtype(mkp->type) == NULL) { free(msg, M_NETGRAPH_MSG); - (void)kern_kldunload(curthread, fileid, - LINKER_UNLOAD_NORMAL); - error = ENXIO; + if (loaded) + (void)kern_kldunload(curthread, fileid, + LINKER_UNLOAD_NORMAL); + error = ENXIO; goto release; } } From nobody Tue Apr 16 13:57:55 2024 X-Original-To: dev-commits-src-branches@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 4VJlwz3Rxsz5GvkN; Tue, 16 Apr 2024 13:57:55 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJlwz2xZqz49w4; Tue, 16 Apr 2024 13:57:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713275875; 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=t7jWNeZggGHAZuAfIITd0xfWgVDn6nUcl6FxZpOoSi8=; b=VMUTioWzvXzumH/JLfjenlO0iSvZQWxLx5qQojoJ6F2MNUb/vBfR3HqEXosHSQSe1lQS4o 7hLtg3VfpxIvKuF3MMisqvBem+0/yeyp3w6G+V17+f/xRlBsDz90RffJcmus2rTqf17RqP 6ijIsS0mfJ1h1rfpO2dYKE0Vj6wUHfxZty083Nu2SCzA0ocZbA66zNHtY1NhqyePAMbgik xGz/xRE/nlct85CdZ4WAS3c0m47nqZ8Bg8J/BSNSgtDqEyv3BUQHvbRYPVDu0hgxgq3f3x feBDMcWlTZJ9m7niBrVlPRogofXaahAcMwul4WrhJKsTeuT2J2Lj9Ri7LZyLRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713275875; a=rsa-sha256; cv=none; b=qlbW3dL9n7+qM2nQm2bt/y9pg/vXIFC51jwKn+GQ58x0Rtt41q52PI6fFt9wyrL5/BsVHJ DqA/uyu9Qav2e4IaZ9uGqZ8zln6oImQ+n/+B8Q4Aj0grIAqFY8BDhMUr0rwOxX3a5BkHnJ /VBg519zQlR3IgMWHF2yXtH5HNhAAsODXwsk1nqhs47orepHjg+sJC2xyWRupym7r+AkzT L+bH+MYcnaW1RowQtErFZY8MV8yFETIU7nzTzuzbY4DruoGhzgNAnq7Km/Bt7JW1YvEqWx QDyvTzgcOmfVQzeau+fPVPa3yYusTdIoclAcRLZvy6gParsVxQ0gAJk1wbUcdA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713275875; 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=t7jWNeZggGHAZuAfIITd0xfWgVDn6nUcl6FxZpOoSi8=; b=Scuque44i3J9/aj7mar93A7f9xv+QrueNhBYCmld+uJBjB/d+rkZCqxefcWxYzMWHYpHgY ScwmjpYdZw/HNqHtyzOcG0NFqv4R+5iU+AQewluKr752s6/nZRSiP6vKm7TZyGLNmt0HVW caRiBxWuKlz4NIDJVv0WNC7nNeg+gfqtEX5GBT4omx26s65xf5BCQNdu/0mMZzy9H8GvMg StkzKMJUejaHewNwh92QtyMsnn4x0VNdm5Nu7WnsEcZ57AuDpKeVTr+OefBENrMnQJOEYK WylIMdMDNKHI0Q7S2FxmLBzg5WP5vTjJlE/v4lQhss+WZix/gvIguqMS1Fz8KA== 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 4VJlwz2Xx5zm1V; Tue, 16 Apr 2024 13:57:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GDvtks090667; Tue, 16 Apr 2024 13:57:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GDvtUw090664; Tue, 16 Apr 2024 13:57:55 GMT (envelope-from git) Date: Tue, 16 Apr 2024 13:57:55 GMT Message-Id: <202404161357.43GDvtUw090664@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 7f156d86dfa9 - stable/14 - tegra210: change to UTF-8 (from ISO-8859) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7f156d86dfa9d40ddf7e389c502a743f7d0439a8 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=7f156d86dfa9d40ddf7e389c502a743f7d0439a8 commit 7f156d86dfa9d40ddf7e389c502a743f7d0439a8 Author: Ed Maste AuthorDate: 2023-12-29 03:53:16 +0000 Commit: Ed Maste CommitDate: 2024-04-16 13:57:43 +0000 tegra210: change to UTF-8 (from ISO-8859) Prompted by Phabricator's complaint that a C source file was a binary file, in D43192. Reviewed by: mmel Differential Revision: https://reviews.freebsd.org/D43229 (cherry picked from commit 56c202de785a5701831ae345a1a5c906e0b2c3e6) --- sys/arm64/nvidia/tegra210/tegra210_xusbpadctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/arm64/nvidia/tegra210/tegra210_xusbpadctl.c b/sys/arm64/nvidia/tegra210/tegra210_xusbpadctl.c index c3ebb4622081..726f26c9f9b5 100644 --- a/sys/arm64/nvidia/tegra210/tegra210_xusbpadctl.c +++ b/sys/arm64/nvidia/tegra210/tegra210_xusbpadctl.c @@ -656,7 +656,7 @@ uphy_pex_enable(struct padctl_softc *sc, struct padctl_pad *pad) goto err; } - /* 5. Enable the PLL (20 µs Lock time) */ + /* 5. Enable the PLL (20 μs Lock time) */ reg = RD4(sc, XUSB_PADCTL_UPHY_PLL_P0_CTL1); reg |= UPHY_PLL_P0_CTL1_PLL0_ENABLE; WR4(sc, XUSB_PADCTL_UPHY_PLL_P0_CTL1, reg); @@ -891,7 +891,7 @@ uphy_sata_enable(struct padctl_softc *sc, struct padctl_pad *pad, bool usb) goto err; } - /* 5. Enable the PLL (20 µs Lock time) */ + /* 5. Enable the PLL (20 μs Lock time) */ reg = RD4(sc, XUSB_PADCTL_UPHY_PLL_S0_CTL1); reg |= UPHY_PLL_S0_CTL1_PLL0_ENABLE; WR4(sc, XUSB_PADCTL_UPHY_PLL_S0_CTL1, reg); From nobody Tue Apr 16 13:58:49 2024 X-Original-To: dev-commits-src-branches@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 4VJly13GJyz5GvkZ; Tue, 16 Apr 2024 13:58:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJly12WFVz4BPB; Tue, 16 Apr 2024 13:58:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713275929; 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=8Y2dHQE9I38BM4W8YVFkIIdAfzh0TbalFtqO2b4vGWs=; b=bCO/LlszWhz2Bfun1Wh+PdF6BxteNViZU+l1uGQIMnuYSRCYNGUfgr5qua5SCr/T6+/OLj 4K8ncW66hwp+jdNojqvu2AEXY4eWbrLz1EilpkeWcf/MffseWs9UTGzJ5wyftCFFtZYxHp 7xH7qt4MZad2yNuehXc2ZiGRjLrxvU/us01K5Bj3v+vCvbLrR6vKWKXRywkOZyadwNougY P9iCf8v024eDQ1/2A7FqOPbyZ8k2GBO2mk4BuXnfMzc/ulqB5zX1Z3XOHfY5s/JX2HQG3r ucyFX89H3pEGeyqw+pa74zb0MSglRac5AwhrRZzVp9CyGlgTS8Kzy4pEbnmVFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713275929; a=rsa-sha256; cv=none; b=X2h4u62U9h05yoeRHgFgyrmVD9BsW3U4K4ZcbHkEnqR+UpcZApmdkqHabE4X9flz80t1JN 0JAVJF9nPnAY9l2UB/MAB8W+S7WY2pdQI/9hz7Qz3W9tKLtm5OtwfEkEEGp8f7eZnwcR3Y lUwkPWXSPdScgL1cax4ONir6wCkCdE7azaG9uOBaTsIMpWLa40fEde+U8BbCMR9vIVTNwf joVsRz5FESGJGX1TT5jAfP6fknXgTCIbaNOs+6sWS/oltTUk7PXWWxKaDsoZoQILpd8LVB sZxDDDycYrlGGfJ8XPpWYEWBPk6a9BTHtfvxhQ4qGNS3LWXDgm+n37jM0RdwNg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713275929; 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=8Y2dHQE9I38BM4W8YVFkIIdAfzh0TbalFtqO2b4vGWs=; b=MFQmao2CZP5cZuY9YHLG40CZzTlmdvU2lUjtClhVPFbDjjpAalXI/yKBFYalTnrONs863y OFBKAk3jM1VyYoUlWF+ckFnrHbZuPJe1U6XCkd63OhHhBAT0OfnuP6Rfo6GYM6ZBifm5jo IFXEobwQ4JwdGbelnDGL/T4zOTIoW72Ld3LM1iR64AEhFtsPsCbr0h20vb9XtD1pQ99mIS h/LJZSziVaGaicgfk+2A4PAtjvxhiRZcenHPnwEcQW0Xaql4wHMloS4EDLGqvhlDcDbdAl OdSHwl3s6RxcLFWk5odgbnki4mTw6kLHtpMZGfhTxLcxQHChxfgeaAAEqdgaCQ== 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 4VJly126s6zlgS; Tue, 16 Apr 2024 13:58:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GDwnML090919; Tue, 16 Apr 2024 13:58:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GDwnXT090916; Tue, 16 Apr 2024 13:58:49 GMT (envelope-from git) Date: Tue, 16 Apr 2024 13:58:49 GMT Message-Id: <202404161358.43GDwnXT090916@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: bf4972a48d2e - stable/14 - bsdlabel: add deprecation notice List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bf4972a48d2ed8762d6aba91573e762c985998a8 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=bf4972a48d2ed8762d6aba91573e762c985998a8 commit bf4972a48d2ed8762d6aba91573e762c985998a8 Author: Ed Maste AuthorDate: 2024-01-23 18:04:43 +0000 Commit: Ed Maste CommitDate: 2024-04-16 13:57:43 +0000 bsdlabel: add deprecation notice gpart is the preferred tool for managing partitions of all types, including BSD disklabels. Note that this is only about bsdlabel/disklabel, the tool -- there is no current plan to remove support for MBR or BSD disk labels from the kernel or from gpart. Reviewed by: imp, olce Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D43563 (cherry picked from commit b6f3cced151f8b7dc3e32977e8f1b826f0654690) --- sbin/bsdlabel/bsdlabel.8 | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/sbin/bsdlabel/bsdlabel.8 b/sbin/bsdlabel/bsdlabel.8 index a1ff2a78f1f0..dcf8c7ccace7 100644 --- a/sbin/bsdlabel/bsdlabel.8 +++ b/sbin/bsdlabel/bsdlabel.8 @@ -28,9 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" @(#)disklabel.8 8.2 (Berkeley) 4/19/94 -.\" -.Dd October 5, 2016 +.Dd March 25, 2024 .Dt BSDLABEL 8 .Os .Sh NAME @@ -61,6 +59,22 @@ .Op Fl f .Ar disk | Fl f Ar file .Ar protofile +.Sh DEPRECATION NOTICE +.Nm +is deprecated and is not available in +.Fx 15.0 +or later. +Use +.Xr gpart 8 +instead +.Po +with the +.Cm BSD +partitioning scheme +.Pc , +or install the +.Pa freebsd-bsdlabel +port or package. .Sh DESCRIPTION The .Nm From nobody Tue Apr 16 15:58:48 2024 X-Original-To: dev-commits-src-branches@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 4VJpcT1D3qz5H5cL; Tue, 16 Apr 2024 15:58:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJpcT0gFhz4S4g; Tue, 16 Apr 2024 15:58:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713283129; 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=MZsH6wut4Oyr4ouy348AhKMMvUNrdWZ3mwhDJs2KPE0=; b=qEBknhwBQ37bjuShP6OJphMYTih4V4Xy4cw8CzQL2aXjdxL60llbzhtrRMdoQLaszReL/n lM+vGDwSQwzo8ILtJw8NQ3PLOk/4Rnn/FOELvIJrFzsuBnYJYCjZAmzU0X6ane4eOI6tzG vI0bShVXOWJDlu/yifHGZkCPThyzBAtCu9pFHVKPHOiXlRkPbMXKt7QDMpmDllx+LPXTQB +pUh6Bd/EkS15DhBOpeXRi8JUTpxebUc40WmGFSMGm3ecg2irvUYirWCtVGVpdRZS2dCnA zqDWKK0xqWzmUwdHArAiXatBSy7+KATAD42esP4VJPXhO1lpXOh77nTceP+3vQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713283129; a=rsa-sha256; cv=none; b=ONSQv7kfrXzwzFGrwV7SEN7eKNBAio2fRTOg68BcF0WA5wpatX4HytDNTwnJ5kRXajS9/g qKunBtJ3LkWRLzNSqE8k66uh9Owt990rrGWfRk50/zgPUvBK/CoJYPjpwpPisBDZdoXpZk j3sMxVpfNdFhIELuZT2ODmYZz1f4ux2sElGB1Ys2vHaHAQ14tL6RFx9ohkMvgsnfelXMPr ezSVD7XAo+xgs3n+l6D5Ul5buo65xQaFHK14cbTU7fKy+k8wTxcU76R//ur0mSnIBVrYFN QoqnasPYPkPZUvClwxxpAGlKNucd8QawO+9demhRbfmsN10Dc2/eJufwM6aVxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713283129; 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=MZsH6wut4Oyr4ouy348AhKMMvUNrdWZ3mwhDJs2KPE0=; b=V+RPLuj3GXCd502m+4H/zcTCRJY7Pr48290VFIenqoS/x+gEkyIDBwZAapiIqjerMQBBUI 1v1JbUPwsOJLQA+Jecw5DTZ/4gxSOEhOcWkc0kCeLDW6ejNtWPjbJzTo4FUtcpBSyyQCj4 hPXnljlER9KdhFrdkTMM908lWdXfZgyqY2nwcCiQUjezyeRaI5dHJFEBGWv80JIaSt7ZJE cBi+7t/FZXEBcU3TC3xTfCOfUjPtHiDCko9prkryxgJ3Uqa0wygQWouHD5Gx1Qwab4MlWk WSYvEdszC+CShpc47vMqVHsvAKUNPo5y1NaFTS0LpW2gq4B6NCQvLLCi2zTvOw== 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 4VJpcT0GRKzq86; Tue, 16 Apr 2024 15:58:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GFwm0r095162; Tue, 16 Apr 2024 15:58:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GFwmYF095159; Tue, 16 Apr 2024 15:58:48 GMT (envelope-from git) Date: Tue, 16 Apr 2024 15:58:48 GMT Message-Id: <202404161558.43GFwmYF095159@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gleb Smirnoff Subject: git: cc16c3c3cb5f - stable/14 - pfilctl: fix 'pfilctl hooks' when nothing is connected List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: glebius X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cc16c3c3cb5f166a2c743077ac8ec37f6af5c24a Auto-Submitted: auto-generated The branch stable/14 has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=cc16c3c3cb5f166a2c743077ac8ec37f6af5c24a commit cc16c3c3cb5f166a2c743077ac8ec37f6af5c24a Author: Gleb Smirnoff AuthorDate: 2024-03-28 21:10:15 +0000 Commit: Gleb Smirnoff CommitDate: 2024-04-16 15:56:13 +0000 pfilctl: fix 'pfilctl hooks' when nothing is connected The 'hooks' command actually worked accidentially until now. It used PFILIOC_LISTHEADS to determine current number of hooks. This worked when at least one head had a hook connected to it. (cherry picked from commit 1bfe195143ffb6832ac6702e281964541554fcb3) --- sbin/pfilctl/pfilctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbin/pfilctl/pfilctl.c b/sbin/pfilctl/pfilctl.c index c2fe04ecc777..81b6d9716dc9 100644 --- a/sbin/pfilctl/pfilctl.c +++ b/sbin/pfilctl/pfilctl.c @@ -151,8 +151,8 @@ listhooks(int argc __unused, char *argv[] __unused) u_int nhooks, i; plh.pio_nhooks = 0; - if (ioctl(dev, PFILIOC_LISTHEADS, &plh) != 0) - err(1, "ioctl(PFILIOC_LISTHEADS)"); + if (ioctl(dev, PFILIOC_LISTHOOKS, &plh) != 0) + err(1, "ioctl(PFILIOC_LISTHOOKS)"); retry: plh.pio_hooks = calloc(plh.pio_nhooks, sizeof(struct pfilioc_hook)); if (plh.pio_hooks == NULL) From nobody Tue Apr 16 15:58:50 2024 X-Original-To: dev-commits-src-branches@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 4VJpcV2qgsz5H5G4; Tue, 16 Apr 2024 15:58:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJpcV1dBbz4SFS; Tue, 16 Apr 2024 15:58:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713283130; 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=GXFKNl2XMj4y4mJzbUaN9M+StyCeMvXVWHVzON8lpZQ=; b=i9g3HrdIWAsD6GNw/XxvMHKG5H/0osY90QB9w6/fQotckcubakjrRGI0kbfDt64+7iFiyZ cH4vAPEXg2vQii8F3l9KPDb46yEBKNvkUNqO7yt6zYNuV86axBuMJ2POtwy+JobA5641qq f/A+n/9jVUi0dbIKQjOf+w/T+kqPay3lkyuIdceh+tdUay89Xkxidu6xOWsCH+O7CIRXTD XB45Hx0ncmVocxQ6gahFv+CqSOieFIAOrDRU2g0r24fR2qq5NgZbFd/kbD8V9TwV6+BI0h EHhAY6n1eVUv4zpUCmRznSs/2/3aUBW6fhFYJgkbojdJyxxYl4ptPVns/rqiIQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713283130; a=rsa-sha256; cv=none; b=n8bZ6/o2bIIfVEd2WwtOIoX/4avNqkQWEXlGT6f+N6LNIq9tMyW1qSwVKZVeCDV2LlMn09 6zbWsBaN8DYyFsD42Q+g8rIIfas/rWPbgNIKHJzh4uMSuL8wEqLumHjHHLsXyw/ZPgEFVe R5S0YYviOpPaYm+KLrTcUXoLlQ7I/nt+YXXLd3K7MKRw2/MwBAdzmTYca8ELTynKdMYxmt OIIESF0HMTdL1GjjDugOMNDulvHf/9Lx2iGG9/H6urzBqg8Kwk6sxF34mVpRmiEkF8ud6U vBgcp39+Gbh+iu1UP0WEwu6ZFnu3FNL3NP8c3IJCx2UgHdrgg2UX72DOMsCouA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713283130; 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=GXFKNl2XMj4y4mJzbUaN9M+StyCeMvXVWHVzON8lpZQ=; b=GUl8N7NM7lWxabGauNiuZ8/U2BGvEXMt4ibd/16gbeOX+Q5i5scOh0ZAA0U6PCfyUE1N9J 4KUN9M3zXnKszPGYKg5uG34nhUQfu+NvWIdatrkUlxpAnCpu61jnbGCdTbH70qHHuEhpwz AcxgvG8NGMEoDgUodAoNDl+dS/nt9M+WbaqDPRKr0WBbECG7NtiSWfa5TzLTB4qvZZAqGW VN7azU910dA+tGRfQ1t7QXFBzfOAmvDZMyWCx9w1sdF4m2f3l84Hv78QO1jmt2rHjlHFI4 jWLDIKyVsv3r7fkKX3mmN63QajJ6ntiDci6nl0CAGz3+LslvDwBfHevkz9SpaA== 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 4VJpcV1DPFzpC2; Tue, 16 Apr 2024 15:58:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GFwob4095210; Tue, 16 Apr 2024 15:58:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GFwoEt095208; Tue, 16 Apr 2024 15:58:50 GMT (envelope-from git) Date: Tue, 16 Apr 2024 15:58:50 GMT Message-Id: <202404161558.43GFwoEt095208@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gleb Smirnoff Subject: git: 8062f37d1c99 - stable/14 - vtnet: set VNET context in RX handler List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: glebius X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8062f37d1c99ded250b36ad90fb32bb5f77ee600 Auto-Submitted: auto-generated The branch stable/14 has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=8062f37d1c99ded250b36ad90fb32bb5f77ee600 commit 8062f37d1c99ded250b36ad90fb32bb5f77ee600 Author: Gleb Smirnoff AuthorDate: 2024-03-28 21:12:39 +0000 Commit: Gleb Smirnoff CommitDate: 2024-04-16 15:56:32 +0000 vtnet: set VNET context in RX handler The context is required for NIC-level pfil(9) filtering. (cherry picked from commit 3f2b9607756d0f92ca29c844db0718b313a06634) --- sys/dev/virtio/network/if_vtnet.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/dev/virtio/network/if_vtnet.c b/sys/dev/virtio/network/if_vtnet.c index 7d6411876b3d..245a6b6d7359 100644 --- a/sys/dev/virtio/network/if_vtnet.c +++ b/sys/dev/virtio/network/if_vtnet.c @@ -2095,6 +2095,7 @@ vtnet_rxq_eof(struct vtnet_rxq *rxq) VTNET_RXQ_LOCK_ASSERT(rxq); + CURVNET_SET_QUIET(if_getvnet(ifp)); while (count-- > 0) { struct mbuf *m; uint32_t len, nbufs, adjsz; @@ -2188,6 +2189,7 @@ vtnet_rxq_eof(struct vtnet_rxq *rxq) #endif virtqueue_notify(vq); } + CURVNET_RESTORE(); return (count > 0 ? 0 : EAGAIN); } From nobody Tue Apr 16 16:18:05 2024 X-Original-To: dev-commits-src-branches@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 4VJq2j3NSSz5H7Jd; Tue, 16 Apr 2024 16:18:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJq2j2gsyz4TkP; Tue, 16 Apr 2024 16:18:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713284285; 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=+cvCn/70/orU46FU7fQMqKgt/9KNeW4nL7vADxffr6E=; b=IvFj34xPxsrP4Hdm6q4PnNn7/thdZxt7MDh+Am4kDXfDmjJoLNwq6XLvnhoRQLcBLeZfxz B6lv+MCry4BinCYnUci7YrPylx1teF6ovwbTmf3SjkH2ymTR/CTwKFZ3QkAMnSj4ovPL2d iZ+Y2IUhvpUctsoxJHrPwL3vzcjeomfmXgIjYlm0CHVW+W0MniGU8X/QJOndKUky7YPbxi i37UXNV8vK7AjPSbsasovbCuaH6z+A+G1ukq24GG7Vpyg9NE4MG/6bYnAcQ6ftNENs/Egg 07SyKZxLhFPjXeHm5UvQM64FzstDMCR9qQiAuXSZnpzZ4GI9JXRX1s/8OpGxpg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713284285; a=rsa-sha256; cv=none; b=kv1y/77yN/pk2zaVgCuZz5FYeH5vKxUvEibXzCEv8VUPTJeDbvYxtinREelY6hcsSCkkBG QYvshPFDbtk5hirPmILFXIDYmOopYnPhvRpB/ntWYKCB4DlbGTWRnfsB7ZOIy64H9YwL3/ nl7QOsR/RB1AAJdWI2tjLzWLFKBceJheMb0Nz2i2r6zUkkxBZo8V6RCnrATOXbag5XNK1x zPLE2XG0odsU+jih/Mltpl67FFhfW9VxeYBQ+Yxeyiimb0vhYBc+fZ9OjmAK3pDWSh+ox+ loKkolPcmy22VrQ7bZvfh6eqcOtPseRhj2Xi9+QIuvTzuwPmyswzVRMBYsdWoQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713284285; 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=+cvCn/70/orU46FU7fQMqKgt/9KNeW4nL7vADxffr6E=; b=JQPHhd/2Q+rZnt5brZiiyK7v0fEJjkSXktyYsseZGrRRefiEtrNBzjKW4ggOTpSVobExtD TfXRHUJrStk9JmilMxExUQaQdDOevwF+XWmoFRN1Y8Ik2LSX3mdqWYdpOlQJXmVe7w6r6m tkdGnw3auWACGe3joJokJ4GIt/SEVE0xmGCnioeGj+J4vUA5T30WWiwbofniZuvoO6ONWm /24+Zp4e/BHaEFJXBMa0DefWoHYQyjE4PGWzpHy9ziq7yua+OJXkc6EmNvqqquVQkPFKgZ 8qWQGEKiQugzWXE7UsPe2xzljZMg5M3Brd5CHpELK9DKiBG7v2m6u7hoC0FvjA== 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 4VJq2j2HDSzq09; Tue, 16 Apr 2024 16:18:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GGI5VT029525; Tue, 16 Apr 2024 16:18:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GGI54n029522; Tue, 16 Apr 2024 16:18:05 GMT (envelope-from git) Date: Tue, 16 Apr 2024 16:18:05 GMT Message-Id: <202404161618.43GGI54n029522@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 894bf6bd7d1d - stable/13 - wg: Use ENETUNREACH when transmitting to a non-existent peer List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 894bf6bd7d1dcdb2869cf065bea697e1dda07cb0 Auto-Submitted: auto-generated The branch stable/13 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=894bf6bd7d1dcdb2869cf065bea697e1dda07cb0 commit 894bf6bd7d1dcdb2869cf065bea697e1dda07cb0 Author: Mark Johnston AuthorDate: 2024-04-01 17:20:55 +0000 Commit: Mark Johnston CommitDate: 2024-04-16 16:08:54 +0000 wg: Use ENETUNREACH when transmitting to a non-existent peer The old errno value used is specifically for Capsicum and shouldn't be co-opted in this way. It has special handling in the generic syscall layer (see syscallret()). OpenBSD returns ENETUNREACH in this case; let's do the same thing. PR: 266712 Reviewed by: kevans, imp MFC after: 2 weeks Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D44582 (cherry picked from commit 63613e3ba1e188e9fece43e1613bd697f04b345e) --- sys/dev/wg/if_wg.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/dev/wg/if_wg.c b/sys/dev/wg/if_wg.c index 6638524301b8..a65c3a707985 100644 --- a/sys/dev/wg/if_wg.c +++ b/sys/dev/wg/if_wg.c @@ -255,9 +255,6 @@ struct wg_softc { #define MAX_LOOPS 8 #define MTAG_WGLOOP 0x77676c70 /* wglp */ -#ifndef ENOKEY -#define ENOKEY ENOTCAPABLE -#endif #define GROUPTASK_DRAIN(gtask) \ gtaskqueue_drain((gtask)->gt_taskqueue, &(gtask)->gt_task) @@ -2116,7 +2113,7 @@ wg_xmit(struct ifnet *ifp, struct mbuf *m, sa_family_t af, uint32_t mtu) BPF_MTAP2_AF(ifp, m, pkt->p_af); if (__predict_false(peer == NULL)) { - rc = ENOKEY; + rc = ENETUNREACH; goto err_xmit; } From nobody Tue Apr 16 20:12:16 2024 X-Original-To: dev-commits-src-branches@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 4VJwDw1xGPz5H00M; Tue, 16 Apr 2024 20:12:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwDw1RLMz4ryw; Tue, 16 Apr 2024 20:12:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298336; 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=F5O1JWQwxZUMWfEbSfFVcjR0fyBmIxww+NXtLl1jGos=; b=NbHfKhxTI0OgKyA2Lnv9qiuhkIaE/SKnesM/eanIoWecRhZ/UsnDQ5EdSAF91QptvqrY7v aB0PY3cNxRVAwgiTp2HkLHU9fPt3MlvdJhKqGhpMbHG2D4k7Wt1X9OKjNuJU1nX59ntwzL vVSrIDLuSFbYAE7xxYxGUVR01qyT2SvARfgbgM2SvSuGLl8pViuMhXsRDV6v9wsWqUDDxd +Evu5iYm4NCr+zOMQFQxDjy9pLwYeFxbdVSO2ZMgDnElT39H8Z4UvZlp0hTRvJGxS8Rkz4 HhZjowueeDarFaKuedesL5/SXM2DaYPBM0mG/P8sEsNUQ3BvyqQDoqJL0bLwfQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298336; a=rsa-sha256; cv=none; b=T457ZsGJ+exMtBrj4kX2YjByfOOkKobPBImgHLCxyhUlCmQUHfT/8yaAwaEVq0rK/gEvGk sA2huOcO4QVWqniXDBUVz8GJ9hnCSeoP0mDkBfbszWJt/5NUAu9VK938mGhKzcjCu5OFao ZGBBXNh6yulj+WUet+/T/J3qcfBqPCO3P9dDIvpwjfxCZLowFvgtrRHJwf1gZhWgin/lCk EoxWfJOlJ1s4ASsY3+UvG/6QKzsLQmw5douUo7KYYu/14SxUhFp6FnhEGX8uVOQlfgH7tR 7diiNoFtB6HEzvhC1H3UPmA50Ei/ZjHJetJgc2m109T/PjcF/v26437RxxkTSQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298336; 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=F5O1JWQwxZUMWfEbSfFVcjR0fyBmIxww+NXtLl1jGos=; b=rRhmMr0R1Xskj6RakFOJTKODPWCD6yAHh0hKsD6usiVZUUL0WEZyYRP7jTDkwLL8kUEc6v MefLg+6XslxBWHEi5tzZ4ZuF3QcOHQh5IWw/lyvHjFgNcPZhzzuI5uUPmJ4Sp8mqx5nEgw 98M9HeYR/+6Imli9NhrJC8PhOXCYM1+75OtbxB1NIlSbAQvuBAw/GFkM1dlK6NiAxQjBxo nbyXQMOy1oYpPzxl0/UXtAKiFjA8Ci5sBLcEOSbFvHy7wkPrbLO3hcNRc7+PvyCxf6xKQS dhGW8jGEHiqeVn3j+oyRlLjUHuf17h1XdTOALzFYQ5IDeYs5wwT0BhfkGJEfsw== 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 4VJwDw128XzxBm; Tue, 16 Apr 2024 20:12:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCGlD035492; Tue, 16 Apr 2024 20:12:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCG10035489; Tue, 16 Apr 2024 20:12:16 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:16 GMT Message-Id: <202404162012.43GKCG10035489@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: ae8398452bd3 - stable/14 - flua: Add hash module List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ae8398452bd3196c0ff1a11039167bd002369eb8 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ae8398452bd3196c0ff1a11039167bd002369eb8 commit ae8398452bd3196c0ff1a11039167bd002369eb8 Author: Warner Losh AuthorDate: 2024-02-16 03:54:36 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 flua: Add hash module Add lua bindings to hashing functions. sha256 is available. sha256.new craetes a new object. sha256.update updates the digest. sha256.digest returns the digest as a binary string and resets the context. sha256.hexdigest returns the digest as a string of hex digits and then resets the cotnext. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43872 (cherry picked from commit f7781d030ccd18b1d4c864ecfade122ea19dafb1) --- lib/flua/Makefile | 4 +- lib/flua/libhash/Makefile | 14 ++++ lib/flua/libhash/hash.3lua | 54 ++++++++++++++ lib/flua/libhash/lhash.c | 177 +++++++++++++++++++++++++++++++++++++++++++++ lib/flua/libhash/lhash.h | 11 +++ 5 files changed, 258 insertions(+), 2 deletions(-) diff --git a/lib/flua/Makefile b/lib/flua/Makefile index eb148c2125fd..769736039f7e 100644 --- a/lib/flua/Makefile +++ b/lib/flua/Makefile @@ -1,4 +1,4 @@ - -SUBDIR= libjail +SUBDIR+= libhash +SUBDIR+= libjail .include diff --git a/lib/flua/libhash/Makefile b/lib/flua/libhash/Makefile new file mode 100644 index 000000000000..f166ff90a392 --- /dev/null +++ b/lib/flua/libhash/Makefile @@ -0,0 +1,14 @@ +SHLIB_NAME= hash.so +SHLIBDIR= ${LIBDIR}/flua + +SRCS+= lhash.c + +CFLAGS+= \ + -I${SRCTOP}/contrib/lua/src \ + -I${SRCTOP}/lib/liblua \ + +LIBADD+= md + +MAN= hash.3lua + +.include diff --git a/lib/flua/libhash/hash.3lua b/lib/flua/libhash/hash.3lua new file mode 100644 index 000000000000..1662e87f7c68 --- /dev/null +++ b/lib/flua/libhash/hash.3lua @@ -0,0 +1,54 @@ +.\" +.\" Copyright (c) 2024 Netflix, Inc. +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.Dd February 6, 2024 +.Dt HASH 3lua +.Os +.Sh NAME +.Nm new , +.Nm update , +.Nm digest , +.Nm hexdigest +.Nd Lua Cryptographic hash module. +.Sh DESCRIPTION +The built-in cryptographic hashing Lua bindings for the are available via the +.Ic hash +table. +.Ss Supported Hashing Schemes +The following hashing schemes are supported by the hash module. +.Bl -bullet -compact +.It +sha256 +.El +.Ss APIs Supported +.Bl -tag -width asdf -compact +.It Fn new data +Compute a digest based on the +.Va data . +.It Fn update Va data +Using the current digest, process +.Va data +to compute a new digest as if all prior data had been concatenated together. +.It Fn digest +Return the hashed digest as a binary array. +This resets the context. +.It Fn hexdigest +Take +.Fn digest +and convert it to an upper case hex string. +This resets the context. +.It Va digest_size +Return the size of the digest, in bytes. +.It Va block_size +Return the block size used in bytes. +.El +.Sh EXAMPLES +.Sh SEE ALSO +.Xr sha256 3 +.Sh AUTHORS +The +.Nm +man page was written by +.An Warner Losh Aq Mt imp@FreeBSD.org . diff --git a/lib/flua/libhash/lhash.c b/lib/flua/libhash/lhash.c new file mode 100644 index 000000000000..4587961fe8a0 --- /dev/null +++ b/lib/flua/libhash/lhash.c @@ -0,0 +1,177 @@ +/*- + * Copyright (c) 2024 Netflix, Inc + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include +#include "lauxlib.h" +#include "lhash.h" + +#include +#include + +#define SHA256_META "SHA256 meta table" +#define SHA256_DIGEST_LEN 32 + +/* + * Note C++ comments indicate the before -- after state of the stack, in with a + * similar convention to forth's ( ) comments. Lua indexes are from 1 and can be + * read left to right (leftmost is 1). Negative are relative to the end (-1 is + * rightmost). A '.' indicates a return value left on the stack (all values to + * its right). Trivial functions don't do this. + */ + +/* + * Updates the digest with the new data passed in. Takes 1 argument, which + * is converted to a string. + */ +static int +lua_sha256_update(lua_State *L) +{ + size_t len; + const unsigned char *data; + SHA256_CTX *ctx; + + ctx = luaL_checkudata(L, 1, SHA256_META); + data = luaL_checklstring(L, 2, &len); + SHA256_Update(ctx, data, len); + + lua_settop(L, 1); + + return (1); +} + +/* + * Finalizes the digest value and returns it as a 32-byte binary string. The ctx + * is zeroed. + */ +static int +lua_sha256_digest(lua_State *L) +{ + SHA256_CTX *ctx; + unsigned char digest[SHA256_DIGEST_LEN]; + + ctx = luaL_checkudata(L, 1, SHA256_META); + SHA256_Final(digest, ctx); + lua_pushlstring(L, digest, sizeof(digest)); + + return (1); +} + +/* + * Finalizes the digest value and returns it as a 64-byte ascii string of hex + * numbers. The ctx is zeroed. + */ +static int +lua_sha256_hexdigest(lua_State *L) +{ + SHA256_CTX *ctx; + char buf[SHA256_DIGEST_LEN * 2 + 1]; + unsigned char digest[SHA256_DIGEST_LEN]; + static const char hex[]="0123456789abcdef"; + int i; + + ctx = luaL_checkudata(L, 1, SHA256_META); + SHA256_Final(digest, ctx); + for (i = 0; i < SHA256_DIGEST_LEN; i++) { + buf[i+i] = hex[digest[i] >> 4]; + buf[i+i+1] = hex[digest[i] & 0x0f]; + } + buf[i+i] = '\0'; + + lua_pushstring(L, buf); + + return (1); +} + +/* + * Zeros out the ctx before garbage collection. Normally this is done in + * obj:digest or obj:hexdigest, but if not, it will be wiped here. Lua + * manages freeing the ctx memory. + */ +static int +lua_sha256_done(lua_State *L) +{ + SHA256_CTX *ctx; + + ctx = luaL_checkudata(L, 1, SHA256_META); + memset(ctx, 0, sizeof(*ctx)); + + return (0); +} + +/* + * Create object obj which accumulates the state of the sha256 digest + * for its contents and any subsequent obj:update call. It takes zero + * or 1 arguments. + */ +static int +lua_sha256(lua_State *L) +{ + SHA256_CTX *ctx; + int top; + + /* We take 0 or 1 args */ + top = lua_gettop(L); // data -- data + if (top > 1) { + lua_pushnil(L); + return (1); + } + + ctx = lua_newuserdata(L, sizeof(*ctx)); // data -- data ctx + SHA256_Init(ctx); + if (top == 1) { + size_t len; + const unsigned char *data; + + data = luaL_checklstring(L, 1, &len); + SHA256_Update(ctx, data, len); + } + luaL_setmetatable(L, SHA256_META); // data ctx -- data ctx + + return (1); // data . ctx +} + +/* + * Setup the metatable to manage our userdata that we create in lua_sha256. We + * request a finalization call with __gc so we can zero out the ctx buffer so + * that we don't leak secrets if obj:digest or obj:hexdigest aren't called. + */ +static void +register_metatable_sha256(lua_State *L) +{ + luaL_newmetatable(L, SHA256_META); // -- meta + + lua_newtable(L); // meta -- meta tbl + lua_pushcfunction(L, lua_sha256_update); // meta tbl -- meta tbl fn + lua_setfield(L, -2, "update"); // meta tbl fn -- meta tbl + lua_pushcfunction(L, lua_sha256_digest); // meta tbl -- meta tbl fn + lua_setfield(L, -2, "digest"); // meta tbl fn -- meta tbl + lua_pushcfunction(L, lua_sha256_hexdigest); // meta tbl -- meta tbl fn + lua_setfield(L, -2, "hexdigest"); // meta tbl fn -- meta tbl + + /* Associate tbl with metatable */ + lua_setfield(L, -2, "__index"); // meta tbl -- meta + lua_pushcfunction(L, lua_sha256_done); // meta -- meta fn + lua_setfield(L, -2, "__gc"); // meta fn -- meta + + lua_pop(L, 1); // meta -- +} + +#define REG_SIMPLE(n) { #n, lua_ ## n } +static const struct luaL_Reg hashlib[] = { + REG_SIMPLE(sha256), + { NULL, NULL }, +}; +#undef REG_SIMPLE + +int +luaopen_hash(lua_State *L) +{ + register_metatable_sha256(L); + + luaL_newlib(L, hashlib); + + return 1; +} diff --git a/lib/flua/libhash/lhash.h b/lib/flua/libhash/lhash.h new file mode 100644 index 000000000000..c1e9788a55a3 --- /dev/null +++ b/lib/flua/libhash/lhash.h @@ -0,0 +1,11 @@ +/*- + * Copyright (c) 2024 Netflix, Inc + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#pragma once + +#include + +int luaopen_hash(lua_State *L); From nobody Tue Apr 16 20:12:17 2024 X-Original-To: dev-commits-src-branches@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 4VJwDx4F1bz5H0DJ; Tue, 16 Apr 2024 20:12:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwDx2RRNz4sCT; Tue, 16 Apr 2024 20:12:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298337; 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=2z3NKjkjJswq7jIp+PxZjfQfHeyEs7hbhDFad6ck/rc=; b=ooxHeNe+iRJq1orD0WStwqdoP4UtDzr5MNeAR4hSSaQIEac94RtadIeIHVrq6mP9yBU4WX bLYr+qKpdE94viQ8nGeAA92AC9gBfPOBK1JuW/c1Tx+a5ocqijR2b6OJORW1QF86e2RvQT fGKn0COC64eDt24HTrdUPlhZNKhB8FBinmbSmoHRqA9teY69reRtXC4/Bu/3IOlsIOnXEz 1VTVxuAytrMhBBnf0M4lNLllISCxsVAsvDZYT5jj94LEFqScMJgL3qch3g/QfiTV9ML08b V9MYcEiYFzh3omCDkFvaM9Wl/U3QpfJ0Vc/YaAERVp7C48T4makf6AqvddSHDA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298337; a=rsa-sha256; cv=none; b=OapmqvbOEzrHO2v4zpXWEdOodSeTnpoIdPosClo088B013uA4Pzwj354jyz6M4WohBn1zY LduAOWFcAfduCKmpPVoJsWCGUpZ7+I1cluH6HtHlWDK4FN/KHfKZB4kk3+DHsw8RqFi2Nr MuyrdhDHOa8+1r2hPa3oM9HtnYc8mIrCIYipQH76ilwmfKjYaCvM08N2Txw7qPzQhnNTuy JCVj5qQ5Peq5flixadSHwK0m3ZeZksk8C23A+YfdfmhBgZHSUN4C7+YyfglCGPMfAy0eGK hs7VodaESPwj3S/s41+IL3Zb2mo3NBzo2XwpkRyc00eAWdYPloQu5xwj0eZzXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298337; 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=2z3NKjkjJswq7jIp+PxZjfQfHeyEs7hbhDFad6ck/rc=; b=ZlQw5pFRnqkMYZgGVqYYMOElNcDykV0l5MuO5PY6hAcmLNoFMFcqqIF9Rl8SCce3gHbgkX sRI4yzFuIFoFRt0j710CeOVF4WEw+ZPkVY6y3UhrCGRw9n9Et248WVtYnMDf6YGBe9wN/a S5Q1nLjoJ0PogYE/JV5zGWXWpRg6LJ5KlGVaecHjobPp4G92VCYl7ou4N4R6D1l3R6XvWc BXNxfZfmZuMbYU7t5CWtgHWAU7WbJpx3jI9//VAuUm06DvQTsAnAAZFuu8B8jBiBAzUAww i5JXQ1qd/o+vI2ZIYdagvmerIKWfOrO7ISCf1TV/O0T80ML9+p8DuFI1Cu6cIA== 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 4VJwDx22p5zxJR; Tue, 16 Apr 2024 20:12:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCH62035582; Tue, 16 Apr 2024 20:12:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCHkB035577; Tue, 16 Apr 2024 20:12:17 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:17 GMT Message-Id: <202404162012.43GKCHkB035577@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 656183c21b58 - stable/14 - share/mk: Don't install only differing in case files on case insensitive fs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 656183c21b58cf6fe9b8c8ee78d2a9245b11fedd Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=656183c21b58cf6fe9b8c8ee78d2a9245b11fedd commit 656183c21b58cf6fe9b8c8ee78d2a9245b11fedd Author: Warner Losh AuthorDate: 2024-03-15 04:33:33 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 share/mk: Don't install only differing in case files on case insensitive fs MacOS has case insensitive filesystems by default. So trying to link between foo.X and FOO.X causes an error of some sort since we unlink the old foo file destroying the newly installed foo due to the insensitive nature of the FS. Assume that this is true on darwin/macos, though it is only try by default there. Perhaps install should grow smarts to know when this is the case, though that looked much trickier. There didn't seem to be a flag to check. This would be better, imho, since we could still write the METALOG data correctly (images created from these metalogs are imperfect due to this relatively issue...). Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D44347 (cherry picked from commit d2a824c29d6925ba8675a811aa81f2ad7d92129d) --- share/mk/bsd.links.mk | 6 ++++++ share/mk/bsd.man.mk | 3 +++ 2 files changed, 9 insertions(+) diff --git a/share/mk/bsd.links.mk b/share/mk/bsd.links.mk index 6070979612bf..437ffd0d3b34 100644 --- a/share/mk/bsd.links.mk +++ b/share/mk/bsd.links.mk @@ -14,16 +14,22 @@ afterinstall: _installlinks .ORDER: realinstall _installlinks _installlinks: .for s t in ${LINKS} +# On MacOS, assume case folding FS, and don't install links from foo.x to FOO.x. +.if ${.MAKE.OS} != "Darwin" || ${s:tu} != ${t:tu} .if defined(LINKTAGS) ${INSTALL_LINK} ${TAG_ARGS:D${TAG_ARGS},${LINKTAGS}} ${DESTDIR}${s} ${DESTDIR}${t} .else ${INSTALL_LINK} ${TAG_ARGS} ${DESTDIR}${s} ${DESTDIR}${t} .endif +.endif .endfor .for s t in ${SYMLINKS} +# On MacOS, assume case folding FS, and don't install links from foo.x to FOO.x. +.if ${.MAKE.OS} != "Darwin" || ${s:tu} != ${t:tu} .if defined(LINKTAGS) ${INSTALL_SYMLINK} ${TAG_ARGS:D${TAG_ARGS},${LINKTAGS}} ${s} ${DESTDIR}${t} .else ${INSTALL_SYMLINK} ${TAG_ARGS} ${s} ${DESTDIR}${t} .endif +.endif .endfor diff --git a/share/mk/bsd.man.mk b/share/mk/bsd.man.mk index 444144e6d626..04316c46b705 100644 --- a/share/mk/bsd.man.mk +++ b/share/mk/bsd.man.mk @@ -229,6 +229,8 @@ maninstall: ${MAN} .endif # ${MK_MANCOMPRESS} == "no" .endif .for l t in ${_MANLINKS} +# On MacOS, assume case folding FS, and don't install links from foo.x to FOO.x. +.if ${.MAKE.OS} != "Darwin" || ${l:tu} != ${t:tu} .if ${MK_MANSPLITPKG} == "no" rm -f ${DESTDIR}${t} ${DESTDIR}${t}${MCOMPRESS_EXT}; \ ${INSTALL_MANLINK} ${TAG_ARGS} ${DESTDIR}${l}${ZEXT} ${DESTDIR}${t}${ZEXT} @@ -236,6 +238,7 @@ maninstall: ${MAN} rm -f ${DESTDIR}${t} ${DESTDIR}${t}${MCOMPRESS_EXT}; \ ${INSTALL_MANLINK} ${TAG_ARGS:D${TAG_ARGS},man} ${DESTDIR}${l}${ZEXT} ${DESTDIR}${t}${ZEXT} .endif +.endif .endfor manlint: From nobody Tue Apr 16 20:12:18 2024 X-Original-To: dev-commits-src-branches@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 4VJwDy5Pdgz5H0GN; Tue, 16 Apr 2024 20:12:18 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwDy2w7tz4s8X; Tue, 16 Apr 2024 20:12:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298338; 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=akmL2pu6fbe2KLiiJdLSlckCrjdD+/4Gk3aSsddDCQ4=; b=SJbeTqypCEwdGmtmGvNljMLyP7O6DBTNYJURxlVHFciWzWVmikSl7uo9fGBxWLIYPkf1Pi vbIX2VEB79ARAeoqae0zqXwkJDsIIr3Tyyiswml36hPt0+Lw9BN4zASh4MdFP2wxb1dU4T n0uCvsRe7gezLZbqTDGGod6CG04PG/ELd8S3pYfki7U2BlAQDxINbHS5I+A8MRoUW+BwS5 C5iRmpynjjfI3BKTefNTWyNGsjttKB5w0kXj+WJwsyfmvMjmUBKv+T6FnrpVdYsUy3K0TX R46VW7qjpLmZMJu6ccUc8d1uzckxLAZlEF3tNjul/s6TM7RH1A6/kRjS/tkwsg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298338; a=rsa-sha256; cv=none; b=VWZHMIFyKHfhDBtJQEOjlUN11D2+/kuiGNNVaOcNRbV5QI3O7m46Flp+dY6ogFEn3uaBQ8 fjbDpR7c5jcbVg03hgpxV2KM8F2kQozaXwccLa96NnIff0vluoGxYM5O+5JLBAd9jrQniR hR9nwIWZ+fkfFiefNswpVgIx42OiKZJhK7i04LrF4i9iks7gIkwgoL3YaUSewijvtKhUk0 P2/TXRK83QK8QnLlE6SLIKy5eIcBsj7UhbxDnCBsKw/L5WFxR0c1SOnhKOIRnU0Z6kOVZV o35m/S0Ha+UwCs6HKS2tReU2H6EZc3H1KgIPY+YcBu48BL9y1ayzEMXchaXZaQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298338; 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=akmL2pu6fbe2KLiiJdLSlckCrjdD+/4Gk3aSsddDCQ4=; b=QANc/UmNa4r4JDYS/brO7jQ6o71erepDKHDHd41nA7CP5O+RYKUH+qfY5dPdg01A293t05 TqJ2HWft+lwcwfaNfSMKPZy/Q6go+fJk/rToHJy71s2JvuEN6O4doDI8QaDYrHnEf0Cd64 Rt81ev0nvhkqeetbiUnnfa2Hcs22+Sh5UHy1cMgpUNqo8jZmIaROoeLMB4hMX/vPdePNjC rfqgqbo2ZXdeK8rTNIt6+rvCC7clz2HnbqkK0FB4FHQGI0uJhZXZ1beNN897vgB1GDunrg hgseof4sIe/FpI1PD+ZULVlWZX5FJo7aPwe3MvxJy8zZJWn/z2ZN9bLani16uw== 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 4VJwDy2X2DzxZw; Tue, 16 Apr 2024 20:12:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCIvG036602; Tue, 16 Apr 2024 20:12:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCIJk036599; Tue, 16 Apr 2024 20:12:18 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:18 GMT Message-Id: <202404162012.43GKCIJk036599@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 3e69ab88a032 - stable/14 - periodic/daily/801.trim-zfs: Add a daily zfs trim script List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3e69ab88a032ac43d433f787b715466a87e72817 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3e69ab88a032ac43d433f787b715466a87e72817 commit 3e69ab88a032ac43d433f787b715466a87e72817 Author: Lexi Winter AuthorDate: 2024-04-09 21:49:56 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 periodic/daily/801.trim-zfs: Add a daily zfs trim script As mentioned in zpoolprops(7), on some SSDs, it may not be desirable to use ZFS autotrim because a large number of trim requests can degrade disk performance; instead, the pool should be manually trimmed at regular intervals. Add a new daily periodic script for this purpose, 801.trim-zfs. If enabled (daily_trim_zfs_enable=YES; the default is NO), it will run a 'zpool trim' operation on all online pools, or on the pools listed in 'daily_trim_zfs_pools'. The trim is not started if the pool is degraded (which matches the behaviour of the existing 800.scrub-zfs script) or if a trim is already running on that pool. Having autotrim enabled does not inhibit the periodic trim; it's sometimes desirable to run periodic trims even with autotrim enabled, because autotrim can elide trims for very small regions. PR: 275965 MFC after: 1 week Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/956 (cherry picked from commit 493908c4b45c7b75e4a6b4aea3b5b63ea5c268d5) --- share/man/man5/periodic.conf.5 | 11 +++++- usr.sbin/periodic/etc/daily/801.trim-zfs | 59 ++++++++++++++++++++++++++++++++ usr.sbin/periodic/etc/daily/Makefile | 3 +- usr.sbin/periodic/periodic.conf | 5 +++ 4 files changed, 76 insertions(+), 2 deletions(-) diff --git a/share/man/man5/periodic.conf.5 b/share/man/man5/periodic.conf.5 index 29fff146c212..a2ed2b09d772 100644 --- a/share/man/man5/periodic.conf.5 +++ b/share/man/man5/periodic.conf.5 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd December 31, 2023 +.Dd April 9, 2024 .Dt PERIODIC.CONF 5 .Os .Sh NAME @@ -634,6 +634,15 @@ The same as .Va daily_scrub_zfs_default_threshold but specific to the pool .Ao Ar poolname Ac Ns . +.It Va daily_trim_zfs_enable +.Pq Vt bool +Set to +.Dq Li YES +if you want to run a zfs trim daily. +.It Va daily_trim_zfs_pools +.Pq Vt str +A space separated list of names of zfs pools to trim. +If the list is empty or not set, all zfs pools are trimmed. .It Va daily_local .Pq Vt str Set to a list of extra scripts that should be run after all other diff --git a/usr.sbin/periodic/etc/daily/801.trim-zfs b/usr.sbin/periodic/etc/daily/801.trim-zfs new file mode 100755 index 000000000000..17d2ce217c10 --- /dev/null +++ b/usr.sbin/periodic/etc/daily/801.trim-zfs @@ -0,0 +1,59 @@ +#!/bin/sh +# +# + +# If there is a global system configuration file, suck it in. +# + +if [ -r /etc/defaults/periodic.conf ] +then + . /etc/defaults/periodic.conf + source_periodic_confs +fi + +case "$daily_trim_zfs_enable" in + [Yy][Ee][Ss]) + echo + echo 'Trimming of zfs pools:' + + if [ -z "${daily_trim_zfs_pools}" ]; then + daily_trim_zfs_pools="$(zpool list -H -o name)" + fi + + rc=0 + for pool in ${daily_trim_zfs_pools}; do + # sanity check + _status=$(zpool list -Hohealth "${pool}" 2> /dev/null) + if [ $? -ne 0 ]; then + rc=2 + echo " WARNING: pool '${pool}' specified in" + echo " '/etc/periodic.conf:daily_trim_zfs_pools'" + echo " does not exist" + continue + fi + case ${_status} in + FAULTED) + rc=3 + echo "Skipping faulted pool: ${pool}" + continue ;; + UNAVAIL) + rc=4 + echo "Skipping unavailable pool: ${pool}" + continue ;; + esac + + if ! zpool status "${pool}" | grep -q '(trimming)'; then + echo " starting trim of pool '${pool}'" + zpool trim ${daily_zfs_trim_flags} "${pool}" + else + echo " trim of pool '${pool}' already in progress, skipping" + fi + done + ;; + + *) + rc=0 + ;; +esac + +exit $rc diff --git a/usr.sbin/periodic/etc/daily/Makefile b/usr.sbin/periodic/etc/daily/Makefile index 4eabc0bb1d52..3bf4601f5145 100644 --- a/usr.sbin/periodic/etc/daily/Makefile +++ b/usr.sbin/periodic/etc/daily/Makefile @@ -60,7 +60,8 @@ SENDMAILPACKAGE= sendmail .if ${MK_ZFS} != "no" CONFS+= 223.backup-zfs \ 404.status-zfs \ - 800.scrub-zfs + 800.scrub-zfs \ + 801.trim-zfs .endif .include diff --git a/usr.sbin/periodic/periodic.conf b/usr.sbin/periodic/periodic.conf index 5e3a7837c6b4..608a199b3cc9 100644 --- a/usr.sbin/periodic/periodic.conf +++ b/usr.sbin/periodic/periodic.conf @@ -179,6 +179,11 @@ daily_scrub_zfs_pools="" # empty string selects all pools daily_scrub_zfs_default_threshold="35" # days between scrubs #daily_scrub_zfs_${poolname}_threshold="35" # pool specific threshold +# 801.trim-zfs +daily_trim_zfs_enable="NO" +daily_trim_zfs_pools="" # empty string selects all pools +daily_trim_zfs_flags="" # zpool-trim(8) flags + # 999.local daily_local="/etc/daily.local" # Local scripts From nobody Tue Apr 16 20:12:19 2024 X-Original-To: dev-commits-src-branches@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 4VJwDz57kTz5HT4n; Tue, 16 Apr 2024 20:12:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwDz3fXsz4sLR; Tue, 16 Apr 2024 20:12:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298339; 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=W3GNm5S98gusLQupd/FHrgx77/BqKNLeU1mrwmvvU78=; b=W9Docvc6AeQmP0VxTtD0fNbFl7AUJE234GKVQFwFHyCceTbJJ8OS2k5hlDtszQ7ap9s2tI sN0WwKkB63rbHXNPDDpJ0McSmu4GwU2h3YPCKVzDfo0SrhhG/ZSF5dhtHnVKwLSslGHGy4 jC4h9AKiVm2gH4bXKmkf1ifBkvcZLYRjTmC0x1LyKN6bqUB33EIWzqJ8NOTGuHmxFUYs7J Ht32p8ZFVrU1otfwGbGSi3Bz7Gaz4oJSdsM/KkiDjiiWSxuRIUogx5ghi4yGlHktx5kCIx 7IBpKkSfJxc6EtO611j8/MErAC/gwlq+Bk+PBWzNzsxhPVJgapfwWoPwY3GqXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298339; a=rsa-sha256; cv=none; b=iGqjk/VOiMsIojC42PnUL7IlNUBT4BwdFkvRtYh/ICuzXw3xrNJN1iiL0I4KF8CAql7C/y xfHTSXYqi5bPXmhWxL7LN1L4DZPHb8lfeiXzKgJgL8f9kzKgWOD7QQ9KpYjVR5YYP8BHau yKWGTy8MGoPb+FzMSHIBUke15kwYrdIm6zEbkeOu8w9J9f26cf2eNCveP8DKCphk24Q4zG 9PFHNUUmZL6zUvGykVeH5sHjVpwlUyH8pnReTF5EIb/hnPaKHl7abb519btOP3p/qRs7Qo QIbfCztdSLsL4AfxPZbZ+jm60cjG5NTaPNjsnewEXw1TnmbQSPtPc8qc7w25uQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298339; 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=W3GNm5S98gusLQupd/FHrgx77/BqKNLeU1mrwmvvU78=; b=h8qivsvyg+5QnfKQPwbnRA0SuQMzfu3NSnpjJoFSzPKsngjy0ron/ulqHmwc0X5dbwy/Jr hCq1yi83IjglkJ0FqB3PrkoPyxW1fISuSnL3CmjQR7uwqZtqsyEY0zNNCJanHH26jrkDud jI2Xsm44D8cnQq1VRkkUq7TdvzhjoDz5TrnskHS4hpPJWjXxWP4vk5jf+fRGIlyHI35Vs5 K6PAZrfb5Thgq2xtTxZbFNlnuo4585WMBtubIw/nTbTy72ZV7qSmvq1Toijm821isZgu8i AnDdg3NLs6gFtDr21aGwvSEGcLB9PoWXZTvnD0OVgmndABGKTJOw798Q48HKew== 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 4VJwDz3GnqzxXq; Tue, 16 Apr 2024 20:12:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCJBP036643; Tue, 16 Apr 2024 20:12:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCJEZ036640; Tue, 16 Apr 2024 20:12:19 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:19 GMT Message-Id: <202404162012.43GKCJEZ036640@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: f20b349448f1 - stable/14 - kboot: Move to kboot/kboot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f20b349448f1522fffccd80a4d1f46bfd7c3f28a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=f20b349448f1522fffccd80a4d1f46bfd7c3f28a commit f20b349448f1522fffccd80a4d1f46bfd7c3f28a Author: Warner Losh AuthorDate: 2024-01-28 18:05:05 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 kboot: Move to kboot/kboot In anticipation of separating the library elements from the kboot prorgam elements, move kboot down a level into a subdirectory. There will be libkboot and include directories in subsequent commits, mirroring other subsystems like i386 and efi. Sponsored by: Netflix (cherry picked from commit 091c255b5b279fddf445a42dd7d0bad0e7c213fd) --- stand/kboot/Makefile | 68 +-------------------- stand/kboot/Makefile.inc | 1 + stand/kboot/kboot/Makefile | 69 ++++++++++++++++++++++ stand/kboot/{ => kboot}/arch/aarch64/Makefile.inc | 0 stand/kboot/{ => kboot}/arch/aarch64/exec.c | 0 stand/kboot/{ => kboot}/arch/aarch64/fdt_arch.c | 0 .../kboot/{ => kboot}/arch/aarch64/host_syscall.S | 0 .../{ => kboot}/arch/aarch64/ldscript.aarch64 | 0 stand/kboot/{ => kboot}/arch/aarch64/load_addr.c | 0 stand/kboot/{ => kboot}/arch/aarch64/start_arch.h | 0 stand/kboot/{ => kboot}/arch/aarch64/stat_arch.h | 0 stand/kboot/{ => kboot}/arch/aarch64/syscall_nr.h | 0 .../kboot/{ => kboot}/arch/aarch64/termios_arch.h | 0 stand/kboot/{ => kboot}/arch/aarch64/tramp.S | 0 stand/kboot/{ => kboot}/arch/amd64/Makefile.inc | 0 stand/kboot/{ => kboot}/arch/amd64/amd64_tramp.S | 0 stand/kboot/{ => kboot}/arch/amd64/elf64_freebsd.c | 0 stand/kboot/{ => kboot}/arch/amd64/fdt_arch.c | 0 stand/kboot/{ => kboot}/arch/amd64/host_syscall.S | 0 stand/kboot/{ => kboot}/arch/amd64/ldscript.amd64 | 0 stand/kboot/{ => kboot}/arch/amd64/load_addr.c | 0 stand/kboot/{ => kboot}/arch/amd64/multiboot2.h | 0 stand/kboot/{ => kboot}/arch/amd64/start_arch.h | 0 stand/kboot/{ => kboot}/arch/amd64/stat_arch.h | 0 stand/kboot/{ => kboot}/arch/amd64/syscall_nr.h | 0 stand/kboot/{ => kboot}/arch/amd64/termios_arch.h | 0 .../kboot/{ => kboot}/arch/powerpc64/Makefile.inc | 0 stand/kboot/{ => kboot}/arch/powerpc64/fdt_arch.c | 0 .../{ => kboot}/arch/powerpc64/host_syscall.S | 0 .../kboot/{ => kboot}/arch/powerpc64/kerneltramp.S | 0 .../{ => kboot}/arch/powerpc64/ldscript.powerpc | 0 stand/kboot/{ => kboot}/arch/powerpc64/load_addr.c | 0 .../{ => kboot}/arch/powerpc64/ppc64_elf_freebsd.c | 0 .../kboot/{ => kboot}/arch/powerpc64/start_arch.h | 0 stand/kboot/{ => kboot}/arch/powerpc64/stat_arch.h | 0 .../kboot/{ => kboot}/arch/powerpc64/syscall_nr.h | 0 .../{ => kboot}/arch/powerpc64/termios_arch.h | 0 stand/kboot/{ => kboot}/conf.c | 0 stand/kboot/{ => kboot}/crt1.c | 0 stand/kboot/{ => kboot}/host_syscall.h | 0 stand/kboot/{ => kboot}/host_syscalls.c | 0 stand/kboot/{ => kboot}/hostcons.c | 0 stand/kboot/{ => kboot}/hostdisk.c | 0 stand/kboot/{ => kboot}/hostfs.c | 0 stand/kboot/{ => kboot}/init.c | 0 stand/kboot/{ => kboot}/kboot.h | 0 stand/kboot/{ => kboot}/kbootfdt.c | 0 stand/kboot/{ => kboot}/main.c | 0 stand/kboot/{ => kboot}/seg.c | 0 stand/kboot/{ => kboot}/termios.c | 0 stand/kboot/{ => kboot}/termios.h | 0 stand/kboot/{ => kboot}/termios_gen.h | 0 stand/kboot/{ => kboot}/util.c | 0 stand/kboot/{ => kboot}/version | 0 54 files changed, 73 insertions(+), 65 deletions(-) diff --git a/stand/kboot/Makefile b/stand/kboot/Makefile index b9d68cddf97d..2e0b9d7a2e09 100644 --- a/stand/kboot/Makefile +++ b/stand/kboot/Makefile @@ -1,69 +1,7 @@ - -LOADER_DISK_SUPPORT?= yes -LOADER_CD9660_SUPPORT?= yes -LOADER_MSDOS_SUPPORT?= no -LOADER_EXT2FS_SUPPORT?= yes -LOADER_UFS_SUPPORT?= yes -LOADER_ZFS_SUPPORT?= yes -LOADER_NET_SUPPORT?= no -LOADER_NFS_SUPPORT?= no -LOADER_TFTP_SUPPORT?= no -LOADER_GZIP_SUPPORT?= no -LOADER_BZIP2_SUPPORT?= no +NO_OBJ=t .include -PROG= loader.kboot -NEWVERSWHAT= "kboot loader" ${MACHINE_ARCH} -INSTALLFLAGS= -b - -# Architecture-specific loader code -SRCS= \ - bootinfo.c \ - conf.c \ - crt1.c \ - gfx_fb_stub.c \ - host_syscalls.c \ - hostcons.c \ - hostdisk.c \ - hostfs.c \ - init.c \ - kbootfdt.c \ - main.c \ - seg.c \ - termios.c \ - util.c \ - vers.c - -CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken -.if ${MK_LOADER_ZFS} != "no" -CFLAGS+= -I${ZFSSRC} -CFLAGS+= -I${SYSDIR}/contrib/openzfs/include -CFLAGS+= -I${SYSDIR}/contrib/openzfs/include/os/freebsd/zfs -HAVE_ZFS=yes -.endif - -HELP_FILENAME= loader.help.kboot - -.include "${BOOTSRC}/fdt.mk" - -# We share bootinfo.c with efi -.PATH: ${BOOTSRC}/efi/loader - -# Note: Since we're producing a userland binary, we key off of MACHINE_ARCH -# instead of the more normal MACHINE since the changes between different flavors -# of MACHINE_ARCH are large enough in Linux that it's easier that way. -.PATH: ${.CURDIR}/arch/${MACHINE_ARCH} -.include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" - -# Always add MI sources -.include "${BOOTSRC}/loader.mk" -.PATH: ${SYSDIR}/libkern -CFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} - -CFLAGS+= -Wall - -DPADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} -LDADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} +SUBDIR+= kboot -.include +.include diff --git a/stand/kboot/Makefile.inc b/stand/kboot/Makefile.inc new file mode 100644 index 000000000000..01b5f23410c8 --- /dev/null +++ b/stand/kboot/Makefile.inc @@ -0,0 +1 @@ +.include "../Makefile.inc" diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile new file mode 100644 index 000000000000..b9d68cddf97d --- /dev/null +++ b/stand/kboot/kboot/Makefile @@ -0,0 +1,69 @@ + +LOADER_DISK_SUPPORT?= yes +LOADER_CD9660_SUPPORT?= yes +LOADER_MSDOS_SUPPORT?= no +LOADER_EXT2FS_SUPPORT?= yes +LOADER_UFS_SUPPORT?= yes +LOADER_ZFS_SUPPORT?= yes +LOADER_NET_SUPPORT?= no +LOADER_NFS_SUPPORT?= no +LOADER_TFTP_SUPPORT?= no +LOADER_GZIP_SUPPORT?= no +LOADER_BZIP2_SUPPORT?= no + +.include + +PROG= loader.kboot +NEWVERSWHAT= "kboot loader" ${MACHINE_ARCH} +INSTALLFLAGS= -b + +# Architecture-specific loader code +SRCS= \ + bootinfo.c \ + conf.c \ + crt1.c \ + gfx_fb_stub.c \ + host_syscalls.c \ + hostcons.c \ + hostdisk.c \ + hostfs.c \ + init.c \ + kbootfdt.c \ + main.c \ + seg.c \ + termios.c \ + util.c \ + vers.c + +CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken +.if ${MK_LOADER_ZFS} != "no" +CFLAGS+= -I${ZFSSRC} +CFLAGS+= -I${SYSDIR}/contrib/openzfs/include +CFLAGS+= -I${SYSDIR}/contrib/openzfs/include/os/freebsd/zfs +HAVE_ZFS=yes +.endif + +HELP_FILENAME= loader.help.kboot + +.include "${BOOTSRC}/fdt.mk" + +# We share bootinfo.c with efi +.PATH: ${BOOTSRC}/efi/loader + +# Note: Since we're producing a userland binary, we key off of MACHINE_ARCH +# instead of the more normal MACHINE since the changes between different flavors +# of MACHINE_ARCH are large enough in Linux that it's easier that way. +.PATH: ${.CURDIR}/arch/${MACHINE_ARCH} +.include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" + +# Always add MI sources +.include "${BOOTSRC}/loader.mk" +.PATH: ${SYSDIR}/libkern +CFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} + +CFLAGS+= -Wall + +DPADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} +LDADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} + +.include diff --git a/stand/kboot/arch/aarch64/Makefile.inc b/stand/kboot/kboot/arch/aarch64/Makefile.inc similarity index 100% rename from stand/kboot/arch/aarch64/Makefile.inc rename to stand/kboot/kboot/arch/aarch64/Makefile.inc diff --git a/stand/kboot/arch/aarch64/exec.c b/stand/kboot/kboot/arch/aarch64/exec.c similarity index 100% rename from stand/kboot/arch/aarch64/exec.c rename to stand/kboot/kboot/arch/aarch64/exec.c diff --git a/stand/kboot/arch/aarch64/fdt_arch.c b/stand/kboot/kboot/arch/aarch64/fdt_arch.c similarity index 100% rename from stand/kboot/arch/aarch64/fdt_arch.c rename to stand/kboot/kboot/arch/aarch64/fdt_arch.c diff --git a/stand/kboot/arch/aarch64/host_syscall.S b/stand/kboot/kboot/arch/aarch64/host_syscall.S similarity index 100% rename from stand/kboot/arch/aarch64/host_syscall.S rename to stand/kboot/kboot/arch/aarch64/host_syscall.S diff --git a/stand/kboot/arch/aarch64/ldscript.aarch64 b/stand/kboot/kboot/arch/aarch64/ldscript.aarch64 similarity index 100% rename from stand/kboot/arch/aarch64/ldscript.aarch64 rename to stand/kboot/kboot/arch/aarch64/ldscript.aarch64 diff --git a/stand/kboot/arch/aarch64/load_addr.c b/stand/kboot/kboot/arch/aarch64/load_addr.c similarity index 100% rename from stand/kboot/arch/aarch64/load_addr.c rename to stand/kboot/kboot/arch/aarch64/load_addr.c diff --git a/stand/kboot/arch/aarch64/start_arch.h b/stand/kboot/kboot/arch/aarch64/start_arch.h similarity index 100% rename from stand/kboot/arch/aarch64/start_arch.h rename to stand/kboot/kboot/arch/aarch64/start_arch.h diff --git a/stand/kboot/arch/aarch64/stat_arch.h b/stand/kboot/kboot/arch/aarch64/stat_arch.h similarity index 100% rename from stand/kboot/arch/aarch64/stat_arch.h rename to stand/kboot/kboot/arch/aarch64/stat_arch.h diff --git a/stand/kboot/arch/aarch64/syscall_nr.h b/stand/kboot/kboot/arch/aarch64/syscall_nr.h similarity index 100% rename from stand/kboot/arch/aarch64/syscall_nr.h rename to stand/kboot/kboot/arch/aarch64/syscall_nr.h diff --git a/stand/kboot/arch/aarch64/termios_arch.h b/stand/kboot/kboot/arch/aarch64/termios_arch.h similarity index 100% rename from stand/kboot/arch/aarch64/termios_arch.h rename to stand/kboot/kboot/arch/aarch64/termios_arch.h diff --git a/stand/kboot/arch/aarch64/tramp.S b/stand/kboot/kboot/arch/aarch64/tramp.S similarity index 100% rename from stand/kboot/arch/aarch64/tramp.S rename to stand/kboot/kboot/arch/aarch64/tramp.S diff --git a/stand/kboot/arch/amd64/Makefile.inc b/stand/kboot/kboot/arch/amd64/Makefile.inc similarity index 100% rename from stand/kboot/arch/amd64/Makefile.inc rename to stand/kboot/kboot/arch/amd64/Makefile.inc diff --git a/stand/kboot/arch/amd64/amd64_tramp.S b/stand/kboot/kboot/arch/amd64/amd64_tramp.S similarity index 100% rename from stand/kboot/arch/amd64/amd64_tramp.S rename to stand/kboot/kboot/arch/amd64/amd64_tramp.S diff --git a/stand/kboot/arch/amd64/elf64_freebsd.c b/stand/kboot/kboot/arch/amd64/elf64_freebsd.c similarity index 100% rename from stand/kboot/arch/amd64/elf64_freebsd.c rename to stand/kboot/kboot/arch/amd64/elf64_freebsd.c diff --git a/stand/kboot/arch/amd64/fdt_arch.c b/stand/kboot/kboot/arch/amd64/fdt_arch.c similarity index 100% rename from stand/kboot/arch/amd64/fdt_arch.c rename to stand/kboot/kboot/arch/amd64/fdt_arch.c diff --git a/stand/kboot/arch/amd64/host_syscall.S b/stand/kboot/kboot/arch/amd64/host_syscall.S similarity index 100% rename from stand/kboot/arch/amd64/host_syscall.S rename to stand/kboot/kboot/arch/amd64/host_syscall.S diff --git a/stand/kboot/arch/amd64/ldscript.amd64 b/stand/kboot/kboot/arch/amd64/ldscript.amd64 similarity index 100% rename from stand/kboot/arch/amd64/ldscript.amd64 rename to stand/kboot/kboot/arch/amd64/ldscript.amd64 diff --git a/stand/kboot/arch/amd64/load_addr.c b/stand/kboot/kboot/arch/amd64/load_addr.c similarity index 100% rename from stand/kboot/arch/amd64/load_addr.c rename to stand/kboot/kboot/arch/amd64/load_addr.c diff --git a/stand/kboot/arch/amd64/multiboot2.h b/stand/kboot/kboot/arch/amd64/multiboot2.h similarity index 100% rename from stand/kboot/arch/amd64/multiboot2.h rename to stand/kboot/kboot/arch/amd64/multiboot2.h diff --git a/stand/kboot/arch/amd64/start_arch.h b/stand/kboot/kboot/arch/amd64/start_arch.h similarity index 100% rename from stand/kboot/arch/amd64/start_arch.h rename to stand/kboot/kboot/arch/amd64/start_arch.h diff --git a/stand/kboot/arch/amd64/stat_arch.h b/stand/kboot/kboot/arch/amd64/stat_arch.h similarity index 100% rename from stand/kboot/arch/amd64/stat_arch.h rename to stand/kboot/kboot/arch/amd64/stat_arch.h diff --git a/stand/kboot/arch/amd64/syscall_nr.h b/stand/kboot/kboot/arch/amd64/syscall_nr.h similarity index 100% rename from stand/kboot/arch/amd64/syscall_nr.h rename to stand/kboot/kboot/arch/amd64/syscall_nr.h diff --git a/stand/kboot/arch/amd64/termios_arch.h b/stand/kboot/kboot/arch/amd64/termios_arch.h similarity index 100% rename from stand/kboot/arch/amd64/termios_arch.h rename to stand/kboot/kboot/arch/amd64/termios_arch.h diff --git a/stand/kboot/arch/powerpc64/Makefile.inc b/stand/kboot/kboot/arch/powerpc64/Makefile.inc similarity index 100% rename from stand/kboot/arch/powerpc64/Makefile.inc rename to stand/kboot/kboot/arch/powerpc64/Makefile.inc diff --git a/stand/kboot/arch/powerpc64/fdt_arch.c b/stand/kboot/kboot/arch/powerpc64/fdt_arch.c similarity index 100% rename from stand/kboot/arch/powerpc64/fdt_arch.c rename to stand/kboot/kboot/arch/powerpc64/fdt_arch.c diff --git a/stand/kboot/arch/powerpc64/host_syscall.S b/stand/kboot/kboot/arch/powerpc64/host_syscall.S similarity index 100% rename from stand/kboot/arch/powerpc64/host_syscall.S rename to stand/kboot/kboot/arch/powerpc64/host_syscall.S diff --git a/stand/kboot/arch/powerpc64/kerneltramp.S b/stand/kboot/kboot/arch/powerpc64/kerneltramp.S similarity index 100% rename from stand/kboot/arch/powerpc64/kerneltramp.S rename to stand/kboot/kboot/arch/powerpc64/kerneltramp.S diff --git a/stand/kboot/arch/powerpc64/ldscript.powerpc b/stand/kboot/kboot/arch/powerpc64/ldscript.powerpc similarity index 100% rename from stand/kboot/arch/powerpc64/ldscript.powerpc rename to stand/kboot/kboot/arch/powerpc64/ldscript.powerpc diff --git a/stand/kboot/arch/powerpc64/load_addr.c b/stand/kboot/kboot/arch/powerpc64/load_addr.c similarity index 100% rename from stand/kboot/arch/powerpc64/load_addr.c rename to stand/kboot/kboot/arch/powerpc64/load_addr.c diff --git a/stand/kboot/arch/powerpc64/ppc64_elf_freebsd.c b/stand/kboot/kboot/arch/powerpc64/ppc64_elf_freebsd.c similarity index 100% rename from stand/kboot/arch/powerpc64/ppc64_elf_freebsd.c rename to stand/kboot/kboot/arch/powerpc64/ppc64_elf_freebsd.c diff --git a/stand/kboot/arch/powerpc64/start_arch.h b/stand/kboot/kboot/arch/powerpc64/start_arch.h similarity index 100% rename from stand/kboot/arch/powerpc64/start_arch.h rename to stand/kboot/kboot/arch/powerpc64/start_arch.h diff --git a/stand/kboot/arch/powerpc64/stat_arch.h b/stand/kboot/kboot/arch/powerpc64/stat_arch.h similarity index 100% rename from stand/kboot/arch/powerpc64/stat_arch.h rename to stand/kboot/kboot/arch/powerpc64/stat_arch.h diff --git a/stand/kboot/arch/powerpc64/syscall_nr.h b/stand/kboot/kboot/arch/powerpc64/syscall_nr.h similarity index 100% rename from stand/kboot/arch/powerpc64/syscall_nr.h rename to stand/kboot/kboot/arch/powerpc64/syscall_nr.h diff --git a/stand/kboot/arch/powerpc64/termios_arch.h b/stand/kboot/kboot/arch/powerpc64/termios_arch.h similarity index 100% rename from stand/kboot/arch/powerpc64/termios_arch.h rename to stand/kboot/kboot/arch/powerpc64/termios_arch.h diff --git a/stand/kboot/conf.c b/stand/kboot/kboot/conf.c similarity index 100% rename from stand/kboot/conf.c rename to stand/kboot/kboot/conf.c diff --git a/stand/kboot/crt1.c b/stand/kboot/kboot/crt1.c similarity index 100% rename from stand/kboot/crt1.c rename to stand/kboot/kboot/crt1.c diff --git a/stand/kboot/host_syscall.h b/stand/kboot/kboot/host_syscall.h similarity index 100% rename from stand/kboot/host_syscall.h rename to stand/kboot/kboot/host_syscall.h diff --git a/stand/kboot/host_syscalls.c b/stand/kboot/kboot/host_syscalls.c similarity index 100% rename from stand/kboot/host_syscalls.c rename to stand/kboot/kboot/host_syscalls.c diff --git a/stand/kboot/hostcons.c b/stand/kboot/kboot/hostcons.c similarity index 100% rename from stand/kboot/hostcons.c rename to stand/kboot/kboot/hostcons.c diff --git a/stand/kboot/hostdisk.c b/stand/kboot/kboot/hostdisk.c similarity index 100% rename from stand/kboot/hostdisk.c rename to stand/kboot/kboot/hostdisk.c diff --git a/stand/kboot/hostfs.c b/stand/kboot/kboot/hostfs.c similarity index 100% rename from stand/kboot/hostfs.c rename to stand/kboot/kboot/hostfs.c diff --git a/stand/kboot/init.c b/stand/kboot/kboot/init.c similarity index 100% rename from stand/kboot/init.c rename to stand/kboot/kboot/init.c diff --git a/stand/kboot/kboot.h b/stand/kboot/kboot/kboot.h similarity index 100% rename from stand/kboot/kboot.h rename to stand/kboot/kboot/kboot.h diff --git a/stand/kboot/kbootfdt.c b/stand/kboot/kboot/kbootfdt.c similarity index 100% rename from stand/kboot/kbootfdt.c rename to stand/kboot/kboot/kbootfdt.c diff --git a/stand/kboot/main.c b/stand/kboot/kboot/main.c similarity index 100% rename from stand/kboot/main.c rename to stand/kboot/kboot/main.c diff --git a/stand/kboot/seg.c b/stand/kboot/kboot/seg.c similarity index 100% rename from stand/kboot/seg.c rename to stand/kboot/kboot/seg.c diff --git a/stand/kboot/termios.c b/stand/kboot/kboot/termios.c similarity index 100% rename from stand/kboot/termios.c rename to stand/kboot/kboot/termios.c diff --git a/stand/kboot/termios.h b/stand/kboot/kboot/termios.h similarity index 100% rename from stand/kboot/termios.h rename to stand/kboot/kboot/termios.h diff --git a/stand/kboot/termios_gen.h b/stand/kboot/kboot/termios_gen.h similarity index 100% rename from stand/kboot/termios_gen.h rename to stand/kboot/kboot/termios_gen.h diff --git a/stand/kboot/util.c b/stand/kboot/kboot/util.c similarity index 100% rename from stand/kboot/util.c rename to stand/kboot/kboot/util.c diff --git a/stand/kboot/version b/stand/kboot/kboot/version similarity index 100% rename from stand/kboot/version rename to stand/kboot/kboot/version From nobody Tue Apr 16 20:12:20 2024 X-Original-To: dev-commits-src-branches@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 4VJwF073XPz5HT4q; Tue, 16 Apr 2024 20:12:20 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF04dpQz4sCk; Tue, 16 Apr 2024 20:12:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298340; 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=+I7SO9lXLdUhAif6M42X+E/4/KvZeJy+0nG4+YrOVRg=; b=DwRZC1Ke5CiHnrioCON9zsBCE0d/Ttx8f7kGywHJpRplcKMvGOMarLJvSvWeaMKtlZZyVH snOAjIXa8IB9XmAbNdWKcz/tNhqJBEdewwe43uTqoZNlc7eT28gN2rBU1EnC5TzbHGdmTc E4ANU9NiAE9vlgIEFHRZMJZcGqekcAuPOvspHfWakfgjdWAxnZJCBtSTQfsMRvnjDa/Gs7 2rnTXnXmB7T37fcw3oGv1sR7XFwNH7P2ll4GBY/AYojJqHmf80D2wruvVu7LO94kWNWX6B qRIS7ByZxWXwickFQyoo40x0TGk05UNNC2vdZvRIs3YpgK9cD9g2IkmCB8wiDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298340; a=rsa-sha256; cv=none; b=MrQ/uovNZa85bV3t1yI7Lt0SG/HQ0Rz435o9oD3uLyE2ZPRQKwPYCyKY+NSdX31uyTo7W+ GPpw/KcdgHgZ6R5MQk8XHA+0x8uIPv4ZCUu4rBFa9Zbh3VessHNE3CYJ8V3aJTflnKSLoj Bbkpx+MUKZIDitnPi20plqr6Fp9+xx495OCpUbqmIj4JfoZ0vNlHJlhcg/jqsN36vMcpsJ fbqJaXIlOeF07KkfLN7sn46gG1T0yfW1x1o90+0cbGHO1Rtm/ToLPBexN6Wp8xdgZWDqNB Q1DHxdq1+vTtxNGNrBWTjt/gOHML10jj+E/Ynqvfs/rm0cMnV8fjAI9F7GiOqg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298340; 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=+I7SO9lXLdUhAif6M42X+E/4/KvZeJy+0nG4+YrOVRg=; b=LZJns+UD4+SOFvmq6TfQdHNySdEhRLCEv89XaFbC2dA4RxHE3ZZWr5R8DLf59tpCaqq4bn CfU9bCPZs2SzU5V4ZwzCd8Ay82pHpS0o8bvKLDW/Z5pXXHjwIdctr4RrskcR1j7RZ9HbRd R6QyDEZWoEg7j+0RnnmycsyD6n6TQ8vSTntGavvi54j5muU4G78ErtTOr+lN2nSQpaOnCq RFOo934gzQH5LJ8Fv9hmTAiKyxQjlRB80+wYbBAX6h+TYuUrl2UM9j8IHY3pJ3cwmr5idQ 393yLxYL3ccl/Abx8zpMyGaBle0QmiOkUvZssbDwiZtpTe5qECXwCSmnMDT2DQ== 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 4VJwF04FszzxWD; Tue, 16 Apr 2024 20:12:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCKY0036699; Tue, 16 Apr 2024 20:12:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCKR7036696; Tue, 16 Apr 2024 20:12:20 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:20 GMT Message-Id: <202404162012.43GKCKR7036696@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 93fa71ab2499 - stable/14 - kboot: Move _start out of kboot and into libkboot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 93fa71ab2499dcd8460d472d4b9911de120e2577 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=93fa71ab2499dcd8460d472d4b9911de120e2577 commit 93fa71ab2499dcd8460d472d4b9911de120e2577 Author: Warner Losh AuthorDate: 2024-01-28 18:53:59 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 kboot: Move _start out of kboot and into libkboot Move the startup code from kboot/kboot to kboot/libkboot and add the necessary infrastructure for it to build. move start_arch.h, a private header for libkboot, over as well. Sponsored by: Netflix (cherry picked from commit a03411e84728e9b267056fd31c7d1d9d1dc1b01e) --- stand/kboot/Makefile | 2 +- stand/kboot/Makefile.inc | 6 ++++++ stand/kboot/kboot/Makefile | 5 ++--- stand/kboot/libkboot/Makefile | 10 ++++++++++ stand/kboot/{kboot => libkboot}/arch/aarch64/start_arch.h | 0 stand/kboot/{kboot => libkboot}/arch/amd64/start_arch.h | 0 stand/kboot/{kboot => libkboot}/arch/powerpc64/start_arch.h | 0 stand/kboot/{kboot => libkboot}/crt1.c | 0 8 files changed, 19 insertions(+), 4 deletions(-) diff --git a/stand/kboot/Makefile b/stand/kboot/Makefile index 2e0b9d7a2e09..72dbabc00568 100644 --- a/stand/kboot/Makefile +++ b/stand/kboot/Makefile @@ -2,6 +2,6 @@ NO_OBJ=t .include -SUBDIR+= kboot +SUBDIR+= libkboot .WAIT kboot .include diff --git a/stand/kboot/Makefile.inc b/stand/kboot/Makefile.inc index 01b5f23410c8..02aecdad55f1 100644 --- a/stand/kboot/Makefile.inc +++ b/stand/kboot/Makefile.inc @@ -1 +1,7 @@ +# Bring in the mini-libc that we wrote + +KBOOTSRC=${BOOTSRC}/kboot +CFLAGS+=-I${KBOOTSRC}/include +LIBKBOOT=${BOOTOBJ}/kboot/libkboot/libkboot.a + .include "../Makefile.inc" diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index b9d68cddf97d..4054bb1da9f2 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -21,7 +21,6 @@ INSTALLFLAGS= -b SRCS= \ bootinfo.c \ conf.c \ - crt1.c \ gfx_fb_stub.c \ host_syscalls.c \ hostcons.c \ @@ -63,7 +62,7 @@ CFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} CFLAGS+= -Wall -DPADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} -LDADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} +DPADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} ${LIBKBOOT} +LDADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} ${LIBKBOOT} .include diff --git a/stand/kboot/libkboot/Makefile b/stand/kboot/libkboot/Makefile new file mode 100644 index 000000000000..415571617d2a --- /dev/null +++ b/stand/kboot/libkboot/Makefile @@ -0,0 +1,10 @@ +.include + +LIB= kboot +WARNS?= 4 + +CFLAGS+=-I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} + +SRCS= crt1.c + +.include diff --git a/stand/kboot/kboot/arch/aarch64/start_arch.h b/stand/kboot/libkboot/arch/aarch64/start_arch.h similarity index 100% rename from stand/kboot/kboot/arch/aarch64/start_arch.h rename to stand/kboot/libkboot/arch/aarch64/start_arch.h diff --git a/stand/kboot/kboot/arch/amd64/start_arch.h b/stand/kboot/libkboot/arch/amd64/start_arch.h similarity index 100% rename from stand/kboot/kboot/arch/amd64/start_arch.h rename to stand/kboot/libkboot/arch/amd64/start_arch.h diff --git a/stand/kboot/kboot/arch/powerpc64/start_arch.h b/stand/kboot/libkboot/arch/powerpc64/start_arch.h similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/start_arch.h rename to stand/kboot/libkboot/arch/powerpc64/start_arch.h diff --git a/stand/kboot/kboot/crt1.c b/stand/kboot/libkboot/crt1.c similarity index 100% rename from stand/kboot/kboot/crt1.c rename to stand/kboot/libkboot/crt1.c From nobody Tue Apr 16 20:12:21 2024 X-Original-To: dev-commits-src-branches@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 4VJwF21MmPz5H00T; Tue, 16 Apr 2024 20:12:22 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF15brYz4s8y; Tue, 16 Apr 2024 20:12:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298341; 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=KsaiZyMx/96MZWAeqvCKqog9xMpRn/5jbnpk5hGTZV8=; b=H53iNTg8dlLIOXtx4pwEJEWMfHmv/thMMY35g7xDruoiqfyWP0hEZ9P8PnlVKdayikgzTN e6dtSLK6YBgLxU9IuRiM9PCFP5sf3X5SAEsHT+DkY33wmjVMdrlsSfOfqD8irm27uBR3Wy r/NsUReij0iDjcTs0UMhu1ZiWqzZYeQt0DuNmK9SE2bTIl8BbTQVUXsQE3I/HKxriktqoz xVZqZhBPanlZulzZ4VIUBd1GILFQcQ9aDgs0kTDqu3S2Y5cs9MOq4ARrxDkgF25J2NcH5C pVsivVW7Zi7mzb423xQMLpsUJW+6oq93+S0v3VmrHVbVJWI/jaS+IJaCpY9zXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298341; a=rsa-sha256; cv=none; b=KRU5GYOJl893Sd6NJV8p480PafCV5vJrG2U9/H3Pni+x2SoHjQa+Y/ll5tjBS65dOS8nci AE14KUVw5zyI/nt9CEYI9XqSf1C0h9Nl6T0iAp0hKKH7jKYzlUixCvbwzDzSlfiUMG53ON 2wZspKGIpwV5OZlEu+pJR7pGASZAwW5DhyfzRMDEciaLHNV+wtgUjzaJ/Q/dvahyfKT0tf XZKaHRPoM4bSz5+0fU+h9LsBBjqW+PR0LaubNdmmDBQA3U08HGmqE2cmdYgahBTpSKmi39 7RGwSBBQO/jzLhgVxQ9Lle1TgXnCJdMk4pMeqJnEcJY9h5WyxiEloVpSxDenWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298341; 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=KsaiZyMx/96MZWAeqvCKqog9xMpRn/5jbnpk5hGTZV8=; b=KGIj4MnYoBYH5mxqH22EvNE47d0F+Epxd3cFRVESX3ysasJMgqzItYkd2zOpE0lBUshP5k HRlcx9nlHfroCGVKCr+/aE0wPxJf5urC+I4WQcOAg/LP0ZJHup6jQQQmsKEgNb85aEgckb 129I2SouOOwxzyY4wpb8qzLj5oRFXKaG4lI+R0/UoJupxUF8rT0FI16up9SoL0OTxvvmY5 RsEv+hIGwpzyNCShO9DUi00X9nxkHoiCkou1RKOmJ2LYwuoexjCnxEexVWTsyS3qOAegny zWgLQglT1YGQscn9XtwDEHAMU4P6umuLpzRIZ94hRbRBwVCGBSG/aZlok8+u1Q== 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 4VJwF15DHczxdR; Tue, 16 Apr 2024 20:12:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCLWi036747; Tue, 16 Apr 2024 20:12:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCLhM036744; Tue, 16 Apr 2024 20:12:21 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:21 GMT Message-Id: <202404162012.43GKCLhM036744@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: edf8a9a42d30 - stable/14 - kboot: Cleanup libkern reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: edf8a9a42d3057f701228f37e73c0c551a47225e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=edf8a9a42d3057f701228f37e73c0c551a47225e commit edf8a9a42d3057f701228f37e73c0c551a47225e Author: Warner Losh AuthorDate: 2024-01-28 18:28:05 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 kboot: Cleanup libkern reference For aarch64 and amd64, we don't pull in anything from libkern, so we don't need it in our path. However, powerpc needs ucmpdi2 from libkern, so bring it into libkboot's build and omit it from loader.kboot. Sponsored by: Netflix (cherry picked from commit 4aabaa1890e927ed3dd34ccc4642268ea6a505ce) --- stand/kboot/kboot/Makefile | 1 - stand/kboot/kboot/arch/powerpc64/Makefile.inc | 3 +-- stand/kboot/libkboot/Makefile | 2 ++ stand/kboot/libkboot/arch/powerpc64/Makefile.inc | 4 ++++ 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index 4054bb1da9f2..ae32d878a3f4 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -57,7 +57,6 @@ HELP_FILENAME= loader.help.kboot # Always add MI sources .include "${BOOTSRC}/loader.mk" -.PATH: ${SYSDIR}/libkern CFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} CFLAGS+= -Wall diff --git a/stand/kboot/kboot/arch/powerpc64/Makefile.inc b/stand/kboot/kboot/arch/powerpc64/Makefile.inc index c29e69970505..338d1222ab65 100644 --- a/stand/kboot/kboot/arch/powerpc64/Makefile.inc +++ b/stand/kboot/kboot/arch/powerpc64/Makefile.inc @@ -1,7 +1,6 @@ CFLAGS+= -mcpu=powerpc64 -SRCS+= ppc64_elf_freebsd.c host_syscall.S kerneltramp.S load_addr.c fdt_arch.c -SRCS+= ucmpdi2.c +SRCS+= ppc64_elf_freebsd.c kerneltramp.S load_addr.c fdt_arch.c LDFLAGS= -nostdlib -static -T ${.CURDIR}/arch/${MACHINE_ARCH}/ldscript.powerpc diff --git a/stand/kboot/libkboot/Makefile b/stand/kboot/libkboot/Makefile index 415571617d2a..1b030ccfe018 100644 --- a/stand/kboot/libkboot/Makefile +++ b/stand/kboot/libkboot/Makefile @@ -7,4 +7,6 @@ CFLAGS+=-I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} SRCS= crt1.c +.sinclude "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" + .include diff --git a/stand/kboot/libkboot/arch/powerpc64/Makefile.inc b/stand/kboot/libkboot/arch/powerpc64/Makefile.inc new file mode 100644 index 000000000000..4cafaee28847 --- /dev/null +++ b/stand/kboot/libkboot/arch/powerpc64/Makefile.inc @@ -0,0 +1,4 @@ +CFLAGS+= -mcpu=powerpc64 + +.PATH: ${SYSDIR}/libkern +SRCS+= ucmpdi2.c From nobody Tue Apr 16 20:12:23 2024 X-Original-To: dev-commits-src-branches@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 4VJwF42D1Nz5HT4t; Tue, 16 Apr 2024 20:12:24 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF40kxMz4s4x; Tue, 16 Apr 2024 20:12:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298344; 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=R5AFlX90EFBcbJVOgL0L4J4f0+bSFz1JO9PhGb0BQ/0=; b=S+VR/dcfjh2w9K1BUG1CtAK/MxTqUSoUYIFWdqKiPJePw412TuVPx+pzzKUyftmdupRypN wMwV7bUR+GNdegWu0MVtuoXErmhx4iLPGC5L10LV5TKplIgqIdcbf+w7C3b3xKExpnBOfp yilpuGslE46O0/jgJ84lg5NE+z74KZbWD3/BihEbpIldrzIDqq6hClb982k8mi7AMSwLOi 8eNrFpKfRGuR/QIZq5hOiP/y1W2z5XiwnB16DdIfClveDchlkzAK/iTluaWLBeUUhEWJ2g lonYl45zrMwQpn7GnTgwsstu27mjgVPESq49b/MIdpVRirpdtreskz8ckppggQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298344; a=rsa-sha256; cv=none; b=JoqAXMek41DfbDDM3jrL8d8sWBOdFCtPWM+vZqMRasgySzJo6P0zuU1PfWMLFQmzPI+cV7 bS3M4oTV9z1RXEWxQVRoym7pI/Ma4xAtcJK9egWp4221wuCFrhq5Ktu+N0bcXBZPEUTT3g 6VGKf0dSYk4jiCaMLF2AqQ5FcweA+6KPXTUY0wtO+wtom4y4Ip5BR9xcK1kl0lH3koWhVd nsvQbjoojDc9lyCiEwIk8xJJLZmj4smU8HDtE0tzXymdVSCkSm0QoTexTHmqJGmovr3M8y FjHGW768UM25r2c10kuuuJor9KSSOq4G12+v0/QAJgj0HI2n8eHdehgBe9bYbw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298344; 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=R5AFlX90EFBcbJVOgL0L4J4f0+bSFz1JO9PhGb0BQ/0=; b=IuGByOoKFGm7s6OjtqsYnVv8ZOtuDGN7IoNx2vNuNO2NomIWTIDeLJxQ9WuVh0KFW4NIL/ 5maRG0+wEVEGFyGPVg+7lrdv5Ndox8Aas3VWRQAaZsuuzf16YBwxpyg88DwFk7YIKsVO4u pfVSSAyLjBOf5XhbEO499ToIVIi7lf9ONdcALU4OUqtd3HKzhCH4JrQ3cjJ2NK8VZWJ9Ly 3zc9c5zaz1fpJRa3FFAdLKUqrfZMphHPQEDNfWV+bqtDUP/PwtPjOQSwLZ64DtsTOC7dcW 3B7KBgYb30XcyfRXu1QoS8VtvUH25TmNw1KSzQ+O0UsoroM5MrRIWiycqtmP7w== 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 4VJwF408lVzxPJ; Tue, 16 Apr 2024 20:12:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCNHS036845; Tue, 16 Apr 2024 20:12:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCNdS036842; Tue, 16 Apr 2024 20:12:23 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:23 GMT Message-Id: <202404162012.43GKCNdS036842@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 29f9f6b9800d - stable/14 - kboot: Move system calls to libkboot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 29f9f6b9800d721330d8326a60780077b1d3779e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=29f9f6b9800d721330d8326a60780077b1d3779e commit 29f9f6b9800d721330d8326a60780077b1d3779e Author: Warner Losh AuthorDate: 2024-01-28 19:08:45 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 kboot: Move system calls to libkboot Sponsored by: Netflix (cherry picked from commit 2e3f49888ec8851bafb22011533217487764fdb0) --- stand/kboot/Makefile.inc | 2 +- stand/kboot/{kboot => include}/arch/aarch64/stat_arch.h | 0 stand/kboot/{kboot => include}/arch/aarch64/syscall_nr.h | 0 stand/kboot/{kboot => include}/arch/amd64/stat_arch.h | 0 stand/kboot/{kboot => include}/arch/amd64/syscall_nr.h | 0 stand/kboot/{kboot => include}/arch/powerpc64/stat_arch.h | 0 stand/kboot/{kboot => include}/arch/powerpc64/syscall_nr.h | 0 stand/kboot/{kboot => include}/host_syscall.h | 0 stand/kboot/kboot/Makefile | 1 - stand/kboot/libkboot/Makefile | 3 ++- stand/kboot/{kboot => libkboot}/host_syscalls.c | 0 11 files changed, 3 insertions(+), 3 deletions(-) diff --git a/stand/kboot/Makefile.inc b/stand/kboot/Makefile.inc index 02aecdad55f1..90a1b9a17e3e 100644 --- a/stand/kboot/Makefile.inc +++ b/stand/kboot/Makefile.inc @@ -1,7 +1,7 @@ # Bring in the mini-libc that we wrote KBOOTSRC=${BOOTSRC}/kboot -CFLAGS+=-I${KBOOTSRC}/include +CFLAGS+=-I${KBOOTSRC}/include -I${KBOOTSRC}/include/arch/${MACHINE_ARCH} LIBKBOOT=${BOOTOBJ}/kboot/libkboot/libkboot.a .include "../Makefile.inc" diff --git a/stand/kboot/kboot/arch/aarch64/stat_arch.h b/stand/kboot/include/arch/aarch64/stat_arch.h similarity index 100% rename from stand/kboot/kboot/arch/aarch64/stat_arch.h rename to stand/kboot/include/arch/aarch64/stat_arch.h diff --git a/stand/kboot/kboot/arch/aarch64/syscall_nr.h b/stand/kboot/include/arch/aarch64/syscall_nr.h similarity index 100% rename from stand/kboot/kboot/arch/aarch64/syscall_nr.h rename to stand/kboot/include/arch/aarch64/syscall_nr.h diff --git a/stand/kboot/kboot/arch/amd64/stat_arch.h b/stand/kboot/include/arch/amd64/stat_arch.h similarity index 100% rename from stand/kboot/kboot/arch/amd64/stat_arch.h rename to stand/kboot/include/arch/amd64/stat_arch.h diff --git a/stand/kboot/kboot/arch/amd64/syscall_nr.h b/stand/kboot/include/arch/amd64/syscall_nr.h similarity index 100% rename from stand/kboot/kboot/arch/amd64/syscall_nr.h rename to stand/kboot/include/arch/amd64/syscall_nr.h diff --git a/stand/kboot/kboot/arch/powerpc64/stat_arch.h b/stand/kboot/include/arch/powerpc64/stat_arch.h similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/stat_arch.h rename to stand/kboot/include/arch/powerpc64/stat_arch.h diff --git a/stand/kboot/kboot/arch/powerpc64/syscall_nr.h b/stand/kboot/include/arch/powerpc64/syscall_nr.h similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/syscall_nr.h rename to stand/kboot/include/arch/powerpc64/syscall_nr.h diff --git a/stand/kboot/kboot/host_syscall.h b/stand/kboot/include/host_syscall.h similarity index 100% rename from stand/kboot/kboot/host_syscall.h rename to stand/kboot/include/host_syscall.h diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index ae32d878a3f4..475f863b77bd 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -22,7 +22,6 @@ SRCS= \ bootinfo.c \ conf.c \ gfx_fb_stub.c \ - host_syscalls.c \ hostcons.c \ hostdisk.c \ hostfs.c \ diff --git a/stand/kboot/libkboot/Makefile b/stand/kboot/libkboot/Makefile index 31f4827e64b9..33674da83661 100644 --- a/stand/kboot/libkboot/Makefile +++ b/stand/kboot/libkboot/Makefile @@ -7,7 +7,8 @@ WARNS?= 4 CFLAGS+=-I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} SRCS= crt1.c \ - host_syscall.S + host_syscall.S \ + host_syscalls.c .sinclude "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" diff --git a/stand/kboot/kboot/host_syscalls.c b/stand/kboot/libkboot/host_syscalls.c similarity index 100% rename from stand/kboot/kboot/host_syscalls.c rename to stand/kboot/libkboot/host_syscalls.c From nobody Tue Apr 16 20:12:22 2024 X-Original-To: dev-commits-src-branches@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 4VJwF32gQwz5H00X; Tue, 16 Apr 2024 20:12:23 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF26h0Fz4s97; Tue, 16 Apr 2024 20:12:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298343; 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=aHtVrR0oIEwEQCThtNqh6Nhs/Q8QHGD4bNXn4sxGhFM=; b=P1hxnHBhOKDQfNvD3a2Z51yS3Dnx3YruLFge/pfmEdPPvTDVrwbCv/q28QrQhWHjks98HY nMdNvXB/m6fw7fKY06S1TfI7LVuCTArAQJhQKt5RWud1LtrXIIg0IBTAPLMlGobpDJ7lL/ MLwUNnSo7DNcwebtokPwgFyAwd4YJlKxqpA9KCOZYHpeIn5inDNiiUPGUbksHsg9pON5QD KkzpBzLKhr/l9s68FypYaQTrJPO3Kwa0UivUHwd8aFMqbo4z7/8D0vuNchhKb8fcMKmAIZ a/gFxsKZWEBlcGFu+WKxXzq0UmJNiJv4Rdxrb2UgIllFLlIvzoFTMNX+6sPvsA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298343; a=rsa-sha256; cv=none; b=X//EZf7e+rDK/eaXIOAFnGx7zrATDARufuVzA+M8A64vOTuMrNyu/Q3YpFCyM/vF3rfFC2 A0Yy87Ow57hG4QRdM59BMUxOPj/HOEHC44jY8M32VX0SB64w/MrUvA9YvFx5joJBsYBsgZ jYpjG2QvXhfyR8GH/B8ZuvqEz4S2WQEDKWrUS+4+43e6nDbXo8WN5DRdNW7fznDAPZkz3g j9+Z0dysSP6EFlIy5RSY3SqAN2N/2o/FSWHMZMnqJ2qVt04C6XVgNYx5Rz8uhDSAWzXOSQ DwJb7Ksdju8AT7iA5koacqbktSfaKQDUt/CHvdt5/gYQQpu5EKHFSjjims9GBw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298343; 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=aHtVrR0oIEwEQCThtNqh6Nhs/Q8QHGD4bNXn4sxGhFM=; b=YF8hsW081wPEAjqIEDcd8tGQdBZUFBNreaE5nA0Pnyzw4AGeCnZJDl8ogire2ZZpwnXtwU 9MPMfTBb694SSgshM4oSLE9SQgnk+uTjLmwp+zOrYQx85q/Ch0R8A5sfWwXO+zViIG0waM FpEfCYZfPTcaAepX7a30tlvMDa9wn88hc48XOSSjwbUIPQ9a9xWy1YgECV1MEcmdi2/Zk2 NesrjGH8vmY8dG1lCSG9MOGuaEkSEcptauFXLd6yAcaE4hQZTuiccKyZlVWbK1Ihjs/3rj 99KQbHtw6vo95zJTZhncMWPLmRcIUlV3ihvMBXWL1SiYim6CNkcPB2FLwTbfMg== 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 4VJwF26CbCzxdS; Tue, 16 Apr 2024 20:12:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCM77036800; Tue, 16 Apr 2024 20:12:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCMDk036797; Tue, 16 Apr 2024 20:12:22 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:22 GMT Message-Id: <202404162012.43GKCMDk036797@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 78f3a2d48ebd - stable/14 - kboot: Move syscall stubs to libkboot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 78f3a2d48ebd004d209f395ac84bc5c5e081b228 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=78f3a2d48ebd004d209f395ac84bc5c5e081b228 commit 78f3a2d48ebd004d209f395ac84bc5c5e081b228 Author: Warner Losh AuthorDate: 2024-01-28 19:34:13 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:20 +0000 kboot: Move syscall stubs to libkboot Sponsored by: Netflix (cherry picked from commit 099335814d5aafefb3603b1a0901a1432895455c) --- stand/kboot/kboot/arch/aarch64/Makefile.inc | 2 +- stand/kboot/kboot/arch/amd64/Makefile.inc | 2 +- stand/kboot/libkboot/Makefile | 4 +++- stand/kboot/{kboot => libkboot}/arch/aarch64/host_syscall.S | 0 stand/kboot/{kboot => libkboot}/arch/amd64/host_syscall.S | 0 stand/kboot/{kboot => libkboot}/arch/powerpc64/host_syscall.S | 0 6 files changed, 5 insertions(+), 3 deletions(-) diff --git a/stand/kboot/kboot/arch/aarch64/Makefile.inc b/stand/kboot/kboot/arch/aarch64/Makefile.inc index 50388d38dbf2..744a15f363d3 100644 --- a/stand/kboot/kboot/arch/aarch64/Makefile.inc +++ b/stand/kboot/kboot/arch/aarch64/Makefile.inc @@ -1,4 +1,4 @@ -SRCS+= host_syscall.S tramp.S exec.c load_addr.c fdt_arch.c +SRCS+= tramp.S exec.c load_addr.c fdt_arch.c .PATH: ${BOOTSRC}/arm64/libarm64 CFLAGS+=-I${BOOTSRC}/arm64/libarm64 diff --git a/stand/kboot/kboot/arch/amd64/Makefile.inc b/stand/kboot/kboot/arch/amd64/Makefile.inc index fdd40fe9bc5a..55b1819ccdee 100644 --- a/stand/kboot/kboot/arch/amd64/Makefile.inc +++ b/stand/kboot/kboot/arch/amd64/Makefile.inc @@ -1,4 +1,4 @@ -SRCS+= host_syscall.S amd64_tramp.S elf64_freebsd.c load_addr.c fdt_arch.c +SRCS+= amd64_tramp.S elf64_freebsd.c load_addr.c fdt_arch.c CFLAGS+= -I${SYSDIR}/contrib/dev/acpica/include diff --git a/stand/kboot/libkboot/Makefile b/stand/kboot/libkboot/Makefile index 1b030ccfe018..31f4827e64b9 100644 --- a/stand/kboot/libkboot/Makefile +++ b/stand/kboot/libkboot/Makefile @@ -3,9 +3,11 @@ LIB= kboot WARNS?= 4 +.PATH: ${.CURDIR}/arch/${MACHINE_ARCH} CFLAGS+=-I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} -SRCS= crt1.c +SRCS= crt1.c \ + host_syscall.S .sinclude "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" diff --git a/stand/kboot/kboot/arch/aarch64/host_syscall.S b/stand/kboot/libkboot/arch/aarch64/host_syscall.S similarity index 100% rename from stand/kboot/kboot/arch/aarch64/host_syscall.S rename to stand/kboot/libkboot/arch/aarch64/host_syscall.S diff --git a/stand/kboot/kboot/arch/amd64/host_syscall.S b/stand/kboot/libkboot/arch/amd64/host_syscall.S similarity index 100% rename from stand/kboot/kboot/arch/amd64/host_syscall.S rename to stand/kboot/libkboot/arch/amd64/host_syscall.S diff --git a/stand/kboot/kboot/arch/powerpc64/host_syscall.S b/stand/kboot/libkboot/arch/powerpc64/host_syscall.S similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/host_syscall.S rename to stand/kboot/libkboot/arch/powerpc64/host_syscall.S From nobody Tue Apr 16 20:12:25 2024 X-Original-To: dev-commits-src-branches@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 4VJwF552QNz5H03B; Tue, 16 Apr 2024 20:12:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF51nVvz4sSB; Tue, 16 Apr 2024 20:12:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298345; 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=duCsTQK2GT7/sPof+1x42osiAcfQ/Y6ds1DS69Wg8iU=; b=bP1rs6SYCChejqU6YeOZAPdVEqWExB83d/e6W38cP3SUkYqvnLl8ovflw+H7gCBUWt0LCx 5XB7UcsHauookgu/D5pGICfK4VJXb6P88mkR2mdv9pbbuj1zYu7MvEJs4kSzdczSnNF3oz 2W6LTpDNu5C+brREfR9ignIVBUUZICPoZuJ9xLe3ZHPmFSYQEeeNjcYMk6FYTVJoLFYSO7 3tBPy1faMsJdxVcyE/Vm1YgWzRhLZCcJccNz8jUCz86Z9h+GY0xgNIbGIwZlvH4mv7GPZa ud3SF/yMr6IG9T8+1AsttL6RlGMmOKrFHfWvWr0NSnU6L6X1ZAd+VwKa3ywrJQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298345; a=rsa-sha256; cv=none; b=EGa4Pq2EnxcVu4kFGwb7yE8szqkhm7pG4w5U8p2qGkqD+W6IxOLHqyI0kJ5zWOuqfagroz u7uodLJlv6jy/+g/t8ZIptQW6eRr55MVkboyfR9XL8G/6bHjy3HH/ywJ73gmFVOFMdnpKi B0h6Pr9B1iiSAFFFxSjcUyvsm+AaQCouMXJ6C37Z24KWBSoYGiPENExTwymjcQXWU9dLOj kbk4smaSXuSdbCGYAWzZ+GnKmz5Aw+AqP/EkZT7wq/lh9ARgF+KjhuIGQ9HS7EGeguchlM jokeaAn00lnzWB81nwesbPneYPzalN7smWlpO3C7KH6zESty7qIEJ4VgIQFmsw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298345; 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=duCsTQK2GT7/sPof+1x42osiAcfQ/Y6ds1DS69Wg8iU=; b=NrjhQmbxNCJGHtOTYNCJuE2G5+VbXKVO0YVB5SlDodY5MtlPgk/4ClYhclRuoaVCfcWztJ 9hWNFUUP1Ki1p1fvnksRDh1zWz/skDNrnokh+6fK7qiNhSQ4ilVhsTRVxyLuOEYOv0+3fu GRKfqB6WLuGRrpUvCd8kOy+dadovH0UDGhEg4jAoqRMgi/aftp1Z4A1Vx/4PQtIv/qf9/8 Dag9Q3xO0u9G+x7teexC3MA5Ukmxb0gE5XXPFtaCTBPx4C6r6dci8qsn+mLRBIskujyF2L TzVTQIACsnLvp5eyJLChYaybAzrdo38K/Lo2hikF5tk4fvH6xk86h2CyvT1TGA== 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 4VJwF518jkzww8; Tue, 16 Apr 2024 20:12:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCPB8036887; Tue, 16 Apr 2024 20:12:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCPKr036884; Tue, 16 Apr 2024 20:12:25 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:25 GMT Message-Id: <202404162012.43GKCPKr036884@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: df6ae1140005 - stable/14 - kboot: Move termios to libkboot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: df6ae1140005f9ac821d85f9ef6c6895e69c6b0b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=df6ae1140005f9ac821d85f9ef6c6895e69c6b0b commit df6ae1140005f9ac821d85f9ef6c6895e69c6b0b Author: Warner Losh AuthorDate: 2024-01-28 19:28:30 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 kboot: Move termios to libkboot Sponsored by: Netflix (cherry picked from commit 36ef238cb604c827c696e975281f63d90641005f) --- stand/kboot/{kboot => include}/arch/aarch64/termios_arch.h | 0 stand/kboot/{kboot => include}/arch/amd64/termios_arch.h | 0 stand/kboot/{kboot => include}/arch/powerpc64/termios_arch.h | 0 stand/kboot/{kboot => include}/termios.h | 0 stand/kboot/{kboot => include}/termios_gen.h | 0 stand/kboot/kboot/Makefile | 1 - stand/kboot/libkboot/Makefile | 3 ++- stand/kboot/{kboot => libkboot}/termios.c | 0 8 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/kboot/kboot/arch/aarch64/termios_arch.h b/stand/kboot/include/arch/aarch64/termios_arch.h similarity index 100% rename from stand/kboot/kboot/arch/aarch64/termios_arch.h rename to stand/kboot/include/arch/aarch64/termios_arch.h diff --git a/stand/kboot/kboot/arch/amd64/termios_arch.h b/stand/kboot/include/arch/amd64/termios_arch.h similarity index 100% rename from stand/kboot/kboot/arch/amd64/termios_arch.h rename to stand/kboot/include/arch/amd64/termios_arch.h diff --git a/stand/kboot/kboot/arch/powerpc64/termios_arch.h b/stand/kboot/include/arch/powerpc64/termios_arch.h similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/termios_arch.h rename to stand/kboot/include/arch/powerpc64/termios_arch.h diff --git a/stand/kboot/kboot/termios.h b/stand/kboot/include/termios.h similarity index 100% rename from stand/kboot/kboot/termios.h rename to stand/kboot/include/termios.h diff --git a/stand/kboot/kboot/termios_gen.h b/stand/kboot/include/termios_gen.h similarity index 100% rename from stand/kboot/kboot/termios_gen.h rename to stand/kboot/include/termios_gen.h diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index 475f863b77bd..055027b85eb2 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -29,7 +29,6 @@ SRCS= \ kbootfdt.c \ main.c \ seg.c \ - termios.c \ util.c \ vers.c diff --git a/stand/kboot/libkboot/Makefile b/stand/kboot/libkboot/Makefile index 33674da83661..d9ce08cb0856 100644 --- a/stand/kboot/libkboot/Makefile +++ b/stand/kboot/libkboot/Makefile @@ -8,7 +8,8 @@ CFLAGS+=-I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} SRCS= crt1.c \ host_syscall.S \ - host_syscalls.c + host_syscalls.c \ + termios.c .sinclude "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" diff --git a/stand/kboot/kboot/termios.c b/stand/kboot/libkboot/termios.c similarity index 100% rename from stand/kboot/kboot/termios.c rename to stand/kboot/libkboot/termios.c From nobody Tue Apr 16 20:12:27 2024 X-Original-To: dev-commits-src-branches@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 4VJwF74X6nz5HT4y; Tue, 16 Apr 2024 20:12:27 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF73NGQz4sZk; Tue, 16 Apr 2024 20:12:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298347; 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=XDr+lpxRuOWK/rinmy9nQqThEehqrIAh2tM8afDy66M=; b=wrneWocPUPQVeoT8bmj8xcyu2Qd7eZfeNtchvNWyGs7wQDRwaTeOL9UVeZjegQt/cl/Vpi ZuACjIOBtX39/tgHRo2pA23HE5PAdA+FXSticZ+0XSYaouGV/73oPhjg0DIuY9b8mwBKzo b0OhPQYI6zllneMU7vn36NF0SAYK5+MRYUGfwFG7+qiKSSVuf7ghWvBJEcfHZFLQD262XA NNMUK9iLF2+MC/las1LgXO2IgP4pbBwdTGO0GxUrURAkABOBLHmCwrHpbx9x5V7WDkGd7V cU9DYsSY77/eXF5aT7xTThimBWb567RNTMZhMhT9AJG5DxEBuIjVOgUNg6AfYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298347; a=rsa-sha256; cv=none; b=TQlcltwN9D2vXc5+0P9SHzqAdF0zWeiHEGIuCA00GAXoc8sJcZvww+SCL+KzDGcjgALC1R jjy3RuqIzNWxAPfsG88caD4EksavmYrI7Qa0LfUCA9lIa0TeZuJwUNT5dYljPNHa3Es/f+ VY5+2cono9qBhWCnX3JcUThc528XYAK9xBtH17GCCkg9r/tFwV6FYy1lAcF7o1SrNIYOES 2Fa+ZSZkov3WOXzx7aiy0Hw4R3PRq7Z4EDycuyX5ifXFz1PH4LP/8Ag5vZDXEbll/nZpPg 9iIwJYhqc9IWYjaSow7rOSMaQ1h+ODgBkmMmVPCEt2IfwujwOb9vUwnVHu2X4w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298347; 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=XDr+lpxRuOWK/rinmy9nQqThEehqrIAh2tM8afDy66M=; b=qcOGght/YHsImxU34x0lGCmQFvZHviNAv4ynH3ww2e1ghVGw7tr2Kjno5Gt1YydOfb1T57 gEy5UioVgL/DmbdRb2/iX0vqT7oJDVTisueefvvOdyerpvrwTbc4k21Xg1WtU+rdMv8/JU VPzUy1kZV5jT+gsEcRxwRE64mN3lONbXDoiC9Y+D94AMQsDhEuIJ6EOMuuyqf6LJp7oZpn iuo+qrbRdKfhfSAOQvHHjKovnKJiIaG75bGjAbAhvmOiavID92Zn8V6jZwW+z8bUn0Q64n b2kPw/g4cB1M+EFFK6sL5nJ9firZOoNbURRHHCn3mEtUT+RF9a7kS8QcoVD8ww== 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 4VJwF72vRszxWK; Tue, 16 Apr 2024 20:12:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCRSK036978; Tue, 16 Apr 2024 20:12:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCRoa036975; Tue, 16 Apr 2024 20:12:27 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:27 GMT Message-Id: <202404162012.43GKCRoa036975@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: b5fa90e2e20f - stable/14 - kboot: Assert copyright here List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b5fa90e2e20f20b93a26591fb4b9cc60e7fd7fe4 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=b5fa90e2e20f20b93a26591fb4b9cc60e7fd7fe4 commit b5fa90e2e20f20b93a26591fb4b9cc60e7fd7fe4 Author: Warner Losh AuthorDate: 2024-01-28 19:17:44 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 kboot: Assert copyright here According to git blame I've 95%+ rewritten this file. Update copyright to reflect that, but give nod to Nathan for the original I started with. Sponsored by: Netflix (cherry picked from commit 2b7918f13c6fce378a75f8247b5dd203bf4a3c5d) --- stand/kboot/include/host_syscall.h | 25 ++++--------------------- 1 file changed, 4 insertions(+), 21 deletions(-) diff --git a/stand/kboot/include/host_syscall.h b/stand/kboot/include/host_syscall.h index fc44419201f6..fd3b7a0f362b 100644 --- a/stand/kboot/include/host_syscall.h +++ b/stand/kboot/include/host_syscall.h @@ -1,26 +1,9 @@ -/*- - * Copyright (C) 2014 Nathan Whitehorn - * All rights reserved. +/* + * Copyright (c) 2022, Netflix, Inc. * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. + * SPDX-License-Identifier: BSD-2-Clause * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; - * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * Rewritten from the original host_syscall.h Copyright (C) 2014 Nathan Whitehorn */ #ifndef _HOST_SYSCALL_H From nobody Tue Apr 16 20:12:28 2024 X-Original-To: dev-commits-src-branches@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 4VJwF85V0Kz5H0Gf; Tue, 16 Apr 2024 20:12:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF84Nnkz4sT3; Tue, 16 Apr 2024 20:12:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298348; 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=48r3ihK71gE/B9Y7udk7b5bZ40cG9rmp874Q/HEznBA=; b=lwDIyWLEaRBpr+g6CTyr+HP4TbQw1KwGM7taW/NqBMgFvX+bTZMVxCMWIf+li0Bg3794x3 CabdRy0Sm1/glmmPsaSZqSAa9sLrSOpRt3e9s4MeyWz8EU46ID4dI6yT0P7obC74/uuIKP Y7qIjoEy05++7IhRthjgIuceMIjOeSCohx36zA83QQvEqYH8k9wEiqWIFuvhj/oGCRXrq0 JVMY7sqKTb7XBff4l18OZZNa2DRzA8kfK6+CeZv81bPZo2qXvpPR4Sf7WnRvov4rkiKUmT nqK3N+p5u+Hk5prI8GohRtSY+enDQOBdb4TBvOtRjJDC5hsUKsHU2SdLbl+QCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298348; a=rsa-sha256; cv=none; b=odZBL9YckAs6uUIpnoWMiv3S61X79Cx5Gw2V/iWfb4Xi40mPK/QAwW4XfOZxGmw7LoEWxv fIk0MoS8uNsKx6Bj2enh+PjB+7je1B5FBFfO8q5/rV7KL/0l/a8ZoR3SnmgmTbguEC1VfM bEmRFtK7FZZiMoDLmdFI6sTfPKvCBtEgfq4QTqzU+R628CEG9Ha9Zp123mRRsGQrS7zMFz 40GAiefBLkTCNWr/hr0MUpSHTYNJIQba+zcmUAiRomXLgmCvMdX+KD4k9cuiW2gjT4nm8c dkrYzawQFXiN8DC7o6Q7ALy4/BXRJYB1ZNkHtoT4Sp6LfeOVpH4+Gjh89wVfHA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298348; 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=48r3ihK71gE/B9Y7udk7b5bZ40cG9rmp874Q/HEznBA=; b=ZPNW0WtB9ont7Cg61v3IBTcWO0YFJxNX0vuE5uP/EtGeNSK+KC7n2+DXHRsO7Z2nJ0T1XX lAnwfhqP3nuyxW02iVsa9LGs9Ue8X2pbYwG1r8xCy+oq3tyZoCEVY4TgXEqcwsIopSiJ6r 5iobCweH+Lp2vcDlsgHVB9dBWw17jJd0O+oVBr4j4pnqqL2LyRkvZDTxD2hq7cAZX4CsJh 1Flo4LMoXD8W2xVU96+TRYlbDgtOsm9ArZtFIfBDj3P9d92c+zWYfWNdSoHusoD1vQqtAg vT3koT7HyUgdT0cgcf3CAXJXagsLXG+b3eKN50skfPRE1BifUygSIZ6i+ElGUA== 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 4VJwF8417RzxWM; Tue, 16 Apr 2024 20:12:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCSOr037029; Tue, 16 Apr 2024 20:12:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCS3Q037026; Tue, 16 Apr 2024 20:12:28 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:28 GMT Message-Id: <202404162012.43GKCS3Q037026@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: a975ee493d89 - stable/14 - kboot: update copyright on these files. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a975ee493d896774c8901bdd6b869fa0ea1e8a71 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=a975ee493d896774c8901bdd6b869fa0ea1e8a71 commit a975ee493d896774c8901bdd6b869fa0ea1e8a71 Author: Warner Losh AuthorDate: 2024-01-28 19:19:32 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 kboot: update copyright on these files. host_syscalls.c: I've written, so put Netflix copyright on. It's possible in the confusion that Nathan wrote the host_gettimeofday implementation. syscall_nr: These files likely can't enjoy copyright protection since they are just facts (the per-arch Linux system calls), so add a note they are in the public domain. Sponsored by: Netflix (cherry picked from commit 8f7327dceecc225029b17378e4a26ae0b73a0a49) --- stand/kboot/include/arch/aarch64/syscall_nr.h | 4 ++++ stand/kboot/include/arch/amd64/syscall_nr.h | 4 ++++ stand/kboot/include/arch/powerpc64/syscall_nr.h | 4 ++++ stand/kboot/libkboot/host_syscalls.c | 6 ++++++ 4 files changed, 18 insertions(+) diff --git a/stand/kboot/include/arch/aarch64/syscall_nr.h b/stand/kboot/include/arch/aarch64/syscall_nr.h index 83069dd8dc76..5c776db81d03 100644 --- a/stand/kboot/include/arch/aarch64/syscall_nr.h +++ b/stand/kboot/include/arch/aarch64/syscall_nr.h @@ -1,3 +1,7 @@ +/* + * This file is in the public domain. It only recounts facts in the only way + * possible. + */ #define SYS_close 57 #define SYS_dup 23 #define SYS_exit 93 diff --git a/stand/kboot/include/arch/amd64/syscall_nr.h b/stand/kboot/include/arch/amd64/syscall_nr.h index 2cf26d7ca4dc..705b39c62f44 100644 --- a/stand/kboot/include/arch/amd64/syscall_nr.h +++ b/stand/kboot/include/arch/amd64/syscall_nr.h @@ -1,3 +1,7 @@ +/* + * This file is in the public domain. It only recounts facts in the only way + * possible. + */ #define SYS_close 3 #define SYS_dup 32 #define SYS_exit 60 diff --git a/stand/kboot/include/arch/powerpc64/syscall_nr.h b/stand/kboot/include/arch/powerpc64/syscall_nr.h index 735e79a09158..50946a4f058c 100644 --- a/stand/kboot/include/arch/powerpc64/syscall_nr.h +++ b/stand/kboot/include/arch/powerpc64/syscall_nr.h @@ -1,3 +1,7 @@ +/* + * This file is in the public domain. It only recounts facts in the only way + * possible. + */ #define SYS_close 6 #define SYS_dup 41 #define SYS_exit 1 diff --git a/stand/kboot/libkboot/host_syscalls.c b/stand/kboot/libkboot/host_syscalls.c index 092ddfd133fd..551ff6b777d6 100644 --- a/stand/kboot/libkboot/host_syscalls.c +++ b/stand/kboot/libkboot/host_syscalls.c @@ -1,3 +1,9 @@ +/* + * Copyright (c) 2022-2024, Netflix, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + #include "host_syscall.h" #include "syscall_nr.h" #include From nobody Tue Apr 16 20:12:29 2024 X-Original-To: dev-commits-src-branches@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 4VJwFB20v7z5H0DY; Tue, 16 Apr 2024 20:12:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwF95Xzxz4sTP; Tue, 16 Apr 2024 20:12:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298349; 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=Qf3umVbnN9Q6daPHGdVUaVVN2QuNBQSqAttSyQKqblg=; b=Qkh/XvrbIMxlZyLsitaE/urBcQxGbIGpVMxGM+qeSm9oXr/uPMmtFUy/2TqDrhf3fmg7DZ UZ2KNKmjD7B1YgaK5XMVL0nTsPv39agVvs8RAtYFBcJV/P8KZLWhCzW8nVTs7FiYpobp2j w+puetduVSRDM/SuMvrgt/wbUZIf2BWtq4TtM04+GwFB4IUIAFL/XyTgUVNsDItTpEZIiR PDk2A3lqKNEz9vQbcyVIeYHsrHaKb3y+XagecRRuXkqo//rXgSdhMbNpPLDLgWrSe4TfuI QGJrZJ4OCxWtZZTK4Y0Ud95t+c4QCAoEHe72xaXQ+lQj+dXOM4qeB+7k6MIK/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298349; a=rsa-sha256; cv=none; b=uRD2YJGCQIiD5ac0lcCA2SFT/Q9bH8x9X4ipEBzY8ehHCvUW+IWcxWrjUVndFf9ZGfyF7P i5u3Zu2X3V0BCpmBQN49TREooCu4w1C6y4woVZrsxVHJp2Vo8P42I2I8sqKoR/YUxoCqMf ETngi1bk/uqvcD5m+lGT7Z2nwLN8mg9gVPolQs4DbvgGqrCUizjLxDBOgXbVDH76OM+FlD wsNc5sSfx6+CrnsOzmI4McyWpgdOf2iwSMjvZoQ9l2lZCt+gDnSP68jFFwoLLYyBXlGgNr pUFAB6Zzy2O/T0kQvD9qTt2EnSxQ4VIEjKQMn7A+AWdpMhaR/VihWN0q2Lm7yw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298349; 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=Qf3umVbnN9Q6daPHGdVUaVVN2QuNBQSqAttSyQKqblg=; b=VSbLNbDus/TiivKjq9YlXhqNRj3WwnqKh1OCNeRqjGQPrD/KEjqZXj/eMewYW51rHEPGCB ao2lY4CRYvQNYHdK9kFf2UyCqZLnvXMUOEAKBjDvkp25kzAKoSE9ha0IkrbluFZB76nb9U qPgujAX7ujmXWHVvAtq88HR2QBvGZCHdWAUtEd4pZEgT70RCyEquFng68OUDumORMC7dFJ LlGcHCyoMAh23qgFMNemG1OSvQ3yUXam9nZ9lU/q8ml1N6cjkCYkyrAMuHWqzufVf0QyqV 6sFxBHU8Q2hSLCffsEt+ZDSylZ7j4tYwiKbvfcCrH/YDFG1mPepTv8JJFdO4hg== 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 4VJwF959DdzxXw; Tue, 16 Apr 2024 20:12:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCTwN037081; Tue, 16 Apr 2024 20:12:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCTlP037078; Tue, 16 Apr 2024 20:12:29 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:29 GMT Message-Id: <202404162012.43GKCTlP037078@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 3eb3a802a31b - stable/14 - stand/lua: per-product conf if requested via product_vars List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3eb3a802a31ba84d70e1be50c793ec34bec3614f Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3eb3a802a31ba84d70e1be50c793ec34bec3614f commit 3eb3a802a31ba84d70e1be50c793ec34bec3614f Author: Stéphane Rochoy AuthorDate: 2023-05-04 07:23:47 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 stand/lua: per-product conf if requested via product_vars If product_vars is set, it must be a space separated list of environment variable names to walk through to guess the product. Each time a product can be guessed (i.e., the corresponding variable is defined), prepend /boot/loader.conf.d/PRODUCT/ to loader_conf_dirs. It can be typically used as follow: smbios.system.planar.maker="PLANAR_MAKER" smbios.system.planar.product="PLANAR_PRODUCT" smbios.system.product="PRODUCT" uboot.m_product="M_PRODUCT" product_vars="smbios.system.planar.maker smbios.system.planar.product smbios.system.product uboot.m_product" to read files found in the following directories, in that order: /boot/loader.conf.d/PLANAR_MAKER /boot/loader.conf.d/PLANAR_PRODUCT /boot/loader.conf.d/PRODUCT /boot/loader.conf.d/M_PRODUCT Reviewed by: imp, kevans Pull Request: https://github.com/freebsd/freebsd-src/pull/759 [[ The commit, revert, commit has been squashed dpwn ]] (cherry picked from commit c343eedc6db381ac76e489f8ae0304898b71c5db) (cherry picked from commit 994865caf250ea2a59b7b842e44680931e8b19f6) (cherry picked from commit 754cac4b283eb024a3a6a194130199c860e32ebf) --- stand/defaults/loader.conf.5 | 34 +++++++++++++++++++++++++++++++++- stand/lua/config.lua | 25 +++++++++++++++++++++++++ 2 files changed, 58 insertions(+), 1 deletion(-) diff --git a/stand/defaults/loader.conf.5 b/stand/defaults/loader.conf.5 index 42e5712d93b8..0d82a3dac9b3 100644 --- a/stand/defaults/loader.conf.5 +++ b/stand/defaults/loader.conf.5 @@ -21,7 +21,7 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.Dd January 10, 2024 +.Dd February 2, 2024 .Dt LOADER.CONF 5 .Os .Sh NAME @@ -138,6 +138,38 @@ present file. should be treated as write-only. One cannot depend on any value remaining in the loader environment or carried over into the kernel environment. +.It Ar product_vars +When set, must be a space separated list of environment variable names to walk +through to guess product information. +The order matters as reading a config file override the previously defined +values. +Undefined variables are silently ignored. +.Pp +When product information can be guessed, for each product information found, +append +.Pa /boot/loader.conf.d/PRODUCT +to +.Ar loader_conf_dirs . +It can be typically used as follow: +.Bd -literal +smbios.system.planar.maker="PLANAR_MAKER" +smbios.system.planar.product="PLANAR_PRODUCT" +smbios.system.product="PRODUCT" +uboot.m_product="M_PRODUCT" +product_vars="smbios.system.planar.maker smbios.system.planar.product smbios.system.product uboot.m_product" +.Ed +.Pp +to read files found in the following directories, in that order: +.Bl -bullet -compact +.It +.Pa /boot/loader.conf.d/PLANAR_MAKER +.It +.Pa /boot/loader.conf.d/PLANAR_PRODUCT +.It +.Pa /boot/loader.conf.d/PRODUCT +.It +.Pa /boot/loader.conf.d/M_PRODUCT +.El .It Ar kernel Name of the kernel to be loaded. If no kernel name is set, no additional diff --git a/stand/lua/config.lua b/stand/lua/config.lua index 8fdc805ee983..210bb9338783 100644 --- a/stand/lua/config.lua +++ b/stand/lua/config.lua @@ -658,12 +658,37 @@ function config.readConf(file, loaded_files) if load_conf_dirs then local loader_conf_dirs = getEnv("loader_conf_dirs") + + -- If product_vars is set, it must be a list of environment variable names + -- to walk through to guess product information. The order matters as + -- reading a config files override the previously defined values. + -- + -- If product information can be guessed, for each product information + -- found, also read config files found in /boot/loader.conf.d/PRODUCT/. + local product_vars = getEnv("product_vars") + if product_vars then + local product_conf_dirs = "" + for var in product_vars:gmatch("%S+") do + local product = getEnv(var) + if product then + product_conf_dirs = product_conf_dirs .. " /boot/loader.conf.d/" .. product + end + end + + if loader_conf_dirs then + loader_conf_dirs = loader_conf_dirs .. product_conf_dirs + else + loader_conf_dirs = product_conf_dirs + end + end + if loader_conf_dirs ~= nil then for name in loader_conf_dirs:gmatch("[%w%p]+") do if lfs.attributes(name, "mode") ~= "directory" then print(MSG_FAILDIR:format(name)) goto nextdir end + for cfile in lfs.dir(name) do if cfile:match(".conf$") then local fpath = name .. "/" .. cfile From nobody Tue Apr 16 20:12:30 2024 X-Original-To: dev-commits-src-branches@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 4VJwFC12B3z5H0MH; Tue, 16 Apr 2024 20:12:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFB6T14z4sBS; Tue, 16 Apr 2024 20:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298350; 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=CPi13tKyJheT2ke3He+8padx8xRuui6HRkrfFZfPK6g=; b=xd43+U+o0FPTB9GCyxb6LrCH1TFqvb5sKM3QWYN7HhMnwgCeILS8jTdU/7F2fnU2QrhPOB kKCTJX23RbOMMcgj2wMEu8yhG//yJfJHW8OWYQd5vBH/TzXegjNiLhYqRmgYtkkvGYxG2+ yqdqT4P8b2mqz2ZHh/GhhzlE3Lyd11wmNyZNpUsb0H6XsjfN/ACgDe5El7yru9guxCXkn6 trbXwYCm1qfl07hlHG98h8uLaXqBJOUaJ8iAkAJBMFM8ZdHvlkO2CIAwyapSJzDMm4+qPj 2wLKLocIh8vNmxAwpumQ5rRWXcckcjvJVmBltiQDFvCUnbwKq3P2BR3e/D1Csg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298350; a=rsa-sha256; cv=none; b=rRm54gt3WF0YBXSfTkeJgsa1e3NXbbTBjo8x1Zt7pQp0PI36F7H+JPOu1D3o797iXstzvq pzQ1Ov/Ze9mCMZy9l1n+6la1SRbK36gpH4odqEDXYBXYe6WQLpOSLTRdQ8TnCqdMLLzSQM Nx4vAkSTEsPwrwPUCzCvTa5uII+XcCmkzzt9+DnbOLCkNlshfCdTXSFkvishLww/U3kQ2J SGvDDHwTN5eakF7kSPZzgZd8tcQqy5AOYh30V3lbp8TbQTXfnghQlSDeo0/L8foX+ytQsS Dnmwqcle0pAoJOWbo+iXUYFg8BvwafuhrnLT7WxXFehygPYQqklTVOoF4yV5Qg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298350; 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=CPi13tKyJheT2ke3He+8padx8xRuui6HRkrfFZfPK6g=; b=ecRCJFoaUkIc9bFbq+yGJq6e8CCn5uBfOjVfvT/rJsbGwUkm6c5+5wuaAdnMXP5p3HOmd1 uJeVMXd2L+C+0glCRD/7vX4/FmPuQCZc5wLMCiOm213UWaGZ/FByiR01ItwIEPUuUUb6L4 ElC9lhP4AEgmBRWGH+tzOKP/Vjl8H2PrcYDH/JymrU9ksaGnwE7sbWDvnplRDgibQ+GZ8W mUUkrIH7rEmZAFVqUpkkUFCv3mQnSCxByN+XQ4iPdw+ngKEb4M5UWGBNJiAjPTvxYO5yA5 ARgUMxW8NXLVkUvxJnHnP4gAumpFrihlfymWuwKkFAAZHmwDLOVQnKYR16r1Ig== 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 4VJwFB64STzxJS; Tue, 16 Apr 2024 20:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCUqp037134; Tue, 16 Apr 2024 20:12:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCUjH037131; Tue, 16 Apr 2024 20:12:30 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:30 GMT Message-Id: <202404162012.43GKCUjH037131@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: a25531db0fc2 - stable/14 - stand/lua: always allow overriding with local config files List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a25531db0fc22a82f87f6166553e9b1623c83837 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=a25531db0fc22a82f87f6166553e9b1623c83837 commit a25531db0fc22a82f87f6166553e9b1623c83837 Author: Stéphane Rochoy AuthorDate: 2023-12-21 14:05:58 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:21 +0000 stand/lua: always allow overriding with local config files Loader now also read configuration files listed in local_loader_conf_files. Files listed here are the last ones read. And /boot/loader.conf.local was moved from loader_conf_files to local_loader_conf_files leaving only loader.conf and device.hints in loader_conf_files by default. The idea is to ensure local_loader_conf_files, i.e., /boot/loader.conf.local, can always be used to override other user defined settings. So the sequencing is now as follow: 1. Bootstrap: /boot/defaults/loader.conf 2. Read loader_conf_files files: /boot/device.hints /boot/loader.conf 3. Read loader_conf_dirs files: /boot/loader.conf.d/*.conf 4. And finally, rread local_loader_conf_files files: /boot/loader.conf.local Reviewed by: imp, kevans Pull Request: https://github.com/freebsd/freebsd-src/pull/759 [[ The commit, revert, recommit has been squashed down to record the merge ]] (cherry picked from commit c475e61f66fe8fe939e18ec7821c2340569f3271) (cherry picked from commit 5fdf01dbeef1f64f8c446561498d662702451ac1) (cherry picked from commit d3d0b735571d9562812ce5b343a6e91f7a795dbe) --- UPDATING | 21 +++++++++++++++++++++ stand/defaults/loader.conf | 3 ++- stand/defaults/loader.conf.5 | 32 ++++++++++++++++++++++++++++---- stand/lua/config.lua | 15 ++++++++++++--- stand/lua/config.lua.8 | 8 ++++++-- 5 files changed, 69 insertions(+), 10 deletions(-) diff --git a/UPDATING b/UPDATING index d211814b0248..83b0d8b27cda 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,27 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20240202: + Loader now also read configuration files listed in local_loader_conf_files. + Files listed here are the last ones read. And /boot/loader.conf.local was + moved from loader_conf_files to local_loader_conf_files leaving only + loader.conf and device.hints in loader_conf_files by default. + + The following sequencing is applied: + + 1. Bootstrap: + /boot/defaults/loader.conf + + 2. Read loader_conf_files files: + /boot/device.hints + /boot/loader.conf + + 3. Read loader_conf_dirs files: + /boot/loader.conf.d/*.conf + + 4. And finally, rread local_loader_conf_files files: + /boot/loader.conf.local + 20240415: MFC e0f3dc82727f: If you have an arm64 system that uses ACPI, you will need to update your loader.efi in the ESP when you update past this diff --git a/stand/defaults/loader.conf b/stand/defaults/loader.conf index e0062bbc8149..a5d27b96b6ba 100644 --- a/stand/defaults/loader.conf +++ b/stand/defaults/loader.conf @@ -13,8 +13,9 @@ exec="echo Loading /boot/defaults/loader.conf" kernel="kernel" # /boot sub-directory containing kernel and modules bootfile="kernel" # Kernel name (possibly absolute path) kernel_options="" # Flags to be passed to the kernel -loader_conf_files="/boot/device.hints /boot/loader.conf /boot/loader.conf.local" +loader_conf_files="/boot/device.hints /boot/loader.conf" loader_conf_dirs="/boot/loader.conf.d" +local_loader_conf_files="/boot/loader.conf.local" nextboot_conf="/boot/nextboot.conf" verbose_loading="NO" # Set to YES for verbose loader output diff --git a/stand/defaults/loader.conf.5 b/stand/defaults/loader.conf.5 index 0d82a3dac9b3..e38ad865c288 100644 --- a/stand/defaults/loader.conf.5 +++ b/stand/defaults/loader.conf.5 @@ -131,6 +131,10 @@ Space separated list of directories to process for configuration files. The lua-based loader will process files with a .Dq .conf suffix that are placed in these directories. +Files found here are processed after the ones listed in +.Va loader_conf_files +but before the ones found in +.Va local_loader_conf_files . .It Ar loader_conf_files Defines additional configuration files to be processed right after the present file. @@ -138,6 +142,13 @@ present file. should be treated as write-only. One cannot depend on any value remaining in the loader environment or carried over into the kernel environment. +.It Ar local_loader_conf_files +Space separated list of additional configuration files to be processed at last, +i.e., after +.Va loader_conf_files +and +.Va loader_conf_dirs +are processed. .It Ar product_vars When set, must be a space separated list of environment variable names to walk through to guess product information. @@ -274,6 +285,14 @@ default settings can be ignored. The few of them which are important or useful are: .Bl -tag -width bootfile -offset indent +.It Va local_loader_conf_files +.Pq Dq /boot/loader.conf.local +Ensure +.Va loader.conf.local +can always be used to override settings from files found in +.Va loader_conf_files +and +.Va loader_conf_dirs . .It Va bitmap_load .Pq Dq NO If set to @@ -455,13 +474,18 @@ It is not available in the default Forth-based loader. .Sh FILES .Bl -tag -width /boot/defaults/loader.conf -compact .It Pa /boot/defaults/loader.conf -default settings \(em do not change this file. +Default settings \(em do not change this file. .It Pa /boot/loader.conf -user defined settings. +User defined settings. .It Pa /boot/loader.conf.lua -user defined settings written in lua. +User defined settings written in lua. +.It Pa /boot/loader.conf.d/*.conf +User defined settings split in separate files. +.It Pa /boot/loader.conf.d/*.lua +User defined settings written in lua and split in separate files. .It Pa /boot/loader.conf.local -machine-specific settings for sites with a common loader.conf. +Machine-specific settings for sites with a common loader.conf. Allow to override +settings defined in other files. .El .Sh SEE ALSO .Xr kenv 1 , diff --git a/stand/lua/config.lua b/stand/lua/config.lua index 210bb9338783..86f5ef6174a2 100644 --- a/stand/lua/config.lua +++ b/stand/lua/config.lua @@ -630,8 +630,7 @@ function config.readConf(file, loaded_files) return end - -- We'll process loader_conf_dirs at the top-level readConf - local load_conf_dirs = next(loaded_files) == nil + local top_level = next(loaded_files) == nil -- Are we the top-level readConf? print("Loading " .. file) -- The final value of loader_conf_files is not important, so just @@ -656,7 +655,7 @@ function config.readConf(file, loaded_files) end end - if load_conf_dirs then + if top_level then local loader_conf_dirs = getEnv("loader_conf_dirs") -- If product_vars is set, it must be a list of environment variable names @@ -682,6 +681,7 @@ function config.readConf(file, loaded_files) end end + -- Process "loader_conf_dirs" extra-directories if loader_conf_dirs ~= nil then for name in loader_conf_dirs:gmatch("[%w%p]+") do if lfs.attributes(name, "mode") ~= "directory" then @@ -700,6 +700,15 @@ function config.readConf(file, loaded_files) ::nextdir:: end end + + -- Always allow overriding with local config files, e.g., + -- /boot/loader.conf.local. + local local_loader_conf_files = getEnv("local_loader_conf_files") + if local_loader_conf_files then + for name in local_loader_conf_files:gmatch("[%w%p]+") do + config.readConf(name, loaded_files) + end + end end end diff --git a/stand/lua/config.lua.8 b/stand/lua/config.lua.8 index f9896f2aa420..b2b1122285eb 100644 --- a/stand/lua/config.lua.8 +++ b/stand/lua/config.lua.8 @@ -64,9 +64,13 @@ as a configuration file .Po e.g., as .Pa loader.conf .Pc -and then processing files listed in +and then process files listed in the .Ev loader_conf_files -variable +variable. Additionnaly, the top-level call to readConf will process files listed in the +.Ev loader_conf_dirs +and +.Ev local_loader_conf_files +variables .Po see .Xr loader.conf 5 .Pc . From nobody Tue Apr 16 20:12:31 2024 X-Original-To: dev-commits-src-branches@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 4VJwFD4Y3Hz5H0V2; Tue, 16 Apr 2024 20:12: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFD0y1Yz4sbv; Tue, 16 Apr 2024 20:12:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298352; 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=uybj64E6t46IXRYoIhbY0AaDDKn2okF7j0jUFZwArfY=; b=hpfgLcVl1vhltWssr7spuZRgnlq4y0rso54IiG9E20T97SeCWZxmnuKvLIjZbBYNenZsL2 zlC2aOko9gizXcfnlS1RbvKO6KgRaLESyHsLAoJa/DZ20iOQhRRflkUObWdp+8mTE4VBtv pSgth3WnIkCKPemxTySZnfMheK0XAOOu/gk05YOCQS8PQjPV+HvZ2pHhFH4Gx+TqA8D95y F65AcvdHl08Q6xv6WBrFl+cs5apYOIHUx6LxczO6y1rUVUcsx8akNZ3BkBbFPSLafDHMrf EXecWEGa2f/v3aFLX1NnLajTTowhZyQkRQxDSZBoWx5yeSwG6EvelVnvmeSRcA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298352; a=rsa-sha256; cv=none; b=OIi9ljnFCGAoe9iVNmnK7+jXTj1XwXGGBPIzb/6XHjJvMBPToxfQTnQhTeAwNh5WemKnMh Y4rQr3Fwp7rW9Pvko27GyowwnKIYULbcGtwQ/DeljgbuODfskGRi+0jXGxuuDHz2ZU1Bay 6LSxk06EqN00kai1bY8X9u2S6aoZlurf0Z0558Vt98vfWM0dzDlkF8KVI9E19zMjfuUPE8 UfRObLxIgNDIhlgEhyWwVOvsTOaWOblX8MWx9yWpDWxY4gVQ5KIsMywsC79K56+J3gAvvE JaT1SSqieevp1fhF5qzh3Ps7Wgg/vNXiGzTaXs9wn2mTfnabqZ0RAOou3z2Mhw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298352; 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=uybj64E6t46IXRYoIhbY0AaDDKn2okF7j0jUFZwArfY=; b=r9wtMdPw7xs0D3I9nC/3/25RHdUCTm4JxEkJAmy2xJ3tM+VXgOvhKyvmuhqgLw/8caslPj 2jbaFvRaXBheNveNBKnO3C3+2w1q8mM+9kkqOfyvPnE5uSgDljSQxdQmuQzJZC6ZQWMZ8v 4T9X/HNxwMf0foa0gn2f1tfWVOkH66VZTOZdSE367Q9zKScgw8baMilHzgiBJDmbb6bc9u HQ6ID4jZCQ20r3+jOChoyWEt+Q7BiW48j8NBG3txKUKZo6v+Ve6XbLH0+iPDIkLG0f3/RN MDNbdEVgchA48l7CezRpCgmtO5AqNQuDBKcRczu3nZnLm02BwaT9HfSeEaP9iw== 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 4VJwFD0ZMFzxPL; Tue, 16 Apr 2024 20:12:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCVTs037196; Tue, 16 Apr 2024 20:12:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCVHx037193; Tue, 16 Apr 2024 20:12:31 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:31 GMT Message-Id: <202404162012.43GKCVHx037193@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 6d41d985fdbf - stable/14 - libsa: Move include file creation to the end of the Makefile List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6d41d985fdbf713adb204840aabfea551d4f8b47 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=6d41d985fdbf713adb204840aabfea551d4f8b47 commit 6d41d985fdbf713adb204840aabfea551d4f8b47 Author: Warner Losh AuthorDate: 2024-01-31 23:42:49 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 libsa: Move include file creation to the end of the Makefile The include file symblic links, etc are out of place where they are. Move them to the end of the file. No functional change intended. Sponsored by: Netflix (cherry picked from commit 7c8b126c1a7b30fe690800d7e27b308876711f9d) --- stand/libsa/Makefile | 52 ++++++++++++++++++++++++++-------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/stand/libsa/Makefile b/stand/libsa/Makefile index a1b9bc32e025..f7d7778d5653 100644 --- a/stand/libsa/Makefile +++ b/stand/libsa/Makefile @@ -108,32 +108,6 @@ SRCS+= ${i} SRCS+= lz4.c CFLAGS.lz4.c+= -I${SRCTOP}/sys/cddl/contrib/opensolaris/common/lz4 -# Create a subset of includes that are safe, as well as adjusting those that aren't -# The lists may drive people nuts, but they are explicitly opt-in -FAKE_DIRS=xlocale arpa -SAFE_INCS=a.out.h assert.h elf.h inttypes.h limits.h nlist.h setjmp.h stddef.h stdbool.h string.h strings.h time.h unistd.h uuid.h -STAND_H_INC=ctype.h fcntl.h signal.h stdio.h stdlib.h -OTHER_INC=stdarg.h errno.h stdint.h - -beforedepend: - mkdir -p ${FAKE_DIRS}; \ - for i in ${SAFE_INCS}; do \ - ln -sf ${SRCTOP}/include/$$i $$i; \ - done; \ - ln -sf ${SYSDIR}/${MACHINE}/include/stdarg.h stdarg.h; \ - ln -sf ${SYSDIR}/sys/errno.h errno.h; \ - ln -sf ${SYSDIR}/sys/stdint.h stdint.h; \ - ln -sf ${SRCTOP}/include/arpa/inet.h arpa/inet.h; \ - ln -sf ${SRCTOP}/include/arpa/tftp.h arpa/tftp.h; \ - for i in _time.h _strings.h _string.h; do \ - [ -f xlocale/$$i ] || :> xlocale/$$i; \ - done; \ - for i in ${STAND_H_INC}; do \ - ln -sf ${SASRC}/stand.h $$i; \ - done -CLEANDIRS+=${FAKE_DIRS} -CLEANFILES+= ${SAFE_INCS} ${STAND_H_INC} ${OTHER_INC} - # io routines SRCS+= closeall.c dev.c ioctl.c nullfs.c stat.c mount.c \ fstat.c close.c lseek.c open.c read.c write.c readdir.c preload.c @@ -210,4 +184,30 @@ SRCS+= explicit_bzero.c crc32_libkern.c MAN=libsa.3 .endif +# Create a subset of includes that are safe, as well as adjusting those that aren't +# The lists may drive people nuts, but they are explicitly opt-in +FAKE_DIRS=xlocale arpa +SAFE_INCS=a.out.h assert.h elf.h inttypes.h limits.h nlist.h setjmp.h stddef.h stdbool.h string.h strings.h time.h unistd.h uuid.h +STAND_H_INC=ctype.h fcntl.h signal.h stdio.h stdlib.h +OTHER_INC=stdarg.h errno.h stdint.h + +beforedepend: + mkdir -p ${FAKE_DIRS}; \ + for i in ${SAFE_INCS}; do \ + ln -sf ${SRCTOP}/include/$$i $$i; \ + done; \ + ln -sf ${SYSDIR}/${MACHINE}/include/stdarg.h stdarg.h; \ + ln -sf ${SYSDIR}/sys/errno.h errno.h; \ + ln -sf ${SYSDIR}/sys/stdint.h stdint.h; \ + ln -sf ${SRCTOP}/include/arpa/inet.h arpa/inet.h; \ + ln -sf ${SRCTOP}/include/arpa/tftp.h arpa/tftp.h; \ + for i in _time.h _strings.h _string.h; do \ + [ -f xlocale/$$i ] || :> xlocale/$$i; \ + done; \ + for i in ${STAND_H_INC}; do \ + ln -sf ${SASRC}/stand.h $$i; \ + done +CLEANDIRS+=${FAKE_DIRS} +CLEANFILES+= ${SAFE_INCS} ${STAND_H_INC} ${OTHER_INC} + .include From nobody Tue Apr 16 20:12:34 2024 X-Original-To: dev-commits-src-branches@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 4VJwFG3zNGz5H0RY; Tue, 16 Apr 2024 20:12:34 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFG2ZRyz4scL; Tue, 16 Apr 2024 20:12:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298354; 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=v+YjtVe83dKyG7g45MHcJvvexbxgOxvWzfxrvtXPGJI=; b=ixxb0PC5t9yayOwnzS1+N+t0HlEwvCtYlBYeuSITFpBcWWQTI5b9KAp2YYcBkpjBcoK9Nn JHId1xSgTOb6Cs9Rr6bFJ3bnkrVAS8h6I2jWd1725wrNq8vi0xPpxIaYsM+97gKTTmAFAm bUtQ8p/qpBr0oM5Mnmo+5OHqJdcYyCGT49khAT8QxagvDro56woMPNen2W2wlfPk7xSY6p 2GK7g6EQUlQaCrQJ4RJZnE+DlxTBFGoiGovexxUqDOIH0v5CrmjzXw5EWcz9ypA6xcgh2J Qb7XI31QIUYUCp3HVRee2WLxe2Lb4WP9TR7bm5Sjfb31c+5CxiBscA6ZKxxDSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298354; a=rsa-sha256; cv=none; b=JXzEzi90MEpMFp6W3eT7+Wv6+r41RUlTGY3orAM4MR0HGDqBcqQdnay8jWWGK3eOoIr09K 4kOG5GSUI34brebLdfpSpLFH2VxwYmGttU46CFjMNm5Qo+pw72Ahj5Bk2BehtN8HfyzZRS KnWIl5VKUfrnk/ETyrWkt7C4kASWUYcXBc+IwzF/om+35pBSBKMZ59vTm5irx0V3yEn44G Zu/d73X+h4fg3w4FPK5G49E/tVw8sIixOjpsnOcMDKZ4Ldl3xRsv3f0ifXKHxvhPbXHMTV /A5WmsFGzZp7vrgDk/WtlwCOaCXzpMSSXSl7N+G92A7Q7c21I2Vi85iX5Yb0fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298354; 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=v+YjtVe83dKyG7g45MHcJvvexbxgOxvWzfxrvtXPGJI=; b=T9ceF2c4u+l4fbPYtqv/BtsxZSJyVGJQEkPeL43G81No/fpG7lqfc6xPakOa0Mfv9KdjMr dgCUkhymjGQhOKoKp/mlYdsFiR4m18dsKwsXca/vLgnFGHBE6lky79DxKYGSBSVIO/g1br iuRQzBGI9YQrZVBqEtOSsePTGPjFFyV57Vv5srZTNxHni6veVGt1xwoj6cE7gq95mcKYgR LgKuHMd/aVSrmRq4fHH8bLiDSb1OyQhJopAeGzrscbEJx8TtQX3Lz1IWaBr9UZpdCQiqX5 ha4Z/txBCGzwaY18h3erZOv7jeYhEnPiz9ryxyK1Ayt2hZF+qVPaqf/BeJhNmg== 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 4VJwFG273yzxPM; Tue, 16 Apr 2024 20:12:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCY3R037298; Tue, 16 Apr 2024 20:12:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCYFg037295; Tue, 16 Apr 2024 20:12:34 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:34 GMT Message-Id: <202404162012.43GKCYFg037295@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 639574132b95 - stable/14 - loader: Move build_font_module to gfx_fb.c List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 639574132b9582d1193aac5ba79a6244743d579e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=639574132b9582d1193aac5ba79a6244743d579e commit 639574132b9582d1193aac5ba79a6244743d579e Author: Warner Losh AuthorDate: 2024-02-02 01:38:18 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 loader: Move build_font_module to gfx_fb.c The font module is part and parsel of the gfx_fb support. Move it to gfx_fb.c where it can access the data it needs. Sponsored by: Netflix (cherry picked from commit 18968b8274b56d8b60ab4e0d606e7f53f3a02014) --- stand/common/gfx_fb.c | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++ stand/common/module.c | 87 ------------------------------------------------- 2 files changed, 89 insertions(+), 87 deletions(-) diff --git a/stand/common/gfx_fb.c b/stand/common/gfx_fb.c index c10d227a5fc8..b61591bf3d45 100644 --- a/stand/common/gfx_fb.c +++ b/stand/common/gfx_fb.c @@ -87,6 +87,8 @@ #include #include #include +#include +#include #include #include #include @@ -2917,3 +2919,90 @@ gfx_get_edid_resolution(struct vesa_edid_info *edid, edid_res_list_t *res) } return (!TAILQ_EMPTY(res)); } + +vm_offset_t +build_font_module(vm_offset_t addr) +{ + vt_font_bitmap_data_t *bd; + struct vt_font *fd; + struct preloaded_file *fp; + size_t size; + uint32_t checksum; + int i; + struct font_info fi; + struct fontlist *fl; + uint64_t fontp; + + if (STAILQ_EMPTY(&fonts)) + return (addr); + + /* We can't load first */ + if ((file_findfile(NULL, NULL)) == NULL) { + printf("Can not load font module: %s\n", + "the kernel is not loaded"); + return (addr); + } + + /* helper pointers */ + bd = NULL; + STAILQ_FOREACH(fl, &fonts, font_next) { + if (gfx_state.tg_font.vf_width == fl->font_data->vfbd_width && + gfx_state.tg_font.vf_height == fl->font_data->vfbd_height) { + /* + * Kernel does have better built in font. + */ + if (fl->font_flags == FONT_BUILTIN) + return (addr); + + bd = fl->font_data; + break; + } + } + if (bd == NULL) + return (addr); + fd = bd->vfbd_font; + + fi.fi_width = fd->vf_width; + checksum = fi.fi_width; + fi.fi_height = fd->vf_height; + checksum += fi.fi_height; + fi.fi_bitmap_size = bd->vfbd_uncompressed_size; + checksum += fi.fi_bitmap_size; + + size = roundup2(sizeof (struct font_info), 8); + for (i = 0; i < VFNT_MAPS; i++) { + fi.fi_map_count[i] = fd->vf_map_count[i]; + checksum += fi.fi_map_count[i]; + size += fd->vf_map_count[i] * sizeof (struct vfnt_map); + size += roundup2(size, 8); + } + size += bd->vfbd_uncompressed_size; + + fi.fi_checksum = -checksum; + + fp = file_findfile(NULL, "elf kernel"); + if (fp == NULL) + fp = file_findfile(NULL, "elf64 kernel"); + if (fp == NULL) + panic("can't find kernel file"); + + fontp = addr; + addr += archsw.arch_copyin(&fi, addr, sizeof (struct font_info)); + addr = roundup2(addr, 8); + + /* Copy maps. */ + for (i = 0; i < VFNT_MAPS; i++) { + if (fd->vf_map_count[i] != 0) { + addr += archsw.arch_copyin(fd->vf_map[i], addr, + fd->vf_map_count[i] * sizeof (struct vfnt_map)); + addr = roundup2(addr, 8); + } + } + + /* Copy the bitmap. */ + addr += archsw.arch_copyin(fd->vf_bytes, addr, fi.fi_bitmap_size); + + /* Looks OK so far; populate control structure */ + file_addmetadata(fp, MODINFOMD_FONT, sizeof(fontp), &fontp); + return (addr); +} diff --git a/stand/common/module.c b/stand/common/module.c index 289d174733da..ac0ad466484a 100644 --- a/stand/common/module.c +++ b/stand/common/module.c @@ -640,93 +640,6 @@ file_load_dependencies(struct preloaded_file *base_file) return (error); } -vm_offset_t -build_font_module(vm_offset_t addr) -{ - vt_font_bitmap_data_t *bd; - struct vt_font *fd; - struct preloaded_file *fp; - size_t size; - uint32_t checksum; - int i; - struct font_info fi; - struct fontlist *fl; - uint64_t fontp; - - if (STAILQ_EMPTY(&fonts)) - return (addr); - - /* We can't load first */ - if ((file_findfile(NULL, NULL)) == NULL) { - printf("Can not load font module: %s\n", - "the kernel is not loaded"); - return (addr); - } - - /* helper pointers */ - bd = NULL; - STAILQ_FOREACH(fl, &fonts, font_next) { - if (gfx_state.tg_font.vf_width == fl->font_data->vfbd_width && - gfx_state.tg_font.vf_height == fl->font_data->vfbd_height) { - /* - * Kernel does have better built in font. - */ - if (fl->font_flags == FONT_BUILTIN) - return (addr); - - bd = fl->font_data; - break; - } - } - if (bd == NULL) - return (addr); - fd = bd->vfbd_font; - - fi.fi_width = fd->vf_width; - checksum = fi.fi_width; - fi.fi_height = fd->vf_height; - checksum += fi.fi_height; - fi.fi_bitmap_size = bd->vfbd_uncompressed_size; - checksum += fi.fi_bitmap_size; - - size = roundup2(sizeof (struct font_info), 8); - for (i = 0; i < VFNT_MAPS; i++) { - fi.fi_map_count[i] = fd->vf_map_count[i]; - checksum += fi.fi_map_count[i]; - size += fd->vf_map_count[i] * sizeof (struct vfnt_map); - size += roundup2(size, 8); - } - size += bd->vfbd_uncompressed_size; - - fi.fi_checksum = -checksum; - - fp = file_findfile(NULL, "elf kernel"); - if (fp == NULL) - fp = file_findfile(NULL, "elf64 kernel"); - if (fp == NULL) - panic("can't find kernel file"); - - fontp = addr; - addr += archsw.arch_copyin(&fi, addr, sizeof (struct font_info)); - addr = roundup2(addr, 8); - - /* Copy maps. */ - for (i = 0; i < VFNT_MAPS; i++) { - if (fd->vf_map_count[i] != 0) { - addr += archsw.arch_copyin(fd->vf_map[i], addr, - fd->vf_map_count[i] * sizeof (struct vfnt_map)); - addr = roundup2(addr, 8); - } - } - - /* Copy the bitmap. */ - addr += archsw.arch_copyin(fd->vf_bytes, addr, fi.fi_bitmap_size); - - /* Looks OK so far; populate control structure */ - file_addmetadata(fp, MODINFOMD_FONT, sizeof(fontp), &fontp); - return (addr); -} - #ifdef LOADER_VERIEXEC_VECTX #define VECTX_HANDLE(fd) vctx #else From nobody Tue Apr 16 20:12:33 2024 X-Original-To: dev-commits-src-branches@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 4VJwFF62C8z5H0V3; Tue, 16 Apr 2024 20:12:33 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFF1XShz4sWj; Tue, 16 Apr 2024 20:12:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298353; 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=KCJoPQ3dNkdfL0socol7TK0vFs4TiTY1TbNRYTvh8GE=; b=qZsASmIoyUlQCOoaFJG9+V8LDK/UWmdvSYf87ILR53G2DJORCG8CVUuikcoGFgImoNe1aF rT9c6d3fyN7WjqSS1bcrFn9oGvZ6wURYcdq9a+BeuycpOM9tDy2AuA8/VaMw8TmKFsEVnM eB+Yxjg58Hnx0CMlyCSAzp7q7WdKhaJ6q2nxAPvH9EdoBfr5l7mDQj0JhAyWzdOxkQnFW4 OSSmZ9NhYnMRzlWzKDs+9PdZp9ClTvBaAQYUOJG4Bt5XKMHQeiNHa43/yakI+rMYrn1deE 2yrFNJYeBfEeOZFaYCpsYblizaL97veOfRvVGkwohL0bz4leFqxHYu01dKrqWQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298353; a=rsa-sha256; cv=none; b=B1CJ/C+5Z9M8d/fkS1qWsFEkx82eYvQ6y1u6+WlZ1EL3ttXLUUQptm6+r7XTQ0Q45sHMId GvB9zs2Z3qbQKYv4S5XfWUNW976WlKFEzhlH73BjVP+zsDenlge8vKT9KZd6r7fyxNK0gf oZhEdURj9J6tc3ZXgcv0rfYl0LqJybZU8N2yuWwbRuOT3U9vjtlqAUER+y/IE2zcgAlFXA u31qjPm1Gdh14WmEAsE+bmy4Jrdjhops5EvFFXULhYSwv1iLh1aggD2ILXTeZrwELQboHX bpVVDIITHNUBtX8rWYEYmxpVSmDIzzTXQiPHZlvOZn/wRfmLPa2gCVQuZ+iuVA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298353; 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=KCJoPQ3dNkdfL0socol7TK0vFs4TiTY1TbNRYTvh8GE=; b=BTMJlEkRUysFrhkQkIE6ZLqf/BR38DxdGNgb2XUoFKWPxklXZdt+4Pj6t4WcupmJ0JiBNB 1F3xfYx9Khw6Ydht9xV7cd2+OlP+7YtjYjUMAuBVhjstDCx7CGxKRjj8p7evYtQefO1h05 /9h+4fIJ3rHzf8/p2YnIsoNMWn9n6arWqsQnLYGA6ctjyQ1e+LW+cAflwDu5/JwhVwOmeN hbqKGoITKEAhOdY2fiDwGVcuiPpmb1AMNA0EHTP5xrqsh7X1yQXL3dzj4hTEyPF+s+swvn chj2o5aLztwYCTBXc3YSJ5IWjrjink45LJ8IzRqxKSnRWdfYEa3b8f4Xa43X5Q== 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 4VJwFF18C7zxdb; Tue, 16 Apr 2024 20:12:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCXQV037244; Tue, 16 Apr 2024 20:12:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCXIi037241; Tue, 16 Apr 2024 20:12:33 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:33 GMT Message-Id: <202404162012.43GKCXIi037241@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 12138b85bb0f - stable/14 - libsa: Move hash functions up a level List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 12138b85bb0f5fa7fc72d99f17ae34e94dfae26e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=12138b85bb0f5fa7fc72d99f17ae34e94dfae26e commit 12138b85bb0f5fa7fc72d99f17ae34e94dfae26e Author: Warner Losh AuthorDate: 2024-01-31 23:54:19 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 libsa: Move hash functions up a level This should have no functional change. Move compiling the sha256, sha512 and md5 hash functions up into libsa to allow them to be used elsewhere in the boot loader when geli isn't configured. Since libsa is a .a, these won't wind up in any boot loader that doesn't reference them, so should be a nop. Sponsored by: Netflix (cherry picked from commit fd577b59b2d78a32f40fdc3847666728d8a897db) --- stand/libsa/Makefile | 9 +++++++++ stand/libsa/geli/Makefile.inc | 11 ----------- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/stand/libsa/Makefile b/stand/libsa/Makefile index f7d7778d5653..bc85a3dcb0de 100644 --- a/stand/libsa/Makefile +++ b/stand/libsa/Makefile @@ -180,6 +180,15 @@ SRCS+= explicit_bzero.c crc32_libkern.c .include "${SASRC}/zfs/Makefile.inc" .endif +# Crypto hashing functions +# sha256 and sha512 from sys/crypto +.PATH: ${SYSDIR}/crypto/sha2 +SRCS+= sha256c.c sha512c.c + +# md5 from libmd +.PATH: ${SRCTOP}/lib/libmd +SRCS+= md5c.c + .if ${DO32:U0} == 0 MAN=libsa.3 .endif diff --git a/stand/libsa/geli/Makefile.inc b/stand/libsa/geli/Makefile.inc index 0d9fcb90bbd8..07600d5287bd 100644 --- a/stand/libsa/geli/Makefile.inc +++ b/stand/libsa/geli/Makefile.inc @@ -5,16 +5,6 @@ # Our password input method SRCS+= pwgets.c -# sha256 and sha512 from sys/crypto -.PATH: ${SYSDIR}/crypto/sha2 -CFLAGS.sha256.c+= -DWEAK_REFS -CFLAGS.sha512.c+= -DWEAK_REFS -SRCS+= sha256c.c sha512c.c - -# md5 from libmd -.PATH: ${SRCTOP}/lib/libmd -SRCS+= md5c.c - # AES implementation from sys/crypto .PATH: ${SYSDIR}/crypto/rijndael .for i in rijndael-alg-fst.c rijndael-api-fst.c rijndael-api.c @@ -23,7 +13,6 @@ CFLAGS.${i}+= -DNDEBUG SRCS+= ${i} .endfor - # local GELI Implementation .PATH: ${SYSDIR}/geom/eli .for i in gelidev.c geli_metadata.c From nobody Tue Apr 16 20:12:35 2024 X-Original-To: dev-commits-src-branches@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 4VJwFH4yfmz5HT5F; Tue, 16 Apr 2024 20:12:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFH3ZZpz4shf; Tue, 16 Apr 2024 20:12:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298355; 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=oLTCwXK93vGJyp2EMtbg5OddMzWctErCx+Y+XpoFmhY=; b=bYT81hGZNqMELIj6MW0E7i+msH7H4+bj/8+0pNlcfAshZWrRl4eAcNTvIGGKj0nrhiVvi4 v+c9SMzkLVWRZ2TmZmEaJS2//A1ou/tlMZKP5MtHrQ8d0lBAQx5LSdAxZPTF9ffTYa1CAT 7epvED0s+/me0iNdU0xoTm3eBe8crXexKBg23j3c2i8Saw08Y4kx+Pu8QOMrYrkyflTEnu BBZ3bGHqv+z8W278hOIMb4PlxDcUF/wvPCpJu6garRN/eI+7q2rudiPKIPSKAXDZGn/Ldz rNDnJEa4yCqF+QeVcV0PY4nqEy1nqEM1BloSbC5NNDr6uLJ0VY5SP90511DEZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298355; a=rsa-sha256; cv=none; b=oi11/OFvZt2iI5GCg+6oc4nFi+ECIgFdLqrA8Hx3ES8Nn0Y7Vzz9j03XiQTyfsc6B2IpXn 6BQqogNNpP7SRXhmm9vYH4DBI9AyDlicDgsT8RpZDJ/DemzPCcFkpFMEaO71I1Wk5YayIw xUoYdmidykj4dTeXLERpm10aUvV9FLTYt1qjKdi7A95giY2hzY9Bp9MMDMddVW3EZyM6dm kmsvo3o3oIrSSi9T7hfW4Ti6shZjNjReeJq6wDmkeI7icvJ8HT408b3z8+RzyC7Zc0Pr1O sk7///cQgTQngQlPZQNx+Uj/8w1nRj4cRCqJImhnxaVXr/MdZhgLCJqJWteO6w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298355; 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=oLTCwXK93vGJyp2EMtbg5OddMzWctErCx+Y+XpoFmhY=; b=klQo1JzES/1e3a7LS4lbZj/KdXW0vpyUhfF3pGU7iNZJp1VX4obL1pppJUhz7CCPSQPwBM d4EivepJUwETvH2X0blQLsI/+wUvqKt/sRwJS8E2bzB6IWaDNdwIE0n91fvJC/NkO/wMZy 7+uFQXYBPetrWMJHBP++efCuc0Ybk4baORhRYQfDYiWeyOO/+x61SkRRa0iaLM51VNKW7T RcqhR1VxLGn3BsmkC7itOLen0ShXx8UeOw0/toEMIY6YRyygECE2t57vtWX//onnbuRoXb rS0RskJ9YwcjxQ+x96swM2SLEkHRegRMRc0uuM3YpXS3bRfPNmD+KTvoSt1idA== 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 4VJwFH3Bw9zxXx; Tue, 16 Apr 2024 20:12:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCZ32037344; Tue, 16 Apr 2024 20:12:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCZp0037341; Tue, 16 Apr 2024 20:12:35 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:35 GMT Message-Id: <202404162012.43GKCZp0037341@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 03de11635be1 - stable/14 - loader: Font module is EFI dependent List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 03de11635be102d0ccfe7e81b550873d319e5a87 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=03de11635be102d0ccfe7e81b550873d319e5a87 commit 03de11635be102d0ccfe7e81b550873d319e5a87 Author: Warner Losh AuthorDate: 2024-02-02 01:37:12 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 loader: Font module is EFI dependent The font module is part of the gfx_fb support. Since we share this file between EFI and kboot, we only want to pass the font data to the kernel when we're booting from EFI, not kboot. Sponsored by: Netflix (cherry picked from commit 784f925e507f441206279a1e8776629fa7cdd14c) --- stand/efi/loader/bootinfo.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stand/efi/loader/bootinfo.c b/stand/efi/loader/bootinfo.c index f47d81e23591..13b6df9c5b06 100644 --- a/stand/efi/loader/bootinfo.c +++ b/stand/efi/loader/bootinfo.c @@ -386,10 +386,12 @@ bi_load(char *args, vm_offset_t *modulep, vm_offset_t *kernendp, bool exit_bs) /* Pad to a page boundary. */ addr = roundup(addr, PAGE_SIZE); +#ifdef EFI addr = build_font_module(addr); /* Pad to a page boundary. */ addr = roundup(addr, PAGE_SIZE); +#endif /* Copy our environment. */ envp = addr; From nobody Tue Apr 16 20:12:36 2024 X-Original-To: dev-commits-src-branches@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 4VJwFJ6ldvz5H0MM; Tue, 16 Apr 2024 20:12:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFJ4lR8z4ssn; Tue, 16 Apr 2024 20:12:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298356; 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=plei8EbtF5Sw127hm0W4ZjO0uH/H4zXRPde0yT2xfU4=; b=uh9fY81zimiVmeahxMEIBBtaGNYDujXgy1+UnHMPHp8mUJ8RBwxVf5110fvrDNtUU/Niuu ebJuCoh6GuxAbZAUcXOtXP08uUKmPjEIyJyYQgx11+F6zS+juciOXTBSRzEIuteqDmQx5P 6aogZS9K1jjmF9sXfKvLVkysoVQkjwCkuHot16R0sEVInpi3NMpNaiDkNL1Mj2dP6nDkU1 ZzKvNGrfm6o1KrD77/nhA96ISNpn7eus7BCUoSeq8WfC5xmMDK+hLkIVZLByUwDmNbPXf+ 0uslmYKOTInZxqwalmC3XITJ5QuIiwtXxWUAJKB89QprnZGbK2vN0B1w2qPt0Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298356; a=rsa-sha256; cv=none; b=wzNbjOg8bbjRWazZUNIhYQ8gshSxJDLE5m6HgNHnfdYbVKMj0kJeFiHvtCdg4zWPzRm1Ib NQLIPpe+sqdzxstC5+dXlLkx+02m1GXwp4ekwEKke0KMyk+pkrq20pAo/b0y/NZQOogTdW f7WILXGtIRLnWG4qe+E5gxVFp1ur+yMjHHeTiZLqB4vFwTEtXwiu7M6unPUk2IuqUyd+St ta3zKT7Am5lkYISvMR1AwlZCI0XY6CuibF6povXUrXw5hgz4PBPYoyzzcIdY4ju9JlkY5T NHR1poJrHenQSCiCrd9EdFSL/hlYQOAh2ryPO4pWreaduBAYZmUw9hFv0dK8ig== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298356; 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=plei8EbtF5Sw127hm0W4ZjO0uH/H4zXRPde0yT2xfU4=; b=MNMz+14YPWbSxJeK8YJrqdsEm9xen0BXgufhWedUPAJUC22V8xUjbRNX3Nf36jVQ7WPPcD RiDd6dCCLT4fZj0xbjVWSTsyRn+GO2n5Vl3h6vuUfan9BKTxdJaFo38r2XuvAuLqKBWMF4 3i27pc6SqkCgiIoJl0kmpzA41CjeuM3G0Px/r3snSB+xnHMA2ehoI2CtHsYXxUkXr1Tti3 y4Qs3D3oIyP/N1rcbniw22tJKYdBKW1H+ZBoSzSjMt3eqbW6SSu40HKO9rLv6yChJKeeMK X6Hp7GmJoijaCp91nZEYKlakSB7UAMA0zst6sOFXnV2ROJDt3rsYZLZySj08Ew== 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 4VJwFJ4JrWzwwB; Tue, 16 Apr 2024 20:12:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCa7o037401; Tue, 16 Apr 2024 20:12:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCagr037398; Tue, 16 Apr 2024 20:12:36 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:36 GMT Message-Id: <202404162012.43GKCagr037398@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: cfe4f061a78a - stable/14 - loader: Document the lua loader table. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cfe4f061a78af28bc9a63617766697b154c3a829 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=cfe4f061a78af28bc9a63617766697b154c3a829 commit cfe4f061a78af28bc9a63617766697b154c3a829 Author: Warner Losh AuthorDate: 2024-02-10 18:49:09 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 loader: Document the lua loader table. Document all the public functions from the "loader" table. Sponsored by: Netflix Reviewed by: pauamma_gundo.com, tsoome, kevans Differential Revision: https://reviews.freebsd.org/D43701 (cherry picked from commit 621dae89f3c70b86bef255a621a76bf553f733ff) --- stand/lua/Makefile | 1 + stand/lua/loader.lua.8 | 247 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 248 insertions(+) diff --git a/stand/lua/Makefile b/stand/lua/Makefile index 6b1064dc1815..e8fa16e6b589 100644 --- a/stand/lua/Makefile +++ b/stand/lua/Makefile @@ -8,6 +8,7 @@ MAN= loader.conf.lua.5 \ core.lua.8 \ drawer.lua.8 \ hook.lua.8 \ + loader.lua.8 \ menu.lua.8 \ password.lua.8 \ screen.lua.8 diff --git a/stand/lua/loader.lua.8 b/stand/lua/loader.lua.8 new file mode 100644 index 000000000000..cd436255d4a5 --- /dev/null +++ b/stand/lua/loader.lua.8 @@ -0,0 +1,247 @@ +.\" +.\" Copyright (c) 2024 Netflix, Inc. +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.Dd February 6, 2024 +.Dt LOADER.LUA 8 +.Os +.Sh NAME +.Nm loader.lua +.Nd Fx Lua loader module +.Sh DESCRIPTION +The built-in Lua bindings for the +.Fx +boot loaders using the Lua interpreter +are available via the +.Ic loader +table. +.Pp +The +.Ic loader +table is always available in Lua scripts. +There is no need to require it like other loader-specific modules. +.Ss Exported Variables +The following variables are provided by the Lua interpreter in the +.Nm loader +table: +.Bl -tag -width machine_arch +.It Ic machine +The target's +.Va hw.machine +.Xr sysctl 8 +value. +.It Ic machine_arch +The target's +.Va hw.machine_arch +.Xr sysctl 8 +value. +Some boot loaders are 32-bit applications that then load a 64-bit +kernel. +In these cases, +.Ic machine_arch +represents the 32-bit architecture, not the 64-bit architecture. +.It Ic lua_path +The current lua loading path. +.It Ic version +The version of the boot program. +.El +.Ss Exported Functions +The following functions are exported in the +.Nm loader +table. +.Bl -tag -width term_putimage +.It Fn delay usec +Delay for +.Va usec +microseconds. +.It Fn command_error +Returns the error string from the last command to fail. +.It Fn command argc argv +Like +.Fn perform +but the arguments are already parsed onto the stack. +.It Fn interpret str +Execute the loader builtin command +.Va str +as if it were typed by the user. +This will first try to execute +.Va str +as Lua. +If that fails, it will attempt to execute it as a cli command, +including those defined by the +.Xr cli.lua 8 +mechanism. +If that fails, it will attempt to execute it as a builtin command +and return the same values as +.Fn perform . +.It Fn parse str +Parses the command +.Va str +into its words and return those words on the stack. +.It Fn getenv name +Obtains the value of the environment variable +.Va name . +.It Fn has_command cmd +returns +.Va true +if +.Va commmand +is present in the interpreter as a builtin. +Otherwise it returns +.Va nil +and an error string. +It does not check the +.Dq cli +table to see if a user defined command has been created. +.It Fn has_feature feature +returns +.Va true +if the +.Va feature +is enabled. +Otherwise it returns +.Va nil +and an error string. +.It Fn perform str +Execute the loader builtin command +.Va str . +Returns the result of the command, one of the following values: +.Bl -tag -width loader -offset indent +.It loader.CMD_OK +The command completed successfully. +.It loader.CMD_WARN +The command was successful, but the user stopped its output +prematurely. +.It loader.CMD_ERROR +The command did not complete successfully. +Use +.Va command_error +to retrieve the error. +.It loader.CMD_CRIT +The command returned a critical error that was already printed. +.It loader.CMD_FATAL +The command determined continuation was not possible +and the loader panicked. +In practice, though, +.Fn panic +does not return. +.El +.It Fn printc str +Outputs the string using the loader's +.Fn putchar +function. +This function is also available globally as +.Fn printc . +.It Fn setenv name value +Insert or reset the environment variable +.Va name +into the loader's environment list. +If no environment variable with this name exists, one is created. +If one exists, its value is replaced. +.It Fn time +Returns the loader's notion of time, in seconds since 1970. +The value of loader's notion varies somewhat between different loading +environments. +.It Fn unsetenv name +Removes the environment variable +.Va name +from the loader's environment list. +.It Fn fb_bezier x0 y0 x1 y1 x2 y2 width +Draw a bezier curve through the points +.Pq Va x0 , Va y0 , +.Pq Va x1 , Va y1 , +and +.Pq Va x2 , Va y2 +of width +.Va width . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_drawrect x0 y0 x1 y1 fill +Fill in a rectangle with the pixel +.Va fill +with the corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_line x0 y0 x1 y1 width +Draw a line from +.Pq Va x0 , Va y0 +to +.Pq Va x1 , Va y1 +with a width of +.Va width . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_putimage name x0 y0 x1 y1 f +Load the PNG file +.Va name +and place it in the rectangle +with the corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 +and fill with pixel +.Va f . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_set_pixel x y +Sets the pixel at +.Pq Va x , Va y . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn term_drawrect x0 y0 x1 y1 +Draw the outline of a rectangle with the text coordinate corners of +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 . +The units are in character cells and have an origin of +.Pq 1 , 1 . +.It Fn term_putimage name x0 y0 x1 y1 f +Load the PNG file +.Va name +and place it in the rectangle +with the text coordinate corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 +and fill with pixel +.Va f . +The units are in character cells and have an origin of +.Pq 1 , 1 . +.El +.Pp +The functions starting with +.Fn fb_ +and +.Fn term_ +are optional. +They should only be used if they are non-nil and if +.Fn core.isFramebufferConsole +is true. +.Ss Default File +In addition, the Lua interpreters start with the file +.Pa /boot/lua/loader.lua +when they start to boot the system. +The default one will fixup the screen, load the configuration files, check for a +password, and then load the menu or load the kernel file and then return. +If autoboot is enabled, the loaded files will boot. +.Sh SEE ALSO +.Xr loader.conf 5 , +.Xr core.lua 8 , +.Xr loader 8 , +.Xr sysctl 8 +.Sh AUTHORS +The +.Nm +man page was written by +.An Warner Losh Aq Mt imp@FreeBSD.org . +.Sh BUGS +.Fn command +and +.Fn perform +should return a tuple when there's +.Va CMD_ERROR +or worse. From nobody Tue Apr 16 20:12:37 2024 X-Original-To: dev-commits-src-branches@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 4VJwFL0KC8z5HT5L; Tue, 16 Apr 2024 20:12:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFK5SqPz4sqj; Tue, 16 Apr 2024 20:12:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298357; 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=avQGS0o00sNi1szB/EHvSI0td78A1cQNf9Ail/NffJQ=; b=KXKXxSkHElrExLv58N14qlbKaNsmtdAxHJo6YSs2xfXpQH9LRNT7NQvK5rq8U5DcGGX9wB TqeEHQlMktcuBacBk4r5dpMfKFDogi2Ht8DnkVrDFHJ7wfHSqrsNTDVRuSB6gheuCiQQ0l Dp8WWy2rAwraTUnC38dl5Fy2S1VdQTi9pni18NXNrSAqv1F8rLxK70krIe/1OX49Z5OM7c VSffeU/EvVxsigLGLN21AyJtlcHeyGiy0K1uZ8LNer6MbZTS9CVdJ6YfqzV+c4MQZf+gF9 pDn5PwnIqr29Kx7FcvHf4v345Eq4P9IFhUk4Hq8ePU/qDYrs4KvWZRGsNbfhvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298357; a=rsa-sha256; cv=none; b=JcSfemHo4FhzrZ1Hv3UDwclPGnn3C1FAm82djdeBW3ZLXIR0jTMfInZGfjENbL2SMcNbsv qytUOVLZaGRnnapU76xLlfPVutMb0hxvF+OFMuvWf/xx06PqlqNq9vpFXbYvCjvPQNapwF UhRM0ROWBJP+1dL5JzMUcz/3izldqgRAU55t8h9PugGz6uBYxdZ+r260Zajns5qQwr+if2 pvAH4kViCl1BbVmZkEA4zjBUHA3OcTMsQlfBZVi7T4n3PLCEgmAeFTR5fWjzLg5L5Y9Ofy RJlTpVhOY31/HNU5eEwAJyLoZnghfb/SEBW6jMmyHMGeAtmZbg8MmHUFcMhYuA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298357; 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=avQGS0o00sNi1szB/EHvSI0td78A1cQNf9Ail/NffJQ=; b=bJOklq68CrB09185CKZaNXGpflrg6HxAmj/vtBTbemC0bidjk7vjQ89w/YlsIKhMEuWPmr lVSPlNuvQzfXz5ep7sv7RJuTaZonv/8hQ+thh+beOf9RJ4a2c6lTmq/7y5Mmh7qPj62WHN GwX99pizVVGMczDjKGXkdJiQkN0Ob5+dpYNKWij2PmAqzta0nL9PX5RXPY8Dskg1V+5YgY SD9dHJupM4VC7Is2WRo/xjpH1geRij8HudRek+BLwmRo+5OU7bkhG96MiP05e/pr1T2iKN K7RIEI+F5GiuU531DxlH6MDLQDCGp5Sf8zjSc1JcI6/sFXwZhzL1JihdmnDGBA== 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 4VJwFK50gCzxXy; Tue, 16 Apr 2024 20:12:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCbwu037454; Tue, 16 Apr 2024 20:12:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCbww037451; Tue, 16 Apr 2024 20:12:37 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:37 GMT Message-Id: <202404162012.43GKCbww037451@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 16d49d0e4fe7 - stable/14 - libsecureboot do not report expected unverified files List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 16d49d0e4fe7061832c2c23ff9e91e7abdc272ac Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=16d49d0e4fe7061832c2c23ff9e91e7abdc272ac commit 16d49d0e4fe7061832c2c23ff9e91e7abdc272ac Author: Simon J. Gerraty AuthorDate: 2024-02-12 22:35:01 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 libsecureboot do not report expected unverified files By default only report unverified files at severity VE_WANT and above. This inlcudes *.conf but not *.hints, *.cookie or *.tgz which get VE_TRY as their severity. If Verbose is set to 0, then VerifyFlags should default to 0 too. Thus the combination of module_verbose=0 VE_VEBOSE=0 is sufficient to make the loader almost totally silent. When verify_prep has to find_manifest and it is verified ok return VE_NOT_CHECKED to verify_file so that it can skip repeating verify_fd Also add better debugging output for is_verified and add_verify_status. vectx handle compressed modules When verifying a compressed module (.ko.gz or .ko.bz2) stat() reports the size as -1 (unknown). vectx_lseek needs to spot this during closing - and just read until EOF is hit. Note: because of the way libsa's open() works, verify_prep will see the path to be verified as module.ko not module.ko.bz2 etc. This is actually ok, because we need a separate module.ko.bz2 entry so that the package can be verified, and the hash for module.ko is of the uncompressed file which is what vectx will see. Re-work local.trust.mk so site.trust.mk need only set VE_SIGN_URL_LIST (if using the mentioned signing server) interp.c: restrict interactive input Apply the same restrictions to interactive input as for unverified conf and hints files. Use version.veriexec when LOADER_VERIEXEC is yes Reviewed by: kevans Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D43810 (cherry picked from commit f616d61ab6b071e5fbfdbae7033a9ef04c1444ad) --- lib/libsecureboot/Makefile.inc | 8 +- lib/libsecureboot/Makefile.libsa.inc | 7 +- lib/libsecureboot/h/verify_file.h | 1 + lib/libsecureboot/local.trust.mk | 143 +++++++++++++++-------------------- lib/libsecureboot/vectx.c | 26 +++++-- lib/libsecureboot/verify_file.c | 35 +++++++-- stand/common/interp.c | 8 ++ stand/efi/loader/version.veriexec | 7 ++ stand/veriexec.mk | 3 + 9 files changed, 136 insertions(+), 102 deletions(-) diff --git a/lib/libsecureboot/Makefile.inc b/lib/libsecureboot/Makefile.inc index ff40b919bad3..b09e44edc1b0 100644 --- a/lib/libsecureboot/Makefile.inc +++ b/lib/libsecureboot/Makefile.inc @@ -58,6 +58,10 @@ _2ndLAST_PEM_USE: .USE sed -n "`grep -n .-BEGIN ${.ALLSRC:M*.pem} | tail -2 | \ sed 's,:.*,,' | xargs | (read a b; echo $$a,$$(($$b - 1)))`p" ${.ALLSRC:M*.pem} > ${.TARGET} +# rules to populate the [tv]*.pem files we use to generate ta.h +# and can add/alter VE_*_LIST as desired. +.-include "local.trust.mk" + # list of hashes we support VE_HASH_LIST?= SHA256 @@ -74,10 +78,6 @@ VE_SIGNATURE_EXT_LIST?= sig # needs to be yes for FIPS 140-2 compliance VE_SELF_TESTS?= no -# rules to populate the [tv]*.pem files we use to generate ta.h -# and can add/alter VE_*_LIST as desired. -.-include "local.trust.mk" - # this is what we use as our trust anchor CFLAGS+= -I. -DTRUST_ANCHOR_STR=ta_PEM diff --git a/lib/libsecureboot/Makefile.libsa.inc b/lib/libsecureboot/Makefile.libsa.inc index 76e0a91bc20a..907c8e8f7533 100644 --- a/lib/libsecureboot/Makefile.libsa.inc +++ b/lib/libsecureboot/Makefile.libsa.inc @@ -46,9 +46,12 @@ manifests.h: echo '${VE_MANIFEST_LIST:@m@"$m",${.newline}@}'; \ echo 'NULL };' ) > ${.TARGET} +# only add these if set XCFLAGS.verify_file+= \ - -DVE_DEBUG_LEVEL=${VE_DEBUG_LEVEL:U0} \ - -DVE_VERBOSE_DEFAULT=${VE_VERBOSE_DEFAULT:U0} \ + ${VE_DEBUG_LEVEL \ + VE_VERBOSE_DEFAULT \ + VE_VERIFY_FLAGS \ + :L:@v@${$v:S,^,-D$v=,}@} .if !empty(MANIFEST_SKIP_ALWAYS) XCFLAGS.verify_file+= -DMANIFEST_SKIP_ALWAYS=\"${MANIFEST_SKIP_ALWAYS}\" diff --git a/lib/libsecureboot/h/verify_file.h b/lib/libsecureboot/h/verify_file.h index 88d758b27af4..f918ed6d0e38 100644 --- a/lib/libsecureboot/h/verify_file.h +++ b/lib/libsecureboot/h/verify_file.h @@ -46,6 +46,7 @@ int verify_prep(int, const char *, off_t, struct stat *, const char *); void ve_debug_set(int); char *ve_error_get(void); void ve_efi_init(void); +void ve_status_set(int, int); int ve_status_get(int); int load_manifest(const char *, const char *, const char *, struct stat *); int pass_manifest(const char *, const char *); diff --git a/lib/libsecureboot/local.trust.mk b/lib/libsecureboot/local.trust.mk index 7b1e5f7ee97b..b009139a2f68 100644 --- a/lib/libsecureboot/local.trust.mk +++ b/lib/libsecureboot/local.trust.mk @@ -5,65 +5,69 @@ # the signing server (http://www.crufty.net/sjg/blog/signing-server.htm) # for each key will provide the appropriate certificate chain on request -# force these for Junos -#MANIFEST_SKIP_ALWAYS= boot -VE_HASH_LIST= \ - SHA1 \ - SHA256 \ - SHA384 \ - SHA512 - -VE_SIGNATURE_LIST= \ - ECDSA \ - RSA - -VE_SIGNATURE_EXT_LIST= \ - esig \ - rsig - -VE_SELF_TESTS= yes - -.if ${MACHINE} == "host" && ${.CURDIR:T} == "tests" - -VE_SIGNATURE_LIST+= \ - DEPRECATED_RSA_SHA1 +# allow site control +.-include "site.trust.mk" -VE_SIGNATURE_EXT_LIST+= \ - sig -.endif +#VE_DEBUG_LEVEL?=3 +#VE_VERBOSE_DEFAULT?=2 -# add OpenPGP support - possibly dormant -VE_SIGNATURE_LIST+= OPENPGP -VE_SIGNATURE_EXT_LIST+= asc +VE_HASH_LIST?= \ + SHA256 \ + SHA384 \ -# allow site override of all the above -.-include "site.trust.mk" +VE_SELF_TESTS?= yes -SIGNER ?= ${SB_TOOLS_PATH:U/volume/buildtools/bin}/sign.py +# client for the signing server above +SIGNER?= /opt/sigs/sign.py .if exists(${SIGNER}) -SIGN_HOST ?= ${SB_SITE:Usvl}-junos-signer.juniper.net -ECDSA_PORT:= ${133%y:L:gmtime} -SIGN_ECDSA= ${PYTHON} ${SIGNER} -u ${SIGN_HOST}:${ECDSA_PORT} -h sha256 -RSA2_PORT:= ${163%y:L:gmtime} -SIGN_RSA2= ${PYTHON} ${SIGNER} -u ${SIGN_HOST}:${RSA2_PORT} -h sha256 +OPENPGP_SIGNER?= ${SIGNER:H}/openpgp-sign.py +OPENPGP_SIGN_FLAGS= -a +OPENPGP_SIGN_HOST?= localhost +SIGN_HOST ?= localhost + +# A list of name/ext/url tuples. +# name should be one of ECDSA, OPENPGP or RSA, they can be repeated +# Order of ext list implies runtime preference so do not sort! +VE_SIGN_URL_LIST?= \ + ECDSA/esig/${SIGN_HOST}:${133%y:L:localtime} \ + RSA/rsig/${SIGN_HOST}:${163%y:L:localtime} \ + OPENPGP/asc/${OPENPGP_SIGN_HOST}:1234 \ + +.for sig ext url in ${VE_SIGN_URL_LIST:@x@${x:H:H} ${x:H:T} ${x:T}@} +SIGN_${sig}:= ${PYTHON} ${${sig}_SIGNER:U${SIGNER}} -u ${url} ${${sig}_SIGN_FLAGS:U-h sha256} + +VE_SIGNATURE_LIST+= ${sig} +VE_SIGNATURE_EXT_LIST+= ${ext} + +_SIGN_${sig}_USE: .USE + ${SIGN_${sig}} ${.ALLSRC} + +_TA_${sig}_USE: .USE + ${SIGN_${sig}} -C ${.TARGET} + +.if ${sig} == "OPENPGP" +ta_${sig:tl}.${ext}: _TA_${sig}_USE +ta_${ext}.h: ta_${sig:tl}.${ext} +.else +${ext:S/sig/certs/}.pem: _TA_${sig}_USE +# the last cert in the chain is the one we want +ta_${ext}.pem: ${ext:S/sig/certs/}.pem _LAST_PEM_USE +ta.h: ta_${ext}.pem +.if ${VE_SELF_TESTS} != "no" +# we use the 2nd last cert to test verification +vc_${ext}.pem: ${ext:S/sig/certs/}.pem _2ndLAST_PEM_USE +ta.h: vc_${ext}.pem +.endif +.endif +.endfor -# deal with quirk of our .esig format -XCFLAGS.vets+= -DVE_ECDSA_HASH_AGAIN +# cleanup duplicates +VE_SIGNATURE_LIST:= ${VE_SIGNATURE_LIST:O:u} -.if !empty(OPENPGP_SIGN_URL) +.if target(ta_asc.h) XCFLAGS.opgp_key+= -DHAVE_TA_ASC_H -VE_SIGNATURE_LIST+= OPENPGP -VE_SIGNATURE_EXT_LIST+= asc - -SIGN_OPENPGP= ${PYTHON} ${SIGNER:H}/openpgp-sign.py -a -u ${OPENPGP_SIGN_URL} - -ta_openpgp.asc: - ${SIGN_OPENPGP} -C ${.TARGET} - -ta_asc.h: ta_openpgp.asc - .if ${VE_SELF_TESTS} != "no" # for self test vc_openpgp.asc: ta_openpgp.asc @@ -74,48 +78,26 @@ ta_asc.h: vc_openpgp.asc .endif .endif -rcerts.pem: - ${SIGN_RSA2} -C ${.TARGET} - -ecerts.pem: - ${SIGN_ECDSA} -C ${.TARGET} - -.if ${VE_SIGNATURE_LIST:tu:MECDSA} != "" -# the last cert in the chain is the one we want -ta_ec.pem: ecerts.pem _LAST_PEM_USE -ta.h: ta_ec.pem -.if ${VE_SELF_TESTS} != "no" -# these are for verification self test -vc_ec.pem: ecerts.pem _2ndLAST_PEM_USE -ta.h: vc_ec.pem -.endif -.endif - -.if ${VE_SIGNATURE_LIST:tu:MRSA} != "" -ta_rsa.pem: rcerts.pem _LAST_PEM_USE -ta.h: ta_rsa.pem -.if ${VE_SELF_TESTS} != "no" -vc_rsa.pem: rcerts.pem _2ndLAST_PEM_USE -ta.h: vc_rsa.pem -.endif -.endif - -# we take the mtime of this as our baseline time -#BUILD_UTC_FILE= ecerts.pem -#VE_DEBUG_LEVEL=3 -#VE_VERBOSE_DEFAULT=1 - .else +VE_SIGNATURE_LIST?= RSA + # you need to provide t*.pem or t*.asc files for each trust anchor +# below assumes they are named ta_${ext}.pem eg ta_esig.pem for ECDSA .if empty(TRUST_ANCHORS) TRUST_ANCHORS!= cd ${.CURDIR} && 'ls' -1 *.pem t*.asc 2> /dev/null .endif .if empty(TRUST_ANCHORS) && ${MK_LOADER_EFI_SECUREBOOT} != "yes" .error Need TRUST_ANCHORS see ${.PARSEDIR}/README.rst .endif + .if ${TRUST_ANCHORS:T:Mt*.pem} != "" ta.h: ${TRUST_ANCHORS:M*.pem} +VE_SIGNATURE_EXT_LIST?= ${TRUST_ANCHORS:T:Mt*.pem:R:S/ta_//} +.if ${VE_SIGNATURE_EXT_LIST:Mesig} != "" +VE_SIGNATURE_LIST+= ECDSA +.endif .endif + .if ${TRUST_ANCHORS:T:Mt*.asc} != "" VE_SIGNATURE_LIST+= OPENPGP VE_SIGNATURE_EXT_LIST+= asc @@ -124,4 +106,3 @@ ta_asc.h: ${TRUST_ANCHORS:M*.asc} # we take the mtime of this as our baseline time BUILD_UTC_FILE?= ${TRUST_ANCHORS:[1]} .endif - diff --git a/lib/libsecureboot/vectx.c b/lib/libsecureboot/vectx.c index dba728421ce4..2d56830cd81d 100644 --- a/lib/libsecureboot/vectx.c +++ b/lib/libsecureboot/vectx.c @@ -306,19 +306,31 @@ vectx_lseek(struct vectx *ctx, off_t off, int whence) DEBUG_PRINTF(3, ("%s(%s, %ld, %d)\n", __func__, ctx->vec_path, (long)off, whence)); if (whence == SEEK_END && off <= 0) { - if (ctx->vec_closing && ctx->vec_hashed < ctx->vec_size) { - DEBUG_PRINTF(3, ("%s: SEEK_END %ld\n", - __func__, - (long)(ctx->vec_size - ctx->vec_hashed))); + if (ctx->vec_size < 0) { + if (ctx->vec_closing) { + /* size unknown - read until EOF */ + do { + n = vectx_read(ctx, buf, PAGE_SIZE); + if (n < 0) + return (n); + } while (n > 0); + return (ctx->vec_off); + } + } else { + if (ctx->vec_closing && ctx->vec_hashed < ctx->vec_size) { + DEBUG_PRINTF(3, ("%s: SEEK_END %ld\n", + __func__, + (long)(ctx->vec_size - ctx->vec_hashed))); + } + whence = SEEK_SET; + off += ctx->vec_size; } - whence = SEEK_SET; - off += ctx->vec_size; } else if (whence == SEEK_CUR) { whence = SEEK_SET; off += ctx->vec_off; } if (whence != SEEK_SET || - off > ctx->vec_size) { + (off > ctx->vec_size && ctx->vec_size > 0)) { printf("ERROR: %s: unsupported operation: whence=%d off=%ld -> %ld\n", __func__, whence, (long)ctx->vec_off, (long)off); return (-1); diff --git a/lib/libsecureboot/verify_file.c b/lib/libsecureboot/verify_file.c index 1e1c714d1fa8..eaf8fa94d75f 100644 --- a/lib/libsecureboot/verify_file.c +++ b/lib/libsecureboot/verify_file.c @@ -82,7 +82,7 @@ static int Verbose = VE_VERBOSE_DEFAULT; /** * @brief set ve status for fd */ -static void +void ve_status_set(int fd, int ves) { if (fd >= 0 && fd < SOPEN_MAX) { @@ -131,15 +131,21 @@ int is_verified(struct stat *stp) { struct verify_status *vsp; + int rc = VE_NOT_CHECKED; if (stp->st_ino > 0) { for (vsp = verified_files; vsp != NULL; vsp = vsp->vs_next) { if (stp->st_dev == vsp->vs_dev && - stp->st_ino == vsp->vs_ino) - return (vsp->vs_status); + stp->st_ino == vsp->vs_ino) { + rc = vsp->vs_status; + break; + } } } - return (VE_NOT_CHECKED); + DEBUG_PRINTF(4, ("%s: dev=%lld,ino=%llu,status=%d\n", + __func__, (long long)stp->st_dev, + (unsigned long long)stp->st_ino, rc)); + return (rc); } /* most recent first, since most likely to see repeated calls. */ @@ -156,6 +162,9 @@ add_verify_status(struct stat *stp, int status) vsp->vs_status = status; verified_files = vsp; } + DEBUG_PRINTF(4, ("%s: dev=%lld,ino=%llu,status=%d\n", + __func__, (long long)stp->st_dev, + (unsigned long long)stp->st_ino, status)); } @@ -270,11 +279,14 @@ severity_guess(const char *filename) /* * Some files like *.conf and *.hints may be unsigned, * a *.tgz is expected to have its own signed manifest. + * We allow *.conf to get VE_WANT, but files we expect + * to always be unverified get VE_TRY and we will not + * report them. */ if ((cp = strrchr(filename, '.'))) { - if (strcmp(cp, ".conf") == 0 || - strcmp(cp, ".cookie") == 0 || + if (strcmp(cp, ".cookie") == 0 || strcmp(cp, ".hints") == 0 || + strcmp(cp, ".order") == 0 || strcmp(cp, ".tgz") == 0) return (VE_TRY); if (strcmp(cp, ".4th") == 0 || @@ -398,6 +410,8 @@ void verify_report(const char *path, int severity, int status, struct stat *stp) { if (status < 0 || status == VE_FINGERPRINT_IGNORE) { + if (Verbose < VE_VERBOSE_ALL && severity < VE_WANT) + return; if (Verbose >= VE_VERBOSE_UNVERIFIED || severity > VE_TRY || status <= VE_FINGERPRINT_WRONG) { if (Verbose == VE_VERBOSE_DEBUG && stp != NULL) @@ -462,9 +476,10 @@ verify_prep(int fd, const char *filename, off_t off, struct stat *stp, caller, fd, filename, (long long)off, (long long)stp->st_dev, (unsigned long long)stp->st_ino)); rc = is_verified(stp); - DEBUG_PRINTF(4,("verify_prep: is_verified()->%d\n", rc)); if (rc == VE_NOT_CHECKED) { rc = find_manifest(filename); + if (rc == VE_VERIFIED) + rc = VE_NOT_CHECKED; } else { ve_status_set(fd, rc); } @@ -511,7 +526,8 @@ verify_file(int fd, const char *filename, off_t off, int severity, if (check_verbose) { check_verbose = 0; Verbose = getenv_int("VE_VERBOSE", VE_VERBOSE_DEFAULT); - VerifyFlags = getenv_int("VE_VERIFY_FLAGS", VEF_VERBOSE); + VerifyFlags = getenv_int("VE_VERIFY_FLAGS", + Verbose ? VEF_VERBOSE : 0); #ifndef UNIT_TEST ve_debug_set(getenv_int("VE_DEBUG_LEVEL", VE_DEBUG_LEVEL)); #endif @@ -523,6 +539,9 @@ verify_file(int fd, const char *filename, off_t off, int severity, return (0); if (rc != VE_FINGERPRINT_WRONG && loaded_manifests) { + if (rc != VE_NOT_CHECKED) + return (rc); + if (severity <= VE_GUESS) severity = severity_guess(filename); #ifdef VE_PCR_SUPPORT diff --git a/stand/common/interp.c b/stand/common/interp.c index b71e0858e702..0f142902b4ac 100644 --- a/stand/common/interp.c +++ b/stand/common/interp.c @@ -35,6 +35,10 @@ #include #include "bootstrap.h" +#ifdef LOADER_VERIEXEC +#include +#endif + #define MAXARGS 20 /* maximum number of arguments allowed */ const char * volatile interp_identifier; @@ -79,6 +83,10 @@ interact(void) input[0] = '\0'; interp_emit_prompt(); ngets(input, sizeof(input)); +#ifdef LOADER_VERIEXEC + /* some settings should be restritcted */ + ve_status_set(-1, VE_UNVERIFIED_OK); +#endif interp_run(input); } } diff --git a/stand/efi/loader/version.veriexec b/stand/efi/loader/version.veriexec new file mode 100644 index 000000000000..5c9292310c04 --- /dev/null +++ b/stand/efi/loader/version.veriexec @@ -0,0 +1,7 @@ +NOTE ANY CHANGES YOU MAKE TO THE BOOTBLOCKS HERE. The format of this +file is important. Make sure the current version number is on line 6. + +2.1: SMBIOS 3 support +2.0: Secure boot support +1.1: Keep in sync with i386 version. +0.1: Initial i386 version. Derived from ia64. diff --git a/stand/veriexec.mk b/stand/veriexec.mk index 930e933be0a9..a0ff7d1e8489 100644 --- a/stand/veriexec.mk +++ b/stand/veriexec.mk @@ -1,4 +1,7 @@ .if ${MK_LOADER_VERIEXEC} != "no" +.if exists(${VERSION_FILE}.veriexec) +VERSION_FILE:= ${VERSION_FILE}.veriexec +.endif CFLAGS+= -DLOADER_VERIEXEC -I${SRCTOP}/lib/libsecureboot/h .if ${MK_LOADER_VERIEXEC_VECTX} != "no" CFLAGS+= -DLOADER_VERIEXEC_VECTX From nobody Tue Apr 16 20:12:38 2024 X-Original-To: dev-commits-src-branches@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 4VJwFM28qrz5H0Gs; Tue, 16 Apr 2024 20:12:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFL6GBFz4sjP; Tue, 16 Apr 2024 20:12:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298358; 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=aPQkOb72h+D1/e7XjuLmQYquFHWole+PXDzHB/hoQNw=; b=Zq9W8/wih7B7Nd+ha99low6hRiUwUc8QCf3aJrgEmvsXRuiolTNeGiwRwpzQEB2evyTT6e cRJFCaO51d2P2eqy9YlmjTUURUfs0HcPTh+AY1d9uJNho7WOQqNtLkVmQBE0n9LDf/jNjI emoooWCTKt8e/6KOLmX4LXDVDpLIDhTPRtMdcz50QjzgHj/a6IOAfTkCsP1vSpD2zGCE1I ag+6JUziis7PmzhxglAqu4F3uY6IaKU2YOqKJP8UHmcL3laJGHVk30aSnuNrPC+BOsoJN7 993tO1YyGGdgO4GmQx/9PM9ebFySpP6c1SO7XX4+SpMNnnaZf6bQ3in4r4ksXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298358; a=rsa-sha256; cv=none; b=s8/4NFM57B6tqMHQoKSllILNqTmXZTzCDQqM+hPwrSL2vZlAAqlGLCgcjC/GpUj6TdShV0 +bezr/qpPP9CqqE2QaBMeh47vFCCtZtMGGMmve+AVaprdndbJdxfHOV3DMWTRvLLUDyv6a 4xlScqytULNduAe1MkgYQvMndgG/moZTjv127opV+4Wv2hQzN9arXbXJqXFCMBAoVak7MC I95DH2+hdckXF3Cm/kvDM2fxTnKCYALgXAVxasPbFKfMsp3Ye/Q8Gyj0/8c+EmhKmuvQtd IKntupWWbA5ogZjzhuOahfe3aX1A5w+F/sUUKAdQfeLfdovxApraOXMG3gzKFw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298358; 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=aPQkOb72h+D1/e7XjuLmQYquFHWole+PXDzHB/hoQNw=; b=AX849OL3R92MyKuVNyGVNj+JxqilWK0oHAKYxjUhSoyeHCpSVD/J2ffAIjFJH84V9qobqJ 58wqWi01Ft+kUzfCb14gCCii1CZDyFDBGQgfMHUU9YTZvaiTnv62B0Gt1VPqrWerBGvA6H nuI6On+E7fF35yoekrYeVdFWQbdBFLJfuH3U6OIAUor7TFgpdvbojjZUfrYaVfa2lDLAsI m9iXLE8Y82bFaqby6cfuZDxTLNGzEEZRzTbmLNWLgV4j/RyZRLWijuSHmf+unjU7ZNhzxo rOw3futOwWufBId/HbGtww3EUPDufhQK8qN+OOm76E1YeyXJOzsS/58UHhZaaw== 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 4VJwFL5rSgzwhc; Tue, 16 Apr 2024 20:12:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCc1N037507; Tue, 16 Apr 2024 20:12:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCc6i037504; Tue, 16 Apr 2024 20:12:38 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:38 GMT Message-Id: <202404162012.43GKCc6i037504@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 3601f439783a - stable/14 - loader: export the CMD_ constants in loader table List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3601f439783a711c3860e9770cb654670b8e4ed1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3601f439783a711c3860e9770cb654670b8e4ed1 commit 3601f439783a711c3860e9770cb654670b8e4ed1 Author: Warner Losh AuthorDate: 2024-02-14 17:51:58 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:22 +0000 loader: export the CMD_ constants in loader table Export the CMD_OK, etc constants in the loader table. They are the return values of loader.perform, etc. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43821 (cherry picked from commit 62a52c15422470f97fc7b311d89c83f910bcc1b1) --- stand/liblua/lutils.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 274d9a39da21..8066d3f685f7 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -639,6 +639,16 @@ luaopen_loader(lua_State *L) lua_setfield(L, -2, "lua_path"); lua_pushinteger(L, bootprog_rev); lua_setfield(L, -2, "version"); + lua_pushinteger(L, CMD_OK); + lua_setfield(L, -2, "CMD_OK"); + lua_pushinteger(L, CMD_WARN); + lua_setfield(L, -2, "CMD_WARN"); + lua_pushinteger(L, CMD_ERROR); + lua_setfield(L, -2, "CMD_ERROR"); + lua_pushinteger(L, CMD_CRIT); + lua_setfield(L, -2, "CMD_CRIT"); + lua_pushinteger(L, CMD_FATAL); + lua_setfield(L, -2, "CMD_FATAL"); lua_add_features(L); /* Set global printc to loader.printc */ lua_register(L, "printc", lua_printc); From nobody Tue Apr 16 20:12:39 2024 X-Original-To: dev-commits-src-branches@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 4VJwFN2MxNz5H0Gt; Tue, 16 Apr 2024 20:12:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFM6vPzz4sr9; Tue, 16 Apr 2024 20:12:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298360; 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=uWLTM7vmORE8MmKsa4hdndGGE11lOor9D3EhpyIRJmw=; b=OKEuPGAH4GNU8EJ0nxLGHWuv36falVA2Itp0h9s4pK7O00m0aHuoPMmbcNCDZ3nEMenWxG jTcM/qV1uVsLASxHaPQD/qqodjOJZ/65pHVSRm0m6zNacder9UX9WLLxF3o6lcYzDDyOu0 uZB0r1ihLcIbcqFlnNsGOLj10HJHZaMOv1YVjnJiWpq7zOfxAvWDMC47guA30So4kSg6Da vkLkiSTDLESXGrz5E5EXfD6MqzsANbhSi3ZSMZPycYOwDY/SxhfRp6gQ3rpYIo0lbM7LdC p434ahiwcBGaVLiRGdegTxqxQJY5sWaDfMcfOZFQKE2MA8H+QMB5Z8LKNqxhUA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298360; a=rsa-sha256; cv=none; b=sU/JdFNOt7MHSbXZ39ESYECjCgvfj4zeJ0fKuLOqQWeKU3+psYAPxr/c7pYaoeJT7iCPMR b3U+S8lWO/+Sn2Rq8KT9qzcsftAR8OSYs1NJioBB8Wu2T6jSmDV62Jgioof7R1oq6ndDpL x53nED5mC8yMfKh0koTJq+LcsX6COXBbRNt3RArIwwCMKOwOqSwb0Lxe4aSuUF4klHJkd8 aR0wEKMgmqLIK1GTIAgPYq4RvFb8cEMyEym1eN2pxtR7GqVG8raUaoy1qKO2aQMzP8XMPP bonJ4Fcmobg2hEyhkNrd3iC+HALIqhe/mqukkIDSXaPiWrjOl9mAr3iI4vUAbg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298360; 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=uWLTM7vmORE8MmKsa4hdndGGE11lOor9D3EhpyIRJmw=; b=Gl7RvAtnflMqpHHrZUOqeI7R/Y2IjpgpKUy2rA4ifaxXEmdvOPhvJw8/c3sKN+lPj4lPum 5ONLcRsMVynJBlOQrjXOA3jH2L+s5N3V3o336zQci4CU78mensLt51lgRNUGYaFsBdgD1A YTdu/WS4Lr32YaHmcbPWRM3mZVJrzPSS8a1VTr7n1A49MvL3tPyzG4xgfrXH4Pob6ThTcu SHnWkCShbphNpDCJrhPqBn+kZtW/yZsAO9w3ep9O9AhpgphGQSM8x9DiP+SntIZqnHMbSx wOIgZV3PiA8qEeyPrVNfrYy7/tfTCfIfCGxKSsb8bDkxv2kXlgA01uS0IZJipg== 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 4VJwFM6WkFzxWN; Tue, 16 Apr 2024 20:12:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCdRE037563; Tue, 16 Apr 2024 20:12:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCdYb037560; Tue, 16 Apr 2024 20:12:39 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:39 GMT Message-Id: <202404162012.43GKCdYb037560@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 8ea26f3280f7 - stable/14 - loader: Fetch initial script from loader_lua env List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8ea26f3280f7df1aad1c34d5bad1472a02c18fdf Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=8ea26f3280f7df1aad1c34d5bad1472a02c18fdf commit 8ea26f3280f7df1aad1c34d5bad1472a02c18fdf Author: Warner Losh AuthorDate: 2024-02-14 17:51:38 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Fetch initial script from loader_lua env Sometimes it is nice to override the initial script that we run. Make it possible by fetching loader_lua from the env and using that instead of the default if prsent. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43819 (cherry picked from commit cd147a2a024301a796f307c7bae686305d2bf302) --- stand/common/interp_lua.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/stand/common/interp_lua.c b/stand/common/interp_lua.c index db58d80b2048..3f758baebc2d 100644 --- a/stand/common/interp_lua.c +++ b/stand/common/interp_lua.c @@ -123,7 +123,9 @@ interp_init(void) lua_pop(luap, 1); /* remove lib */ } - filename = LOADER_LUA; + filename = getenv("loader_lua"); + if (filename == NULL) + filename = LOADER_LUA; if (interp_include(filename) != 0) { const char *errstr = lua_tostring(luap, -1); errstr = errstr == NULL ? "unknown" : errstr; From nobody Tue Apr 16 20:12:40 2024 X-Original-To: dev-commits-src-branches@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 4VJwFP2bsjz5H0Py; Tue, 16 Apr 2024 20:12:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFP15QZz4stf; Tue, 16 Apr 2024 20:12:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298361; 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=zdXXLKRvURGqFP900aK1VMjvkb1maXYEJWlFgKb2MNg=; b=gpBLBUq70zAYD1Fmj05iOBe21vAp7TRPP9B5UYoe2VjZ9SW97qwu7BbIV2GaVaOA3p5ZUC vLLOqFiY+YDAwkMNFUVxrMMAO6g5Z0IZ3GgIIKBY+vVO2a07KJ60n3k0pp95B6i1T/M83y 2HTy2Ju+b0ZZg7N7erdQBc9Kt/NUHFoiq/vgFg5uur1+DA6Tf8tp+iN6N1Qd4JI0uBHhYn VdGWKSTyhw3pnHKm3HbmnkoUMDP8ZhShzoYyn2ds46DXwwYq2fE7Fr5hYFwqueFmyLUvFH 5lU/sCqRwSCW33GJ88BxTjA+ouecoXghyC3nrgAUS31VUcpiaWe6y/DDOHK8nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298361; a=rsa-sha256; cv=none; b=kabBR8bf2PtU+HUZ94WPRCftKWtWoTsMJxVSubCnTX+9at9GEj3FaL71CQQXrpQsy3YMD+ JuW79EkB8Bcxr7Q7QLvNoTQck/tPTlAwk6LWcjoVjy6BtHeIm5GkYZiclxpjk2daEd10TL jSk188cVI3mI0K8fEi4dd8w6F9LfcXl0F916nRzrtbA00BsgJGekbZziPqiUwSALlwzwJN tYVAvosb7K7bBkhYbYmTpvs/319srKyp5anH0bTTnjnT11DuDHrTXo5ehxzMQ57p9BQVh/ mgQX1CeMiXpjMUZG+pbvh+J4rWsg1OK7Eg1QF/PXeULSz1aYdps7E5kjigEQJQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298361; 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=zdXXLKRvURGqFP900aK1VMjvkb1maXYEJWlFgKb2MNg=; b=k2P8oXE4vhE/tEq8vr+Jk8qNLBvS7oZPHQuFLulDD82bvIh7ma2lM3mYfYJyopgVpOtdFe EPmIW/SJSWVtar6nI1iG0L5DqrlPt8uF/5uLVdNxbWoE4tKfF+WMoVDuTpbYBN1mZb+d/K pjfbEI9QnavSRkKjEWgU5BZhMu3RPh0mM0a25vblK+0DEAXOUYGC0/NU7NuEPz8XlYpilD hTf8LOlcKNuSimKOzjYnVHEdMZ+jlnhdJqqAbdPpiW8xk3AHNs5JhctRw2Er/HWhyaVF4f TAXSeWvo+PUzHpJORhNoYkfD3YyDuPqf5r3AZdqzyRYEaZtNfkl1YO8Pve9qZQ== 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 4VJwFP0j6zzxdc; Tue, 16 Apr 2024 20:12:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCeIf037605; Tue, 16 Apr 2024 20:12:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCeYl037602; Tue, 16 Apr 2024 20:12:40 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:40 GMT Message-Id: <202404162012.43GKCeYl037602@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 4b559231c468 - stable/14 - loader: Make vidc_biosputchar static List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4b559231c468a0361e3f520ecbbe2d65fb389f45 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=4b559231c468a0361e3f520ecbbe2d65fb389f45 commit 4b559231c468a0361e3f520ecbbe2d65fb389f45 Author: Warner Losh AuthorDate: 2024-02-14 18:07:10 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Make vidc_biosputchar static It's currently unused outside of vidconsole.c. Gerald Hicks' fix to the beep code from de37e4a6d2333/1998 introduced the funciton as static. Maxim Sobolev (sobomax) made it non-static since his spinconsole called it in c4c3b35172d67/2009. When sobomax dropped the direct call after making spinconsole console independent in b35172d67/2017, vidc_biosputchar remained a harmless unreferenced global. Make it static once again. Fixes: c7e10205ae0d Sponsored by: Netflix (cherry picked from commit a27c1350e43a863fbe2bf0927ef762a20babe5d5) --- stand/i386/libi386/vidconsole.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/i386/libi386/vidconsole.c b/stand/i386/libi386/vidconsole.c index aec41a6373d6..f8a6bf34acad 100644 --- a/stand/i386/libi386/vidconsole.c +++ b/stand/i386/libi386/vidconsole.c @@ -1046,7 +1046,7 @@ vidc_init(int arg) return (0); /* XXX reinit? */ } -void +static void vidc_biosputchar(int c) { From nobody Tue Apr 16 20:12:42 2024 X-Original-To: dev-commits-src-branches@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 4VJwFQ3BBTz5HT5Z; Tue, 16 Apr 2024 20:12:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFQ268Lz4t2c; Tue, 16 Apr 2024 20:12:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298362; 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=kLLqox1usmukP3K7oe34aDqPeR0MJtGlsMqocSmdGPk=; b=HzNNGZwSAPwzHGS4IHSW08/IRujhRsEyyfBRmPhI+ECH8sp0x/upnBXgz9HAfw3yb1qceS Zfq84UzxfJ8ppnWj+/GzNQ9Ekm36zR19i6NPDU+Sj5+9F3WGHTr9iYtd8dGTvx//J6A93p rqCAJ0d8tK4H50HHugA/TgOHfaMxEZGCc2uaQRO+CrRZt/EB25c5PJ42yRiUCOWPQa9gE4 h10q3t0229iY935vtog8wlcNX++hDH98eO5/fl3GLyAiSHHyYakeq7kDb9WDQMdDbFsnQV 3RWGwJU1Twe1jFh2A031/xvl5sEyph0IZBOL3QqrtyEq3rZ/lFxfBVy752GfYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298362; a=rsa-sha256; cv=none; b=UiqbGiBKJqf04mvuABNiTgFI/m0c8gjKn4ZJL7Oa1KISTSNjIz4iTTXY6QEFKfJvGEp/K/ O6tUR74M1y7cq71t7v/Y6evJBUVMx8AtJGuOAwVDv40zdWnLUsug3jS2MJQ8Do6KB3EwvV aE3C7gKCJEwjISy3VYiNSecqhRUvdanQEXH8PbqEWAcM1asHsn6xuDAXQWLDw7TgYUws6U SqEHfUjicI9nLiLb/ZVczJgXQrU6gIwrn1HvSbIskD963OZtMjLLTvwRqEIkDLjBnSZHn6 DaO85qEC2epymHP/18uOxriW3REwRHCLV9Vj2XOzk8p3giQ+CuaJ3tLBPNItRQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298362; 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=kLLqox1usmukP3K7oe34aDqPeR0MJtGlsMqocSmdGPk=; b=sgqLDYQSWSiq/4K+swkqCQYb5QMy2DEceupTTnUodPJnHquxx00+Qow2NSVPVHhlbRnUqj W01JRdoJ4a/J+WUT3RHw/DAP6KBjPXpOTBRMh2gUQTZGFFQN5bgndJ85QEAEgbpJocptzc VI5FVj6X2c0QvmrjNFSelOFmcHgcwbnBZUjPaIm6nDMKcboIPpGixG3BpRssfaP3P5Ng+H U1e37CixjraZtLmIqlpA7gqepA0Rq1ptn6p4/F1MUkYLLN/j43AHFONGCC07lGzKmsAzbz 7uw3k50CumoTNThF9hSV3QDQHLPK1VEr/IKGCrFK/hcTI/jtoQ5AkMyzJKAHqw== 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 4VJwFQ1gwgzwhd; Tue, 16 Apr 2024 20:12:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCgRA037644; Tue, 16 Apr 2024 20:12:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCgCT037641; Tue, 16 Apr 2024 20:12:42 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:42 GMT Message-Id: <202404162012.43GKCgCT037641@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: c54653978ebd - stable/14 - loader: Simplify the loader.has_command List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c54653978ebd2ad8f6cea4b8220bb620b1f3db40 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c54653978ebd2ad8f6cea4b8220bb620b1f3db40 commit c54653978ebd2ad8f6cea4b8220bb620b1f3db40 Author: Warner Losh AuthorDate: 2024-02-16 03:52:41 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Simplify the loader.has_command luaL_checkstring already checks for the right number of arguments. There's no need to do that by hand here. Now an exception will be thrown like any other function with the wrong args. Also, push a boolean instead of an int. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43820 (cherry picked from commit 7fc95c31f007ef01c53aa5f9d8802e9579f408ee) --- stand/liblua/lutils.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 8066d3f685f7..182bd699dbc3 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -65,14 +65,15 @@ lua_has_command(lua_State *L) { const char *cmd; - if (lua_gettop(L) != 1) { - lua_pushnil(L); + cmd = luaL_checkstring(L, 1); + if (interp_has_builtin_cmd(cmd)) { + lua_pushboolean(L, 1); return 1; } - cmd = luaL_checkstring(L, 1); - lua_pushinteger(L, interp_has_builtin_cmd(cmd)); - return 1; + lua_pushnil(L); + lua_pushstring(L, "Builtin command not found"); + return 2; } static int From nobody Tue Apr 16 20:12:43 2024 X-Original-To: dev-commits-src-branches@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 4VJwFR3yXvz5H0Mj; Tue, 16 Apr 2024 20:12:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFR34KFz4t4y; Tue, 16 Apr 2024 20:12:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298363; 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=ylcN3lAdnQOEYvcjy7uje6JfK7dEu85dsf3rTDiKf90=; b=A2woEVKmxb6G2KcwGUMY12QHHLtHFeFUt5O/RCrAUCAgS7YVJdf1YApW8Glbe42kAnFUFd kgov37yEVy6JUHE5Y3mYnYeq69aY68RUZCkg5iXe9qgVHSXWyg0OWjCJDWwl2C727ayZpj lq0l5F2yp2FfSoq89boNAOCsDgxLpqJlm6ERZtYxRWwufbP3jxGx139OmyrwT89FBGKdwT vadq6W1k4sJUR7UF5cjpXjUPmLDUo8lhODDxT/yrQ9tKjvXFW9nQhjHq7kvXBcsbGLKRjK /wfPBvJ0iE5qwNOgWQ71OUArz66lTo0zFTZTOwU22gpVjP7mxnZ27b4k1fEV9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298363; a=rsa-sha256; cv=none; b=tfQnKWLARx37fg5h5YXDFG30aUcDRSpbCBgHBh9YdodGZd93DPsKDVCZXN9nn9IAH1XGzF qpQoRW+jiutOpIdGHVxD7RnnZrCT3P91UFLoREcYTECUG6ULeUYOCwrty8+LIGiUQz71Al 0jekUfCXHsDz0PGYTaWOcbrLUZehX+D6M17FvGNjsc6J0fNMbou9b7L+MCEkswD+7nq9Qh Jfo+NZ/ue90iujhqBWSlNqRgP86fdUqh5z1jvcQmqtj3MiOT/IRLyNcLDqaddhBPP2oX1J /s6vmgrXROKOfvPqH4KLMHJljaTaygj41fB8q5fQ6x3LB1ZVcB+5ml+gaTD77A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298363; 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=ylcN3lAdnQOEYvcjy7uje6JfK7dEu85dsf3rTDiKf90=; b=nF3X68qvhzG0PHuevUttSfae2s3AS5ZI7GgUmDwjV3yENpJ1l/v1kfHeYBrsUMr/wgLHDu hC4DgLetNjMr5d3sb0EGZYgeMaFXeSrjxz2JU0r6VZgWjl19volHcbCI8b90gR3113/6cb Cw1dtOPosI7xqBMBtkcg4fo332CDJ8Fg786bHJG7UGXG8kNE/DouEQWQpvWAZrkaJLMETK RXf3T7WKqDrpAUYdFy/Wxxm+wVXM6zbvWOTGHD/58XrGbe/uQUkSLWSqKneep6rPwEhmxm fJVSVdZ4lFMLPjVcrS4FYppuhSEbMZHptjOEQxV9e0cRLE3WKCjqn9l40K1EPg== 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 4VJwFR2gY1zxdd; Tue, 16 Apr 2024 20:12:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKChDw037696; Tue, 16 Apr 2024 20:12:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKChSw037693; Tue, 16 Apr 2024 20:12:43 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:43 GMT Message-Id: <202404162012.43GKChSw037693@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 5bbe8ec08417 - stable/14 - loader: Register the gfx stuff separately. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5bbe8ec08417dbfc0ef7761e28764fe01047311a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5bbe8ec08417dbfc0ef7761e28764fe01047311a commit 5bbe8ec08417dbfc0ef7761e28764fe01047311a Author: Warner Losh AuthorDate: 2024-02-16 03:52:48 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Register the gfx stuff separately. Move registration of the gfx stuff to separate function. However, no change in functionality is intended. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43900 (cherry picked from commit 1dac5a34b64e2573236f38b23f8b1f92bd6a1d7c) --- stand/liblua/lutils.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 182bd699dbc3..0dbd8a6f720b 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -578,6 +578,10 @@ static const struct luaL_Reg loaderlib[] = { REG_SIMPLE(setenv), REG_SIMPLE(time), REG_SIMPLE(unsetenv), + { NULL, NULL }, +}; + +static const struct luaL_Reg gfxlib[] = { REG_SIMPLE(fb_bezier), REG_SIMPLE(fb_drawrect), REG_SIMPLE(fb_line), @@ -627,10 +631,17 @@ lua_add_features(lua_State *L) lua_setfield(L, -2, "features"); } +static void +luaopen_gfx(lua_State *L) +{ + luaL_newlib(L, gfxlib); +} + int luaopen_loader(lua_State *L) { luaL_newlib(L, loaderlib); + luaopen_gfx(L); /* Add loader.machine and loader.machine_arch properties */ lua_pushstring(L, MACHINE); lua_setfield(L, -2, "machine"); From nobody Tue Apr 16 20:12:44 2024 X-Original-To: dev-commits-src-branches@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 4VJwFS5PJZz5H0VS; Tue, 16 Apr 2024 20:12: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFS3gJMz4t33; Tue, 16 Apr 2024 20:12:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298364; 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=3IMe7bs29vb8MAbfQvCD8PATejo5ccwZmeWusAEsDjA=; b=uwMWnmDnJP8K3JaeUZgAfdjz6TSnoeV6AwxbQI8DZz1tFIfBs5CtJ/Vdrfa+1KN7ZKtrOg zX+U37k9GqMiJ0JvY5XMtzK2ERglVvq77NxbJIb1Ueo9sN+MNpmrErGQtxMM4KgaiOiHDC IAzp3gpZllqbDdWwwlt99YU0sbfQRXmiO4R1XJtS0vIU0RcIau6Jk55v2gVrYFsarq+XHo 6n8DRvv4XCUk7ajKgBFQicn94nE9sf6zyEaXM74p9q98zNvaUkegDY5Wp2rPqNPPTxyEZj S4Zf4VHzriPKuQu0RyZM32NE4zpghD+mhOKoTqZClTX4qJTehVgslP7LSsIxDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298364; a=rsa-sha256; cv=none; b=U4VC5W1SKlvmVpeo8voAlilp24pEtc7pJvnULN2bKbRIB8YC2yyevvwOMzKk0I01WmqojA FRiijpIIHSV7DWiRsnVXHbMWtZnxhLnI+rWQJm+jRxFJS5Rni0zQic2McCdm51gJi7pNy6 KDgRV6oxRftKFKQFcBOMDahGjmxxXbWL4UM+0vrtVaIarVrqhJblNUbha9jD9GnO1oeiTY ierr3YcB9SKvE8kN0+8MjhQx/LbsDxsb02+TPkUehaUNwExO4ExrtogPEZvcQFH5tuoW4Q pqPumFfghD2+/OoOtb2+zZukm/1nNGm/ee7vnKgz5k1mmf64NiYPaMV25go3KA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298364; 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=3IMe7bs29vb8MAbfQvCD8PATejo5ccwZmeWusAEsDjA=; b=iKKtsQg/vMZ8ZssU03xOZeUlbd+CXm/kqVd1cVd6OIbAR+K1ZdzTtWo2da//uPzVcEA3GX C/mc9gmQXLcVH/R0WOV90W8WWQdT+VicjThA+AUPUTUIjzxIBsp9zDOIuQ4j+nUKQwElBr Jd0Nw5AwkA//utxmS1eOt8GqHMFdhIXj7zz1A6a3gHgkFRsilAhZF9h8TF2aTkF9NkaEC6 UB1nqTSStLRQ2jlIGJhyaWEorM1/Lt34FREiV0HZ/0RxUPWCE3IIQmnSuFf+82DEC/rGpZ GmnUaOx2MFI2lbeZfV6vfcGHqat6R/RMnGCr5UQTL6JKx828bnvxw3ijW84oaA== 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 4VJwFS3Fn7zxWP; Tue, 16 Apr 2024 20:12:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCi7c037744; Tue, 16 Apr 2024 20:12:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCiI9037741; Tue, 16 Apr 2024 20:12:44 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:44 GMT Message-Id: <202404162012.43GKCiI9037741@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 8929f8454fff - stable/14 - loader: Separate gfx to a new file. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8929f8454fffcae33e65689b806e236c16c6761b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=8929f8454fffcae33e65689b806e236c16c6761b commit 8929f8454fffcae33e65689b806e236c16c6761b Author: Warner Losh AuthorDate: 2024-02-16 03:52:59 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Separate gfx to a new file. Move gfx lua hook registration to a new file. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43901 (cherry picked from commit 061b68a76030f4147f5a30e60ab5f4296c1376b7) --- stand/liblua/Makefile | 3 +- stand/liblua/gfx_utils.c | 242 +++++++++++++++++++++++++++++++++++++++++++++++ stand/liblua/lutils.c | 202 --------------------------------------- stand/liblua/lutils.h | 1 + 4 files changed, 245 insertions(+), 203 deletions(-) diff --git a/stand/liblua/Makefile b/stand/liblua/Makefile index b2f17811ff84..bbfa21e07f53 100644 --- a/stand/liblua/Makefile +++ b/stand/liblua/Makefile @@ -23,6 +23,7 @@ SRCS+= lauxlib.c lbaselib.c lstrlib.c loadlib.c # Our utilities. SRCS+= lerrno.c lpager.c lstd.c lutils.c +SRCS+= gfx_utils.c .PATH: ${FLUASRC}/modules SRCS+= lfs.c @@ -34,7 +35,7 @@ CFLAGS+= -ffreestanding -nostdlib -DLUA_USE_POSIX CFLAGS+= -fno-stack-protector -D__BSD_VISIBLE CFLAGS+= -I${BOOTSRC}/include -I${LIBLUASRC} -I${LUASRC} -I${LDRSRC} -CFLAGS.lutils.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite +CFLAGS.gfx_utils.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite .if ${MACHINE_CPUARCH} == "amd64" && ${DO32:U0} == 0 CFLAGS+= -fPIC diff --git a/stand/liblua/gfx_utils.c b/stand/liblua/gfx_utils.c new file mode 100644 index 000000000000..fe208dc990d8 --- /dev/null +++ b/stand/liblua/gfx_utils.c @@ -0,0 +1,242 @@ +/*- + * Copyright (c) 2024 Netflix, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +/* Copied from a file that likely shoulve have had this at the top */ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright 2020 Toomas Soome + * Copyright 2020 RackTop Systems, Inc. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include "lua.h" +#include "lauxlib.h" +#include "lutils.h" +#include +#include + +/* + * put image using terminal coordinates. + */ +static int +lua_term_putimage(lua_State *L) +{ + const char *name; + png_t png; + uint32_t x1, y1, x2, y2, f; + int nargs, ret = 0, error; + + nargs = lua_gettop(L); + if (nargs != 6) { + lua_pushboolean(L, 0); + return 1; + } + + name = luaL_checkstring(L, 1); + x1 = luaL_checknumber(L, 2); + y1 = luaL_checknumber(L, 3); + x2 = luaL_checknumber(L, 4); + y2 = luaL_checknumber(L, 5); + f = luaL_checknumber(L, 6); + + x1 = gfx_state.tg_origin.tp_col + x1 * gfx_state.tg_font.vf_width; + y1 = gfx_state.tg_origin.tp_row + y1 * gfx_state.tg_font.vf_height; + if (x2 != 0) { + x2 = gfx_state.tg_origin.tp_col + + x2 * gfx_state.tg_font.vf_width; + } + if (y2 != 0) { + y2 = gfx_state.tg_origin.tp_row + + y2 * gfx_state.tg_font.vf_height; + } + + if ((error = png_open(&png, name)) != PNG_NO_ERROR) { + if (f & FL_PUTIMAGE_DEBUG) + printf("%s\n", png_error_string(error)); + } else { + if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) + ret = 1; + (void) png_close(&png); + } + lua_pushboolean(L, ret); + return 1; +} + +static int +lua_fb_putimage(lua_State *L) +{ + const char *name; + png_t png; + uint32_t x1, y1, x2, y2, f; + int nargs, ret = 0, error; + + nargs = lua_gettop(L); + if (nargs != 6) { + lua_pushboolean(L, 0); + return 1; + } + + name = luaL_checkstring(L, 1); + x1 = luaL_checknumber(L, 2); + y1 = luaL_checknumber(L, 3); + x2 = luaL_checknumber(L, 4); + y2 = luaL_checknumber(L, 5); + f = luaL_checknumber(L, 6); + + if ((error = png_open(&png, name)) != PNG_NO_ERROR) { + if (f & FL_PUTIMAGE_DEBUG) + printf("%s\n", png_error_string(error)); + } else { + if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) + ret = 1; + (void) png_close(&png); + } + lua_pushboolean(L, ret); + return 1; +} + +static int +lua_fb_setpixel(lua_State *L) +{ + uint32_t x, y; + int nargs; + + nargs = lua_gettop(L); + if (nargs != 2) { + lua_pushnil(L); + return 1; + } + + x = luaL_checknumber(L, 1); + y = luaL_checknumber(L, 2); + gfx_fb_setpixel(x, y); + return 0; +} + +static int +lua_fb_line(lua_State *L) +{ + uint32_t x0, y0, x1, y1, wd; + int nargs; + + nargs = lua_gettop(L); + if (nargs != 5) { + lua_pushnil(L); + return 1; + } + + x0 = luaL_checknumber(L, 1); + y0 = luaL_checknumber(L, 2); + x1 = luaL_checknumber(L, 3); + y1 = luaL_checknumber(L, 4); + wd = luaL_checknumber(L, 5); + gfx_fb_line(x0, y0, x1, y1, wd); + return 0; +} + +static int +lua_fb_bezier(lua_State *L) +{ + uint32_t x0, y0, x1, y1, x2, y2, width; + int nargs; + + nargs = lua_gettop(L); + if (nargs != 7) { + lua_pushnil(L); + return 1; + } + + x0 = luaL_checknumber(L, 1); + y0 = luaL_checknumber(L, 2); + x1 = luaL_checknumber(L, 3); + y1 = luaL_checknumber(L, 4); + x2 = luaL_checknumber(L, 5); + y2 = luaL_checknumber(L, 6); + width = luaL_checknumber(L, 7); + gfx_fb_bezier(x0, y0, x1, y1, x2, y2, width); + return 0; +} + +static int +lua_fb_drawrect(lua_State *L) +{ + uint32_t x0, y0, x1, y1, fill; + int nargs; + + nargs = lua_gettop(L); + if (nargs != 5) { + lua_pushnil(L); + return 1; + } + + x0 = luaL_checknumber(L, 1); + y0 = luaL_checknumber(L, 2); + x1 = luaL_checknumber(L, 3); + y1 = luaL_checknumber(L, 4); + fill = luaL_checknumber(L, 5); + gfx_fb_drawrect(x0, y0, x1, y1, fill); + return 0; +} + +static int +lua_term_drawrect(lua_State *L) +{ + uint32_t x0, y0, x1, y1; + int nargs; + + nargs = lua_gettop(L); + if (nargs != 4) { + lua_pushnil(L); + return 1; + } + + x0 = luaL_checknumber(L, 1); + y0 = luaL_checknumber(L, 2); + x1 = luaL_checknumber(L, 3); + y1 = luaL_checknumber(L, 4); + gfx_term_drawrect(x0, y0, x1, y1); + return 0; +} + +#define REG_SIMPLE(n) { #n, lua_ ## n } +static const struct luaL_Reg gfxlib[] = { + REG_SIMPLE(fb_bezier), + REG_SIMPLE(fb_drawrect), + REG_SIMPLE(fb_line), + REG_SIMPLE(fb_putimage), + REG_SIMPLE(fb_setpixel), + REG_SIMPLE(term_drawrect), + REG_SIMPLE(term_putimage), + { NULL, NULL }, +}; + +int +luaopen_gfx(lua_State *L) +{ + luaL_newlib(L, gfxlib); + return 1; +} diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 0dbd8a6f720b..20876f965f0c 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -32,8 +32,6 @@ #include "lstd.h" #include "lutils.h" #include "bootstrap.h" -#include -#include /* * Like loader.perform, except args are passed already parsed @@ -380,189 +378,6 @@ lua_writefile(lua_State *L) return 1; } -/* - * put image using terminal coordinates. - */ -static int -lua_term_putimage(lua_State *L) -{ - const char *name; - png_t png; - uint32_t x1, y1, x2, y2, f; - int nargs, ret = 0, error; - - nargs = lua_gettop(L); - if (nargs != 6) { - lua_pushboolean(L, 0); - return 1; - } - - name = luaL_checkstring(L, 1); - x1 = luaL_checknumber(L, 2); - y1 = luaL_checknumber(L, 3); - x2 = luaL_checknumber(L, 4); - y2 = luaL_checknumber(L, 5); - f = luaL_checknumber(L, 6); - - x1 = gfx_state.tg_origin.tp_col + x1 * gfx_state.tg_font.vf_width; - y1 = gfx_state.tg_origin.tp_row + y1 * gfx_state.tg_font.vf_height; - if (x2 != 0) { - x2 = gfx_state.tg_origin.tp_col + - x2 * gfx_state.tg_font.vf_width; - } - if (y2 != 0) { - y2 = gfx_state.tg_origin.tp_row + - y2 * gfx_state.tg_font.vf_height; - } - - if ((error = png_open(&png, name)) != PNG_NO_ERROR) { - if (f & FL_PUTIMAGE_DEBUG) - printf("%s\n", png_error_string(error)); - } else { - if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) - ret = 1; - (void) png_close(&png); - } - lua_pushboolean(L, ret); - return 1; -} - -static int -lua_fb_putimage(lua_State *L) -{ - const char *name; - png_t png; - uint32_t x1, y1, x2, y2, f; - int nargs, ret = 0, error; - - nargs = lua_gettop(L); - if (nargs != 6) { - lua_pushboolean(L, 0); - return 1; - } - - name = luaL_checkstring(L, 1); - x1 = luaL_checknumber(L, 2); - y1 = luaL_checknumber(L, 3); - x2 = luaL_checknumber(L, 4); - y2 = luaL_checknumber(L, 5); - f = luaL_checknumber(L, 6); - - if ((error = png_open(&png, name)) != PNG_NO_ERROR) { - if (f & FL_PUTIMAGE_DEBUG) - printf("%s\n", png_error_string(error)); - } else { - if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) - ret = 1; - (void) png_close(&png); - } - lua_pushboolean(L, ret); - return 1; -} - -static int -lua_fb_setpixel(lua_State *L) -{ - uint32_t x, y; - int nargs; - - nargs = lua_gettop(L); - if (nargs != 2) { - lua_pushnil(L); - return 1; - } - - x = luaL_checknumber(L, 1); - y = luaL_checknumber(L, 2); - gfx_fb_setpixel(x, y); - return 0; -} - -static int -lua_fb_line(lua_State *L) -{ - uint32_t x0, y0, x1, y1, wd; - int nargs; - - nargs = lua_gettop(L); - if (nargs != 5) { - lua_pushnil(L); - return 1; - } - - x0 = luaL_checknumber(L, 1); - y0 = luaL_checknumber(L, 2); - x1 = luaL_checknumber(L, 3); - y1 = luaL_checknumber(L, 4); - wd = luaL_checknumber(L, 5); - gfx_fb_line(x0, y0, x1, y1, wd); - return 0; -} - -static int -lua_fb_bezier(lua_State *L) -{ - uint32_t x0, y0, x1, y1, x2, y2, width; - int nargs; - - nargs = lua_gettop(L); - if (nargs != 7) { - lua_pushnil(L); - return 1; - } - - x0 = luaL_checknumber(L, 1); - y0 = luaL_checknumber(L, 2); - x1 = luaL_checknumber(L, 3); - y1 = luaL_checknumber(L, 4); - x2 = luaL_checknumber(L, 5); - y2 = luaL_checknumber(L, 6); - width = luaL_checknumber(L, 7); - gfx_fb_bezier(x0, y0, x1, y1, x2, y2, width); - return 0; -} - -static int -lua_fb_drawrect(lua_State *L) -{ - uint32_t x0, y0, x1, y1, fill; - int nargs; - - nargs = lua_gettop(L); - if (nargs != 5) { - lua_pushnil(L); - return 1; - } - - x0 = luaL_checknumber(L, 1); - y0 = luaL_checknumber(L, 2); - x1 = luaL_checknumber(L, 3); - y1 = luaL_checknumber(L, 4); - fill = luaL_checknumber(L, 5); - gfx_fb_drawrect(x0, y0, x1, y1, fill); - return 0; -} - -static int -lua_term_drawrect(lua_State *L) -{ - uint32_t x0, y0, x1, y1; - int nargs; - - nargs = lua_gettop(L); - if (nargs != 4) { - lua_pushnil(L); - return 1; - } - - x0 = luaL_checknumber(L, 1); - y0 = luaL_checknumber(L, 2); - x1 = luaL_checknumber(L, 3); - y1 = luaL_checknumber(L, 4); - gfx_term_drawrect(x0, y0, x1, y1); - return 0; -} - #define REG_SIMPLE(n) { #n, lua_ ## n } static const struct luaL_Reg loaderlib[] = { REG_SIMPLE(delay), @@ -581,17 +396,6 @@ static const struct luaL_Reg loaderlib[] = { { NULL, NULL }, }; -static const struct luaL_Reg gfxlib[] = { - REG_SIMPLE(fb_bezier), - REG_SIMPLE(fb_drawrect), - REG_SIMPLE(fb_line), - REG_SIMPLE(fb_putimage), - REG_SIMPLE(fb_setpixel), - REG_SIMPLE(term_drawrect), - REG_SIMPLE(term_putimage), - { NULL, NULL }, -}; - static const struct luaL_Reg iolib[] = { { "close", lua_closefile }, REG_SIMPLE(getchar), @@ -631,12 +435,6 @@ lua_add_features(lua_State *L) lua_setfield(L, -2, "features"); } -static void -luaopen_gfx(lua_State *L) -{ - luaL_newlib(L, gfxlib); -} - int luaopen_loader(lua_State *L) { diff --git a/stand/liblua/lutils.h b/stand/liblua/lutils.h index 280fb77aa665..c1fd6af496e5 100644 --- a/stand/liblua/lutils.h +++ b/stand/liblua/lutils.h @@ -26,6 +26,7 @@ #include +int luaopen_gfx(lua_State *); int luaopen_loader(lua_State *); int luaopen_io(lua_State *); int luaopen_pager(lua_State *); From nobody Tue Apr 16 20:12:45 2024 X-Original-To: dev-commits-src-branches@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 4VJwFT6m4Mz5H0KK; Tue, 16 Apr 2024 20:12:45 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFT4hHTz4t7s; Tue, 16 Apr 2024 20:12:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298365; 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=pJmVI7U5mD2R2IyYYl+4Tyw2Xyw8VqR7jMgn+OjSFGM=; b=hxf15gR9TZsQXheTyJU3XbqKK/LT74ufYZ0LaYu3Ay+R7A+4qrbjOVblb8/jHUkVlccsFS mXZj8d4YaTjXG7OXdm1F2fJ5/mcehRhUEYUIv0uVifYGSXw0zDy7/suX868hgo/d8kkJDx 1CCcDGCsf5XwMn2hv6L8RZZSpzi+lVJVseitctD4nkj8o+2weqMCtWPLSfTveLJhGyEwgr QYydlkh9sqPNOI/7V2UBizYAZxGemjdQCC6+V/0jMG3ziQnV+EJncVEnctMYNpjTy6aYm5 qxWS3ZIzZ4+c0OO3F8nQymPQqE2CoKChex4bkNHEeevMV8HoqPA1rJrUT2O02g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298365; a=rsa-sha256; cv=none; b=tEzhQN5iuI5AQ52f8zB4GyOy1SKj3NfYnO8aKKIr4W6mSYSIjg95Fi2I1McalYP9w53sO+ l1jDmAftbHjM8e4Tz983b7PALJn0h4He3aSyWoreefsgiEHCSHyg6E4ueCZeSmvZ0F8TRV KlnVikntuhBlHTf3ueqOWcwG8BjiV0Sequ8100NwSqDM2Z2gt1PwUpNoTaHud2Hcg6lqkU cbyodYcwBBPN6nFKBpdyDd45RuxKCpnyQ2QMFfQrjn7bHbxnEpg9zbhmxgLspLT/n1R69o UxxXdP7XmndJmtwWeEezWz/YHaNeReWohEdfqh9uKYfBobOgIN7fvMiLNDJasw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298365; 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=pJmVI7U5mD2R2IyYYl+4Tyw2Xyw8VqR7jMgn+OjSFGM=; b=Mb9471mygCKK5vfFozedtpI+SH2q7JTcD7DlSsU54VkPvhNi92XJexExUfk4Wta4/uNHaB gy7wi2+MAYMIzm+B1hClo0n9Ng9r+MTfrS9/CNfceEs63OBY0NPaJj3han5l9CfEeJXLqD ENK/yNYqRAvyG9eRwmGG5bGWeYbQYiq6iFrE8d5KZz9yb7SLKb/sIOCrwNkFSXz1P46TU8 qJv4Lgv3/kzYjttwCht5KfWxLL2KzYzk5kR5LZxqwlWKZAPwKzpEGl21z2DndoILP3D3TP cWEibdyuZ2XhdiYpIePneKqsh0pPcB7i4roE9+dQSYfKK+4psUmJ3m5ZRcWdCQ== 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 4VJwFT4GbDzxY0; Tue, 16 Apr 2024 20:12:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCjfH037792; Tue, 16 Apr 2024 20:12:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCjb3037789; Tue, 16 Apr 2024 20:12:45 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:45 GMT Message-Id: <202404162012.43GKCjb3037789@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 73fac51c5726 - stable/14 - loader: Create new gfx table List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 73fac51c572655a3d0e55af410f42dc15713ef31 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=73fac51c572655a3d0e55af410f42dc15713ef31 commit 73fac51c572655a3d0e55af410f42dc15713ef31 Author: Warner Losh AuthorDate: 2024-02-16 03:53:07 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Create new gfx table Create a new gfx global table. Put into it all the graphics bindings that we have in loader today. For now, have compatability binding for loader. Remove them from loader. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43902 (cherry picked from commit 9b16231032ddb40be282d76ec0d82b3a0ec96d60) --- stand/common/interp_lua.c | 27 +++++++++++++++++++++++++++ stand/liblua/lutils.c | 1 - 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/stand/common/interp_lua.c b/stand/common/interp_lua.c index 3f758baebc2d..a347526b67c9 100644 --- a/stand/common/interp_lua.c +++ b/stand/common/interp_lua.c @@ -97,6 +97,31 @@ static const luaL_Reg loadedlibs[] = { {NULL, NULL} }; +static void +interp_init_md(lua_State *L) +{ + luaL_requiref(L, "gfx", luaopen_gfx, 1); + lua_pop(L, 1); /* Remove lib */ + + /* + * Add in the comparability references in the loader table. Doing it with + * a pseudo-embedded script is easier than the raw calls. + */ + if (luaL_dostring(L, + "loader.fb_bezier = gfx.fb_bezier\n" + "loader.fb_drawrect = gfx.fb_drawrect\n" + "loader.fb_line = gfx.fb_line\n" + "loader.fb_putimage = gfx.fb_putimage\n" + "loader.fb_setpixel = gfx.fb_setpixel\n" + "loader.term_drawrect = gfx.term_drawrect\n" + "loader.term_putimage = gfx.term_putimage") != 0) { + lua_pop(L, 1); + const char *errstr = lua_tostring(L, -1); + errstr = errstr == NULL ? "unknown" : errstr; + printf("Error adding compat loader bindings: %s.\n", errstr); + } +} + void interp_init(void) { @@ -123,6 +148,8 @@ interp_init(void) lua_pop(luap, 1); /* remove lib */ } + interp_init_md(luap); + filename = getenv("loader_lua"); if (filename == NULL) filename = LOADER_LUA; diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 20876f965f0c..0be9f5f28ac3 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -439,7 +439,6 @@ int luaopen_loader(lua_State *L) { luaL_newlib(L, loaderlib); - luaopen_gfx(L); /* Add loader.machine and loader.machine_arch properties */ lua_pushstring(L, MACHINE); lua_setfield(L, -2, "machine"); From nobody Tue Apr 16 20:12:46 2024 X-Original-To: dev-commits-src-branches@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 4VJwFV60Jgz5H0QK; Tue, 16 Apr 2024 20:12:46 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFV5MwHz4t82; Tue, 16 Apr 2024 20:12:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298366; 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=t/B7HkwJkRJwyDE7uvnqJVf3N5FmAK5osCGJv4HewJI=; b=WD8BTgmNIixjOI1RT+Rkesh6MlCmDMydwqcQcCak0oveA/aQ7mwm5Hf9qhMPKuv9PR5SGO 2d/Jipj0y9uFgqB5FFsxWQ74PNoncKCPF/LpvTnS9TrkZWNzYnj27p6EsRQ1XyvJNtFeTe uOxHx4GVgbBqsjUTwh+0mCwzTCMlSsQlS2Toga/bQUfAvKSovDA3KBsC+kAQHzBpDnFJ+I vR+xPm0o7yuFk9miCsWqoEZCmZziGujNeY23/QUTtxSnLMbLX3F2xy+ImxFi8qHJWi/aIy /CrHxddnSNuEBXaFYUSGCeq01x70Z3jVV0abnipc2hEXt1b/NjgonG6mzMYFbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298366; a=rsa-sha256; cv=none; b=aTNmXCGvmyCbH1JD9qKNrwAymJ0itRyNLRFQYHbuetRekqpMqP+Mzum86RBiXTTgabp6Qr qCK5AVox0Tdpu20nbhsqHI9M7M1/TViNas2BfMw7Vy3f0jqhyIixM6Q4NCWWk0gra49pss +OZQUN47UltaFVxL1Gf7YtYn9ZAvOdxSaak55nXEIb629fJrki/wjfssHmTSR0zeNWIIMS nbVUpuNSpP5LE1ngkCnhPZaV7C533mAhjjiRDYZ9s1ZSol+JcvBJpX86w4o5sVqQu1TdoV fP/hgkbxch4zmWTZHaOsTIl50qwky7L362IdrEiUJpIKKqGLmwQaXe2qeZV/Ug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298366; 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=t/B7HkwJkRJwyDE7uvnqJVf3N5FmAK5osCGJv4HewJI=; b=UYwUmwwLJys1FsauzLxLB6XQfNWKoHJGqnvFc3fMe8J0VSH6DUAXOtjX23jB/lBwTMfSEX mcwZrJHXE/aJWKNs4IdIUqXD6qo/AhSaZcFDWzol2mVonYJIXxKYWTAU4CpZWTB7M4pxDP Qd2hCAgC7880P8Caro3l1qo3gptGliIwwpTegI6pG6QmHyZ8njlNQOJFWRmdWipFcKsXRG EK0rnzkmoOKjS7oGIaAGKsk/PjhUwlR/ZvZO61DsG+BYBb367jzx6SsnBC8b70FsjBAaw8 nJTeuaDYjU4983kKEpuwF0PdV2pKke/XELOAthhpEdJSuRdX8CDU+niiF9gU4w== 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 4VJwFV4y29zxdf; Tue, 16 Apr 2024 20:12:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCkpu037834; Tue, 16 Apr 2024 20:12:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCk3e037831; Tue, 16 Apr 2024 20:12:46 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:46 GMT Message-Id: <202404162012.43GKCk3e037831@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: ab3aa90b70db - stable/14 - loader: Add prototype for gfx_interp_md List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ab3aa90b70db580adbc73ac62ca2c3ea4ff5c596 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ab3aa90b70db580adbc73ac62ca2c3ea4ff5c596 commit ab3aa90b70db580adbc73ac62ca2c3ea4ff5c596 Author: Warner Losh AuthorDate: 2024-02-16 03:53:19 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Add prototype for gfx_interp_md This function will be used to draw in the graphics bindings when the loader is compiled with graphics (gfx) support. Provide definitions for lua and the simple interpreter. 4th support is forthcoming. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43903 (cherry picked from commit 60e199d9fde1c3c60a96b969bf6982278cbc1e88) --- stand/common/gfx_fb.h | 2 ++ stand/common/interp_simple.c | 8 ++++++++ stand/liblua/gfx_utils.c | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/stand/common/gfx_fb.h b/stand/common/gfx_fb.h index adb60c673ea9..84062864c57f 100644 --- a/stand/common/gfx_fb.h +++ b/stand/common/gfx_fb.h @@ -281,6 +281,8 @@ void term_image_display(teken_gfx_t *, const teken_rect_t *); void reset_font_flags(void); +void gfx_interp_md(void); + #ifdef __cplusplus } #endif diff --git a/stand/common/interp_simple.c b/stand/common/interp_simple.c index fa021c796308..61ed724af9d0 100644 --- a/stand/common/interp_simple.c +++ b/stand/common/interp_simple.c @@ -198,3 +198,11 @@ interp_include(const char *filename) } return(res); } + +/* + * There's no graphics commands for the simple interpreter. + */ +void +gfx_interp_md(void) +{ +} diff --git a/stand/liblua/gfx_utils.c b/stand/liblua/gfx_utils.c index fe208dc990d8..d2d22738c929 100644 --- a/stand/liblua/gfx_utils.c +++ b/stand/liblua/gfx_utils.c @@ -240,3 +240,8 @@ luaopen_gfx(lua_State *L) luaL_newlib(L, gfxlib); return 1; } + +void +gfx_interp_md(void) +{ +} From nobody Tue Apr 16 20:12:47 2024 X-Original-To: dev-commits-src-branches@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 4VJwFX0SKZz5H0Mr; Tue, 16 Apr 2024 20:12:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFW6Brtz4sy8; Tue, 16 Apr 2024 20:12:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298367; 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=8sRfxmprsbEksUuXjrYHoqYni9qI1Q5YCTiEUNKT3DA=; b=lJ+nUJh1klYBBQSZ8yZfy7v1OJ5GnwKiuYqO3rcaQCCD7KU22N+4UeqgESKhS7VQ7poKPH zLl901J7oYI9mkcnvZjz36JirT7F2aVUCne7kTQr9JbJDPO71y2xlPVUwSiyhZxzz2duwb RWYhq0HHJ4dBSGakLtZT0w8MKOBSObqOzZeyDq2CWqnTzSaJ77y7eOYZZRjE+DRnGQUTP/ U4r14izEpjfOQeFbqiyz+ydpY4uBF/+4Sfanmqskxy3HxDLmAVi6dh6+ed8z7QSq068ine pmsLG8JnwU4Jz9zIMZrGkWs8qgI9R2NC6C0bjk8u1CRnIRB4lZG/5GVdRyGq4w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298367; a=rsa-sha256; cv=none; b=j7cXtpEzUs1z1Ud51EKQkvrMmbE9FH8MS56/3EUet6cc4HzReuOGeFwFRMo+dEuTI2H5jY f0uNlN4mPKey1KXkX2sJCN8vIU7v2gimU+XJdltXMv0t4Q9ABrSUq7ubmMcW2Rpd4kSbok 0tllhoDHe+ir9DLJ8mGWEi30Qh6hLeuCEXgxzjMDKd7OYrfQemGh6drL2QX/29tN/JN2T5 yWoA4/6WXQjF3pATW1R3oSb2ADzovkASW47TLy41yBLrIBXkxUc6RkjW44RicdJFIpT3ky GjXrsu6+lUEwbupIX95bsbLX5B1Ktcy425TEiZk/ouCYPjykl/+1OfuFOVDi/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298367; 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=8sRfxmprsbEksUuXjrYHoqYni9qI1Q5YCTiEUNKT3DA=; b=mT2gXuQ2jUKTg47PKzpGoZomxzl7e6qLuRAHGS9BcYU1VS83DYW/ymnDDHAHIB4WdztY8c XuiiD+VMrsoRDsqnds9G0/fd8QCklr2+14U79tsDS+DK3laOUemUPmFUJATj87P2UxAO3U ddHBwq/GYR9qJ0lG/NFrZcbeE350C7hRW0RBHHtnxeh1YMHxmKpwSCp7QMUtNkBeskisE5 zqfXvntl+eB40Do6JsmhdZmEIJQQaqRuBPVEZ7rWpdxDWOCJptnoTLOmoLw1O+4s7M5G0n csWoFMy9JTicuTFnqDWqTEY9MCcuBS30Be2CEFJcn+5ziwm1JDVoj8xpIvs7cg== 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 4VJwFW5jsmzxJT; Tue, 16 Apr 2024 20:12:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCldR037895; Tue, 16 Apr 2024 20:12:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCla9037892; Tue, 16 Apr 2024 20:12:47 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:47 GMT Message-Id: <202404162012.43GKCla9037892@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 254adb825999 - stable/14 - loader: Only create gfx 4th bindings when gfx is available List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 254adb82599945e635252c17cf522da540c23aac Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=254adb82599945e635252c17cf522da540c23aac commit 254adb82599945e635252c17cf522da540c23aac Author: Warner Losh AuthorDate: 2024-02-16 03:53:28 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:23 +0000 loader: Only create gfx 4th bindings when gfx is available Only create the gfx bindings for 4th when it's compiled into the loader. We do this with a linker set that only gets brought in to those loaders that call gfx_framework_init. This calls gfx_interp_md() will will drag in gfx_loader.c which will add to the linker set that registers these bindings. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43904 (cherry picked from commit 9c8bf69a53f628b62fb196182ea55fb34c1c19e1) --- stand/common/gfx_fb.c | 1 + stand/ficl/Makefile | 5 +- stand/ficl/gfx_loader.c | 259 ++++++++++++++++++++++++++++++++++++++++++++++++ stand/ficl/loader.c | 188 ----------------------------------- 4 files changed, 263 insertions(+), 190 deletions(-) diff --git a/stand/common/gfx_fb.c b/stand/common/gfx_fb.c index b61591bf3d45..3a5b851915e0 100644 --- a/stand/common/gfx_fb.c +++ b/stand/common/gfx_fb.c @@ -181,6 +181,7 @@ gfx_framework_init(void) * Setup font list to have builtin font. */ (void) insert_font(NULL, FONT_BUILTIN); + gfx_interp_md(); /* Draw in the gfx interpreter for this thing */ } static uint8_t * diff --git a/stand/ficl/Makefile b/stand/ficl/Makefile index a9b384024667..fe4ee03974b1 100644 --- a/stand/ficl/Makefile +++ b/stand/ficl/Makefile @@ -11,8 +11,8 @@ BASE_SRCS= dict.c ficl.c fileaccess.c float.c loader.c math64.c \ SRCS= ${BASE_SRCS} sysdep.c softcore.c CLEANFILES+= softcore.c testmain testmain.o -CFLAGS.loader.c += -I${SRCTOP}/sys/teken -CFLAGS.loader.c += -I${SRCTOP}/contrib/pnglite +CFLAGS.gfx_loader.c += -I${SRCTOP}/sys/teken +CFLAGS.gfx_loader.c += -I${SRCTOP}/contrib/pnglite .ifmake testmain CFLAGS= -DTESTMAIN -D_TESTMAIN CFLAGS+= -I${FICLSRC} -I${FICLSRC}/${FICL_CPUARCH} -I${LDRSRC} @@ -21,6 +21,7 @@ PROG= testmain .include .else LIB= ficl +BASE_SRCS+= gfx_loader.c # Not TESTMAINable .include .endif diff --git a/stand/ficl/gfx_loader.c b/stand/ficl/gfx_loader.c new file mode 100644 index 000000000000..a4501a7d3c39 --- /dev/null +++ b/stand/ficl/gfx_loader.c @@ -0,0 +1,259 @@ +/*- + * Copyright (c) 2024 Netflix, Inc + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +/* Copied from a file that likely shoulve have had this at the top */ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright 2020 Toomas Soome + * Copyright 2020 RackTop Systems, Inc. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/******************************************************************* +** g f x _ l o a d e r . c +** Additional FICL words designed for FreeBSD's loader +** for graphics +*******************************************************************/ + +#include +#include "bootstrap.h" +#include +#include +#include "ficl.h" + +/* FreeBSD's loader interaction words and extras + * for graphics + * fb-bezier ( x0 y0 x1 y1 x2 y2 wd -- ) + * fb-drawrect ( x1 y1 x2 y2 fill -- ) + * fb-line ( x0 y0 x1 y1 wd -- ) + * fb-putimage ( flags x1 y1 x2 y2 -- flag ) + * fb-setpixel ( x y -- ) + * term-drawrect ( x1 y1 x2 y2 fill -- ) + * term-putimage ( flags x1 y1 x2 y2 -- flag ) + */ + +/* ( flags x1 y1 x2 y2 -- flag ) */ +void +ficl_term_putimage(FICL_VM *pVM) +{ + char *namep, *name; + int names; + unsigned long ret = FICL_FALSE; + uint32_t x1, y1, x2, y2, f; + png_t png; + int error; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 7, 1); +#endif + names = stackPopINT(pVM->pStack); + namep = (char *) stackPopPtr(pVM->pStack); + y2 = stackPopINT(pVM->pStack); + x2 = stackPopINT(pVM->pStack); + y1 = stackPopINT(pVM->pStack); + x1 = stackPopINT(pVM->pStack); + f = stackPopINT(pVM->pStack); + + x1 = gfx_state.tg_origin.tp_col + x1 * gfx_state.tg_font.vf_width; + y1 = gfx_state.tg_origin.tp_row + y1 * gfx_state.tg_font.vf_height; + if (x2 != 0) { + x2 = gfx_state.tg_origin.tp_col + + x2 * gfx_state.tg_font.vf_width; + } + if (y2 != 0) { + y2 = gfx_state.tg_origin.tp_row + + y2 * gfx_state.tg_font.vf_height; + } + + name = ficlMalloc(names + 1); + if (!name) + vmThrowErr(pVM, "Error: out of memory"); + (void) strncpy(name, namep, names); + name[names] = '\0'; + + if ((error = png_open(&png, name)) != PNG_NO_ERROR) { + if (f & FL_PUTIMAGE_DEBUG) + printf("%s\n", png_error_string(error)); + } else { + if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) + ret = FICL_TRUE; /* success */ + (void) png_close(&png); + } + ficlFree(name); + stackPushUNS(pVM->pStack, ret); +} + +/* ( flags x1 y1 x2 y2 -- flag ) */ +void +ficl_fb_putimage(FICL_VM *pVM) +{ + char *namep, *name; + int names; + unsigned long ret = FICL_FALSE; + uint32_t x1, y1, x2, y2, f; + png_t png; + int error; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 7, 1); +#endif + names = stackPopINT(pVM->pStack); + namep = (char *) stackPopPtr(pVM->pStack); + y2 = stackPopINT(pVM->pStack); + x2 = stackPopINT(pVM->pStack); + y1 = stackPopINT(pVM->pStack); + x1 = stackPopINT(pVM->pStack); + f = stackPopINT(pVM->pStack); + + name = ficlMalloc(names + 1); + if (!name) + vmThrowErr(pVM, "Error: out of memory"); + (void) strncpy(name, namep, names); + name[names] = '\0'; + + if ((error = png_open(&png, name)) != PNG_NO_ERROR) { + if (f & FL_PUTIMAGE_DEBUG) + printf("%s\n", png_error_string(error)); + } else { + if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) + ret = FICL_TRUE; /* success */ + (void) png_close(&png); + } + ficlFree(name); + stackPushUNS(pVM->pStack, ret); +} + +void +ficl_fb_setpixel(FICL_VM *pVM) +{ + FICL_UNS x, y; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 2, 0); +#endif + + y = stackPopUNS(pVM->pStack); + x = stackPopUNS(pVM->pStack); + gfx_fb_setpixel(x, y); +} + +void +ficl_fb_line(FICL_VM *pVM) +{ + FICL_UNS x0, y0, x1, y1, wd; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 5, 0); +#endif + + wd = stackPopUNS(pVM->pStack); + y1 = stackPopUNS(pVM->pStack); + x1 = stackPopUNS(pVM->pStack); + y0 = stackPopUNS(pVM->pStack); + x0 = stackPopUNS(pVM->pStack); + gfx_fb_line(x0, y0, x1, y1, wd); +} + +void +ficl_fb_bezier(FICL_VM *pVM) +{ + FICL_UNS x0, y0, x1, y1, x2, y2, width; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 7, 0); +#endif + + width = stackPopUNS(pVM->pStack); + y2 = stackPopUNS(pVM->pStack); + x2 = stackPopUNS(pVM->pStack); + y1 = stackPopUNS(pVM->pStack); + x1 = stackPopUNS(pVM->pStack); + y0 = stackPopUNS(pVM->pStack); + x0 = stackPopUNS(pVM->pStack); + gfx_fb_bezier(x0, y0, x1, y1, x2, y2, width); +} + +void +ficl_fb_drawrect(FICL_VM *pVM) +{ + FICL_UNS x1, x2, y1, y2, fill; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 5, 0); +#endif + + fill = stackPopUNS(pVM->pStack); + y2 = stackPopUNS(pVM->pStack); + x2 = stackPopUNS(pVM->pStack); + y1 = stackPopUNS(pVM->pStack); + x1 = stackPopUNS(pVM->pStack); + gfx_fb_drawrect(x1, y1, x2, y2, fill); +} + +void +ficl_term_drawrect(FICL_VM *pVM) +{ + FICL_UNS x1, x2, y1, y2; + +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 4, 0); +#endif + + y2 = stackPopUNS(pVM->pStack); + x2 = stackPopUNS(pVM->pStack); + y1 = stackPopUNS(pVM->pStack); + x1 = stackPopUNS(pVM->pStack); + gfx_term_drawrect(x1, y1, x2, y2); +} + +/************************************************************************** + f i c l C o m p i l e G f x +** Build FreeBSD platform extensions into the system dictionary +** for gfx +**************************************************************************/ +static void ficlCompileGfx(FICL_SYSTEM *pSys) +{ + ficlCompileFcn **fnpp; + FICL_DICT *dp = pSys->dp; + assert (dp); + + dictAppendWord(dp, "fb-setpixel", ficl_fb_setpixel, FW_DEFAULT); + dictAppendWord(dp, "fb-line", ficl_fb_line, FW_DEFAULT); + dictAppendWord(dp, "fb-bezier", ficl_fb_bezier, FW_DEFAULT); + dictAppendWord(dp, "fb-drawrect", ficl_fb_drawrect, FW_DEFAULT); + dictAppendWord(dp, "fb-putimage", ficl_fb_putimage, FW_DEFAULT); + dictAppendWord(dp, "term-drawrect", ficl_term_drawrect, FW_DEFAULT); + dictAppendWord(dp, "term-putimage", ficl_term_putimage, FW_DEFAULT); + + return; +} +FICL_COMPILE_SET(ficlCompileGfx); + +void +gfx_interp_md(void) +{ +} diff --git a/stand/ficl/loader.c b/stand/ficl/loader.c index edde4f477d55..618d9483fbd9 100644 --- a/stand/ficl/loader.c +++ b/stand/ficl/loader.c @@ -44,8 +44,6 @@ #include "bootstrap.h" #include #include -#include -#include #include "ficl.h" /* FreeBSD's loader interaction words and extras @@ -65,182 +63,6 @@ * .# ( value -- ) */ -#ifndef TESTMAIN -/* ( flags x1 y1 x2 y2 -- flag ) */ -void -ficl_term_putimage(FICL_VM *pVM) -{ - char *namep, *name; - int names; - unsigned long ret = FICL_FALSE; - uint32_t x1, y1, x2, y2, f; - png_t png; - int error; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 7, 1); -#endif - names = stackPopINT(pVM->pStack); - namep = (char *) stackPopPtr(pVM->pStack); - y2 = stackPopINT(pVM->pStack); - x2 = stackPopINT(pVM->pStack); - y1 = stackPopINT(pVM->pStack); - x1 = stackPopINT(pVM->pStack); - f = stackPopINT(pVM->pStack); - - x1 = gfx_state.tg_origin.tp_col + x1 * gfx_state.tg_font.vf_width; - y1 = gfx_state.tg_origin.tp_row + y1 * gfx_state.tg_font.vf_height; - if (x2 != 0) { - x2 = gfx_state.tg_origin.tp_col + - x2 * gfx_state.tg_font.vf_width; - } - if (y2 != 0) { - y2 = gfx_state.tg_origin.tp_row + - y2 * gfx_state.tg_font.vf_height; - } - - name = ficlMalloc(names + 1); - if (!name) - vmThrowErr(pVM, "Error: out of memory"); - (void) strncpy(name, namep, names); - name[names] = '\0'; - - if ((error = png_open(&png, name)) != PNG_NO_ERROR) { - if (f & FL_PUTIMAGE_DEBUG) - printf("%s\n", png_error_string(error)); - } else { - if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) - ret = FICL_TRUE; /* success */ - (void) png_close(&png); - } - ficlFree(name); - stackPushUNS(pVM->pStack, ret); -} - -/* ( flags x1 y1 x2 y2 -- flag ) */ -void -ficl_fb_putimage(FICL_VM *pVM) -{ - char *namep, *name; - int names; - unsigned long ret = FICL_FALSE; - uint32_t x1, y1, x2, y2, f; - png_t png; - int error; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 7, 1); -#endif - names = stackPopINT(pVM->pStack); - namep = (char *) stackPopPtr(pVM->pStack); - y2 = stackPopINT(pVM->pStack); - x2 = stackPopINT(pVM->pStack); - y1 = stackPopINT(pVM->pStack); - x1 = stackPopINT(pVM->pStack); - f = stackPopINT(pVM->pStack); - - name = ficlMalloc(names + 1); - if (!name) - vmThrowErr(pVM, "Error: out of memory"); - (void) strncpy(name, namep, names); - name[names] = '\0'; - - if ((error = png_open(&png, name)) != PNG_NO_ERROR) { - if (f & FL_PUTIMAGE_DEBUG) - printf("%s\n", png_error_string(error)); - } else { - if (gfx_fb_putimage(&png, x1, y1, x2, y2, f) == 0) - ret = FICL_TRUE; /* success */ - (void) png_close(&png); - } - ficlFree(name); - stackPushUNS(pVM->pStack, ret); -} - -void -ficl_fb_setpixel(FICL_VM *pVM) -{ - FICL_UNS x, y; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 2, 0); -#endif - - y = stackPopUNS(pVM->pStack); - x = stackPopUNS(pVM->pStack); - gfx_fb_setpixel(x, y); -} - -void -ficl_fb_line(FICL_VM *pVM) -{ - FICL_UNS x0, y0, x1, y1, wd; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 5, 0); -#endif - - wd = stackPopUNS(pVM->pStack); - y1 = stackPopUNS(pVM->pStack); - x1 = stackPopUNS(pVM->pStack); - y0 = stackPopUNS(pVM->pStack); - x0 = stackPopUNS(pVM->pStack); - gfx_fb_line(x0, y0, x1, y1, wd); -} - -void -ficl_fb_bezier(FICL_VM *pVM) -{ - FICL_UNS x0, y0, x1, y1, x2, y2, width; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 7, 0); -#endif - - width = stackPopUNS(pVM->pStack); - y2 = stackPopUNS(pVM->pStack); - x2 = stackPopUNS(pVM->pStack); - y1 = stackPopUNS(pVM->pStack); - x1 = stackPopUNS(pVM->pStack); - y0 = stackPopUNS(pVM->pStack); - x0 = stackPopUNS(pVM->pStack); - gfx_fb_bezier(x0, y0, x1, y1, x2, y2, width); -} - -void -ficl_fb_drawrect(FICL_VM *pVM) -{ - FICL_UNS x1, x2, y1, y2, fill; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 5, 0); -#endif - - fill = stackPopUNS(pVM->pStack); - y2 = stackPopUNS(pVM->pStack); - x2 = stackPopUNS(pVM->pStack); - y1 = stackPopUNS(pVM->pStack); - x1 = stackPopUNS(pVM->pStack); - gfx_fb_drawrect(x1, y1, x2, y2, fill); -} - -void -ficl_term_drawrect(FICL_VM *pVM) -{ - FICL_UNS x1, x2, y1, y2; - -#if FICL_ROBUST > 1 - vmCheckStack(pVM, 4, 0); -#endif - - y2 = stackPopUNS(pVM->pStack); - x2 = stackPopUNS(pVM->pStack); - y1 = stackPopUNS(pVM->pStack); - x1 = stackPopUNS(pVM->pStack); - gfx_term_drawrect(x1, y1, x2, y2); -} -#endif /* TESTMAIN */ - void ficlSetenv(FICL_VM *pVM) { @@ -1042,16 +864,6 @@ void ficlCompilePlatform(FICL_SYSTEM *pSys) dictAppendWord(dp, "ccall", ficlCcall, FW_DEFAULT); dictAppendWord(dp, "uuid-from-string", ficlUuidFromString, FW_DEFAULT); dictAppendWord(dp, "uuid-to-string", ficlUuidToString, FW_DEFAULT); -#ifndef TESTMAIN - dictAppendWord(dp, "fb-setpixel", ficl_fb_setpixel, FW_DEFAULT); - dictAppendWord(dp, "fb-line", ficl_fb_line, FW_DEFAULT); - dictAppendWord(dp, "fb-bezier", ficl_fb_bezier, FW_DEFAULT); - dictAppendWord(dp, "fb-drawrect", ficl_fb_drawrect, FW_DEFAULT); - dictAppendWord(dp, "fb-putimage", ficl_fb_putimage, FW_DEFAULT); - dictAppendWord(dp, "term-drawrect", ficl_term_drawrect, FW_DEFAULT); - dictAppendWord(dp, "term-putimage", ficl_term_putimage, FW_DEFAULT); - dictAppendWord(dp, "isvirtualized?",ficlIsvirtualizedQ, FW_DEFAULT); -#endif SET_FOREACH(fnpp, Xficl_compile_set) (*fnpp)(pSys); From nobody Tue Apr 16 20:12:48 2024 X-Original-To: dev-commits-src-branches@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 4VJwFY1XQPz5H0F9; Tue, 16 Apr 2024 20:12:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFX6w1Bz4tBS; Tue, 16 Apr 2024 20:12:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298369; 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=OIx5rf7pBcp+sCgMmsVwCm88YkHFuz8cPyZZvgcXBS0=; b=E3eK4CibwrngcrDRWhy24b4IRVewyuWoE0XuENP5MiE6dAeQe1vVB2ulmk5B4gXDlhgfBp 49uxwnS43kfK/iPtpmAhcqwRPeJDfhHPLi6op7RcL84OBkNPiMcrI69cw4EHzhZSHhd8vr C97132BjTTv6c1NR4c3OY1/pl2KSF4lZ/4OTI/+rj5uVi5b4gdL5196Pk0+tSqLurCS19y NMI6rkIslOyOusQrW9UTKZjwTpDmD/zFczqgfAQo1aNR7v6rLd+jl6cpG2s4dnIGdDYGr0 xWjpgMoJ7pRS7f1mFno0AkaqmuttotKsoagbfs7euiqxJDJNaAnpsDdSoO2NDg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298369; a=rsa-sha256; cv=none; b=LSDYCvEuCBbbWQoOh8oelmBveZjyZnefZFfKqz/bgvZJy/bJyg775CZsV77AeSTlMh69yf N5kygh0p6x8mawRJUUSMIuEr3Hvojl3uGViuDVcEBxnHuEhdnItd5yayJQeEn04ElfnCy5 2aydetgS1e6xGAM6Ad2q+SWCVAWNY3OFIjVKEIfI483tSE0CT+LP2EuCwymI1KCZqg1qXn MNQjNIv3UoQ7XZNsib2g9Qkhgo4cNE1Qq8CTiipO0twZ/d6/148L6VSwpjvnZyC1p/awYW MpR0xpPANbQospmdOeIBEeMYFnlizXneOLIpSoyY52F1tmUygwj3IqhlHWq+MA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298369; 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=OIx5rf7pBcp+sCgMmsVwCm88YkHFuz8cPyZZvgcXBS0=; b=RKM+y7UcEpi8WNN9ShyeM1mqqL0hNY6Y/NapvI/pcPhBy7fOjWmUa9pRDVLc4NBJMdMpYb qkg9Zeag8Vk/RKWc1OXn5mMOVa9VSbU3kfz8hgiPVCNR72FbF7wKecmobF+FHt+RUnCXl/ ElAvWRCauGfDGLJl6ZloZGLsrjDbpQ4V6u/YF/Ady3jpetSTadFRt/V5eC+4Z/NvPHzglz 36JvYadu9d0Mu4ohbgUHbrGjGfjDZiqcAoVVHEkILh+dHveKxuHywY4fI3J5f28tOCsNUP qTXQeZgkcYesx9dPkpvEQ1r5v/3FhMgg8IKJX2YoibW2W9FTSAHYXk84H7SfOg== 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 4VJwFX6V4DzxY1; Tue, 16 Apr 2024 20:12:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCmE0037943; Tue, 16 Apr 2024 20:12:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCmbe037940; Tue, 16 Apr 2024 20:12:48 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:48 GMT Message-Id: <202404162012.43GKCmbe037940@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: e55748d65b74 - stable/14 - loader: Remove gfx_fb_stub.c, it's no longer needed List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e55748d65b746a4ae14e20cdf471398581d3b08a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e55748d65b746a4ae14e20cdf471398581d3b08a commit e55748d65b746a4ae14e20cdf471398581d3b08a Author: Warner Losh AuthorDate: 2024-02-16 03:53:39 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: Remove gfx_fb_stub.c, it's no longer needed Now that we draw in the gfx bindings for all our interpreters only when graphics support is compiled in, we can eliminate this from all the loaders that don't have graphics support. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43905 (cherry picked from commit 23d9b5c9febf4b02957d01bc46ee75530b0dcb4a) --- stand/common/gfx_fb_stub.c | 76 ---------------------------------------- stand/kboot/kboot/Makefile | 2 -- stand/powerpc/ofw/Makefile | 4 +-- stand/uboot/Makefile | 3 +- stand/userboot/userboot/Makefile | 2 -- 5 files changed, 2 insertions(+), 85 deletions(-) diff --git a/stand/common/gfx_fb_stub.c b/stand/common/gfx_fb_stub.c deleted file mode 100644 index a4ebdeb8c388..000000000000 --- a/stand/common/gfx_fb_stub.c +++ /dev/null @@ -1,76 +0,0 @@ -/*- - * Copyright 2021 Toomas Soome - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include -/* - * Generic gfx stubs. - */ - -#include -#include -#include "bootstrap.h" -#include "gfx_fb.h" - -font_list_t fonts = STAILQ_HEAD_INITIALIZER(fonts); -teken_gfx_t gfx_state = { 0 }; - -void -gfx_fb_setpixel(uint32_t x __unused, uint32_t y __unused) -{ -} - -void -gfx_fb_drawrect(uint32_t x1 __unused, uint32_t y1 __unused, - uint32_t x2 __unused, uint32_t y2 __unused, uint32_t fill __unused) -{ -} - -void -gfx_term_drawrect(uint32_t x1 __unused, uint32_t y1 __unused, - uint32_t x2 __unused, uint32_t y2 __unused) -{ -} - -void -gfx_fb_line(uint32_t x0 __unused, uint32_t y0 __unused, - uint32_t x1 __unused, uint32_t y1 __unused, uint32_t w __unused) -{ -} - -void -gfx_fb_bezier(uint32_t x0 __unused, uint32_t y0 __unused, - uint32_t x1 __unused, uint32_t y1 __unused, uint32_t x2 __unused, - uint32_t y2 __unused, uint32_t w __unused) -{ -} - -int -gfx_fb_putimage(png_t *png __unused, uint32_t ux1 __unused, - uint32_t uy1 __unused, uint32_t ux2 __unused, uint32_t uy2 __unused, - uint32_t flags __unused) -{ - return (1); -} diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index 055027b85eb2..2e68a9ba9214 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -21,7 +21,6 @@ INSTALLFLAGS= -b SRCS= \ bootinfo.c \ conf.c \ - gfx_fb_stub.c \ hostcons.c \ hostdisk.c \ hostfs.c \ @@ -32,7 +31,6 @@ SRCS= \ util.c \ vers.c -CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken .if ${MK_LOADER_ZFS} != "no" CFLAGS+= -I${ZFSSRC} CFLAGS+= -I${SYSDIR}/contrib/openzfs/include diff --git a/stand/powerpc/ofw/Makefile b/stand/powerpc/ofw/Makefile index 3e4c92220fac..b7cbbd9fca00 100644 --- a/stand/powerpc/ofw/Makefile +++ b/stand/powerpc/ofw/Makefile @@ -17,9 +17,7 @@ INSTALLFLAGS= -b # Architecture-specific loader code SRCS= conf.c vers.c main.c elf_freebsd.c ppc64_elf_freebsd.c start.c -SRCS+= ucmpdi2.c gfx_fb_stub.c - -CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken +SRCS+= ucmpdi2.c .include "${BOOTSRC}/fdt.mk" .if ${MK_FDT} == "yes" diff --git a/stand/uboot/Makefile b/stand/uboot/Makefile index 83ac5949cbb3..4405f09408bf 100644 --- a/stand/uboot/Makefile +++ b/stand/uboot/Makefile @@ -46,10 +46,9 @@ LDFLAGS+= -Wl,-znotext SRCS+= main.c vers.c SRCS+= copy.c devicename.c elf_freebsd.c glue.c -SRCS+= net.c reboot.c time.c gfx_fb_stub.c +SRCS+= net.c reboot.c time.c SRCS+= uboot_console.c uboot_disk.c uboot_fdt.c uboot_module.c -CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken CFLAGS.glue.c+= -DHAVE_MEMCPY -I${SRCTOP}/sys/contrib/zlib CFLAGS+= -I${BOOTSRC}/common diff --git a/stand/userboot/userboot/Makefile b/stand/userboot/userboot/Makefile index d652f2b53968..15ac8701e4d4 100644 --- a/stand/userboot/userboot/Makefile +++ b/stand/userboot/userboot/Makefile @@ -31,7 +31,6 @@ SRCS+= main.c SRCS+= userboot_cons.c SRCS+= userboot_disk.c SRCS+= vers.c -SRCS+= gfx_fb_stub.c CFLAGS+= -Wall CFLAGS+= -I${BOOTSRC}/userboot @@ -43,7 +42,6 @@ CFLAGS.main.c+= -I${SYSDIR}/contrib/openzfs/include/os/freebsd/zfs .endif CWARNFLAGS.main.c += -Wno-implicit-function-declaration -CFLAGS.gfx_fb_stub.c += -I${SRCTOP}/contrib/pnglite -I${SRCTOP}/sys/teken NEWVERSWHAT= "User boot ${LOADER_INTERP}" ${MACHINE_CPUARCH} VERSION_FILE= ${.CURDIR}/../userboot/version From nobody Tue Apr 16 20:12:49 2024 X-Original-To: dev-commits-src-branches@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 4VJwFZ3LsHz5H0H6; Tue, 16 Apr 2024 20:12:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFZ18LWz4tDl; Tue, 16 Apr 2024 20:12:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298370; 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=zw1HrUWI9uZNPqeduoXMywwsSV8JlPalLiCbyow0RXI=; b=oITvKBx439djDDxW1VWWbUVoD7VzQiGS2gjN9i9R7rP1yHSAw/ysxVEqg5PLEoPMjm3qD7 w+Sx3J5njYvONTIIinKyT5xL03NNvmZcYYYy+E4TL9MhMlKVZvp4RRKTPk/D9yEIbchTqP Xm5JagqbE3UmR2cUDa4G9g1rw0Iq4xp5djFKRQUlSL+yGECxFQDvbGS+waqs1v3agwOb4c OLJiQhwABaKEm9PQBqRGQx7ZRGhECbi5eB7NtbbmRqy93i71HtNHvmyFWHelUJPQSu+4tl qkivWoCxc5priPx7V8bCxfiQtCCDU2Zyrq2hQe4uc0RNFhomEWCbYeZGdd1xHg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298370; a=rsa-sha256; cv=none; b=hrtvVl2NkXDo9E1WoTc98km/PWNggK/o4d7cOkcBo4mv8JOFw2AaxY2WFMCedfe4iQ/xSS mQgsHg6yT13xmNBheONAv7QRwJAMbVDO2cpAQjt8ip9G9IXShTnXCzmqbPVs8BhCfnRRmX CZLdkxdqVcBmkPwKL3DJBDW7QxGXhS89/+4B8aSJpqa/RU0gy62sr8phYVKXxw6eeqFxiJ +SxUN0wxZie25teWC5+r4UZ3jDbphoZHee99PZXh9l3N89X5tJyGjGHmq8sjTPCT95/KZD zA1rxXTAVBUuUWvEO944ZbXMmWSOh5YAgDEs1EGYt2CTfM4b23B1f36OpjsjxQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298370; 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=zw1HrUWI9uZNPqeduoXMywwsSV8JlPalLiCbyow0RXI=; b=SLoEif4Fa0sKgJn/ftjsFuwZWgVRHOTXLCQo7DRJpawFEjm8j2lwgMxmGOxGgPJ0INmW31 ADUBcZqutCBoV6KS79Pm/GyDqE2ZwgASqJqHlB0XbAa5Mqp9M924TojAAskRKidsbRnvsj UFLaci48Fyn39VVZWx9UEIG4F7+cIjBNhaVlsk16pqynab7aZf5u97kgn9+XrvwWCTtGTP PBbC+9wKbkrCGrMXWhotfJpGVPluoKhGaQnseJpkCrKEbqJXfoBW6EvbjLll3K7JW4BB7A lNmdCR3meGVU5daQKkhabeY2KVVf9FoqQstD/JKEqQy2kuntD/PE6YMbRAfYkQ== 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 4VJwFZ0cytzxb1; Tue, 16 Apr 2024 20:12:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCn97038006; Tue, 16 Apr 2024 20:12:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCnEC038003; Tue, 16 Apr 2024 20:12:49 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:49 GMT Message-Id: <202404162012.43GKCnEC038003@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 94e1374b55c7 - stable/14 - loader: Move to using linker sets to bring in optional bits List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 94e1374b55c7c3ac484bbe0631591545a5536c8d Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=94e1374b55c7c3ac484bbe0631591545a5536c8d commit 94e1374b55c7c3ac484bbe0631591545a5536c8d Author: Warner Losh AuthorDate: 2024-02-16 03:53:47 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: Move to using linker sets to bring in optional bits The graphics stuff is optional. When it is pulled into the system, we use a linker set to initialize the lua bindings for it now. Sponsored by: Netflix Reviewed by: kevans, jhb Differential Revision: https://reviews.freebsd.org/D43906 (cherry picked from commit 0921a771da8a9117edf26352a8a047bacbfcee45) --- stand/common/interp_lua.c | 29 +++-------------------------- stand/liblua/gfx_utils.c | 27 +++++++++++++++++++++++++++ stand/liblua/lutils.h | 9 +++++++++ 3 files changed, 39 insertions(+), 26 deletions(-) diff --git a/stand/common/interp_lua.c b/stand/common/interp_lua.c index a347526b67c9..11595b78a7bd 100644 --- a/stand/common/interp_lua.c +++ b/stand/common/interp_lua.c @@ -97,31 +97,6 @@ static const luaL_Reg loadedlibs[] = { {NULL, NULL} }; -static void -interp_init_md(lua_State *L) -{ - luaL_requiref(L, "gfx", luaopen_gfx, 1); - lua_pop(L, 1); /* Remove lib */ - - /* - * Add in the comparability references in the loader table. Doing it with - * a pseudo-embedded script is easier than the raw calls. - */ - if (luaL_dostring(L, - "loader.fb_bezier = gfx.fb_bezier\n" - "loader.fb_drawrect = gfx.fb_drawrect\n" - "loader.fb_line = gfx.fb_line\n" - "loader.fb_putimage = gfx.fb_putimage\n" - "loader.fb_setpixel = gfx.fb_setpixel\n" - "loader.term_drawrect = gfx.term_drawrect\n" - "loader.term_putimage = gfx.term_putimage") != 0) { - lua_pop(L, 1); - const char *errstr = lua_tostring(L, -1); - errstr = errstr == NULL ? "unknown" : errstr; - printf("Error adding compat loader bindings: %s.\n", errstr); - } -} - void interp_init(void) { @@ -129,6 +104,7 @@ interp_init(void) struct interp_lua_softc *softc = &lua_softc; const char *filename; const luaL_Reg *lib; + lua_init_md_t **fnpp; TSENTER(); @@ -148,7 +124,8 @@ interp_init(void) lua_pop(luap, 1); /* remove lib */ } - interp_init_md(luap); + LUA_FOREACH_SET(fnpp) + (*fnpp)(luap); filename = getenv("loader_lua"); if (filename == NULL) diff --git a/stand/liblua/gfx_utils.c b/stand/liblua/gfx_utils.c index d2d22738c929..8d2aaacbd688 100644 --- a/stand/liblua/gfx_utils.c +++ b/stand/liblua/gfx_utils.c @@ -245,3 +245,30 @@ void gfx_interp_md(void) { } + +static void +gfx_init_md(lua_State *L) +{ + luaL_requiref(L, "gfx", luaopen_gfx, 1); + lua_pop(L, 1); /* Remove lib */ + + /* + * Add in the compatibility references in the loader table. Doing it with + * a pseudo-embedded script is easier than the raw calls. + */ + if (luaL_dostring(L, + "loader.fb_bezier = gfx.fb_bezier\n" + "loader.fb_drawrect = gfx.fb_drawrect\n" + "loader.fb_line = gfx.fb_line\n" + "loader.fb_putimage = gfx.fb_putimage\n" + "loader.fb_setpixel = gfx.fb_setpixel\n" + "loader.term_drawrect = gfx.term_drawrect\n" + "loader.term_putimage = gfx.term_putimage") != 0) { + lua_pop(L, 1); + const char *errstr = lua_tostring(L, -1); + errstr = errstr == NULL ? "unknown" : errstr; + printf("Error adding compat loader bindings: %s.\n", errstr); + } +} + +LUA_COMPILE_SET(gfx_init_md); diff --git a/stand/liblua/lutils.h b/stand/liblua/lutils.h index c1fd6af496e5..522abfd3d0d4 100644 --- a/stand/liblua/lutils.h +++ b/stand/liblua/lutils.h @@ -30,3 +30,12 @@ int luaopen_gfx(lua_State *); int luaopen_loader(lua_State *); int luaopen_io(lua_State *); int luaopen_pager(lua_State *); + +#include + +typedef void lua_init_md_t(lua_State *); +#define LUA_COMPILE_SET(func) \ + DATA_SET(Xficl_compile_set, func) /* XXX linker set know by ldscrips */ +#define LUA_FOREACH_SET(s) \ + SET_FOREACH((s), Xficl_compile_set) +SET_DECLARE(Xficl_compile_set, lua_init_md_t); From nobody Tue Apr 16 20:12:51 2024 X-Original-To: dev-commits-src-branches@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 4VJwFb3xL0z5H0Vm; Tue, 16 Apr 2024 20:12:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFb22rMz4swB; Tue, 16 Apr 2024 20:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298371; 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=GXr3dEicL9EZ4NQ1Cq6FyS5C9A2ItQbFnarhWcrfKr4=; b=DPB/lpz6IsKcZcsab4+AujjWHcze8kmvmuztaLxGwH5z7dRwDEi2gLBuqF6UMAJ3GgZLuT nSCtIVzGXluT/mQb9BS8sVf//eOhPm8WeYyOxK4LdP8kmU0RaG5i6kzSK626H3xcIaZCrm pdWNospYa8iDd6TvHwf8zscH0bBrgpqJtfmt6ozTWgTRTFX9bFMPhLu0/rnotQdHy1tTrn lqVzWWyucnFfPLVUH0zHGsFzqQEfUa2c/o7on50DOaA3fR5Cgqure6UPEP9Q7Vc9wNdFz0 GHOM5IjfRPWAF4He7+zAvQUtbJAdnUU8OR4gCEnQVsgsGbbUisGLqvPIejrerg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298371; a=rsa-sha256; cv=none; b=Y5knfE4eYIY17gxuAWuWr8lFdCJg3rjSiREw9uUji7RKIvjM92PXi5x8ipoSWKquG0qL4k 9tgbBRJSJWQJt9Dop12OdRgYqp8h+I+0NrW0D2CoawwsLwcTXXVq+2zRnaXXEsu22TPIps U9yXUzZ1+nBsgTDv2JrLiHNCxKCqb0KgiKXo7zagVUiERlr+XzObAPAzTzisXdWvecxy/a sFTX/mu6VhMPeb9anb3Y9muN/ITin0BrGAVmym4uqe1jm8at8pmeVW9+RueXefUyI2n+ri oCoTeE0riVHheEfLXa/5YRNCErlHLHXCdF1c/Z7Pz36Rp8ASrYpESwFjyyq3OQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298371; 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=GXr3dEicL9EZ4NQ1Cq6FyS5C9A2ItQbFnarhWcrfKr4=; b=DuznT3c17yDTYjP8nVT3g4cxn523GlADfowJE1s4+iFEYoelxBJ4ry1hzyvR1gR72B288e N7o6tkCpOJOME9wFGZmmyiJCLS5KSOHvwnvCEXmQTEK/HRnjAkDK10dU2Qvp/+WZ4LE4mC MzQbctLbu5WQN0w4/B0CMM/jFOL/O9qMfTXA/HNYIDTEJmD/NF7VeQStbPowzi2k7YLMrl U9ECx0szXMbC7CMcD/Xe/yLwM42RcWaVt+NrWid1DjbfPczbu4otlyMyg63Q7g/Mp1EwRZ zS+SWELGU+cH6N8VivCR/YC6PVcX9CD1SL1JyPcZTHhWd+MJvQA2LIKSM4rP9w== 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 4VJwFb1TKvzxPN; Tue, 16 Apr 2024 20:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCpQe038061; Tue, 16 Apr 2024 20:12:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCptI038058; Tue, 16 Apr 2024 20:12:51 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:51 GMT Message-Id: <202404162012.43GKCptI038058@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 32c08f492557 - stable/14 - loader: Move gfx functions to gfx.lua.8 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 32c08f492557b8159f0017412eb8b3b7183d5754 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=32c08f492557b8159f0017412eb8b3b7183d5754 commit 32c08f492557b8159f0017412eb8b3b7183d5754 Author: Warner Losh AuthorDate: 2024-02-16 03:53:55 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: Move gfx functions to gfx.lua.8 Now that the fb_* and term_* functions are available in the gfx table, move the documentation to gfx.lua.8. Add information about backwards compatibility. Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D43907 (cherry picked from commit a8f8c53761c4b0436c9d546ebe046003f1b3d88f) --- stand/lua/Makefile | 1 + stand/lua/gfx.lua.8 | 106 +++++++++++++++++++++++++++++++++++++++++++++++++ stand/lua/loader.lua.8 | 89 ++++++++--------------------------------- 3 files changed, 124 insertions(+), 72 deletions(-) diff --git a/stand/lua/Makefile b/stand/lua/Makefile index e8fa16e6b589..4462a803beef 100644 --- a/stand/lua/Makefile +++ b/stand/lua/Makefile @@ -7,6 +7,7 @@ MAN= loader.conf.lua.5 \ config.lua.8 \ core.lua.8 \ drawer.lua.8 \ + gfx.lua.8 \ hook.lua.8 \ loader.lua.8 \ menu.lua.8 \ diff --git a/stand/lua/gfx.lua.8 b/stand/lua/gfx.lua.8 new file mode 100644 index 000000000000..82d3f90f4af7 --- /dev/null +++ b/stand/lua/gfx.lua.8 @@ -0,0 +1,106 @@ +.\" +.\" Copyright (c) 2024 Netflix, Inc. +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.Dd February 6, 2024 +.Dt GFX.LUA 8 +.Os +.Sh NAME +.Nm gfx.lua +.Nd Fx Lua gfx module +.Sh DESCRIPTION +The built-in graphics related Lua bindings for the +.Fx +boot loaders using the Lua interpreter are available via the +.Ic gfx +table. +.Ss Exported Functions +The following functions are exported in the +.Nm loader +table. +.Bl -tag -width term_putimage +.It Fn fb_bezier x0 y0 x1 y1 x2 y2 width +Draw a bezier curve through the points +.Pq Va x0 , Va y0 , +.Pq Va x1 , Va y1 , +and +.Pq Va x2 , Va y2 +of width +.Va width . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_drawrect x0 y0 x1 y1 fill +Fill in a rectangle with the pixel +.Va fill +with the corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_line x0 y0 x1 y1 width +Draw a line from +.Pq Va x0 , Va y0 +to +.Pq Va x1 , Va y1 +with a width of +.Va width . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_putimage name x0 y0 x1 y1 f +Load the PNG file +.Va name +and place it in the rectangle +with the corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 +and fill with pixel +.Va f . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn fb_set_pixel x y +Sets the pixel at +.Pq Va x , Va y . +The units are in pixels and have an origin of +.Pq 0 , 0 . +.It Fn term_drawrect x0 y0 x1 y1 +Draw the outline of a rectangle with the text coordinate corners of +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 . +The units are in character cells and have an origin of +.Pq 1 , 1 . +.It Fn term_putimage name x0 y0 x1 y1 f +Load the PNG file +.Va name +and place it in the rectangle +with the text coordinate corners +.Pq Va x0 , Va y0 +and +.Pq Va x1 , Va y1 +and fill with pixel +.Va f . +The units are in character cells and have an origin of +.Pq 1 , 1 . +.El +.Pp +This table is optional and should only be used if it is non-nil and if +.Fn core.isFramebufferConsole +is true. +.Ss Compatibility +All the interfaces described above are also available via the +.Ic loader +table through at last FreeBSD 15.0. +.Sh SEE ALSO +.Xr loader.conf 5 , +.Xr core.lua 8 , +.Xr loader 8 , +.Xr loader.lua 8 +.Sh AUTHORS +The +.Nm +man page was written by +.An Warner Losh Aq Mt imp@FreeBSD.org . + diff --git a/stand/lua/loader.lua.8 b/stand/lua/loader.lua.8 index cd436255d4a5..ff3b91ddfb09 100644 --- a/stand/lua/loader.lua.8 +++ b/stand/lua/loader.lua.8 @@ -147,80 +147,24 @@ environments. Removes the environment variable .Va name from the loader's environment list. -.It Fn fb_bezier x0 y0 x1 y1 x2 y2 width -Draw a bezier curve through the points -.Pq Va x0 , Va y0 , -.Pq Va x1 , Va y1 , -and -.Pq Va x2 , Va y2 -of width -.Va width . -The units are in pixels and have an origin of -.Pq 0 , 0 . -.It Fn fb_drawrect x0 y0 x1 y1 fill -Fill in a rectangle with the pixel -.Va fill -with the corners -.Pq Va x0 , Va y0 -and -.Pq Va x1 , Va y1 . -The units are in pixels and have an origin of -.Pq 0 , 0 . -.It Fn fb_line x0 y0 x1 y1 width -Draw a line from -.Pq Va x0 , Va y0 -to -.Pq Va x1 , Va y1 -with a width of -.Va width . -The units are in pixels and have an origin of -.Pq 0 , 0 . -.It Fn fb_putimage name x0 y0 x1 y1 f -Load the PNG file -.Va name -and place it in the rectangle -with the corners -.Pq Va x0 , Va y0 -and -.Pq Va x1 , Va y1 -and fill with pixel -.Va f . -The units are in pixels and have an origin of -.Pq 0 , 0 . -.It Fn fb_set_pixel x y -Sets the pixel at -.Pq Va x , Va y . -The units are in pixels and have an origin of -.Pq 0 , 0 . -.It Fn term_drawrect x0 y0 x1 y1 -Draw the outline of a rectangle with the text coordinate corners of -.Pq Va x0 , Va y0 -and -.Pq Va x1 , Va y1 . -The units are in character cells and have an origin of -.Pq 1 , 1 . -.It Fn term_putimage name x0 y0 x1 y1 f -Load the PNG file -.Va name -and place it in the rectangle -with the text coordinate corners -.Pq Va x0 , Va y0 -and -.Pq Va x1 , Va y1 -and fill with pixel -.Va f . -The units are in character cells and have an origin of -.Pq 1 , 1 . .El -.Pp -The functions starting with -.Fn fb_ +.Ss Compatibility +The functions +.Fn fb_bezier , +.Fn fb_drawrect , +.Fn fb_line , +.Fn fb_putimage , +.Fn fb_set_pixel , +.Fn term_drawrect , and -.Fn term_ -are optional. -They should only be used if they are non-nil and if -.Fn core.isFramebufferConsole -is true. +.Fn term_putimage +have moved to the +.Ic gfx +table. +They remain in the +.Ic loader +table for a transition period and are documented in +.Xr gfx.lua 8 . .Ss Default File In addition, the Lua interpreters start with the file .Pa /boot/lua/loader.lua @@ -231,6 +175,7 @@ If autoboot is enabled, the loaded files will boot. .Sh SEE ALSO .Xr loader.conf 5 , .Xr core.lua 8 , +.Xr gfx.lua 8 , .Xr loader 8 , .Xr sysctl 8 .Sh AUTHORS From nobody Tue Apr 16 20:12:52 2024 X-Original-To: dev-commits-src-branches@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 4VJwFc53lRz5H0QZ; Tue, 16 Apr 2024 20:12:52 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFc3HMVz4t4R; Tue, 16 Apr 2024 20:12:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298372; 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=blR7E0jGBYPxNDCSyX7HUCy44+dGT1JAMOmpFVxz0sM=; b=ooqJ00g7B3ZVUXoWw6cwFo2mqo/lq+izZRaCh/jpghwXPs+vH2yx1YpdJlLA514CZol3eD nRPXl1Dq65CO91M342kC44wwY0sakMwwo0qwPKiDgjWYBqAkcHuAsoSAOAzDgnCXSSWEvn ZklwOcpXCOC+5nyU+n++qxYdW1FoZktLHdy18760ec+hzctoEf+SlMNBCII8OJkxo9Ea5h x4S9dqykkSHOn16WRbo1PGa9RyYpa88ZiQpJHMWgAfE7uVeObgzj+vfKVidE3Exnx+Fxrh XYcyI6krlXWHpjcEpLIn0WtuQVpYgMJZPz/aWKn534IEehU/7mR0C4nALZb/2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298372; a=rsa-sha256; cv=none; b=oD6xX1VQCTLkcpA8Vm9So9/nY9NKgM9aANWD4ymp8K1WD06hSG1HlvrwXc15huAxn8bFOK /ar0KrjXa81YxjuvbixdBGvXja6g8bSC9SERFDhQL7SEmntIiEiWKHeam2z8aNS58fTmCf CSieAG/SX+BEep8pypCuIMfqeHiREcJn3WH1TAJ1TM/SuSd+dwK9/NruNSxvQ1TiW3E7jZ lQ2bV7QwTXDCqmSJSt7EH17GgrP7LRd6pOyvZ2O8ljEImOexANJJP+qRGjXPXLKFNCUimy 747ygb3Jk6MBRmD9gYmsSxatBofGcR6yNKpvpeodwE8IHIinQRJtLOeNqv4atA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298372; 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=blR7E0jGBYPxNDCSyX7HUCy44+dGT1JAMOmpFVxz0sM=; b=FWZ0Nf1aADM7P0e/mmdrUA2A+LKJbHlrcP9/4zqvZ17LlvLQvHvHPfoqdMQtCnxBzc/wwF p/XVm+tKjerZG1Nenq0K9tjOJ98epAWyMIPjgU0kiOWCLq1Ig/QG9q3W2QWbR2G5TyQsVF y+kaPuQTBB1rYg6XQAl6pEb/Q30hulYh3z6Km+ZBI6fryFqKzAomMaulAqFNF3H09ZZDAM G3O608LdeSN2p44n8taaNo4XUGG0x4RZQHA/6bHNLw9vOZyWnfOeY3tUmVOmODyCDYxU4/ P8aZF3hZG1fXZ/liaGHBLh7xr/2YmocUq5dIF0FlCbAt7rbEqb29BD1ncg1AmA== 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 4VJwFc2Tphzwhf; Tue, 16 Apr 2024 20:12:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCqK3038109; Tue, 16 Apr 2024 20:12:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCqqu038106; Tue, 16 Apr 2024 20:12:52 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:52 GMT Message-Id: <202404162012.43GKCqqu038106@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 19388dd2ad91 - stable/14 - loader: Move drawer.lua over to gfx table. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 19388dd2ad91c087ca65fd3fbad4ca69ffdd0912 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=19388dd2ad91c087ca65fd3fbad4ca69ffdd0912 commit 19388dd2ad91c087ca65fd3fbad4ca69ffdd0912 Author: Warner Losh AuthorDate: 2024-02-16 03:54:04 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: Move drawer.lua over to gfx table. Drawer.lua is the only bit of lua code in the base that uses any of the functons moved from the loader table to the gfx table. Move the main code to using the gfx dispatch. Add compat code for running on old loaders that creates the newer-style gfx table with the term_* functions we call in it populated. This will even work on the super old versions of the loader that don't have them (we'll still skip using them). Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D43908 (cherry picked from commit 0fd98b8a7691b4f11e1bfbcb53a3a7c68d7c1fb7) --- stand/lua/drawer.lua | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/stand/lua/drawer.lua b/stand/lua/drawer.lua index 2dcf7d5de0f8..a009b78164df 100644 --- a/stand/lua/drawer.lua +++ b/stand/lua/drawer.lua @@ -47,6 +47,19 @@ local frame_size local default_shift local shift +-- Make this code compatible with older loader binaries. We moved the term_* +-- functions from loader to the gfx. if we're running on an older loader that +-- has these functions, create aliases for them in gfx. The loader binary might +-- be so old as to not have them, but in that case, we want to copy the nil +-- values. The new loader will provide loader.* versions of all the gfx.* +-- functions for backwards compatibility, so we only define the functions we use +-- here. +if gfx == nil then + gfx = {} + gfx.term_drawrect = loader.term_drawrect + gfx.term_putimage = loader.term_putimage +end + local function menuEntryName(drawing_menu, entry) local name_handler = menu_name_handlers[entry.entry_type] @@ -225,8 +238,8 @@ local function drawframe() x = x + shift.x y = y + shift.y - if core.isFramebufferConsole() and loader.term_drawrect ~= nil then - loader.term_drawrect(x, y, x + w, y + h) + if core.isFramebufferConsole() and gfx.term_drawrect ~= nil then + gfx.term_drawrect(x, y, x + w, y + h) return true end @@ -312,9 +325,9 @@ local function drawbrand() end if core.isFramebufferConsole() and - loader.term_putimage ~= nil and + gfx.term_putimage ~= nil and branddef.image ~= nil then - if loader.term_putimage(branddef.image, 1, 1, 0, 7, 0) + if gfx.term_putimage(branddef.image, 1, 1, 0, 7, 0) then return true end @@ -363,14 +376,14 @@ local function drawlogo() end if core.isFramebufferConsole() and - loader.term_putimage ~= nil and + gfx.term_putimage ~= nil and logodef.image ~= nil then local y1 = 15 if logodef.image_rl ~= nil then y1 = logodef.image_rl end - if loader.term_putimage(logodef.image, x, y, 0, y + y1, 0) + if gfx.term_putimage(logodef.image, x, y, 0, y + y1, 0) then return true end From nobody Tue Apr 16 20:12:53 2024 X-Original-To: dev-commits-src-branches@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 4VJwFd6M5dz5H0Qd; Tue, 16 Apr 2024 20:12:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFd40WQz4t4f; Tue, 16 Apr 2024 20:12:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298373; 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=5/zk9KC8Q4RsaQHAVzD+y/Kpr3yMqsv0BaBqQ6uGnnE=; b=XJbEdiHpdtyXpACisVut+ULBkbeOATsZ0RmwwGdGpKi4E/ItLAe/bpMPDP4zzdrTTt9m3R AiwdhzYlJnQ6wgPOj0OGH5sVjeieSoUSbbUmOVCk+u9ucwoCPD0DeXnD2amX2gicRn6NMW pjubVDkXfQ59R47ukBfVvnSWLuHsOPGjOX74NXRY/247JQ0Ce38FSE449NqUfO4fyeeCzm 8hIR08BtYYY8w9XVbAhI06pk/zGXH+kzS7n3o3NtYXx3G/4775BdkUBqUNa90L51ZxIFq6 bnZN1mbmW/K7zDTFiFprWbY9hgiHXOfd1Y3ljNhOFx+eKRs34h7VpUupw8NiVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298373; a=rsa-sha256; cv=none; b=u4hx7/t+c6KcizNJisv0JlR5IhmCFobxfWnhE9AOHZW1cReaYeBxVhGgQaudZ2wqHmIymY H4UJt+PL+PChWsZEF3HvVT58EOdHo+xXsHOWWBjp14lnuUKhbOndtI5l4bGpPhTLzekXb2 gxNxY92k5Vtbn6Omgbo/gZg8KYRZR+RhLoOSiJJL41B9hAWygd0L+UGTrRC97Wvyj4uXTY yb6KusgdQYBr3VTMNQi/8g8FU5V7aBX/rlp1zwIKAx8HIc4iA+TMrcB2TajqUGzunEXTxX mE4/UZrdOOJ+CU/HGEoNhjgYKCE3gzXEROslgipvJ9RSX4A6+ieDhsngriOtnQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298373; 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=5/zk9KC8Q4RsaQHAVzD+y/Kpr3yMqsv0BaBqQ6uGnnE=; b=cq5H06Rnx8HNZbviDuMHzCef56mbvWwHhRHIURCy9iiR9WiLF8zCd+n16UusUrLThvDVHe now0boBVwiThP6l9V270sauu1FLt9Bl4kUeFxXgIGbsoflMlVtByJ6EPh0WdvK8WU9dqT5 rp8gT7l6Wn9TYCxFZED8NWUnx/nJ53zXHPtbZJpdvaM4pbyvmYiGDIspJKf95vUuVV6jWV zsjzb/zFAecjLgf6oRUfFPPhLHmGfme0ulbCIK8fOhesh/C14vB2pYSP0gFcrL2bUErOvw tbwXi5PQB4hTSOV+VOpxptUmQMCn8gFCAf/Gio2afaUajP+sXZT9TY0eYTua/A== 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 4VJwFd3ZszzxY2; Tue, 16 Apr 2024 20:12:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCr6N038156; Tue, 16 Apr 2024 20:12:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCrP5038153; Tue, 16 Apr 2024 20:12:53 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:53 GMT Message-Id: <202404162012.43GKCrP5038153@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 78f5850093c5 - stable/14 - kboot: Add our own lua bindings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 78f5850093c5afe2a710903b2422dfc9857e401d Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=78f5850093c5afe2a710903b2422dfc9857e401d commit 78f5850093c5afe2a710903b2422dfc9857e401d Author: Warner Losh AuthorDate: 2024-02-16 03:54:55 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 kboot: Add our own lua bindings Create a small wrapper around the new flua hash module so we can use it here too. There's no 4th bindings, nor will they be created. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43874 (cherry picked from commit e34fd722cafe8639214c72997f08b5f5faa9c21f) --- stand/defs.mk | 1 + stand/i386/loader/Makefile | 2 +- stand/kboot/kboot/Makefile | 7 +++++++ stand/kboot/kboot/lua_bindings.c | 19 +++++++++++++++++++ stand/liblua/Makefile | 3 +++ 5 files changed, 31 insertions(+), 1 deletion(-) diff --git a/stand/defs.mk b/stand/defs.mk index e8480a8c2b1e..3624b9311161 100644 --- a/stand/defs.mk +++ b/stand/defs.mk @@ -62,6 +62,7 @@ BINDIR?= /boot # LUAPATH is where we search for and install lua scripts. LUAPATH?= /boot/lua FLUASRC?= ${SRCTOP}/libexec/flua +FLUALIB?= ${SRCTOP}/lib/flua LIBSA= ${BOOTOBJ}/libsa/libsa.a .if ${MACHINE} == "i386" diff --git a/stand/i386/loader/Makefile b/stand/i386/loader/Makefile index de96e1329b2f..57191b3c8f78 100644 --- a/stand/i386/loader/Makefile +++ b/stand/i386/loader/Makefile @@ -33,7 +33,7 @@ VERSION_FILE= ${.CURDIR}/../loader/version # # will tell you how many kiB of lomem are available. # -LOADERSIZE?= 550000 # Largest known safe size for loader.bin +LOADERSIZE?= 570000 # Largest known safe size for loader.bin .PATH: ${BOOTSRC}/i386/loader diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index 2e68a9ba9214..b571c3acada1 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -60,4 +60,11 @@ CFLAGS+= -Wall DPADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} ${LIBKBOOT} LDADD= ${LDR_INTERP} ${LIBOFW} ${LIBSAFDT} ${LIBSA} ${LIBKBOOT} +# Add our own lua bindings until they are universal +.if ${LOADER_INTERP} == "lua" +SRCS+= \ + lua_bindings.c +CFLAGS.lua_bindings.c+= -I${FLUALIB}/libhash +.endif + .include diff --git a/stand/kboot/kboot/lua_bindings.c b/stand/kboot/kboot/lua_bindings.c new file mode 100644 index 000000000000..ca5d0253c21f --- /dev/null +++ b/stand/kboot/kboot/lua_bindings.c @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2024 Netflix, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include "lua.h" +#include "lauxlib.h" +#include "lutils.h" +#include "lhash.h" + +static void +lua_hash_bindings(lua_State *L) +{ + luaL_requiref(L, "hash", luaopen_hash, 1); + lua_pop(L, 1); /* Remove lib */ +} + +LUA_COMPILE_SET(lua_hash_bindings); diff --git a/stand/liblua/Makefile b/stand/liblua/Makefile index bbfa21e07f53..b0d89bec4f02 100644 --- a/stand/liblua/Makefile +++ b/stand/liblua/Makefile @@ -27,6 +27,8 @@ SRCS+= gfx_utils.c .PATH: ${FLUASRC}/modules SRCS+= lfs.c +.PATH: ${FLUALIB}/libhash +SRCS+= lhash.c WARNS?= 3 @@ -36,6 +38,7 @@ CFLAGS+= -fno-stack-protector -D__BSD_VISIBLE CFLAGS+= -I${BOOTSRC}/include -I${LIBLUASRC} -I${LUASRC} -I${LDRSRC} CFLAGS.gfx_utils.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite +CFLAGS.lhash.c+= -I${FLUALIB}/libhash -I${SRCTOP}/sys/crypto/sha2 .if ${MACHINE_CPUARCH} == "amd64" && ${DO32:U0} == 0 CFLAGS+= -fPIC From nobody Tue Apr 16 20:12:54 2024 X-Original-To: dev-commits-src-branches@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 4VJwFg0TcRz5H0gt; Tue, 16 Apr 2024 20:12:55 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFf53JNz4t79; Tue, 16 Apr 2024 20:12:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298374; 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=kny40haFki/fpDXrs46vcYrlnYHS/Q9/enBoZ7HoMs8=; b=Bmoh4o9DA8sp0Om65gOqMBpDPY372JC7DGjVgWerKpk8fD4kHecYNUU3YDJvn9EVhbAjFj 8zjn+tB9VjRdPQZXAsDnQ5ITso1rkaXcxxYJUhnhNuUbXaEkunDVRHkBYhpYnSo17nIY9g ys92NJPNtIdOl2jpfqM9R2nbJJBefALhSZaK/oGJrbsiFDSoB3w3X8NLumYt52X1u8X7mh mSGqZv6gywk7vmkK024ivr3oH2S7zbspyYZhOoe4Ls1atU+4XtrtDTEQwQ6ViTEe9r1dPV g0rJDsqVux8ExsUUcq9tgJ75u95ONLcJXKjcmyd2J3Bk07kALQZnf4d8+WDKvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298374; a=rsa-sha256; cv=none; b=LVDzg2WNnztiVDL4xJy4Z9e5IxZLLS56/tmLieAm8BAyUs4Q2iZmdZXpU1THA58X71IC3V XLaqUKBgxRgirw7/lrvg2O1twhAdMxWFhs+Pwt8CnRfZk5mSyAKY0uORx+yEpDfnA+0bbs FEQTwYmpKBlTeXyTwZr6Fvo7fBlsAyXRdGamMrou0OGs9gs1JwkSRh8VfrCC7Bll72U9l7 oLwmlsVYVNfnvhMpc7GQWQJkq2iUt367X0FtVkdt1qorGTDI6YNJi3znRzwmiVjU4Y24gl nZ4f6Nj4LUJC1T9bVavCTAgdGJI5Zla7p9ZvOHDAhCJy06P7Vg5/TZ3FW7dJbg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298374; 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=kny40haFki/fpDXrs46vcYrlnYHS/Q9/enBoZ7HoMs8=; b=waNHFOMdTo+TLKPkzP3kMIAQLRTzqhNDPZRsXV5UUsrdNUCRT+MwV1GjD/gRYEHHAVmdl5 o4v8nymSfWofkPZ7L7/UyoeVM938POZSFhI1WrPhA1OcyYvIBKoi8wBBp2e99GnPvpPxqj XBnmrH2UIaKO8dEtk3PO79nSW8a2Mp2jObOX8wZDyDIJgHBY3b3e6DSBwn51joHgDBAcii 41hWyA48q9pbqaYe16OgE6u5aW/c7r6i9PcLueX7Nssos1CIN2ExHpRL8oHazXQkGJHH49 oyhDHAuNos+4LekHeKn1C/1nVS+wKzg5P2CrOj6YvXi3qpMSQbGQZ2HcZKctzQ== 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 4VJwFf4d1PzxJV; Tue, 16 Apr 2024 20:12:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCsNv038200; Tue, 16 Apr 2024 20:12:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCssm038197; Tue, 16 Apr 2024 20:12:54 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:54 GMT Message-Id: <202404162012.43GKCssm038197@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: c34c7f78c751 - stable/14 - loader: Simplify build a little List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c34c7f78c751fc594fedaeab85368bd8fd91e405 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c34c7f78c751fc594fedaeab85368bd8fd91e405 commit c34c7f78c751fc594fedaeab85368bd8fd91e405 Author: Warner Losh AuthorDate: 2024-02-16 03:55:05 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: Simplify build a little Confine -DDISK_DEBUG to biosdisc.c, the only file it affects. Use modern variable arrays instead of alloca and add a sanity size minimum for biospnp nodes. These nodes are tiny enough that we needn't do a malloc/free pair: the stack is fine. Sponsored by: Netflix Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D43914 (cherry picked from commit 588ff0748f4acf8e00395f86e4956f184c7d3795) --- stand/i386/libi386/Makefile | 8 ++------ stand/i386/libi386/biospnp.c | 3 ++- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/stand/i386/libi386/Makefile b/stand/i386/libi386/Makefile index 0bc0efd35f22..fcba20fa26c4 100644 --- a/stand/i386/libi386/Makefile +++ b/stand/i386/libi386/Makefile @@ -23,7 +23,7 @@ CFLAGS+= -DCOMSPEED=${BOOT_COMCONSOLE_SPEED} .ifdef(BOOT_BIOSDISK_DEBUG) # Make the disk code more talkative -CFLAGS+= -DDISK_DEBUG +CFLAGS.biosdisk.c+= -DDISK_DEBUG .endif # terminal emulation @@ -35,11 +35,7 @@ CFLAGS.teken.c+= -I${SRCTOP}/sys/teken CFLAGS.bootinfo.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite CFLAGS.vbe.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite -# XXX: make alloca() useable -CFLAGS+= -Dalloca=__builtin_alloca - -CFLAGS+= -I${BOOTSRC}/ficl -I${BOOTSRC}/ficl/i386 \ - -I${LDRSRC} -I${BOOTSRC}/i386/common \ +CFLAGS+= -I${LDRSRC} -I${BOOTSRC}/i386/common \ -I${SYSDIR}/contrib/dev/acpica/include # Handle FreeBSD specific %b and %D printf format specifiers diff --git a/stand/i386/libi386/biospnp.c b/stand/i386/libi386/biospnp.c index 7e3bc97a35ee..a26c0d4d52d8 100644 --- a/stand/i386/libi386/biospnp.c +++ b/stand/i386/libi386/biospnp.c @@ -155,6 +155,7 @@ biospnp_enumerate(void) { uint8_t Node; struct pnp_devNode *devNodeBuffer; + uint8_t buffer[max(pnp_NodeSize, sizeof(*devNodeBuffer))]; int result; struct pnpinfo *pi; int count; @@ -163,7 +164,7 @@ biospnp_enumerate(void) if (biospnp_init()) return; - devNodeBuffer = (struct pnp_devNode *)alloca(pnp_NodeSize); + devNodeBuffer = (struct pnp_devNode *)buffer; Node = 0; count = 1000; while((Node != 0xff) && (count-- > 0)) { From nobody Tue Apr 16 20:12:55 2024 X-Original-To: dev-commits-src-branches@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 4VJwFh25G2z5H0kQ; Tue, 16 Apr 2024 20:12:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFg5t10z4tCg; Tue, 16 Apr 2024 20:12:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298375; 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=e0DI5mGyZo6+U4mGeCn1chOFExfpp/ZAxJJr4LeZA/Y=; b=rjzGtQai06xVY/I3JbU8WSd5aPBzS5Yd+Hq3C0cbA6WvCN5Xn4BPIM0d5vQDEjdQHo4njj vhrxphajHNJOYMYs5GQttH4WZ9eG6JdwOhwz8Mw14OTm6C9m7XuMza0GFDgtWSZYcwOnZS 7J1/7Y9VmAksBrdfpjZfXp/RTAGLpJ30dL0Zpvl2OapC7XIE0uX0j6uqEZ32kd4TqtrAkZ 7xCYFm6y140jF/kEFxRn0rm7GV5TsrS+Z8CgqeEI1EVBYh/dC3wIANz2qG0i/36dITKiS0 xQ5ct1LlCPngNWwEp4CsxG4k8NGOkVNQQqqzIYl8lio4F+JRN6aZSVsswuV6ig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298375; a=rsa-sha256; cv=none; b=Kt9c0NM7b7MYILmumpfhd3RCb7Wc+xZY4SbYXkD+5GmVzm2r0FbJEUDp7Xz/WkO46FCkwO sJw5LHHVjjbzDhNEya9Nl3L3aaoxlPr6BLPpxLM5t8m4wiKH8JnfF2iZUSjPOmg4HjhXkd aFKG+w9XOcXagf1IDjPaInPQ1Hf8sgzaJGG1aruyfieqGcZblKBmQ/LyVS5F49htT6hHk0 CWDHVJe+qTeIUScRYVZfNhcN08M75vECDBgUlgtLEVdDZa/JXx8Sr+1IOBsBSbj0LxR3Xb 58CA5e10chz2QkHd7SXAGK9wl8Gi/ejYm3Z6MjU4z6ky3+nPLucatNqrdkkQ7A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298375; 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=e0DI5mGyZo6+U4mGeCn1chOFExfpp/ZAxJJr4LeZA/Y=; b=Y63koWnYFzWk5Y9YGDbzEgaa5iMJZ/7MMyKFENXjKcDKSnuaBqO93dVzh4YiCtNdyza3Rv k51sylLax0OqPImXOO89sleXUHPo40Op0Ba6wieL8+6jr+0FL1MV4kVsn2UCCAUt9NRF78 Uo3H7PsjA3nL6fmgO8NW6Kb2BDGjd4hQgBI73gZtVWpnwT/xyYpb05oGiFj2ZctuHvmNxJ Zc0+UJJfsde/p90qAbOE0Kg3eaG6Qqo7duw5owpx0Ictdx4OL0irV1LLFgmPfNDDAZE6oZ Yjlun1617TkmZk1qz872vcmjh23N/0xMePE21MXoY+mY5pPmavVXjPKxy1+C+A== 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 4VJwFg5TbTzxWQ; Tue, 16 Apr 2024 20:12:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCts3038252; Tue, 16 Apr 2024 20:12:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCtr3038249; Tue, 16 Apr 2024 20:12:55 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:55 GMT Message-Id: <202404162012.43GKCtr3038249@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 151ff218eb7a - stable/14 - loader: line line per src file in libi386 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 151ff218eb7a25ecbe2770d3b0b84c1ce83e4e79 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=151ff218eb7a25ecbe2770d3b0b84c1ce83e4e79 commit 151ff218eb7a25ecbe2770d3b0b84c1ce83e4e79 Author: Warner Losh AuthorDate: 2024-02-16 04:02:37 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:24 +0000 loader: line line per src file in libi386 Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43913 (cherry picked from commit 26c8dedef118cebdda4a0e22949ae35bc60c45c9) --- stand/i386/libi386/Makefile | 37 +++++++++++++++++++++++++++++-------- 1 file changed, 29 insertions(+), 8 deletions(-) diff --git a/stand/i386/libi386/Makefile b/stand/i386/libi386/Makefile index fcba20fa26c4..ac12d67e3475 100644 --- a/stand/i386/libi386/Makefile +++ b/stand/i386/libi386/Makefile @@ -1,14 +1,35 @@ .include -LIB= i386 - -SRCS= bio.c biosacpi.c biosdisk.c biosmem.c biospnp.c \ - biospci.c biossmap.c bootinfo.c bootinfo32.c bootinfo64.c \ - comconsole.c devicename.c elf32_freebsd.c \ - elf64_freebsd.c multiboot.c multiboot_tramp.S relocater_tramp.S \ - i386_copy.c i386_module.c nullconsole.c pxe.c pxetramp.S \ - time.c vidconsole.c vbe.c amd64_tramp.S spinconsole.c +LIB= i386 + +SRCS+= amd64_tramp.S +SRCS+= bio.c +SRCS+= biosacpi.c +SRCS+= biosdisk.c +SRCS+= biosmem.c +SRCS+= biospci.c +SRCS+= biospnp.c +SRCS+= biossmap.c +SRCS+= bootinfo.c +SRCS+= bootinfo32.c +SRCS+= bootinfo64.c +SRCS+= comconsole.c +SRCS+= devicename.c +SRCS+= elf32_freebsd.c +SRCS+= elf64_freebsd.c +SRCS+= i386_copy.c +SRCS+= i386_module.c +SRCS+= multiboot.c +SRCS+= multiboot_tramp.S +SRCS+= nullconsole.c +SRCS+= pxe.c +SRCS+= pxetramp.S +SRCS+= relocater_tramp.S +SRCS+= spinconsole.c +SRCS+= time.c +SRCS+= vbe.c +SRCS+= vidconsole.c .PATH: ${SYSDIR}/teken SRCS+= teken.c From nobody Tue Apr 16 20:12:58 2024 X-Original-To: dev-commits-src-branches@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 4VJwFk3hX1z5H0W7; Tue, 16 Apr 2024 20:12:58 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFk0v15z4tLX; Tue, 16 Apr 2024 20:12:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298378; 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=B3IJJErGMvQ/ts0UGcIDtlHijkTxJQKpPggFuLF4pME=; b=Xpcf/8FoCqYwhlN6vW0j0f3IbGKYW21ICH7riawCbbNM0mEcAcZ8jeKTSZ51SYWKR6BT9j 95YIrooCD8j1/PohJa4QBov7jtr4rocUJMVrmdfGB5RCxef3IQ+5NyD0ZIhw8zadBu99W/ koyhEoPYTUbHBhwPJIFmL2RQd/eQmEul8Pw85IfcAlpOlYhDZehOuQ97nbwRqoGjniBSr4 opZ8m+EYIgDEFT92wL1wXArLseBeQMVbYomrozT9qh/57/ovxl0I8sVUU7pzK7ZpDKGSpF StTbxREHIh7b+cWrERtR/J7o/bDB7Ms0nv/efbaiV0jnQuB/ubUHM7Q+cqlfkQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298378; a=rsa-sha256; cv=none; b=YkeMYOUe44Bcqhr+e4Wd0qWuqpZCBOcO0VRuPN16j3Ff3IV4P+9ITaHMnPMqBPT/90s4oP Z4ibQs7Ylp/xVwm1bOF7khlzpm251wBoy3T4OqhCuwLioHTkhTFar7RZfDrLHZuUoagDok ubMb+sKMFOaQI/19/uQomH6QVOmoUfwPiKghm9lk/KYVzjmxPuFeqFLLCkXuMPBv8MeAeS 4C9FPxL/XhdLqR6EJgQRVRVb0t7IqGd/F1RlkLIr/MyOGWBbgBc6rhI/Plf+26+SA5anV1 qV+WN5DmO1AwT8jnFgSLRUr/LmUNHfr03E21+WBwlWMmcenYsv4tSg97kddS9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298378; 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=B3IJJErGMvQ/ts0UGcIDtlHijkTxJQKpPggFuLF4pME=; b=pwV/73eK+9m/tgaX8M5FG3wlyoraW7NsojdjVq04Fw6LEJYgBjzbdK4mWao/R6X4A/cPcR Fd4jRzn/0Y/oAVu/9JUTlKMOR5Z4IPRxpza8FgBxZydN8FnbmgnwazRh39C11nWX+nW503 vzBPojlzr0ym0zLPDX2YBwGNK7cV1ekZ63UVGHoVysKA9u+1yXHtuSLkXRLTFtkV5IoqdM 6kMixbYQpjWssYx1P3c3IWJgUWtTy9HMqaQJZSHMrOcZVKdpBULBnwO3IgYU6xB5DDYLDK tJlpfRVqx3mpHtXMKzfazYt19wcssaXl9ypLJhwaVjCEBAhWLfyyQUVykEWV3A== 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 4VJwFk0WKJzwwD; Tue, 16 Apr 2024 20:12:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCwGv038366; Tue, 16 Apr 2024 20:12:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCwXM038363; Tue, 16 Apr 2024 20:12:58 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:58 GMT Message-Id: <202404162012.43GKCwXM038363@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: fcfd7396ae8a - stable/14 - loader: Add new option WITH_LOADER_BIOS_TEXTONLY List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: fcfd7396ae8a93ecfe880bbfa6bc3461b98eb6d6 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=fcfd7396ae8a93ecfe880bbfa6bc3461b98eb6d6 commit fcfd7396ae8a93ecfe880bbfa6bc3461b98eb6d6 Author: Warner Losh AuthorDate: 2024-02-18 06:14:50 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: Add new option WITH_LOADER_BIOS_TEXTONLY This option will omit all the graphics support, the teken terminal library, video mode support, etc and support a simple, basic, text-only video console for the x86 BIOS boot loader. It uses the FreeBSD 12 version of vidconsole.c. It defaults to NO. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43912 (cherry picked from commit 63e9c976640d05ef65842eaf3d54de9a8d48cbdc) --- share/man/man5/src.conf.5 | 6 +++++- share/mk/src.opts.mk | 1 + tools/build/options/WITH_LOADER_BIOS_TEXTONLY | 3 +++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index eec250bcbca2..4bb38fe61a77 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,5 +1,5 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. -.Dd April 11, 2024 +.Dd April 15, 2024 .Dt SRC.CONF 5 .Os .Sh NAME @@ -999,6 +999,10 @@ Do not build LLVM target support for X86. The .Va LLVM_TARGET_ALL option should be used rather than this in most cases. +.It Va WITH_LOADER_BIOS_TEXTONLY +Use the old, FreeBSD 12 vidconsole.c. +This only supports text mode without teken, without any graphics, font or video mode support. +This setting only affects the i386 and amd64 BIOS boot loader. .It Va WITH_LOADER_EFI_SECUREBOOT Enable building .Xr loader 8 diff --git a/share/mk/src.opts.mk b/share/mk/src.opts.mk index a8b33fcdc6d6..788c6a9b956f 100644 --- a/share/mk/src.opts.mk +++ b/share/mk/src.opts.mk @@ -204,6 +204,7 @@ __DEFAULT_NO_OPTIONS = \ DTRACE_TESTS \ EXPERIMENTAL \ HESIOD \ + LOADER_BIOS_TEXTONLY \ LOADER_VERBOSE \ LOADER_VERIEXEC_PASS_MANIFEST \ LLVM_ASSERTIONS \ diff --git a/tools/build/options/WITH_LOADER_BIOS_TEXTONLY b/tools/build/options/WITH_LOADER_BIOS_TEXTONLY new file mode 100644 index 000000000000..08804c19c691 --- /dev/null +++ b/tools/build/options/WITH_LOADER_BIOS_TEXTONLY @@ -0,0 +1,3 @@ +Use the old, FreeBSD 12 vidconsole.c. +This only supports text mode without teken, without any graphics, font or video mode support. +This setting only affects the i386 and amd64 BIOS boot loader. From nobody Tue Apr 16 20:12:56 2024 X-Original-To: dev-commits-src-branches@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 4VJwFj2dLdz5H0h0; Tue, 16 Apr 2024 20:12:57 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFj0lNtz4tTC; Tue, 16 Apr 2024 20:12:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298377; 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=T4FG1WN0z1AD2Y1oYoJSfVxmIiqIrKAaTUDAbX2XeLw=; b=alD7j19XWQlMpBWf2kE6WTck7HJ4bl9/zJs0d3qzB6XMInJ6Pk5GhIig8WhTo+7kl9slEx DW1NK3NW2qToD6R0cfvm3c72qqv4Q59r7eCOguGFFVAM5bG4pwhS92XYYs+3M1Ad2ipnoI HgEKpsN5AOn5I2xXxZBZnO8pIUfNRCi3hj43p/CJbUAYqfwmkDClCqxU1EbYu0gEVVG79b dwCnsWm9k+8HrOzLuUl/ebRWghB4YEV3B1lpm77JMfldAmk0PJ8WybVhzdqcmOcCkayhff ObZwr4rg5UM3WdpDx8TnhZE/HLCZmJFZVYrKDyCAv4oAXfo79hQZfPYtfPumvQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298377; a=rsa-sha256; cv=none; b=szTeXl9viWjoYoz3gPOJKPQZ0cObH5O+wqusv1g35rvqOaMEekHAo1HHm1PELx6m7w0ArY bWB4jzSLsVcOgblhBSncaViOGn6SeHIztMHTKcTxkBJCZ4WppBX8d/KG9aHdsvI8Z1VVq2 hczGUtnOMMUXenJ4ZPuzMocba96kTdETgsqj6fecOu2taoHdyBvMC9vypItzYxMXV/TO+G 1sujZMWzIi3Xpe4YUc8sbn+Y921s67FIj51TFHa87Sz3V7IPu4OAqBlyPRa3/EQHfLHx3w 5xWvxTK0CMOAeSm0gFcVDLodWW2TxRsSsqC4iZMYHwE/OchSVcoQgmZ3WRsIjQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298377; 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=T4FG1WN0z1AD2Y1oYoJSfVxmIiqIrKAaTUDAbX2XeLw=; b=Cyg21RVtXsPwmPWwN3dX3wammJ2AMRby2MRjhLUO5d4FdCVhmn3UpQhxAUKGnf3jFjDydI RPHF7A1R7QCrucfVdSRX2IefiqnOPE9Gcy+FWwwY49TW0i9CabmFtP03kOS97sH8MIHaHn HxRbK1TTp/jkU+W7OPpXqM8n5xSiT/02cv+FCnZjukLPfmI04BSyu5vDyImVaF3QpZB1Wv gmof9ixwTPCR1Z3XyY5mxKP8y4i31SwcNRTY2N5RlB1GCdy3i/NSSCIKlpKAhaGmlEtgRF 7iH/XLANHYSa9MjZcFIMbOPOMFjhpWDhXwaLznAhU1MgUIhTN6GlnS8FcRbGOQ== 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 4VJwFh6kh4zwwC; Tue, 16 Apr 2024 20:12:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCuOx038322; Tue, 16 Apr 2024 20:12:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCu74038319; Tue, 16 Apr 2024 20:12:56 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:56 GMT Message-Id: <202404162012.43GKCu74038319@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 795edc4ac23e - stable/14 - loader: Bump the limit to 560,000 bytes for BIOS loader List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 795edc4ac23e050c57a5ee0aab70d6bea62dc49a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=795edc4ac23e050c57a5ee0aab70d6bea62dc49a commit 795edc4ac23e050c57a5ee0aab70d6bea62dc49a Author: Warner Losh AuthorDate: 2024-02-16 04:12:52 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: Bump the limit to 560,000 bytes for BIOS loader Further experience suggests we do not need as much margin. This was mistakenly bumped to 570,000 in a prior commit, so this undoes that. Sponsored by: Netflix (cherry picked from commit e5d1a21e500142c02fd44ce2f7822f2815a74fcc) --- stand/i386/loader/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/stand/i386/loader/Makefile b/stand/i386/loader/Makefile index 57191b3c8f78..525561b7c4d1 100644 --- a/stand/i386/loader/Makefile +++ b/stand/i386/loader/Makefile @@ -1,4 +1,3 @@ - HAVE_ZFS= ${MK_LOADER_ZFS} LOADER_NET_SUPPORT?= yes @@ -23,7 +22,7 @@ VERSION_FILE= ${.CURDIR}/../loader/version # non-random survey suggests that 20k-25k is a good value for 'most' machines. # We also need to subtract maximum stack usage (20-25k). # -# So 640k - 40k - 25k - 25k = 550k = 563,200 bytes, but use 550,000 below for +# So 640k - 40k - 25k - 25k = 550k = 563,200 bytes, but use 560,000 below for # some extra buffer for more complex setups and/or wider BIOS lomem variation. # # Some systems use more stack or have BIOS reserve more RAM (or both), and will @@ -33,7 +32,7 @@ VERSION_FILE= ${.CURDIR}/../loader/version # # will tell you how many kiB of lomem are available. # -LOADERSIZE?= 570000 # Largest known safe size for loader.bin +LOADERSIZE?= 560000 # Largest known safe size for loader.bin .PATH: ${BOOTSRC}/i386/loader From nobody Tue Apr 16 20:12:59 2024 X-Original-To: dev-commits-src-branches@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 4VJwFl3vpyz5H0kV; Tue, 16 Apr 2024 20:12:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFl2cGHz4tRH; Tue, 16 Apr 2024 20:12:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298379; 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=Yz3cET/O66fcO7E2uTI46J8COMNDZDOhVQzTK9Lid24=; b=T0WHr1SflryllsejssuUPClczxzg7vm61rTSZ0QbUF/HRrpZAxrqN0Kf3PrRN7dFua/z94 ujdvd+4A/RYTWsTE2vWsheuEhAiKhUYhvkob0ftoG8U9awbxDzOB9ZFRJ73J7Y2IGBEgcu vg1dxNOscS6Q2TS+n3vTUXYnWTRiF9doXOmQCJdc0XXgRY3q1UAY9hUj9Dk5o3uydKgMUD mrWmApq/pvM4h6YYG34XoiV8xrcOBbf9RXyBncbSLKtjnzFRReJ9TfnAZsiAsHEQrsiAVK vbEN3++ML0tximyvFgDG1n59+huqZkVimVtaEWkGG4VajtBR4DdpePmMZ6Rpsw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298379; a=rsa-sha256; cv=none; b=gpqi3EdSVllw697KckNF3WYtME+E1O+bAFKYy6jk13CdwRRzDN4bt4PR02OcqB9UVtNKTN 3gQ3XizagmCUaRwHiD13ShpreGtLcF20J13tqNjkcUTuWs0J2OSRXEXs4vsfS5rmPgwjk0 3IRZN68r8zP6CAkeGSbQna4nHAHUcTP6jmu4k7MPCF1qBbTbqPiLbksWbmeLhdlotQNvlC ouxeGx3mmNN4mBAdAw2VgMHNO/FZeP6/0wxRtvpRaKhu8/Xf1mfSqJLxZsRZfngxsFFFOu pKZxZp6uyKYbDo1J9Q/BKfdhCVnR4YzyhK9ujwrGJQDqPKT4zm7xpluiEzHieQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298379; 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=Yz3cET/O66fcO7E2uTI46J8COMNDZDOhVQzTK9Lid24=; b=Jj4PhO7SQOf9/wbzrQvVFup3trr33SqV7gBw7GcMASMy9YPjgnGSjD7vS+T7kycWk7xr+3 A7xg7s1TL01hocoBo/OZOxlrgaqgbncG0XJ0wR31lByg+gqZDMIpciJtYaggM+RCFdGRj5 wAYpcKkXdLFL8KY4jLTkfwPxK7UK1yhyFG5lTl1P2as/04qHUB8Wn7ay+vDmVIydzaNjK8 u7WxFkCt5FZRKdXff2KBtjn9+QYBjRUlTE2nh9Krue9EOkCepTBTo+kuNPLH9eb1aRGtGw TWm6Lsi5EgsQXaSvwJ6nEkC5FktsIruAq5QwbHiGyKaMsm1xbkzpNe7I83Kbbg== 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 4VJwFl1t2tzxY3; Tue, 16 Apr 2024 20:12:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKCxBW038414; Tue, 16 Apr 2024 20:12:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKCxRU038411; Tue, 16 Apr 2024 20:12:59 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:12:59 GMT Message-Id: <202404162012.43GKCxRU038411@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 7816528ccf9c - stable/14 - loader: bring back old text-only video console List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7816528ccf9ceb2c79efa99231dad9c3de0e36d3 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=7816528ccf9ceb2c79efa99231dad9c3de0e36d3 commit 7816528ccf9ceb2c79efa99231dad9c3de0e36d3 Author: Warner Losh AuthorDate: 2024-02-18 06:14:44 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: bring back old text-only video console Bring back vidconsole.c as textvidc.c from 2a0e2c88db20. This console does no graphics stuff at all, supports no fancy logos, has known bugs in the terminal emulation, etc. However, it is small. It will be a build-time option to select between the two. The BIOS loader is running out of space when too many options are selected, so this allows people to select the smaller one to spend the space elsewhere. This is only the verbatim copy of the old vidconsole.c. It's not yet connected to the build. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43911 (cherry picked from commit 1954e5c1dc583df602e6d7058f59eac71b4be6b2) --- stand/i386/libi386/textvidc.c | 645 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 645 insertions(+) diff --git a/stand/i386/libi386/textvidc.c b/stand/i386/libi386/textvidc.c new file mode 100644 index 000000000000..f3ab6f4b98cf --- /dev/null +++ b/stand/i386/libi386/textvidc.c @@ -0,0 +1,645 @@ +/*- + * Copyright (c) 1998 Michael Smith (msmith@freebsd.org) + * Copyright (c) 1997 Kazutaka YOKOTA (yokota@zodiac.mech.utsunomiya-u.ac.jp) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * Id: probe_keyboard.c,v 1.13 1997/06/09 05:10:55 bde Exp + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include "libi386.h" + +#if KEYBOARD_PROBE +#include + +static int probe_keyboard(void); +#endif +static void vidc_probe(struct console *cp); +static int vidc_init(int arg); +static void vidc_putchar(int c); +static int vidc_getchar(void); +static int vidc_ischar(void); + +static int vidc_started; + +void get_pos(int *x, int *y); + +#ifdef TERM_EMU +#define MAXARGS 8 +#define DEFAULT_FGCOLOR 7 +#define DEFAULT_BGCOLOR 0 + +void end_term(void); +void bail_out(int c); +void vidc_term_emu(int c); +void curs_move(int *_x, int *_y, int x, int y); +void write_char(int c, int fg, int bg); +void scroll_up(int rows, int fg, int bg); +void CD(void); +void CM(void); +void HO(void); + +static int args[MAXARGS], argc; +static int fg_c, bg_c, curx, cury; +static int esc; +#endif + + +struct console textvidc = { + "vidconsole", + "internal video/keyboard", + 0, + vidc_probe, + vidc_init, + vidc_putchar, + vidc_getchar, + vidc_ischar +}; + +static void +vidc_probe(struct console *cp) +{ + /* look for a keyboard */ +#if KEYBOARD_PROBE + if (probe_keyboard()) +#endif + { + cp->c_flags |= C_PRESENTIN; + } + + /* XXX for now, always assume we can do BIOS screen output */ + cp->c_flags |= C_PRESENTOUT; +} + +static int +vidc_init(int arg) +{ + int i; + + if (vidc_started && arg == 0) + return (0); + vidc_started = 1; +#ifdef TERM_EMU + /* Init terminal emulator */ + end_term(); + get_pos(&curx, &cury); + curs_move(&curx, &cury, curx, cury); + fg_c = DEFAULT_FGCOLOR; + bg_c = DEFAULT_BGCOLOR; +#endif + for (i = 0; i < 10 && vidc_ischar(); i++) + (void)vidc_getchar(); + return (0); /* XXX reinit? */ +} + +static void +vidc_biosputchar(int c) +{ + + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0xe00 | (c & 0xff); + v86.ebx = 0x7; + v86int(); +} + +static void +vidc_rawputchar(int c) +{ + int i; + + if (c == '\t') { + int n; +#ifndef TERM_EMU + int curx, cury; + + get_pos(&curx, &cury); +#endif + + n = 8 - ((curx + 8) % 8); + for (i = 0; i < n; i++) + vidc_rawputchar(' '); + } else { +#ifndef TERM_EMU + vidc_biosputchar(c); +#else + /* Emulate AH=0eh (teletype output) */ + switch(c) { + case '\a': + vidc_biosputchar(c); + return; + case '\r': + curx = 0; + curs_move(&curx, &cury, curx, cury); + return; + case '\n': + cury++; + if (cury > 24) { + scroll_up(1, fg_c, bg_c); + cury--; + } else { + curs_move(&curx, &cury, curx, cury); + } + return; + case '\b': + if (curx > 0) { + curx--; + curs_move(&curx, &cury, curx, cury); + /* write_char(' ', fg_c, bg_c); XXX destructive(!) */ + return; + } + return; + default: + write_char(c, fg_c, bg_c); + curx++; + if (curx > 79) { + curx = 0; + cury++; + } + if (cury > 24) { + curx = 0; + scroll_up(1, fg_c, bg_c); + cury--; + } + } + curs_move(&curx, &cury, curx, cury); +#endif + } +} + +/* Get cursor position on the screen. Result is in edx. Sets + * curx and cury appropriately. + */ +void +get_pos(int *x, int *y) +{ + + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0300; + v86.ebx = 0x0; + v86int(); + *x = v86.edx & 0x00ff; + *y = (v86.edx & 0xff00) >> 8; +} + +#ifdef TERM_EMU + +/* Move cursor to x rows and y cols (0-based). */ +void +curs_move(int *_x, int *_y, int x, int y) +{ + + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0200; + v86.ebx = 0x0; + v86.edx = ((0x00ff & y) << 8) + (0x00ff & x); + v86int(); + *_x = x; + *_y = y; + /* If there is ctrl char at this position, cursor would be invisible. + * Make it a space instead. + */ + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0800; + v86.ebx = 0x0; + v86int(); +#define isvisible(c) (((c) >= 32) && ((c) < 255)) + if (!isvisible(v86.eax & 0x00ff)) { + write_char(' ', fg_c, bg_c); + } +} + +/* Scroll up the whole window by a number of rows. If rows==0, + * clear the window. fg and bg are attributes for the new lines + * inserted in the window. + */ +void +scroll_up(int rows, int fgcol, int bgcol) +{ + + if (rows == 0) + rows = 25; + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0600 + (0x00ff & rows); + v86.ebx = (bgcol << 12) + (fgcol << 8); + v86.ecx = 0x0; + v86.edx = 0x184f; + v86int(); +} + +/* Write character and attribute at cursor position. */ +void +write_char(int c, int fgcol, int bgcol) +{ + + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0900 + (0x00ff & c); + v86.ebx = (bgcol << 4) + fgcol; + v86.ecx = 0x1; + v86int(); +} + +/**************************************************************/ +/* + * Screen manipulation functions. They use accumulated data in + * args[] and argc variables. + * + */ + +/* Clear display from current position to end of screen */ +void +CD(void) +{ + + get_pos(&curx, &cury); + if (curx > 0) { + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0600; + v86.ebx = (bg_c << 4) + fg_c; + v86.ecx = (cury << 8) + curx; + v86.edx = (cury << 8) + 79; + v86int(); + if (++cury > 24) { + end_term(); + return; + } + } + v86.ctl = 0; + v86.addr = 0x10; + v86.eax = 0x0600; + v86.ebx = (bg_c << 4) + fg_c; + v86.ecx = (cury << 8) + 0; + v86.edx = (24 << 8) + 79; + v86int(); + end_term(); +} + +/* Absolute cursor move to args[0] rows and args[1] columns + * (the coordinates are 1-based). + */ +void +CM(void) +{ + + if (args[0] > 0) + args[0]--; + if (args[1] > 0) + args[1]--; + curs_move(&curx, &cury, args[1], args[0]); + end_term(); +} + +/* Home cursor (left top corner) */ +void +HO(void) +{ + + argc = 1; + args[0] = args[1] = 1; + CM(); +} + +/* Clear internal state of the terminal emulation code */ +void +end_term(void) +{ + + esc = 0; + argc = -1; +} + +/* Gracefully exit ESC-sequence processing in case of misunderstanding */ +void +bail_out(int c) +{ + char buf[16], *ch; + int i; + + if (esc) { + vidc_rawputchar('\033'); + if (esc != '\033') + vidc_rawputchar(esc); + for (i = 0; i <= argc; ++i) { + sprintf(buf, "%d", args[i]); + ch = buf; + while (*ch) + vidc_rawputchar(*ch++); + } + } + vidc_rawputchar(c); + end_term(); +} + +static void +get_arg(int c) +{ + + if (argc < 0) + argc = 0; + args[argc] *= 10; + args[argc] += c - '0'; +} + +/* Emulate basic capabilities of cons25 terminal */ +void +vidc_term_emu(int c) +{ + static int ansi_col[] = { + 0, 4, 2, 6, 1, 5, 3, 7, + }; + int t; + int i; + + switch (esc) { + case 0: + switch (c) { + case '\033': + esc = c; + break; + default: + vidc_rawputchar(c); + break; + } + break; + + case '\033': + switch (c) { + case '[': + esc = c; + args[0] = 0; + argc = -1; + break; + default: + bail_out(c); + break; + } + break; + + case '[': + switch (c) { + case ';': + if (argc < 0) /* XXX */ + argc = 0; + else if (argc + 1 >= MAXARGS) + bail_out(c); + else + args[++argc] = 0; + break; + case 'H': + if (argc < 0) + HO(); + else if (argc == 1) + CM(); + else + bail_out(c); + break; + case 'J': + if (argc < 0) + CD(); + else + bail_out(c); + break; + case 'm': + if (argc < 0) { + fg_c = DEFAULT_FGCOLOR; + bg_c = DEFAULT_BGCOLOR; + } + for (i = 0; i <= argc; ++i) { + switch (args[i]) { + case 0: /* back to normal */ + fg_c = DEFAULT_FGCOLOR; + bg_c = DEFAULT_BGCOLOR; + break; + case 1: /* bold */ + fg_c |= 0x8; + break; + case 4: /* underline */ + case 5: /* blink */ + bg_c |= 0x8; + break; + case 7: /* reverse */ + t = fg_c; + fg_c = bg_c; + bg_c = t; + break; + case 22: /* normal intensity */ + fg_c &= ~0x8; + break; + case 24: /* not underline */ + case 25: /* not blinking */ + bg_c &= ~0x8; + break; + case 30: case 31: case 32: case 33: + case 34: case 35: case 36: case 37: + fg_c = ansi_col[args[i] - 30]; + break; + case 39: /* normal */ + fg_c = DEFAULT_FGCOLOR; + break; + case 40: case 41: case 42: case 43: + case 44: case 45: case 46: case 47: + bg_c = ansi_col[args[i] - 40]; + break; + case 49: /* normal */ + bg_c = DEFAULT_BGCOLOR; + break; + } + } + end_term(); + break; + default: + if (isdigit(c)) + get_arg(c); + else + bail_out(c); + break; + } + break; + + default: + bail_out(c); + break; + } +} +#endif + +static void +vidc_putchar(int c) +{ +#ifdef TERM_EMU + vidc_term_emu(c); +#else + vidc_rawputchar(c); +#endif +} + +static int +vidc_getchar(void) +{ + + if (vidc_ischar()) { + v86.ctl = 0; + v86.addr = 0x16; + v86.eax = 0x0; + v86int(); + return (v86.eax & 0xff); + } else { + return (-1); + } +} + +static int +vidc_ischar(void) +{ + + v86.ctl = V86_FLAGS; + v86.addr = 0x16; + v86.eax = 0x100; + v86int(); + return (!V86_ZR(v86.efl)); +} + +#if KEYBOARD_PROBE + +#define PROBE_MAXRETRY 5 +#define PROBE_MAXWAIT 400 +#define IO_DUMMY 0x84 +#define IO_KBD 0x060 /* 8042 Keyboard */ + +/* selected defines from kbdio.h */ +#define KBD_STATUS_PORT 4 /* status port, read */ +#define KBD_DATA_PORT 0 /* data port, read/write + * also used as keyboard command + * and mouse command port + */ +#define KBDC_ECHO 0x00ee +#define KBDS_ANY_BUFFER_FULL 0x0001 +#define KBDS_INPUT_BUFFER_FULL 0x0002 +#define KBD_ECHO 0x00ee + +/* 7 microsec delay necessary for some keyboard controllers */ +static void +delay7(void) +{ + /* + * I know this is broken, but no timer is available yet at this stage... + * See also comments in `delay1ms()'. + */ + inb(IO_DUMMY); inb(IO_DUMMY); + inb(IO_DUMMY); inb(IO_DUMMY); + inb(IO_DUMMY); inb(IO_DUMMY); +} + +/* + * This routine uses an inb to an unused port, the time to execute that + * inb is approximately 1.25uS. This value is pretty constant across + * all CPU's and all buses, with the exception of some PCI implentations + * that do not forward this I/O address to the ISA bus as they know it + * is not a valid ISA bus address, those machines execute this inb in + * 60 nS :-(. + * + */ +static void +delay1ms(void) +{ + int i = 800; + while (--i >= 0) + (void)inb(0x84); +} + +/* + * We use the presence/absence of a keyboard to determine whether the internal + * console can be used for input. + * + * Perform a simple test on the keyboard; issue the ECHO command and see + * if the right answer is returned. We don't do anything as drastic as + * full keyboard reset; it will be too troublesome and take too much time. + */ +static int +probe_keyboard(void) +{ + int retry = PROBE_MAXRETRY; + int wait; + int i; + + while (--retry >= 0) { + /* flush any noise */ + while (inb(IO_KBD + KBD_STATUS_PORT) & KBDS_ANY_BUFFER_FULL) { + delay7(); + inb(IO_KBD + KBD_DATA_PORT); + delay1ms(); + } + + /* wait until the controller can accept a command */ + for (wait = PROBE_MAXWAIT; wait > 0; --wait) { + if (((i = inb(IO_KBD + KBD_STATUS_PORT)) + & (KBDS_INPUT_BUFFER_FULL | KBDS_ANY_BUFFER_FULL)) == 0) + break; + if (i & KBDS_ANY_BUFFER_FULL) { + delay7(); + inb(IO_KBD + KBD_DATA_PORT); + } + delay1ms(); + } + if (wait <= 0) + continue; + + /* send the ECHO command */ + outb(IO_KBD + KBD_DATA_PORT, KBDC_ECHO); + + /* wait for a response */ + for (wait = PROBE_MAXWAIT; wait > 0; --wait) { + if (inb(IO_KBD + KBD_STATUS_PORT) & KBDS_ANY_BUFFER_FULL) + break; + delay1ms(); + } + if (wait <= 0) + continue; + + delay7(); + i = inb(IO_KBD + KBD_DATA_PORT); +#ifdef PROBE_KBD_BEBUG + printf("probe_keyboard: got 0x%x.\n", i); +#endif + if (i == KBD_ECHO) { + /* got the right answer */ + return (1); + } + } + + return (0); +} +#endif /* KEYBOARD_PROBE */ From nobody Tue Apr 16 20:13:00 2024 X-Original-To: dev-commits-src-branches@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 4VJwFm50fgz5H0h6; Tue, 16 Apr 2024 20:13:00 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFm3Fvdz4tXB; Tue, 16 Apr 2024 20:13:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298380; 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=0Q244UZNz+2qXwHUkoa5riHE4TCr5zQy1/qYl4IsJEc=; b=AWHtdZc7yLc+OasMJ11PYKg3ZkYR0S0BrJMWYAPla4ulTfj8SiL507N1l31596xAnPF+V1 OvHJDVuN8xTDQbEoDzc7XDxB0TTRYsnqzPA364BGRsAGfEbeTfHUMdx+k2trQR/vq1S4Mk p8T0qNK8lKPrIIZ+dJStpSkKeNODcixSLS/uRsBLkysIgbCfwblVxyjliOqNUsprXJWQT8 vEeI1wOe1FGLdLvrjAu/NjrCA+tfS5HzIhioY3HTeahARJvdiSTUQJ9+hjRwQaXhFCykcH 2VRPEghz6qQXkDFjyEH4WfXWzg6oQgWSrNbZU3vGjaE2vvnlRzKsHXDZWRIliw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298380; a=rsa-sha256; cv=none; b=r936dAhEqMixhbexpCJY25M0CZiR1Yxs8HndABcQroh4xfhqeOOu2LBVkFMCVlVH+C3XQG 9LQpdAz7Mn9aqzAs0xZ8UoENlBasQqkxFQd33wy/RISvh6vpRn6zUijcyfr7Zbmg7TeHsm fz25bmATpOY2u+ul6TfHO+uf8rsNua07T0efQ/FQ4hfT9Wk3TTzEx3YshZDHB0Xr7UQv1h bAnYezFhxF+8vGJCA5bXOAcwjofZDu8kFrr5664RtMqdVP/kDFOjMgQeHQqs0NO+tkUj34 3rU+M0jsu5gYOZAtbfGLDoFIaIWNNRhQS3Zj3A9zjG8Yfvr5DgANVJH7lYz9hQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298380; 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=0Q244UZNz+2qXwHUkoa5riHE4TCr5zQy1/qYl4IsJEc=; b=gsQmEjn4dhT4u+MnP3F9BsCtydYwANCSzuFoe4k5CJjgTD7F5VW3+QROtfgss9QYwccSi+ NtDvCGfRHreiRUMCqz+YayJFk6jNW5M2o/R8sXbPlVvolZ4CgOEVoZN9zIVmqAuZUA7YiO sSreVblfITntZo951uRQrZRpu2bcN3rWnILVs6kD9Oq3palUHplOD1nKXmrv0mBwhRzGy2 VAeR/xkZG6BF29eCoBTTcS6f+aBsodFGiuXJbUgK/jhR0QmlBLMVu+xJL8tUo/rbz4lzDs qS5lf/l/gpHLxpFbIycuGbn5Q4rZ9LexC58hXCyzhyVhwxNydCDkpJiLSbceKg== 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 4VJwFm2pf6zxY4; Tue, 16 Apr 2024 20:13:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD0Lx038463; Tue, 16 Apr 2024 20:13:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD0Xi038460; Tue, 16 Apr 2024 20:13:00 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:00 GMT Message-Id: <202404162013.43GKD0Xi038460@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 82d4e9b248b6 - stable/14 - loader: Add textvidc to build List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 82d4e9b248b608f72838e6266b17bc99a459e5d7 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=82d4e9b248b608f72838e6266b17bc99a459e5d7 commit 82d4e9b248b608f72838e6266b17bc99a459e5d7 Author: Warner Losh AuthorDate: 2024-02-18 06:14:56 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: Add textvidc to build Add textvidc to the build. And use -DTERM_EMU to build it. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43915 (cherry picked from commit e36afddf11eb9f83ee867532a32ef2373434d670) --- stand/i386/libi386/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/stand/i386/libi386/Makefile b/stand/i386/libi386/Makefile index ac12d67e3475..8608c369a118 100644 --- a/stand/i386/libi386/Makefile +++ b/stand/i386/libi386/Makefile @@ -28,6 +28,7 @@ SRCS+= pxetramp.S SRCS+= relocater_tramp.S SRCS+= spinconsole.c SRCS+= time.c +SRCS+= textvidc.c SRCS+= vbe.c SRCS+= vidconsole.c @@ -56,6 +57,8 @@ CFLAGS.teken.c+= -I${SRCTOP}/sys/teken CFLAGS.bootinfo.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite CFLAGS.vbe.c+= -I${SRCTOP}/sys/teken -I${SRCTOP}/contrib/pnglite +CFLAGS.textvidc.c+= -DTERM_EMU + CFLAGS+= -I${LDRSRC} -I${BOOTSRC}/i386/common \ -I${SYSDIR}/contrib/dev/acpica/include From nobody Tue Apr 16 20:13:01 2024 X-Original-To: dev-commits-src-branches@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 4VJwFn6w00z5H0kd; Tue, 16 Apr 2024 20:13:01 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFn5HpNz4tQ0; Tue, 16 Apr 2024 20:13:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298381; 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=ornf5vcGgIQRT1NK22e5o10LqKzrbwfph0yCY23rC7I=; b=AFofWZJyn8Qu6VZ4LQdzeDFK19eZb5w03OH9hIjG/YFA/cRFxgSQuf0+xuCQ3OOW8xITwi G6w0F4UbnI1D79/ZNq7G60qxQ+5eXBeRqDKbVJ1yp5GI5aZYSVYS6kR+F3Svvb7Vi/DwEq V4mCvf7dHVFXtENqA7FISijiB13DHE4q14JNcJYYGFlaAlJPHSk113+aY7bUV1X5MVrW3c qzXR0sn23I1ufX2sKq3ixtrKsL5DSW0ddlhkoQeT6XBFXCOaV+pi9LdTUOhIbT1zJ3imJw zRc+y2YZu5z3IK7UmH69P0gL1WbrerOTVKBN0kgBvmhQmwwMeTqhWNd3P/5UXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298381; a=rsa-sha256; cv=none; b=SOJbZRaZlow+AsD92recmPPm2EswMv6hHUfAdjtCvtAZqo7E6pzKLzuryEgwRoK+w2bJLv 7LcIIZVeBWVpGW9hhhFzuo8TpP8TDJKPPMy8ZV83dg+eZN7SDfr9i6tYjOI9a1+mtL3B4/ t+bqfXH7dvgcMWyWK7Rm6II+7C7jndM6Go/jBLb+ojN+O/dI9YdlXz3sGLU/uim/TRKkSV kIZyhVVEH+4BVzN34IuhJOxQn4rC0LNUsC7pkezm+0ehKsBx96tNlx/kqjB16U0Ub63DvY L3VGs3OcXOLuXGo+4BHTnkNax+lT5CvslfcUCRJY+VdzVsPKn8IOJIcqgwlkeA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298381; 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=ornf5vcGgIQRT1NK22e5o10LqKzrbwfph0yCY23rC7I=; b=rZ/oZlMkdy2xRrtqLvizCiB2ctzpbzAirrNtbF98VkDTr1pKwxuo6gafk2hD1hzHSVTI1S kzh9elsDSf/ri+WOYZhANPNJiYEwFRSDtJlYW2YVPUrDfzK4AAlMd49VOikHX9GAYXiQ9n lzuDljy4CHtu+wbM3koOnp+SDkUvLyMDUn3DZvzVFixOUR9/RkmbdeXpm4yOS9emKOlvj3 5kNrOyqPaUnpX09sGEwvKfbt4K8jzVPpP8J0eAnvUgbohhD28olnA6uqYjYJWRyDkRhZp3 GRyxgAWHKkdgot0dmrkqD+PUkPDrcXGWZ/wmA4VDYDzdK7Xql+BDKKP+QDRSAg== 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 4VJwFn3zwGzxWR; Tue, 16 Apr 2024 20:13:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD1MZ038508; Tue, 16 Apr 2024 20:13:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD1m8038505; Tue, 16 Apr 2024 20:13:01 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:01 GMT Message-Id: <202404162013.43GKD1m8038505@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 57ca2848c0aa - stable/14 - loader: Make MK_LOADER_BIOS_TEXTONLY work List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 57ca2848c0aad6dbef66dbac5c0b0f0a6eb798c1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=57ca2848c0aad6dbef66dbac5c0b0f0a6eb798c1 commit 57ca2848c0aad6dbef66dbac5c0b0f0a6eb798c1 Author: Warner Losh AuthorDate: 2024-02-18 06:15:01 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: Make MK_LOADER_BIOS_TEXTONLY work Select between text-only and graphical frame buffer consoles for the BIOS boot loader. Pull one or the other in with #ifdef in conf.c. Add gfx_bios.c for the few routines that are needed for the BIOS support of gfx. These are stubbed out for text-only mode. Move bi_load_vbe_data here since it's only used for the graphical frame buffer. Note: This setup also allows us to build multiple BIOS loaders if we have to, some with text-only and some graphical. We don't do this today. We may be forced to turn this on in the future if ZFS keeps growing. The size savings is 41k, which helps a lot with some of our users that want to enable more options in the BIOS boot loader than are normally safe to do, and they don't need graphics. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D43917 (cherry picked from commit bbfc01c2d29c462a95346f7916a692de396438e6) --- stand/i386/libi386/bootinfo.c | 19 ------------ stand/i386/loader/Makefile | 16 +++++++++- stand/i386/loader/conf.c | 5 ++++ stand/i386/loader/gfx_bios.c | 68 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 88 insertions(+), 20 deletions(-) diff --git a/stand/i386/libi386/bootinfo.c b/stand/i386/libi386/bootinfo.c index cc9a42164ed3..4f652632b755 100644 --- a/stand/i386/libi386/bootinfo.c +++ b/stand/i386/libi386/bootinfo.c @@ -36,25 +36,6 @@ #include "vbe.h" #include "btxv86.h" -void -bi_load_vbe_data(struct preloaded_file *kfp) -{ - if (!kfp->f_tg_kernel_support) { - /* - * Loaded kernel does not have vt/vbe backend, - * switch console to text mode. - */ - if (vbe_available()) - bios_set_text_mode(VGA_TEXT_MODE); - return; - } - - if (vbe_available()) { - file_addmetadata(kfp, MODINFOMD_VBE_FB, - sizeof(gfx_state.tg_fb), &gfx_state.tg_fb); - } -} - int bi_getboothowto(char *kargs) { diff --git a/stand/i386/loader/Makefile b/stand/i386/loader/Makefile index 525561b7c4d1..ab446d67225b 100644 --- a/stand/i386/loader/Makefile +++ b/stand/i386/loader/Makefile @@ -37,13 +37,27 @@ LOADERSIZE?= 560000 # Largest known safe size for loader.bin .PATH: ${BOOTSRC}/i386/loader # architecture-specific loader code -SRCS= main.c conf.c vers.c chain.c gfx_fb.c 8x16.c +SRCS+= chain.c +SRCS+= conf.c +SRCS+= gfx_bios.c +SRCS+= main.c +SRCS+= vers.c + +.if ${MK_LOADER_BIOS_TEXTONLY} == "no" +SRCS+= gfx_fb.c +SRCS+= 8x16.c CFLAGS.gfx_fb.c += -I${.CURDIR}/../libi386 CFLAGS.gfx_fb.c += -I$(SRCTOP)/sys/teken CFLAGS.gfx_fb.c += -I${SRCTOP}/sys/cddl/contrib/opensolaris/common/lz4 CFLAGS.gfx_fb.c += -I${SRCTOP}/contrib/pnglite CFLAGS.gfx_fb.c += -DHAVE_MEMCPY -I${SRCTOP}/sys/contrib/zlib +CFLAGS.gfx_bios.c += -I$(SRCTOP)/sys/teken +CFLAGS.gfx_bios.c += -I${SRCTOP}/contrib/pnglite +.else +CFLAGS.gfx_bios.c += -DBIOS_TEXT_ONLY +CFLAGS.conf.c += -DBIOS_TEXT_ONLY +.endif # Include bcache code. HAVE_BCACHE= yes diff --git a/stand/i386/loader/conf.c b/stand/i386/loader/conf.c index 329bcd577fbe..b4e9f401ded7 100644 --- a/stand/i386/loader/conf.c +++ b/stand/i386/loader/conf.c @@ -128,13 +128,18 @@ struct file_format *file_formats[] = { * We don't prototype these in libi386.h because they require * data structures from bootstrap.h as well. */ +extern struct console textvidc; extern struct console vidconsole; extern struct console comconsole; extern struct console nullconsole; extern struct console spinconsole; struct console *consoles[] = { +#ifdef BIOS_TEXT_ONLY + &textvidc, +#else &vidconsole, +#endif &comconsole, &nullconsole, &spinconsole, diff --git a/stand/i386/loader/gfx_bios.c b/stand/i386/loader/gfx_bios.c new file mode 100644 index 000000000000..a0b08a7cbcde --- /dev/null +++ b/stand/i386/loader/gfx_bios.c @@ -0,0 +1,68 @@ +/* + * Copyright (c) 2024 Netflix, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +/* + * This file provides all the gfx glue, or stubs, so that we can build, if we + * want, two versions of the bios loader: one with graphics support and one + * without. This allows us to keep the calls in other places, like libraries + * that are tricky to compile twice. It also reduces the number of ifdefs we + * need to support the old text-only video console. This could also be two + * separate files, but it is short and having it all here helps to constrain + * dependency creap somewhat. + */ + +#include +#ifndef BIOS_TEXT_ONLY +#include "bootstrap.h" +#include "libi386/libi386.h" +#include "libi386/vbe.h" +#include +#endif + +#ifdef BIOS_TEXT_ONLY +void autoload_font(bool bios); + +void +autoload_font(bool bios) +{ +} + +vm_offset_t build_font_module(vm_offset_t addr); + +vm_offset_t +build_font_module(vm_offset_t addr) +{ + return addr; +} + +struct preloaded_file; +void bi_load_vbe_data(struct preloaded_file *kfp); + +void bi_load_vbe_data(struct preloaded_file *kfp) +{ +} + +#else + +void +bi_load_vbe_data(struct preloaded_file *kfp) +{ + if (!kfp->f_tg_kernel_support) { + /* + * Loaded kernel does not have vt/vbe backend, + * switch console to text mode. + */ + if (vbe_available()) + bios_set_text_mode(VGA_TEXT_MODE); + return; + } + + if (vbe_available()) { + file_addmetadata(kfp, MODINFOMD_VBE_FB, + sizeof(gfx_state.tg_fb), &gfx_state.tg_fb); + } +} +#endif From nobody Tue Apr 16 20:13:02 2024 X-Original-To: dev-commits-src-branches@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 4VJwFq0K5Bz5H0bJ; Tue, 16 Apr 2024 20:13:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFp5QLJz4tMP; Tue, 16 Apr 2024 20:13:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298382; 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=xCNIMp/Hsd2Ylz9xiW5XygLWj10rufr+1rZ1bYCVrAk=; b=ZxH4E7UkSKmMxYkP1TIuRJ+/Yv/QkG7H5v4obhk2blq7bZNxzkur4xOrzZcbyTA78h+hWV s4YWqFBoc1jk0EWBCBX5vPwsEMMwIbDtuGwY3sx2gShSib5CBZ08rGCvwqIHELwkV9jDpc vl1x8uTx1yhJyWhmr8iPoF37r3HHiJ3+iO+pMH9/3YL7UVZE/4Wyx+RbNV6/viJ/em8BOU J4I0cQ1d2Lpmj1AakCAqjyTjd4S4mg/gEkJZBsIJwU0cuaBFQkwjbaifatH2OIYQtYEr5s yYfWoD8cZy1OIs1c5bH+2u7EKnius1ejF/WbNS11Qxef6mwdl0RlVN+IQquuMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298382; a=rsa-sha256; cv=none; b=MG3rUT4rOS71cjwRRbK+PiCu8oZCVNpWtVT6kZJFf6/RZc6+H1vOCQCYZ4rfqxxfgeYxmR JaM1ZgWLDv+HH0/APhkLM2Ey+95UkLlqE2FzxxxYoHKIIEdz/3/833cWN9ofxk9svk4ROb ZMB+rwMLELHDgrg/0s9J3HsN23Cft831vbQHCmKKlVAB5od+9a1P1uKH0IQC4xlZK1GvXP zFRX2xKXNYQuStqqJlO5P6rrs3EddWW7zkxWrg+B5QnxCsJmExzidOd2Pqk8PRw4SaxbmL BNt09/o+2BI/oCBjiruplZxMk9CsD1KErxcPbcRrpDJV0cHUkRQiKppn9bxclQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298382; 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=xCNIMp/Hsd2Ylz9xiW5XygLWj10rufr+1rZ1bYCVrAk=; b=PvSnjdeGi5Lf8S5MYHwC4YjjWUfwun8TTCNGhKnzoNmAEmGNCA1DsculLHWWDFtQnmEp+8 hFUl5mguwUQHxtkVRak3tD1cWo+gTpHypO35Ncma9RGWD4pk2aje4Hj+AsWkRRyg6lvT9M xmoTTUO38Logik8zYXF0kvWrABQaLzueJLvYj1d42ZrP65LGh3I+P8HKAPb5Btz6UjKg4y mZR4y88U6SEhgyB9Yb9rqsqOCbbyr0imqFXpWDeiqf8iL6D+8Vv7Ymx+janwnYHFnOg9VC 8vQazpgSf1EAdHzzfsBMmXYjpFWUi1A528yb6+uJJbujo4+GzPRDBaWVaUxy1Q== 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 4VJwFp52hlzxdg; Tue, 16 Apr 2024 20:13:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD2Pi038563; Tue, 16 Apr 2024 20:13:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD2oP038560; Tue, 16 Apr 2024 20:13:02 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:02 GMT Message-Id: <202404162013.43GKD2oP038560@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d6a4e4842943 - stable/14 - loader/libofw: Fix disk size truncation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d6a4e4842943fb525061cfee34bc37a098cb7433 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d6a4e4842943fb525061cfee34bc37a098cb7433 commit d6a4e4842943fb525061cfee34bc37a098cb7433 Author: Justin Hibbits AuthorDate: 2024-02-20 22:08:54 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader/libofw: Fix disk size truncation At present OF_ioctl first multiplies, then casts to 64-bit, meaning at the asm level it truncates the result to 32-bit, then zero-extends it to 64-bit to return. Cast `n` to 64-bit before multiplying, so that the correct result is returned. (cherry picked from commit cd6e526e268e4fdf1c9a65b9d792e67343f52307) --- stand/libofw/ofw_disk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/libofw/ofw_disk.c b/stand/libofw/ofw_disk.c index e9002ca23fe9..d30454b70b74 100644 --- a/stand/libofw/ofw_disk.c +++ b/stand/libofw/ofw_disk.c @@ -174,7 +174,7 @@ ofwd_ioctl(struct open_file *f, u_long cmd, void *data) case DIOCGMEDIASIZE: block_size = OF_block_size(dev->d_handle); n = OF_blocks(dev->d_handle); - *(uint64_t *)data = (uint64_t)(n * block_size); + *(uint64_t *)data = ((uint64_t)n * block_size); break; default: return (ENOTTY); From nobody Tue Apr 16 20:13:03 2024 X-Original-To: dev-commits-src-branches@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 4VJwFr06Tzz5H0Xq; Tue, 16 Apr 2024 20:13:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFq6C4Kz4tjT; Tue, 16 Apr 2024 20:13:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298383; 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=OQXE2cDJha6ifDQp1VwJnRNl3Es9G8AO9pXaYuZ/hK4=; b=MXxuo0K+nyxD1S7Vo+z5qyvjyriqMmi8IYJUotaGBc02q2LjTZ1UZm6EPbyiuEoGggkWIC DfDYuEb9BP1u19HPbnL/rxDxVTBHrl11iBq26odc3+moBiZl0qKzdztV6Tvcawoa8xqT+N BB+kxNWkua+dQbyKJM+eprYAmBHDHuyCIV0mOdMW1PMZB5QByHVzlY+3o6hYPUO9W9gGEp ++klM2f7Q8ysRuh2RBdOoi9DqIvtIXAyHn39dWY5Zjg/bJNLVhqvdm1Q2wLC8OUxUh9lmx X6AScVTemW93ckuz3jBGFejTp5UDlEDJeAPG6lumiF2KCY5t8o7p4TOS8UQELQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298383; a=rsa-sha256; cv=none; b=mGwiFkm2hXezmKctEGRj1HAgru+5qLoahreI4UreuD8ZDV1Zp2hpLJwgfnZ8f/1fAHAA9c Wu75u+KB4Tveodm+wDM7UGDpdlbpVgJ7wKJrcK9fRDLWzkR34A4fVCEvAc/pHPzC4HzJVM vTKng2LSZbIin2PnlUiFq4oiKLcfWl314Vs8ykXL2htkeQ5rww6K5buEdvj1fkpS5OFx5n v6TZMmrOxXbyt4vIk7/QnTGPhAOZ4IcjSixjVUpR1Idfz+4Jmn8GBmHwnQsSWq6Ju1yUOk 4EpHektDRHNw5FcovNLZVNMBbLzmBTbBKwlBZ9WRId6/QvywQB4fWUg9riyvPA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298383; 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=OQXE2cDJha6ifDQp1VwJnRNl3Es9G8AO9pXaYuZ/hK4=; b=cWRaloQOCf6qZzRgALI5WE+E1lKEglGKyOOrQvOh7CpuVyldolQncmsV7AGDGzJDW6054u lM0nI3I8+7X/gXHnm0HaWvdL4xbCo+Yj2JjXpJOaKQAEdQjg5l5USFwGKnsPZS8yY1f4xQ XNOu4NdOnPuWUft0TvP77RO8bUwPwLAzg3Cfge/TfUgnP/N3cuHWoWxtyHp1dKJOxhuhGg jSDionfFbGmiiVCa/12g0KJaDKvR7p9iUyo/0zNDzECbkW7nkOXP/3Z7MNmyBtgJcdBSWv ZyYkP9nyCXm3Tf+f1qXg+FFU6gtrXQ3ozfCn39zjOdoLbjEwUnVCwHMYIJ+HEw== 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 4VJwFq5pwDzxPP; Tue, 16 Apr 2024 20:13:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD3kq038629; Tue, 16 Apr 2024 20:13:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD36t038626; Tue, 16 Apr 2024 20:13:03 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:03 GMT Message-Id: <202404162013.43GKD36t038626@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 67d21468bfaf - stable/14 - loader: For the mini-stdio we have for lua, #define them to something else List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 67d21468bfafc489194ee2b88180baefd2b83a2a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=67d21468bfafc489194ee2b88180baefd2b83a2a commit 67d21468bfafc489194ee2b88180baefd2b83a2a Author: Warner Losh AuthorDate: 2024-02-21 03:31:50 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:25 +0000 loader: For the mini-stdio we have for lua, #define them to something else To make it easier to port lua and some of the lua modules, we have a series of routines to implement the stdio routines, even though we don't normally implement them in the boot loader. Add a comment to this effect. Also, some tools, like sanitizers and static analysis tools, make unwarranted assumptions about these, so #define them to a different name so they stop. Sponsored by: Netflix (cherry picked from commit 9a5aaa97cbae024f90bb626f78c3dbde28653c58) --- stand/liblua/lstd.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/stand/liblua/lstd.h b/stand/liblua/lstd.h index 05a8b8843d9c..ce3aef4bc5fc 100644 --- a/stand/liblua/lstd.h +++ b/stand/liblua/lstd.h @@ -34,6 +34,15 @@ #include #include +/* + * Mini stdio FILE and DIR routines. These are the minimal routines needed by + * the lfs module and lua's base code. We define them minimally here so we don't + * have to modify lua on every import. Further, since they aren't completely + * standard, we #define them to other names so they don't conflict with other + * tooling that makes assumptions about these routines that might not be, in + * fact, correct. + */ + typedef struct FILE { int fd; @@ -46,6 +55,18 @@ typedef struct DIR int fd; } DIR; +#define fopen lua_loader_fopen +#define freopen lua_loader_freopen +#define fread lua_loader_fread +#define fwrite lua_loader_fwrite +#define fclose lua_loader_fclose +#define ferror lua_loader_ferror +#define feof lua_loader_feof +#define getc lua_loader_getc +#define opendir lua_loader_opendir +#define fdopendir lua_loader_fdopendir +#define closedir lua_loader_closedir + FILE *fopen(const char *filename, const char *mode); FILE *freopen( const char *filename, const char *mode, FILE *stream); size_t fread(void *ptr, size_t size, size_t count, FILE *stream); From nobody Tue Apr 16 20:13:04 2024 X-Original-To: dev-commits-src-branches@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 4VJwFs4JCzz5H0bM; Tue, 16 Apr 2024 20:13:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFs0J2Vz4tMn; Tue, 16 Apr 2024 20:13:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298385; 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=6dhLpnoKyDShCDVaXpaol6B7RkdcUmTTspoY1Zrok3g=; b=M+CGxgvfy/rfrOGmD87XcPwpkqebqJLNeioomwRiBOpPzbfpY3rOhN98YynaqWf54MqqvB k1Y13C70aRYyQGS+D8wrzV4hGU2YwrCk4uL/Lj5HtuXHDzrdl9MJnNk7XNsv0hjMOm/qH8 eEcDSM+NPlWMI4/MAdsQ2wi0+s6su8eDL7QTBjFcbzQrpPoQGDRcYcZ4Hg1tPSBbBGuA4N E9VUeruOPEby1j9Y9dO/oOargdkV0AIXfHMAoxKIx5rDVczl5gEf/zBzxExOQzQk1H29pK vP5POVOAibntJAU+KmcfvHmDnEknOWUR5+NJ6ixOB6Cq2mTqhDLmKvUGksU2xw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298385; a=rsa-sha256; cv=none; b=QGoBdIsyQo1J5FA/eCptkskbnsoynCim1lJIiBopxF525IEzgKUZFwoVVEpAbMheKefN+6 1QDtSkRE3Bfg/43nb7tJUI2jS1V41Ggxx1JemNq7ijkeXKNi1JkFjtfki6hL5+5NVRZQSD Asz5pDsArvgcQmpK/36bUtVISDde4Ye2r9elDoPRv2KGyE6HXI+fM3gz13Db+ybbJUIbge RoEnNhHZjKzOWMBgt1fp3UHC8uaUALOacIeZ408knDiDoVJd/5Szd8EuF1rWvTCiarY0QI tfi630Dsqtc95Z0cejduu44bk7rOIzITD7W91suw9qhV9CVhio5w5SVoceWvrw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298385; 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=6dhLpnoKyDShCDVaXpaol6B7RkdcUmTTspoY1Zrok3g=; b=rjJbM6yAK4L//fXBcU4mVfZnnhItgh+QKI2OSXKHGhOytNjKWHp/GZ5c5Ayt/EPmROCe1m E9sCzVhs5oxzBvj5kRKHELxnElSsZpd6olOF0hb5KKE3zOeo8ZCZ4b2sSPrBg9ZN8vYyaX Cao8kORiIrFb89g1C/hex9ZfMJZdUIbESz6GlyGFQL0dlAoXiSZumJlBu1Q58kInR4CgWU YZEkBb+xa0eCW0IeCuXJTQEuWUwaeGa6x/11fsGVw06ruv30cNJKWbfSse70fOYPE8RMYD rJfxWiGxZWphI1x9D+yMsnxN8l1AKXnGksl0M4NCFNryGndrr75WB7Z0GUZ4zA== 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 4VJwFr6x9dzxWS; Tue, 16 Apr 2024 20:13:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD4Kw038674; Tue, 16 Apr 2024 20:13:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD423038671; Tue, 16 Apr 2024 20:13:04 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:04 GMT Message-Id: <202404162013.43GKD423038671@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: c3f5ae85ceda - stable/14 - kboot: Fix zfs bootonce protocol List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c3f5ae85ceda88473c1b8fc671284e467bd37ce8 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c3f5ae85ceda88473c1b8fc671284e467bd37ce8 commit c3f5ae85ceda88473c1b8fc671284e467bd37ce8 Author: Warner Losh AuthorDate: 2024-02-21 03:26:08 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 kboot: Fix zfs bootonce protocol This wasn't updated when the other copies were updated. Make it identical to efi code. We should likely refactor this (with userboot), but they are all not quite identical. Sponsored by: Netflix (cherry picked from commit 65ee8f90b7906a5895c87bfe05f85ce3d3bf84c7) --- stand/kboot/kboot/hostdisk.c | 35 +++++++++++++++-------------------- 1 file changed, 15 insertions(+), 20 deletions(-) diff --git a/stand/kboot/kboot/hostdisk.c b/stand/kboot/kboot/hostdisk.c index 552ae68daced..423151983523 100644 --- a/stand/kboot/kboot/hostdisk.c +++ b/stand/kboot/kboot/hostdisk.c @@ -567,40 +567,35 @@ hostdisk_zfs_probe(void) /* This likely shoud move to libsa/zfs/zfs.c and be used by at least EFI booting */ static bool -probe_zfs_currdev(uint64_t pool_guid, uint64_t root_guid, bool setcurrdev) +probe_zfs_currdev(uint64_t pool_guid) { char *devname; struct zfs_devdesc currdev; - bool bootable; + char buf[VDEV_PAD_SIZE]; currdev.dd.d_dev = &zfs_dev; currdev.dd.d_unit = 0; currdev.pool_guid = pool_guid; - currdev.root_guid = root_guid; + currdev.root_guid = 0; devname = devformat(&currdev.dd); - if (setcurrdev) - set_currdev(devname); - - bootable = sanity_check_currdev(); - if (bootable) { - char buf[VDEV_PAD_SIZE]; - - if (zfs_get_bootonce(&currdev, OS_BOOTONCE, buf, sizeof(buf)) == 0) { - printf("zfs bootonce: %s\n", buf); - if (setcurrdev) - set_currdev(buf); - setenv("zfs-bootonce", buf, 1); - } - (void)zfs_attach_nvstore(&currdev); - init_zfs_boot_options(devname); + printf("Setting currdev to %s\n", devname); + set_currdev(devname); + init_zfs_boot_options(devname); + + if (zfs_get_bootonce(&currdev, OS_BOOTONCE, buf, sizeof(buf)) == 0) { + printf("zfs bootonce: %s\n", buf); + set_currdev(buf); + setenv("zfs-bootonce", buf, 1); } - return (bootable); + (void)zfs_attach_nvstore(&currdev); + + return (sanity_check_currdev()); } static bool hostdisk_zfs_try_default(hdinfo_t *hd) { - return (probe_zfs_currdev(hd->hd_zfs_uuid, 0, true)); + return (probe_zfs_currdev(hd->hd_zfs_uuid)); } bool From nobody Tue Apr 16 20:13:06 2024 X-Original-To: dev-commits-src-branches@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 4VJwFt3PzYz5H0fD; Tue, 16 Apr 2024 20:13:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFt1H8tz4tdc; Tue, 16 Apr 2024 20:13:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298386; 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=rbIJwqNYKfCDrygrewhnSryq+BJlPLwBZhYvKhadi7U=; b=LA3yTKqths9ZzaEdDXInqcntP/rTopbYWWxlczMSv8f4SEEkPAOSeFUS8AS850kw2THEzi YHkuYeW6yV07Ob4MK2ikVPIHMsqj2CCwU5gtR2EgZN+s3jLGffFvAASVoClnx87B2v7gxE +6YzLlync5vmZ3dJWN4kHUsFjAd46n7rm6SFsSPMqJQK2s8Ud603eQ1984Dk/MyHT4vAqN vdCiVRoUt5QoONIzDFf8w1eSuuo1paTXCcCS9Q9kpUf9nmqW6x49q+IYsnmUvAwL9S65az 143ay+PfX57nE29rqYlHUFS0mViZEaHfauIiIAPmdwcf878xjc01WIiH4SSG8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298386; a=rsa-sha256; cv=none; b=WwuWzaJrkMYizP77xIAC1JxQZMXgyhk7tvZzIp89AaMz4xCbJZ7/Iw7OpZ4z4TQb5k7NG/ zixbgQH+8FRpUpwf2MXFC6VdFRocb6ujjAPwEeUGJMbGO9MZ8GIyTyA3Hx37UUSYJZq7LT N0poA5oJPSNs7QS41TvVNp5Ah4cyxvC8PZHpuCfpxr7JSCh4cvwnl+hAh4wbYtZNXL3IXy HJMVrqG67ScsroFkcvwNSYLfZgd4ydx1PGx7+1sQLTkcOdTTbgAPKFj3TVVj7Rhjn0IlNa sHzqVY8QkMmcWpq/82EnsQdv3qUNlfKvQDBdOykFVY+eYz9JHDb5FpdFC+5pQg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298386; 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=rbIJwqNYKfCDrygrewhnSryq+BJlPLwBZhYvKhadi7U=; b=sPVAelxN28722eUELTPwcLKusObFnvvR/vcuGFsj+jss/+cvlS5eRsgy3yeO8XoZ5ubU38 ANi+KVImUmsR+X/W709QJrZUEH16osSOcHqPBUXPKB2RecYl7L/Z4Dp+FfeHg6iUhphP32 R1GqrXwO4LNqQdHLYmwcO9B4BQSlKagewraZLxIrT+MofGkAZywH3oLy608L51rkqssG+k 48l528TvxqrJtww8Uhl0XxC71d7RcAvSIo6GVQn4IGRJNX01BdeiRgzVA1Y14DXw+pn0c4 RLJzkkBnaspJBalCeQLfCUrBlGLLrg2MX6KCwUi89JyaTDBy28txSQW/U2NwOQ== 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 4VJwFt0vfRzxPQ; Tue, 16 Apr 2024 20:13:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD64R038714; Tue, 16 Apr 2024 20:13:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD6mA038711; Tue, 16 Apr 2024 20:13:06 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:06 GMT Message-Id: <202404162013.43GKD6mA038711@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: e9620c27f176 - stable/14 - loader: Retire CTASSERT List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e9620c27f176ef66abe128bcb17df37eac46c6e6 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e9620c27f176ef66abe128bcb17df37eac46c6e6 commit e9620c27f176ef66abe128bcb17df37eac46c6e6 Author: Warner Losh AuthorDate: 2024-02-21 15:48:32 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 loader: Retire CTASSERT The project is moving away from CTASSERT in favor of _Static_assert. Cleanup the few instances in the loader proactively. Sponsored by: Netflix Reviewed by: manu, tsoome Differential Revision: https://reviews.freebsd.org/D44006 (cherry picked from commit 32568e5f2435a2539b0c4177a6fefe7a9e0a0c89) --- stand/common/bootstrap.h | 4 ---- stand/efi/loader/arch/amd64/multiboot2.c | 2 +- stand/i386/libi386/multiboot.c | 2 +- stand/i386/loader/main.c | 9 ++++----- 4 files changed, 6 insertions(+), 11 deletions(-) diff --git a/stand/common/bootstrap.h b/stand/common/bootstrap.h index 7387569ad65a..b7d6e538f9be 100644 --- a/stand/common/bootstrap.h +++ b/stand/common/bootstrap.h @@ -382,8 +382,4 @@ int gen_setcurrdev(struct env_var *ev, int flags, const void *value); int mount_currdev(struct env_var *, int, const void *); void set_currdev(const char *devname); -#ifndef CTASSERT -#define CTASSERT(x) _Static_assert(x, "compile-time assertion failed") -#endif - #endif /* !_BOOTSTRAP_H_ */ diff --git a/stand/efi/loader/arch/amd64/multiboot2.c b/stand/efi/loader/arch/amd64/multiboot2.c index 4d7b2713685d..6c96d7dc0073 100644 --- a/stand/efi/loader/arch/amd64/multiboot2.c +++ b/stand/efi/loader/arch/amd64/multiboot2.c @@ -334,7 +334,7 @@ exec(struct preloaded_file *fp) struct mb2hdr *hdr; - CTASSERT(sizeof(header) <= PAGE_SIZE); + _Static_assert(sizeof(header) <= PAGE_SIZE, "header too big"); if ((md = file_findmetadata(fp, MODINFOMD_NOCOPY | MODINFOMD_MB2HDR)) == NULL) { diff --git a/stand/i386/libi386/multiboot.c b/stand/i386/libi386/multiboot.c index e11da0444fcd..b69895de9706 100644 --- a/stand/i386/libi386/multiboot.c +++ b/stand/i386/libi386/multiboot.c @@ -165,7 +165,7 @@ multiboot_exec(struct preloaded_file *fp) int error, mod_num; struct xen_header header; - CTASSERT(sizeof(header) <= PAGE_SIZE); + _Static_assert(sizeof(header) <= PAGE_SIZE, "header too large for page"); /* * Don't pass the memory size found by the bootloader, the memory diff --git a/stand/i386/loader/main.c b/stand/i386/loader/main.c index 97c4448afdc3..8a3c1cbc6a42 100644 --- a/stand/i386/loader/main.c +++ b/stand/i386/loader/main.c @@ -51,14 +51,13 @@ #include "libzfs.h" #endif -CTASSERT(sizeof(struct bootargs) == BOOTARGS_SIZE); -CTASSERT(offsetof(struct bootargs, bootinfo) == BA_BOOTINFO); -CTASSERT(offsetof(struct bootargs, bootflags) == BA_BOOTFLAGS); -CTASSERT(offsetof(struct bootinfo, bi_size) == BI_SIZE); +_Static_assert(sizeof(struct bootargs) == BOOTARGS_SIZE, "Bootarg size bad"); +_Static_assert(offsetof(struct bootargs, bootinfo) == BA_BOOTINFO, "BA_BOOTINFO"); +_Static_assert(offsetof(struct bootargs, bootflags) == BA_BOOTFLAGS, "BA_BOOTFLAGS"); +_Static_assert(offsetof(struct bootinfo, bi_size) == BI_SIZE, "BI_SIZE"); /* Arguments passed in from the boot1/boot2 loader */ static struct bootargs *kargs; - static uint32_t initial_howto; static uint32_t initial_bootdev; static struct bootinfo *initial_bootinfo; From nobody Tue Apr 16 20:13:07 2024 X-Original-To: dev-commits-src-branches@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 4VJwFv4p6rz5H0hT; Tue, 16 Apr 2024 20:13:07 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFv2N8Qz4tpZ; Tue, 16 Apr 2024 20:13:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298387; 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=rgQ69MMkVQvsW53Y4sK3UFjCiTB/kQ3jW4JxK6w6TW8=; b=odzpbT5nGGbnDfIPDsj4ZEY0fsoJ9zdLsTvYsc0Ys8nBYfLXgek+hqxwDVmceOeGPD/+Q6 nTwfBLhvcCnrEhyV9R2nqrH5rjiIEveBvCQEMidhQjH8tnKCOU5w81Z2igh1dKTyC6bc0l 9tdM1bPb0vjBeERanItBzTyxZfrrHZHnMRXRrP8ojmt5HMKRm4guZZBnHVGTqOvV4bEEPF 9Nc2SuFUcNotbN19ekB/jmN0roydUjJ14jrCQO7PoEeddw9zOTEnHomWujA7jFD9g43nlQ Rhav2EUzW5MB5o/gshSW8Hy84erIX4XQ53iGzJFyWELZIt2dfREFqZnET6vjdw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298387; a=rsa-sha256; cv=none; b=f7dbRLn+Ko1R/v9azF/9mSVe4SGpZ9dVhN2FiYvRBFN1diCUyhEkaGGhu+BoVzp6PXt4AR 8YjRha64arugvXyFiuX37vYwxey3dwuzabeUWiJTo0ukbe6243O6ZEOdha2Vj3FaJNkXLu M5vqwA/ToZBGe4D3nEjJMTLaE9n169C9P5qjMUO6Ap1tS3UgQWLBWnJPeFehKo/+EAKN4e Kk6NpMX5OVHoSSkA9RGBfNvgmztFx7VO5CXgdoqMUoKsNLP1RnEhGfzW6PXzQdgjc4lk+t Z+dOVowR+N1SI6lhdU1Tb5G/WEzuidTerv9GmESknxGORWWeYLSO4PxIaXtWyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298387; 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=rgQ69MMkVQvsW53Y4sK3UFjCiTB/kQ3jW4JxK6w6TW8=; b=o8d5+R1yIQj4B4TWC+FVvfDq947kkbkAxzeMvVZUpsaun80C5cGAtzErw8nE7UXYnWInD5 zvQPBWf4EngMngw7EgOIZIOYoYW+BCprbMCG0S5TQ5scfJqRHGLSKPV0syFqDkTN5yjkv1 owBYbk0ReA3ynYS37a4XOiPY/QOv6hqtApqKm1Rv+uEb4XHNVwwkZ5osyhzW39T4Zoz9uZ st3MmXF8Y1xIzasxHptsu4eQa1Rwxfvpu9RwrfmQsie5qVogPNIhmSdO/N+r/gO9uNiJod AO5KWWbdMiRSRw7QRtdu84FBcj/9kJp9MMKwHaT3Nes1pwh92JmZe/2CujLZ/w== 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 4VJwFv1yX5zxPR; Tue, 16 Apr 2024 20:13:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD72c038777; Tue, 16 Apr 2024 20:13:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD76H038774; Tue, 16 Apr 2024 20:13:07 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:07 GMT Message-Id: <202404162013.43GKD76H038774@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 92f8c2f636e0 - stable/14 - loader/efi: Make gcc friendlier by move md_dev List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 92f8c2f636e0ade6a5986c0be449ccf819f8b2be Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=92f8c2f636e0ade6a5986c0be449ccf819f8b2be commit 92f8c2f636e0ade6a5986c0be449ccf819f8b2be Author: Warner Losh AuthorDate: 2024-02-21 15:50:31 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 loader/efi: Make gcc friendlier by move md_dev Move the extern struct devsw md_dev out of the function. gcc is happier with this arrangemnt often. However, we really should move it to a header file, but that requires a bit of a rework of md support and config. Sponsored by: Netflix Reviewed by: manu, tsoome Differential Revision: https://reviews.freebsd.org/D44008 (cherry picked from commit b2822c40f61d351bf8a4cac87e12521db06ff962) --- stand/efi/loader/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index d7cffe5f6df9..5944c383574e 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -278,10 +278,11 @@ probe_zfs_currdev(uint64_t guid) #endif #ifdef MD_IMAGE_SIZE +extern struct devsw md_dev; + static bool probe_md_currdev(void) { - extern struct devsw md_dev; bool rv; set_currdev_devsw(&md_dev, 0); From nobody Tue Apr 16 20:13:08 2024 X-Original-To: dev-commits-src-branches@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 4VJwFw5vSGz5H0bS; Tue, 16 Apr 2024 20:13:08 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFw3Czmz4tpw; Tue, 16 Apr 2024 20:13:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298388; 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=SWfgNThFvZP4DkW4oufbMzx9s2g79aQDT/hbLgi8iyE=; b=h9Wfggg2nKH2V5Gowdw5lRHEtc/JdG3X1Jb6lGWpET7ggC55NJB4mqLd/AwjyfMj/VyxnV OT7tsMjtMRYrcEFxB4FXuwberz6G0iUsALX2EquYQDYsxXjhxdajN19g9/xi3JqZZDBX2U 14RZaJ7zIeYhfwxgPxBwNG2Jp08qFet08jxHxGzBRsoGTqokH7X7zQwmik4lyNmz3nCXUn OFOVFWVTinW5U+u/56ff+jMDTQ3hfa6pnc6ekNa0hc50ArRy7kTkstzDKT/j/MDgiWdnRg FHP8fDjoZc+NIQEr7KfdmIWGOeMRHojlX9hDXDqH+jVXUvgRdK6SP01BKQSC6w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298388; a=rsa-sha256; cv=none; b=eUp27yB60sSuezEOHHyc0+IP4MsrF2K3kwHaUClwKAl1DAO3uRXPg7H1Fm14fisV9prNzH Z8zwL9uhoRBsGX0pc/eJ5aibnz9vghhtpwlB0ZD66BSEIrWnNAXWHBqfxRfHBZ5YD1w/DD kQJFcvF0R2cUdRUsILj+2/ppULd6zgK59OniC29KQnDTjCA9OP/ncsPeT+Npai4mx1t231 WdFsQqCnGXoP5s5SaZYhysgl/YK5/dwy3FFVDygel+B7WZgsMcuyrNAzLX4RPSu37nZ7Dq HtOWju8LbgMVD69rJlKT6zaEO/1Bjlf3RhMS1PQr3ddpuDmkYtrwRA0ZCHob5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298388; 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=SWfgNThFvZP4DkW4oufbMzx9s2g79aQDT/hbLgi8iyE=; b=e6LpewZHnn9C5M9Ex6Oq45h/PPorDlD3jAry41gzkBAZMBsG7qH3kkvIVHxAmvRi5lPqOw LdUZE1NhZYKZz5bh1x1iyzTBNqvQnZH9Go7RVmatOoYBHHdOHww96bKe+lRPwB0/1xLu6a Qd4+3YpTqCszmy7hBRoCbdwU4f6zKwQtPCfuC+EHehA3bQ92TfYYpay9CJXEqwkfGSV55n w0I8U8PbYeFU8iaOrO3J0FPU2WeeyJYCFSRzddSt0mUYZsj6oYGf7synCeovZAGiPNGoAf dFl/EpcmI8oIYgIb+hU88ouJ5M+t8NvakC7mqpsYCfV1BHOH9vTfNXppF/Zxhw== 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 4VJwFw2ngTzxWT; Tue, 16 Apr 2024 20:13:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD8XM038831; Tue, 16 Apr 2024 20:13:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD8Ql038828; Tue, 16 Apr 2024 20:13:08 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:08 GMT Message-Id: <202404162013.43GKD8Ql038828@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 7209dd3eba78 - stable/14 - kboot: Implement write support for hostdisk List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7209dd3eba787f07484570edaac5aa0b8db96f18 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=7209dd3eba787f07484570edaac5aa0b8db96f18 commit 7209dd3eba787f07484570edaac5aa0b8db96f18 Author: Warner Losh AuthorDate: 2024-02-22 15:17:48 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 kboot: Implement write support for hostdisk Don't assume that strategy is only called for read. Check the passed flag for F_READ or F_WRITE and fail if it is neither. Open the disks for writing and call host_read/host_write depending on that flag. Sponsored by: Netflix Reviewed by: kevans, gallatin Differential Revision: https://reviews.freebsd.org/D44016 (cherry picked from commit b3e76e3d9e2262c4b79e81e63e09bfe62c1f6baa) --- stand/kboot/kboot/hostdisk.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/stand/kboot/kboot/hostdisk.c b/stand/kboot/kboot/hostdisk.c index 423151983523..a9117d4c1c9d 100644 --- a/stand/kboot/kboot/hostdisk.c +++ b/stand/kboot/kboot/hostdisk.c @@ -305,7 +305,6 @@ hostdisk_strategy(void *devdata, int flag, daddr_t dblk, size_t size, struct devdesc *desc = devdata; daddr_t pos; int n; - int64_t off; uint64_t res; uint32_t posl, posh; @@ -313,12 +312,14 @@ hostdisk_strategy(void *devdata, int flag, daddr_t dblk, size_t size, posl = pos & 0xffffffffu; posh = (pos >> 32) & 0xffffffffu; - if ((off = host_llseek(desc->d_unit, posh, posl, &res, 0)) < 0) { - printf("Seek error on fd %d to %ju (dblk %ju) returns %jd\n", - desc->d_unit, (uintmax_t)pos, (uintmax_t)dblk, (intmax_t)off); + if (host_llseek(desc->d_unit, posh, posl, &res, 0) < 0) return (EIO); - } - n = host_read(desc->d_unit, buf, size); + if (flag & F_READ) + n = host_read(desc->d_unit, buf, size); + else if (flag & F_WRITE) + n = host_write(desc->d_unit, buf, size); + else + return (EINVAL); if (n < 0) return (EIO); @@ -339,7 +340,7 @@ hostdisk_open(struct open_file *f, ...) va_end(vl); fn = dev2hd(desc)->hd_dev; - desc->d_unit = host_open(fn, O_RDONLY, 0); + desc->d_unit = host_open(fn, O_RDWR, 0); if (desc->d_unit <= 0) { printf("hostdisk_open: couldn't open %s: %d\n", fn, errno); return (ENOENT); From nobody Tue Apr 16 20:13:09 2024 X-Original-To: dev-commits-src-branches@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 4VJwFy1FZ1z5H0WX; Tue, 16 Apr 2024 20:13:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFx4ZDlz4tq9; Tue, 16 Apr 2024 20:13:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298389; 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=wVcT/vM1MXNB8L2u8sw6uIxsx5pg0RhkJkpeuMZWewE=; b=bj3K7Vcm3vAgijVOSx1qi/WCxJ9vaZ4Fe0JX9qVby4vu58s/nAXcbBdaoTlzIMyYGykboG JgV00WaVXmOcCbOLQia7R8g1PUlcTKsil2USAmXMRsujDBLQGIsIyG66tpnBDQ5x8yDBWj +Be4ZhQqX2ZsPF6G9y0IXY5V9oGc6DUVEU/YD6J7f9p5Ki6iCihC85Cwz9yTE5nqy5Klfz KkCBYrb/9BbM2O30kGM7DMRvMU6Fhy0OqVqbJb02Kvxn6D36imsGw1+L1Ses+RKbvmKDWQ mFa39Swgs99tH4mFXXbvoM/lEPKy2oepX5PVqp63kOglsHRfQrDhFVyo507vAQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298389; a=rsa-sha256; cv=none; b=KHo/+DA5lai6CFrC0B9bqVLBPebAu7LPIdNIltZ/gFuwJMosGkOWNWSFSu9b/DkPFvfDV7 1paOyCuO+N2+zrFFpxGYI77dxxkVNZdhEL0RW+Cvy1xcAKl7gIpEMewwc1gGXr6gQQzZQ2 nYMKe7FMNOf2miVuDJwhqV8x1LL3Aod+tA38+ywKz0hPjwF4s+Bih66SR29kEvZ0AmaJdX 3HGE+s+I6krfVGdFwic3NdqzyDVFOSUwyFHb+zVTz+XtAi8j26NzKkhb5EtpuDwyxH1lTy KJEOSGnvBXRZ9OIxY1yRzdK+Vo42vnmbRH7QwVAGk8ZMNCr/y6bVZkNtiWW/tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298389; 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=wVcT/vM1MXNB8L2u8sw6uIxsx5pg0RhkJkpeuMZWewE=; b=tjl9jqQTLi5YNcK83FYarL0PYrl3hmcTtbZUxmHsC0uy4TadLOh4cWJIretQ0ek7dN2q7W HtONJ97MhEkzmh1Le2rP5QoeZ8oh4pH18t1OLPvq8E4kk+I7CY50x3xkqPssYRVglHNwh/ 4FN/G6vOGuecesKQEGC7jIJEufSpVCqVDyLgm39eREyFar0jfXOXMe0MU8hUfNDzn1TGzF IkyVDcdMlIFGMjIErVp0G2sjI5JuDUUgyjlIsVXWxU3EjLfW3JGv4c3neAxXf+q1S41Baa 3emH9tVnYQxLCfmyUXmQYLaHj+iFNKc+yQ2dM9k+EU+/8MXeFBDKSlUMMIxeaA== 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 4VJwFx4BYZzxY5; Tue, 16 Apr 2024 20:13:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKD9rk038883; Tue, 16 Apr 2024 20:13:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKD9Q0038880; Tue, 16 Apr 2024 20:13:09 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:09 GMT Message-Id: <202404162013.43GKD9Q0038880@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 1ad22bbc04c7 - stable/14 - loader: return errors from writing ZFS labels List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1ad22bbc04c7094644135b2e22386e20b899b3ff Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=1ad22bbc04c7094644135b2e22386e20b899b3ff commit 1ad22bbc04c7094644135b2e22386e20b899b3ff Author: Warner Losh AuthorDate: 2024-02-22 15:17:56 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 loader: return errors from writing ZFS labels vdev_write_bootenv_impl can only return success. Instead, return the last error. This will make any write errors more visible. The old code masked kboot's inability to write bootenv. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D44018 and loader/zfs: Fix to actually return the last error The last fix, to try to return the last error, really returns the first return code after the last error, which could be zero. Instead, return the last error. Also, change rc to err to make it visually distinct from rv, which is the cause of my error in e54bb0ad8058. Reported by: Bill Sommerfeld Fixes: e54bb0ad8058 Sponsored by: Netflix (cherry picked from commit e54bb0ad8058c0f84ceb08b49bb1d22af829a9e8) (cherry picked from commit 525e6d6c890f6aee898ac70347e5bb49da6638a1) --- stand/libsa/zfs/zfsimpl.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/stand/libsa/zfs/zfsimpl.c b/stand/libsa/zfs/zfsimpl.c index ed9c3753dd19..1b29c57a2ed1 100644 --- a/stand/libsa/zfs/zfsimpl.c +++ b/stand/libsa/zfs/zfsimpl.c @@ -1682,14 +1682,14 @@ static int vdev_write_bootenv_impl(vdev_t *vdev, vdev_boot_envblock_t *be) { vdev_t *kid; - int rv = 0, rc; + int rv = 0, err; STAILQ_FOREACH(kid, &vdev->v_children, v_childlink) { if (kid->v_state != VDEV_STATE_HEALTHY) continue; - rc = vdev_write_bootenv_impl(kid, be); - if (rv == 0) - rv = rc; + err = vdev_write_bootenv_impl(kid, be); + if (err != 0) + rv = err; } /* @@ -1699,12 +1699,12 @@ vdev_write_bootenv_impl(vdev_t *vdev, vdev_boot_envblock_t *be) return (rv); for (int l = 0; l < VDEV_LABELS; l++) { - rc = vdev_label_write(vdev, l, be, + err = vdev_label_write(vdev, l, be, offsetof(vdev_label_t, vl_be)); - if (rc != 0) { + if (err != 0) { printf("failed to write bootenv to %s label %d: %d\n", - vdev->v_name ? vdev->v_name : "unknown", l, rc); - rv = rc; + vdev->v_name ? vdev->v_name : "unknown", l, err); + rv = err; } } return (rv); From nobody Tue Apr 16 20:13:10 2024 X-Original-To: dev-commits-src-branches@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 4VJwFz0qMzz5H0fH; Tue, 16 Apr 2024 20:13:11 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFy68K2z4tky; Tue, 16 Apr 2024 20:13:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298390; 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=E2zPiOGIwZrWtY1g3ffnHxQ6IGb+Io2nvor17qfv1q0=; b=weOjRQksWVJNKFC0QZAV0Ev8oM/TFRsVw93IDGJthDepY6VwVoBc3Dd80rJ1My91MxaMbI pDheiUX4l6AQ+ZjwpWQd+kkKd4NKSx+2Rq+UlM8GCVATSSkPeR8/vA0UXQmLBbYpq1/3v3 36ouMLdU2QK1w2KYcDP/jacZEN/gxtot18/FWmNaxlAzq9NOq5oaEB00u1vV89XNC4w3Qc kx9N/lXKkRTExol27q5+q/hLcvc9surgE8pJVGmMsvyPRkTCZOyCC0KR5DS+skF9pygpE9 6FDG7Av5B2tU5/2C9FeA/voYzJjx6epYAY7G910TaMerGKI7onj4XUFT8BKvqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298390; a=rsa-sha256; cv=none; b=Vn2oGpUV+wFRZD9Yjejip4aVVT9GWkI46sZaoHfg9vmO9AOT/MB3b+BAEXDM4m9HnlwvpK HqQ1Y+PhcON07pzm5r5l2UTOjBmgzQWJUEvyZ5qQpkBoAjBJB2nDZtrj8WOBY4YvlYS3lw M5s2yoWLCUeRAKjqUXDxhPjuyiYTLJT171RPeESN6sunhEVuhKlLpER1ez9ASdcA0HuWAu BlOLxOJlPga3APhPj0bhoIxG2ehqrsADQKYPluj4gTmwwKJ15t1nZRCKPc2Ilxa+XJ6LUZ BTdO33tKgXjeKJf/ip0uPTBwzZiTU+6TC5dlwFEkU2QgLdVuaUJ8LNF0vDi/XA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298390; 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=E2zPiOGIwZrWtY1g3ffnHxQ6IGb+Io2nvor17qfv1q0=; b=Bwur/D/0QPcoz7fPSIr+RVQzBdhC6OhIdzkQpsalrAmkOSxuu4U48EgJKdD1xOW+JGCJwj PB5xmTUO4v5XpZZtBGagKqG38WMqv/JAKEHzwtGFXCUGiDFhTTl7ZJw9CdtYdkTUJjmS0/ z7RrY1zGV0w42tTLSrueWcPIvf8UCvJCl/AuRVZk2nouBfotE/poggFtXGaQbo1CMgKltk lqbEzyF2sNq1357aF2/iMhEkrosNwtmYxMbSrtvtsQsfrRePUh3TJ8ziyllbG9KETzCbas 0hbNdWEeI8gW482jXX4nbs00zvpZp2HmKijo96MIqcPdDQWDyPwD8RxcF6cr+g== 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 4VJwFy5bYtzxb2; Tue, 16 Apr 2024 20:13:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDA5e038923; Tue, 16 Apr 2024 20:13:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDAxM038920; Tue, 16 Apr 2024 20:13:10 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:10 GMT Message-Id: <202404162013.43GKDAxM038920@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: c05fe06acbc6 - stable/14 - libsa: Remove redundant sys/cdefs.h List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c05fe06acbc6e1ec82d5f610ced1dd9550c68305 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c05fe06acbc6e1ec82d5f610ced1dd9550c68305 commit c05fe06acbc6e1ec82d5f610ced1dd9550c68305 Author: Warner Losh AuthorDate: 2024-02-22 15:18:02 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 libsa: Remove redundant sys/cdefs.h Sponsored by: Netflix (cherry picked from commit 3e15b01d6914c927e37d1699645783acf286655c) --- stand/common/boot.c | 1 - stand/common/commands.c | 1 - stand/common/dev_net.c | 1 - stand/common/devopen.c | 1 - stand/common/disk.c | 1 - stand/common/interp.c | 1 - stand/common/interp_backslash.c | 1 - stand/common/interp_lua.c | 1 - stand/common/interp_parse.c | 1 - stand/common/interp_simple.c | 1 - stand/common/isapnp.c | 1 - stand/common/load_elf32.c | 2 -- stand/common/load_elf32_obj.c | 2 -- stand/common/load_elf64.c | 2 -- stand/common/load_elf64_obj.c | 2 -- stand/common/md.c | 1 - stand/common/metadata.c | 1 - stand/common/misc.c | 1 - stand/common/module.c | 1 - stand/common/part.c | 1 - stand/common/pnp.c | 1 - stand/common/reloc_elf32.c | 2 -- stand/common/reloc_elf64.c | 2 -- stand/common/vdisk.c | 1 - stand/common/zfs_cmd.c | 1 - stand/efi/libefi/delay.c | 1 - stand/efi/libefi/devicename.c | 1 - stand/efi/libefi/devpath.c | 1 - stand/efi/libefi/eficom.c | 1 - stand/efi/libefi/efienv.c | 1 - stand/efi/libefi/efipart.c | 1 - stand/efi/libefi/env.c | 1 - stand/efi/libefi/errno.c | 1 - stand/efi/libefi/handles.c | 1 - stand/efi/libefi/libefi.c | 1 - stand/efi/libefi/time.c | 1 - stand/efi/libefi/time_arm64.c | 1 - stand/efi/libefi/time_event.c | 1 - stand/efi/libefi/wchar.c | 1 - stand/efi/loader/arch/amd64/elf64_freebsd.c | 1 - stand/efi/loader/arch/amd64/multiboot2.c | 2 -- stand/efi/loader/arch/amd64/trap.c | 1 - stand/efi/loader/arch/arm64/exec.c | 1 - stand/efi/loader/autoload.c | 1 - stand/efi/loader/bootinfo.c | 1 - stand/efi/loader/conf.c | 1 - stand/efi/loader/efi_main.c | 1 - stand/efi/loader/framebuffer.c | 1 - stand/efi/loader/main.c | 1 - stand/fdt/fdt_loader_cmd.c | 1 - stand/i386/libi386/bio.c | 1 - stand/i386/libi386/biosacpi.c | 1 - stand/i386/libi386/biosdisk.c | 1 - stand/i386/libi386/biosmem.c | 1 - stand/i386/libi386/biospci.c | 1 - stand/i386/libi386/biospnp.c | 1 - stand/i386/libi386/biossmap.c | 1 - stand/i386/libi386/bootinfo.c | 1 - stand/i386/libi386/bootinfo32.c | 1 - stand/i386/libi386/bootinfo64.c | 1 - stand/i386/libi386/comconsole.c | 1 - stand/i386/libi386/devicename.c | 1 - stand/i386/libi386/elf64_freebsd.c | 1 - stand/i386/libi386/i386_copy.c | 1 - stand/i386/libi386/i386_module.c | 1 - stand/i386/libi386/nullconsole.c | 1 - stand/i386/libi386/pread.c | 1 - stand/i386/libi386/pxe.c | 1 - stand/i386/libi386/spinconsole.c | 1 - stand/i386/libi386/textvidc.c | 5 +---- stand/i386/libi386/time.c | 1 - stand/i386/libi386/vbe.c | 1 - stand/i386/libi386/vidconsole.c | 3 +-- stand/i386/loader/chain.c | 1 - stand/i386/loader/conf.c | 1 - stand/i386/loader/main.c | 1 - stand/i386/zfsboot/zfsboot.c | 1 - stand/kboot/kboot/arch/aarch64/exec.c | 1 - stand/kboot/kboot/arch/amd64/elf64_freebsd.c | 1 - stand/kboot/kboot/arch/powerpc64/ppc64_elf_freebsd.c | 1 - stand/kboot/kboot/conf.c | 1 - stand/kboot/kboot/main.c | 1 - stand/liblua/lerrno.c | 1 - stand/liblua/lpager.c | 1 - stand/liblua/lstd.c | 1 - stand/libofw/devicename.c | 1 - stand/libofw/ofw_copy.c | 1 - stand/libofw/ofw_disk.c | 1 - stand/libofw/ofw_module.c | 1 - stand/libofw/ofw_reboot.c | 1 - stand/libofw/ofw_time.c | 1 - stand/libofw/openfirm.c | 1 - stand/libsa/abort.c | 1 - stand/libsa/assert.c | 2 -- stand/libsa/bootp.c | 1 - stand/libsa/bootparam.c | 1 - stand/libsa/bzipfs.c | 1 - stand/libsa/cd9660.c | 1 - stand/libsa/close.c | 1 - stand/libsa/closeall.c | 1 - stand/libsa/dosfs.c | 1 - stand/libsa/environment.c | 1 - stand/libsa/ext2fs.c | 1 - stand/libsa/fstat.c | 1 - stand/libsa/geli/pwgets.c | 1 - stand/libsa/getopt.c | 2 -- stand/libsa/gets.c | 1 - stand/libsa/gzipfs.c | 1 - stand/libsa/hexdump.c | 1 - stand/libsa/inet_ntoa.c | 2 -- stand/libsa/ioctl.c | 1 - stand/libsa/lseek.c | 1 - stand/libsa/mount.c | 1 - stand/libsa/netif.c | 1 - stand/libsa/nullfs.c | 1 - stand/libsa/nvstore.c | 1 - stand/libsa/open.c | 1 - stand/libsa/pager.c | 1 - stand/libsa/panic.c | 1 - stand/libsa/pkgfs.c | 1 - stand/libsa/printf.c | 1 - stand/libsa/rpc.c | 1 - stand/libsa/sbrk.c | 1 - stand/libsa/smbios.c | 1 - stand/libsa/splitfs.c | 1 - stand/libsa/stand.h | 2 -- stand/libsa/stat.c | 1 - stand/libsa/strcasecmp.c | 5 +---- stand/libsa/strdup.c | 2 -- stand/libsa/strerror.c | 1 - stand/libsa/tftp.c | 1 - stand/libsa/time.c | 1 - stand/libsa/ufs.c | 1 - stand/libsa/ufsread.c | 1 - stand/libsa/x86/hypervisor.c | 1 - stand/libsa/zalloc_malloc.c | 1 - stand/libsa/zfs/zfs.c | 1 - stand/libsa/zfs/zfsimpl.c | 1 - stand/powerpc/ofw/cas.c | 1 - stand/powerpc/ofw/conf.c | 1 - stand/powerpc/ofw/main.c | 1 - stand/powerpc/ofw/ofwfdt.c | 1 - stand/powerpc/ofw/ppc64_elf_freebsd.c | 1 - stand/powerpc/ofw/start.c | 1 - stand/uboot/arch/arm/conf.c | 1 - stand/uboot/arch/powerpc/conf.c | 1 - stand/uboot/arch/powerpc/ppc64_elf_freebsd.c | 1 - stand/uboot/devicename.c | 1 - stand/uboot/reboot.c | 1 - stand/uboot/time.c | 2 -- stand/uboot/uboot_console.c | 1 - stand/uboot/uboot_module.c | 1 - stand/userboot/userboot/autoload.c | 1 - stand/userboot/userboot/biossmap.c | 1 - stand/userboot/userboot/bootinfo.c | 1 - stand/userboot/userboot/bootinfo32.c | 1 - stand/userboot/userboot/bootinfo64.c | 1 - stand/userboot/userboot/conf.c | 1 - stand/userboot/userboot/copy.c | 1 - stand/userboot/userboot/devicename.c | 1 - stand/userboot/userboot/elf64_freebsd.c | 1 - stand/userboot/userboot/host.c | 1 - stand/userboot/userboot/main.c | 1 - stand/userboot/userboot/userboot_cons.c | 1 - stand/userboot/userboot/userboot_disk.c | 1 - 165 files changed, 3 insertions(+), 185 deletions(-) diff --git a/stand/common/boot.c b/stand/common/boot.c index 658da097b9a9..e0775c0fca26 100644 --- a/stand/common/boot.c +++ b/stand/common/boot.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * Loading modules, booting the system */ diff --git a/stand/common/commands.c b/stand/common/commands.c index b09bb9604386..e6e4fd005f72 100644 --- a/stand/common/commands.c +++ b/stand/common/commands.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/common/dev_net.c b/stand/common/dev_net.c index b6880e894477..3cd78c5346ac 100644 --- a/stand/common/dev_net.c +++ b/stand/common/dev_net.c @@ -29,7 +29,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include /*- * This module implements a "raw device" interface suitable for * use by the stand-alone I/O library NFS code. This interface diff --git a/stand/common/devopen.c b/stand/common/devopen.c index a51ebaf0c9d7..a50334ba61e3 100644 --- a/stand/common/devopen.c +++ b/stand/common/devopen.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/common/disk.c b/stand/common/disk.c index e1add50bd1fb..c1650f0fa1ec 100644 --- a/stand/common/disk.c +++ b/stand/common/disk.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/interp.c b/stand/common/interp.c index 0f142902b4ac..c6ac01ea099b 100644 --- a/stand/common/interp.c +++ b/stand/common/interp.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * Simple commandline interpreter, toplevel and misc. * diff --git a/stand/common/interp_backslash.c b/stand/common/interp_backslash.c index 6d650cd2e286..e1bc84c3a1a7 100644 --- a/stand/common/interp_backslash.c +++ b/stand/common/interp_backslash.c @@ -14,7 +14,6 @@ * Routine for doing backslash elimination. */ -#include #include #include #include "bootstrap.h" diff --git a/stand/common/interp_lua.c b/stand/common/interp_lua.c index 11595b78a7bd..aa759aa99ec1 100644 --- a/stand/common/interp_lua.c +++ b/stand/common/interp_lua.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include "bootstrap.h" diff --git a/stand/common/interp_parse.c b/stand/common/interp_parse.c index 6e883a81e383..9efcade04b36 100644 --- a/stand/common/interp_parse.c +++ b/stand/common/interp_parse.c @@ -14,7 +14,6 @@ * The meat of the simple parser. */ -#include #include #include #include "bootstrap.h" diff --git a/stand/common/interp_simple.c b/stand/common/interp_simple.c index 61ed724af9d0..d64c0d27b97f 100644 --- a/stand/common/interp_simple.c +++ b/stand/common/interp_simple.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * Simple commandline interpreter, toplevel and misc. */ diff --git a/stand/common/isapnp.c b/stand/common/isapnp.c index 3f554305c2e2..eaf5a08cf82a 100644 --- a/stand/common/isapnp.c +++ b/stand/common/isapnp.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include /* * Machine-independent ISA PnP enumerator implementing a subset of the * ISA PnP specification. diff --git a/stand/common/load_elf32.c b/stand/common/load_elf32.c index 5b942fd63444..4737670d2eeb 100644 --- a/stand/common/load_elf32.c +++ b/stand/common/load_elf32.c @@ -1,5 +1,3 @@ -#include #define __ELF_WORD_SIZE 32 #define _MACHINE_ELF_WANT_32BIT - #include "load_elf.c" diff --git a/stand/common/load_elf32_obj.c b/stand/common/load_elf32_obj.c index dffb0070b0c0..e37b4dfddb49 100644 --- a/stand/common/load_elf32_obj.c +++ b/stand/common/load_elf32_obj.c @@ -1,5 +1,3 @@ -#include #define __ELF_WORD_SIZE 32 #define _MACHINE_ELF_WANT_32BIT - #include "load_elf_obj.c" diff --git a/stand/common/load_elf64.c b/stand/common/load_elf64.c index e3a913c0ce8c..98ef7dc40985 100644 --- a/stand/common/load_elf64.c +++ b/stand/common/load_elf64.c @@ -1,4 +1,2 @@ -#include #define __ELF_WORD_SIZE 64 - #include "load_elf.c" diff --git a/stand/common/load_elf64_obj.c b/stand/common/load_elf64_obj.c index 14d6e3dc3d4d..43de8cc1214f 100644 --- a/stand/common/load_elf64_obj.c +++ b/stand/common/load_elf64_obj.c @@ -1,4 +1,2 @@ -#include #define __ELF_WORD_SIZE 64 - #include "load_elf_obj.c" diff --git a/stand/common/md.c b/stand/common/md.c index 6b6e6303c898..d12429c3c45c 100644 --- a/stand/common/md.c +++ b/stand/common/md.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/metadata.c b/stand/common/metadata.c index 8d5003ec47bf..f95763bfd01b 100644 --- a/stand/common/metadata.c +++ b/stand/common/metadata.c @@ -26,7 +26,6 @@ * from: FreeBSD: src/sys/boot/sparc64/loader/metadata.c,v 1.6 */ -#include #include #include #include diff --git a/stand/common/misc.c b/stand/common/misc.c index 046094f868e0..402213100951 100644 --- a/stand/common/misc.c +++ b/stand/common/misc.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/module.c b/stand/common/module.c index ac0ad466484a..832a8eb4988d 100644 --- a/stand/common/module.c +++ b/stand/common/module.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * file/module function dispatcher, support, etc. */ diff --git a/stand/common/part.c b/stand/common/part.c index 41c0eef95d7d..5f7bc2103c01 100644 --- a/stand/common/part.c +++ b/stand/common/part.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/pnp.c b/stand/common/pnp.c index 8ee7f5f711b1..aab84e07935d 100644 --- a/stand/common/pnp.c +++ b/stand/common/pnp.c @@ -3,7 +3,6 @@ * */ -#include /* * "Plug and Play" functionality. * diff --git a/stand/common/reloc_elf32.c b/stand/common/reloc_elf32.c index ee2617b371c1..04b4969a51b3 100644 --- a/stand/common/reloc_elf32.c +++ b/stand/common/reloc_elf32.c @@ -1,4 +1,2 @@ -#include #define __ELF_WORD_SIZE 32 - #include "reloc_elf.c" diff --git a/stand/common/reloc_elf64.c b/stand/common/reloc_elf64.c index c7b76ca6b265..1230f27741cd 100644 --- a/stand/common/reloc_elf64.c +++ b/stand/common/reloc_elf64.c @@ -1,4 +1,2 @@ -#include #define __ELF_WORD_SIZE 64 - #include "reloc_elf.c" diff --git a/stand/common/vdisk.c b/stand/common/vdisk.c index 3bbb13d908c5..067e3ca3a481 100644 --- a/stand/common/vdisk.c +++ b/stand/common/vdisk.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/common/zfs_cmd.c b/stand/common/zfs_cmd.c index 9a4dc01f0159..0180d31f374b 100644 --- a/stand/common/zfs_cmd.c +++ b/stand/common/zfs_cmd.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include /* * MD bootstrap main() and assorted miscellaneous * commands. diff --git a/stand/efi/libefi/delay.c b/stand/efi/libefi/delay.c index becdcb3fa267..af03f0075330 100644 --- a/stand/efi/libefi/delay.c +++ b/stand/efi/libefi/delay.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/devicename.c b/stand/efi/libefi/devicename.c index 22844bbbd6ec..c18017429665 100644 --- a/stand/efi/libefi/devicename.c +++ b/stand/efi/libefi/devicename.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/devpath.c b/stand/efi/libefi/devpath.c index 6b4b8785a2dd..85a5459c7d6b 100644 --- a/stand/efi/libefi/devpath.c +++ b/stand/efi/libefi/devpath.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/eficom.c b/stand/efi/libefi/eficom.c index c84e040420e7..d5f3f07e083f 100644 --- a/stand/efi/libefi/eficom.c +++ b/stand/efi/libefi/eficom.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/efienv.c b/stand/efi/libefi/efienv.c index 031c144ee194..83da2acc816b 100644 --- a/stand/efi/libefi/efienv.c +++ b/stand/efi/libefi/efienv.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/efipart.c b/stand/efi/libefi/efipart.c index 475a796b4da5..3df6034571f5 100644 --- a/stand/efi/libefi/efipart.c +++ b/stand/efi/libefi/efipart.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/env.c b/stand/efi/libefi/env.c index 6887038fe950..328476a9f68b 100644 --- a/stand/efi/libefi/env.c +++ b/stand/efi/libefi/env.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/errno.c b/stand/efi/libefi/errno.c index e614824a2bed..92050af7f4e1 100644 --- a/stand/efi/libefi/errno.c +++ b/stand/efi/libefi/errno.c @@ -24,7 +24,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/handles.c b/stand/efi/libefi/handles.c index bc42ae144509..d3ec428b8d4a 100644 --- a/stand/efi/libefi/handles.c +++ b/stand/efi/libefi/handles.c @@ -24,7 +24,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/libefi.c b/stand/efi/libefi/libefi.c index c33c61cdef16..f615bd214bfc 100644 --- a/stand/efi/libefi/libefi.c +++ b/stand/efi/libefi/libefi.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/libefi/time.c b/stand/efi/libefi/time.c index bab8e4f73434..99d86e30ee96 100644 --- a/stand/efi/libefi/time.c +++ b/stand/efi/libefi/time.c @@ -38,7 +38,6 @@ * */ -#include #include #include diff --git a/stand/efi/libefi/time_arm64.c b/stand/efi/libefi/time_arm64.c index 616d05adb806..d3c7a4e236d0 100644 --- a/stand/efi/libefi/time_arm64.c +++ b/stand/efi/libefi/time_arm64.c @@ -28,7 +28,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/time_event.c b/stand/efi/libefi/time_event.c index e6aad64342ce..c4334412a4fe 100644 --- a/stand/efi/libefi/time_event.c +++ b/stand/efi/libefi/time_event.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/libefi/wchar.c b/stand/efi/libefi/wchar.c index d67f1bf34cf8..953f29418c21 100644 --- a/stand/efi/libefi/wchar.c +++ b/stand/efi/libefi/wchar.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/loader/arch/amd64/elf64_freebsd.c b/stand/efi/loader/arch/amd64/elf64_freebsd.c index 5a41ea99867e..91dd979a677e 100644 --- a/stand/efi/loader/arch/amd64/elf64_freebsd.c +++ b/stand/efi/loader/arch/amd64/elf64_freebsd.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #define __ELF_WORD_SIZE 64 #include #include diff --git a/stand/efi/loader/arch/amd64/multiboot2.c b/stand/efi/loader/arch/amd64/multiboot2.c index 6c96d7dc0073..130caa82aa49 100644 --- a/stand/efi/loader/arch/amd64/multiboot2.c +++ b/stand/efi/loader/arch/amd64/multiboot2.c @@ -34,8 +34,6 @@ * https://www.gnu.org/software/grub/manual/multiboot2/multiboot.html */ -#include - #include #include #include diff --git a/stand/efi/loader/arch/amd64/trap.c b/stand/efi/loader/arch/amd64/trap.c index 56a3ee67da6f..95a42a18f719 100644 --- a/stand/efi/loader/arch/amd64/trap.c +++ b/stand/efi/loader/arch/amd64/trap.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/loader/arch/arm64/exec.c b/stand/efi/loader/arch/arm64/exec.c index ef410a7d556c..877cff658d1e 100644 --- a/stand/efi/loader/arch/arm64/exec.c +++ b/stand/efi/loader/arch/arm64/exec.c @@ -24,7 +24,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/efi/loader/autoload.c b/stand/efi/loader/autoload.c index a7a5f8212e9c..ba7997487ffc 100644 --- a/stand/efi/loader/autoload.c +++ b/stand/efi/loader/autoload.c @@ -24,7 +24,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #if defined(LOADER_FDT_SUPPORT) #include #include diff --git a/stand/efi/loader/bootinfo.c b/stand/efi/loader/bootinfo.c index 13b6df9c5b06..b55c2184d9fe 100644 --- a/stand/efi/loader/bootinfo.c +++ b/stand/efi/loader/bootinfo.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/loader/conf.c b/stand/efi/loader/conf.c index 389489726d84..3bc74ea6354c 100644 --- a/stand/efi/loader/conf.c +++ b/stand/efi/loader/conf.c @@ -24,7 +24,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/loader/efi_main.c b/stand/efi/loader/efi_main.c index 25b13d5d3728..2a5120dc89d7 100644 --- a/stand/efi/loader/efi_main.c +++ b/stand/efi/loader/efi_main.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/loader/framebuffer.c b/stand/efi/loader/framebuffer.c index 56693187b576..2f580309c2f3 100644 --- a/stand/efi/loader/framebuffer.c +++ b/stand/efi/loader/framebuffer.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 5944c383574e..12efe594e0e2 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -27,7 +27,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/fdt/fdt_loader_cmd.c b/stand/fdt/fdt_loader_cmd.c index eb152ae1949c..c51e8c5ab583 100644 --- a/stand/fdt/fdt_loader_cmd.c +++ b/stand/fdt/fdt_loader_cmd.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/bio.c b/stand/i386/libi386/bio.c index e3b17ccc2a44..357d6cbedf6e 100644 --- a/stand/i386/libi386/bio.c +++ b/stand/i386/libi386/bio.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include "libi386.h" diff --git a/stand/i386/libi386/biosacpi.c b/stand/i386/libi386/biosacpi.c index fcad64d81549..077b6c7e53de 100644 --- a/stand/i386/libi386/biosacpi.c +++ b/stand/i386/libi386/biosacpi.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/biosdisk.c b/stand/i386/libi386/biosdisk.c index 29cd39e157b8..9ad9b67f5b57 100644 --- a/stand/i386/libi386/biosdisk.c +++ b/stand/i386/libi386/biosdisk.c @@ -25,7 +25,6 @@ * SUCH DAMAGE. */ -#include /* * BIOS disk device handling. * diff --git a/stand/i386/libi386/biosmem.c b/stand/i386/libi386/biosmem.c index eaf41743bb1f..fc612eda5d69 100644 --- a/stand/i386/libi386/biosmem.c +++ b/stand/i386/libi386/biosmem.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * Obtain memory configuration information from the BIOS */ diff --git a/stand/i386/libi386/biospci.c b/stand/i386/libi386/biospci.c index 1003e368043d..5b39eab1e5e5 100644 --- a/stand/i386/libi386/biospci.c +++ b/stand/i386/libi386/biospci.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include /* * PnP enumerator using the PCI BIOS. */ diff --git a/stand/i386/libi386/biospnp.c b/stand/i386/libi386/biospnp.c index a26c0d4d52d8..5b22f066d4ef 100644 --- a/stand/i386/libi386/biospnp.c +++ b/stand/i386/libi386/biospnp.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * PnP BIOS enumerator. */ diff --git a/stand/i386/libi386/biossmap.c b/stand/i386/libi386/biossmap.c index a2ad83cafdba..c281e6949c20 100644 --- a/stand/i386/libi386/biossmap.c +++ b/stand/i386/libi386/biossmap.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * Obtain memory configuration information from the BIOS */ diff --git a/stand/i386/libi386/bootinfo.c b/stand/i386/libi386/bootinfo.c index 4f652632b755..b81d181a75bd 100644 --- a/stand/i386/libi386/bootinfo.c +++ b/stand/i386/libi386/bootinfo.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/bootinfo32.c b/stand/i386/libi386/bootinfo32.c index 1b038ff6b245..535849011b6b 100644 --- a/stand/i386/libi386/bootinfo32.c +++ b/stand/i386/libi386/bootinfo32.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/bootinfo64.c b/stand/i386/libi386/bootinfo64.c index 2a62eba4fc09..a55b86eb5ba7 100644 --- a/stand/i386/libi386/bootinfo64.c +++ b/stand/i386/libi386/bootinfo64.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/comconsole.c b/stand/i386/libi386/comconsole.c index 6fff811bd34c..b2d48b13a9f4 100644 --- a/stand/i386/libi386/comconsole.c +++ b/stand/i386/libi386/comconsole.c @@ -23,7 +23,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/devicename.c b/stand/i386/libi386/devicename.c index c6125ba7a78b..628b969ad132 100644 --- a/stand/i386/libi386/devicename.c +++ b/stand/i386/libi386/devicename.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #include #include #include "bootstrap.h" diff --git a/stand/i386/libi386/elf64_freebsd.c b/stand/i386/libi386/elf64_freebsd.c index da034437c6e0..b1340fd1f2e2 100644 --- a/stand/i386/libi386/elf64_freebsd.c +++ b/stand/i386/libi386/elf64_freebsd.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include #define __ELF_WORD_SIZE 64 #include #include diff --git a/stand/i386/libi386/i386_copy.c b/stand/i386/libi386/i386_copy.c index 3fcf9d09b280..44ca51f6b2ae 100644 --- a/stand/i386/libi386/i386_copy.c +++ b/stand/i386/libi386/i386_copy.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * MD primitives supporting placement of module data * diff --git a/stand/i386/libi386/i386_module.c b/stand/i386/libi386/i386_module.c index 8c6300b3ad98..26f2ed3eec40 100644 --- a/stand/i386/libi386/i386_module.c +++ b/stand/i386/libi386/i386_module.c @@ -24,7 +24,6 @@ * SUCH DAMAGE. */ -#include /* * i386-specific module functionality. * diff --git a/stand/i386/libi386/nullconsole.c b/stand/i386/libi386/nullconsole.c index b39e52630c9d..b4ffd3e30789 100644 --- a/stand/i386/libi386/nullconsole.c +++ b/stand/i386/libi386/nullconsole.c @@ -35,7 +35,6 @@ * OF SUCH DAMAGE. */ -#include #include #include diff --git a/stand/i386/libi386/pread.c b/stand/i386/libi386/pread.c index 854f28068ab0..5a922e3bfc6b 100644 --- a/stand/i386/libi386/pread.c +++ b/stand/i386/libi386/pread.c @@ -33,7 +33,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include /* read into destination in flat addr space */ #include diff --git a/stand/i386/libi386/pxe.c b/stand/i386/libi386/pxe.c index 895e8fc5ff51..aa392b83718c 100644 --- a/stand/i386/libi386/pxe.c +++ b/stand/i386/libi386/pxe.c @@ -26,7 +26,6 @@ * SUCH DAMAGE. */ -#include #include #include #include diff --git a/stand/i386/libi386/spinconsole.c b/stand/i386/libi386/spinconsole.c index 05ce33bfc5a8..156eaf35e1c0 100644 *** 1185 LINES SKIPPED *** From nobody Tue Apr 16 20:13:12 2024 X-Original-To: dev-commits-src-branches@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 4VJwG13G9dz5H0Y7; Tue, 16 Apr 2024 20:13:13 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG114yfz4tlZ; Tue, 16 Apr 2024 20:13:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298393; 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=8HNScYlRtGhaGUdy8vjsud3PkqlyNUv4k25Xfy7Vb9A=; b=VlLbzY7F7kRNsDN6NTcTRx3FsLh5Nx2J92RC86PNiGpFGT11fyt0UttG22z5+xv/DyQ/4q 48WXbxoSXWL+E06PmqrTvsDOQZladsj2FcBsAydecXAOUpWzq7305nOaLSXrwJ8OmhUOB4 GCV62yVzQNaZDmtG2Izo7jIEtTltThzRgzQr4g/kvwKb2dokvfpLPc/svWPtDlyxN2phCE XqG3JKssuE4vKGfUn2/8ca7cXCDOKFgyPhtn7UHWNawwoeMb/okUSEO6bjS+EEZokh+BwF pN3RoSVKU3g+0IaIxPSTFLMjynuah3mPRC8OrWm/WKT7OjSJrrbN3nui//Zy2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298393; a=rsa-sha256; cv=none; b=Cr6P5nURsJi3+q8jR9953jp9BC4XsP0K7BZJKXWgLSbJGKbHBhoOW3BH7RsadkMBtn7xhv X5Q/cXM9kF/ZpFrJiQ5yZI60yf4+LNpJWkzP5SkjylEgSGiHEcltwWWEhxd+IhOfXDH5t+ EBwWimPvCnkiyvdtpsMTFBiMpm+2nRh4nPncTbJXblIe7NomnaVMIgEV9wGgJGba5AL10+ S5B8ma0kaZ5f8hVfb+Wi66HHxav0HGaDdEhiKgw64NPtubGWpcoXifuY9MwACqvyGG9yPp dm4JlcXx60NiYjQUlY/SD0IbBpAetIyRtiRx71S/NZaMXGMiYo+D43z0StQ8eg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298393; 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=8HNScYlRtGhaGUdy8vjsud3PkqlyNUv4k25Xfy7Vb9A=; b=wYboyOSrr25QygjsiYN+Qm5sxufFRpjHJp5vEd+4vzSTR3OO4uSfPhuNdXwh7bytqqAdD0 AHOT+63VRJcynuvwhy/qegPTbgXZqwpGEUVGmLtd8enc7F0cmk1njD6/sxELK/Pk+uEQE/ Zs7WkEc6iTxXlNa1Fz9MjjD0ZifO+Mv4CX3h9nd2tmje5dO7LUx34aFTutgEgM8yKB8MZM lTO8dW1ULJSYiKx7g5tBdSkz2KTwERTeFQOuluvRFK/1HDZi7Eo/MsILjZY8e4ASXvD/YR +Ee57egXUWsGFXcHrA6FTe/PRLrtRFrgG/TqrKyfQCxvHkY5Qb/a+4P+hcVzjw== 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 4VJwG10XBxzxJW; Tue, 16 Apr 2024 20:13:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDCqg039017; Tue, 16 Apr 2024 20:13:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDCgD039014; Tue, 16 Apr 2024 20:13:12 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:12 GMT Message-Id: <202404162013.43GKDCgD039014@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 204a5c85ab2a - stable/14 - loader: rename gfx_interp_md to gfx_interp_ref List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 204a5c85ab2af888ed852dedc9b4c9aae93dfd13 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=204a5c85ab2af888ed852dedc9b4c9aae93dfd13 commit 204a5c85ab2af888ed852dedc9b4c9aae93dfd13 Author: Warner Losh AuthorDate: 2024-02-24 04:22:08 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader: rename gfx_interp_md to gfx_interp_ref We have the call to gfx_interp_ref to bring in the .o so that we get the linker set item to add the language bindings at the right time. Where we call it is not the right time... So the _ref name is better. Change it before we have too many others like it. Sponsored by: Netflix (cherry picked from commit 6faf55c86d9b86f40de8d19970e42cb42a892c47) --- stand/common/gfx_fb.c | 2 +- stand/common/gfx_fb.h | 2 +- stand/common/interp_simple.c | 2 +- stand/ficl/gfx_loader.c | 2 +- stand/liblua/gfx_utils.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/stand/common/gfx_fb.c b/stand/common/gfx_fb.c index 3a5b851915e0..0a88a166089b 100644 --- a/stand/common/gfx_fb.c +++ b/stand/common/gfx_fb.c @@ -181,7 +181,7 @@ gfx_framework_init(void) * Setup font list to have builtin font. */ (void) insert_font(NULL, FONT_BUILTIN); - gfx_interp_md(); /* Draw in the gfx interpreter for this thing */ + gfx_interp_ref(); /* Draw in the gfx interpreter for this thing */ } static uint8_t * diff --git a/stand/common/gfx_fb.h b/stand/common/gfx_fb.h index 84062864c57f..17e419d8ffd3 100644 --- a/stand/common/gfx_fb.h +++ b/stand/common/gfx_fb.h @@ -281,7 +281,7 @@ void term_image_display(teken_gfx_t *, const teken_rect_t *); void reset_font_flags(void); -void gfx_interp_md(void); +void gfx_interp_ref(void); #ifdef __cplusplus } diff --git a/stand/common/interp_simple.c b/stand/common/interp_simple.c index d64c0d27b97f..d675da0aa61e 100644 --- a/stand/common/interp_simple.c +++ b/stand/common/interp_simple.c @@ -202,6 +202,6 @@ interp_include(const char *filename) * There's no graphics commands for the simple interpreter. */ void -gfx_interp_md(void) +gfx_interp_ref(void) { } diff --git a/stand/ficl/gfx_loader.c b/stand/ficl/gfx_loader.c index a4501a7d3c39..4ac69e3c9895 100644 --- a/stand/ficl/gfx_loader.c +++ b/stand/ficl/gfx_loader.c @@ -254,6 +254,6 @@ static void ficlCompileGfx(FICL_SYSTEM *pSys) FICL_COMPILE_SET(ficlCompileGfx); void -gfx_interp_md(void) +gfx_interp_ref(void) { } diff --git a/stand/liblua/gfx_utils.c b/stand/liblua/gfx_utils.c index 8d2aaacbd688..301cd9cb8610 100644 --- a/stand/liblua/gfx_utils.c +++ b/stand/liblua/gfx_utils.c @@ -242,7 +242,7 @@ luaopen_gfx(lua_State *L) } void -gfx_interp_md(void) +gfx_interp_ref(void) { } From nobody Tue Apr 16 20:13:11 2024 X-Original-To: dev-commits-src-branches@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 4VJwG02K7Hz5H0fL; Tue, 16 Apr 2024 20:13:12 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwFz70PZz4tnM; Tue, 16 Apr 2024 20:13:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298392; 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=9j14Qq6v7IiYZhXWjiGytearT0dz8hy5JKMRgMl5cH8=; b=rBO9p2K8bvQPym6FkzkHNrDnU3OPZRwHfzZQA8Mnu7Z+4REPuJq7SWglaSKq8RKVHueow9 TpSM4TBV1/YEDEHoWmTGSQVdF++HTKaIYemRLb4VVKL1acN70rA2lhPst82Ub0o0Pb8nX2 BJRk/3l+78ckuSKrkW6L2O3QCwwSd0ah//xUxGMGdUsqtj5lqH0yk7RO9P+obaVRfdzHkW 2R6YgMYzLRqBjPiyhCUUE7x4JRwnKJoKhctU9QV//HvPmhoh0S7wzSd0Vm1fjHOiGycizq FI5XokDVHMnEYXZm2jY0TJqW9w6nj9PKB83opawcdHeAxHM1fIAOzmwlid1Rfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298392; a=rsa-sha256; cv=none; b=NFh1b8eCUZigXp4Lq5IFbSvGXjgUOq23gTqmYM7JHru6cEHsoeVsYoFsLF3njj5FwxjbjR qfrvbazNDjPffLxsl7Y0sxJL8NTi0ecM/iim4U/NDjHQtWtAytZdBmmQutBwUN4uwKvdMR ZqEz5Le8g7ILxEBSJVbWij96j+KA+dIS06tOVeTasvh8napp0YJPD6ApHSoc/Q2Sd1UsSZ 8alWK7AKnG+fB53yefXy0oHA99Jm5Culyp6xD/ICJGWMn6x8OfkYggaHFL34Sr7LHwoolf v+2WHNDaNNfTx+LLXUdoW1BPVMtCPxessqK9LSzpZtjZT2FBzy24cXQxMPUtlg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298392; 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=9j14Qq6v7IiYZhXWjiGytearT0dz8hy5JKMRgMl5cH8=; b=p9ulO7jn+WkryTCNndtPFBJyhvTwjbNGUWML4hI5pzpBAL7FPTEpJo61bQUKHdeoLupZ+u 3/OAkeZJ0XGhbchIE8Ux9+gIDgwUKwdhTn89udqy2I2mGd2H0AvXOq8REKZF6lgYqXN8sJ acdWgmyvFBTR5bKLz7ApJhsOkt/00EV2He5ucREKxS779YvgaT7DUycoscquKUm6aESAY0 Klk0VU3lN2L1ZE5xq7TAWTYhwAT1hVu0Z2yK+EyspR+Si7ljU8PqVrzMBqmm15pULmTIPr Iib/mIi8/KjU6kfcmcFofnvXtjwH/zEhwMYDxesaN+jb8G+fpLJ0x1Nn3ImFpQ== 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 4VJwFz6cpczxPS; Tue, 16 Apr 2024 20:13:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDBfC038971; Tue, 16 Apr 2024 20:13:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDBRI038968; Tue, 16 Apr 2024 20:13:11 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:11 GMT Message-Id: <202404162013.43GKDBRI038968@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: bcb0e17d35fb - stable/14 - loader: These files have no copyrightable material List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bcb0e17d35fb475128d9ad1840c85b188ab0ed5e Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=bcb0e17d35fb475128d9ad1840c85b188ab0ed5e commit bcb0e17d35fb475128d9ad1840c85b188ab0ed5e Author: Warner Losh AuthorDate: 2024-02-22 16:30:59 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:26 +0000 loader: These files have no copyrightable material These files have no copyrightable material, and so are in the public domain. Sponsored by: Netflix (cherry picked from commit 27c0f2a544989760c4b3b16a3615839c8ab44b32) --- stand/common/load_elf32.c | 2 ++ stand/common/load_elf32_obj.c | 2 ++ stand/common/load_elf64.c | 2 ++ stand/common/load_elf64_obj.c | 2 ++ 4 files changed, 8 insertions(+) diff --git a/stand/common/load_elf32.c b/stand/common/load_elf32.c index 4737670d2eeb..4ecdeb773228 100644 --- a/stand/common/load_elf32.c +++ b/stand/common/load_elf32.c @@ -1,3 +1,5 @@ +/* This file is in the public domain */ + #define __ELF_WORD_SIZE 32 #define _MACHINE_ELF_WANT_32BIT #include "load_elf.c" diff --git a/stand/common/load_elf32_obj.c b/stand/common/load_elf32_obj.c index e37b4dfddb49..d0278930f5e4 100644 --- a/stand/common/load_elf32_obj.c +++ b/stand/common/load_elf32_obj.c @@ -1,3 +1,5 @@ +/* This file is in the public domain */ + #define __ELF_WORD_SIZE 32 #define _MACHINE_ELF_WANT_32BIT #include "load_elf_obj.c" diff --git a/stand/common/load_elf64.c b/stand/common/load_elf64.c index 98ef7dc40985..d55f139d1e6a 100644 --- a/stand/common/load_elf64.c +++ b/stand/common/load_elf64.c @@ -1,2 +1,4 @@ +/* This file is in the public domain */ + #define __ELF_WORD_SIZE 64 #include "load_elf.c" diff --git a/stand/common/load_elf64_obj.c b/stand/common/load_elf64_obj.c index 43de8cc1214f..0f01258fa372 100644 --- a/stand/common/load_elf64_obj.c +++ b/stand/common/load_elf64_obj.c @@ -1,2 +1,4 @@ +/* This file is in the public domain */ + #define __ELF_WORD_SIZE 64 #include "load_elf_obj.c" From nobody Tue Apr 16 20:13:14 2024 X-Original-To: dev-commits-src-branches@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 4VJwG24PP9z5H0T4; Tue, 16 Apr 2024 20:13:14 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG21k2mz4v1p; Tue, 16 Apr 2024 20:13:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298394; 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=WknelCd620ggGRmxoVTRXKzdsLqHBTQZL5KX17+uyAQ=; b=roiubT4CNz7or5BdFuPd98RTGCfg1HPWVRP7vJ7kvJ4MJfB0Ihc2AopIIPBozWnJT/gCzw Kj7LvKwP2aYzyhNmcnod8kPQRV5FFAdz0OVKQV1n0kbQsLhBbu96KoS/vQaqFHRTedgUqp zvTldfSZz9qO+8pNOaa68Plud5iqOaPkgls39pG/49uIc7uxdq7Meb505ytKMlJcOQDhG+ kUixlR9ccQA/N/gVz1JTt1l3eGjGXVBUhZZEDmLApzKV00Zg7OySMxw5+fe//JpbX+upPw /J2rl34vduF1YM4f6vv3khWAm1sQA6jqx+l1+fq/SL6QV2B5we1UlB95netibg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298394; a=rsa-sha256; cv=none; b=ZsTbU/Kz93+KfhH6pqAB8CeO8MIL/FXeWkcf39Tt4Uutqo7OQcd0Jo2wgnxrDVJIkRugZ2 a0mdpKUwI2b3MeDzUfReb8k4PszE2PHDgYsR8aSEWP2IhHxKkwEMheCFwxAd76BcI4mBVy gKKMkcVsPJQWHX0Rr1SwZs5XTCzKS3fcUt0k2cSTS/m1YRY9tdwmBy5jOlOsZIg0oBb97Z Qdkb6axETilOhqs1fY+NF20xCN8TP81pHjq2QuL4SjKCN0uCRkMfpyBqUo7ZJABmE/3aYi OuzX+rKspFUnfLSiD0+tInfaO+XE23ZCYIUypjMVI5wKiIVe6cr1NZqt9zpOvQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298394; 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=WknelCd620ggGRmxoVTRXKzdsLqHBTQZL5KX17+uyAQ=; b=gy8ZtrvYVWiW2Wr46nUhDDo0jhcLRGLZXClOGw6kX7j7Is9/t60fcyHqbdHGhAjE4hbgmQ deTlCXdpNDjwysh0CpQ1qRSOOPxRIXUgHDag0qve2/36zlXfZ3dJvi8mvxN/58IBMHoSHJ dbusZ4Se1dWpb0gCN5GcnnMd/shTujkHj1uTpMfLfsDaZeY3GpJjKqvHItC8v0+HHZCAWK Zo2T+gS91j8fYB5b8Z6bIwc4MelqwWAMfHI69QFGRAbyuXHxWjUP0xSLPDGbAEY9ShCNxv WnS+J9w65Tj+w+HvAYfPPiJnWlOR2YqIpkn/KpmdmofiSzTkd5vA28tdJuPqxQ== 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 4VJwG21C1dzxdj; Tue, 16 Apr 2024 20:13:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDEqu039074; Tue, 16 Apr 2024 20:13:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDExX039071; Tue, 16 Apr 2024 20:13:14 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:14 GMT Message-Id: <202404162013.43GKDExX039071@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 5f4d3f8e8835 - stable/14 - loader: Move ldscripts to match more standard practices List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5f4d3f8e88354c97b1153998e728f132548886b3 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5f4d3f8e88354c97b1153998e728f132548886b3 commit 5f4d3f8e88354c97b1153998e728f132548886b3 Author: Warner Losh AuthorDate: 2024-02-25 00:56:14 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader: Move ldscripts to match more standard practices In the larger open source community, ld scripts are foo.ldscrpt rather than ldscript.arch like we use here. This moves the EFI ldscripts. Sponsored by: Netflix Reviewed by: tsoome, kevans, emaste Differential Revision: https://reviews.freebsd.org/D44056 (cherry picked from commit 5b3b9a58584b101e3ea0fd8dd50dc8d9157c058e) --- stand/efi/boot1/Makefile | 2 +- stand/efi/loader/Makefile | 2 +- stand/efi/loader/arch/amd64/{ldscript.amd64 => amd64.ldscript} | 0 stand/efi/loader/arch/arm/{ldscript.arm => arm.ldscript} | 0 stand/efi/loader/arch/arm64/{ldscript.arm64 => arm64.ldscript} | 0 stand/efi/loader/arch/riscv/{ldscript.riscv => riscv.ldscript} | 0 6 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/efi/boot1/Makefile b/stand/efi/boot1/Makefile index e03b95d2276f..fd5069004dff 100644 --- a/stand/efi/boot1/Makefile +++ b/stand/efi/boot1/Makefile @@ -64,7 +64,7 @@ CFLAGS+= -I${LDRSRC} FILES= ${BOOT1}.efi FILESMODE_${BOOT1}.efi= ${BINMODE} -LDSCRIPT= ${EFISRC}/loader/arch/${MACHINE}/ldscript.${MACHINE} +LDSCRIPT= ${EFISRC}/loader/arch/${MACHINE}/${MACHINE}.ldscript LDFLAGS+= -Wl,-T${LDSCRIPT},-Bsymbolic,-znotext -pie .if ${LINKER_TYPE} == "bfd" && ${LINKER_VERSION} >= 23400 LDFLAGS+= -Wl,--no-dynamic-linker diff --git a/stand/efi/loader/Makefile b/stand/efi/loader/Makefile index 5a755c1d329f..2031400814e9 100644 --- a/stand/efi/loader/Makefile +++ b/stand/efi/loader/Makefile @@ -100,7 +100,7 @@ FILESMODE_${LOADER}.efi= ${BINMODE} LINKS+= ${BINDIR}/${LOADER}.efi ${BINDIR}/loader.efi .endif -LDSCRIPT= ${.CURDIR}/../loader/arch/${MACHINE}/ldscript.${MACHINE} +LDSCRIPT= ${.CURDIR}/../loader/arch/${MACHINE}/${MACHINE}.ldscript LDFLAGS+= -Wl,-T${LDSCRIPT},-Bsymbolic,-znotext -pie .if ${LINKER_TYPE} == "bfd" && ${LINKER_VERSION} >= 23400 LDFLAGS+= -Wl,--no-dynamic-linker diff --git a/stand/efi/loader/arch/amd64/ldscript.amd64 b/stand/efi/loader/arch/amd64/amd64.ldscript similarity index 100% rename from stand/efi/loader/arch/amd64/ldscript.amd64 rename to stand/efi/loader/arch/amd64/amd64.ldscript diff --git a/stand/efi/loader/arch/arm/ldscript.arm b/stand/efi/loader/arch/arm/arm.ldscript similarity index 100% rename from stand/efi/loader/arch/arm/ldscript.arm rename to stand/efi/loader/arch/arm/arm.ldscript diff --git a/stand/efi/loader/arch/arm64/ldscript.arm64 b/stand/efi/loader/arch/arm64/arm64.ldscript similarity index 100% rename from stand/efi/loader/arch/arm64/ldscript.arm64 rename to stand/efi/loader/arch/arm64/arm64.ldscript diff --git a/stand/efi/loader/arch/riscv/ldscript.riscv b/stand/efi/loader/arch/riscv/riscv.ldscript similarity index 100% rename from stand/efi/loader/arch/riscv/ldscript.riscv rename to stand/efi/loader/arch/riscv/riscv.ldscript From nobody Tue Apr 16 20:13:15 2024 X-Original-To: dev-commits-src-branches@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 4VJwG36YBTz5H0YB; Tue, 16 Apr 2024 20:13:15 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG32KJZz4tys; Tue, 16 Apr 2024 20:13:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298395; 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=qQldRLWotCxK5RWNC4bp8kzX/GmkBOoKKy+EAifyAeQ=; b=kF4gsS3zIpMZ0RfTG7vyZTT8Kf7Q6f+AHMyBJuO06lcxQAC1jJKhi4/XARzQZzfYYkFW8A i47WLdsiBGhAk7inqDL6+LpSQGUMOfqLbegW9fKxWWPjACjjm8CO6ly3MEG99j1/ZQGSnG yASxt469tIo5+uMoF3y976R6N1UWn3MzUKihVOu1m5C0P/E4PLuFTi4ML6Yi0l5fViH6ew /5mYWhQOarrOn6M7c4GM5MwEYA99yPwc0FUBgInD+d0fqzj9myw42uQE5e2roTUAeI21nq jxhtkNqc4FQLrRxnNhk5pIX2Ks56TsQhufSw1FqhxVs39M2eDRMUh83urfuhTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298395; a=rsa-sha256; cv=none; b=a9MTNQgCg3zaJfowefFJDixcGH/JxpC7pFfkHZ94CBhXERLDzOzlpCm36pk+W9EYULTrLz xXnvfq1TpVnsDC/gQxVgRCWmsKGxZpKd2ItnARIUoud/W9mERjCzOtzISrUecW9SIDZrdS xFmTqXAiSbNxMWThDJl1Uebs+a2MAFS0W+hat9WBDoIZon9KxYum581jW0sp3oBD82T9uE VfOib/GIrtpg3jkwk8H6f6k88tkqzJXOE1fQswDjL/ZTznpcjK0DUPy/ZgsHwpriyOw8Pm zqoAOfJ6SMcM63JSwgN+QRw/NHceP+Lovh/ugYhy+SEbNvWZ90rNKk4g5sxGug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298395; 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=qQldRLWotCxK5RWNC4bp8kzX/GmkBOoKKy+EAifyAeQ=; b=yMFcYCNV2Q7tZonGf5kuIVAaa050MCYDt5i+vUxywE+2G3OxTsNoHvpKVQXrq16LdeqX9l wGCgnM6T1pMaT0bAvDyRIFh50BF/0d4VDHOoDO2OZCQI2fBUiloibgeIkXC8ImZ7ieduV6 ERxWFt9iT8D0kDDKCqxk90rskkr5dJEl4PFQa1gXS3LcicJsjhDjsX2SngX8s5S3fv8ts0 +RryAzqc3hhtyVHoXTJb8OVb/fSSiZUY4x0NNGZ8jhApMG1Fbc34JiIljozUxV7Y1AYUZl rlRenc/wChsF71wTv4mdxEGbu4dB4o1AKvuhwVRQbG9H/513TsRAYnoIouhijg== 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 4VJwG31tgwzxdk; Tue, 16 Apr 2024 20:13:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDF8R039117; Tue, 16 Apr 2024 20:13:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDFnn039114; Tue, 16 Apr 2024 20:13:15 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:15 GMT Message-Id: <202404162013.43GKDFnn039114@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 95497a6215e8 - stable/14 - kboot: Centralize ldscript addition List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 95497a6215e81ac3515bd034dfa5db4346147ba1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=95497a6215e81ac3515bd034dfa5db4346147ba1 commit 95497a6215e81ac3515bd034dfa5db4346147ba1 Author: Warner Losh AuthorDate: 2024-02-25 00:56:23 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 kboot: Centralize ldscript addition Make the pattern for ldscripts always be arch/$MACHINE_ARCH/$MACHINE_ARCH.ldscript so we can add it from a central Makefile. This also moves from ldscript.arch to arch.ldscript to match the loader's new convention. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44057 (cherry picked from commit acb474c084b8e3b7bb738a286f9218f926a15823) --- stand/kboot/kboot/Makefile | 3 +++ stand/kboot/kboot/arch/aarch64/Makefile.inc | 2 -- stand/kboot/kboot/arch/aarch64/{ldscript.aarch64 => aarch64.ldscript} | 0 stand/kboot/kboot/arch/amd64/Makefile.inc | 2 -- stand/kboot/kboot/arch/amd64/{ldscript.amd64 => amd64.ldscript} | 0 stand/kboot/kboot/arch/powerpc64/Makefile.inc | 2 -- .../kboot/arch/powerpc64/{ldscript.powerpc => powerpc64.ldscript} | 0 7 files changed, 3 insertions(+), 6 deletions(-) diff --git a/stand/kboot/kboot/Makefile b/stand/kboot/kboot/Makefile index b571c3acada1..c6cb47fbbba2 100644 --- a/stand/kboot/kboot/Makefile +++ b/stand/kboot/kboot/Makefile @@ -51,6 +51,9 @@ HELP_FILENAME= loader.help.kboot .PATH: ${.CURDIR}/arch/${MACHINE_ARCH} .include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" +# Bring in our ldscript +LDFLAGS= -nostdlib -static -T ${.CURDIR}/arch/${MACHINE_ARCH}/${MACHINE_ARCH}.ldscript + # Always add MI sources .include "${BOOTSRC}/loader.mk" CFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} diff --git a/stand/kboot/kboot/arch/aarch64/Makefile.inc b/stand/kboot/kboot/arch/aarch64/Makefile.inc index 744a15f363d3..3e856f5322b3 100644 --- a/stand/kboot/kboot/arch/aarch64/Makefile.inc +++ b/stand/kboot/kboot/arch/aarch64/Makefile.inc @@ -8,5 +8,3 @@ CFLAGS+= -I${SYSDIR}/contrib/dev/acpica/include # load address. set in linker script RELOC?= 0x0 CFLAGS+= -DRELOC=${RELOC} - -LDFLAGS= -nostdlib -static -T ${.CURDIR}/arch/${MACHINE_ARCH}/ldscript.${MACHINE_ARCH} diff --git a/stand/kboot/kboot/arch/aarch64/ldscript.aarch64 b/stand/kboot/kboot/arch/aarch64/aarch64.ldscript similarity index 100% rename from stand/kboot/kboot/arch/aarch64/ldscript.aarch64 rename to stand/kboot/kboot/arch/aarch64/aarch64.ldscript diff --git a/stand/kboot/kboot/arch/amd64/Makefile.inc b/stand/kboot/kboot/arch/amd64/Makefile.inc index 55b1819ccdee..edb8a1de0bba 100644 --- a/stand/kboot/kboot/arch/amd64/Makefile.inc +++ b/stand/kboot/kboot/arch/amd64/Makefile.inc @@ -1,5 +1,3 @@ SRCS+= amd64_tramp.S elf64_freebsd.c load_addr.c fdt_arch.c CFLAGS+= -I${SYSDIR}/contrib/dev/acpica/include - -LDFLAGS= -nostdlib -static -T ${.CURDIR}/arch/${MACHINE_ARCH}/ldscript.amd64 diff --git a/stand/kboot/kboot/arch/amd64/ldscript.amd64 b/stand/kboot/kboot/arch/amd64/amd64.ldscript similarity index 100% rename from stand/kboot/kboot/arch/amd64/ldscript.amd64 rename to stand/kboot/kboot/arch/amd64/amd64.ldscript diff --git a/stand/kboot/kboot/arch/powerpc64/Makefile.inc b/stand/kboot/kboot/arch/powerpc64/Makefile.inc index 338d1222ab65..11a67a93d9e0 100644 --- a/stand/kboot/kboot/arch/powerpc64/Makefile.inc +++ b/stand/kboot/kboot/arch/powerpc64/Makefile.inc @@ -2,6 +2,4 @@ CFLAGS+= -mcpu=powerpc64 SRCS+= ppc64_elf_freebsd.c kerneltramp.S load_addr.c fdt_arch.c -LDFLAGS= -nostdlib -static -T ${.CURDIR}/arch/${MACHINE_ARCH}/ldscript.powerpc - MK_PIE= no diff --git a/stand/kboot/kboot/arch/powerpc64/ldscript.powerpc b/stand/kboot/kboot/arch/powerpc64/powerpc64.ldscript similarity index 100% rename from stand/kboot/kboot/arch/powerpc64/ldscript.powerpc rename to stand/kboot/kboot/arch/powerpc64/powerpc64.ldscript From nobody Tue Apr 16 20:13:16 2024 X-Original-To: dev-commits-src-branches@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 4VJwG45tl2z5H0ky; Tue, 16 Apr 2024 20:13:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG43VF5z4v08; Tue, 16 Apr 2024 20:13:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298396; 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=PYeyomW0KEdUw74okMnxdKZ1ZbK3BHJfMQVeFsouaPU=; b=hDbQVdpAhE2DseQm9LZ0NFsZ/L8htQ7zAAA16NyunuldzkEsCGa7+FfYorqiwc6uUpEBH/ f9ZNC0uxDu+CyZ71UfIFsqfYl3ZXpqyU9dYgu9XL/ZCWk+YnwNZGl28Sg+CdStJx1Egvhr epMende+G4QE4HJWOGkryt0eWXgufevPtFLKinIpAMIVM/hUEgLqPOlKkQ+jspwiYVTjUQ GQOtQtjAdaMRLTH15N/xVbYcNU8UYhjm5E6YcPcYhfPyEq4kjWENE9XyA+PsoAMEqAO/Uw xnaySyvFX50UGiZDIQuDmH6OR5QtIAVbXf8x4YEt6ZwYIoPcIahXxdRnbWsS0w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298396; a=rsa-sha256; cv=none; b=ZxmMfy5kVD7/Ek7/vIXVWosxqALA/OaD0sUJC6slNtFqM+OkDafAElRgyW27meRTnK2ua5 J4ly7CKoH2pqQxk2u9bo1k6mWdm3SZm2ayPSa9J8/qc4pnY2WV16yRxDHw8oRzek7Y9jdY nhqw6wCGi267YlOrlLBnDi8hWo+CVuAP+ofT5bxo3xmlqG03L00+FpCzkbZF8CpwHaDqft IYHJ+QhSGarxAAUBLCmq2JJkqAcxDWdvBCsxHYoOM++BUJxZG0+LZCWUab7W5tzDi+Igyk ynO7b5nBkdXauKP5gy7UA6lkbIt0uNvbLbcyhJqZqqItBaxO1T0fUbHJGKAusA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298396; 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=PYeyomW0KEdUw74okMnxdKZ1ZbK3BHJfMQVeFsouaPU=; b=NUl1Tswnr6/NzDXvg4ebB6LDYr55VuV5BHfKb4X4FIz2DxAzqd80yFP1tEgrstBQwC07Ki D7OHQYdNYBE9Hss/fGQRidh0JAeBgKqHraPoOxI6E8/DP8S51OAfI+rX0yW7YJuodrbHqC WEciTGakGUas2T6B+5hAkNA3t3AhBmIVUxqCtbcNzFEXfpbYXa4iVBDQoYbPKl7P3tE6pJ ZeM9Basq+YbVipWelSgZBWn6nCgjHKQhhhwjLNDy3Pdj9kQz1pZrGMG8FoP7i4xuehOAFz hYBLEFH/gBeLTMgmCzipC9XmX+0Ef22lt3QNkBFRonJwyzSxGVDnUGq18GqOUA== 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 4VJwG42x9VzxJX; Tue, 16 Apr 2024 20:13:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDGBN039153; Tue, 16 Apr 2024 20:13:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDGbw039150; Tue, 16 Apr 2024 20:13:16 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:16 GMT Message-Id: <202404162013.43GKDGbw039150@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 36653c3faa5d - stable/14 - loader/powerpc: Share ldscript List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 36653c3faa5dc7dc1efee62301e8c354cc3f9e61 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=36653c3faa5dc7dc1efee62301e8c354cc3f9e61 commit 36653c3faa5dc7dc1efee62301e8c354cc3f9e61 Author: Warner Losh AuthorDate: 2024-02-25 00:56:31 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader/powerpc: Share ldscript Share ldscript between the different ppc versions. There's two different scripts since we build 32-bit binaries for all types of powerpc, but have little endian and big endian variations that are different by only two lines. Set the output format and include the rest. Move to foo.ldscript as well. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44058 (cherry picked from commit fe4ab1fdb0da06ddfbd8bf168db9f91b66609253) --- stand/powerpc/ofw/Makefile | 6 +- stand/powerpc/ofw/ldscript.powerpcle | 142 --------------------- stand/powerpc/ofw/powerpc.ldscript | 3 + stand/powerpc/ofw/powerpc64.ldscript | 3 + stand/powerpc/ofw/powerpc64le.ldscript | 3 + stand/powerpc/ofw/powerpcspe.ldscript | 3 + .../ofw/{ldscript.powerpc => ppc-common.ldscript} | 3 - 7 files changed, 13 insertions(+), 150 deletions(-) diff --git a/stand/powerpc/ofw/Makefile b/stand/powerpc/ofw/Makefile index b7cbbd9fca00..80ebaf486296 100644 --- a/stand/powerpc/ofw/Makefile +++ b/stand/powerpc/ofw/Makefile @@ -47,11 +47,7 @@ CFLAGS+= -DRELOC=${RELOC} -g LDFLAGS= -nostdlib -static -.if ${MACHINE_ARCH} == "powerpc64le" -LDFLAGS+= -T ${.CURDIR}/ldscript.powerpcle -.else -LDFLAGS+= -T ${.CURDIR}/ldscript.powerpc -.endif +LDFLAGS+= -L ${.CURDIR} -T ${.CURDIR}/${MACHINE_ARCH}.ldscript # Open Firmware standalone support library LIBOFW= ${BOOTOBJ}/libofw/libofw.a diff --git a/stand/powerpc/ofw/ldscript.powerpcle b/stand/powerpc/ofw/ldscript.powerpcle deleted file mode 100644 index 946e3dd48ae9..000000000000 --- a/stand/powerpc/ofw/ldscript.powerpcle +++ /dev/null @@ -1,142 +0,0 @@ - -OUTPUT_FORMAT("elf32-powerpcle-freebsd", "elf32-powerpcle-freebsd", - "elf32-powerpcle-freebsd") -OUTPUT_ARCH(powerpcle:common) -ENTRY(_start) -SEARCH_DIR(/usr/lib); -PROVIDE (__stack = 0); -PHDRS -{ - text PT_LOAD; -} -SECTIONS -{ - /* Read-only sections, merged into text segment: */ - . = 0x02c00000 + SIZEOF_HEADERS; - .interp : { *(.interp) } :text - .hash : { *(.hash) } - .dynsym : { *(.dynsym) } - .dynstr : { *(.dynstr) } - .gnu.version : { *(.gnu.version) } - .gnu.version_d : { *(.gnu.version_d) } - .gnu.version_r : { *(.gnu.version_r) } - .rela.text : - { *(.rela.text) *(.rela.gnu.linkonce.t*) } - .rela.data : - { *(.rela.data) *(.rela.gnu.linkonce.d*) } - .rela.rodata : - { *(.rela.rodata) *(.rela.gnu.linkonce.r*) } - .rela.got : { *(.rela.got) } - .rela.got1 : { *(.rela.got1) } - .rela.got2 : { *(.rela.got2) } - .rela.ctors : { *(.rela.ctors) } - .rela.dtors : { *(.rela.dtors) } - .rela.init : { *(.rela.init) } - .rela.fini : { *(.rela.fini) } - .rela.bss : { *(.rela.bss) } - .rela.plt : { *(.rela.plt) } - .rela.sdata : { *(.rela.sdata) } - .rela.sbss : { *(.rela.sbss) } - .rela.sdata2 : { *(.rela.sdata2) } - .rela.sbss2 : { *(.rela.sbss2) } - .text : - { - *(.text) - /* .gnu.warning sections are handled specially by elf32.em. */ - *(.gnu.warning) - *(.gnu.linkonce.t*) - } =0 - _etext = .; - PROVIDE (etext = .); - .init : { *(.init) } =0 - .fini : { *(.fini) } =0 - .rodata : { *(.rodata) *(.gnu.linkonce.r*) } - .rodata1 : { *(.rodata1) } - .sdata2 : { *(.sdata2) } - .sbss2 : { *(.sbss2) } - /* Adjust the address for the data segment to the next page up. */ - . = ((. + 0x1000) & ~(0x1000 - 1)); - .data.rel.ro : { *(.data.rel.ro*) } - .data : - { - *(.data) - *(.gnu.linkonce.d*) - CONSTRUCTORS - } - .data1 : { *(.data1) } - .got1 : { *(.got1) } - .dynamic : { *(.dynamic) } - /* Put .ctors and .dtors next to the .got2 section, so that the pointers - get relocated with -mrelocatable. Also put in the .fixup pointers. - The current compiler no longer needs this, but keep it around for 2.7.2 */ - PROVIDE (_GOT2_START_ = .); - .got2 : { *(.got2) } - PROVIDE (__CTOR_LIST__ = .); - .ctors : { *(.ctors) } - PROVIDE (__CTOR_END__ = .); - PROVIDE (__DTOR_LIST__ = .); - .dtors : { *(.dtors) } - PROVIDE (__DTOR_END__ = .); - PROVIDE (_FIXUP_START_ = .); - .fixup : { *(.fixup) } - PROVIDE (_FIXUP_END_ = .); - PROVIDE (_GOT2_END_ = .); - PROVIDE (_GOT_START_ = .); - .got : { *(.got) } - .got.plt : { *(.got.plt) } - PROVIDE (_GOT_END_ = .); - /* We want the small data sections together, so single-instruction offsets - can access them all, and initialized data all before uninitialized, so - we can shorten the on-disk segment size. */ - .sdata : { *(.sdata) } - _edata = .; - PROVIDE (edata = .); - .sbss : - { - PROVIDE (__sbss_start = .); - *(.sbss) - *(.scommon) - *(.dynsbss) - PROVIDE (__sbss_end = .); - } - .plt : { *(.plt) } - .bss : - { - PROVIDE (__bss_start = .); - *(.dynbss) - *(.bss) - *(COMMON) - } - _end = . ; - PROVIDE (end = .); - /* Stabs debugging sections. */ - .stab 0 : { *(.stab) } - .stabstr 0 : { *(.stabstr) } - /* DWARF debug sections. - Symbols in the DWARF debugging sections are relative to the beginning - of the section so we begin them at 0. */ - /* DWARF 1 */ - .debug 0 : { *(.debug) } - .line 0 : { *(.line) } - /* GNU DWARF 1 extensions */ - .debug_srcinfo 0 : { *(.debug_srcinfo) } - .debug_sfnames 0 : { *(.debug_sfnames) } - /* DWARF 1.1 and DWARF 2 */ - .debug_aranges 0 : { *(.debug_aranges) } - .debug_pubnames 0 : { *(.debug_pubnames) } - /* DWARF 2 */ - .debug_info 0 : { *(.debug_info) } - .debug_abbrev 0 : { *(.debug_abbrev) } - .debug_line 0 : { *(.debug_line) } - .debug_frame 0 : { *(.debug_frame) } - .debug_str 0 : { *(.debug_str) } - .debug_loc 0 : { *(.debug_loc) } - .debug_macinfo 0 : { *(.debug_macinfo) } - /* SGI/MIPS DWARF 2 extensions */ - .debug_weaknames 0 : { *(.debug_weaknames) } - .debug_funcnames 0 : { *(.debug_funcnames) } - .debug_typenames 0 : { *(.debug_typenames) } - .debug_varnames 0 : { *(.debug_varnames) } - /* These must appear regardless of . */ -} - diff --git a/stand/powerpc/ofw/powerpc.ldscript b/stand/powerpc/ofw/powerpc.ldscript new file mode 100644 index 000000000000..aa48f257af1a --- /dev/null +++ b/stand/powerpc/ofw/powerpc.ldscript @@ -0,0 +1,3 @@ +OUTPUT_FORMAT("elf32-powerpc-freebsd", "elf32-powerpc-freebsd", + "elf32-powerpc-freebsd") +INCLUDE "ppc-common.ldscript" diff --git a/stand/powerpc/ofw/powerpc64.ldscript b/stand/powerpc/ofw/powerpc64.ldscript new file mode 100644 index 000000000000..aa48f257af1a --- /dev/null +++ b/stand/powerpc/ofw/powerpc64.ldscript @@ -0,0 +1,3 @@ +OUTPUT_FORMAT("elf32-powerpc-freebsd", "elf32-powerpc-freebsd", + "elf32-powerpc-freebsd") +INCLUDE "ppc-common.ldscript" diff --git a/stand/powerpc/ofw/powerpc64le.ldscript b/stand/powerpc/ofw/powerpc64le.ldscript new file mode 100644 index 000000000000..269d8121db6b --- /dev/null +++ b/stand/powerpc/ofw/powerpc64le.ldscript @@ -0,0 +1,3 @@ +OUTPUT_FORMAT("elf32-powerpcle-freebsd", "elf32-powerpcle-freebsd", + "elf32-powerpcle-freebsd") +INCLUDE "ppc-common.ldscript" diff --git a/stand/powerpc/ofw/powerpcspe.ldscript b/stand/powerpc/ofw/powerpcspe.ldscript new file mode 100644 index 000000000000..aa48f257af1a --- /dev/null +++ b/stand/powerpc/ofw/powerpcspe.ldscript @@ -0,0 +1,3 @@ +OUTPUT_FORMAT("elf32-powerpc-freebsd", "elf32-powerpc-freebsd", + "elf32-powerpc-freebsd") +INCLUDE "ppc-common.ldscript" diff --git a/stand/powerpc/ofw/ldscript.powerpc b/stand/powerpc/ofw/ppc-common.ldscript similarity index 97% rename from stand/powerpc/ofw/ldscript.powerpc rename to stand/powerpc/ofw/ppc-common.ldscript index 1c023ce6ade6..e12dee74824a 100644 --- a/stand/powerpc/ofw/ldscript.powerpc +++ b/stand/powerpc/ofw/ppc-common.ldscript @@ -1,6 +1,3 @@ - -OUTPUT_FORMAT("elf32-powerpc-freebsd", "elf32-powerpc-freebsd", - "elf32-powerpc-freebsd") OUTPUT_ARCH(powerpc:common) ENTRY(_start) SEARCH_DIR(/usr/lib); From nobody Tue Apr 16 20:13:17 2024 X-Original-To: dev-commits-src-branches@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 4VJwG5592qz5H0fZ; Tue, 16 Apr 2024 20:13:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG548rxz4v2V; Tue, 16 Apr 2024 20:13:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298397; 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=7EW0rDed5j5tpDg6LPaNWswLweZWaw3w4L6Tw47xzH8=; b=YcvbbSp7YW8QcSzKqTsGMU0XiElntqq+HpVLqR39lonASWaOcvWhbXouRJJ2m5SUdqM0y2 q2cQN/rDgLPuUvKC12oBN/HgjXFd91EcIvHMtyhwHFrQ4+TArbrlCnPg3FG60slDnT5k/B MOxOoos1m+XI2bcW/MXcj4oOSY+8sjoAP48Y9M9D7PhOyvdsiZS+1shOA7zQHCD7vnvSg6 ZpBe4Eh5Qm5/PHOZ3d7p39o1JtwLyCjFcxi+sLgx07WvcXWDRyM9TlCTtcicfKcFWrmiLb gdtQm46qf1xfOxoNLJF0HWtdBQMP8KSWohgaYAtjoawDy81geaPIhcqWVkcwrQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298397; a=rsa-sha256; cv=none; b=DgANMYti+q5No5gI5KGGBdOTmUZXXY/aaLShndeWo0WZOp5DzCk2RUvfJ2YZX4Y5dGTUVF m4J9p1cunSNIkiyddkeEsdPCn1JFATo69x08Ge7nuyIl88qevuo4IvrSXT+ECWLJsUnBxd y1gAvKSUvwRnrLUZZ9U33aP3j2KQXnGmDoJrDTv3UoNu/1iil7Zac9NT6XxCFkabNUdmi/ I2K2xjfIwdi9+7U0c3Qz/A2wpjN9CAH1cpTH/wbDSsehR1Dtp54CpoLiAI0GsPBloKdWfn 5jQAglFw7ACJHqYQTM9ul/Nf7glNd800ucJEmZBggthxkA6K8IjIGnkdyXpeWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298397; 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=7EW0rDed5j5tpDg6LPaNWswLweZWaw3w4L6Tw47xzH8=; b=jWTWIL0R34QJNSgA9+aQsZWoR1KWXU4Wxehye0uiwqcBPvtagIHSYjqZoi0WPmO1O5icRK cabDR1Qh3bZ0pQTTkRUkcXGZc1aI7/eUMEPUfz7e7nHe6bOFmgem5kWH3WWyczGedFMTr0 YQ5HeOdhUbkbzDxpev0GqHroOWlKyr6f1+ugTtTES1e8JcsHCgEcdldnvHqajFhJWiDxPJ dfzuRyNMpOkMaey/UyU5CewBnSPpQo7tWf31DSS3RGH/jpmuUzPaeTLR+pTnixxFftDWga qHyHamQEcp67EN8sd0oO2RlC88mOB6q0hEzr0ufd/DoVo/aHv2qZFpMA1Hzmfg== 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 4VJwG53dBWzxWV; Tue, 16 Apr 2024 20:13:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDH5w039197; Tue, 16 Apr 2024 20:13:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDH6N039194; Tue, 16 Apr 2024 20:13:17 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:17 GMT Message-Id: <202404162013.43GKDH6N039194@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 295ed2786bb1 - stable/14 - loader/uboot: Move to foo.ldconfig List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 295ed2786bb162dafabc80685935d9f0e8bf224c Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=295ed2786bb162dafabc80685935d9f0e8bf224c commit 295ed2786bb162dafabc80685935d9f0e8bf224c Author: Warner Losh AuthorDate: 2024-02-25 00:56:48 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader/uboot: Move to foo.ldconfig Move to the foo.ldconfig convention to match the rest of the boot loader. No functional change intended. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44059 (cherry picked from commit 3d6239d2449ee085a9a078c378659469fd69b135) --- stand/uboot/Makefile | 2 +- stand/uboot/arch/arm/Makefile.inc | 14 +++++++------- stand/uboot/arch/arm/{ldscript.arm => arm.ldscript} | 0 .../arch/powerpc/{ldscript.powerpc => powerpc.ldscript} | 0 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/stand/uboot/Makefile b/stand/uboot/Makefile index 4405f09408bf..ccd02c44957f 100644 --- a/stand/uboot/Makefile +++ b/stand/uboot/Makefile @@ -40,7 +40,7 @@ HELP_FILENAME= loader.help.uboot # Always add MI sources .include "${BOOTSRC}/loader.mk" -LDSCRIPT= ${.CURDIR}/arch/${MACHINE_CPUARCH}/ldscript.${MACHINE_CPUARCH} +LDSCRIPT= ${.CURDIR}/arch/${MACHINE_CPUARCH}/${MACHINE_CPUARCH}.ldscript LDFLAGS= -nostdlib -static -T ${LDSCRIPT} LDFLAGS+= -Wl,-znotext diff --git a/stand/uboot/arch/arm/Makefile.inc b/stand/uboot/arch/arm/Makefile.inc index 66cb3f1b4dda..115f48672b18 100644 --- a/stand/uboot/arch/arm/Makefile.inc +++ b/stand/uboot/arch/arm/Makefile.inc @@ -4,22 +4,22 @@ UBLDR_LOADADDR?= 0x1000000 SRCS+= start.S conf.c self_reloc.c -ldscript.abs: +abs.ldscript: echo "UBLDR_LOADADDR = ${UBLDR_LOADADDR};" >${.TARGET} -ldscript.pie: +pie.ldscript: echo "UBLDR_LOADADDR = 0;" >${.TARGET} -ubldr: ${OBJS} ldscript.abs ${LDSCRIPT} ${DPADD} - ${CC} ${CFLAGS} -T ldscript.abs ${LDFLAGS} \ +ubldr: ${OBJS} abs.ldscript ${LDSCRIPT} ${DPADD} + ${CC} ${CFLAGS} -T abs.ldscript ${LDFLAGS} \ -o ${.TARGET} ${OBJS} ${LDADD} -ubldr.pie: ${OBJS} ldscript.pie ${LDSCRIPT} ${DPADD} - ${CC} ${CFLAGS} -T ldscript.pie ${LDFLAGS} -pie -Wl,-Bsymbolic \ +ubldr.pie: ${OBJS} pie.ldscript ${LDSCRIPT} ${DPADD} + ${CC} ${CFLAGS} -T pie.ldscript ${LDFLAGS} -pie -Wl,-Bsymbolic \ -o ${.TARGET} ${OBJS} ${LDADD} ubldr.bin: ubldr.pie ${OBJCOPY} -S -O binary ubldr.pie ${.TARGET} -CLEANFILES+= ldscript.abs ldscript.pie ubldr ubldr.pie ubldr.bin +CLEANFILES+= abs.ldscript pie.ldscript ubldr ubldr.pie ubldr.bin diff --git a/stand/uboot/arch/arm/ldscript.arm b/stand/uboot/arch/arm/arm.ldscript similarity index 100% rename from stand/uboot/arch/arm/ldscript.arm rename to stand/uboot/arch/arm/arm.ldscript diff --git a/stand/uboot/arch/powerpc/ldscript.powerpc b/stand/uboot/arch/powerpc/powerpc.ldscript similarity index 100% rename from stand/uboot/arch/powerpc/ldscript.powerpc rename to stand/uboot/arch/powerpc/powerpc.ldscript From nobody Tue Apr 16 20:13:19 2024 X-Original-To: dev-commits-src-branches@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 4VJwG82KvZz5H0l6; Tue, 16 Apr 2024 20:13:20 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG764G1z4v7F; Tue, 16 Apr 2024 20:13:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298399; 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=0Vwq7hn8AX3ROJwGzjy4Pz3Hv5UcPSFD1h3mwJidXVo=; b=P5xJCAuE/ktuBoO51Pp6Y67Lxn7m6LWqiP6MhG2/rec288CSP7lcvv7WM/Mg1gxBYhQgU4 PC8g6+1C3xrQZ4KTjHeNVInXF8IcNgnY6eeuoX8JgFuvcXEv6ywFD1xwG2nirXhYPXOXq2 C/XZ4o7sANAENfA/UBAIctZU6axAPtBGKThw21c3Jx7Ygo9thMpx0GMZ/8Ee5xI7JB7r9Z yQCDnsPYEqJo+s3Y5PAxCQ77Au+Pk7rsnTSLgfHQvToIc4dxtTcYFfrvFAm/EIriV45YUH 1XCMWC0ZPqqA3wGJqIZ7RzN1IhxeH512QRuabtfcheOt64rm885pGgy2DKHFBw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298399; a=rsa-sha256; cv=none; b=WwiGjXVDvM6EItU+6wsNrreE4+NThjU1cPvfNQT0TtiSWxDC/gFrUIAOb9FDk4knkv2RVy xHGnSdnTIgY1eBEWLTHyRgUoRxGalaSx/HuHeg0UhHD17q7jE93v2cd/SyVqVFRlxFciEZ UX04wdbwHn1rBW/Nl2XnmNX7wL7T43JAGDEOwN6fdP+Z3sLHUvZ/z1dwlcy/2tH1cGzrNV 7dYR4K8yD+DC6UMMCiuW5fUWE9AcX19VXqZs5Vm4M8ZwtC64kT9hU9eMO5mKY55pwCdJIc c9sNYYxSnEkRzSLKtUlRQcbObQe88KPcK/N2D69h7ro5X6pRflQLNCZaCR2ukA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298399; 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=0Vwq7hn8AX3ROJwGzjy4Pz3Hv5UcPSFD1h3mwJidXVo=; b=c8sSm46itTeag+on6TXQZgeQ4ZSxHCyXDr+A2PQMiFiVid+f/13g10bRJ8XK8yk91SqVHU GovcNdZYdcey5SG9rFOLLkRxMXT9wp4xZW+TTQs+A5HHb9jcG6bwAIUoK1A01bK0Kxptf7 yr/i3KFcMcvICFQiSwjt0u3+gOvPWG5mH/sBIVNb3s06aHbXfdd4ZrCysH2ivJLrw4gH1D tE4qbZX0cFa3GfO96g53JSWwsJ7uZQCxJboMjbsNsgAo3WnizwsueLu6Iq5IjA2xi/5Mdo IPKGNXfXB5ZLCWBLLEyF0EcsKK4li9kOgJAgowx2ZmNCPo0g7rK8TU9iWhXi3A== 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 4VJwG75dFZzxY6; Tue, 16 Apr 2024 20:13:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDJ4r039296; Tue, 16 Apr 2024 20:13:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDJnf039293; Tue, 16 Apr 2024 20:13:19 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:19 GMT Message-Id: <202404162013.43GKDJnf039293@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 6cad882b7eec - stable/14 - loader/efi: Linker sets not needed. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6cad882b7eeced9c268cdd0f848b03cfde5722ce Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=6cad882b7eeced9c268cdd0f848b03cfde5722ce commit 6cad882b7eeced9c268cdd0f848b03cfde5722ce Author: Warner Losh AuthorDate: 2024-02-25 00:57:04 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader/efi: Linker sets not needed. We don't need linker sets listed as sections. They are explicitly included in the objcopy we use to create the .efi file. This practice was added in 2002 by peter@ in a6d81d83a280 to make ia64 builds self-hosted. However, it was added back to the objcopy in 2010 by rpaulo in 8df7a05edd36 for i386 EFI support, though the ldscript file then retained them needlessly. The gcc/binutils bug having been fixed in the interim. We've not needed them since then, but the redundancy didn't matter. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44061 (cherry picked from commit d024bc7ff5e80537438b4556810782e9a8257b44) --- stand/efi/loader/arch/amd64/amd64.ldscript | 11 ----------- stand/efi/loader/arch/arm/arm.ldscript | 10 ---------- stand/efi/loader/arch/arm64/arm64.ldscript | 11 ----------- stand/efi/loader/arch/riscv/riscv.ldscript | 11 ----------- 4 files changed, 43 deletions(-) diff --git a/stand/efi/loader/arch/amd64/amd64.ldscript b/stand/efi/loader/arch/amd64/amd64.ldscript index 57014aefc025..0e620654ea81 100644 --- a/stand/efi/loader/arch/amd64/amd64.ldscript +++ b/stand/efi/loader/arch/amd64/amd64.ldscript @@ -34,17 +34,6 @@ SECTIONS *(COMMON) } . = ALIGN(4096); - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } - . = ALIGN(4096); __gp = .; .sdata : { *(.got.plt .got) diff --git a/stand/efi/loader/arch/arm/arm.ldscript b/stand/efi/loader/arch/arm/arm.ldscript index 13affe12bbba..7b5c2af399c9 100644 --- a/stand/efi/loader/arch/arm/arm.ldscript +++ b/stand/efi/loader/arch/arm/arm.ldscript @@ -42,16 +42,6 @@ SECTIONS *(.got.plt .got) *(.sdata*.sdata.* .gnu.linkonce.s.*) } - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } __gp = .; .plt : { *(.plt) } .reloc : { *(.reloc) } diff --git a/stand/efi/loader/arch/arm64/arm64.ldscript b/stand/efi/loader/arch/arm64/arm64.ldscript index bacb81b5032f..18aead05cb49 100644 --- a/stand/efi/loader/arch/arm64/arm64.ldscript +++ b/stand/efi/loader/arch/arm64/arm64.ldscript @@ -39,17 +39,6 @@ SECTIONS __bss_end = .; } . = ALIGN(16); - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } - . = ALIGN(16); __gp = .; .sdata : { *(.got.plt .got) diff --git a/stand/efi/loader/arch/riscv/riscv.ldscript b/stand/efi/loader/arch/riscv/riscv.ldscript index 342ec62cf03e..63b71c3bd702 100644 --- a/stand/efi/loader/arch/riscv/riscv.ldscript +++ b/stand/efi/loader/arch/riscv/riscv.ldscript @@ -35,17 +35,6 @@ SECTIONS __bss_end = .; } . = ALIGN(16); - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } - . = ALIGN(16); .sdata : { /* * u-boot expects the gp register to be untouched by the EFI payload, so we From nobody Tue Apr 16 20:13:18 2024 X-Original-To: dev-commits-src-branches@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 4VJwG71LyNz5H0l4; Tue, 16 Apr 2024 20:13:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG65Rc1z4v2p; Tue, 16 Apr 2024 20:13:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298398; 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=Qg81K7hqiPCOxork4eq1C63kjwEg+4KlbkItk3Tbnkk=; b=l6ZtfOKogMvlumiR/i0nqTpMnyYHXdi4TxH66BVMpnbIt1dH6KW66bj/EDWqFo/2e70wr5 ITiqaOnm+XAgzZZqxZj6cgXzS4GcHq3C3lVBZu6Vt+6KU0sPCp/kqrUgWu0KBTNvaZWiNC WpHNFOE8B0xiHjcqHFGX0CrvSa/2lFivTbvbV2HP2nhJLG8h6BmY3BalGVb2wZvYD/BHl/ neamH4t/5rmqu3CQ2XXejoeCTSjcMpobeIjVaLTij3RG8cpPN2PpWHpnqVGLdFkUStCcS8 V3sMxHWw8+CMvpG2b+HhQV8Dmd0+NrMs76ycKhKGW89V5/jF1c+EFzFNMR8R2A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298398; a=rsa-sha256; cv=none; b=Gc++ARIkFPOdvbKYWejzKdPR7TEwg8aFucA17dcTDSmkzSiqod0XK2tnuNlF/k4gWfo/Nt RVpbUdWWUVSkhWj7KPrXK8JUNd4t55+H6y5z9uAEePY0cfQK+19JObjEIXpHZuvcoOLZ2a 6LdU99gMa6OuxVV2lDw7YthOHlJgt0gCcPyM2ewCOCeF6qDIxwESAFrPwbN4rupByGWQyl crobJdgkb2zk9hSh2nhpuwg42WTpHg/wrsGNf1VlmSCQCP3yx//AGoc4gw6aABcR3mGY+7 R5Tpgpj9ALcR2cqjPKPs0B4xp/Uj2h6z/w1pme9yZF0Mh7sSb8ViDio+3ELRRA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298398; 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=Qg81K7hqiPCOxork4eq1C63kjwEg+4KlbkItk3Tbnkk=; b=JRW6KRvi2VnJchfUd8r08pYX6NEpoDyA2VSRimcgKUX7Y7CS1rAIQuWBJ4UxYbjZYyVDzs ITeMyOv/CIxTAb1GHYcStaw99/q4ssppMdZA4AoRIfX1uODEIIVVhHkLwHesg7HoxY7ltR 4e/blF5R09mMzzue/pLBEjTK7RgD7LPsTQvFpU8QJKNN4xQvL+CiOl2kX1iWBlVofueKQZ vojZtRISCjZZn6pQGaZ1i2xc9YpQbv1R0iVJeqXBWkfPKgcTMnD12Lt5qHu1uQLFgshuXa D/sNOJ6cLuh83+Hr/esTP3avT+GUMwNiB+pZ1nZaiHdoloNNrTAV2/72cgupgQ== 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 4VJwG64ltJzxJY; Tue, 16 Apr 2024 20:13:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDI8H039245; Tue, 16 Apr 2024 20:13:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDIhE039242; Tue, 16 Apr 2024 20:13:18 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:18 GMT Message-Id: <202404162013.43GKDIhE039242@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 851c8f5707ac - stable/14 - loader/kboot: simplify linker set inclusion a little List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 851c8f5707acb22e200c4839c20f4644f018b4cf Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=851c8f5707acb22e200c4839c20f4644f018b4cf commit 851c8f5707acb22e200c4839c20f4644f018b4cf Author: Warner Losh AuthorDate: 2024-02-25 00:56:56 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader/kboot: simplify linker set inclusion a little Linker set sections are included by default. No need to do so explicitly. These were bogusly copied from the efi ldscripts. They were there due to a workaround introduced in 2002 by peter@ for a gcc upgrade, but whatever bugs necessitated it were filed by 2010 when rpaulo@ imported the i386 support (though they were copied even though the objcopy retained them correctly, the gcc bug having been fixed). They've never been needed. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44060 (cherry picked from commit ec6cbe468fb364a763fdea3a2803481624702cad) --- stand/kboot/kboot/arch/aarch64/aarch64.ldscript | 11 ----------- stand/kboot/kboot/arch/amd64/amd64.ldscript | 11 ----------- 2 files changed, 22 deletions(-) diff --git a/stand/kboot/kboot/arch/aarch64/aarch64.ldscript b/stand/kboot/kboot/arch/aarch64/aarch64.ldscript index 62b7d2b6be01..9460be1874bf 100644 --- a/stand/kboot/kboot/arch/aarch64/aarch64.ldscript +++ b/stand/kboot/kboot/arch/aarch64/aarch64.ldscript @@ -34,17 +34,6 @@ SECTIONS *(COMMON) } . = ALIGN(4096); - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } - . = ALIGN(4096); __gp = .; .sdata : { *(.got.plt .got) diff --git a/stand/kboot/kboot/arch/amd64/amd64.ldscript b/stand/kboot/kboot/arch/amd64/amd64.ldscript index 4009ba5fa81c..f8ba7b05a55a 100644 --- a/stand/kboot/kboot/arch/amd64/amd64.ldscript +++ b/stand/kboot/kboot/arch/amd64/amd64.ldscript @@ -34,17 +34,6 @@ SECTIONS *(COMMON) } . = ALIGN(4096); - set_Xcommand_set : { - __start_set_Xcommand_set = .; - *(set_Xcommand_set) - __stop_set_Xcommand_set = .; - } - set_Xficl_compile_set : { - __start_set_Xficl_compile_set = .; - *(set_Xficl_compile_set) - __stop_set_Xficl_compile_set = .; - } - . = ALIGN(4096); __gp = .; .sdata : { *(.got.plt .got) From nobody Tue Apr 16 20:13:20 2024 X-Original-To: dev-commits-src-branches@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 4VJwG91Fz9z5H0hl; Tue, 16 Apr 2024 20:13:21 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwG86xwDz4v9r; Tue, 16 Apr 2024 20:13:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298401; 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=GstGBarUnaTkzw9+5M4229jO8fsLY8x1U9hYJazNNaI=; b=ZmiXlcNUg4YgdjTuHv6E3uvTqWZ1e5AwYCajqRz4ykQJMYWxqzv/t6XH1GGx5eGRxC1udr 2RASmLr7guBc/BXLtSNTNsnKuffakWPtBMYGTd+VjqV9FsF3IrlZ0c/k98g1YhAl98EgPU zP4r5Oa6JVQe4oxKnvwnusLX0mPGjrAS7q1EDuanGYEtthnpHK/0mpafb5PDi++Ow801zh fP0klx57JUIZm3ChsC4WtHJrqs9/3NsMABswXcf38p4HbrKHDemYoHmx1leqbijH6u3Icy 0rdedQ+K/2l4LKk8+sfezSg0rdlPErDZJif6q14gLb7fWJFzDYe+MUeZEJWpug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298401; a=rsa-sha256; cv=none; b=T0MgAL26kZiYwIWk9uqcOMptuQubrZGl6b7HmM5TN3ShNN/exDAekuhGo3YiOYpGCIbEtY QKZqn+cNOVTcblCUw07lYBdWDxRUn24q5CNXR85YZLTEIfTCv5Q8PYU5xC5Q7KwjxKT2rv LSzHLl/jhJEcvXi/Uek4z10thmaDOAgT3yRLlsBFpgolEJfMghzOKlkQWA9msTLv+kZngL 3YZJpYAYwzLyBhUkBD+dk2MQdWgw/8Qz8D/o9/Ci1unN6SIEpGDK49oC/6xePz/wvlvrKw 5ooEGCdqVEz3mpMzswVyqyFrhsq8+kN75tZ9CHIdp2rTVlKFsg+6hFtygkIAkQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298401; 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=GstGBarUnaTkzw9+5M4229jO8fsLY8x1U9hYJazNNaI=; b=i2YMqu7GJdUTswJSdBGXAw9gCbwvC7XPJDXh68PQzEyDHuswan8Y0r0ALpSmI9LtFnlteM 0CLC2ztaZTqhSUQYHYOA4bNxg9uW/sIsf22duoTJJS6iZUWaP95mowRbGV9wwzTg7G5OBe tWOU16Uuc4snFE2An66V7zJh+kIw8bCsQzPj+bd7qlZD321+IrXJcaJhpd151FEXTv4Xwt FJffTGYK055pGUjS2Ddxm303x+xuDbREBqfJOdt8fJPKbwESEe3cYxMwrH5CvsGl0E/pzI wO7LMJwzeL3h5joC/OkBNY4ToHXGz4Hvc/beaA1/6rtUTDxUQeVTAhZ3KxGlDA== 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 4VJwG869s4zwwF; Tue, 16 Apr 2024 20:13:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDKlF039345; Tue, 16 Apr 2024 20:13:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDKU8039342; Tue, 16 Apr 2024 20:13:20 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:20 GMT Message-Id: <202404162013.43GKDKU8039342@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 88ec6ce7d159 - stable/14 - loader/efi: Use unique linker set for lua List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 88ec6ce7d15915d53f68b9930b7f2cbb791d227f Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=88ec6ce7d15915d53f68b9930b7f2cbb791d227f commit 88ec6ce7d15915d53f68b9930b7f2cbb791d227f Author: Warner Losh AuthorDate: 2024-02-25 00:57:13 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:27 +0000 loader/efi: Use unique linker set for lua After the linker set cleanup in ldscripts, there's now only one place we need to know the linkerset name, so go ahead and change the lua interpreter augmentation linker set to be uniquely named. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44062 (cherry picked from commit b4e85f760b6b77d276747c9beb6191bfb864e0c2) --- stand/efi/loader/Makefile | 2 +- stand/liblua/lutils.h | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/stand/efi/loader/Makefile b/stand/efi/loader/Makefile index 2031400814e9..bb95b6480646 100644 --- a/stand/efi/loader/Makefile +++ b/stand/efi/loader/Makefile @@ -117,7 +117,7 @@ ${LOADER}.efi: ${PROG} ${OBJCOPY} -j .peheader -j .text -j .sdata -j .data \ -j .dynamic -j .dynsym -j .rel.dyn \ -j .rela.dyn -j .reloc -j .eh_frame -j set_Xcommand_set \ - -j set_Xficl_compile_set \ + -j set_Xficl_compile_set -j set_Xlua_compile_set \ --output-target=${EFI_TARGET} ${.ALLSRC} ${.TARGET} LIBEFI= ${BOOTOBJ}/efi/libefi/libefi.a diff --git a/stand/liblua/lutils.h b/stand/liblua/lutils.h index 522abfd3d0d4..ea715096df09 100644 --- a/stand/liblua/lutils.h +++ b/stand/liblua/lutils.h @@ -34,8 +34,9 @@ int luaopen_pager(lua_State *); #include typedef void lua_init_md_t(lua_State *); +#define _LUA_COMPIE_SET Xlua_compile_set #define LUA_COMPILE_SET(func) \ - DATA_SET(Xficl_compile_set, func) /* XXX linker set know by ldscrips */ + DATA_SET(_LUA_COMPILE_SET, func) #define LUA_FOREACH_SET(s) \ - SET_FOREACH((s), Xficl_compile_set) -SET_DECLARE(Xficl_compile_set, lua_init_md_t); + SET_FOREACH((s), _LUA_COMPILE_SET) +SET_DECLARE(_LUA_COMPILE_SET, lua_init_md_t); From nobody Tue Apr 16 20:13:21 2024 X-Original-To: dev-commits-src-branches@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 4VJwGB1ZB6z5H0hm; Tue, 16 Apr 2024 20:13:22 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGB0jThz4vH5; Tue, 16 Apr 2024 20:13:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298402; 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=tiKSq3n/5nYiwLkDdHJvMDCYLedt7hEcBszqZu4lzkI=; b=sRrNbNJjDzsE9fyrZ1XfleXm23cUmh5X4Ii9Es1ES/aSKuzK79thDsl3DrxcSrx7GazOPk TVG+TuSX2sqx17jOpz+Smoa4/4qhn2iOsQN3UbIfqf2I7EQUOFNHCFp8f7B7eI7IXAALSy KanycERy35UIqlqyCLSLFVuFK5PNQyBscYfYlPZgz7qYIBjTpvyXl7g8omSxasCa1PAkNS UNI3HtkRfbzmceELLhahGM9P3tkME3JXV2AHXTvhZWQpX5iLeHbteEVJ202IJXAhHSlWhz eDbEvG1SrSkbd6LNz4/mgRmsVKjyuQy5skpWpCZEJsOloS/qz/NH8ju2ICoNtg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298402; a=rsa-sha256; cv=none; b=OVfGwj1i/O0/fhGtzg1qCCZXmkANJqEzpKPprvqQVR7hEpByFnRmiXEXhPq9gZYqddVOT8 cwTdYp0HcK+XS1Cdosy8lzkvYD4qfqcN5NyT9dLuIzhTPiRiSEpyFFcIn9QGpq+28S2dq1 S2INjQy+k6v8er1EHR8QLCl812SBGjoHzvR13xi651NqFV1m1//OQvi7TjVfosKg5Qm/WR DWCs9dzENd1AbnTLe3DLeZxwannCKEKWWnTAWko0aORjmPz9V2gHIIyRIprxpf/rK0qnfW vQYfAgOytMIdbj9a35bQk73h5W2sK/KtumTbJHOt91Dkfm4dIwmi/mCqJ8KSbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298402; 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=tiKSq3n/5nYiwLkDdHJvMDCYLedt7hEcBszqZu4lzkI=; b=yndtz/qWT+nQA3y1CElY0TmgAEaX1EHmU4KLAE1UfHdFoyaNYGa3HBLVuQHuf1yISNEr0Q NN+kNIvy2aSb7NMSQ0dGY9XUbWh5y2qmNmMxMdojmf59ZQhYwp1akj9MSv+JeuFFc/ZaPG k6wOoUyjeR3EYj6qcgEwPt5AJ/WuFjpKTvwooLHoSVAu3Ex/DCsjlIV6HNRO/Yu4xvS18R mkRoHtKSQIk3Lxk0nQwcGuj5kkd+xJfpfY49d8JFIc8g4RMaEPwQbKq+HIfdTEyOA+BQxd gMT3Y3xnIrtGvw08KYXwn+aTzF1/OhUTDAIznOZDHFvXahCfz6QdNwhCeCgG8w== 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 4VJwGB0JqXzxY7; Tue, 16 Apr 2024 20:13:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDLk5039396; Tue, 16 Apr 2024 20:13:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDL6A039393; Tue, 16 Apr 2024 20:13:21 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:21 GMT Message-Id: <202404162013.43GKDL6A039393@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 36d49fb2d585 - stable/14 - loader/ficl: Rename the ficl compile set to X4th_compile_set List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 36d49fb2d58501facfd219f0b5bb260c9986b53d Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=36d49fb2d58501facfd219f0b5bb260c9986b53d commit 36d49fb2d58501facfd219f0b5bb260c9986b53d Author: Warner Losh AuthorDate: 2024-02-25 00:57:21 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader/ficl: Rename the ficl compile set to X4th_compile_set And upcoming change will need this set to be named this. Since it's only used in the efi Makefile, and inside if ficl itself, the change should be a nop. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44063 (cherry picked from commit 8ec8413faa3573c579d9e6361de904f8251b0c0e) --- stand/efi/loader/Makefile | 2 +- stand/ficl/ficl.h | 4 ++-- stand/ficl/loader.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/stand/efi/loader/Makefile b/stand/efi/loader/Makefile index bb95b6480646..b8a98fc1dd47 100644 --- a/stand/efi/loader/Makefile +++ b/stand/efi/loader/Makefile @@ -117,7 +117,7 @@ ${LOADER}.efi: ${PROG} ${OBJCOPY} -j .peheader -j .text -j .sdata -j .data \ -j .dynamic -j .dynsym -j .rel.dyn \ -j .rela.dyn -j .reloc -j .eh_frame -j set_Xcommand_set \ - -j set_Xficl_compile_set -j set_Xlua_compile_set \ + -j set_X4th_compile_set -j set_Xlua_compile_set \ --output-target=${EFI_TARGET} ${.ALLSRC} ${.TARGET} LIBEFI= ${BOOTOBJ}/efi/libefi/libefi.a diff --git a/stand/ficl/ficl.h b/stand/ficl/ficl.h index bdade26eee09..7be78f1a36b8 100644 --- a/stand/ficl/ficl.h +++ b/stand/ficl/ficl.h @@ -1153,8 +1153,8 @@ typedef struct ficlFILE typedef void ficlCompileFcn(FICL_SYSTEM *); #define FICL_COMPILE_SET(func) \ - DATA_SET(Xficl_compile_set, func) -SET_DECLARE(Xficl_compile_set, ficlCompileFcn); + DATA_SET(X4th_compile_set, func) +SET_DECLARE(X4th_compile_set, ficlCompileFcn); #ifdef LOADER_VERIEXEC #include diff --git a/stand/ficl/loader.c b/stand/ficl/loader.c index 618d9483fbd9..69a65ebedb73 100644 --- a/stand/ficl/loader.c +++ b/stand/ficl/loader.c @@ -865,7 +865,7 @@ void ficlCompilePlatform(FICL_SYSTEM *pSys) dictAppendWord(dp, "uuid-from-string", ficlUuidFromString, FW_DEFAULT); dictAppendWord(dp, "uuid-to-string", ficlUuidToString, FW_DEFAULT); - SET_FOREACH(fnpp, Xficl_compile_set) + SET_FOREACH(fnpp, X4th_compile_set) (*fnpp)(pSys); #if defined(__i386__) From nobody Tue Apr 16 20:13:23 2024 X-Original-To: dev-commits-src-branches@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 4VJwGC2wngz5H0Td; Tue, 16 Apr 2024 20:13:23 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGC1wXqz4v62; Tue, 16 Apr 2024 20:13:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298403; 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=8RQ+ITWoiXVSfpGly4oFsOJww6JD2Y19vSZhDXQQNpI=; b=hoLN0LYZdoOG828Gvobnpaou4UfSNm/XtuTXFPjvBMA2TqYQ2kaY6tu8OIYZoGE2bobjQX nFiD8ZSjeJKVhLWUxSJNuf28c4700rFuWmi4LN7mzny6U9AjMMifKLEh9rDVy9hnGYxE1R UxOaLRvs4BX+tyDiuY4gSLubaGS9Z+RZZoZQ+Ttbo5BeptXmKPaKTNVedOPJXUWs3JcFc/ fhsUqzmVwjgEt1MFUnlCofmkMWj6dreIHbBP6jkrzz5Hg+VH992YlMmMrK48iLDb9GV5IP 8OUEA8/s+cnjvDZ62ZBxtBPn0g5CzrLDhQttg5mFSqsAqf3A7C8GM6vRGs4K9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298403; a=rsa-sha256; cv=none; b=MdzB87coUREcpOY1UyIynClGUFQdYINGv12eGVPaTdm+RHVqEygJk0EWQ6QZvkEqGihu5A wrB0Z1MEwUTVYMt2iOv32YZSs+theskTyW4sNkRaEpTcDnl15bPcaoWs1/saA1DafBWqlc n99M2iiLVKKbcS8W3c1p6qZ+oH2YpBUUnGcdbqxZRmnnnghuktTf5Rho0e2QAnrWs3/owj Ee/90hSCcfXErViaBen3mSiqMCO9Ry5RfiGRNTSRjbZJzxSwq5o8e6JuS+dRUaD7KGh6pp NMXu66Ip8zuyNQzV3PfSExch11FWv8brAxcA0A0gLdoF2JXpRQt39m7UDQApXA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298403; 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=8RQ+ITWoiXVSfpGly4oFsOJww6JD2Y19vSZhDXQQNpI=; b=qaEQYhgjAGUguXXO9L2ybI8Ticd9NdCqHZroXfjb/r8xOTbPzGf61Dj0aApfjc3gCRCv7k OZ2Z4e1GkeNpgnHjn14JOXM4DPYPZ7h6Sp8Pd5ukGkAL4gI3RTrDy8KIgo5bDEp7fGnVpX 7Rf1LqG1jyAMk6qz25NGbLkCF9DrEbDrHlZIqRrfCdno5QaJO3AVnIFWoJYlBlrAddF2UZ jw/00ye3ax18MDdOKIurbZFQX+xnluLdawJ1v6p2sQ4+BBcci5uXFpQQ8r+E+5x/HoaaXj ro5ilVCizGu88FjdLgAgpl2DbTw2JLldnn8HiH1H+YjqL+wMR0Ux9twoawoshA== 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 4VJwGC1PDPzxWW; Tue, 16 Apr 2024 20:13:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDNiK039443; Tue, 16 Apr 2024 20:13:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDN56039440; Tue, 16 Apr 2024 20:13:23 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:23 GMT Message-Id: <202404162013.43GKDN56039440@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 7cc0ac566600 - stable/14 - loader/efi: Only include interpreter's linker script List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7cc0ac56660095543aa2a71c787f4277f64d9c00 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=7cc0ac56660095543aa2a71c787f4277f64d9c00 commit 7cc0ac56660095543aa2a71c787f4277f64d9c00 Author: Warner Losh AuthorDate: 2024-02-25 00:57:29 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader/efi: Only include interpreter's linker script For safety, only include the interpreter's linker script. Note that the simple loader doesn't have one, but it's not an error to copy a ELF section that does not exist. No functional change, however. Sponsored by: Netflix Reviewed by: tsoome, kevans Differential Revision: https://reviews.freebsd.org/D44064 (cherry picked from commit f5f08e41aa57f94e3c127a488a82b4e518781f89) --- stand/efi/loader/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/Makefile b/stand/efi/loader/Makefile index b8a98fc1dd47..b3395bdfdf53 100644 --- a/stand/efi/loader/Makefile +++ b/stand/efi/loader/Makefile @@ -117,7 +117,7 @@ ${LOADER}.efi: ${PROG} ${OBJCOPY} -j .peheader -j .text -j .sdata -j .data \ -j .dynamic -j .dynsym -j .rel.dyn \ -j .rela.dyn -j .reloc -j .eh_frame -j set_Xcommand_set \ - -j set_X4th_compile_set -j set_Xlua_compile_set \ + -j set_X${LOADER_INTERP}_compile_set \ --output-target=${EFI_TARGET} ${.ALLSRC} ${.TARGET} LIBEFI= ${BOOTOBJ}/efi/libefi/libefi.a From nobody Tue Apr 16 20:13:24 2024 X-Original-To: dev-commits-src-branches@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 4VJwGD4k49z5H0hr; Tue, 16 Apr 2024 20:13:24 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGD3D12z4vHc; Tue, 16 Apr 2024 20:13:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298404; 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=kpJ+4Xz675Hd4QKCsmBYu6gveMlXxPy7coqGuqNxOEw=; b=p5J2WAJ6m0DWpzRAlMxudXzmEHXgghVFpLvFDEihFZjO656Yt8Le0Jn+mRtXVI5BoGVnm3 x9/6Ka93tDdd1qJVgYqjq4GKSHgKI0JOo2LIyRJ33hypA3qIfhL1xgiM0couHlA5akBVAy QTt/uPLMw3MlJXkPqVYcfvoyqXYkXHLhNmZetuOjdapPdv+LhTGiWwlM4IxhOMiWVMspZJ ZXxnUubXDj9Smepvi7tDk3c4zc04odkF0kmKM+aFra/W9ytHQ73T0s67gVV+MPyY8tX07J Xs5HF1GPBMMv9ezPr9Zp9lMtERzV/NiJJ4NSa/GzRbPBAJ2XeVCkJEXfV6DpRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298404; a=rsa-sha256; cv=none; b=oSTFpckMxF9t1t/5rl2+3E6G4nyLccEHS57CWr+4/vOcgSdcZfF7UPT7Oac/V+xPRe31dO XaJevdyGSAfJxDPYhtu4OGh8GYoAmA/G9Ejb00hUh6r+hczf23iPoanlJUYh3FeNdiENHc 7mfjn6AMXuymTllaLQSqiQvRTfV5VO3o8t5cS4ifbv5oHTR7wRYw0bNeq3pvtRr5URg/FV z+5C/pklGiGX8seBSTQuU5CxE/sB+yETUB/JwQpuUCX+CFS4yk+UuWKVli0dvr/a5P9IY/ JKrbIIE5QbxsJXvI/qRmmCYfZ4r9FspW1L+3h197jZBQEb6gISh4LZfiFnLb3A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298404; 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=kpJ+4Xz675Hd4QKCsmBYu6gveMlXxPy7coqGuqNxOEw=; b=VHaQUbAFV+ytXyy1ggAYkXWw5zFspvtq2/ihLMVIa8i/NQOQt1elumM4ZXtn6vOelZ+mQd zxqCB9O2vIfiepjJen66p5s/abHjdX3wzLSwU1pgtAYKNHXR/PUdjt5aG5XHr2bXBo+oDi w8AFfZ5R1zw2oMdTEagYejOGxLWJOy7nB7GyhpLHzSkn1NGbUd73f28t9IUBzE9G86RTJv VOckJDcbFaUiUdREdwFiNHvb26j+hRaGjmpMCXO/fTLx6Ab/S+zoGFaou4pwZIE02TNAiY JMHyYmLawXSnR7ffKGNgD4RyFNg/mZSN7vO8XJUSXd1yZgPpbVMPXZ+dDiMvdA== 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 4VJwGD2TCjzxb3; Tue, 16 Apr 2024 20:13:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDO1G039479; Tue, 16 Apr 2024 20:13:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDOsm039476; Tue, 16 Apr 2024 20:13:24 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:24 GMT Message-Id: <202404162013.43GKDOsm039476@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 5e8509073162 - stable/14 - loader: Add loader.exit List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5e8509073162d52e13dd49a3c2fe112df2675935 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5e8509073162d52e13dd49a3c2fe112df2675935 commit 5e8509073162d52e13dd49a3c2fe112df2675935 Author: Warner Losh AuthorDate: 2024-02-27 03:19:58 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader: Add loader.exit Add loader.exit(status). While one can get alomst this behavior with loader.perform("quit"), quit doesn't allow a value to be returned to the firmware. The interpretation of 'status' is firmware specific. This can be used when autobooting doesn't work in scripts, for example, to allow the firmware to try something else... Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D44094 (cherry picked from commit 9398a495eb305d5bf240bc998ee2f6128d75f4ca) --- stand/liblua/lutils.c | 16 ++++++++++++---- stand/lua/loader.lua.8 | 4 ++++ 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/stand/liblua/lutils.c b/stand/liblua/lutils.c index 0be9f5f28ac3..874dc8bf7d5d 100644 --- a/stand/liblua/lutils.c +++ b/stand/liblua/lutils.c @@ -109,6 +109,13 @@ lua_perform(lua_State *L) return 1; } +static int +lua_exit(lua_State *L) +{ + exit(luaL_checkinteger(L, 1)); + return 0; +} + static int lua_command_error(lua_State *L) { @@ -380,14 +387,15 @@ lua_writefile(lua_State *L) #define REG_SIMPLE(n) { #n, lua_ ## n } static const struct luaL_Reg loaderlib[] = { - REG_SIMPLE(delay), - REG_SIMPLE(command_error), REG_SIMPLE(command), - REG_SIMPLE(interpret), - REG_SIMPLE(parse), + REG_SIMPLE(command_error), + REG_SIMPLE(delay), + REG_SIMPLE(exit), REG_SIMPLE(getenv), REG_SIMPLE(has_command), REG_SIMPLE(has_feature), + REG_SIMPLE(interpret), + REG_SIMPLE(parse), REG_SIMPLE(perform), REG_SIMPLE(printc), /* Also registered as the global 'printc' */ REG_SIMPLE(setenv), diff --git a/stand/lua/loader.lua.8 b/stand/lua/loader.lua.8 index ff3b91ddfb09..e5aee7e8602d 100644 --- a/stand/lua/loader.lua.8 +++ b/stand/lua/loader.lua.8 @@ -61,6 +61,10 @@ Returns the error string from the last command to fail. Like .Fn perform but the arguments are already parsed onto the stack. +.It Fn exit status +Exit the boot loader back to the firmware with a status of +.Va status . +The interpretation of this value is firmware specific. .It Fn interpret str Execute the loader builtin command .Va str From nobody Tue Apr 16 20:13:25 2024 X-Original-To: dev-commits-src-branches@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 4VJwGF49W0z5H0YR; Tue, 16 Apr 2024 20:13:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGF3Qs5z4vPh; Tue, 16 Apr 2024 20:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298405; 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=uwEovsgzVigWJm8ya2nRCgYDWWXPyS3LqoIgQpRVkKs=; b=gfwdvPrbMraRTHU9meng25rkRXT+TCHG3oJuu3qJaHwY7mDyjqUNFQT/zahKFkEI/xPDOx JyqZyVAKkNRgNBk0cSH2W3oBt8afUOAbF9Iy0tvcl4+fxxl4euGGTdo3zJ+KvVKNChmt6J alS/8eGoU0CvOILayKCFwliMXk9Xf3K/gBmcom2FznfTwOhf8/TxRVjFHVJkjd+uZ5dJYt XfA//hmcyJo5Z91V0zRPUxwPrRvDheV/nQDAf0Crn9yoKyNqRCYjAfLqcqkmYiRgSJ391t Sgq5xNZCSHSki/iH+q7sdNI++L8018Mqn4WAxW3GnQRshZdNeDOw5cnYzuNd/Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298405; a=rsa-sha256; cv=none; b=Z8JEe1JSssypnTNHOhcrv7PX7e0Ms7UpRopFuagIo1gugMxGXfrhl6I+2/NccJeh5pP2MD ZRzQ68wAtaqoSIWpKY9kxtNL3MfzoKIg6xfEKbPib+5B7bcHVIfNI4XRJIyGlMpvjUMOxs LBgoQUlagJcE8jyt7ax2/k6r2GsBXkWDVn+yYpDs9MPw+P7cH4oAhlllJkhEVxZXA150x9 UHcKYecy4S4VqXoeCHZR61jCja4vNnPzVcZUJM1C1krFNjhIr5Q5JhQS3a8syVPX+GxbrT I7DKD/EcwVg+QprYsrQv0L6PPxhGqE0bay8sOrzwuaC2FYgCL9GGnzmsSoJ6XA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298405; 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=uwEovsgzVigWJm8ya2nRCgYDWWXPyS3LqoIgQpRVkKs=; b=u0TZrbbOFHzcVckWR1ISeofu1OAbYtJv5LvFS0QUWRllT6pFgN7cDFsk0VPzjwP2Tdd7Fy JsAnTeGEKr2tbMvt3gpwjVi8B5x/2ESSS4HMcrpAQyebdpz3wmDduavtipkkdlW9013kK8 6TINgReEjNixdBnQ0hjpZAmL/QI96nXqRVEwJlIyleEN5ED0J1n88qrGrv90XFZy9GuoyD WFFERHzl6oFUD7PMLdgZa+E+dYU5nmFXt3jtDW68rNsCRzK3glYWrfr104FZ/Ns2uPQm5+ sfjlBDUdFFy3g/6SXQhmoar9dya5GPZgjQ25aN79tgw0B4TVUMdTSwMRV4eNbg== 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 4VJwGF32wKzxPT; Tue, 16 Apr 2024 20:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDPtC039532; Tue, 16 Apr 2024 20:13:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDPpB039528; Tue, 16 Apr 2024 20:13:25 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:25 GMT Message-Id: <202404162013.43GKDPpB039528@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: a552d4047e6c - stable/14 - stand: Remove dangling mips references List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a552d4047e6cb5b14ddc1fa273bf318395ec289a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=a552d4047e6cb5b14ddc1fa273bf318395ec289a commit a552d4047e6cb5b14ddc1fa273bf318395ec289a Author: Warner Losh AuthorDate: 2024-02-27 22:59:30 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 stand: Remove dangling mips references Remove mips support files from ficl. Sponsored by: Netflix (cherry picked from commit 07d600649ef804b9a492ba2d690f676f0513ae08) --- stand/ficl/mips/sysdep.c | 98 ----------- stand/ficl/mips/sysdep.h | 431 --------------------------------------------- stand/ficl/mips64/sysdep.c | 98 ----------- stand/ficl/mips64/sysdep.h | 431 --------------------------------------------- 4 files changed, 1058 deletions(-) diff --git a/stand/ficl/mips/sysdep.c b/stand/ficl/mips/sysdep.c deleted file mode 100644 index 87bed142d684..000000000000 --- a/stand/ficl/mips/sysdep.c +++ /dev/null @@ -1,98 +0,0 @@ -/******************************************************************* -** s y s d e p . c -** Forth Inspired Command Language -** Author: John Sadler (john_sadler@alum.mit.edu) -** Created: 16 Oct 1997 -** Implementations of FICL external interface functions... -** -*******************************************************************/ - - -#ifdef TESTMAIN -#include -#include -#else -#include -#endif -#include "ficl.h" - -/* -******************* FreeBSD P O R T B E G I N S H E R E ******************** Michael Smith -*/ - -#if PORTABLE_LONGMULDIV == 0 -DPUNS ficlLongMul(FICL_UNS x, FICL_UNS y) -{ - DPUNS q; - uint64_t qx; - - qx = (uint64_t)x * (uint64_t) y; - - q.hi = (uint32_t)( qx >> 32 ); - q.lo = (uint32_t)( qx & 0xFFFFFFFFL); - - return q; -} - -UNSQR ficlLongDiv(DPUNS q, FICL_UNS y) -{ - UNSQR result; - uint64_t qx, qh; - - qh = q.hi; - qx = (qh << 32) | q.lo; - - result.quot = qx / y; - result.rem = qx % y; - - return result; -} -#endif - -void ficlTextOut(FICL_VM *pVM, char *msg, int fNewline) -{ - IGNORE(pVM); - - while(*msg != 0) - putchar(*(msg++)); - if (fNewline) - putchar('\n'); - - return; -} - -void *ficlMalloc (size_t size) -{ - return malloc(size); -} - -void *ficlRealloc (void *p, size_t size) -{ - return realloc(p, size); -} - -void ficlFree (void *p) -{ - free(p); -} - - -/* -** Stub function for dictionary access control - does nothing -** by default, user can redefine to guarantee exclusive dict -** access to a single thread for updates. All dict update code -** is guaranteed to be bracketed as follows: -** ficlLockDictionary(TRUE); -** -** ficlLockDictionary(FALSE); -** -** Returns zero if successful, nonzero if unable to acquire lock -** befor timeout (optional - could also block forever) -*/ -#if FICL_MULTITHREAD -int ficlLockDictionary(short fLock) -{ - IGNORE(fLock); - return 0; -} -#endif /* FICL_MULTITHREAD */ diff --git a/stand/ficl/mips/sysdep.h b/stand/ficl/mips/sysdep.h deleted file mode 100644 index 9c2f1d2140b9..000000000000 --- a/stand/ficl/mips/sysdep.h +++ /dev/null @@ -1,431 +0,0 @@ -/******************************************************************* - s y s d e p . h -** Forth Inspired Command Language -** Author: John Sadler (john_sadler@alum.mit.edu) -** Created: 16 Oct 1997 -** Ficl system dependent types and prototypes... -** -** Note: Ficl also depends on the use of "assert" when -** FICL_ROBUST is enabled. This may require some consideration -** in firmware systems since assert often -** assumes stderr/stdout. -** $Id: sysdep.h,v 1.6 2001-04-26 21:41:55-07 jsadler Exp jsadler $ -*******************************************************************/ -/* -** Copyright (c) 1997-2001 John Sadler (john_sadler@alum.mit.edu) -** All rights reserved. -** -** Get the latest Ficl release at http://ficl.sourceforge.net -** -** L I C E N S E and D I S C L A I M E R -** -** Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions -** are met: -** 1. Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** 2. Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in the -** documentation and/or other materials provided with the distribution. -** -** THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -** ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -** FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -** DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -** OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -** LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -** OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -** SUCH DAMAGE. -** -** I am interested in hearing from anyone who uses ficl. If you have -** a problem, a success story, a defect, an enhancement request, or -** if you would like to contribute to the ficl release, please send -** contact me by email at the address above. -** -** $Id: sysdep.h,v 1.6 2001-04-26 21:41:55-07 jsadler Exp jsadler $ -*/ - -#if !defined (__SYSDEP_H__) -#define __SYSDEP_H__ - -#include - -#include /* size_t, NULL */ -#include -#include - -#if !defined IGNORE /* Macro to silence unused param warnings */ -#define IGNORE(x) &x -#endif - -/* -** TRUE and FALSE for C boolean operations, and -** portable 32 bit types for CELLs -** -*/ -#if !defined TRUE -#define TRUE 1 -#endif -#if !defined FALSE -#define FALSE 0 -#endif - - -/* -** System dependent data type declarations... -*/ -#if !defined INT32 -#define INT32 int -#endif - -#if !defined UNS32 -#define UNS32 unsigned int -#endif - -#if !defined UNS16 -#define UNS16 unsigned short -#endif - -#if !defined UNS8 -#define UNS8 unsigned char -#endif - -#if !defined NULL -#define NULL ((void *)0) -#endif - -/* -** FICL_UNS and FICL_INT must have the same size as a void* on -** the target system. A CELL is a union of void*, FICL_UNS, and -** FICL_INT. -** (11/2000: same for FICL_FLOAT) -*/ -#if !defined FICL_INT -#define FICL_INT INT32 -#endif - -#if !defined FICL_UNS -#define FICL_UNS UNS32 -#endif - -#if !defined FICL_FLOAT -#define FICL_FLOAT float -#endif - -/* -** Ficl presently supports values of 32 and 64 for BITS_PER_CELL -*/ -#if !defined BITS_PER_CELL -#define BITS_PER_CELL 32 -#endif - -#if ((BITS_PER_CELL != 32) && (BITS_PER_CELL != 64)) - Error! -#endif - -typedef struct -{ - FICL_UNS hi; - FICL_UNS lo; -} DPUNS; - -typedef struct -{ - FICL_UNS quot; - FICL_UNS rem; -} UNSQR; - -typedef struct -{ - FICL_INT hi; - FICL_INT lo; -} DPINT; - -typedef struct -{ - FICL_INT quot; - FICL_INT rem; -} INTQR; - - -/* -** B U I L D C O N T R O L S -*/ - -#if !defined (FICL_MINIMAL) -#define FICL_MINIMAL 0 -#endif -#if (FICL_MINIMAL) -#define FICL_WANT_SOFTWORDS 0 -#define FICL_WANT_FILE 0 -#define FICL_WANT_FLOAT 0 -#define FICL_WANT_USER 0 -#define FICL_WANT_LOCALS 0 -#define FICL_WANT_DEBUGGER 0 -#define FICL_WANT_OOP 0 -#define FICL_PLATFORM_EXTEND 0 -#define FICL_MULTITHREAD 0 -#define FICL_ROBUST 1 -#define FICL_EXTENDED_PREFIX 0 -#endif - -/* -** FICL_PLATFORM_EXTEND -** Includes words defined in ficlCompilePlatform -*/ -#if !defined (FICL_PLATFORM_EXTEND) -#define FICL_PLATFORM_EXTEND 1 -#endif - -/* -** FICL_WANT_FILE -** Includes the FILE and FILE-EXT wordset and associated code. Turn this off if you do not -** have a filesystem! -** Contributed by Larry Hastings -*/ -#if !defined (FICL_WANT_FILE) -#define FICL_WANT_FILE 0 -#endif - -/* -** FICL_WANT_FLOAT -** Includes a floating point stack for the VM, and words to do float operations. -** Contributed by Guy Carver -*/ -#if !defined (FICL_WANT_FLOAT) -#define FICL_WANT_FLOAT 0 -#endif - -/* -** FICL_WANT_DEBUGGER -** Inludes a simple source level debugger -*/ -#if !defined (FICL_WANT_DEBUGGER) -#define FICL_WANT_DEBUGGER 1 -#endif - -/* -** User variables: per-instance variables bound to the VM. -** Kinda like thread-local storage. Could be implemented in a -** VM private dictionary, but I've chosen the lower overhead -** approach of an array of CELLs instead. -*/ -#if !defined FICL_WANT_USER -#define FICL_WANT_USER 1 -#endif - -#if !defined FICL_USER_CELLS -#define FICL_USER_CELLS 16 -#endif - -/* -** FICL_WANT_LOCALS controls the creation of the LOCALS wordset and -** a private dictionary for local variable compilation. -*/ -#if !defined FICL_WANT_LOCALS -#define FICL_WANT_LOCALS 1 -#endif - -/* Max number of local variables per definition */ -#if !defined FICL_MAX_LOCALS -#define FICL_MAX_LOCALS 16 -#endif - -/* -** FICL_WANT_OOP -** Inludes object oriented programming support (in softwords) -** OOP support requires locals and user variables! -*/ -#if !(FICL_WANT_LOCALS) || !(FICL_WANT_USER) -#if !defined (FICL_WANT_OOP) -#define FICL_WANT_OOP 0 -#endif -#endif - -#if !defined (FICL_WANT_OOP) -#define FICL_WANT_OOP 1 -#endif - -/* -** FICL_WANT_SOFTWORDS -** Controls inclusion of all softwords in softcore.c -*/ -#if !defined (FICL_WANT_SOFTWORDS) -#define FICL_WANT_SOFTWORDS 1 -#endif - -/* -** FICL_MULTITHREAD enables dictionary mutual exclusion -** wia the ficlLockDictionary system dependent function. -** Note: this implementation is experimental and poorly -** tested. Further, it's unnecessary unless you really -** intend to have multiple SESSIONS (poor choice of name -** on my part) - that is, threads that modify the dictionary -** at the same time. -*/ -#if !defined FICL_MULTITHREAD -#define FICL_MULTITHREAD 0 -#endif - -/* -** PORTABLE_LONGMULDIV causes ficlLongMul and ficlLongDiv to be -** defined in C in sysdep.c. Use this if you cannot easily -** generate an inline asm definition -*/ -#if !defined (PORTABLE_LONGMULDIV) -#define PORTABLE_LONGMULDIV 0 -#endif - -/* -** INLINE_INNER_LOOP causes the inner interpreter to be inline code -** instead of a function call. This is mainly because MS VC++ 5 -** chokes with an internal compiler error on the function version. -** in release mode. Sheesh. -*/ -#if !defined INLINE_INNER_LOOP -#if defined _DEBUG -#define INLINE_INNER_LOOP 0 -#else -#define INLINE_INNER_LOOP 1 -#endif -#endif - -/* -** FICL_ROBUST enables bounds checking of stacks and the dictionary. -** This will detect stack over and underflows and dictionary overflows. -** Any exceptional condition will result in an assertion failure. -** (As generated by the ANSI assert macro) -** FICL_ROBUST == 1 --> stack checking in the outer interpreter -** FICL_ROBUST == 2 also enables checking in many primitives -*/ - -#if !defined FICL_ROBUST -#define FICL_ROBUST 2 -#endif - -/* -** FICL_DEFAULT_STACK Specifies the default size (in CELLs) of -** a new virtual machine's stacks, unless overridden at -** create time. -*/ -#if !defined FICL_DEFAULT_STACK -#define FICL_DEFAULT_STACK 128 -#endif - -/* -** FICL_DEFAULT_DICT specifies the number of CELLs to allocate -** for the system dictionary by default. The value -** can be overridden at startup time as well. -** FICL_DEFAULT_ENV specifies the number of cells to allot -** for the environment-query dictionary. -*/ -#if !defined FICL_DEFAULT_DICT -#define FICL_DEFAULT_DICT 12288 -#endif - -#if !defined FICL_DEFAULT_ENV -#define FICL_DEFAULT_ENV 260 -#endif - -/* -** FICL_DEFAULT_VOCS specifies the maximum number of wordlists in -** the dictionary search order. See Forth DPANS sec 16.3.3 -** (file://dpans16.htm#16.3.3) -*/ -#if !defined FICL_DEFAULT_VOCS -#define FICL_DEFAULT_VOCS 16 -#endif - -/* -** FICL_MAX_PARSE_STEPS controls the size of an array in the FICL_SYSTEM structure -** that stores pointers to parser extension functions. I would never expect to have -** more than 8 of these, so that's the default limit. Too many of these functions -** will probably exact a nasty performance penalty. -*/ -#if !defined FICL_MAX_PARSE_STEPS -#define FICL_MAX_PARSE_STEPS 8 -#endif - -/* -** FICL_EXTENDED_PREFIX enables a bunch of extra prefixes in prefix.c and prefix.fr (if -** included as part of softcore.c) -*/ -#if !defined FICL_EXTENDED_PREFIX -#define FICL_EXTENDED_PREFIX 0 -#endif - -/* -** FICL_ALIGN is the power of two to which the dictionary -** pointer address must be aligned. This value is usually -** either 1 or 2, depending on the memory architecture -** of the target system; 2 is safe on any 16 or 32 bit -** machine. 3 would be appropriate for a 64 bit machine. -*/ -#if !defined FICL_ALIGN -#define FICL_ALIGN 2 -#define FICL_ALIGN_ADD ((1 << FICL_ALIGN) - 1) -#endif - -/* -** System dependent routines -- -** edit the implementations in sysdep.c to be compatible -** with your runtime environment... -** ficlTextOut sends a NULL terminated string to the -** default output device - used for system error messages -** ficlMalloc and ficlFree have the same semantics as malloc and free -** in standard C -** ficlLongMul multiplies two UNS32s and returns a 64 bit unsigned -** product -** ficlLongDiv divides an UNS64 by an UNS32 and returns UNS32 quotient -** and remainder -*/ -struct vm; -void ficlTextOut(struct vm *pVM, char *msg, int fNewline); -void *ficlMalloc (size_t size); -void ficlFree (void *p); -void *ficlRealloc(void *p, size_t size); -/* -** Stub function for dictionary access control - does nothing -** by default, user can redefine to guarantee exclusive dict -** access to a single thread for updates. All dict update code -** must be bracketed as follows: -** ficlLockDictionary(TRUE); -** -** ficlLockDictionary(FALSE); -** -** Returns zero if successful, nonzero if unable to acquire lock -** before timeout (optional - could also block forever) -** -** NOTE: this function must be implemented with lock counting -** semantics: nested calls must behave properly. -*/ -#if FICL_MULTITHREAD -int ficlLockDictionary(short fLock); -#else -#define ficlLockDictionary(x) 0 /* ignore */ -#endif - -/* -** 64 bit integer math support routines: multiply two UNS32s -** to get a 64 bit product, & divide the product by an UNS32 -** to get an UNS32 quotient and remainder. Much easier in asm -** on a 32 bit CPU than in C, which usually doesn't support -** the double length result (but it should). -*/ -DPUNS ficlLongMul(FICL_UNS x, FICL_UNS y); -UNSQR ficlLongDiv(DPUNS q, FICL_UNS y); - -/* -** FICL_HAVE_FTRUNCATE indicates whether the current OS supports -** the ftruncate() function (available on most UNIXes). This -** function is necessary to provide the complete File-Access wordset. -*/ -#if !defined (FICL_HAVE_FTRUNCATE) -#define FICL_HAVE_FTRUNCATE 0 -#endif - - -#endif /*__SYSDEP_H__*/ diff --git a/stand/ficl/mips64/sysdep.c b/stand/ficl/mips64/sysdep.c deleted file mode 100644 index 87bed142d684..000000000000 --- a/stand/ficl/mips64/sysdep.c +++ /dev/null @@ -1,98 +0,0 @@ -/******************************************************************* -** s y s d e p . c -** Forth Inspired Command Language -** Author: John Sadler (john_sadler@alum.mit.edu) -** Created: 16 Oct 1997 -** Implementations of FICL external interface functions... -** -*******************************************************************/ - - -#ifdef TESTMAIN -#include -#include -#else -#include -#endif -#include "ficl.h" - -/* -******************* FreeBSD P O R T B E G I N S H E R E ******************** Michael Smith -*/ - -#if PORTABLE_LONGMULDIV == 0 -DPUNS ficlLongMul(FICL_UNS x, FICL_UNS y) -{ - DPUNS q; - uint64_t qx; - - qx = (uint64_t)x * (uint64_t) y; - - q.hi = (uint32_t)( qx >> 32 ); - q.lo = (uint32_t)( qx & 0xFFFFFFFFL); - - return q; -} - -UNSQR ficlLongDiv(DPUNS q, FICL_UNS y) -{ - UNSQR result; - uint64_t qx, qh; - - qh = q.hi; - qx = (qh << 32) | q.lo; - - result.quot = qx / y; - result.rem = qx % y; - - return result; -} -#endif - -void ficlTextOut(FICL_VM *pVM, char *msg, int fNewline) -{ - IGNORE(pVM); - - while(*msg != 0) - putchar(*(msg++)); - if (fNewline) - putchar('\n'); - - return; -} - -void *ficlMalloc (size_t size) -{ - return malloc(size); -} - -void *ficlRealloc (void *p, size_t size) -{ - return realloc(p, size); -} - -void ficlFree (void *p) -{ - free(p); -} - - -/* -** Stub function for dictionary access control - does nothing -** by default, user can redefine to guarantee exclusive dict -** access to a single thread for updates. All dict update code -** is guaranteed to be bracketed as follows: -** ficlLockDictionary(TRUE); -** -** ficlLockDictionary(FALSE); -** -** Returns zero if successful, nonzero if unable to acquire lock -** befor timeout (optional - could also block forever) -*/ -#if FICL_MULTITHREAD -int ficlLockDictionary(short fLock) -{ - IGNORE(fLock); - return 0; -} -#endif /* FICL_MULTITHREAD */ diff --git a/stand/ficl/mips64/sysdep.h b/stand/ficl/mips64/sysdep.h deleted file mode 100644 index 6c1d8486137c..000000000000 --- a/stand/ficl/mips64/sysdep.h +++ /dev/null @@ -1,431 +0,0 @@ -/******************************************************************* - s y s d e p . h -** Forth Inspired Command Language -** Author: John Sadler (john_sadler@alum.mit.edu) -** Created: 16 Oct 1997 -** Ficl system dependent types and prototypes... -** -** Note: Ficl also depends on the use of "assert" when -** FICL_ROBUST is enabled. This may require some consideration -** in firmware systems since assert often -** assumes stderr/stdout. -** $Id: sysdep.h,v 1.6 2001-04-26 21:41:55-07 jsadler Exp jsadler $ -*******************************************************************/ -/* -** Copyright (c) 1997-2001 John Sadler (john_sadler@alum.mit.edu) -** All rights reserved. -** -** Get the latest Ficl release at http://ficl.sourceforge.net -** -** L I C E N S E and D I S C L A I M E R -** -** Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions -** are met: -** 1. Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** 2. Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in the -** documentation and/or other materials provided with the distribution. -** -** THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -** ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -** FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -** DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -** OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -** LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -** OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -** SUCH DAMAGE. -** -** I am interested in hearing from anyone who uses ficl. If you have -** a problem, a success story, a defect, an enhancement request, or -** if you would like to contribute to the ficl release, please send -** contact me by email at the address above. -** -** $Id: sysdep.h,v 1.6 2001-04-26 21:41:55-07 jsadler Exp jsadler $ -*/ - -#if !defined (__SYSDEP_H__) -#define __SYSDEP_H__ - -#include - -#include /* size_t, NULL */ -#include -#include - -#if !defined IGNORE /* Macro to silence unused param warnings */ -#define IGNORE(x) &x -#endif - -/* -** TRUE and FALSE for C boolean operations, and -** portable 32 bit types for CELLs -** -*/ -#if !defined TRUE -#define TRUE 1 -#endif -#if !defined FALSE -#define FALSE 0 -#endif - - -/* -** System dependent data type declarations... -*/ -#if !defined INT32 -#define INT32 int -#endif - -#if !defined UNS32 -#define UNS32 unsigned int -#endif - -#if !defined UNS16 -#define UNS16 unsigned short -#endif - -#if !defined UNS8 -#define UNS8 unsigned char -#endif - -#if !defined NULL -#define NULL ((void *)0) -#endif - -/* -** FICL_UNS and FICL_INT must have the same size as a void* on -** the target system. A CELL is a union of void*, FICL_UNS, and -** FICL_INT. -** (11/2000: same for FICL_FLOAT) -*/ -#if !defined FICL_INT -#define FICL_INT long -#endif - -#if !defined FICL_UNS -#define FICL_UNS unsigned long -#endif - -#if !defined FICL_FLOAT -#define FICL_FLOAT float -#endif - -/* -** Ficl presently supports values of 32 and 64 for BITS_PER_CELL -*/ -#if !defined BITS_PER_CELL -#define BITS_PER_CELL 64 -#endif - -#if ((BITS_PER_CELL != 32) && (BITS_PER_CELL != 64)) - Error! -#endif - -typedef struct -{ - FICL_UNS hi; - FICL_UNS lo; -} DPUNS; - -typedef struct -{ - FICL_UNS quot; - FICL_UNS rem; -} UNSQR; - -typedef struct -{ - FICL_INT hi; - FICL_INT lo; -} DPINT; - -typedef struct -{ - FICL_INT quot; - FICL_INT rem; -} INTQR; - - -/* -** B U I L D C O N T R O L S -*/ - -#if !defined (FICL_MINIMAL) -#define FICL_MINIMAL 0 -#endif -#if (FICL_MINIMAL) -#define FICL_WANT_SOFTWORDS 0 -#define FICL_WANT_FILE 0 -#define FICL_WANT_FLOAT 0 -#define FICL_WANT_USER 0 -#define FICL_WANT_LOCALS 0 -#define FICL_WANT_DEBUGGER 0 -#define FICL_WANT_OOP 0 -#define FICL_PLATFORM_EXTEND 0 -#define FICL_MULTITHREAD 0 -#define FICL_ROBUST 1 -#define FICL_EXTENDED_PREFIX 0 -#endif - -/* -** FICL_PLATFORM_EXTEND -** Includes words defined in ficlCompilePlatform -*/ -#if !defined (FICL_PLATFORM_EXTEND) -#define FICL_PLATFORM_EXTEND 1 -#endif - -/* -** FICL_WANT_FILE -** Includes the FILE and FILE-EXT wordset and associated code. Turn this off if you do not -** have a filesystem! -** Contributed by Larry Hastings -*/ -#if !defined (FICL_WANT_FILE) -#define FICL_WANT_FILE 0 -#endif - -/* -** FICL_WANT_FLOAT -** Includes a floating point stack for the VM, and words to do float operations. -** Contributed by Guy Carver -*/ -#if !defined (FICL_WANT_FLOAT) -#define FICL_WANT_FLOAT 0 -#endif - -/* -** FICL_WANT_DEBUGGER -** Inludes a simple source level debugger -*/ -#if !defined (FICL_WANT_DEBUGGER) -#define FICL_WANT_DEBUGGER 1 -#endif - -/* -** User variables: per-instance variables bound to the VM. -** Kinda like thread-local storage. Could be implemented in a -** VM private dictionary, but I've chosen the lower overhead -** approach of an array of CELLs instead. -*/ -#if !defined FICL_WANT_USER -#define FICL_WANT_USER 1 -#endif - -#if !defined FICL_USER_CELLS -#define FICL_USER_CELLS 16 -#endif - -/* -** FICL_WANT_LOCALS controls the creation of the LOCALS wordset and -** a private dictionary for local variable compilation. -*/ -#if !defined FICL_WANT_LOCALS -#define FICL_WANT_LOCALS 1 -#endif - -/* Max number of local variables per definition */ -#if !defined FICL_MAX_LOCALS -#define FICL_MAX_LOCALS 16 -#endif - -/* -** FICL_WANT_OOP -** Inludes object oriented programming support (in softwords) -** OOP support requires locals and user variables! -*/ -#if !(FICL_WANT_LOCALS) || !(FICL_WANT_USER) -#if !defined (FICL_WANT_OOP) -#define FICL_WANT_OOP 0 -#endif -#endif - -#if !defined (FICL_WANT_OOP) -#define FICL_WANT_OOP 1 -#endif - -/* -** FICL_WANT_SOFTWORDS -** Controls inclusion of all softwords in softcore.c -*/ -#if !defined (FICL_WANT_SOFTWORDS) -#define FICL_WANT_SOFTWORDS 1 -#endif - -/* -** FICL_MULTITHREAD enables dictionary mutual exclusion -** wia the ficlLockDictionary system dependent function. -** Note: this implementation is experimental and poorly -** tested. Further, it's unnecessary unless you really -** intend to have multiple SESSIONS (poor choice of name -** on my part) - that is, threads that modify the dictionary -** at the same time. -*/ -#if !defined FICL_MULTITHREAD -#define FICL_MULTITHREAD 0 -#endif - -/* -** PORTABLE_LONGMULDIV causes ficlLongMul and ficlLongDiv to be -** defined in C in sysdep.c. Use this if you cannot easily -** generate an inline asm definition -*/ -#if !defined (PORTABLE_LONGMULDIV) -#define PORTABLE_LONGMULDIV 0 -#endif - -/* -** INLINE_INNER_LOOP causes the inner interpreter to be inline code -** instead of a function call. This is mainly because MS VC++ 5 -** chokes with an internal compiler error on the function version. -** in release mode. Sheesh. -*/ -#if !defined INLINE_INNER_LOOP -#if defined _DEBUG -#define INLINE_INNER_LOOP 0 -#else -#define INLINE_INNER_LOOP 1 -#endif -#endif - -/* -** FICL_ROBUST enables bounds checking of stacks and the dictionary. -** This will detect stack over and underflows and dictionary overflows. -** Any exceptional condition will result in an assertion failure. -** (As generated by the ANSI assert macro) -** FICL_ROBUST == 1 --> stack checking in the outer interpreter -** FICL_ROBUST == 2 also enables checking in many primitives -*/ - -#if !defined FICL_ROBUST -#define FICL_ROBUST 2 -#endif - -/* -** FICL_DEFAULT_STACK Specifies the default size (in CELLs) of -** a new virtual machine's stacks, unless overridden at *** 120 LINES SKIPPED *** From nobody Tue Apr 16 20:13:26 2024 X-Original-To: dev-commits-src-branches@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 4VJwGG61jkz5H0j0; Tue, 16 Apr 2024 20:13:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGG47cFz4vMn; Tue, 16 Apr 2024 20:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298406; 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=AgipyxL6nm9gkvusigHSzunzbKkj5ggrcrXh/wSQCcU=; b=a9xOTdhHQCz9tee927hS6V01gzDREobsASf7ouJCOVvT+d6KK5KgkznbEhdmKwSFohuPtZ FoyhTtq5uxMMJnl27Akn+wxgQFzwtb/CbfBtcQhlDSuoOCVw+yjUQQmePDHfYcOYNggs2G /bOze5j/Cmej75NEDIA0Dv/lGEAxz8oArHfgTjR2r6DvREaSunIi5jKPKNQ2s4NoZgpXkC iFpOAfIqFMSLtWx8r25a8DQM46hiDLXIfs5eNIMGv/QfD8VeBHbFMjTWUStEA8VUyrNDBh ga8kmFnT6ndWfxRCu8eJ+OrgPcUXXR/D38wDSYMN/dErbVOEbKOqL1YazEqoyQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298406; a=rsa-sha256; cv=none; b=wYoLimVc00IzbwZJnhuzkNgfoZGIfx0y4oO2awt6kkcScJejBnGfVbSaAMPjBYB5fTZ1fR S+cEBwpSI/2wtCQiNqpHSVMbBu5F9c6UJTh8OK5b7yZc/I6VImPsd2ivKanVXoacq4JFGO PUkI3TQwxkPATD0HvHP5wbwmxNlfX5RdYLoZqGn4WRV8OydEc1w1skgktvpSbf+OMbS2pa AYhwkhxcTzi9Dne+AY6V0XcSFKC88IvwYKHznjtZXwF8Y+GSsNEoGdWfO3ZFekfjV41TlZ KyM/VKDg24+p8etwfgp9aKTWmyX0UWpzVRoBs1Ny//aHYQX93sXrJXciHPW5tQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298406; 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=AgipyxL6nm9gkvusigHSzunzbKkj5ggrcrXh/wSQCcU=; b=MJNolW8HYP/qI50Ctd3qjUgEoBBJcNUaOlUwvKuL2jlnABf57UcGsLz25t0wf0Z/wG5cgS uPcpzDc3oOj+3OEbFTj8oPsVMzogrAgKby910PLrN5a8SqfQyq12rJhHTCtviobXC5Sfen ATGuzsxdQT/YDEGGjRE9kkf4jdeIsOSyBtChR6nDWlkycIMfROxadwhOXiyF7wwqcuz7X2 ERL+ga71A7ouHj1h5vccMvpTli3lgr0Qc/t/zfa/L0Bt0FNl2POtdzBPpuhMIspETcaPE5 0InJJ2DkrtEY+N5YjcJbLiVeuqKFJX7BR04lELzIg/TR1wpk9oZON2UermPQvA== 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 4VJwGG3jqgzxJZ; Tue, 16 Apr 2024 20:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDQuq039573; Tue, 16 Apr 2024 20:13:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDQVs039570; Tue, 16 Apr 2024 20:13:26 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:26 GMT Message-Id: <202404162013.43GKDQVs039570@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d9288e8fcccd - stable/14 - loader/efi: Small diff reduction List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d9288e8fcccddfd230c8b3d5eec74f95910d04e4 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d9288e8fcccddfd230c8b3d5eec74f95910d04e4 commit d9288e8fcccddfd230c8b3d5eec74f95910d04e4 Author: Warner Losh AuthorDate: 2024-02-29 16:14:41 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader/efi: Small diff reduction Make doing the boot once protocol more similar to copies of this code. Sponsored by: Netflix Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D44007 (cherry picked from commit 2425dbdff3d7c23f464262517faf1f99a1b51165) --- stand/efi/loader/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index 12efe594e0e2..e4d62f2e940c 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -261,8 +261,9 @@ probe_zfs_currdev(uint64_t guid) currdev.dd.d_unit = 0; currdev.pool_guid = guid; currdev.root_guid = 0; - set_currdev_devdesc((struct devdesc *)&currdev); devname = devformat(&currdev.dd); + set_currdev(devname); + printf("Setting currdev to %s\n", devname); init_zfs_boot_options(devname); if (zfs_get_bootonce(&currdev, OS_BOOTONCE, buf, sizeof(buf)) == 0) { From nobody Tue Apr 16 20:13:27 2024 X-Original-To: dev-commits-src-branches@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 4VJwGJ0ZYVz5H0XK; Tue, 16 Apr 2024 20:13:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGH58x4z4vN2; Tue, 16 Apr 2024 20:13:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298407; 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=7uX8OMEXcSfiJsKaXZGJxxnbNFlbgHE2w9Pzs85ddcY=; b=sQjbd1CkF/k9/Q2OvQVxRwQrtL9lntty5UInq5iQDubXeDYRsgaMnh/WPR3bgBlmaid/3X Q+epJRZ+eTrstjoN/kNalQW0yyvsPZ1i9bXrU4yO1LtplB3BeL5DA18NJr6csMb7+Miam7 Djckg7ZxkYZmaBw5P031/b77lcK8vcbT1rpRwOg9udPaK4hCLwxvrKoQt1sRah4AZy5jyS Nmw3N2x8/TyF70fJF7JN+ZoDbc3O6VqlIlogtby9q63w1p6sFz+bE5ow1j64ZRhH4AElSY RZOb9XYfbjPktFgLD9pgV0GHkZEJAFFYf2PhVFODjgLA4oU8U+nPUtjDL3G3lw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298407; a=rsa-sha256; cv=none; b=UdEH/1YPqg/9Fx0rBpI9pYy65roYieu5K2JxWseEeuZSZRLcFMZ0rl5zw7dkBt32IRp2ua N0JO8uTwaQ2WYm8pVkQS+QR87RHJ3pThDXhSZQH+b3JsLG/1MtiOv1kEpIdWrhK5hUtXXa jM9iNcZ9JfZnYUY/pNvJZf+MRAPBdff/gZco1AXmIM5vhVKB/yn9tL/uIOesE/3xLKCDJV ERGtTBDv3kwvFY9mRL+TxDhzBmoG3BOkBM4VWyqsYTeJuVCaoWKK4kP9uGRal0Ha7nXn/8 qJUAJneaX0uwsktBg2VT3K9+8905vdG8ck329fdxR16LscVSUR7HMnOWHjRuVQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298407; 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=7uX8OMEXcSfiJsKaXZGJxxnbNFlbgHE2w9Pzs85ddcY=; b=ROnyU2k6dwjOLzIdA1dM/odAU4YfvBmCnPZgTtkT2mMv8tuikYdJMzzsu+47huk3+Vs/vG syszCNeCDwjED/gTr43KC4vDUs2vDQBDsL6YNOQfQ0MSQLTslUOmYqI2J+NfIfGbW4CLJv b31WosmcTP7rqj2Ih7Ksi6eaVYCrhiXdySFGHDnhXICUyNz49NklfQBcEWHAaaMctuqNxs fCShHbKirCuRPZbx5IEq67X5cAFzMeIcYi9U0qj5IXYGLo1iID6wwwzEA9TYbDCJuZXITX Tytl8aD3BC2p5X/hUZtBltjbpaIX4B92fweOQyZLBF0UvHBOdQEYD4EGGbPuwA== 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 4VJwGH4lk5zxWX; Tue, 16 Apr 2024 20:13:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDR7B039612; Tue, 16 Apr 2024 20:13:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDRYJ039609; Tue, 16 Apr 2024 20:13:27 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:27 GMT Message-Id: <202404162013.43GKDRYJ039609@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 71969b965b60 - stable/14 - loader/lua: Remove pager shim List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 71969b965b6051c1af4989efb7665c1e04d89f15 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=71969b965b6051c1af4989efb7665c1e04d89f15 commit 71969b965b6051c1af4989efb7665c1e04d89f15 Author: Warner Losh AuthorDate: 2024-02-29 17:58:43 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader/lua: Remove pager shim Just after 12.2 and before the stable/13 branch, kevans added lpager.c to provide a pager interface for commands written in lua. It was merged into 12.3. Now that 12.2 is long since EOL, we can remove the pager shim here. Nobody needs that old loader + new lua scripts. Plus only one command is affected. Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D44142 (cherry picked from commit 8b9178cd0d35ff2beafebdd51c8c44ba2b5aeb0f) --- stand/lua/cli.lua | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/stand/lua/cli.lua b/stand/lua/cli.lua index 6832da0a31a5..596e55a8d1d8 100644 --- a/stand/lua/cli.lua +++ b/stand/lua/cli.lua @@ -30,18 +30,6 @@ local core = require("core") local cli = {} -if not pager then - -- shim for the pager module that just doesn't do it. - -- XXX Remove after 12.2 goes EoL. - pager = { - open = function() end, - close = function() end, - output = function(str) - printc(str) - end, - } -end - -- Internal function -- Parses arguments to boot and returns two values: kernel_name, argstr -- Defaults to nil and "" respectively. From nobody Tue Apr 16 20:13:28 2024 X-Original-To: dev-commits-src-branches@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 4VJwGJ70FRz5H0lG; Tue, 16 Apr 2024 20:13:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGJ5vP2z4vSc; Tue, 16 Apr 2024 20:13:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298408; 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=KOCZtlR+jEwfySfTHbSUzAI19j5uUob4dPRg6rIzwBE=; b=u+RwYRPVbyS6GtQtex3xvznmcaiEqCzJgWhdewRqvFCSiy9hnn/2gr6zuE3jnsS6U2TDhL k5teyk3RFVUZs1wXCzsOUFTmL9xkJZr9qblNoeoIbfnPe68/rrCEbgMYdiB6707sVmlQhI i1xZq2vIKaKipjPSjNL/KcAU0qnNmi1CC59Bx06tkkbkjOb+/DhBnGcCNOwgQuWugzBJfh HsDtsB8ZfJcowCGWbCcUqcp8yGP1drxVBMEeRgSqIf+OM+jeT0/BPEkJwNYheG7Isy1RFI ey3cocXj0KhrPKnx+ExSJ4PL9DjRhRy96ateRcn8kvqm1KyqrjBoazmpXrU7Rw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298408; a=rsa-sha256; cv=none; b=CngGYwRrGi7wxljYzx2B0pifi4nAXWgxlpNAawr1bklXo/55G8RvQO4dqn3VI1L5vsLzdh Aus0N/9bKp4PqRWrHQsOtB0QsPFCaie/0y1fi4NBJYw3v1QGEsGZ9bAkFNVuIPgvk1hEnx NfzD4HnyDOqvfTuDQJbxirJ1NB2Re6kbkrLz8pUyUNiOH9vaS8hgid4L1qu1raxKCkowzF icXJSf+giZiNSYWH9nRJx8OiRKlhd1JGRbdzQ8jFU3cR/sQ74J8jjMH5817tW1BACn+CaQ p0qxYXITZUAL90jQX3hTGL95CsyFLGebL03jFF0qyau8nHa0lauhR/BtLzAI0g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298408; 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=KOCZtlR+jEwfySfTHbSUzAI19j5uUob4dPRg6rIzwBE=; b=lPWYKFUWUUofIbNWV6q8KbmYYdqG3Az1sJlyhd1XX9B9tiGA9xqb4Z318nzCke6f+7JfiG EESIl7HUqwF3GHHhE3rcmHpfUb02hhodYDx/Le8vtDiPN2NLnx2kA6dBf+N3TWptdLkEnJ +oFs4gj95K/uVWv0FeqZ/4U9qk0VANv/aJh8/5G55Ntv+eqM4ppz8O1p8GReYcBxVc0Qnq AdBtJo6eZSbOSrb/uI2aiCiD+ygNtJefZ8A/ysz9sKnHdKEMNOKkytkVpLJdTO+K+Oa/9b X0fsiI3/8eDRZXqCDctQKq3qGWYvrX7QalFQVsx1ujDtf4qpMGjXSKdJ2qhnHA== 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 4VJwGJ5WjDzxWY; Tue, 16 Apr 2024 20:13:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDSlR039657; Tue, 16 Apr 2024 20:13:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDSbw039654; Tue, 16 Apr 2024 20:13:28 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:28 GMT Message-Id: <202404162013.43GKDSbw039654@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 216c56ff1df6 - stable/14 - loader/lua: Remove compat shim for loader.lua_path List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 216c56ff1df63ae61431b20aab722e9f8a5f2b44 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=216c56ff1df63ae61431b20aab722e9f8a5f2b44 commit 216c56ff1df63ae61431b20aab722e9f8a5f2b44 Author: Warner Losh AuthorDate: 2024-02-29 17:58:52 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:28 +0000 loader/lua: Remove compat shim for loader.lua_path loader.lua_path was committed before stable/13 was branched, and merged in to for 12.2. Remove workaround for it not being present. Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D44143 (cherry picked from commit ab97d42addae97a389c6f22d6bba62ed954bb8e7) --- stand/lua/core.lua | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/stand/lua/core.lua b/stand/lua/core.lua index 9226de564348..eaabff6a7602 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -65,13 +65,7 @@ end -- message on failure. function try_include(module) if module:sub(1, 1) ~= "/" then - local lua_path = loader.lua_path - -- XXX Temporary compat shim; this should be removed once the - -- loader.lua_path export has sufficiently spread. - if lua_path == nil then - lua_path = "/boot/lua" - end - module = lua_path .. "/" .. module + module = loader.lua_path .. "/" .. module -- We only attempt to append an extension if an absolute path -- wasn't specified. This assumes that the caller either wants -- to treat this like it would require() and specify just the From nobody Tue Apr 16 20:13:29 2024 X-Original-To: dev-commits-src-branches@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 4VJwGL1WXVz5H0nF; Tue, 16 Apr 2024 20:13:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGL098yz4vYc; Tue, 16 Apr 2024 20:13:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298410; 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=HNaIBM0qOHDrkdLIxZKofSjQ+AKMYFXjs/NhSdVAwyk=; b=Po4RTn56Zfq1Op04F48gVjBcbjdHCdWB2Pof2zebIiM17Gi5qq9O5QkK55Q0UAds4jljzb 4wcBgNV3QDf5RJDpKXC+JxvEN4PCif+VdmGiKJpnKJgyWS96Jgd2HCRiu239bvQKon1ZJH bIxvW36v1+UKGwit4Wetj7nMm8/Q3h+XU6VJNhLzQJ/23vcFeUeYeBhwM1FEFHxH/DKp2F rVy/71COT6dLIg1+qx6PDmDbo8NcJWM15z9xyXUFJEdvopSOwZrMlKHR/IdLP5Gpu75gxh Pfi2dJlImf3eDrFloNlDioEP6wPR9wtFsi4qCRyP34IQFU0TocrGKO3pQxWpAA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298410; a=rsa-sha256; cv=none; b=IeIysUpuPZjtxJDEOQzPpIkKRTfGoEZLLE43Ih2fscKv+IM+mAcjla4Fs3ip9l2CcuISEj HLd7YrWKxB5AwVSDQFk748/urPxEUUBxp3iJQA8fbbz+mO1J6+EUFovHeIBx0idJIvGbqf 1Lkwpg1PhbYp5C+iPheiFn1DVgdwN6US+RC6RSZ7ewgqjCS9lBSj9N+dCl2HstWI7qvh9D n9i92HksshL59U/B46g/3zmjmrBpd0uUgV0seeuXpNRaFUo9cQeKFkBvoIuMKNd0ky6FvT vwKan5aWD+mLTX6EgTNXEGexjVlQ9AO6hsmVUijIgbMnvuH5JV99TcKjGqaMxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298410; 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=HNaIBM0qOHDrkdLIxZKofSjQ+AKMYFXjs/NhSdVAwyk=; b=X+0VyrXE96byqb0AESkOC0fwweV65MQwDvdeyX4PwFm+C9XwsndDdaz0vZR3ozJIJqlgbo 3IM9iR2HmQCUKzZb4TJbuT0bG1SERzqWoODolgDtq67eWxik49LRBstteyOI9fjuJgfEfM Lb9PjtlQrhutWibWXlzZl9hUoMwU9ukBK+yprZJeMSBuGCgPNp9rKLKwoyas/vAH9FXYhz 8UxoqCsjOUttORzDO27dzyl75NuAFv+9FRi8QSW88K9D62Pvlvu02Fm+nLM4bsMIhgnSZB jZRv2NCJRufFACfdQUIu70vqMBsPHHFBZYpyHaWZ15vYaJIlJXS5qX91VbR85A== 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 4VJwGK6sHHzwhg; Tue, 16 Apr 2024 20:13:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDT6g039702; Tue, 16 Apr 2024 20:13:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDTm4039699; Tue, 16 Apr 2024 20:13:29 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:29 GMT Message-Id: <202404162013.43GKDTm4039699@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 64355a9cb3dc - stable/14 - loader/lua: Remove workaround for command_error List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 64355a9cb3dca2157062c279aa60cab4e19d4366 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=64355a9cb3dca2157062c279aa60cab4e19d4366 commit 64355a9cb3dca2157062c279aa60cab4e19d4366 Author: Warner Losh AuthorDate: 2024-02-29 17:58:59 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 loader/lua: Remove workaround for command_error loader.command_error was available prior to stable/12 branching. No need to check if it is available or not. Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D44144 (cherry picked from commit 552f3072af54820cf1805f712e2567bc1b7f046d) --- stand/lua/config.lua | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/stand/lua/config.lua b/stand/lua/config.lua index 86f5ef6174a2..ba6144364247 100644 --- a/stand/lua/config.lua +++ b/stand/lua/config.lua @@ -407,12 +407,7 @@ local function loadModule(mod, silent) end if cli_execute_unparsed(str) ~= 0 then - -- XXX Temporary shim: don't break the boot if - -- loader hadn't been recompiled with this - -- function exposed. - if loader.command_error then - print(loader.command_error()) - end + print(loader.command_error()) if not silent then print("failed!") end From nobody Tue Apr 16 20:13:31 2024 X-Original-To: dev-commits-src-branches@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 4VJwGM4pZnz5H0YZ; Tue, 16 Apr 2024 20:13:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGM19gkz4vYy; Tue, 16 Apr 2024 20:13:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298411; 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=30ShAClxbcopui2KuBI4c6Nwg/bkft2tXjqa8s7hRi0=; b=yHEtINY+G1wEbm6ylgng26Fz2EhpduhHvpBBu1JtksSahAo1j+eFHZ0PwuIIk8NykGGu0u sSQzgRtAvRko/fCz+1KLEjGYmWjsyl4F4iLPsCcDIwk9arsPVQOLZE4EsMYNP0SP7ADPW3 3sbGWjlvKBZb+zMyN7QFcNcnf0RpxtjlFLRs0JKFL9hZt3n4IyCUjazue0FdGpGXGpPSoW ZG3QNErMVRGy0GQSg9D8X/4vt3nvb8kQqxWR9HSSfzgCX8RpBrXdiATvAf5t3bamutNqAj +NxPNL2hiIS7yE9W6luYnY+MdI/RrZjIQu+LVd6AXhgKDSkppTHPkQ1Hg2MnhQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298411; a=rsa-sha256; cv=none; b=ZLT56CKVXuj9GMP2RntwvABigAH8O/hUV3povDCtmvuCkkI9YBW4HJgHM2WYMT5jVZf43T g9jI44btaV4fr2kKn4ed10F+7WpHy343IQl2uVEzW+6AvDuPV3Pqv4wtYQpeDJcWdkoRYy EIB8o89dJ3bjHNdROe9b6UCWY9JZ2AxeCBswnChZ1ZWmdcBRHO9zAMxzLrzE/Dr6jooMEh D+0J1yL0/1A/2GKhsXYfqheLgTwsEK8RtIdhwvIkvhdVVx9mcWm8TS8mwCa2q3cbK2UlIL RxlIxWsJvvZSOZkArcv49CsxRfRpLJOoBKXU3lwZuogQa4WN7e1rh96LbaZ/yQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298411; 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=30ShAClxbcopui2KuBI4c6Nwg/bkft2tXjqa8s7hRi0=; b=uqxl0lpX0/vu1z0PdFJYseycsBeRe/ukT+pn4WxOY/1+2VDVViYfAYbEB7DgG/+nPldZFw 2bl72yLqfinfVja5VZNpkEzfJKEHKWrJ41Rj+wRAclgcOWPmOld5LS01waL0ULRhMvXi9W kSMrHFl+DwCsr6TCJNc9ZCISV173ACUslirZCDLNNl9PrLFX4d/cQ4vRtd8HI/S7BcDHF1 xw9uqcjQC33VqAMPRBLJBNQU8gLotxvg7g6ish8Mk7rsQLhtuCD7K9FAVg8HuZTyoOO+Lz abBJRoOvjpTk8AeKWpMmL9TO1rl1m2gZA4mYHatpb193XRzKPyB+aXvYJ+oHdw== 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 4VJwGM0lr0zxPV; Tue, 16 Apr 2024 20:13:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDVl6039755; Tue, 16 Apr 2024 20:13:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDVhw039752; Tue, 16 Apr 2024 20:13:31 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:31 GMT Message-Id: <202404162013.43GKDVhw039752@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 649cc3598192 - stable/14 - kboot: Create function for error checking. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 649cc3598192b6c03a5165010a97a3778dd3f0e1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=649cc3598192b6c03a5165010a97a3778dd3f0e1 commit 649cc3598192b6c03a5165010a97a3778dd3f0e1 Author: Warner Losh AuthorDate: 2024-03-11 20:15:03 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: Create function for error checking. Linux has the convention of returning -ERRNO to flag errors from its system calls. Sometimes other negative values are returned that are success... However, only values -1 to -4096 (inclusive) are really errors. The rest are either truncated values that only look negative (so use long instead of int), or are things like addresses or legal unsigned file offsets or similar that are successful returns. Filter out the latter. Sponsored by: Netflix (cherry picked from commit 3ae18fdfbcaad827defdc217386e73c993beeba0) --- stand/kboot/include/host_syscall.h | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/stand/kboot/include/host_syscall.h b/stand/kboot/include/host_syscall.h index fd3b7a0f362b..68106093ce1f 100644 --- a/stand/kboot/include/host_syscall.h +++ b/stand/kboot/include/host_syscall.h @@ -190,20 +190,36 @@ ssize_t host_write(int fd, const void *buf, size_t nbyte); host_mmap(0, size, HOST_PROT_READ | HOST_PROT_WRITE, \ HOST_MAP_PRIVATE | HOST_MAP_ANONYMOUS, -1, 0); +/* + * Since we have to interface with the 'raw' system call, we have to cope with + * Linux's conventions. To run on the most architectures possible, they don't + * return errors through some CPU flag, but instead, return a negative value for + * an error, and a positive one for success. However, there's some issues since + * addresses have to be returned, some of which are also negative, so Linus + * declared that no successful result could be -4096 to 0. This implements + * that quirk so we can check return values easily. + */ +static __inline bool +is_linux_error(long e) +{ + return (e < 0 && e >= -4096); +} + /* * Translate Linux errno to FreeBSD errno. The two system have idenitcal errors * for 1-34. After that, they differ. Linux also has errno that don't map * exactly to FreeBSD's errno, plus the Linux errno are arch dependent > * 34. Since we just need to do this for simple cases, use the simple mapping * function where -1 to -34 are translated to 1 to 34 and all others are EINVAL. - * Pass the linux return value, which will be the -errno. + * Pass the linux return value, which will be the -errno. Linux returns these + * values as a 'long' which has to align to CPU register size, so accept that + * size as the error so the assert can catch more values. */ static __inline int -host_to_stand_errno(int e) +host_to_stand_errno(long e) { - assert(e < 0); + assert(is_linux_error(e)); return((-e) > 34 ? EINVAL : (-e)); } - #endif From nobody Tue Apr 16 20:13:33 2024 X-Original-To: dev-commits-src-branches@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 4VJwGP5htvz5H0j9; Tue, 16 Apr 2024 20:13:33 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGP3Y5Kz4vTQ; Tue, 16 Apr 2024 20:13:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298413; 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=LEP6hnKG4SbThO8whPzzOm9wdWcLzGSbCv0cN/UcKQU=; b=Kh4tA4EMalL2HuU8Nhe2ftcwXf5r2hC5QOvdOykHd8/oYSRuMzIvG9Zs4QRUxq5SxST+la BcVUBbrZm891iaEzdBaAX7a1XGRVUKqEqhtBF+0i9djf2c48hwsLdddTUWhD50v8ycYaDX X16ZRU/WkzDmds9ZAd0HVDYn3VbqbFAVqbfKiHnPk6H4OCL21m64unS8SFn/By9N0xLAki 64Ld32NV7rJDL7RCwD1j97Qggvun9v0UH2NFrv1Ers10UJg1fEFdrOSBGhroELh/vFUGX7 tS47letkBY5yl5CRB2cPQh0bp9wakMm72V9FNA5Tw+IEedSyYO9MwseJYTJwzg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298413; a=rsa-sha256; cv=none; b=OmUMTVFBC87zTIeteyrBD2OkJ+Z2I/eltAildhvgautIMrGT76d+nkqwvXxmRLePZj+Lk/ iiwbxsucKaUsuHqcJBgX7/OzdNXHsGBwoxKS3XXPRmZ1Hd2gsuUcmjqpxYbsAumRcM7DmZ nHJ4YTtucnTGO4Pekshjp3zH7IBt2sBzeBDThcww7hmTiLlD4Zi5rGEt/34Ctsck+uUqzD bZqI5MZ2Nl5R55xKxfeJazNrixtyU9hkYOj0WBb/Iu0HGOgUgGYxYybk5UiL3wz7jz73KL pchn0kJCERrc8iFMYJtW5zSnAavTwJuxnTmikBnYmnGXB5h9FpDDM0LriBVt8A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298413; 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=LEP6hnKG4SbThO8whPzzOm9wdWcLzGSbCv0cN/UcKQU=; b=erq9sKxL5auggfCCnX3zytiXW9bVOjrXfOHwgZD4ZZs6Zxu78oJyv72kOVLjwh3BXYQh2E ZwDYpSvNDrr7hB74ZMMYw4xI6vJYUT18omAzIH1yd0zxnb3YJXtdbxSG4t4nD3FngnUslv DgqSWUcInohcnaowOIfD6V/oaQQ5gKK5PH+V7k2zk3Q/W7jwhxs4LIUdFK/f3VPvXynLXY YRiXRM+qAZ8S+A/lwI3P0uML73T20ChXlochGOR8g+McHv82poqEiZGtkvnLZKlmXpUsAj ny202INKGggXeg2JBqpH7RAPmf71a96sADg+/UkaUTgp2S5wD68wwsy7mHAOMA== 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 4VJwGP2trMzxdl; Tue, 16 Apr 2024 20:13:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDXNd039853; Tue, 16 Apr 2024 20:13:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDXQw039850; Tue, 16 Apr 2024 20:13:33 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:33 GMT Message-Id: <202404162013.43GKDXQw039850@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 519aef9045d0 - stable/14 - kboot: hostfs -- check for llseek failure correctly List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 519aef9045d00e0e2082d3096abef139b24623e9 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=519aef9045d00e0e2082d3096abef139b24623e9 commit 519aef9045d00e0e2082d3096abef139b24623e9 Author: Warner Losh AuthorDate: 2024-03-11 20:15:24 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: hostfs -- check for llseek failure correctly The host_* syscalls are all raw Linux system calls, not the POSIX wrappers that glibc / musl create. So we have to ranage change the return value of host_llseek correctly to use the negative value hack that all Linux system calls use. This fixes a false positive error detection when we do something like lseek(fd, 0xf1234567, ...); This returns 0xf1234567, which is a negative value which used to trigger the error path. Instead, we check using the is_linux_error() and store the return value in a long. Translate that errno to a host errno and set the global errno to that and return -1. lseek can't otherwise return a negative number, since it's the offset after seeking into the file, which by definition is positive. This kept the 'read the UEFI memory map out of physical memory' from working on aarch64 (whose boot loader falls back to reading it since there are restrictive kernel options that can also prevent it), since the physical address the memory map was at on my platform was like 0xfa008018. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D44286 (cherry picked from commit d650c3efb638f1b2742429a5fb8e7c087839868b) --- stand/kboot/kboot/hostfs.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/stand/kboot/kboot/hostfs.c b/stand/kboot/kboot/hostfs.c index 7c0600fc35a0..cfd3476b3c84 100644 --- a/stand/kboot/kboot/hostfs.c +++ b/stand/kboot/kboot/hostfs.c @@ -124,7 +124,7 @@ hostfs_seek(struct open_file *f, off_t offset, int whence) { hostfs_file *hf = f->f_fsdata; uint32_t offl, offh; - int err; + long err; uint64_t res; /* @@ -137,8 +137,15 @@ hostfs_seek(struct open_file *f, off_t offset, int whence) offl = res & 0xfffffffful; offh = (res >> 32) & 0xfffffffful; err = host_llseek(hf->hf_fd, offh, offl, &res, whence); - if (err < 0) - return (err); + /* + * Since we're interfacing to the raw linux system call, we have to + * carefully check. We have to translate the errno value from the host + * to libsa's conventions. + */ + if (is_linux_error(err)) { + errno = host_to_stand_errno(err); + return (-1); + } return (res); } From nobody Tue Apr 16 20:13:32 2024 X-Original-To: dev-commits-src-branches@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 4VJwGN3rj4z5H0Yb; Tue, 16 Apr 2024 20:13: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGN28hVz4vP8; Tue, 16 Apr 2024 20:13:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298412; 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=6pcePTREE2jXNk4RgJ9bx7uFhstgJnN1sj5htmZ67hA=; b=XTTweNB1+SNf0k57AMJXbPZ+GMnowNy+tawtEXWUqsVv0pt7WGl6NyShKpIXLI2nKqIkdW GG7j4IOSR3At8H2FvNKioQl+pIvTYALe2vQI21HuNPihwjArNpjhZzeTkDvgb/0BpGNVL1 lF/T/NqaKlajV/DDjkWlNzlddQo0Qog4vUtePFhz4EYRxSxiTb8yc0GGQDN/5VflVCkCoJ xCzhdHvaGRY5Zta6wPenlQiC9+x6WgLLE7Gp2qxh5Cd1MYLObmcLbDgxqadRnuBgDAiQ7D 69fhRBSim9cd5QAYld+CtPLIK6NPnf75QnVTdJE8htO+30csQRfSUrND6K3/xw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298412; a=rsa-sha256; cv=none; b=PdeTB/gk7DPMQ7MGt2814Wi3SPh48V4aaiDFWafUMRM3aKpBdtAKa/yZ3mDJ5eoUajdACr uPMpiU1QHwPn4PQsIaHHi2kPsc+GVtXDQ3i6g4cSPD0hMPq21YNi59uxfqd3ZjVQHbBqpz ckHSJmA0ufYc3d66RSmi5JY8lp0kzPpmKRvKamXaCKcYMr6SENj1kZL7tMGxWKlBAOzAjs CiRSQXtIbxy5hgI2BSWp95lLWqVHuLncdEhfLnvJzGFiN5UYqXyrGf5iAt0nm3aMBBqneG BZFXZwxH8E7rWNW4upySdQMiAACOCZYv1w7UV3jSHK1aCDp78JMnr/x+VO8ehA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298412; 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=6pcePTREE2jXNk4RgJ9bx7uFhstgJnN1sj5htmZ67hA=; b=sv/CdrnP1s+tJ2/eBkfhIl8NdwORvPGkGly+Nl4OV8FEkLBouX4P91ugihKvnKuKL3J0xD Xl8VrgVgd9ehQk/IXr1LqiuyIAW91BLsbBYEPaqze6B8CAin+dznE5QXnZ2kDkZxK3dyZK i4RarftDFJyT2jJCjHTawItxNV9EP9Uxb54C4vMMT5Cg5l1B9ibPlErHdpssdW2UN2m0ZJ vBAPXjZu1OIJF3Q17Cga7lkpiHQt/tNbK47yTC+Y00p0tUXRaUKCC7tQmrVBjXxoFGLZ8Y 5WQvpV8BQDeEL1RgW1MRqHSgD3XqzROpX+1vok4FXXwLaeYkvkQi8IxQNi/62g== 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 4VJwGN1nD5zxWZ; Tue, 16 Apr 2024 20:13:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDWwJ039800; Tue, 16 Apr 2024 20:13:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDWlP039797; Tue, 16 Apr 2024 20:13:32 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:32 GMT Message-Id: <202404162013.43GKDWlP039797@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d18377cbb723 - stable/14 - kboot: Avoid UB in signed shift List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d18377cbb7233ca9a468728596718884c64d6cb1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d18377cbb7233ca9a468728596718884c64d6cb1 commit d18377cbb7233ca9a468728596718884c64d6cb1 Author: Warner Losh AuthorDate: 2024-03-11 20:15:10 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: Avoid UB in signed shift offset is signed. Copy it to the unsigned res before shifting. This avoids any possible undefined behavior for right shifting signed numbers. No functional change intended (and the code generated is the nearly same for aarch64). Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D44285 (cherry picked from commit 8b1925f29c54f5791db3c8dcdf2b67541bb8ab32) --- stand/kboot/kboot/hostfs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/stand/kboot/kboot/hostfs.c b/stand/kboot/kboot/hostfs.c index 02afa885d833..7c0600fc35a0 100644 --- a/stand/kboot/kboot/hostfs.c +++ b/stand/kboot/kboot/hostfs.c @@ -133,8 +133,9 @@ hostfs_seek(struct open_file *f, off_t offset, int whence) * from V7 later ISO-C). Also assumes we have to support powerpc still, * it's interface is weird for legacy reasons.... */ - offl = offset & 0xffffffff; - offh = (offset >> 32) & 0xffffffff; + res = (uint64_t)offset; + offl = res & 0xfffffffful; + offh = (res >> 32) & 0xfffffffful; err = host_llseek(hf->hf_fd, offh, offl, &res, whence); if (err < 0) return (err); From nobody Tue Apr 16 20:13:34 2024 X-Original-To: dev-commits-src-branches@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 4VJwGQ6BjSz5H0tC; Tue, 16 Apr 2024 20:13:34 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGQ4NfCz4vhn; Tue, 16 Apr 2024 20:13:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298414; 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=nNMJc2liAT5R0CuxrGTTvBO0Q7yt262k1K9Wp9iQO+8=; b=Eg5MMQDRhclTy/3iLIEJderdLk+I9FKATwAffTFKT8grDo23PNsnPrz5dx5eipL7Y+PFoQ FMRt5CpEhQv48ZnLDxizGycZg10MMbvnNgyvbA1IKMN439vhBozq5RjQlqFDXZ1ss0qII5 UiH+Ua/XpgBS2/9D74uTwcZKtWzptZdotCJ6v1+twjwRRz+/GcEYtmqAV14PfXL+nHT3u5 fbHBufeXpR9rHp3xAXtyvJ/jzQbfnuF3/aOx3lxEYyBeZ3XMrGmZsXa3PjdxCLKGVamD21 eW9Kl/H8AXRxXLPqGSB4X4AkWClBMDkE9XX31X/qCae1L9aKOq9DxJ8Vaf/mhw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298414; a=rsa-sha256; cv=none; b=QstFzK7ETAYFj90eGHQMAiVJOIKdwp3HqNnOjrW03E6C2j4Am6Ga/6wjs7dxILvGznmoCk 5iA1sQt0XhyynU4YoNsFNoazHsKKUy05h2zWop2a6YfX0heDhhtKIiZQJ2FC0OiII8iRiV vqWXDluZNp0GYy4qiHceAU8eRjLHiehuvrQSCffdfJUpXNmA29eYC3U622/96Nh7h5CntE 6yJtOCX8qxnuQX+nORXrnGO45iGKhDEf29UYdFoleGKodKKa3lIezymY0h5O787KXstcJr 7S1dMVfT8jrQaGyhUc9NYC7aHj2LWqnakBVw//nMXyaKgwUgFDsJacB157IBIg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298414; 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=nNMJc2liAT5R0CuxrGTTvBO0Q7yt262k1K9Wp9iQO+8=; b=rXZ0FCBVGuDlaSvoLKAFXWpt3kpmmvdO2bUvXHYcHooMcx8b61Z3s7C+ZZa8YGNG5kL24x hCWXmBEtoWEA6RmZFpi835ro/H+ayd26qa1tlaQUfR0pl4L20NCUM/GBA+VnpxyMljTOsj XzxCrIaqoFFTgN/P/aMIjmjvS5ddlNDz3tcrqlJuCrWDyvBLjPvvDBFOTM/tp0Dto4Xdah 43A8zlEzh+UY/5UXBLe56pSFVfEM6ynnTYvJPIJTpftKcrahPwoRr+QNuEbS7BK/vLlQow lOe3zIx1smhhbVzbwtaUI6AdYty4EnTG9r+XfuHmYhd2aUfsclVh2SZYnrdjpw== 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 4VJwGQ3zWtzxWb; Tue, 16 Apr 2024 20:13:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDYiU039900; Tue, 16 Apr 2024 20:13:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDYl7039897; Tue, 16 Apr 2024 20:13:34 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:34 GMT Message-Id: <202404162013.43GKDYl7039897@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 0bca0de6b676 - stable/14 - kboot: Print UEFI memory map List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0bca0de6b676e952a8871a51b8e6880f8f3a5af8 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=0bca0de6b676e952a8871a51b8e6880f8f3a5af8 commit 0bca0de6b676e952a8871a51b8e6880f8f3a5af8 Author: Warner Losh AuthorDate: 2024-03-11 20:15:34 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: Print UEFI memory map If we can read the UEFI memory map, go ahead and print the memory map. While the kernel prints this with bootverbose, having it at this stage is useful for debugging other problems. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D44287 (cherry picked from commit a9cd3b675e243648aa681bc6ce1bf3e788be88c8) --- stand/kboot/kboot/arch/aarch64/load_addr.c | 85 ++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) diff --git a/stand/kboot/kboot/arch/aarch64/load_addr.c b/stand/kboot/kboot/arch/aarch64/load_addr.c index 4cbbd5192f5b..8ea3516a5cff 100644 --- a/stand/kboot/kboot/arch/aarch64/load_addr.c +++ b/stand/kboot/kboot/arch/aarch64/load_addr.c @@ -23,6 +23,87 @@ uint32_t efi_map_size; vm_paddr_t efi_map_phys_src; /* From DTB */ vm_paddr_t efi_map_phys_dst; /* From our memory map metadata module */ +typedef void (*efi_map_entry_cb)(struct efi_md *, void *argp); + +static void +foreach_efi_map_entry(struct efi_map_header *efihdr, efi_map_entry_cb cb, void *argp) +{ + struct efi_md *map, *p; + size_t efisz; + int ndesc, i; + + /* + * Memory map data provided by UEFI via the GetMemoryMap + * Boot Services API. + */ + efisz = (sizeof(struct efi_map_header) + 0xf) & ~0xf; + map = (struct efi_md *)((uint8_t *)efihdr + efisz); + + if (efihdr->descriptor_size == 0) + return; + ndesc = efihdr->memory_size / efihdr->descriptor_size; + + for (i = 0, p = map; i < ndesc; i++, + p = efi_next_descriptor(p, efihdr->descriptor_size)) { + cb(p, argp); + } +} + +static void +print_efi_map_entry(struct efi_md *p, void *argp __unused) +{ + const char *type; + static const char *types[] = { + "Reserved", + "LoaderCode", + "LoaderData", + "BootServicesCode", + "BootServicesData", + "RuntimeServicesCode", + "RuntimeServicesData", + "ConventionalMemory", + "UnusableMemory", + "ACPIReclaimMemory", + "ACPIMemoryNVS", + "MemoryMappedIO", + "MemoryMappedIOPortSpace", + "PalCode", + "PersistentMemory" + }; + + if (p->md_type < nitems(types)) + type = types[p->md_type]; + else + type = ""; + printf("%23s %012lx %012lx %08lx ", type, p->md_phys, + p->md_virt, p->md_pages); + if (p->md_attr & EFI_MD_ATTR_UC) + printf("UC "); + if (p->md_attr & EFI_MD_ATTR_WC) + printf("WC "); + if (p->md_attr & EFI_MD_ATTR_WT) + printf("WT "); + if (p->md_attr & EFI_MD_ATTR_WB) + printf("WB "); + if (p->md_attr & EFI_MD_ATTR_UCE) + printf("UCE "); + if (p->md_attr & EFI_MD_ATTR_WP) + printf("WP "); + if (p->md_attr & EFI_MD_ATTR_RP) + printf("RP "); + if (p->md_attr & EFI_MD_ATTR_XP) + printf("XP "); + if (p->md_attr & EFI_MD_ATTR_NV) + printf("NV "); + if (p->md_attr & EFI_MD_ATTR_MORE_RELIABLE) + printf("MORE_RELIABLE "); + if (p->md_attr & EFI_MD_ATTR_RO) + printf("RO "); + if (p->md_attr & EFI_MD_ATTR_RT) + printf("RUNTIME"); + printf("\n"); +} + static bool do_memory_from_fdt(int fd) { @@ -130,6 +211,10 @@ do_memory_from_fdt(int fd) printf("Read UEFI mem map from physmem\n"); efi_map_phys_src = 0; /* Mark MODINFOMD_EFI_MAP as valid */ close(fd2); + printf("UEFI MAP:\n"); + printf("%23s %12s %12s %8s %4s\n", + "Type", "Physical", "Virtual", "#Pages", "Attr"); + foreach_efi_map_entry(efihdr, print_efi_map_entry, NULL); return true; /* OK, we really have the memory map */ no_read: From nobody Tue Apr 16 20:13:35 2024 X-Original-To: dev-commits-src-branches@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 4VJwGS1LSxz5H0qk; Tue, 16 Apr 2024 20:13:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGR5Wvxz4vj7; Tue, 16 Apr 2024 20:13:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298415; 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=gBJgfrA+afESMKC+XSSYJwyoPZqUxGaez5XW23EXypk=; b=DnfDWRyR/8IoqqQEAYOGtE3hJaNDl8FREVdUvet0bOum/bHvw6Qve9euQhQlMsUgQTFvgW qANnqQaMMMmHAlwAG0vUNqkYsUQtESUW6glc4deOTURAhD/W0vvokGjlaOa+VJK3nsvFf0 1lpWo8dk9bI/HwKuksDndJspSUl9GdcxMKItwn1+b5+u+/9t9qQDfMForS47Pwwy3hhuv2 Nh2tVpGZ5toAkjxRwtlmwGoG5bHT/qBoQDGecQDHMp9K7jmgSMZQDUMBubR6vcPZbiwUue U1To5rRHKqkps2VYwjrKjs+09P1wFpbU6MQqTNpWsnafofe0/tMDwpbM9RZO3w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298415; a=rsa-sha256; cv=none; b=eqfpDhwz4lvH4PcUtopLU4fwdzsS0msQKWSQuP1np8Q0NnWhsw70Mz/A1eAfpKaicpKmJ2 YfsO1x+pppYfZ9OGpYRB4aGtwYyKCtOx5lL4hoMk7C7oxEUnQdGxUz4bQ8s8IIPh0gm5sL ehiB37AyG2oUY8rT+p+YLnR/pK9ab4Swu+KkniCxn+ESHaN/RVTEUc0G55q8+xWJNW3Wen NvlKfsWR0man1rZgvOWG1e8ITXdukMj86Kei1ncdJXZ9neuLoTiy+FNizwQaJT9plcH6T6 fLrSZyNX7HgH8pk4YZyHdzhsBY7apAQ8IcB0pC1KmDfMbDDVUu4qoKOEQrKS6w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298415; 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=gBJgfrA+afESMKC+XSSYJwyoPZqUxGaez5XW23EXypk=; b=A+NSqT35Gz7zUObG0kHM5QgQgIO8xxn0ZkYVmdqdnjrEvlQUmiUaAOG3uu8iAWFFQpSzXw IHVeDeo+SNjrIPvhNX75D6C8RAl36OPaULt7Nm+HN88BXtjExb2SpzwMQt31jojvYzqhh6 c2D7gB/6rrgBSUHGetznLdi69pD07HelgpBsbe2ApuGGaI0kmUgQ0BNypd/t9ApVmIgwnG c7FKImNXxORPR2jsw8wwEcnMs+5GmyiUTH8lofVTFp+Xg8fr86OQS8+3KC3/gj9lIZJ/rG xJ/di5DDtFgwaL3jmUXtkmuEWffhrTnlTOCrPQaNDQWmFbOXAdTzyg4Bmn6lPg== 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 4VJwGR55Wfzxb4; Tue, 16 Apr 2024 20:13:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDZKI039958; Tue, 16 Apr 2024 20:13:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDZA3039955; Tue, 16 Apr 2024 20:13:35 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:35 GMT Message-Id: <202404162013.43GKDZA3039955@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: cb9ef3a7034a - stable/14 - kboot: Use is_linux_error to check mmap return error List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cb9ef3a7034a05fd09241867b092ebe6097097f1 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=cb9ef3a7034a05fd09241867b092ebe6097097f1 commit cb9ef3a7034a05fd09241867b092ebe6097097f1 Author: Warner Losh AuthorDate: 2024-03-11 20:15:39 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: Use is_linux_error to check mmap return error Rather than checking against the (incorrect) -511, use the is_linux_error() function to check to see if host_mmap failed. Sponsored by: Netflix (cherry picked from commit d75524b3fe21752b233f66ae8e9d6450d507f75c) --- stand/kboot/kboot/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/kboot/kboot/main.c b/stand/kboot/kboot/main.c index c397e573fc75..e57446baa47d 100644 --- a/stand/kboot/kboot/main.c +++ b/stand/kboot/kboot/main.c @@ -232,7 +232,7 @@ caddr_t ptov(uintptr_t pa) * the raw system call we have to do that ourselves. */ va = host_mmap(0, PAGE, HOST_PROT_READ, HOST_MAP_SHARED, smbios_fd, pa2); - if ((intptr_t)va < 0 && (intptr_t)va >= -511) + if (is_linux_error((long)va)) panic("smbios mmap offset %#jx failed", (uintmax_t)pa2); m = &map[nmap++]; m->pa = pa2; From nobody Tue Apr 16 20:13:36 2024 X-Original-To: dev-commits-src-branches@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 4VJwGT1KHsz5H0g4; Tue, 16 Apr 2024 20:13:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGS6d9lz4vlp; Tue, 16 Apr 2024 20:13:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298416; 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=4Sgu2BAHRJHmMRSiutNQhNpzpSWr9bcvo5lxtQfufaM=; b=NlwSW2CBT8v8pxKHUQQefC8z209hBxceqVe7C6DKxclgA5LrkXKseF08nGbqQjgLUazO34 WkGWhLP8U8P/n+Gog1BiNHqR4xlbDcljHDfNH4EMIEvxWN1rnYQUDTwxzgmTYKkcnAMBEj /Xv6pfYqCxe+ezUz2o17u0f/W60yCRomL03XtdRFSpfy27wx8fQs04sg4HFWA78hORIdsA n+SMCk8HX2+N1bkJj1H4xjGJmSBdVuTTiatNgNzXah49wwuRO3Bd4vdXIhW9RMuaP/MQ/e vDRlMRDuCDbnJzsm+DZRWnDvppKh5bn2/ygn5Bs4SBZy8wxYSYJNgmwFZbzVqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298416; a=rsa-sha256; cv=none; b=ESapeYr5eDJw88CQNz6Xbrmi1FbXBedbEnHz1YeOARVKpP8qly5wpkUK1WS1UWzG8PPpYo odNxY2c45JsNOXP3LAm6LVMI0Evso/oNkEvQxm1fAxVfd+YhIWD5nVhpluYZkyJnVvZS4I FiSHZDaqasgk7WdJuTsYjbnNYajzmxAdESncpn03eaBTxKHNIjgWQQ32+X+3G9Pnn2PLo+ tJItvpC6YR18rmS2Otpdf/Hp0glNVWi7DSUmb1Sc6kEPilVUNJ5FUB1UD/4dgoifuhc0/7 XaE/o1ZNwUw98i+yI4+t89YeB8hvjBnNwowprhpZteI5EjlYfO4m7wIVjQsSjw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298416; 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=4Sgu2BAHRJHmMRSiutNQhNpzpSWr9bcvo5lxtQfufaM=; b=aDWB8rLV2A8LX7hdu5SOrFKmS0ZRO2vd/LUcEPcadabE4NOSrcc71pCHnfe4llMgn26wsM Rv5+bxO8KowRQxN3AhgQIPjmcVkYRHnSYMlf23jKU9dpB2ELXG5J2UpDSuNE5O8f8ARd/6 +ETnEoaAONKqfvBbK2OJ9/Fz3oOrweyppEVLpmQ8dIU8Gq7yOpa5yagY5p8XZMOJJue4we oNDh+03+NwYhPTPlVg2OtjpuOQ0wtyRG1WDSFSjhfBjBj948uDgfkzTjFHvmNVxdN0lntH zP8hwbSEpNk00c1w/r0W52KnwvP6wy+vdl+hMQGzCudfOhPEWLdQ9v4Sb6Cduw== 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 4VJwGS6D6JzxY8; Tue, 16 Apr 2024 20:13:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDakE040009; Tue, 16 Apr 2024 20:13:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDaWU040006; Tue, 16 Apr 2024 20:13:36 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:36 GMT Message-Id: <202404162013.43GKDaWU040006@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d55ddce0c8e9 - stable/14 - kboot: kbootfdt: fix error handling List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d55ddce0c8e957c5285d28a5bfdbf3774c04bc56 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d55ddce0c8e957c5285d28a5bfdbf3774c04bc56 commit d55ddce0c8e957c5285d28a5bfdbf3774c04bc56 Author: Warner Losh AuthorDate: 2024-03-11 20:15:44 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 kboot: kbootfdt: fix error handling If we are able to open /sys/firmware/fdt, but aren't able to read it, fall back to /proc/device-tree. Remove comment that's not really true, it turns out. Sponsored by: Netflix (cherry picked from commit 462af7676b3ee8a8bd9ee9b55a35c0cf815a351f) --- stand/kboot/kboot/kbootfdt.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/stand/kboot/kboot/kbootfdt.c b/stand/kboot/kboot/kbootfdt.c index 70844820d345..e4c378423585 100644 --- a/stand/kboot/kboot/kbootfdt.c +++ b/stand/kboot/kboot/kbootfdt.c @@ -91,22 +91,21 @@ fdt_platform_load_dtb(void) { void *buffer; size_t buflen = 409600; - int fd; + int fd, err = 0; /* * Should load /sys/firmware/fdt if it exists, otherwise we walk the * tree from /proc/device-tree. The former is much easier than the * latter and also the newer interface. But as long as we support the - * PS3 boot, we'll need the latter due to that kernel's age. It likely - * would be better to script the decision between the two, but that - * turns out to be tricky... + * PS3 boot, we'll need the latter due to that kernel's age. */ buffer = malloc(buflen); fd = host_open("/sys/firmware/fdt", O_RDONLY, 0); - if (fd != -1) { - buflen = host_read(fd, buffer, buflen); + if (fd >= 0) { + err = host_read(fd, buffer, buflen); close(fd); - } else { + } + if (fd < 0 || err < 0) { fdt_create_empty_tree(buffer, buflen); add_node_to_fdt(buffer, "/proc/device-tree", fdt_path_offset(buffer, "/")); From nobody Tue Apr 16 20:13:37 2024 X-Original-To: dev-commits-src-branches@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 4VJwGV4zl4z5H0bx; Tue, 16 Apr 2024 20:13:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGV0Y7Lz4vm6; Tue, 16 Apr 2024 20:13:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298418; 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=8ONTlt6E9fRKeeB1O5AzVeYnZQEzds8so7mUgwrY99M=; b=LZgrw1cwjnRVnStXe7s9WJW36EOIhlJVSk202h9OWgAIiqcB98yAhCR3/lbBqIH/KDDk0N nG4hsC7QZ+YCpzdQPiGhCL2ntQMF4ovD5gPR/oRIHTtQxeSfAo3q/X9uE+X0aa6OBoFI9G R55lfwBgnbkM27eMF5pbVh8FQtC9dKDuNpWJ7t4B5W/QYzfcBLcyaoRmIi3yDCxxpqO3cM PI+mua/g5elVnWj//AnDEC/Z32c8BH7Jw2yzqVKZ1gkVTtD4V60Z7UKzEOLNLzvqOTMQbF eq5L/9WrrHnA2XFLZuwfUqL7R14miv65EC0drZFBzPDPkqEv5XJMH+O8qi+31Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298418; a=rsa-sha256; cv=none; b=hvsuKfFDQuCOmTpcLlf3VUT1oKe8GggDfG3gNsTWNPvslFlqFKSHVJY21b9QmlNuVmEV6t ELywCyOPWF8cwitZXzckrQRYU+dXhxkZdEqYZ/OwXaiwAGsmtbRP0QRWC/Q5Z7+2QpKt/u hqh2TixFNyVawpzpwB9tLlVvMKnqgDXeK0h/X2Am0pdFtWIBeGQBb+F/N5Mj3eTlAaBPGl nSPvdzA2R/ifjJ9Y93NFiupYZZZv+apTHuiCjS1XjB55ynW/0yZPaqgnBz5hsJ3idCReiu JsDXaCG5MoCggC93jIoIg/QJlyPfFaHECGGa7TvAIs5ihxxgV56DOcoFYeuuSg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298418; 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=8ONTlt6E9fRKeeB1O5AzVeYnZQEzds8so7mUgwrY99M=; b=dHrAJkp0CNJB3RzOXB6xabFRpBZz6S5dh1tnXhzKfQ0z964BpYk4lNlOHCu68QtCbcfpHp XyV6TZJlFuNdmsIvDXpMlMnmIVmKOWvrocP5rH7MeW8vHaDWItzdUK2gxu8lqAT1RjTcVJ 2ADACxSdjH1wXMOQHjww4wMYmd73FClJ+i9O//7UuVxclaCeMlu+sZUADOGuLpqfnkYveQ 7vh9HGwDVpCkQZg+C0b192o61+yEeV+JBZR2wN/+QrRmLXKESK/pEEQqElY/UWVj3Mcekd ooGkSNqTzGHZ8cIwkdKlYLggSE709JWB+8bEKWrlfvtZfWoJPDyv3Lw46zmpbw== 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 4VJwGV07mMzxY9; Tue, 16 Apr 2024 20:13:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDbu6040047; Tue, 16 Apr 2024 20:13:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDbTL040044; Tue, 16 Apr 2024 20:13:37 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:37 GMT Message-Id: <202404162013.43GKDbTL040044@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 83bae397799c - stable/14 - uboot/Makefile move BINDIR List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 83bae397799c4480e9712f03aff62d6f4fa447fe Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=83bae397799c4480e9712f03aff62d6f4fa447fe commit 83bae397799c4480e9712f03aff62d6f4fa447fe Author: Simon J. Gerraty AuthorDate: 2024-03-18 23:14:15 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:29 +0000 uboot/Makefile move BINDIR Set BINDIR before we include bsd.init.mk so we can override it via local.init.mk Reviewed by: imp Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D44413 (cherry picked from commit 01f3abbfcd59848e37118e5e2b868a7b3e98cc62) --- stand/uboot/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/stand/uboot/Makefile b/stand/uboot/Makefile index ccd02c44957f..791cfcb47bfe 100644 --- a/stand/uboot/Makefile +++ b/stand/uboot/Makefile @@ -10,6 +10,8 @@ LOADER_GZIP_SUPPORT?= no LOADER_BZIP2_SUPPORT?= no LOADER_DISK_SUPPORT?= yes +BINDIR= /boot/uboot + .include .include "${.CURDIR}/arch/${MACHINE_CPUARCH}/Makefile.inc" @@ -22,7 +24,6 @@ PROG= ubldr .endif NEWVERSWHAT= "U-Boot loader" ${MACHINE_ARCH} -BINDIR= /boot/uboot INSTALLFLAGS= -b WARNS?= 1 From nobody Tue Apr 16 20:13:39 2024 X-Original-To: dev-commits-src-branches@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 4VJwGW4pL7z5H0nR; Tue, 16 Apr 2024 20:13:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGW1psdz4vrK; Tue, 16 Apr 2024 20:13:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298419; 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=VN++eFmN5ImbxMpt8QwblzATiRnHEVOws3/PLJwx8bM=; b=p/ZNczG5dEQDz0uyz4r3TZalHUbLDdiPcodXuOlfHd01HZipFTsPhH+TxQ9YvQaNtdxUtP MSTL3HBtqx37/+q2scvbsbzMI9VCZahWKsT8+zWzWHyefiM//sGPANgvScKXr2/zRszPMT dSf4NQCfwKwbmZmsGLd4Px4emSMc5bErkkZigGR9LPvTA3ZAAgyeIkyOTDyTlpHNTeR9U1 W3YoAY6FZtK6keGbBHTZcTcMBlKtw36RXSIxI5pUtTx+dXYKOA7KKgy8F9uM5yHtmaZ3or qsf70soUw1y9tlAk/xOMY0k59eHfK/PS3oxY0meLDpRv5e/iIpDGgT4gmZJDJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298419; a=rsa-sha256; cv=none; b=SKGUgni+w8bpCPhXxWisWNFBa6ycN9aT5dEZKoSPsVjjOilZCVBisH8cfRoVFi3vJnXNVF ZnEYYurKrYfagsESdfqGt3rrl3NYudfJptu/pNMBwcLR5Q7a0Jnu+XoqMjAzzDZHMcZoZL 3q2BjXlv0qQxyeLw544aEdaaZbIgtgX7OdvnSH7xV1M9hgAhr+EebTH9Q6JwqtqdU5p0tb 5s+xB0t3du5Eal7qDGlr8n7rV/4I+zgndtfqhwcq2tgcWgL15bySbAoBs2R9Btov1ufuS2 MMYaHHskrgWS3Qez3So6Ws3BeVH7++eMUz0BsHlT/wDTdRQ7ZOCFhXv7UsD4og== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298419; 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=VN++eFmN5ImbxMpt8QwblzATiRnHEVOws3/PLJwx8bM=; b=BdxMr6djYwY7KmGIYck7DAoPMaUmMAD7nlmfI59eTkNeB6e2SGYcZJIEnnfbqrW1tUjirz +m/iO2kEKiThEPYJRgeDKHd8LahDZYGshFMZfiAW+b/Ub43KULpC132txKu0WMdM73M9z9 nC6o3qgArung0uAc8Y2N/y33dqLsBivC/o0nG5KuI1OpySlh2niXqdrtq/EKWVOq62oVmt 2+36Pzrb3kNgkByalpLpbQC078YrphmPlcv1Vxd42PmzL5muu4fnNq997bs7J78ZcMxEcM T4TdXs7lAWwqRcLwrkPj4+ddyVtD9BDFLQGBZ1JN94luY9/Y2Z+dFGpRxxvQJQ== 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 4VJwGW1F94zwwG; Tue, 16 Apr 2024 20:13:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDd7B040088; Tue, 16 Apr 2024 20:13:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDdOf040085; Tue, 16 Apr 2024 20:13:39 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:39 GMT Message-Id: <202404162013.43GKDdOf040085@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 41883f55a8f9 - stable/14 - loader.4th dictthreshold too small List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 41883f55a8f9f7755ac7f0c321694eeee2b765e8 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=41883f55a8f9f7755ac7f0c321694eeee2b765e8 commit 41883f55a8f9f7755ac7f0c321694eeee2b765e8 Author: Simon J. Gerraty AuthorDate: 2024-03-18 23:16:29 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:30 +0000 loader.4th dictthreshold too small The dictthreshold in stand/forth/loader.4th is too small resulting in full dictionary. Reviewed by: stevek, imp Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D44414 (cherry picked from commit a8eb3b365eb63d2a569b166f2dfc982967d3a7fa) --- stand/forth/loader.4th | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/forth/loader.4th b/stand/forth/loader.4th index 574077ea5710..db31461f5454 100644 --- a/stand/forth/loader.4th +++ b/stand/forth/loader.4th @@ -61,8 +61,8 @@ s" arch-i386" environment? [if] [if] [then] [then] [then] -256 dictthreshold ! \ 256 cells minimum free space -2048 dictincrease ! \ 2048 additional cells each time +512 dictthreshold ! \ cells minimum free space +2048 dictincrease ! \ additional cells each time include /boot/support.4th include /boot/color.4th From nobody Tue Apr 16 20:13:41 2024 X-Original-To: dev-commits-src-branches@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 4VJwGY6PZfz5H0qt; Tue, 16 Apr 2024 20:13:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGY3vvZz4vv3; Tue, 16 Apr 2024 20:13:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298421; 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=dI5OyGACdXLHuYi+kCzkuITPg0xUcH+FLdcDNDM4cZQ=; b=VIq+4E/KAv0ozAbM0j5aGvm4INB09uQexbJe/nQUoOg/pWC2uveSnUSmgbldX0zXMeNqn7 FQ3tFrD0/5vhkW5Hf7e5LZuWw8B4ek6z29lwVfBAFeGs0Xg90VbC6AkA738uzXntaM2THn WOETN1FEH3zpV0o39C/tFUWCZMWoBClWarF145XoANenck1/on4ttdVCeTdoemZ/6u/iSG TTpax+cSh3afC6z0qlm+UrO7WU24RyotHkx8gOOX07tP+BMcXOeM87xDfHspKb7YX/1q/k v+xiIwOGIsn8GePWaB7mBUUYJ2wwGCQCiNHctF7DpYbF6sjPO/zJNavcKdK7uw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298421; a=rsa-sha256; cv=none; b=FH4EC248JXLMfJe+QzdE80zUul/OeGoeWtJBBQMuRJ24s2AEkX7bzQC0V69JdJcf5fWMqo MVTukZJTJlb355RktlNBKq8ECSlxOd9ojWG6L432CjvG1JsDZhOyIw1l628Y6zj29ILOCv h8R0xnV8Cof159qPKVp2IaH8dCD7uKTfr5k1i+Qzu6eNkKACwJ0/7nepMYhsMDbjRr0roN xPpbyGOL4v1I0rif2k9V04GfNu1dpD2C0UuShG+1yQWHV0oFFTmOR/lKmRDqo4AkXd6IuA fmbjoCOaLYJanTB9mYxZvrnoY0eO0ntLUxFYX+lsQoNpxrNRy1GwpAEwIZSA7g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298421; 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=dI5OyGACdXLHuYi+kCzkuITPg0xUcH+FLdcDNDM4cZQ=; b=tpNgwVuS+efijWLA1uSbPjxZb9v/KuZyxU6XtRK0IUgwNyRNAsxL+bAxkUtxHBDoP74Uk9 zSckteRxvaQAYlw7/L+BPyB7SjQ7U4VBZYH4VIj6tK88YeDVKiKm7U32asBzdgTq7isrLL KjjOaxD1mK8oUaoo1FCiQCYzaCvZeHHy49Ugj+PIfhS/jalcSN03/VfTQHsey7co9U2rUl BiliJpvW90M0WKGJoQ9Zg858qscDjhtMtbWQv9BflWB3GarFeS2hjCq0u+mccfIzDNA9j7 k0SxxjrZiwfsnTTDhTgtnPY2JHYk7G6iKH9wbUizEjjEJXrQ6oWqR7mP6TUTqQ== 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 4VJwGY3TSfzxdn; Tue, 16 Apr 2024 20:13:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDf0X040212; Tue, 16 Apr 2024 20:13:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDf0J040209; Tue, 16 Apr 2024 20:13:41 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:41 GMT Message-Id: <202404162013.43GKDf0J040209@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 33d1ce86abcb - stable/14 - userboot: allow for overriding the version file location List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 33d1ce86abcb072bb0a9fb366aa91e888ea573f8 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=33d1ce86abcb072bb0a9fb366aa91e888ea573f8 commit 33d1ce86abcb072bb0a9fb366aa91e888ea573f8 Author: Stephen J. Kiernan AuthorDate: 2024-04-03 21:22:01 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:30 +0000 userboot: allow for overriding the version file location Use ?= when assigning VERSION_FILE Reviewed by: imp Obtained from: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D44624 (cherry picked from commit 112783ebbc313f0df73bbec8520a94aba4a4f33d) --- stand/userboot/userboot/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/userboot/userboot/Makefile b/stand/userboot/userboot/Makefile index 15ac8701e4d4..4674672bbec5 100644 --- a/stand/userboot/userboot/Makefile +++ b/stand/userboot/userboot/Makefile @@ -44,7 +44,7 @@ CFLAGS.main.c+= -I${SYSDIR}/contrib/openzfs/include/os/freebsd/zfs CWARNFLAGS.main.c += -Wno-implicit-function-declaration NEWVERSWHAT= "User boot ${LOADER_INTERP}" ${MACHINE_CPUARCH} -VERSION_FILE= ${.CURDIR}/../userboot/version +VERSION_FILE?= ${.CURDIR}/../userboot/version .if ${LOADER_INTERP} == ${LOADER_DEFAULT_INTERP} LINKS+= ${BINDIR}/${SHLIB_NAME} ${BINDIR}/userboot.so From nobody Tue Apr 16 20:13:40 2024 X-Original-To: dev-commits-src-branches@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 4VJwGX6xxXz5H0tM; Tue, 16 Apr 2024 20:13:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGX2tMhz4vf4; Tue, 16 Apr 2024 20:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298420; 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=FFPYW7HdB5xmHla47rgfn4YJKzbgptajagyIozOwbc8=; b=MKXj3crf8GmLQOLQWFIJRE60mrUZfqPEHmFTHFMkWeA94YX4IV9VoNHh5UPvZZ53/aXzFN czuYqAGdE2tFaAdMiv9rRXg7nUdqveEIxl3tjcr8Eaq8whXhUSLg6NnrMNRG1ZSOU/EJW9 8gQCQ6xDJFelpsTwIbo9qAlLEwW3BGGBQN3C798zE+Z51Vv3SMVyhVImoUMWvVIn68fSxi AGtUTzfmkYJ8jIJmZwMoiNyR6WauZY8wtY7QUYLH88V+osnfKRF4CC8Cede1tuE268Qv0D 4DqdrMcbvBKePO9hqVA2gQqdTGCE0bX6h4dTBcSNFHRkWbuVnfiyniwekU1ZcA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298420; a=rsa-sha256; cv=none; b=Ggh4Ygn6FNkon4s2WLGj+FaIxrijcgqNDlqPjLPbNwZL9gCJ/EWVLPpQzuFYUfYr8Tg205 tC4HQfHn2i8SDao9q6Y4b0AM76UXN+9y5PSDvuPD2KNiPvEzxeOUzZOE2zx0x8OR7v5u9D OBMAco8fkWf1BuXAjN+vKIYKlSH1L9LZJsstJJ/U9CYiqwN/BqJvNbSFbKiwFppkWTB/Cf JFwU4oQIyfjf8L5FjmXgyO7pWojPfpI8QEXqqpT4xhC4D+tnUr6dB0NTdCs2aiSmY+qYlc toi4/fy9qzmQb0IHa25kKHo4xSyZZRf02F9AXbo8yWx/LJERGvtgA3CTsRFR3g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298420; 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=FFPYW7HdB5xmHla47rgfn4YJKzbgptajagyIozOwbc8=; b=p+9iMLCDtPaj3KK7IuajZaVl+oecrtn37orioOCnAfin48U+QBiAIt1P7pQxYsv7t10YBD Wxwxl7+bhPvF3LHgzhsPPRnHpO6kPTnWlpAeVVrM5J17H1nZY/9v7Ax/5w9TMfAZmK9hV1 mOqNlMYPvDbN8GabyH3M50+MJfLpXx5+v3kfVzMg0VKOji7yo49O58i/MiA9uRrARPz+0G uneFYMowRqnGDrq+9JJqh+rF+diOtxAiUh7p9qlrjv3dWKdA6TxbUa4N1i+qvWt0Tq93VG NkOjmYRQplldBMlHKz9yarw5KakWLjWUUUlvbqddmA5kTstBk5f0DXuwjXharQ== 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 4VJwGX2BCRzxdm; Tue, 16 Apr 2024 20:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDer4040155; Tue, 16 Apr 2024 20:13:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDefL040152; Tue, 16 Apr 2024 20:13:40 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:40 GMT Message-Id: <202404162013.43GKDefL040152@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: e40703a705e5 - stable/14 - stand/efi: Changes to efichar to allow it to be used in the kernel List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e40703a705e598ab0faa8f43c0f75607a269c0db Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e40703a705e598ab0faa8f43c0f75607a269c0db commit e40703a705e598ab0faa8f43c0f75607a269c0db Author: Stephen J. Kiernan AuthorDate: 2024-03-27 22:37:48 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:30 +0000 stand/efi: Changes to efichar to allow it to be used in the kernel Replace malloc/free with EFICHAR_MALLOC and EFICHAR_FREEE macros. Obtained from: Juniper Networks, Inc. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44541 (cherry picked from commit fe429e6794d322636e7c1e520d50ec0cb711dd14) --- stand/efi/include/efichar.h | 8 ++++++++ stand/efi/libefi/efichar.c | 17 ++++++++++++----- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/stand/efi/include/efichar.h b/stand/efi/include/efichar.h index 4460f5efdcef..0a40906aeedf 100644 --- a/stand/efi/include/efichar.h +++ b/stand/efi/include/efichar.h @@ -37,4 +37,12 @@ int ucs2_to_utf8(const efi_char *, char **); int utf8_to_ucs2(const char *, efi_char **, size_t *); int ucs2len(const efi_char *); +#ifdef _KERNEL +#define EFICHAR_MALLOC(sz) malloc((sz), M_TEMP, M_WAITOK | M_ZERO) +#define EFICHAR_FREE(sz) free((sz), M_TEMP) +#else +#define EFICHAR_MALLOC(sz) malloc(sz) +#define EFICHAR_FREE(sz) free(sz) +#endif + #endif /* _BOOT_EFI_EFICHAR_H_ */ diff --git a/stand/efi/libefi/efichar.c b/stand/efi/libefi/efichar.c index 86642d325754..659212799b6a 100644 --- a/stand/efi/libefi/efichar.c +++ b/stand/efi/libefi/efichar.c @@ -25,14 +25,21 @@ */ #include +#ifndef _KERNEL #include +#endif #ifdef _STANDALONE #include #else +#ifdef _KERNEL +#include +#include +#else #include #include #include #include +#endif #include #include #endif @@ -87,7 +94,7 @@ ucs2_to_utf8(const efi_char *nm, char **name) if (*name != NULL) cp = *name; else - cp = *name = malloc(sz); + cp = *name = EFICHAR_MALLOC(sz); if (*name == NULL) return (ENOMEM); @@ -114,7 +121,7 @@ ucs2_to_utf8(const efi_char *nm, char **name) if (len >= sz) { /* Absent bugs, we'll never return EOVERFLOW */ if (freeit) { - free(*name); + EFICHAR_FREE(*name); *name = NULL; } return (EOVERFLOW); @@ -135,7 +142,7 @@ utf8_to_ucs2(const char *name, efi_char **nmp, size_t *len) sz = strlen(name) * 2 + 2; if (*nmp == NULL) - *nmp = malloc(sz); + *nmp = EFICHAR_MALLOC(sz); if (*nmp == NULL) return (ENOMEM); nm = *nmp; @@ -183,7 +190,7 @@ utf8_to_ucs2(const char *name, efi_char **nmp, size_t *len) } if (sz < 2) { if (freeit) { - free(nm); + EFICHAR_FREE(nm); *nmp = NULL; } return (EDOOFUS); @@ -194,7 +201,7 @@ utf8_to_ucs2(const char *name, efi_char **nmp, size_t *len) return (0); ilseq: if (freeit) { - free(nm); + EFICHAR_FREE(nm); *nmp = NULL; } return (EILSEQ); From nobody Tue Apr 16 20:13:42 2024 X-Original-To: dev-commits-src-branches@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 4VJwGb1sFWz5H0lf; Tue, 16 Apr 2024 20:13:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJwGZ4vlSz3wbw; Tue, 16 Apr 2024 20:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298422; 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=XBZeg8I0axLMpg7hg9KKZXAZg7S7VPSp1IZwY9dfsHQ=; b=tolVijMiY0glkFoRzWREzmiq0TpJ2IPEeOXtrzu+Sp58MR6a8SmO22pWZfxfNLD8beyjCn B75UI18zn3wU8ig1Tl4kLirG7RFFdPX/Xckjs20frjCMs7KpNK3qpxIv3Nr6RBZu6j6Hty NRHg5kdvIsKD/g9jRjOx/U2F/FUmoNhgt6L13os9D8QM6zmNt1bnQfwttsb0YfVMf3bV7n TkEz9JavCFnXc/yPYtzaIRHtFPdrtYqbp3n9jvKERKqB/ST5dzY9DWBsdLGxtUdXFMF7zu JuI6A4PGQLXQE8Jk3hXcs/xI0fzX6yy9+iV8weHPenN9HiGRTZpqFIy51GggkQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713298422; a=rsa-sha256; cv=none; b=rVIPhDeGCWI/rbXUb+WXl9pan30G459QpZbtd60dNdd35nIzB2idFsOmJiJoxDyn7fFpzD wysFKKe4Wgo/1OppJ4JoX7g5qEYgFqn8i4mowIQwGX8YgjqWV0f/PS9Sth+CWahoL7vTs0 slQey3z3Ex4GjllMh/Q5hNB+Lmwug5A2Whiskfw0HshK3yYaVTZhfdsxIAvLihHGlokiej UdT7bGmHz7OylUnvnKAhE3W6WKpTnYXH6GEFhXRpwdh+1L4o26tlFSUNLXus/aBu9xw6TY fSV6AfUxHu3jAKMUU5aZXxKDPFs/Bh4jAzBbdfqpZPiyestBHO0V5np7sfMXIg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713298422; 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=XBZeg8I0axLMpg7hg9KKZXAZg7S7VPSp1IZwY9dfsHQ=; b=pS/FC4icAKGZSRXrVsd/lwfVEFENUGsONMNQzdOswIAzg7424ZcCjxUWM27Av09kqZo7hU Qv3/o6SWbxRMPsHSf3pGo1mP94YsZTT6c4x4hAWgHr4/fYqDAzy7GLGMWCpcps1KH9N/Pt ECvfxbVb58eliMEgKimgJFWJxtqCU76eRelcRvw5ygddEeZ+V4f0JQJSFskW4OrtbC6Bm2 W7mnogSRb5fGkPFTbQNyHPiQE8xgcIxyZmp1hpb4S4pZkOsCMJ7ZljOcagroVcCKXX6Ccj xnO74c+ZyA+dqaKDp26c2a6SquY8ZHxLBLTf9hVABxcen4GPL+N6HDaCD8A7Kw== 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 4VJwGZ4W5Hzxdp; Tue, 16 Apr 2024 20:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GKDgtf040253; Tue, 16 Apr 2024 20:13:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GKDgJu040250; Tue, 16 Apr 2024 20:13:42 GMT (envelope-from git) Date: Tue, 16 Apr 2024 20:13:42 GMT Message-Id: <202404162013.43GKDgJu040250@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d1fb333f35fb - stable/14 - stand: Install gptboot.efi(8) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d1fb333f35fb34692abe6d681df7bf2ef287468a Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d1fb333f35fb34692abe6d681df7bf2ef287468a commit d1fb333f35fb34692abe6d681df7bf2ef287468a Author: Warner Losh AuthorDate: 2024-04-04 15:42:06 +0000 Commit: Warner Losh CommitDate: 2024-04-16 19:54:30 +0000 stand: Install gptboot.efi(8) We need to include bsd.init.mk first when we have man pages in the boot loader. Sponsored by: Netflix (cherry picked from commit cfcf475a669738382ac75ea50eb03a20280f7662) --- stand/efi/gptboot/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/stand/efi/gptboot/Makefile b/stand/efi/gptboot/Makefile index 82d4b3b8c464..7d4c225bc5d4 100644 --- a/stand/efi/gptboot/Makefile +++ b/stand/efi/gptboot/Makefile @@ -1,3 +1,4 @@ +.include # ZFS is not supported, we want debugging until this is vetted and # we don't want the gptboot.efifat thing created. From nobody Tue Apr 16 21:42:44 2024 X-Original-To: dev-commits-src-branches@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 4VJyFJ65Pyz5H7rb; Tue, 16 Apr 2024 21:42: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFJ5M18z4YNx; Tue, 16 Apr 2024 21:42:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303764; 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=ksp2tOHJzZSg9VAvCwU3/Y8lClKPrxAqzTmThxtIxs4=; b=m4mlitHj63sQWD8LH3pOGcL6y7sIgb0m2EL9M9b4iYbf1CUzlSAzIVoOfeOsx9+ctEXD17 6UflFg+lFsAyXRX+TYr8wFpQt6Sr2EX/qeQjdib5h9ySDyrZhCRGv+5pPSrEq2KcfckVOs 5BnRc2uFdzJ8i6kNdEZUPkOZri2Nf44GleNQzr3HtBvI+/bwnCjMo5w+sgdz8coPJr4jdj TXR6EKEeJiMngrRBE93/h04u/rvJWQ5cUHWBplOgh2O9rf4j1jnPCIg0y26+U1nRXZAWcF zgtO6sIUoZ7cY6WWvYqSD5+oDqYBTHA3WgBAPZLfmE/+UJ9NAEQHWJN9XGZNSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303764; a=rsa-sha256; cv=none; b=VeC5WHQoH1zcENnu+tLZzWT/O6iwN9E8USKoe+2Qzwtqp6I5ZcG6LfA3fmlBeeKqM5EKbi R8HDhv/uUDK6mRj+seNgPeZ/o8gyrLJJ2pLNL6wjSZIvZNnHBk4N8RScXB3qK7zhbhM/eM mXgWgg/nGhEbFjAzBFpsQiy7i7WOKCr6tD1qXWRDdTFJxfEFQJpEpZB7NGfKjhdjCv9uxj xugcVkYVfqlr0FIBDIoNiA93NqIUqcmocLsij+0ysUO/2y0pUDbi1YgG+dOv9AITbiiB3F pB1HwSBiffhXtlr68OzE6HpDKgh2boj1Q9vMD9QU3akcfy5DB/DMNESN8yMuGQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303764; 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=ksp2tOHJzZSg9VAvCwU3/Y8lClKPrxAqzTmThxtIxs4=; b=HS3Wogpk1pakkNWuMxagoHA75XZHzFKwEYJL3T9dp83Z8gTqeFxPvAEXU2wwX7XSoq9z9n BWO33vA4dVasSda1He3SxYhi04geCimWVg9XpKBhT3Ws6LICnROKNthPqxSNRRjNtQlk8j xg5CmOfsZkZlq17jplONFIk2D4MSPrS0x82r67519YFPr88glQwC3sbvhKIxZlxYq3NSTE ar3n/2Hceml0FeU3ucmbiQt8CSAhp50hmj3Wf2tHR3w/af7HTP6kZrtw9A+DbLqNk2POSy SlEZHV490NhNkoZonmJVDkGyV04YHXAAuRKkxs/y4SnKLy3fl2cnJRfeUcaHsQ== 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 4VJyFJ4ySXz10cX; Tue, 16 Apr 2024 21:42:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgiff094425; Tue, 16 Apr 2024 21:42:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgiTw094422; Tue, 16 Apr 2024 21:42:44 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:44 GMT Message-Id: <202404162142.43GLgiTw094422@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 02eaed648f40 - stable/14 - gicv3: Change how we initialize its children. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 02eaed648f401f2aceaa1cea3fb2ca2e949b47e4 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=02eaed648f401f2aceaa1cea3fb2ca2e949b47e4 commit 02eaed648f401f2aceaa1cea3fb2ca2e949b47e4 Author: Warner Losh AuthorDate: 2024-02-28 14:08:15 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:27:35 +0000 gicv3: Change how we initialize its children. The current code is written such that all the attach routines can do so in parallel. However, newbus serializes children today, and is likely to do so in the future. Only allocate memory for the first time. Add an assertion that this memory is allocated for larger units. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44032 (cherry picked from commit 15c8a610a80dfe1980e043174d0fcc8034868676) --- sys/arm64/arm64/gicv3_its.c | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 777e20649f33..16ea48f49b7f 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -292,8 +292,6 @@ struct gicv3_its_softc { vm_page_t ma; /* fake msi page */ }; -static void *conf_base; - typedef void (its_quirk_func_t)(device_t); static its_quirk_func_t its_quirk_cavium_22375; @@ -681,20 +679,26 @@ gicv3_its_table_init(device_t dev, struct gicv3_its_softc *sc) static void gicv3_its_conftable_init(struct gicv3_its_softc *sc) { - void *conf_table; - - conf_table = atomic_load_ptr(&conf_base); - if (conf_table == NULL) { - conf_table = contigmalloc(LPI_CONFTAB_SIZE, - M_GICV3_ITS, M_WAITOK, 0, LPI_CONFTAB_MAX_ADDR, - LPI_CONFTAB_ALIGN, 0); + /* note: we assume the ITS children are serialized by the parent */ + static void *conf_table; - if (atomic_cmpset_ptr((uintptr_t *)&conf_base, - (uintptr_t)NULL, (uintptr_t)conf_table) == 0) { - contigfree(conf_table, LPI_CONFTAB_SIZE, M_GICV3_ITS); - conf_table = atomic_load_ptr(&conf_base); - } + /* + * The PROPBASER is a singleton in our parent. We only set it up the + * first time through. conf_table is effectively global to all the units + * and we rely on subr_bus to serialize probe/attach. + */ + if (conf_table != NULL) { + sc->sc_conf_base = conf_table; + return; } + + /* + * Just allocate contiguous pages. We'll configure the PROPBASER + * register later in its_init_cpu_lpi(). + */ + conf_table = contigmalloc(LPI_CONFTAB_SIZE, + M_GICV3_ITS, M_WAITOK, 0, LPI_CONFTAB_MAX_ADDR, + LPI_CONFTAB_ALIGN, 0); sc->sc_conf_base = conf_table; /* Set the default configuration */ From nobody Tue Apr 16 21:42:45 2024 X-Original-To: dev-commits-src-branches@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 4VJyFL0Bhxz5H8YZ; Tue, 16 Apr 2024 21:42:46 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFK6Jz6z4YjR; Tue, 16 Apr 2024 21:42:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303765; 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=q4uXRNVztJoW3bgKqhReSghlALVIVwic+wwDT3wbs14=; b=NAcc145IKx08UPl5uMZyWgzq9gMNzb98/kTnEE1fVoX1kQ0vtTajQoArtsx0sqoHTdmZ2L giQoyCRswGe4GXtn3wuzrY/KEdsPhPowX3ZAZzF8lV4Cl0RJc7Gkh8FUX78Hxr6eVtAwaQ 9YZE2Sg5Zid8KLU/PvawkScd6zOV87MQxRNMt7BMHxE/8fhJ+eceWIuf/F+8q5Y9k4dRvC B+uSf6SaSJTYQ5V9OjZtRGqHXe2l21oAeMTnS3XX4OQkSRagnbMTV/5y8eyaAamUPdEIWD pIb4GDh2xPQKPWH5qU5lt7Zbsi2G3k9UjtD1fRR1+mPh3y1PGWxeygALrR+oQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303765; a=rsa-sha256; cv=none; b=AUuqspfY3QdoWZfA5fgvv9b2+phrXZUhfC+p70yv32bMwRWs5FqCLwl9wrsdE6uSyt7RNU iP3PecqHh7OTKrHcIPi79ihBU/8iUHyb+bunq+2lncwhTO+Q9GvSdOXSCFVW/dUVaLBhYH R2QcQtxt330pat+tY40f47ibymhXIb4rxuSScGehrHakepl6sEBEjHtpRraJouFcY1hdVb aUYvQzsa6a9lRiSQSBJBu+fN5j38xR4IxrCPPPsO/u4gFcZJ1cg9ne9jzGbCR0uDBWjqYg HPzCClJ8eBlfusNh9BHS+IgymNwRKvlDM5MN77QUtJSA1q4/UhiKeEJ9XzjajQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303765; 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=q4uXRNVztJoW3bgKqhReSghlALVIVwic+wwDT3wbs14=; b=Fn4IbrqlsVpLUtAWJtUnIkKE0cgGw2dSwByiqHYUwKXjZsjtYLc5iEQ+3WAxhCN89zSckj 8QF1cuQdlvPe5GJ4bjKgrp0AUyU4xFbC/3pwyknzjQHfxx93ikiZLH1EGLB8b6rxm9RHEz tEfzB9bIWubEynA8N2S1be75ogZsisqT1DAr/7QMkWlFepjuR+p+9KEBTuDZjPUHtrvj1n k2WjuQZB0NXd6ErjsGfiT+ro30k153cuoVnBrP8CtzuWWkPYTSoQltcMN1VHMttLR8eZxw MxykKNPak3h2UHMh9gGSpCKlIpaN/rZl+Z2YMAKl4Im/7LlGkYS1QqFJBQWCAg== 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 4VJyFK5wgKz10cY; Tue, 16 Apr 2024 21:42:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgjrl094479; Tue, 16 Apr 2024 21:42:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgjMK094476; Tue, 16 Apr 2024 21:42:45 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:45 GMT Message-Id: <202404162142.43GLgjMK094476@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 531302411740 - stable/14 - gicv3: Panic if the gicv3 already running List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5313024117409f58cbe6af04382768df1572d33b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5313024117409f58cbe6af04382768df1572d33b commit 5313024117409f58cbe6af04382768df1572d33b Author: Warner Losh AuthorDate: 2024-02-28 14:08:24 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:27:35 +0000 gicv3: Panic if the gicv3 already running Due to undefined behavior, it's impossible to re-program a gicv3 ITS table once it's programmed once. Memory corruption happens otherwise. Panic if we detect the LPI is already enabled. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44033 (cherry picked from commit 51c57ca92ed3d0caf8f3e8c61345ac670d494901) --- sys/arm64/arm64/gicv3_its.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 16ea48f49b7f..c9eff1e9f474 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -681,6 +681,8 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) { /* note: we assume the ITS children are serialized by the parent */ static void *conf_table; + device_t gicv3; + uint32_t ctlr; /* * The PROPBASER is a singleton in our parent. We only set it up the @@ -692,13 +694,20 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) return; } - /* - * Just allocate contiguous pages. We'll configure the PROPBASER - * register later in its_init_cpu_lpi(). - */ - conf_table = contigmalloc(LPI_CONFTAB_SIZE, - M_GICV3_ITS, M_WAITOK, 0, LPI_CONFTAB_MAX_ADDR, - LPI_CONFTAB_ALIGN, 0); + gicv3 = device_get_parent(sc->dev); + ctlr = gic_r_read_4(gicv3, GICR_CTLR); + if ((ctlr & GICR_CTLR_LPI_ENABLE) != 0) { + panic("gicv3 already enabled, can't reprogram."); + } else { + + /* + * Otherwise just allocate contiguous pages. We'll configure the + * PROPBASER register later in its_init_cpu_lpi(). + */ + conf_table = contigmalloc(LPI_CONFTAB_SIZE, + M_GICV3_ITS, M_WAITOK, 0, LPI_CONFTAB_MAX_ADDR, + LPI_CONFTAB_ALIGN, 0); + } sc->sc_conf_base = conf_table; /* Set the default configuration */ From nobody Tue Apr 16 21:42:46 2024 X-Original-To: dev-commits-src-branches@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 4VJyFM20n7z5H86T; Tue, 16 Apr 2024 21:42:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFM0Fjlz4Yfw; Tue, 16 Apr 2024 21:42:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303767; 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=QE74C3Che1abXNm5lpYvE5a5lxoGhJJRkgcYCzxnEeo=; b=nMLPOihRjU+FnSF+1dJySXDQGCS6fBb86fLK29z8TQvxx+xC0w8VPZ3lGIZIOxCvKdkEi2 bkBKRmlvOc9yAM7/HwUJZsHvikr54bmea2MCSV3lpR+lWAGuoJ8h51mArMCgMude1md/Ai 2Ez3CWF6uiVjb115Au3i+0CE0W78f04Jy0AXLB+pPlPVmhn0IU9PYJ+xGeYLMapOAGWPpL AWhbG4pg2lJ6KwO36221sAoMWvruDl7VNifHqHNSQmAAs0MCusHfLIQ68tGaV0gznhtAe+ FA9yS5resJa1a5eRRFS1RVMUsaqam1jGreP9yGGNVY1RLGSNXw/Q0tK5EPEGQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303767; a=rsa-sha256; cv=none; b=WCKkqavkvcqgJWlwgrhIQMcQmk5pKgSs0Tu2b5eXzd8PIOANvHkl+wD7a/J5odBP9V5/O1 Ebkadxni1OCcQgL3jS3vhGeC2ocGfMqOHAyDd7dqUgBfvI9ZzGbnaOG7A7kMv6pdLEQxeA 9BFD08EyLY0yiJphdUTk5IITQlEmDVeUdiOgPKuwpaxv2mEmiZ6aKJnpLSGFwhKfwTapat lqv7gYQ677FZ7VP7dXIBqqngPDTdc3Zympp2zpklREh9X5o+3QMQjS+Xn3BbftK6G+rUBj bmSAGYDSxcjoGPArbSvsy0x43Ky3dNuw/Pec9CVXNRRtjq5xOIGJ9IkfOzneIQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303767; 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=QE74C3Che1abXNm5lpYvE5a5lxoGhJJRkgcYCzxnEeo=; b=rCkhyDGBhqVlD2X4jk95ScxIToz04x6Ue4PjBny2ZxUrR2z9KpZNKBL1F/brhTQNN3uf81 citsa0QpwYY5z1rwf69GgswDf1HpKSeV+0wPkQFzPBcvX9I5LC0mwsm4flv9BZbN0ozzoM 4krxAfb/AHYALiauQx6eRtfT1cVEsqjW6u4j9nFRcTMnyTaP/WMWy0lwpU6WYElBiUJtze QKcXS0yrKZd74Krtp+M89Fk8DbnXQMkwAaQNU1Pvsnfv6ESgDNUSb6J4kjvbW4bspAFnj+ SWCBth5jGrlSeTfKchaqgC/1YazQroam+c+JwTeNy4fZt2r413g+CS4lY0Ga/w== 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 4VJyFL6xsnz10Lp; Tue, 16 Apr 2024 21:42:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgkb4094531; Tue, 16 Apr 2024 21:42:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgk8A094528; Tue, 16 Apr 2024 21:42:46 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:46 GMT Message-Id: <202404162142.43GLgk8A094528@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 9eea5eb52a0e - stable/14 - gicv3: Don't allocate pend_base if we're already started List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9eea5eb52a0eb61c46da0721176eac2c0d820531 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9eea5eb52a0eb61c46da0721176eac2c0d820531 commit 9eea5eb52a0eb61c46da0721176eac2c0d820531 Author: Warner Losh AuthorDate: 2024-02-28 14:08:32 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:37 +0000 gicv3: Don't allocate pend_base if we're already started If the gicv3 is already started, then don't allocate memory for the pend_base tables. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44034 (cherry picked from commit ddd98f5a626df5de51fd5c2460592d9b95a49179) --- sys/arm64/arm64/gicv3_its.c | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index c9eff1e9f474..de65d130ce91 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -287,6 +287,7 @@ struct gicv3_its_softc { #define ITS_FLAGS_CMDQ_FLUSH 0x00000001 #define ITS_FLAGS_LPI_CONF_FLUSH 0x00000002 #define ITS_FLAGS_ERRATA_CAVIUM_22375 0x00000004 +#define ITS_FLAGS_LPI_PREALLOC 0x00000008 u_int sc_its_flags; bool trace_enable; vm_page_t ma; /* fake msi page */ @@ -681,6 +682,7 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) { /* note: we assume the ITS children are serialized by the parent */ static void *conf_table; + int extra_flags = 0; device_t gicv3; uint32_t ctlr; @@ -697,6 +699,7 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) gicv3 = device_get_parent(sc->dev); ctlr = gic_r_read_4(gicv3, GICR_CTLR); if ((ctlr & GICR_CTLR_LPI_ENABLE) != 0) { + extra_flags = ITS_FLAGS_LPI_PREALLOC; panic("gicv3 already enabled, can't reprogram."); } else { @@ -709,6 +712,7 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) LPI_CONFTAB_ALIGN, 0); } sc->sc_conf_base = conf_table; + sc->sc_its_flags |= extra_flags; /* Set the default configuration */ memset(sc->sc_conf_base, GIC_PRIORITY_MAX | LPI_CONF_GROUP1, @@ -721,19 +725,20 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) static void gicv3_its_pendtables_init(struct gicv3_its_softc *sc) { - int i; - for (i = 0; i <= mp_maxid; i++) { - if (CPU_ISSET(i, &sc->sc_cpus) == 0) - continue; + if ((sc->sc_its_flags & ITS_FLAGS_LPI_PREALLOC) == 0) { + for (int i = 0; i <= mp_maxid; i++) { + if (CPU_ISSET(i, &sc->sc_cpus) == 0) + continue; - sc->sc_pend_base[i] = (vm_offset_t)contigmalloc( - LPI_PENDTAB_SIZE, M_GICV3_ITS, M_WAITOK | M_ZERO, - 0, LPI_PENDTAB_MAX_ADDR, LPI_PENDTAB_ALIGN, 0); + sc->sc_pend_base[i] = (vm_offset_t)contigmalloc( + LPI_PENDTAB_SIZE, M_GICV3_ITS, M_WAITOK | M_ZERO, + 0, LPI_PENDTAB_MAX_ADDR, LPI_PENDTAB_ALIGN, 0); - /* Flush so the ITS can see the memory */ - cpu_dcache_wb_range((vm_offset_t)sc->sc_pend_base[i], - LPI_PENDTAB_SIZE); + /* Flush so the ITS can see the memory */ + cpu_dcache_wb_range((vm_offset_t)sc->sc_pend_base[i], + LPI_PENDTAB_SIZE); + } } } From nobody Tue Apr 16 21:42:48 2024 X-Original-To: dev-commits-src-branches@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 4VJyFN4ghrz5H8Sq; Tue, 16 Apr 2024 21:42:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFN1JhFz4Yqt; Tue, 16 Apr 2024 21:42:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303768; 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=g6819YOhJhXCfGQHRamGJ+EkLHTdEzwGNuF5R4IWomk=; b=NU1R5b6iiM4shW2ebNkdR6X4i2w6a9WHTkJIDgWWNXHYNug4A2VxHqsmurdbclXunZj7z1 GOFIYV0bumfbcG4onBVGnOBgMolVJqHHiOB+1x/Dbs5yC3w9RPK347dK/xfldQciWKpiPj yG6w/GLS9u72asZZWbG8mjjYG1J0jy8eS30e9eMRR/nG3HVIyeX9f7pcA12zyngYpJj/YY OkoN1WgO2szPNE9P5VaAxoOJJqstVeYkhMmx38Eh+/wt+qVr/1/xc/ZdvNLTXloZ1FccTv kDhl1FmKmZJvtbxf6P+U1dOy0PpabiO3xtLRCv3eLMxge7OXmEJZI63INpqcmA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303768; a=rsa-sha256; cv=none; b=Dcb8K9mCHXp29hYLAinI4Vmv4epsmu98LFNghawNF7mPD2dD1E8rXBznepCNYkPBo8YXUH SfwRGnYYePqh/5vQ/Xb5FjrLuwNh/r+4ShAi3HL6wELW5pAAgbUCCHGWXbQq4xl+0vNNKh tRTI0/LvcBTcfnoG/S4oF4mgEFIl1ol+LZFiWSh3BX4kjKC7lXaO2Q6kMKXsO26GDijl1w w+iCNbbcPau5i+8wNNWtrJeUSSjqG8fRdxY8ml1mYsZvA7m3P/78DWztWm0pa+BtvgIM0a AiY9ZxCOQw3femI6IanMQyg8AD+N8m+U8e3ukwnkQCA5KhmaAlz1Yl2uNXbIUA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303768; 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=g6819YOhJhXCfGQHRamGJ+EkLHTdEzwGNuF5R4IWomk=; b=bT0GSMhSMpChNpp7ifDfcDoLtd2FrYSFZwRQlVabtel9W96o+oPx+twfPk4Nv4iB5V1SXj 02+krMalSnL41IjX+Ua/H8XCLyQLH7M333sIsZxYJpKqciiecuRqCZqgJDZh5I4puC8x4W 7bIafxE14FZVed4kxRkKSXT33Q3802DCyiQvsfl+EgWp6JtgArdE+XTXtxx9q4sBH2gwWZ 4mHqqPo52woR0rcadBQ3QqubEyTusPbBVp/cn9JP0YNTwnHTpkRJc+ngWofb8jgOhSeirU zk8PyphFTC9dgvbPv+0GFght6jggufxwR2/EVjlyI7FFYakv8LztjgpBjkYODg== 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 4VJyFN0vVtz10NK; Tue, 16 Apr 2024 21:42:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgmL4094588; Tue, 16 Apr 2024 21:42:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgmqv094585; Tue, 16 Apr 2024 21:42:48 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:48 GMT Message-Id: <202404162142.43GLgmqv094585@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: bfb3b0e7065f - stable/14 - gicv3: Only set the redistributor base if we're not prealloced List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bfb3b0e7065f0cee980037bd9ef7afc78f68d7b2 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=bfb3b0e7065f0cee980037bd9ef7afc78f68d7b2 commit bfb3b0e7065f0cee980037bd9ef7afc78f68d7b2 Author: Warner Losh AuthorDate: 2024-02-28 14:08:39 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:40 +0000 gicv3: Only set the redistributor base if we're not prealloced Only set the redistributor base if we're not reallocated. If we are preallocated, leave it all alone. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44035 (cherry picked from commit ae84491a3594c542f2aedc9340581cbb30386c1e) --- sys/arm64/arm64/gicv3_its.c | 134 +++++++++++++++++++++++--------------------- 1 file changed, 71 insertions(+), 63 deletions(-) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index de65d130ce91..51e7251b9ffd 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -746,81 +746,89 @@ static void its_init_cpu_lpi(device_t dev, struct gicv3_its_softc *sc) { device_t gicv3; - uint64_t xbaser, tmp; + uint64_t xbaser, tmp, size; uint32_t ctlr; u_int cpuid; gicv3 = device_get_parent(dev); cpuid = PCPU_GET(cpuid); - /* Disable LPIs */ - ctlr = gic_r_read_4(gicv3, GICR_CTLR); - ctlr &= ~GICR_CTLR_LPI_ENABLE; - gic_r_write_4(gicv3, GICR_CTLR, ctlr); - - /* Make sure changes are observable my the GIC */ - dsb(sy); - /* - * Set the redistributor base + * Set the redistributor base. If we're reusing what we found on boot + * since the gic was already running, then don't touch it here. We also + * don't need to disable / enable LPI if we're not changing PROPBASER, + * so only do that if we're not prealloced. */ - xbaser = vtophys(sc->sc_conf_base) | - (GICR_PROPBASER_SHARE_IS << GICR_PROPBASER_SHARE_SHIFT) | - (GICR_PROPBASER_CACHE_NIWAWB << GICR_PROPBASER_CACHE_SHIFT) | - (flsl(LPI_CONFTAB_SIZE | GIC_FIRST_LPI) - 1); - gic_r_write_8(gicv3, GICR_PROPBASER, xbaser); - - /* Check the cache attributes we set */ - tmp = gic_r_read_8(gicv3, GICR_PROPBASER); - - if ((tmp & GICR_PROPBASER_SHARE_MASK) != - (xbaser & GICR_PROPBASER_SHARE_MASK)) { - if ((tmp & GICR_PROPBASER_SHARE_MASK) == - (GICR_PROPBASER_SHARE_NS << GICR_PROPBASER_SHARE_SHIFT)) { - /* We need to mark as non-cacheable */ - xbaser &= ~(GICR_PROPBASER_SHARE_MASK | - GICR_PROPBASER_CACHE_MASK); - /* Non-cacheable */ - xbaser |= GICR_PROPBASER_CACHE_NIN << - GICR_PROPBASER_CACHE_SHIFT; - /* Non-shareable */ - xbaser |= GICR_PROPBASER_SHARE_NS << - GICR_PROPBASER_SHARE_SHIFT; - gic_r_write_8(gicv3, GICR_PROPBASER, xbaser); + if ((sc->sc_its_flags & ITS_FLAGS_LPI_PREALLOC) == 0) { + /* Disable LPIs */ + ctlr = gic_r_read_4(gicv3, GICR_CTLR); + ctlr &= ~GICR_CTLR_LPI_ENABLE; + gic_r_write_4(gicv3, GICR_CTLR, ctlr); + + /* Make sure changes are observable my the GIC */ + dsb(sy); + + size = (flsl(LPI_CONFTAB_SIZE | GIC_FIRST_LPI) - 1); + + xbaser = vtophys(sc->sc_conf_base) | + (GICR_PROPBASER_SHARE_IS << GICR_PROPBASER_SHARE_SHIFT) | + (GICR_PROPBASER_CACHE_NIWAWB << GICR_PROPBASER_CACHE_SHIFT) | + size; + + gic_r_write_8(gicv3, GICR_PROPBASER, xbaser); + + /* Check the cache attributes we set */ + tmp = gic_r_read_8(gicv3, GICR_PROPBASER); + + if ((tmp & GICR_PROPBASER_SHARE_MASK) != + (xbaser & GICR_PROPBASER_SHARE_MASK)) { + if ((tmp & GICR_PROPBASER_SHARE_MASK) == + (GICR_PROPBASER_SHARE_NS << GICR_PROPBASER_SHARE_SHIFT)) { + /* We need to mark as non-cacheable */ + xbaser &= ~(GICR_PROPBASER_SHARE_MASK | + GICR_PROPBASER_CACHE_MASK); + /* Non-cacheable */ + xbaser |= GICR_PROPBASER_CACHE_NIN << + GICR_PROPBASER_CACHE_SHIFT; + /* Non-shareable */ + xbaser |= GICR_PROPBASER_SHARE_NS << + GICR_PROPBASER_SHARE_SHIFT; + gic_r_write_8(gicv3, GICR_PROPBASER, xbaser); + } + sc->sc_its_flags |= ITS_FLAGS_LPI_CONF_FLUSH; } - sc->sc_its_flags |= ITS_FLAGS_LPI_CONF_FLUSH; - } - /* - * Set the LPI pending table base - */ - xbaser = vtophys(sc->sc_pend_base[cpuid]) | - (GICR_PENDBASER_CACHE_NIWAWB << GICR_PENDBASER_CACHE_SHIFT) | - (GICR_PENDBASER_SHARE_IS << GICR_PENDBASER_SHARE_SHIFT); - - gic_r_write_8(gicv3, GICR_PENDBASER, xbaser); - - tmp = gic_r_read_8(gicv3, GICR_PENDBASER); - - if ((tmp & GICR_PENDBASER_SHARE_MASK) == - (GICR_PENDBASER_SHARE_NS << GICR_PENDBASER_SHARE_SHIFT)) { - /* Clear the cahce and shareability bits */ - xbaser &= ~(GICR_PENDBASER_CACHE_MASK | - GICR_PENDBASER_SHARE_MASK); - /* Mark as non-shareable */ - xbaser |= GICR_PENDBASER_SHARE_NS << GICR_PENDBASER_SHARE_SHIFT; - /* And non-cacheable */ - xbaser |= GICR_PENDBASER_CACHE_NIN << - GICR_PENDBASER_CACHE_SHIFT; - } + /* + * Set the LPI pending table base + */ + xbaser = vtophys(sc->sc_pend_base[cpuid]) | + (GICR_PENDBASER_CACHE_NIWAWB << GICR_PENDBASER_CACHE_SHIFT) | + (GICR_PENDBASER_SHARE_IS << GICR_PENDBASER_SHARE_SHIFT); + + gic_r_write_8(gicv3, GICR_PENDBASER, xbaser); + + tmp = gic_r_read_8(gicv3, GICR_PENDBASER); + + if ((tmp & GICR_PENDBASER_SHARE_MASK) == + (GICR_PENDBASER_SHARE_NS << GICR_PENDBASER_SHARE_SHIFT)) { + /* Clear the cahce and shareability bits */ + xbaser &= ~(GICR_PENDBASER_CACHE_MASK | + GICR_PENDBASER_SHARE_MASK); + /* Mark as non-shareable */ + xbaser |= GICR_PENDBASER_SHARE_NS << GICR_PENDBASER_SHARE_SHIFT; + /* And non-cacheable */ + xbaser |= GICR_PENDBASER_CACHE_NIN << + GICR_PENDBASER_CACHE_SHIFT; + } - /* Enable LPIs */ - ctlr = gic_r_read_4(gicv3, GICR_CTLR); - ctlr |= GICR_CTLR_LPI_ENABLE; - gic_r_write_4(gicv3, GICR_CTLR, ctlr); + /* Enable LPIs */ + ctlr = gic_r_read_4(gicv3, GICR_CTLR); + ctlr |= GICR_CTLR_LPI_ENABLE; + gic_r_write_4(gicv3, GICR_CTLR, ctlr); - /* Make sure the GIC has seen everything */ - dsb(sy); + /* Make sure the GIC has seen everything */ + dsb(sy); + } } static int From nobody Tue Apr 16 21:42:49 2024 X-Original-To: dev-commits-src-branches@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 4VJyFP4rYCz5H8bx; Tue, 16 Apr 2024 21:42:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFP20LTz4Yr8; Tue, 16 Apr 2024 21:42:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303769; 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=tBTpKt9+R2r29K9ZUCdhs9ouY/7QAxwqCQm/9Egq/dI=; b=JGMY5IJ9H1tDUfwhfaz8pd+g1bs1d/Kx/cECckjebD5Mk7XkoAD5VLXxUft5A6Bxy5vZ3P dYnqna/fO1nBBlEqlgpYP2hMvsu3uh/+b/X3irlzRVM5+1kihBpZq8QMmse74JbLkIv0ir N2SgrspqzBwCS+NNBVONoUU/W0DQVzKsl56qMm3M2t1aNv0d1dgFDsGf6TYiny9oLG7Cbt dPb+SscPaM+fWyrrUnzgVbjQPjVmGcNABUd0oRxTAEJQBA9BgaY/N97ZXWIt2Ujpkf4auj lq4KRsEEXpFXz6zTLzVtzSeeb/LFK2ss7lxQjqKHdohYQ3F7atU5a+agQtT7jA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303769; a=rsa-sha256; cv=none; b=JQjjz3qNYVxsLsPQy7CW0MjGfaLC5lCIuF2La7AHwxjp+OPIiKnFp0h6wx4VsMg8qk9BKP kF4VE+4xqcKXG5LH1Q55g/kycb/URsSQ+I7bdcNWvZ/crGWdyBh8SPT//y9sj8cNHXdvqC tF2WaLMRUhDwoFr5fCMc7HhYorqeaLRRjnlNQMXO9RmjzcefZNoET4IvGZufrlf6Wleh7o sIh8y6ZBx21BfEV6R3IW9wv8kEocwvMspRCXpyc+v5xjMYS00PLrmGLZOVQpSpn3wnluY0 SHOZN42N9BjhG/z7WLCCe+xCLVhxKBdn7Sd3oKXtuJ8ij+2mWEN1pnR325BY2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303769; 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=tBTpKt9+R2r29K9ZUCdhs9ouY/7QAxwqCQm/9Egq/dI=; b=u7tsW0p3U+68ijh2uLWOiWoL45lXk1zzehOJkaB70X77VFNkIJxNg5dMi5RgCyMss+dRtY 8FIsxJtogedJEX7BOk3Fn2i+bpvPIOB0NCdQH8GQLYozDksOVdU9gyf6PHnHdpgGtnFG+0 zx0LjDSj9PbUPWxI0QqDT0JEoOYUDpUO1HF7vNVyMhzBIm+4+gU3o7BWqXcF5NrXi/JumM YdmHQGxvRAY3oSMmzg3ygJBM5XEwKzIX4pUVchROllCNQQZ9kxWJQ0SeEBLP7f776IqmZt HdJYRn/U1hoahd4XwevOTHD5bbrUuhVX6Hka0c2kvmrZjP8KL5Q6+7EFrjUzog== 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 4VJyFP1bpGzyvH; Tue, 16 Apr 2024 21:42:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgnCX094632; Tue, 16 Apr 2024 21:42:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgne0094629; Tue, 16 Apr 2024 21:42:49 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:49 GMT Message-Id: <202404162142.43GLgne0094629@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 6368e71a25ba - stable/14 - gicv3: Report PENDBASE when bootverbose List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6368e71a25baeb040fd59ce5204e1e949b31124b Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=6368e71a25baeb040fd59ce5204e1e949b31124b commit 6368e71a25baeb040fd59ce5204e1e949b31124b Author: Warner Losh AuthorDate: 2024-02-28 14:08:55 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:41 +0000 gicv3: Report PENDBASE when bootverbose Report some stats about PENDBASE when we're running under bootverbose. We don't do this by default because experience has been excess output in this routine hangs the system. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44036 (cherry picked from commit b4368e83891ed9eba72c0ceccf25f7642f2bad40) --- sys/arm64/arm64/gicv3_its.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 51e7251b9ffd..2ab77e1e9966 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -829,6 +829,11 @@ its_init_cpu_lpi(device_t dev, struct gicv3_its_softc *sc) /* Make sure the GIC has seen everything */ dsb(sy); } + + if (bootverbose) + device_printf(gicv3, "using %sPENDBASE of %#lx on cpu %d\n", + (sc->sc_its_flags & ITS_FLAGS_LPI_PREALLOC) ? "pre-existing " : "", + vtophys(sc->sc_pend_base[cpuid]), cpuid); } static int From nobody Tue Apr 16 21:42:50 2024 X-Original-To: dev-commits-src-branches@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 4VJyFQ64p0z5H8Qc; Tue, 16 Apr 2024 21:42:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFQ3Kmmz4Ygb; Tue, 16 Apr 2024 21:42:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303770; 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=orwHidQRcuF0vB+gL/MVrpGfS0nU5GNFX1wX+dG6Dck=; b=KFuUh6jA1czbTwI0onbJ0MPMsWkOm730xvneKGkW43Jv7j18EicLVQiibEoqjA5SaBrCkF IMw/rihfo/jI1T5b1ByQ7EuFZGokZxs/2Iahz0zPHPiy2GicCstRPRU9dfyfK6T3BOVrB5 ITJEYOjCiroMosvvgEkJj3rZhF/JtWTyILlp+i5mtF9XwMC/HwFeh4lFq8zcAkPvvOxR1J 7sjiLIXCzusJ/1A9l/h9gyJfCjRiBnhwPbwB6tp4+8DIsdin4CQOQ282H/PZ367pKmIgO+ /nhDQp1VmQuqAjGJwYDFg512KWq4KmNce5pWeoUdOAdDL6kvAOJiEuAwT80cyA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303770; a=rsa-sha256; cv=none; b=iAFQu49f4cxBciNW6xHW7PP9Ody9nJhfq3nYQ+dlg/y7QKSeTBPkAUEdDKt0Yz4ZoUFVtf TdMdAmCr2M2Irtv+1X5KZ9gs0tMHHj51zNxGcVlr4V3zP3V4zQ1Qh7YtseGn2KEcVcHi7O wDX9D/Nym/5liFVgTM0wfaq01VEjcLuLPuVB5UmRaWfgQLEUgzgIN5ue2ev0DUtkkLneVO EPszJYMNY6dmZACuywQ3Lu0zjVkkJpqmMTDyZhGYxObHUII+APDUfUqIf64ty1eQfiO1MO EDd/1gerQr/5QrB+sXMxDWwkLByeYe/4jY3eeX6P8RHoRFGGBfIdwKULnAvvZw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303770; 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=orwHidQRcuF0vB+gL/MVrpGfS0nU5GNFX1wX+dG6Dck=; b=CwRJZHjb2XRTg1UIzwvNRZMuGfAI4/3AGDHRC5Qv1tO0PmdYG8Y++JS0AmSCeCa+AsiHEH PS1HHRS8xzsw5bIAtNg/E5O3IJUiceRCMde1J7coscM7XuOnEC8XavBpeP9667OsT9ieGk xHvIlPApMgIOmUgdt6fwHW8/t9q4dC3a6Hi3Yxf/K9qTCMN4LhZXlrRvLuEKLqaNVqIFCZ xBG8+23HUO+n4A4UR9K2kxVQyZZyFvvT6xrKUDPw+cXVdhSUMNBU3F0xru8WSv/tBR+Pe3 aeyYIkYH1LhM0akGYghPC13Q/z0V3lMlpuS+wfJ1ihHB+UfTQSIE0ScaDfZsGA== 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 4VJyFQ2y53zyvJ; Tue, 16 Apr 2024 21:42:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgoHE094689; Tue, 16 Apr 2024 21:42:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgoQI094686; Tue, 16 Apr 2024 21:42:50 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:50 GMT Message-Id: <202404162142.43GLgoQI094686@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 582cece4507b - stable/14 - gicv3: Define PA masks for the PENDBASR and PROPBASER registers List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 582cece4507b15f46723d1757b9fb45c2c8a4117 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=582cece4507b15f46723d1757b9fb45c2c8a4117 commit 582cece4507b15f46723d1757b9fb45c2c8a4117 Author: Warner Losh AuthorDate: 2024-02-28 14:09:02 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:41 +0000 gicv3: Define PA masks for the PENDBASR and PROPBASER registers Define masks for these registers to find the PA of where these are pointing. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44096 (cherry picked from commit a3f164a0c7af17b6b1903e8f13d1b70072e1ccd0) --- sys/arm64/arm64/gic_v3_reg.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/sys/arm64/arm64/gic_v3_reg.h b/sys/arm64/arm64/gic_v3_reg.h index 16b1cd438350..792b532196a9 100644 --- a/sys/arm64/arm64/gic_v3_reg.h +++ b/sys/arm64/arm64/gic_v3_reg.h @@ -182,6 +182,15 @@ #define GICR_PROPBASER_OUTER_CACHE_MASK \ (0x7UL << GICR_PROPBASER_OUTER_CACHE_SHIFT) +/* + * The PROPBASER LPI Configuration Table is 4k aligned, so bits 51:12 are + * defined to be the PA, for 40 potentially significant bits. + */ +#define GICR_PROPBASER_PA_SHIFT 12 +#define GICR_PROPBASER_PA_SIZE 40 +#define GICR_PROPBASER_PA_MASK \ + (((1UL << GICR_PROPBASER_PA_SIZE) - 1) << GICR_PROPBASER_PA_SHIFT) + #define GICR_PENDBASER 0x0078 /* * Cacheability @@ -225,6 +234,15 @@ #define GICR_PENDBASER_OUTER_CACHE_MASK \ (0x7UL << GICR_PENDBASER_OUTER_CACHE_SHIFT) +/* + * The LPI Pending Table (PENDBASER) is 64k aligned. So bits 51:16 are defined to be the PA, for 36 + * potentially significant bits. + */ +#define GICR_PENDBASER_PA_SHIFT 16 +#define GICR_PENDBASER_PA_SIZE 36 +#define GICR_PENDBASER_PA_MASK \ + (((1UL << GICR_PENDBASER_PA_SIZE) - 1) << GICR_PENDBASER_PA_SHIFT) + #define GICR_INVLPIR 0x00a0 #define GICR_INVALLR 0x00b0 #define GICR_SYNCR 0x00c0 From nobody Tue Apr 16 21:42:51 2024 X-Original-To: dev-commits-src-branches@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 4VJyFS00c2z5H8Yf; Tue, 16 Apr 2024 21:42:52 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFR4L4Rz4YtX; Tue, 16 Apr 2024 21:42:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303771; 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=x41KSQvpu+gf7nbJdOxMLjL1CNLRRFroyWC4H6bQNjE=; b=uTH7kJ/FkFxdxcqgEhasm8mgPXbtoxRAE03BCMVEH6KA1oB9woqhY19l1ii6V7yRYOXSg5 HVCcR3fELz0tku6gz4MR7ZC+QGAYnc1GGU+OkDLH96RFGIMTJmtUxCQ8E8/UA8S5rVLDcv u+1eqnjEABHQufi/15T792WPo8CU5S/k7dg/8luYjTMwW5aixgF+F8HIjQnpNZenyAdyKm AnTCL7hqvQ3Muyb/v/0ipdVdZ+b3Gi1zsf5brNtVG3+89pn8pLt9TJK+z3udBEhbH5U+bG /VY6D9j6IQDwbHUq0+Y6Lb+4su4u0W0nrModJJ+4dZh+8hJDiYnkJg7eLwdL8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303771; a=rsa-sha256; cv=none; b=eLUYXvhR5NtOE9azwBr4KhR99xbAgAvJ+X1/Oc4PzCA0f6qfF4KWMnuROVTVBsXh3bNg7g 3/P3uAXdZW9QT9vvgq305QJzvpxMVinXVpj9+P8Xt/65k7h46yHLmDNwSvbscDdjXD6edV QODFXIhcejZdehKfRtFGvYcmHuhkkUJb888VHM8KE9QQbArnRguKYyH0AzHvUtTnrblntP LI/WUIKYYHOgU9bOdXYmuRNC5UQ2unpyQ5QbAudlrKPmtefNeY1Gp/jG3X7yqBKPO0iYUW qRGyF0dvav4zt6yzrwmzPPKBduteFjoEkepQXsuXEcNPT+WhfM4IicmpYhpEFg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303771; 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=x41KSQvpu+gf7nbJdOxMLjL1CNLRRFroyWC4H6bQNjE=; b=Np5Q8eYcxSuILXHDK/fNMdid2LWu/mcTfBWIb6/Xb0hUk0vfOkqxsXUbFWdmdfTOdIkWwm pCPnpMGSet44ngoiypWK1WJOz6eWydB92DpxUoBDKTpSglcjvb0f3FFdm6qPbFWHhZRQex nmEhVRIgDrqwkaO0OfFJA6reY+Ut8C+2EHnk69rLs2G9LMnekmnzdLOrD3VKpb91zRluFs mL2YLFaNP4Snm4UAaDi98RUO8YPfFb0nXF4FNf6ZJEvf8Ob62o/a0mwci0IzaEPyv3RHCq f01GIQS3VzkA1eMcI5BvF8LXEFRySwVDoYsLA++iJCwGrQ6sr9ojJj1EnfXSOA== 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 4VJyFR3xl3z10ZD; Tue, 16 Apr 2024 21:42:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgp8s094742; Tue, 16 Apr 2024 21:42:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgpvk094739; Tue, 16 Apr 2024 21:42:51 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:51 GMT Message-Id: <202404162142.43GLgpvk094739@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: b53202779c2e - stable/14 - gicv3: In its_init_cpu_lpi record each cpu's PENDBASER List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b53202779c2e39c3ecdcd6bbc86a23f0bdc485aa Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=b53202779c2e39c3ecdcd6bbc86a23f0bdc485aa commit b53202779c2e39c3ecdcd6bbc86a23f0bdc485aa Author: Warner Losh AuthorDate: 2024-02-28 14:09:10 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:41 +0000 gicv3: In its_init_cpu_lpi record each cpu's PENDBASER When we're using the preallocated memory for gicv3, record each cpu's PENDBASER where we'd normally allocate memory for it. Make sure that memory is in the excluded list and map the PA to VA and store that, to mimic what we do with the allocation case. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44037 (cherry picked from commit 1d13cc200820a020d7875563b036b5f43800ef38) --- sys/arm64/arm64/gicv3_its.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 2ab77e1e9966..49d9c08a4ffd 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -46,6 +46,7 @@ #include #include #include +#include #include #include #include @@ -828,8 +829,18 @@ its_init_cpu_lpi(device_t dev, struct gicv3_its_softc *sc) /* Make sure the GIC has seen everything */ dsb(sy); + } else { + KASSERT(sc->sc_pend_base[cpuid] == 0, + ("PREALLOC too soon cpuid %d", cpuid)); + tmp = gic_r_read_8(gicv3, GICR_PENDBASER); + tmp &= GICR_PENDBASER_PA_MASK; + if (!physmem_excluded(tmp, LPI_PENDTAB_SIZE)) + panic("gicv3 PENDBASER on cpu %d needs to reuse 0x%#lx, but not reserved\n", + cpuid, tmp); + sc->sc_pend_base[cpuid] = PHYS_TO_DMAP(tmp); } + if (bootverbose) device_printf(gicv3, "using %sPENDBASE of %#lx on cpu %d\n", (sc->sc_its_flags & ITS_FLAGS_LPI_PREALLOC) ? "pre-existing " : "", From nobody Tue Apr 16 21:42:52 2024 X-Original-To: dev-commits-src-branches@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 4VJyFT2NNwz5H7rk; Tue, 16 Apr 2024 21:42:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJyFS5cnmz4Ylx; Tue, 16 Apr 2024 21:42:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303772; 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=uAhLnvyB7S1X6zWYjNTMM6TKlmQZnVg5ATmXEDrP2CE=; b=GOxw+4JuxqAius9tf+Mw4zK/QE4JHq4w+HnmyaMLGnE/LezDTbS8hDUoVjY1CgYZnoOs3e wYNG4eocs5V6dmpzGkhqJD4nIc0zWoklaJ9y1oBqKQ7590opAH6AMP6whg4AzHSSrvSN1q W2Z6k6oGZsVg3ZoJZ2+J2PKBUFn6NC7d8gCMKbbG5XMwxX11tntdcJRQqS1m3SGFxFZAVg wjKrnpGTYXeaKrI2jB+Qxv5fFMNj9KEu+hLoi8va3Jh7k1jJcOkbJNzl3yk+PcyOSWeAON i0TLM/cPib8085aKRNWIkGnhSlG5ifA8sxtQBoCRzZAZvzX3tFOnyGmShAzbQg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713303772; a=rsa-sha256; cv=none; b=l1ybpAn72C2wG7WVmGlAAz6atpe0puSGbJAG3OxNaXDx0dZB6IFznAHAzaCXgekokIkDUs f5Ed7LKghIyZDBhxGNg0MvLo89h8netRkp0uUerWQ+wV6O/kbQj3XNYVQS7TWWjosYC/oN 6KMsknBg1tyLaiDE3r+gfuKYSX9psPiiXpRXYCPNqhy45wk6Zx3BT2VVLiBksHBbHhO7Ej l5g6uVUmwik0TaC72JcJYfo3TpfTrfKX85qzNMzmDlvIcT34UX8CsXX1a8PAWF/vwgTJhS 0FA8PX/gyVDvlr6N+T0UBGXwbcjaxLEOPUQzsQXQgjxZvt3rH+6RXu+4UGFbdg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713303772; 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=uAhLnvyB7S1X6zWYjNTMM6TKlmQZnVg5ATmXEDrP2CE=; b=ru5FBMuXfeumixYG6AOudrUuL52VuJ8blrVRZLfKWZ3pHTP+D+vWqv2jOxYqyvVnE7g+1h NfYzTAGKe+mi6EvjGZQF9Ef/rBk5kyLDvXPiorbKuNHwl2HwWH3fn9fwvW3mhHeICRzCrw Jf+mjUjd1/TVyUSa90f9R51bskuNgMRJFbzp8IdNK4UheDRWRTAbxarMqV6q02aLGrCYd7 1DReN9xt/+WzPROjzMFcXZiOsDdaRWAzGTf7A4Uj6SHpqmxvuoapAMUQ8zQlnVC3WsKrt6 Z0CNVlKnm+Yh03SIqJQDo+QDNdEp0LK40aoxRPysBVYwi11bWPFIRoz8BuALCA== 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 4VJyFS51Ptz10Lq; Tue, 16 Apr 2024 21:42:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43GLgqSX094798; Tue, 16 Apr 2024 21:42:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43GLgqki094795; Tue, 16 Apr 2024 21:42:52 GMT (envelope-from git) Date: Tue, 16 Apr 2024 21:42:52 GMT Message-Id: <202404162142.43GLgqki094795@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: d476e51525ff - stable/14 - gicv3: If the LPI is already allocated, remember it List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d476e51525ff9e5c489feec14f64aa8c1d38c5b5 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d476e51525ff9e5c489feec14f64aa8c1d38c5b5 commit d476e51525ff9e5c489feec14f64aa8c1d38c5b5 Author: Warner Losh AuthorDate: 2024-02-28 14:09:17 +0000 Commit: Warner Losh CommitDate: 2024-04-16 21:28:41 +0000 gicv3: If the LPI is already allocated, remember it If the LPI Configuration Tabel has been pre-allocated by the boot loader, then we have to remember PROPBASER and use it rather than allocating memory for it ourselves. Linux provides us with a reserved table that contains all the gicv3 allocations, so make sure what we read from PROPBASER matches something in that table. Normally, bare metal boot loaders leave the gic in a reset state. However, Linux brings it up fully so it can do I/O to boot the next kernel via kexec. Since the gicv3 PENDBASER can't be reset while running due to undefined behavior, we must reuse what's there for both PENDBASER and PROPBASER. With this commit, the workaround is complete. Details are at https://lkml.iu.edu/hypermail/linux/kernel/1809.2/06246.html and pointers in the thread. Sponsored by: Netflix Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D44038 (cherry picked from commit cb4a83cff01cdf871c78115c942c5b34412914d2) --- sys/arm64/arm64/gicv3_its.c | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 49d9c08a4ffd..02c063fe57b5 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -686,6 +686,8 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) int extra_flags = 0; device_t gicv3; uint32_t ctlr; + vm_paddr_t conf_pa; + vm_offset_t conf_va; /* * The PROPBASER is a singleton in our parent. We only set it up the @@ -700,8 +702,32 @@ gicv3_its_conftable_init(struct gicv3_its_softc *sc) gicv3 = device_get_parent(sc->dev); ctlr = gic_r_read_4(gicv3, GICR_CTLR); if ((ctlr & GICR_CTLR_LPI_ENABLE) != 0) { - extra_flags = ITS_FLAGS_LPI_PREALLOC; - panic("gicv3 already enabled, can't reprogram."); + conf_pa = gic_r_read_8(gicv3, GICR_PROPBASER); + conf_pa &= GICR_PROPBASER_PA_MASK; + /* + * If there was a pre-existing PROPBASER, then we need to honor + * it because implemenetation defined behavior in gicv3 makes it + * impossible to quiesce to change it out. We will only see a + * pre-existing one when we've been kexec'd from a Linux kernel, + * or from a LinuxBoot environment. + * + * Linux provides us with a MEMRESERVE table that we put into + * the excluded physmem area. If PROPBASER isn't in this tabke, + * the system cannot run due to random memory corruption, + * so we panic for this case. + */ + if (!physmem_excluded(conf_pa, LPI_CONFTAB_SIZE)) + panic("gicv3 PROPBASER needs to reuse %#lx, but not reserved\n", + conf_pa); + conf_va = PHYS_TO_DMAP(conf_pa); + if (!pmap_klookup(conf_va, NULL)) + panic("Can't mapped prior LPI mapping into VA\n"); + conf_table = (void *)conf_va; + extra_flags = ITS_FLAGS_LPI_PREALLOC | ITS_FLAGS_LPI_CONF_FLUSH; + if (bootverbose) + device_printf(sc->dev, + "LPI enabled, conf table using pa %#lx va %lx\n", + conf_pa, conf_va); } else { /* From nobody Wed Apr 17 05:43:51 2024 X-Original-To: dev-commits-src-branches@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 4VK8wR6rfcz5Htss; Wed, 17 Apr 2024 05:43:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wR4QqBz4l1x; Wed, 17 Apr 2024 05:43:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332631; 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=9+t7ThnjCL3sBBdloGy27WF2zthf97s8V6r1XSAr9Lc=; b=d3LPZ4wb9n3a++zd15cKlyDkV63bEMmDPFA9Y8oGtPNEyFQC119hM2EjgdW/ovz+tKsMeX YOSi9B8d9Q+3PZ+BiU9+eUUjJCqGxkHH/K4mhiJey3gwee9hCDTyP5qv/8aTh96g0YD6xj O6s431PCcNskieQrdARYwWXXAhehjeV2PmtWqbeq81PsDrwGYjvFls1+TUjM9IOUL+ItnL 6c3HIbAhD+QDLwKYmarGlUDymP4pUfWY47UF/aZkBm25rDxYbj/xp22gtgpAzjVC8/4qRj rNPypmg3+V3EdroQqkCF5TdLgf/dWiMU1AmUY8eVCcANfAPFh1ot8IRLnHEaIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332631; a=rsa-sha256; cv=none; b=gMblIsPj1gLiFeoeHvVEEk8RaVTOJhRgJbN4yl+zjZvbe+i4msea3HygaUfU6AL8CI1lTW 0eCCPbcpYcXG+jN//toN482fhc2FcqHRfclB1Hj9gvWzWfdCyveJAZJJuxVLvtZSOuPqsA t0+eM5zHfGV8LPpCV0H8JkT5WA8iKOQN+7iKnsn7e8EcCoYa0+p0pvQQVyR2LHyqI50Dwh YX6GJ+4Wmoj5IvUr8cgvcbshXNUh4JyAMBXPjML+NkIjYAE55feXL+zZxOULsqaR5d51T3 xcdO5KMVCv/HtWR6BBuagatDK//oTLP9uwt4HqoHltrUfzk43nfJ5i6qpcQmSA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332631; 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=9+t7ThnjCL3sBBdloGy27WF2zthf97s8V6r1XSAr9Lc=; b=pDkZ5aQ1fPR6DJJ5VD8MUoe8Z02CRjnMWj0zuyPUQFmgeqJpUx14nX6PqmOkvgaOg0tyxt 9wMqbx5+We2BwIuFioP6iJiJ0ZUNGV1cBMoyP0H1p7ockIPwJt/zsXtbMzmdlDn0iN21BO U5f0b6BsMtIVNb66OafsWiKqOZq/ArAOIKL8+czozyo/vcsBKeEnJ0SthnygX2tZwBkvq8 8NAQzuloF6svBbZmsRZvkM26tPlaQQVtEkE9bcSw7FU979V9iylLGSm+4V8Fk5r7emEbki mHAeus+dlxr9vWP2rw46jUT2+M5/A5JZLgEw8+2H+5Vg9ROBjE9CZgX/f7l3FQ== 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 4VK8wR42hdzFPk; Wed, 17 Apr 2024 05:43:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hpus006578; Wed, 17 Apr 2024 05:43:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hpvo006576; Wed, 17 Apr 2024 05:43:51 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:51 GMT Message-Id: <202404170543.43H5hpvo006576@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: a8659d8785c0 - stable/14 - release: make -j compat: cd inside subshell List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a8659d8785c068bcc6138708db1db1e24e7327a5 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=a8659d8785c068bcc6138708db1db1e24e7327a5 commit a8659d8785c068bcc6138708db1db1e24e7327a5 Author: Colin Percival AuthorDate: 2024-04-10 03:25:34 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:26 +0000 release: make -j compat: cd inside subshell Place instances of "cd foo && bar" inside subshells for compatibility with modern make(8) which uses a single shell for the duration of a makefile target. MFC after: 1 week (cherry picked from commit 93e4813b9a157396ffbcf8456ca4f5c25599807d) --- release/Makefile | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/release/Makefile b/release/Makefile index 2cf6efe2e231..90937c53cabf 100644 --- a/release/Makefile +++ b/release/Makefile @@ -117,7 +117,7 @@ clean: beforeclean base.txz: mkdir -p ${DISTDIR} - cd ${WORLDDIR} && ${IMAKE} distributeworld DISTDIR=${.OBJDIR}/${DISTDIR} + ( cd ${WORLDDIR} && ${IMAKE} distributeworld DISTDIR=${.OBJDIR}/${DISTDIR} ) # TODO: Add NO_ROOT mode to mm-tree.sh .if !defined(NO_ROOT) # Set up mergemaster root database @@ -136,41 +136,41 @@ base.txz: rm ${.OBJDIR}/${DISTDIR}/base/var/db/etcupdate/current/METALOG .endif # Package all components - cd ${WORLDDIR} && ${IMAKE} packageworld DISTDIR=${.OBJDIR}/${DISTDIR} + ( cd ${WORLDDIR} && ${IMAKE} packageworld DISTDIR=${.OBJDIR}/${DISTDIR} ) mv ${DISTDIR}/*.txz . kernel.txz: mkdir -p ${DISTDIR} - cd ${WORLDDIR} && ${IMAKE} distributekernel packagekernel DISTDIR=${.OBJDIR}/${DISTDIR} + ( cd ${WORLDDIR} && ${IMAKE} distributekernel packagekernel DISTDIR=${.OBJDIR}/${DISTDIR} ) mv ${DISTDIR}/kernel*.txz . src.txz: mkdir -p ${DISTDIR}/usr ln -fs ${WORLDDIR} ${DISTDIR}/usr/src - cd ${DISTDIR} && ${TAR_CMD} cLvf - --exclude .svn --exclude .zfs \ + ( cd ${DISTDIR} && ${TAR_CMD} cLvf - --exclude .svn --exclude .zfs \ --exclude .git --exclude @ --exclude usr/src/release/dist usr/src | \ - ${XZ_CMD} > ${.OBJDIR}/src.txz + ${XZ_CMD} > ${.OBJDIR}/src.txz ) ports.txz: mkdir -p ${DISTDIR}/usr ln -fs ${PORTSDIR} ${DISTDIR}/usr/ports - cd ${DISTDIR} && ${TAR_CMD} cLvf - \ + ( cd ${DISTDIR} && ${TAR_CMD} cLvf - \ --exclude .git --exclude .svn \ --exclude usr/ports/distfiles --exclude usr/ports/packages \ --exclude 'usr/ports/INDEX*' --exclude work usr/ports | \ - ${XZ_CMD} > ${.OBJDIR}/ports.txz + ${XZ_CMD} > ${.OBJDIR}/ports.txz ) disc1: packagesystem # Install system mkdir -p ${.TARGET} - cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ + ( cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ DESTDIR=${.OBJDIR}/${.TARGET} MK_AT=no \ MK_INSTALLLIB=no MK_MAIL=no \ ${_ALL_LIBCOMPATS:@v@MK_LIB$v=no@} \ MK_TOOLCHAIN=no MK_PROFILE=no \ MK_RESCUE=no MK_DICT=no \ MK_KERNEL_SYMBOLS=no MK_TESTS=no MK_DEBUG_FILES=no \ - -DDB_FROM_SRC + -DDB_FROM_SRC ) # Copy distfiles mkdir -p ${.TARGET}/usr/freebsd-dist for dist in MANIFEST $$(ls *.txz | grep -vE -- '(${base ${_ALL_libcompats}:L:ts|})-dbg'); \ @@ -202,7 +202,7 @@ disc1: packagesystem bootonly: packagesystem # Install system mkdir -p ${.TARGET} - cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ + ( cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ DESTDIR=${.OBJDIR}/${.TARGET} MK_AT=no \ MK_GAMES=no \ MK_INSTALLLIB=no MK_MAIL=no \ @@ -210,7 +210,7 @@ bootonly: packagesystem MK_TOOLCHAIN=no MK_PROFILE=no \ MK_RESCUE=no MK_DICT=no \ MK_KERNEL_SYMBOLS=no MK_TESTS=no MK_DEBUG_FILES=no \ - -DDB_FROM_SRC + -DDB_FROM_SRC ) # Copy manifest only (no distfiles) to get checksums mkdir -p ${.TARGET}/usr/freebsd-dist cp MANIFEST ${.TARGET}/usr/freebsd-dist @@ -237,10 +237,10 @@ bootonly: packagesystem dvd: packagesystem # Install system mkdir -p ${.TARGET} - cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ + ( cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ DESTDIR=${.OBJDIR}/${.TARGET} MK_RESCUE=no MK_KERNEL_SYMBOLS=no \ MK_TESTS=no MK_DEBUG_FILES=no \ - -DDB_FROM_SRC + -DDB_FROM_SRC ) # Copy distfiles mkdir -p ${.TARGET}/usr/freebsd-dist for dist in MANIFEST $$(ls *.txz | grep -v -- '(${base ${_ALL_libcompats}:L:ts|})-dbg'); \ @@ -334,8 +334,8 @@ release-install: ${XZ_CMD} -k ${DESTDIR}/${OSRELEASE}-${I} . endif .endfor - cd ${DESTDIR} && sha512 ${OSRELEASE}* > ${DESTDIR}/CHECKSUM.SHA512 - cd ${DESTDIR} && sha256 ${OSRELEASE}* > ${DESTDIR}/CHECKSUM.SHA256 + ( cd ${DESTDIR} && sha512 ${OSRELEASE}* > ${DESTDIR}/CHECKSUM.SHA512 ) + ( cd ${DESTDIR} && sha256 ${OSRELEASE}* > ${DESTDIR}/CHECKSUM.SHA256 ) .endif .include "${.CURDIR}/Makefile.inc1" From nobody Wed Apr 17 05:43:52 2024 X-Original-To: dev-commits-src-branches@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 4VK8wT029Wz5HvJ1; Wed, 17 Apr 2024 05:43:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wS5L00z4lR2; Wed, 17 Apr 2024 05:43:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332632; 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=n+XYhSo5Rid3GsXdTTnlt54nT5e+5bwnrR0hs8XAWHE=; b=yNElMWRf0RLhMH7RJ2d4Wl0Qsv6IjXgDXht/sjwcwzHnN5ARoYTCIiDI+4Jn+897F997km Fl9BBcEbWM3PpAZTQyGJWjjTJm8ioBBrEOMI42HAQ94/HjHbbM0xlqXuFjF++y4rv21+du M4N80hz0UGcCrSBHwtJk21gx1oJD1dET0ueLxGe9+UkeMwWtJc1ezvuy0LimSuLZifott4 q/C35rmNWs7HKorsLKj/0xmdmDsda9iKk4OloSIsA3Qc3vePRnWELSX3GBOubgQqhgtfTl lZWTH3xf4Ngm8Q6h0T/EBOjFJBP6yJcfC4UT7ae65LrkVHAe2wsgMccA2Cy5jw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332632; a=rsa-sha256; cv=none; b=mMUbQahrnvObS3t2kmLMQsr1xjfZAHd+EcjpbkQ6Wus3idQQ/SGPKlgROCyVLIrv2s9QT+ Scq7irxORtVENv6TI7+eZpHt6G1HsbDBnKcWIR0ZAg5HE+VzsrjVAeRz17Pi3zu/QHSjkO 8lZUZIPyFKpZoPVC6xiUaDGgPmUV2YD6JeJKLnN0buQgsIkUdr/dDCkNHiyJqJqyUw6bdt 63cVS/Xk2nLrxd4RMv80bNfpUhyROZLXJ9bxmFQZfCWFDSz6JJetbdz/lLfvAhEig/NpYA Y4SOc+E9jQm15aUdZTTk18Dsm+S7qzOIcHMgH14RJyz7wemn+uOM34cYNxExFQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332632; 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=n+XYhSo5Rid3GsXdTTnlt54nT5e+5bwnrR0hs8XAWHE=; b=K2axu8FHlVImbgPiV13Wlucv6Iw4QH4jzf0IE8ZzWiSOsqcy1Q2Fl0e/RX5IwKDlmzQlAX ALJt9+WWFRgQZcele1TY9G2xhuFXp/GRZKQYkYXWp+r6KL9aCc33ff/UlcCM1mQUG1L0Ov 0Yr3Jki9wx9TJxP7tczi4ISs9Rsb1qh4QIcxYm6oMtVvl10Uynwe8iKuKr9+XHeVIu25mM 9NVNlCTHjUZmn2/0zMSyrwjVvx947opPC2/JkrgbbInD0Ww/D5uSXBruk3QlzdaGSzgKXb OmJRyGbDY4na3MMtpwdgZ5d12zDeVbRCYFELdw9B+pvJmHy8h/waNdBHEe3ThQ== 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 4VK8wS4ykgzDx0; Wed, 17 Apr 2024 05:43:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hqOi006623; Wed, 17 Apr 2024 05:43:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hqvF006620; Wed, 17 Apr 2024 05:43:52 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:52 GMT Message-Id: <202404170543.43H5hqvF006620@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: b4435119eca4 - stable/14 - release: distributekernel before packagekernel List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b4435119eca4e8e5f3d6e3114d62b3469cc544e7 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=b4435119eca4e8e5f3d6e3114d62b3469cc544e7 commit b4435119eca4e8e5f3d6e3114d62b3469cc544e7 Author: Colin Percival AuthorDate: 2024-04-10 03:26:51 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:26 +0000 release: distributekernel before packagekernel With these as a single make command, `make -j` breaks when it tries to package up a kernel which hasn't been distributed yet. MFC after: 1 week (cherry picked from commit 65c603ed65c700d6eacdf9e1e94dc42fd70fb0b7) --- release/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/release/Makefile b/release/Makefile index 90937c53cabf..6c391c9c661d 100644 --- a/release/Makefile +++ b/release/Makefile @@ -141,7 +141,8 @@ base.txz: kernel.txz: mkdir -p ${DISTDIR} - ( cd ${WORLDDIR} && ${IMAKE} distributekernel packagekernel DISTDIR=${.OBJDIR}/${DISTDIR} ) + ( cd ${WORLDDIR} && ${IMAKE} distributekernel DISTDIR=${.OBJDIR}/${DISTDIR} ) + ( cd ${WORLDDIR} && ${IMAKE} packagekernel DISTDIR=${.OBJDIR}/${DISTDIR} ) mv ${DISTDIR}/kernel*.txz . src.txz: From nobody Wed Apr 17 05:43:53 2024 X-Original-To: dev-commits-src-branches@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 4VK8wV0VxXz5Hv5C; Wed, 17 Apr 2024 05:43:54 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wT6KXqz4lNb; Wed, 17 Apr 2024 05:43:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332633; 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=v3uM518LQle/1xjDpyGDVR+gLwS+K+rTkJ2BqR62HDw=; b=MMX1hlXfxtk7LXMF0jQ/tJdEAfS+/iIhVYu8aCk8r+yMZ3WWc8IkFVD43QZUScKSi6KSS6 g6wkBH89gG17ZEixk5rfWhiU1c1MFmD8HJAfD0h+0mWnd32DYLuW1bpCtY+YVlYyDQrSvu eZahyeyeqT//bOL06l94N+0WSckd6agt7RLC/kyoNfm4sv/AwiQrCjY0+EHkT/AmgwXhPD C94eWWTspn85RG9DouUND0Vtoj5BrWCiFSuZ2YhUB3IJi5vIqteJqQUJXg2Vp4MAO6bVda 3ualsW7ptGMHVYhA5Owj6WWVahnpUVYRyWSbezsPPQmYwXGdAvNu12IYn0xumQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332633; a=rsa-sha256; cv=none; b=ssgzWEwdzTAf+S7UaCCXUlWgoE0OXHhmFDMuBP7bNLakei+DQK6nUVwT0ZZy5DBcxl9+fV py2PsAg4/NrycrZcWnbGHIy1Ow0uq2qxp4HpeBGaK+aCllObQ4eHiEZKXhLnm4oOmd3/i0 OGYaoJDQs+ZK0S3U8E+kR3ejkOGMziq5/5n1cpf/Ign2Ib1tmgyvabGZelPBTpmj1GtxgY 7oG4exSjSO7otU4Nm5CcNIHqFLvrEBaA1WVA+iBp4fDpQoiU4Su+PRt+OhprN1Fbw7RzU9 sAsp0RXiLoluH42k5boqwK4x6F7iKtTc+BjWcrx0bnbVrg+u2HV42M32r/nxSw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332633; 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=v3uM518LQle/1xjDpyGDVR+gLwS+K+rTkJ2BqR62HDw=; b=ubyd1d9/riAjq9kHf1z4n8bcfI/4puXzLcoTt+DE+RQwmEwFnLYjXgjDw1UOzLvDao5iLi wBr1WTbJqWJeazHrYbApIWEUOIEIts4a99/bvBSyTjCzXrFIjuu4Mc5SCQFiOVrIRWZldA 4lZQ8Or0ysvab+FOdxdCr0YXMF2sfl0frAXYtwFPvzob6Ex64Uaj1Vrtorou/cyL3MaMJh XclKq0Uyh1beKE+TqjuouEg5MG/3JZ8n8eBmiiYobxI5bz8Uwc7QtmB9U/j3tWQr0BNmxE VeQYd5wEpZ+Dx6Ua0A8SeVHhesMhV1YHYsCZjrFV9bbjPdQH+ytWKNZL70fXEg== 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 4VK8wT5xctzDs1; Wed, 17 Apr 2024 05:43:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hr8P006666; Wed, 17 Apr 2024 05:43:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hrN1006663; Wed, 17 Apr 2024 05:43:53 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:53 GMT Message-Id: <202404170543.43H5hrN1006663@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 2c774c1bb4ee - stable/14 - release: Don't reuse disc1/bootonly directories List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2c774c1bb4eeb50285bcbb874d0a139acec98476 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=2c774c1bb4eeb50285bcbb874d0a139acec98476 commit 2c774c1bb4eeb50285bcbb874d0a139acec98476 Author: Colin Percival AuthorDate: 2024-04-10 03:27:19 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:26 +0000 release: Don't reuse disc1/bootonly directories The disc1 and bootonly directories have files distributed into them for use in "full" and "mini" images; the former are disc1.iso and memstick.img, and the latter is bootonly.iso and mini-memstick.img. Unfortunately the scripts which package a directory tree into an ISO or memory stick image also modify the directory, for example to create an appropriate /etc/fstab file; so creating two images at the same time breaks. Resolve this by copying disc1 to disc1-disc1 and disc1-memstick, and copying bootonly to bootonly-bootonly and bootonly-memstick, before using those directories for constructing the ISO+memstick images. MFC after: 1 week (cherry picked from commit a1bff97300abe4b46528357e39c83da764df1fd8) --- release/Makefile | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/release/Makefile b/release/Makefile index 6c391c9c661d..7b658bb90b29 100644 --- a/release/Makefile +++ b/release/Makefile @@ -109,7 +109,7 @@ CLEANFILES+= ${I}.xz .if defined(WITH_DVD) && !empty(WITH_DVD) CLEANFILES+= pkg-stage .endif -CLEANDIRS= dist ftp disc1 bootonly dvd +CLEANDIRS= dist ftp disc1 disc1-disc1 disc1-memstick bootonly bootonly-bootonly bootonly-memstick dvd beforeclean: chflags -R noschg . .include @@ -270,23 +270,31 @@ dvd: packagesystem .endif touch ${.TARGET} +disc1-disc1 disc1-memstick: disc1 + mkdir ${.TARGET} + tar -cf- -C disc1 . | tar -xf- -C ${.TARGET} + +bootonly-bootonly bootonly-memstick: bootonly + mkdir ${.TARGET} + tar -cf- -C bootonly . | tar -xf- -C ${.TARGET} + release.iso: disc1.iso -disc1.iso: disc1 - cd disc1 && sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b ${VOLUME_LABEL}_CD ../${.TARGET} .${NO_ROOT:D/METALOG} ${XTRADIR} +disc1.iso: disc1-disc1 + cd disc1-disc1 && sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b ${VOLUME_LABEL}_CD ../${.TARGET} .${NO_ROOT:D/METALOG} ${XTRADIR} dvd1.iso: dvd pkg-stage cd dvd && sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b ${VOLUME_LABEL}_DVD ../${.TARGET} .${NO_ROOT:D/METALOG} ${XTRADIR} -bootonly.iso: bootonly - cd bootonly && sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b ${VOLUME_LABEL}_BO ../${.TARGET} .${NO_ROOT:D/METALOG} ${XTRADIR} +bootonly.iso: bootonly-bootonly + cd bootonly-bootonly && sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b ${VOLUME_LABEL}_BO ../${.TARGET} .${NO_ROOT:D/METALOG} ${XTRADIR} memstick: memstick.img -memstick.img: disc1 - cd disc1 && sh ${.CURDIR}/${TARGET}/make-memstick.sh .${NO_ROOT:D/METALOG} ../${.TARGET} +memstick.img: disc1-memstick + cd disc1-memstick && sh ${.CURDIR}/${TARGET}/make-memstick.sh .${NO_ROOT:D/METALOG} ../${.TARGET} mini-memstick: mini-memstick.img -mini-memstick.img: bootonly - cd bootonly && sh ${.CURDIR}/${TARGET}/make-memstick.sh .${NO_ROOT:D/METALOG} ../${.TARGET} +mini-memstick.img: bootonly-memstick + cd bootonly-memstick && sh ${.CURDIR}/${TARGET}/make-memstick.sh .${NO_ROOT:D/METALOG} ../${.TARGET} packagesystem: ${DISTRIBUTIONS} sh ${.CURDIR}/scripts/make-manifest.sh *.txz > MANIFEST From nobody Wed Apr 17 05:43:54 2024 X-Original-To: dev-commits-src-branches@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 4VK8wW33jbz5Hv78; Wed, 17 Apr 2024 05:43:55 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wW0J9nz4l4h; Wed, 17 Apr 2024 05:43:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332635; 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=HdDGOmOs/GWryLtQ0OK4vEEfZTOORCkRebA0kyIEVEI=; b=mtG07zMA5R93rSrURfFDL+enad1a3WJTWpXrz8ASLZ/5ogD1tqs3qhq7EcyUngPdH7UORt wlYMSukezOgP0pmQHLmrS+TiaMI3nLWW77cvh9MJlZwcNtN8DbmvEnLugf/XJUwqDz4Q9X 28+A6QWJSMSDrPW6U9AysZzY3BVGbInylxcYGdB1Izkn3A/d0IdPcoR1q7c0Kzzt44ErPW 1kpy69Q/3R3gO2GZ5kImxdAfXgkGda1MW2ArlvjSVcDwlJEt+XzNnW3gE4PhF2G1UXd0Lv a1OoEnMofXh5wX6WrS9yr6hlEtV/1Iif4cCht9qGt2lc0tp0xn26LMAh1dXxTw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332635; a=rsa-sha256; cv=none; b=VXc6kClIiT114ynLhGr2mXJFxEpcuLrExZdgQ/aU/3v5mpEUCwaz2AdICy6RrlNvq+0cos LKd99sRdmLt7p5g9AgZ5++JXkOFKt8pZpYovhi5W1VpSim0HX87kDRJ8MzfzWYoTi+69xx 15W16Q3CbJSGqLzWd2VGBWk7p6y0KXQT5Wr9Cz467FbAU5OeRxphzvDsMQp1pzO0S8MCE7 0LKta40BYqXQgH407AhS68e2LYwbACXo9ef2sw+jBUEnQPOU5kqU4u8RsKUfDAMxy7Tkla raj8QrZuXC+NeT6mSx0qgkK5VHanZNgYkwFClmLmPmdLpaRywq2BeArQn10NjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332635; 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=HdDGOmOs/GWryLtQ0OK4vEEfZTOORCkRebA0kyIEVEI=; b=nnRAZtT2zBjRVGx/wHzrRqwiHfW0LjwwFy3+uojP2GUWMcgQhiBiDxULQY17tB7ZeoUPiS eoQ/gy95b1Vw+QhIY3rFAfVqeJ2ipy4v4VDNySoly/xZB6CmjsECGlRH+35OxsLPxnkF7N QkoaJ01uWxINYeAcghaPkKmjBqVwPw+6Cs5GtJS1YjzQpvjeyRHIzDn9s3fxFvKRuxlZRz cwVqX/G+jZxaEsoyezlqdZEBpQlIWcTsRAVy5tzn0FMsNGTOVxJJuAMjMxru/I0lAf05LP G+IMlnM1NXuwzhKxEcLt6b1nix7c1lxQIW2BYNUWgltc/mfjbUOZaQ3SedOQjQ== 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 4VK8wV6yRzzFBs; Wed, 17 Apr 2024 05:43:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hs80006714; Wed, 17 Apr 2024 05:43:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hsJ3006711; Wed, 17 Apr 2024 05:43:54 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:54 GMT Message-Id: <202404170543.43H5hsJ3006711@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: db34bbcedbf5 - stable/14 - Reapply "release.sh: Add -jN to `make release`" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: db34bbcedbf5b9fe7c015856cd04136923e1ce06 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=db34bbcedbf5b9fe7c015856cd04136923e1ce06 commit db34bbcedbf5b9fe7c015856cd04136923e1ce06 Author: Colin Percival AuthorDate: 2024-04-10 03:27:44 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:26 +0000 Reapply "release.sh: Add -jN to `make release`" With the latest changes to release/Makefile, it is now possible to run `make release -jN` without the build failing (at least in my latest tests). This reverts commit 7b707e797b2cd6265ba8f6215e59445e9efb9e97. MFC after: 1 week (cherry picked from commit 2c01e189ff190cf1618dedd01f196bca68298c44) --- release/release.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/release/release.sh b/release/release.sh index c9d0203debd4..3c68f89c2cc3 100755 --- a/release/release.sh +++ b/release/release.sh @@ -89,9 +89,11 @@ env_setup() { SRC_CONF="/dev/null" # The number of make(1) jobs, defaults to the number of CPUs available - # for buildworld, and half of number of CPUs available for buildkernel. + # for buildworld, and half of number of CPUs available for buildkernel + # and 'make release'. WORLD_FLAGS="-j$(sysctl -n hw.ncpu)" KERNEL_FLAGS="-j$(( $(( $(sysctl -n hw.ncpu) + 1 )) / 2))" + RELEASE_FLAGS="-j$(( $(( $(sysctl -n hw.ncpu) + 1 )) / 2))" MAKE_FLAGS="-s" @@ -190,7 +192,7 @@ env_check() { ${CONF_FILES}" RELEASE_KMAKEFLAGS="${MAKE_FLAGS} ${KERNEL_FLAGS} \ KERNCONF=\"${KERNEL}\" ${ARCH_FLAGS} ${CONF_FILES}" - RELEASE_RMAKEFLAGS="${ARCH_FLAGS} \ + RELEASE_RMAKEFLAGS="${ARCH_FLAGS} ${RELEASE_FLAGS} \ KERNCONF=\"${KERNEL}\" ${CONF_FILES} ${SRCPORTS} \ WITH_DVD=${WITH_DVD} WITH_VMIMAGES=${WITH_VMIMAGES} \ WITH_CLOUDWARE=${WITH_CLOUDWARE} XZ_THREADS=${XZ_THREADS}" From nobody Wed Apr 17 05:43:56 2024 X-Original-To: dev-commits-src-branches@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 4VK8wX2xKfz5Hv5G; Wed, 17 Apr 2024 05:43:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wX1CbFz4l78; Wed, 17 Apr 2024 05:43:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332636; 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=dewWY+XVDlFKX6q6CdaNuSZboYcEoaeGA2oXi2bJ1nY=; b=IBq9zY41Eht8pXt4MXQ55OiumvmaOXno86jCO1tuKVXxw92bYbrJSK3vmksAR3W6sS3DC/ BGA3HBoNN4hAWws3Fj+lfp0+PZ1ehYngKW9boJFwKrlUXBHSR+RGrHxjoqLJBboA2meLQ4 vm3+bhLqFQpOVqeJSLFgI4Bn3dEy3WsRkvU7SK3rkYpG7/bRJlqH8+4WX57s0uLAeUzuCZ Ej4n3aLLq44YlR89uMNVrguKgxMFIlnBpChHv0AYO219PmIC3jh3IqMVRQ/GB9fA+XX+QO T3AZsdm0d1fxuxMC8KEa7g3Lm4Mxq1ryofnlX/YkDz+zFx35T85GtPjzwDlVMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332636; a=rsa-sha256; cv=none; b=UD+rQ/MRORrdz1DOqKPwLksK2LT9g8Fm6wFbKyYuNghmNRbkgYmOoQzwGRN1yOQbg1LPF8 IjpGezUjxD72XyDUxmmKpe/QEgRGhZdv223AOHzP7v6zAipQv1rqf6/sIKfOtI3PqHIa11 5+NZlowEZIRQYrGmtkjn64dT7EQalg53GTLeeUrI4YdsY9ED8xPeVU1+4CHWi9pRER2Htg Vj7nYincozqT+D0sNbw6SdfqmdyiFnv/LaK8zQv+Y13tkNFiBcu+INWd5sTCnfOw3MXcFt wh7FxbYGSrEnJcRNryPOE76IJfMAKWgTApu5ksahDJWwacDJjzMUcpvQlXeXAQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332636; 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=dewWY+XVDlFKX6q6CdaNuSZboYcEoaeGA2oXi2bJ1nY=; b=TQjhp0nC2aK8rkj9lPoAEGJmVhQN6sgzHRw7dC6HoMzc1HFWDz/cH2QyedV+C3WMoF+fe+ gKE5o5vvPyYNEnmSxWkT1twrvkrIa5QK/Ewo1ELMghuP1q87TjtC5NMqSsXt8RiLOCJ+uN Q9znluiwfPFEdzqRU0NvTRRC5c0t4fgUhqhthUeiyZG2iqt8vqKWCV2JhWyESaIoMD/PT2 W31s/k4ro+nnDfJEzcT91j2UEvjRyWx1Ab1w0dNCxd3L7nINWZEjdgdF4VAGrHmu4SqTtD J7VhmTA2H0fi/6aI5HWWU4ppETLs/oilg4EK/l/iB/X+nHB8SVaQVRKVvh2tuQ== 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 4VK8wX0r4DzDs2; Wed, 17 Apr 2024 05:43:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hugf006756; Wed, 17 Apr 2024 05:43:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5huDC006753; Wed, 17 Apr 2024 05:43:56 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:56 GMT Message-Id: <202404170543.43H5huDC006753@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: ffddfd3631de - stable/14 - release/Makefile.vm: Support read-only ports tree List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ffddfd3631de5b4104af5e0ee1331508ea2a46f3 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=ffddfd3631de5b4104af5e0ee1331508ea2a46f3 commit ffddfd3631de5b4104af5e0ee1331508ea2a46f3 Author: Colin Percival AuthorDate: 2024-04-11 16:24:59 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release/Makefile.vm: Support read-only ports tree Build qemu (if needed) with WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles so that we can have a read-only /usr/ports and don't contaminate it. This became an issue when I enabled parallel release building, since one image might be creating its ports.txz file at the same time as we're building qemu as a prerequisite for building another image. MFC after: 5 days (cherry picked from commit 6f454c211b295ad13e80fc5b858efc9bad33e33b) --- release/Makefile.vm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index a936e6cb98ca..54fee60b2e22 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -76,7 +76,10 @@ ${_V}!= eval $$(awk '/^${_V}=/{print}' ${.CURDIR}/../sys/conf/newvers.sh); echo emulator-portinstall: .if !exists(/usr/local/bin/qemu-${TARGET_ARCH}-static) .if exists(${PORTSDIR}/emulators/qemu-user-static/Makefile) - env - UNAME_r=${UNAME_r} PATH=$$PATH make -C ${PORTSDIR}/emulators/qemu-user-static BATCH=1 all install clean + env - UNAME_r=${UNAME_r} PATH=$$PATH \ + make -C ${PORTSDIR}/emulators/qemu-user-static \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean .else .if !exists(/usr/local/sbin/pkg-static) env ASSUME_ALWAYS_YES=yes pkg bootstrap -y From nobody Wed Apr 17 05:43:57 2024 X-Original-To: dev-commits-src-branches@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 4VK8wY5sxPz5Hv7F; Wed, 17 Apr 2024 05:43:57 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wY2Dzpz4lM8; Wed, 17 Apr 2024 05:43:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332637; 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=pt6mt6nq2tnarhmZpJ6N66Z6PZhdiJ1nUMyHroUsTT0=; b=KMVfdVUIj2jZBJYT9G2UGz9PezzkWbTja3e2QSj93KvnojhsY24JnOf8TP1RgtMCuhB33e +36eBJuM4cwWLTQ7khZVAjZiCnGAJOc23uJs4rsM5tGVKpTK9jH7v0y4q1nkSQUpn0Mpf5 mLqrS65jL7tISUEC9o2I50bBFtpMr6bPjbdCanwKI8Eu0lk5/4qtkie0zIf7hQyX5pWlg8 JvhlE6henVjpfyXBo4T5d3KCGYu5XzWejyaKGfk7nuGpSi4AT4n4kaIvF+W2jqBsnxpHm9 SoTVZ58SxldnknjotrodhE++TJQrs0bYIwvKPwGO+/I4UCKr9xh8KM9g1gowYw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332637; a=rsa-sha256; cv=none; b=bRbbtBNxW6q6cHEkMIxhJ7CnuHXdgdehuF0ambKjrFAyVUMz2wSPORnbdZhBQek8yVyRAZ WNuudduJXeCBNJsUukUcR0VYeYikFXa7TzO0QRTScfiblB2yLri04LZa1o5xRnP17FyF+2 f5DwBEsj+diAyU98XGK1kd/DxuLUOjN4pDo73uoRui5ePxiCsEDpkPo0VaU00S5lRNJXm+ JOU+U3tWQJqhhZxnBYP8QtZ4B152BQzYUizTcxuVIBQ5G/+fTBuLgc7kwgSBCmt+XvmCw7 0hsx3qtzTzAf/5ODCdy+2dyrbiyqSAbCY4KDCR+Q9G4ijS6eLTQmL8bQxYy7ew== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332637; 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=pt6mt6nq2tnarhmZpJ6N66Z6PZhdiJ1nUMyHroUsTT0=; b=Y9NfvtbnIB1bf03ErY6B/wqpPpN4Kuv7FGZo+9dSVQpSP6upet13IDh19cv4NPRGoeewVo Ys4Zj/uv8mbjhLRis3DypfvsyhBozE7aN6MmheiZUR4hI3OzC5foz2Dhe0pJ+XDB6csMC4 lZgzHqUDrv15611c7THgruY9qPR7wViOkdcayJDSE/uox6vTjA5CoUtpxLVDGvGySVC43h Kwqi/VKgR33p5zepNkdKlZAiY+h/i4xUHD/BMVIEFjLMLC437XXWu7Lirb2+OcmKS68a4I JfD9kQgO14XyREuY2NhlDVgJPeeh8Zo4o7NYFzDDGCaq5658LztCjLbtrL3N8Q== 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 4VK8wY1q7WzF05; Wed, 17 Apr 2024 05:43:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hvjR006802; Wed, 17 Apr 2024 05:43:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hvmr006799; Wed, 17 Apr 2024 05:43:57 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:57 GMT Message-Id: <202404170543.43H5hvmr006799@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 2bd006237fbe - stable/14 - ec2: homedir bug fixed in 24.1.4 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2bd006237fbef7cb4ba1c70c89431ab3e2fd4fbd Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=2bd006237fbef7cb4ba1c70c89431ab3e2fd4fbd commit 2bd006237fbef7cb4ba1c70c89431ab3e2fd4fbd Author: Mina Galić AuthorDate: 2024-04-11 20:16:58 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 ec2: homedir bug fixed in 24.1.4 This bug fix is due to be released in Quarterly: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275896 While here, overwrite the `doas` stanza, which needs to correspond to the user that we are creating. MFC after: 5 days Sponsored by: The FreeBSD Foundation Pull Request: https://github.com/freebsd/freebsd-src/pull/1163 (cherry picked from commit 2039437c7655c9cd481c6c4ad92b6bc2a945dd14) --- release/tools/ec2-cloud-init.conf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/release/tools/ec2-cloud-init.conf b/release/tools/ec2-cloud-init.conf index 2dd4df390fa3..7682d635b1d6 100644 --- a/release/tools/ec2-cloud-init.conf +++ b/release/tools/ec2-cloud-init.conf @@ -23,8 +23,9 @@ vm_extra_pre_umount() { lock_passwd: True groups: [wheel] shell: /bin/sh - # Currently broken, cloud-init hard-codes to /usr/home/* homedir: /home/ec2-user + doas: + - permit nopass ec2-user EOF return 0 From nobody Wed Apr 17 05:43:59 2024 X-Original-To: dev-commits-src-branches@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 4VK8wb6BStz5HvFZ; Wed, 17 Apr 2024 05:43:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wb3Dftz4lS8; Wed, 17 Apr 2024 05:43:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332639; 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=477hn5FhHNmmhOCqfgpzHrWJg9STWF3251F1ZH8EUsg=; b=KeWZt/MoXUOy4xeVkdXMN47tiWnrIPo/ltQFBfUmcyoABsuSVT+LMBdDkk4hlIK/farzVg CY3bDL6528dzIJ6ptAMOvjy7Jhq10Rc1ht4Oz0u7khOnDAIJ5w8lEjCHIkv3yHrmwWs6UC wNmalmSJjdlrWd/lp7uRAtBebjbfeJzdK60HtrAMSSkSC8QH6z0hJHURp+dXekM/s3yIPj jeQvvq3XshozcBi3DXi8i9dRnbc5MP9LTA1As71lzbibqpR9s0cJQ79Hmb9FjRW5h2E04d KVsUCZ2SxYYRtXdrHLyN0GvKvOyKNMiHkSOJ0BRAfDomedn49PwK/fjEtlvnww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332639; a=rsa-sha256; cv=none; b=n8YTiO/kCn88L3GYfvXhwaxPd535EElbXdtTPnWRtt5VSZAeJ0HIwUJ1kJ86/smw2kTZXy Bi5emOFXXmQribVWYksKeAvH3alF99NEa+F5TQ2x/OtN7vJDJq5ELSEAv3adY+PRsuqXgC nDNtXa8U6GXW7/pA7clJViDenErwy1NyvVkt7iAnPObqPTDG3/Lvg1u+luaKsylvxuhs9f Csqqy/gt/1WjWD0mtQJCg32G9jCthYyOzg0ylBzd4qwt255Y7hAwi0szvdEr4CdD2Tq0/E I25mhtEYHITVlOhiSId4JRS0M4PUB7z/mJXgMxdg5+gmh3FAP0ExlU354V2d0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332639; 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=477hn5FhHNmmhOCqfgpzHrWJg9STWF3251F1ZH8EUsg=; b=qjwiDEqwV9EatRoNoCazMBBQPQ4q6bVo3uUqinzghZhOeBZXoLS/fIRZXcczUgjzDIHEW9 7IXq2NIsnsLoMg9a9P94Y+IQQEjaOtw27FQ/y+zWLFDtgcJ/Y91cjFiPrLzCleKRRLN9DS d+TLfeMVwz1N/msTtZeWlf2aGtDmFX3VE2rkrw7E34KCflnhEQHow7OHSfxqgfnNIbjdkT K5aXVe6BJEhRs3+fR5PQFN2fLfMafFfgAfxJbNqL6zldiNnu85z62nYKRKJ7hza+4biiJD t8g8XGi6IriNKxvDLvk17nF7WGwphydJxnmzexE9GEO1dwndgg2wb5ubyXVIoQ== 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 4VK8wb2s9LzF06; Wed, 17 Apr 2024 05:43:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hx1t006902; Wed, 17 Apr 2024 05:43:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hxwj006899; Wed, 17 Apr 2024 05:43:59 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:59 GMT Message-Id: <202404170543.43H5hxwj006899@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 434dc04e34c0 - stable/14 - release: Randomize powerpc boot block file name List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 434dc04e34c04a7a1c081902ab569051458d473f Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=434dc04e34c04a7a1c081902ab569051458d473f commit 434dc04e34c04a7a1c081902ab569051458d473f Author: Colin Percival AuthorDate: 2024-04-12 17:42:05 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release: Randomize powerpc boot block file name With parallel builds enabled, we can end up building multiple ISOs at once, which causes problems if mkisoimages.sh uses a consistent file name "/tmp/hfs-boot-block". MFC after: 3 days (cherry picked from commit 6c3e01bf8578de54abc019832d799de80da7378c) --- release/powerpc/mkisoimages.sh | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/release/powerpc/mkisoimages.sh b/release/powerpc/mkisoimages.sh index 8a802e6c62ae..e030ee41691c 100644 --- a/release/powerpc/mkisoimages.sh +++ b/release/powerpc/mkisoimages.sh @@ -67,14 +67,15 @@ fi if [ -n "$bootable" ]; then echo "Building bootable disc" + BOOTBLOCK=$(mktemp /tmp/hfs-boot-block.XXXXXX) + # Apple boot code - uudecode -o /tmp/hfs-boot-block.bz2 "`dirname "$0"`/hfs-boot.bz2.uu" - bzip2 -d /tmp/hfs-boot-block.bz2 - OFFSET=$(hd /tmp/hfs-boot-block | grep 'Loader START' | cut -f 1 -d ' ') + uudecode "`dirname "$0"`/hfs-boot.bz2.uu" | bunzip2 > $BOOTBLOCK + OFFSET=$(hd $BOOTBLOCK | grep 'Loader START' | cut -f 1 -d ' ') OFFSET=0x$(echo 0x$OFFSET | awk '{printf("%x\n",$1/512);}') - dd if="$BASEBITSDIR/boot/loader" of=/tmp/hfs-boot-block seek=$OFFSET conv=notrunc + dd if="$BASEBITSDIR/boot/loader" of=$BOOTBLOCK seek=$OFFSET conv=notrunc - bootable="-o bootimage=macppc;/tmp/hfs-boot-block -o no-emul-boot" + bootable="-o bootimage=macppc;$BOOTBLOCK -o no-emul-boot" # pSeries/PAPR boot code mkdir -p "$BASEBITSDIR/ppc/chrp" @@ -108,7 +109,9 @@ if [ -n "${METALOG}" ]; then fi makefs -D -N ${BASEBITSDIR}/etc -t cd9660 $bootable -o rockridge -o label="$LABEL" -o publisher="$publisher" "$NAME" "$MAKEFSARG" "$@" rm -f "$BASEBITSDIR/etc/fstab" -rm -f /tmp/hfs-boot-block +if [ n "$bootable" ]; then + rm $BOOTBLOCK +fi rm -rf "$BASEBITSDIR/ppc" if [ -n "${METALOG}" ]; then rm ${metalogfilename} From nobody Wed Apr 17 05:43:58 2024 X-Original-To: dev-commits-src-branches@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 4VK8wZ5YCdz5Hv9S; Wed, 17 Apr 2024 05:43:58 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wZ2tfhz4lMJ; Wed, 17 Apr 2024 05:43:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332638; 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=YntBxYJb2jltYmJ4lL417NfSzTZpu+rL1wYP4bY6XAI=; b=JecsBllzTdwyiZ5K0mfxOBGpqr0KGschuFBgND8NYGcFPtj4vkObrKaEIEwo1fGiBAxo4U Aeo+5IGr9IIl3KuZNG8pZ8+ZlsUKNchvgi+FNITzA0MblCBIcs5x6QzZjT0YyDzRoDTt6x uIBxdvfq8LBnt1CLoBGCZ6A34sZ++4mNulNgrH455ubiioz5S5nyeQMGDg2YHlzraBSRs7 /xA/aDM1yPSRD1cHfpI+mDRpXLCPRZbMEbeMdayRiLosh+j2TmXHP5SO0CbTE2UHCWmB2k +b9/TTNoAGU1sT7i1w4krjYuy+mkgxRRbSkshDybLY7a7GPsqpM+hg2TM/6L4A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332638; a=rsa-sha256; cv=none; b=v5cC2cy757etRp8tLm/OztW0/IUYeC6hz7PtXCm74x5enwnqWdalU5zQTMT0PO4jJZvoop AZufBfQ6EYa0LYpDqAyV7HDWCYSLmS/HaNx6mgb47+25eY4taduZFsE0D4zXHwNrG9sXdg nJhdSPN+57SGceBovDX8GXssNpM81Go6JXBN6H86cRF/pDp/uBEwTfFb39SYKCzWp4jD5C 6dMDTW0Nch72D+pESHIW8jcNk52O/A8dTTrl14mJxB+rptI3CMCPaCK1a6YHtRY4ffXrMx kWvbjswRSYKDY0jzPTdKCSqFP8IFQLxf6Ci3JZTUWLQeH1JDzbRAbJ753Xoq8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332638; 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=YntBxYJb2jltYmJ4lL417NfSzTZpu+rL1wYP4bY6XAI=; b=nZFcweiFlQopg/4T76IE4quWT+ZftmwQxX9rtQLKL5dr7jrSTO+FfY49DlkxL7WGVJtZHR KGrUtjoJ6MCGh08LLERMr4P/WxKOspQawxgulan4XRuvd/yl3RLAL7bbtWcNCteq5RFlS6 SiXL8bBQ1Zy6s2m/gPfbTGuma9vpowkuelLJUgyPCI9XV1us7bgULYKeYhPnCqOaRVwTlu A8EnIRthn3XKA8k7szGABmSZOWKS7M/goTaTtArtk4maMJvl4A6MzdFGf4XcrIO97RHZeV r+Qd+uhOlDcGX2nnxJvEniZ4+XCjNedQRRi/i6C+bDqQoHFFMyT0WUNLA1cVlA== 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 4VK8wZ2Vw1zFBt; Wed, 17 Apr 2024 05:43:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5hwlS006851; Wed, 17 Apr 2024 05:43:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5hwtB006848; Wed, 17 Apr 2024 05:43:58 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:43:58 GMT Message-Id: <202404170543.43H5hwtB006848@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 5f2695943de6 - stable/14 - release: Support r/o /usr/ports for cloudware List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5f2695943de6debefe05d387a19d36ac47e281f1 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=5f2695943de6debefe05d387a19d36ac47e281f1 commit 5f2695943de6debefe05d387a19d36ac47e281f1 Author: Colin Percival AuthorDate: 2024-04-12 17:20:25 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release: Support r/o /usr/ports for cloudware Set WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles when building tools needed for uploading cloudware images. While I'm here, adjust the bsdec2-image-upload build target to match the style used by the Azure/GCE/Vagrant Makefiles. MFC after: 3 days (cherry picked from commit 6c87aed39c3053cd338c1ec18fba5b1d773beca9) --- release/Makefile.azure | 4 +++- release/Makefile.ec2 | 16 ++++++++++------ release/Makefile.gce | 8 ++++++-- release/Makefile.vagrant | 4 +++- 4 files changed, 22 insertions(+), 10 deletions(-) diff --git a/release/Makefile.azure b/release/Makefile.azure index a8f59282a09c..36f3f8715de1 100644 --- a/release/Makefile.azure +++ b/release/Makefile.azure @@ -37,7 +37,9 @@ azure-check-depends: . endif env ASSUME_ALWAYS_YES=yes pkg install -y sysutils/py-azure-cli . else - env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/sysutils/py-azure-cli BATCH=1 all install clean + env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/sysutils/py-azure-cli \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean . endif .endif diff --git a/release/Makefile.ec2 b/release/Makefile.ec2 index c674c967ff57..8f5f6f205779 100644 --- a/release/Makefile.ec2 +++ b/release/Makefile.ec2 @@ -40,13 +40,17 @@ CW_EC2_PORTINSTALL= .endif cw-ec2-portinstall: -.if exists(${PORTSDIR}/net/bsdec2-image-upload/Makefile) - env - UNAME_r=${UNAME_r} PATH=$$PATH make -C ${PORTSDIR}/net/bsdec2-image-upload BATCH=1 all install clean -.else -. if !exists(/usr/local/sbin/pkg-static) - env ASSUME_ALWAYS_YES=yes pkg bootstrap -y -. endif +.if !exists(/usr/local/bin/bsdec2-image-upload) +. if !exists(${PORTSDIR}/net/bsdec2-image-upload/Makefile) +. if !exists(/usr/local/sbin/pkg-static) + env ASSUME_ALWAYS_YES=yes pkg bootstrap -yf +. endif env ASSUME_ALWAYS_YES=yes pkg install -y net/bsdec2-image-upload +. else + env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/net/bsdec2-image-upload \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean +. endif .endif @touch ${.TARGET} diff --git a/release/Makefile.gce b/release/Makefile.gce index 2bfdf4edc246..51dc5e3436e2 100644 --- a/release/Makefile.gce +++ b/release/Makefile.gce @@ -43,8 +43,12 @@ gce-check-depends: env ASSUME_ALWAYS_YES=yes pkg install -y net/google-cloud-sdk \ lang/python . else - env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/net/google-cloud-sdk BATCH=1 all install clean - env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/lang/python BATCH=1 all install clean + env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/net/google-cloud-sdk \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean + env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/lang/python \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean . endif .endif diff --git a/release/Makefile.vagrant b/release/Makefile.vagrant index bcfbf9a5a6f7..d8f3c14e9498 100644 --- a/release/Makefile.vagrant +++ b/release/Makefile.vagrant @@ -57,7 +57,9 @@ vagrant-check-depends: . endif env ASSUME_ALWAYS_YES=yes pkg install -y curl . else - env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/ftp/curl BATCH=1 all install clean + env UNAME_r=${UNAME_r} make -C ${PORTSDIR}/ftp/curl \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean . endif .endif From nobody Wed Apr 17 05:44:00 2024 X-Original-To: dev-commits-src-branches@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 4VK8wc6N5Pz5Hv5H; Wed, 17 Apr 2024 05:44:00 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wc4JJ0z4lbC; Wed, 17 Apr 2024 05:44:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332640; 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=0Wp+xrupSGCJ8Jwghv+0v9r2MEVP3mJa2b+u2UWe6eU=; b=bcJWHnBDycNsV07xhqpln6mHdkILhK19+sKwudMP/dVnST6jdD0k3bXijFLZRNhWcYPYeE Xf0zSpVqs10TBWOhkCOaPimDH7XNaMabRNQn7v0Is4+KToTHXxQ/PYDDNMEBfdTZbUXWiE m9wCLpvpoJiHqBY+K3dakcIjN5xr6wGGYwSbW+yux8Qh/CwU9C9eThcV4V2uCoM+Ejrpz9 q2Y1tDl23syEGfQdBn56EzYoJLvb1wjqRRDI3EaVRCBShtw/Nkj4fCL/azU0L3YSnanWOm 01txqouecy3j4Kt4Ng8gYfwkk/AUn/hD04CzJpuqT/kuHpXZ04D5xb8PoYx7xw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332640; a=rsa-sha256; cv=none; b=iEp2sOzY+1q52q3Vx3UFUsYhoJW7teIjBPhD9DO3rNkPGA7vC0kdtK8F353zMjuiAurEw4 CtOB+g4aja3epX5v8YnK1XQC59pxTpDwM4Lxad/gqJyUI6Js+EwZ5B4Tzh8glGuAYBD50Z 7prf7T9pwcpSDd1xmPjI0tx8TKrim5A0vTkv+OayDW0U9MuFF9k99zjeujpo3jFaJap8AU 95hqpQpLQG2wvMRB8PWkgV0B0izF/k9XR5GUlwEK4kL8hAMeT7KyOTbUsgwZY55sYjkWs2 Vyf9Zl3zUI3RZwm9LwtaStVUrWlZXD5FrjC+Xpk1OmzApxRwqVFxWQqKJQG/TQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332640; 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=0Wp+xrupSGCJ8Jwghv+0v9r2MEVP3mJa2b+u2UWe6eU=; b=cX7+6tKfEwGH1IuGY+CCShiHRQHaUCV8GbBVV6MtCbupMJibJO/1vJoKhN+kr2J2nSHNFL 8OLVdly+lCpE36feBgsy75+nPo3iIUFur78fhScfIT7nPygeIyRt4mnbW3nG8BWId0XxG1 uYfB1w/xrn/DG+k3RmKIwzrGMSeMwSOMfsw6WBCYsBUQIeSBWLXDSsFN9sjAI9byD2z+kA wkV6mvKGsheCtu3cQUoskB3VWI0qIYvjDhNCyH3bpjn8+1CKIN3s0OQNEvwam+L9833hqC /x58S6ZTE7vf4+43f74sxhas1rzAAfsh8J2vvaFbcRUW5blChuHSquUpgSASFw== 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 4VK8wc3wRCzFPl; Wed, 17 Apr 2024 05:44:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5i0j7006974; Wed, 17 Apr 2024 05:44:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5i0fj006971; Wed, 17 Apr 2024 05:44:00 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:44:00 GMT Message-Id: <202404170544.43H5i0fj006971@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 449dc2854000 - stable/14 - release: Fix powerpc boot block uudecoding List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 449dc2854000a7bc7ca8e06bf7381a840d9e4b5f Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=449dc2854000a7bc7ca8e06bf7381a840d9e4b5f commit 449dc2854000a7bc7ca8e06bf7381a840d9e4b5f Author: Colin Percival AuthorDate: 2024-04-13 00:50:15 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release: Fix powerpc boot block uudecoding Confusingly, uuencode writes to stdout by default, but uudecode does not. Fixes: 6c3e01bf8578 "release: Randomize powerpc boot block file name" MFC after: 3 days (cherry picked from commit 4d7174b1d91ff3651ef78987d93989a40a4facd2) --- release/powerpc/mkisoimages.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/powerpc/mkisoimages.sh b/release/powerpc/mkisoimages.sh index e030ee41691c..ba7c32f87bee 100644 --- a/release/powerpc/mkisoimages.sh +++ b/release/powerpc/mkisoimages.sh @@ -70,7 +70,7 @@ if [ -n "$bootable" ]; then BOOTBLOCK=$(mktemp /tmp/hfs-boot-block.XXXXXX) # Apple boot code - uudecode "`dirname "$0"`/hfs-boot.bz2.uu" | bunzip2 > $BOOTBLOCK + uudecode -p "`dirname "$0"`/hfs-boot.bz2.uu" | bunzip2 > $BOOTBLOCK OFFSET=$(hd $BOOTBLOCK | grep 'Loader START' | cut -f 1 -d ' ') OFFSET=0x$(echo 0x$OFFSET | awk '{printf("%x\n",$1/512);}') dd if="$BASEBITSDIR/boot/loader" of=$BOOTBLOCK seek=$OFFSET conv=notrunc From nobody Wed Apr 17 05:44:01 2024 X-Original-To: dev-commits-src-branches@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 4VK8wd7165z5HvFf; Wed, 17 Apr 2024 05:44:01 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wd5NM0z4lbV; Wed, 17 Apr 2024 05:44:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332641; 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=auvGgvSET3x+/8JkcBv409nqEQNnHEWRuAVHtUbi8PM=; b=obgF4GwVMH3YgjWSx+FA6COtB1OP1DgMbj6QrXtRQxUQ0hvDNjrmE8UbbPcr94/2XSxnPT uBwr5TK11lnaqigh9Vu6BWpQw1i23yfw75RhVxKzOQy3pvmGMj4Iy2y80pGruF2HF32Hxv OrjGIj2awLX+bCEsGUeiIoCxMK4rGdIE16NaymKDein6Qq26lM599vLDWZtRniZA8uPJgw 5N/XbOWlWGmzNEvftxGeEZNgB2zrBXDz77RM4R0N2mp6x/6/9EjnNwEdqE2SqnNX2Y0AKA waSCk+byW3Mbr6ZdYvnl2EHShodjtcctsmKlHj1Ft/najwaZQkdVa/WzRjHtWw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332641; a=rsa-sha256; cv=none; b=dODXmCysPCrpDzofVWHsDFDW7TuhZSzGmxCUMeTnGpsJ0y4F9COK3Y1DzF7MxZAF63rRm7 Fgzj2cPb7hIPVgud8G3kTSJurrZTFvMhTGDqmUUvwOujpXqGv2dRyAarH+2hVJ0KW8iBhH +TECTar8H/FrG+jKBzn1TI0/68/dJZD62acLWH259oG2GIRPTOvL92yRSCSvnjzw0V25HS 9tnmOlWUW5BIxzE6yRumKM3F3AmrARHIEt8x059AboT4vaBBNCucLvL1I5R08zV8dlcxCK S94S8nyP9t2WG1e/iQgVJVpMTFpeRcp2SEjmDlPrN0AsBx1W70TUCC9i3Uu+Gw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332641; 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=auvGgvSET3x+/8JkcBv409nqEQNnHEWRuAVHtUbi8PM=; b=anTtmeXdZSFU7rKTk8GCT8fkelBtpx0RxuAcg7X0Z75l6BHT3M0GYds6QmXVMgkclSFape HUbMJMO3K0h/+5a7yC0bHNjks2p6sL55uVRKXXwcHyfp5qowQDnchCGZiYaNQL5Hc7Tj3u j7d3ZTFyLzdxe/Fu/uQygLKUuyo6cOwWBanS3J7uoVXE4bzAMK7AGbkA2bbtJGJ5xYgUEE zkRZGjzaC3DNQndjjxGBdSM0yUp1EXvyBJo9e9hpCCI4Wy2WYetL+qsEdqd4XsEBaS5Nzh aPbJnN0y9fYjG8yAodfEWc4Xg2orJ9U1z8+ugSc+M6DqZ3VMnu/zghW2ydhRIw== 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 4VK8wd4zX1zFBv; Wed, 17 Apr 2024 05:44:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5i1db007026; Wed, 17 Apr 2024 05:44:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5i1CC007023; Wed, 17 Apr 2024 05:44:01 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:44:01 GMT Message-Id: <202404170544.43H5i1CC007023@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 1c9953bea952 - stable/14 - cloudware: allow disk format to be a list List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1c9953bea952e1805dd44705d5e1566c3fb7181b Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=1c9953bea952e1805dd44705d5e1566c3fb7181b commit 1c9953bea952e1805dd44705d5e1566c3fb7181b Author: Colin Percival AuthorDate: 2024-04-14 17:44:07 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 cloudware: allow disk format to be a list Make basic-cloudinit available both in qcow2 and raw formats MFC After: 3 days Co-Authored-By: bapt Sponsored by: OVHCloud (original patch from bapt) Differential Revision: https://reviews.freebsd.org/D44747 (cherry picked from commit 5c213bf01a5dca7c4030efd2ad9c9f84852e7b32) --- release/Makefile.vm | 48 ++++++++++++++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 18 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 54fee60b2e22..136e58e1aded 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -30,7 +30,7 @@ AZURE_DESC= Microsoft Azure platform image BASIC-CI_FORMAT= raw BASIC-CI_FSLIST= ufs BASIC-CI_DESC= Image for CI -BASIC-CLOUDINIT_FORMAT= raw +BASIC-CLOUDINIT_FORMAT= raw qcow2 BASIC-CLOUDINIT_FSLIST?= ufs zfs BASIC-CLOUDINIT_DESC?= Images for VM with cloudinit disk config support EC2_FORMAT= raw @@ -103,32 +103,44 @@ QEMUTGT?= ${_CW:tu}CONF?= ${.CURDIR}/tools/${_CW:tl}.conf . endif . for _FS in ${${_CW:tu}_FSLIST} -CLOUDTARGETS+= cw-${_CW:tl}-${_FS} -CLEANDIRS+= cw-${_CW:tl}-${_FS} -CLEANFILES+= ${_CW:tl}.${_FS}.img \ - ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} \ - ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT}.raw -${_CW:tu}${_FS:tu}IMAGE= ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} - -cw-${_CW:tl}-${_FS}: ${QEMUTGT} +. for _FMT in ${${_CW:tu}_FORMAT} +CLOUDTARGETS+= cw-${_CW:tl}-${_FS}-${_FMT} +CLEANDIRS+= cw-${_CW:tl}-${_FS}-${_FMT} +CLEANFILES+= ${_CW:tl}.${_FS}.${_FMT}.img \ + ${_CW:tl}.${_FS}.${_FMT} \ + ${_CW:tl}.${_FS}.${_FMT}.raw +${_CW:tu}${_FS:tu}${_FMT:tu}IMAGE= ${_CW:tl}.${_FS}.${_FMT} + +cw-${_CW:tl}-${_FS}-${_FMT}: ${QEMUTGT} mkdir -p ${.OBJDIR}/${.TARGET} env TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} SWAPSIZE=${SWAPSIZE} \ QEMUSTATIC=${QEMUSTATIC} \ ${.CURDIR}/scripts/mk-vmimage.sh \ -C ${.CURDIR}/tools/vmimage.subr -d ${.OBJDIR}/${.TARGET} -F ${_FS} \ - -i ${.OBJDIR}/${_CW:tl}.${_FS}.img -s ${VMSIZE} -f ${${_CW:tu}_FORMAT} \ - -S ${WORLDDIR} -o ${.OBJDIR}/${${_CW:tu}${_FS:tu}IMAGE} -c ${${_CW:tu}CONF} + -i ${.OBJDIR}/${_CW:tl}.${_FS}.${_FMT}.img -s ${VMSIZE} -f ${_FMT} \ + -S ${WORLDDIR} -o ${.OBJDIR}/${${_CW:tu}${_FS:tu}${_FMT:tu}IMAGE} -c ${${_CW:tu}CONF} touch ${.TARGET} +. endfor . endfor -# Hardlinks from "foo.bar" to "foo-${VMFS}.bar". These can go away once all -# of the cloudware code knows how to handle multiple filesystem images (or +# Hardlinks from "foo.${FMT}" to "foo-${VMFS}.${FMT}". These can go away once +# all of the cloudware code knows how to handle multiple filesystem images (or # at least knows the name of the UFS image). -CLOUDTARGETS+= cw-${_CW:tl} -CLEANFILES+= ${_CW:tl}.${${_CW:tu}_FORMAT} -${_CW:tu}IMAGE= ${_CW:tl}.${${_CW:tu}_FORMAT} -cw-${_CW:tl}: cw-${_CW:tl}-${VMFS} - ln -f ${${_CW:tu}${VMFS:tu}IMAGE} ${${_CW:tu}IMAGE} +. for _FMT in ${${_CW:tu}_FORMAT} +CLOUDTARGETS+= cw-${_CW:tl}-${_FMT} +CLEANFILES+= ${_CW:tl}.${_FMT} +${_CW:tu}${_FMT:tu}IMAGE= ${_CW:tl}.${_FMT} +cw-${_CW:tl}-${_FMT}: cw-${_CW:tl}-${VMFS}-${_FMT} + ln -f ${${_CW:tu}${VMFS:tu}${_FMT:tu}IMAGE} ${${_CW:tu}${_FMT:tu}IMAGE} +. endfor + +# Targets without a disk format listed are the first disk format on the list +. for _FS in ${${_CW:tu}_FSLIST} +${_CW:tu}${_FS:tu}IMAGE= ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT:[1]} +cw-${_CW:tl}-${_FS}: cw-${_CW:tl}-${_FS}-${${_CW:tu}_FORMAT:[1]} +. endfor +${_CW:tu}IMAGE= ${_CW:tl}.${${_CW:tu}_FORMAT:[1]} +cw-${_CW:tl}: cw-${_CW:tl}-${${_CW:tu}_FORMAT:[1]} . endfor .endif From nobody Wed Apr 17 05:44:02 2024 X-Original-To: dev-commits-src-branches@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 4VK8wg1BpWz5Hv5M; Wed, 17 Apr 2024 05:44:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wf6WVBz4lbm; Wed, 17 Apr 2024 05:44:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332642; 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=l0omID/BfosN54Y78iJToL401ceui0Up6rr8HDiOd8o=; b=BTyGzLYwIHv31arxRH8t7CJtosGqZfwSp3pOa4Btzsz1Rn1pCrWUozUm2S9uLIg2VUGe8G /IeJPZuLoLY0JqVaSx2cj130Qk42PsIRZIlOvuRYAozNGYR23m45TtHJb77N024BLtVGqK MTjU98HD7WrpQIakQ12WYu4evNNlvEURHsGTZ9B932PlhtxfDILKGZYx9tXp4aGYwsPD5N sOuzgsPcqg09TqzUVzt7O9TInhPKwGorK6mTTPnBpMuF0pZj/SZbgAwDltFEUnaAru9bJu a+Jku72LqD5XqBq/Hl+Oq2FZER0+0euC5D4KmlhmCE/WBunTPbsW1fFwAgoccQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332642; a=rsa-sha256; cv=none; b=Jok44rn6EEsYzwi/vGleX+Ol8J9P3IRBrRR86u7l2OW1cL3av4MR388i/sqwXykYMHgDWL zSjBjjYaoZ0crtAtXi3adxjeXcTUIfe76XLQOVAbkGbf36uQ022rkDa4VKi4wcn6PeL0mO Dn59DFO1UJzBMP46IDG/mtx0XM2nymG4kNkSHqzgXdoXljofzvu0ySn6Ikt1MS3ZvNGd6V xbW/9H52fsXA8MOEcL6+BlLS9pEK51aaYBgukTGzjmB+Pnd7hi8zyHge8Xb459PX0pNyjl qLUbcJCVFc2Kx04xZljCLkIzRRw1T2bh4gAVzuT9TfoKsLpm4DyxGS+zJW4lyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332642; 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=l0omID/BfosN54Y78iJToL401ceui0Up6rr8HDiOd8o=; b=EU90EN5NH80vZ3JfLlgDqWesuyOgwkweAa6nqtF/KSRu3769hAtT9YZmAnkB94ZdlCNo07 kvt5bPuODCcif8wIY5xZ4d5OgmFFqpQ0pWM6SZqC/taAY7f0qvdZCyNh5vvhB+8M21D8oo 518KDz9NTy3PdW5tBeGKpv+pru+6qm4O43IGPrLUM9bkwlQ4oWlaRywohkONSTGPuB0pwe TttJooUvdKsNk6cOi3mdcjJTkt10M2VJSyk9+rXWdrYGTfZke9V3uVtw0Ptne4lbNGa0SQ OQVYY9SfJoKd1zvttf00Jyv/duvaYwrqmiBbYn4NPrWAb0/w5Qw5sbisfcQXhw== 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 4VK8wf624CzDx1; Wed, 17 Apr 2024 05:44:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5i2ex007086; Wed, 17 Apr 2024 05:44:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5i2q0007083; Wed, 17 Apr 2024 05:44:02 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:44:02 GMT Message-Id: <202404170544.43H5i2q0007083@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 70dcf0608cfc - stable/14 - release: Use the ABI of the target release to fetch packages List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 70dcf0608cfc767321b16509f615c5dddb9378af Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=70dcf0608cfc767321b16509f615c5dddb9378af commit 70dcf0608cfc767321b16509f615c5dddb9378af Author: John Baldwin AuthorDate: 2024-04-13 21:16:01 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release: Use the ABI of the target release to fetch packages - Point --rootdir at the installed destdir in the dvd tree. This causes pkg to determine the ABI from the installed destdir instead of the host's binaries. Previously the result was that packages for the host's ABI were always downloaded breaking cross-releases (e.g. arm64 releases built on an amd64 host included amd64 packages on the DVD ISO image rather than arm64 packages). This also handles version mismatches, and I tested this by cross-building a 15.x arm64 release on a 14.x amd64 host. - As a result, pkg now does a chdir(3) to the rootdir before running, so the -o argument to fetch needs to be updated to be relative to rootdir instead of the CWD as make runs. - Add a new ROOTDIR variable to limit references to "dvd" to one place. Ideally ROOTDIR would be an argument to this script so that it didn't really know about the dvd layout at all. - While here, simplify creation of symlinks by just using a longer path to the link name instead of using 'cd' in the shell before invoking ln(1). Also use ln -sf to create the pkg.pkg symlink rather than rm + ln. PR: 278273 Reported by: gatekeeper Reviewed by: imp, delphij MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D44749 (cherry picked from commit ea2663040d524efd84b12edcbe83884437fdceea) --- release/scripts/pkg-stage.sh | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/release/scripts/pkg-stage.sh b/release/scripts/pkg-stage.sh index e53bd72db249..bdfa3643bacb 100755 --- a/release/scripts/pkg-stage.sh +++ b/release/scripts/pkg-stage.sh @@ -8,7 +8,8 @@ export ASSUME_ALWAYS_YES="YES" export PKG_DBDIR="/tmp/pkg" export PERMISSIVE="YES" export REPO_AUTOUPDATE="NO" -export PKGCMD="/usr/sbin/pkg -d" +export ROOTDIR="$PWD/dvd" +export PKGCMD="/usr/sbin/pkg -d --rootdir ${ROOTDIR}" export PORTSDIR="${PORTSDIR:-/usr/ports}" _DVD_PACKAGES="archivers/unzip @@ -47,14 +48,13 @@ if [ ! -x /usr/local/sbin/pkg ]; then /usr/bin/make -C ${PORTSDIR}/ports-mgmt/pkg install clean fi -export DVD_DIR="dvd/packages" -export PKG_ABI=$(pkg config ABI) -export PKG_ALTABI=$(pkg config ALTABI 2>/dev/null) -export PKG_REPODIR="${DVD_DIR}/${PKG_ABI}" +export PKG_ABI=$(pkg --rootdir ${ROOTDIR} config ABI) +export PKG_ALTABI=$(pkg --rootdir ${ROOTDIR} config ALTABI 2>/dev/null) +export PKG_REPODIR="packages/${PKG_ABI}" -/bin/mkdir -p ${PKG_REPODIR} +/bin/mkdir -p ${ROOTDIR}/${PKG_REPODIR} if [ ! -z "${PKG_ALTABI}" ]; then - (cd ${DVD_DIR} && ln -s ${PKG_ABI} ${PKG_ALTABI}) + ln -s ${PKG_ABI} ${ROOTDIR}/packages/${PKG_ALTABI} fi # Ensure the ports listed in _DVD_PACKAGES exist to sanitize the @@ -83,11 +83,10 @@ ${PKGCMD} fetch -o ${PKG_REPODIR} -d ${DVD_PACKAGES} # Create the 'Latest/pkg.txz' symlink so 'pkg bootstrap' works # using the on-disc packages. -mkdir -p ${PKG_REPODIR}/Latest -(cd ${PKG_REPODIR}/Latest && \ - ln -s ../All/$(${PKGCMD} rquery %n-%v pkg).pkg pkg.pkg) -(cd ${PKG_REPODIR}/Latest && \ - rm -f pkg.txz && ln -s pkg.pkg pkg.txz) +export LATEST_DIR="${ROOTDIR}/${PKG_REPODIR}/Latest" +mkdir -p ${LATEST_DIR} +ln -s ../All/$(${PKGCMD} rquery %n-%v pkg).pkg ${LATEST_DIR}/pkg.pkg +ln -sf pkg.pkg ${LATEST_DIR}/pkg.txz ${PKGCMD} repo ${PKG_REPODIR} From nobody Wed Apr 17 05:44:03 2024 X-Original-To: dev-commits-src-branches@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 4VK8wh2crnz5HttJ; Wed, 17 Apr 2024 05:44:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wh000Cz4lNQ; Wed, 17 Apr 2024 05:44:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332644; 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=suQLl7hqvt6qo0xjNS3BSdrnhtzVYMEUg7meMfwVqIw=; b=CKH+rEGMVOqxvASLQMaq3crBGyzTDHI/3xih8Wxw+dMwYW6RT+TtV2FeUiLty6UlIBP5YJ MAWXwve9PQKiU++JWVN5i5Fm5drti6FIQo3S+rkBy7diWHfjd3Hjh4Hn41GQtvY703o8Cy JFCaUj8FGaThdfC16nN4c33C4RRy87Ht6glTIuMzwbUcbszuAT/CvwDf7Dr20DS3mXNQgE fWoNm8IQzReiNSW/p5zKOH0tEcaqMyKr0icLimKPGrdLaw23LDO0Wtmw5K22/nANaEkipE Z8Em/rT6T4NTYjpYTD10PEi0nPgjyaFNMj8HaQi8S066NFDgsPxNyXzWqIrGGw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332644; a=rsa-sha256; cv=none; b=cBBZ80xTu4K/PpZxbfAREsLqaIw9JSzQLhtqyROdf5Z9a26xvL2bcxQbQYiGhRhL7Elu1t y5Jug09LVQPza2IRU5/L0LsfCFYBBx4XQgy6zQk5vfKBx4FAsNK1dFOy5Ey2c2l956hwBs Ilc7ue/29sRw+7CYyhv5/tVD3zUy7xgK/pH5ZdwxWbnQzvG70ginGOSpRWI9O7IXt6d1r5 5pg+l40zevYtfvCEVYTrZxMzHV5Z24vIUheaCp7U6JFEtVsMv6Iohm7nIF9RBJMaEoemO0 1OwiKPNZ9Sgm0qhQK0Q9KUg0wBZhHTASb7NAcCswUuqJscn1uQz509q5zY3t/A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332644; 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=suQLl7hqvt6qo0xjNS3BSdrnhtzVYMEUg7meMfwVqIw=; b=wfIy79H4mgKjDnufk8Lrtf8amAxaAK3FRT8ADfErjlFKPG7liAhDapY+w5UIdB7jFyraTo awe5VnDTUHW+YUXJdGIJSdIyDaWhukWgmJciprco9uDXau+IVnYhqhnuirm79uy8sOuGKL 3klIC4AXjlvbt+ScwEHz5w+z5+6LoV0MbO0PXkxoYtEdYNua7y7mtzGQ/bUXPMH8ES2GiH 5wMqObKprNq0WV9KgWqQtDqe/1+pfcf+IfsdqYO2DzIfDF1o1eIs5OxvHXKsmZ1i1y+Tvy x5jFSePRyd98SEDVGLI9f5u3ICDrN2vTFaml7zEygyFWqmtT03c5iMOOKU9xHQ== 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 4VK8wg6kJqzFBw; Wed, 17 Apr 2024 05:44:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5i3Ct007138; Wed, 17 Apr 2024 05:44:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5i366007135; Wed, 17 Apr 2024 05:44:03 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:44:03 GMT Message-Id: <202404170544.43H5i366007135@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: d576c1dd9744 - stable/14 - Makefile.vm: Set CLEANDIRS correctly for vm-image List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d576c1dd9744d65906c257e226cd535e8aec574c Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=d576c1dd9744d65906c257e226cd535e8aec574c commit d576c1dd9744d65906c257e226cd535e8aec574c Author: Colin Percival AuthorDate: 2024-04-14 22:27:19 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 Makefile.vm: Set CLEANDIRS correctly for vm-image With multiple filesystems and disk image formats, we now use different staging directories; we need to include them all in CLEANDIRS. Fixes: 97bd53ef4d20b "Makefile.vm: Fix duplicate rc.conf files" MFC after: 3 days (cherry picked from commit 7ffa1f14e3c19f0061ec9f38bb74c564a49ffc17) --- release/Makefile.vm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 136e58e1aded..0eb549ec7bc2 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -145,9 +145,10 @@ cw-${_CW:tl}: cw-${_CW:tl}-${${_CW:tu}_FORMAT:[1]} .endif .if defined(WITH_VMIMAGES) && !empty(WITH_VMIMAGES) -CLEANDIRS+= ${VMTARGETS} +CLEANFILES+= vm-image . for FORMAT in ${VMFORMATS} . for FS in ${VMFSLIST} +CLEANDIRS+= vm-image-${FORMAT}-${FS} CLEANFILES+= ${FORMAT}.${FS}.img CLEANFILES+= ${VMBASE}.${FS}.${FORMAT} . endfor From nobody Wed Apr 17 05:44:05 2024 X-Original-To: dev-commits-src-branches@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 4VK8wj2GYXz5HvJL; Wed, 17 Apr 2024 05:44:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK8wj1NTtz4lmZ; Wed, 17 Apr 2024 05:44:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332645; 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=UQq0qFHWHk3XA7cpQzH5t2nMk4Q9Dm6wNs1ylpox7bc=; b=YzOia7g6XNqpAXrfuLeNHxH8D7s5riufszF5Ng7yI2kQGuzw1aR+ArVOk2StjUwdeBzie3 KL/iEYjtmJIWU/cRjxhDxyjmvA+eu76Nu35T9FbzOXrVBqDgkUnM4mgbZx8phRHO79T0c2 JuVh/7IuHc39jrFAZk7IT8Y0LCRMsm36yBJGyaEWYwnJPfv2CMSdh+aFnV8F8BNSxwjBaO 3pqCzhgebdH9wGey7wQ6lzwOvPk5+qGertYyeFkucMWahpVtkETe88fChgWQueJgvnb9zN yPrCo3qfqbW/YSCS2IiU1JTFtxVOiyuCOr1xSyPU7ACy5Y85BsPRLnh2g6B+QA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332645; a=rsa-sha256; cv=none; b=CSR3H7/Zzj9jI0Vxngq5c3HSqDSwkiJkRVZB6yphGae9BYZNP1FwJWyFkQ3dkhZBduVozc YkbHaj+4//SH1rm5TCI6+ftDcBTLxP/g0eUrauYfCK8cLPO1pa6nZn49+TrUKJJS5LtJzs HGBoK7Rg+3MohmRqEwRV+zZoQ+BfI9Hm9MTBqBqgy1kJlPZmup1MWqv2w7qfkC30TsLqlb KafxGiVvdMZSWGhEtkBcXcIhrDmRs6pLWBe3QIeW1g93pZUWyoyuDGO19NeGhFjCpZ6vVq vpi3Js4UsLGGw4vlnJqrbaXMDcEhcW5mygcBuX/Dlb9r02CPjuhnLoHW/DTenQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332645; 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=UQq0qFHWHk3XA7cpQzH5t2nMk4Q9Dm6wNs1ylpox7bc=; b=wQPsv5n0xzUfX8b6gvk7LUxklADaLJeYvGXZzcY79eS+JegmIjIhmeQ5pCPeapd5vxZzYT ZQind3AhUhO7KzC75ws47A+QfjVZn1al4LgZ/LXlalfl76qocWseL2jsuqkuglJTfq6VwB 4qQoC+UVi8+4G0cbAm9UGnUVpMK3yb0YOKY6eO279cW0cgYY9UGA3rXyo3MPxB57KTfLyJ 9Le95sD+7m6Q1A2JW/xgYV9ZPnT834yfMEMznIOfksngJrpCSJfk8335Hrvsbc8sQLRRrq VEF9vIwN7m38jSvoSmJXh5h2a1BViGtDazh+LNbv60PKj6XqgaqKnHUhr9imiQ== 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 4VK8wj10tJzDx2; Wed, 17 Apr 2024 05:44:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5i51D007188; Wed, 17 Apr 2024 05:44:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5i5KD007185; Wed, 17 Apr 2024 05:44:05 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:44:05 GMT Message-Id: <202404170544.43H5i5KD007185@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: f1c7e9bc7233 - stable/14 - release: Build dvd image before staging pkgs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f1c7e9bc72336602e4a147757488794f139f8510 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=f1c7e9bc72336602e4a147757488794f139f8510 commit f1c7e9bc72336602e4a147757488794f139f8510 Author: Colin Percival AuthorDate: 2024-04-14 22:31:26 +0000 Commit: Colin Percival CommitDate: 2024-04-17 05:43:27 +0000 release: Build dvd image before staging pkgs This missing dependency is only visible with -jN (which was otherwise broken until recently) and only when building DVD images (which aren't included in weekly snapshots and thereby slipped past testing). MFC after: 3 days (cherry picked from commit 567cbd8ff1c4edc1f2015ec4f93608aaf5a3c546) --- release/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/Makefile b/release/Makefile index 7b658bb90b29..ba9499ac5a3f 100644 --- a/release/Makefile +++ b/release/Makefile @@ -300,7 +300,7 @@ packagesystem: ${DISTRIBUTIONS} sh ${.CURDIR}/scripts/make-manifest.sh *.txz > MANIFEST touch ${.TARGET} -pkg-stage: +pkg-stage: dvd # TODO: Support for -DNO_ROOT .if !defined(NOPKG) || empty(NOPKG) env PORTSDIR=${PORTSDIR} REPOS_DIR=${.CURDIR}/pkg_repos/ \ From nobody Wed Apr 17 05:48:49 2024 X-Original-To: dev-commits-src-branches@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 4VK9294W7Qz5HvPV; Wed, 17 Apr 2024 05:48:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK9293p0vz4pdv; Wed, 17 Apr 2024 05:48:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332929; 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=IzB6Rwi9BWXHFnjn6kVxl2CR9fsCnCF/10ARKEUB3S0=; b=AJsUQfIAdq8Jz6Z4X4TOxLKbqCYr9aZETuxlrkeerwkKCU3E8vt1ljhoDsDFSWU2XOJ/95 XTRHy7lelRcv8opS8zcOvJ/Mc3SwFNNMvz/IuuZaoevQ1mqjW1ejo1OAZQv6hudNE38yPM W6dmyFymEo047XgbzcoDjJ01+Uog65s7iGqKsEww+WrRgG505YKRkH4kZBYZxa8vhVMiBF AJIqd8Ov8MizzqdYLcUQK4SysISUO7l9aQtyZ8nTrXCOboRMxDj0g4aufsZsJ45lb2wI7y 0hLORwNudCXWR8Vwq6mZZuRTBfzkLgF/ryEzOxKDbvEAPypOcu/9pPtorfDEKQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713332929; a=rsa-sha256; cv=none; b=lr3j6639Y+M2QuQdFQ9FDYoB5ttHFqZNSZv8qzraNC3aQSHx9RfwYxqs5qcZdLLR2b6ycc 4422sKqDoG44nX4LSDYTN4GNESDQsZVaX8UlNaxX9WkW0TZfZI5NkK6qHwv3ilE4dpBALV LTuy649dCPmF5ap3UlgTLUzHN25XpEA4rSRhy2wZsiyIzuJ5f/2ztvKpdKNaOM3ut9cahl Qt91VH7d+R/Ln+Kk8f3pjrsOku382wzqI1SSnUyxftvLCJWDUN+mvJgW+7W+tPxXP0POxp /MUzjG777te7aN3JxD6IVLXH8kyn2aDWwb/mL4EuRZTaq/y/GtZ/5qNeaCpnAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713332929; 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=IzB6Rwi9BWXHFnjn6kVxl2CR9fsCnCF/10ARKEUB3S0=; b=KUtIoqyEiPuG57Vfso363QjoD/K5r8iV2xsPedj9DrBFknaX2pULcBYPkD+fXrgl6W1va0 mlHcBPnouxMHxDjLXSJtyS5EsRESrfFJxBK1fFYC8s3WtXykyrue+KXeuXVJZAv4pyo2oF p3jbnm2hlJW70TvVjL6g21HP16JJCsj8AVDEDyhIEaMT12m3bVaxlvPTr6lU/xX1SouqS5 gbrLHqRxHMOvVbTtFhciL/ZcSRJPCZyOrGoTmJylnmpz+RlYPdkhgprYEj44U8yOwqtGha DEl3AcUUB0lY4vCWTsKKAsf1I24sx/Gqffgpnj2lGNhQlejMAjvGxm3biRxjGw== 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 4VK9293QJ1zF9K; Wed, 17 Apr 2024 05:48:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5mnvq008033; Wed, 17 Apr 2024 05:48:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5mnf3008030; Wed, 17 Apr 2024 05:48:49 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:48:49 GMT Message-Id: <202404170548.43H5mnf3008030@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: a871d0f13c56 - stable/14 - daemon: fix -R to enable supervision mode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a871d0f13c56f6ea2ec86ed8175634b562de514a Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=a871d0f13c56f6ea2ec86ed8175634b562de514a commit a871d0f13c56f6ea2ec86ed8175634b562de514a Author: Mathieu AuthorDate: 2024-04-14 03:10:06 +0000 Commit: Kyle Evans CommitDate: 2024-04-17 05:48:26 +0000 daemon: fix -R to enable supervision mode If we're doing restarts, then we must supervise -- the 'R' case simply got missed. PR: 278342 Fixes: f907027b49d ("daemon: set supervise_enabled during [..]") (cherry picked from commit bbc6e6c5ec8c7938b98a36899fa083aa7ce4724e) --- usr.sbin/daemon/daemon.c | 1 + 1 file changed, 1 insertion(+) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index da8e4895e19b..52fbfca1dcd2 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -243,6 +243,7 @@ main(int argc, char *argv[]) if (p == optarg || state.restart_delay < 1) { errx(6, "invalid restart delay"); } + state.mode = MODE_SUPERVISE; break; case 's': state.syslog_priority = get_log_mapping(optarg, From nobody Wed Apr 17 05:50:15 2024 X-Original-To: dev-commits-src-branches@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 4VK93r0PDlz5HvQF; Wed, 17 Apr 2024 05:50:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VK93q6zb3z4q3j; Wed, 17 Apr 2024 05:50:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713333016; 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=GdOuDBCqDB/6J/CAGa+EX/88OudbNZTiS6IQh0feCAU=; b=VrgjfaHxWTEZeKclWtzB2cjqYwLJN0iBtAYKUTkp61Ieh88TjxqMj/EUWrQONXIEt4DRok YQfvln2gqf+bh5k26ns3C5zdQATxYemQV5yZ7yx06H3Ujifzgt5BZhO4NNt/dACevL9ZxC wddCRq2IucpyaAi8fYK6bkFNzimSlFAukBAfR+FmtUZqyVBO5M9qLSp2rXbwNv1SzFjzYN JznIQiZZNfrPpOsavg3U1Z/uiNNmStExnjMKbEoSe9dAsQ0URegbBypuvtyIV2w7MYhrSP ymk76fuAFJ/SCSlWw1ggtDAC3QB4ObFgfwoxNV1Y+dzbd1bDX+Gof+i0yBhAtA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713333016; a=rsa-sha256; cv=none; b=vjb3h9uQ/fnxMxMDzyiSzkW24Z+fXOyqfI0+CMo6yzhG1hcY8916tzD9vt/lZhEiMDU9z8 XSkybC90oivpSqJVsHhMDfuJJGtM/urty13X/Hn3ZyWSHGCfr0pV8wOrZNYy5OzPl1mX4c T9yUtIwVmUSmasbLCJup/IfR+WimodsyztLM9Yi4LpVttRkEw3jCGNiewxCgV0i+zrtuhz K2XGQfzwv9leSy72Rf/jMirgKD0Qag3R0uEXdwe0OfeT4Wb0ewMCr+HDPc5h2MXopiUwis 12yPybaH0f9Iohf23sVUP7WZe/sJBCnB3a1WKlDWtCsoHfKPD99/fBy06eWNAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713333016; 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=GdOuDBCqDB/6J/CAGa+EX/88OudbNZTiS6IQh0feCAU=; b=fW+7xzctMJgDbxOQI2iVk14Lgrg5nOm5pxhixS+1yvD4LI3j63cxgzofAGJ/yDIdh+65uB RnojHcORovn44vkEL1KSo/rAMdVYcq3xGhAnviEslMqzogC9RZBzud6ryTRgnS9ZziDRpE y3yBTRAM9Qctok4qXSe2AEztCHkXDBIEweSW3jlQJP9GVQZRMnIZbZbY3d3Wfiyhe2RoWM VKEubWyGqUZ1RCTRPGC9Yj5s/vcoyTppw5xL1XzxIGHe3rQwrbkbSJ9WCkpiy65AgCn8NM owR2WsuilamGg3Tmvw8JpzHEcRJieoUeG0ls8ZZex+ve6WGuYwqFOtlmzU8Urw== 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 4VK93q6ZjPzDx5; Wed, 17 Apr 2024 05:50:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H5oFU0015706; Wed, 17 Apr 2024 05:50:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H5oFR3015698; Wed, 17 Apr 2024 05:50:15 GMT (envelope-from git) Date: Wed, 17 Apr 2024 05:50:15 GMT Message-Id: <202404170550.43H5oFR3015698@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 1e2be096d425 - stable/13 - daemon: fix -R to enable supervision mode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1e2be096d4252308db35b0424bd408c2b8aa5990 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=1e2be096d4252308db35b0424bd408c2b8aa5990 commit 1e2be096d4252308db35b0424bd408c2b8aa5990 Author: Mathieu AuthorDate: 2024-04-14 03:10:06 +0000 Commit: Kyle Evans CommitDate: 2024-04-17 05:50:03 +0000 daemon: fix -R to enable supervision mode If we're doing restarts, then we must supervise -- the 'R' case simply got missed. PR: 278342 Fixes: f907027b49d ("daemon: set supervise_enabled during [..]") (cherry picked from commit bbc6e6c5ec8c7938b98a36899fa083aa7ce4724e) --- usr.sbin/daemon/daemon.c | 1 + 1 file changed, 1 insertion(+) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index da8e4895e19b..52fbfca1dcd2 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -243,6 +243,7 @@ main(int argc, char *argv[]) if (p == optarg || state.restart_delay < 1) { errx(6, "invalid restart delay"); } + state.mode = MODE_SUPERVISE; break; case 's': state.syslog_priority = get_log_mapping(optarg, From nobody Wed Apr 17 06:50:25 2024 X-Original-To: dev-commits-src-branches@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 4VKBPG0hBXz5J0xN; Wed, 17 Apr 2024 06:50:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKBPF62Swz3wdS; Wed, 17 Apr 2024 06:50:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713336625; 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=oh0Fd2acpM4vWa//ybupzzIYqK+yQipNFsDJIFrqSWM=; b=Y6xZ8QN3ZrwQyIQMN+LbidmJzsUnWnxC1bHTbEvSCwMur784r9FipGkcfbvdSXlGkK63BG iorkMD56uH/lhnBqwxMr9CSL1TLCtm7N5IPI4hN3DQSNzfrNEclDGHt9a2KAmp/8kpj8tU RxUCPWGLchgzwRKaQMVy9cNHOsM7Kn/Azf7yY4q8LXAKspmdVbUtyRPE3Euf2M6Y70H5fr M2mTe9S0b0J3N59x3nloxLJZiupuFFBA8Ah68Mmp7H2rhZx5s2RTR5HjHo4aGWO9ioU36Z 7YEoO4bsvba9xsBxMAVhzXi3pjb49/5hfiVLKk7lZ6tJOaN0S58uQob+5pmkjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713336625; a=rsa-sha256; cv=none; b=eugIYd2RsqD1FsHpDWXu45SZio7OwPkfQs1fY0qin3lnoTqEV3dE2TOc4ei5TjBWT4MbTh za2yPHAf5rdsLcRpVGLcSzWEcUoDrporULMv9g7pQLjtDzlbcP3HUpKCRIOhMc5PmTCQ/t qAeLoRpj/4rnXjSTkZ/p6t7xZ0ZoNUd+ODBmfvMUQiisE1TOmtR96cKR6hzUhb8omcYs2e uqo1x4lQNQnvKQkriFJigb4vBye65ZkniEwDGJ3tQDvZyWqdSt+68/tQDx7iKDdYd4yrXW t2fAUU1OhGWpHXV5bUdeFYv0OWb1cImK312VpN1zEKe+zP0thzAff1txEU8/Tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713336625; 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=oh0Fd2acpM4vWa//ybupzzIYqK+yQipNFsDJIFrqSWM=; b=fVMk5GHsGxg6sLfVz2CiKyQYnRx3CAIdQ14NCnKumkVK7EPmfqMPv5+ZuylwFFqAi1KkYI lsFlOTgzV08+KKN0M5E3UrHG7MGWmlGX57DNmxaszr27DJC8W3eqjmbsxdlTUpd9IOreOH 7/W5qaAacLpQ9WZQBZ2Q31DS/8PRyWsIRMCekG1DxriVEAcVKvRj7fgUrL5hyy3E+Fh+iK Uei8KOTTkkjdHyGV3GmB9rE9FC/6zjBgloikJ2tRrnLzuqrF+5ryxspkIy711RfGOmJ/05 wpua816HbIjDMeaO+MF3LXJbq7Sh9Xw848yuHv8lwk/YWddCk/Buf08bGYvx/w== 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 4VKBPF5dPFzGhq; Wed, 17 Apr 2024 06:50:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H6oPOr018259; Wed, 17 Apr 2024 06:50:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H6oPbE018256; Wed, 17 Apr 2024 06:50:25 GMT (envelope-from git) Date: Wed, 17 Apr 2024 06:50:25 GMT Message-Id: <202404170650.43H6oPbE018256@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Osipov Subject: git: 69dbc448cf8b - stable/14 - freebsd-update: Don't provide copiable commands in output List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: michaelo X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 69dbc448cf8b3677e783353bcc0c2108b8a74b9d Auto-Submitted: auto-generated The branch stable/14 has been updated by michaelo: URL: https://cgit.FreeBSD.org/src/commit/?id=69dbc448cf8b3677e783353bcc0c2108b8a74b9d commit 69dbc448cf8b3677e783353bcc0c2108b8a74b9d Author: Michael Osipov AuthorDate: 2024-01-30 16:24:45 +0000 Commit: Michael Osipov CommitDate: 2024-04-17 06:50:07 +0000 freebsd-update: Don't provide copiable commands in output Previously, freebsd-update provided ready-to-go commands for copying and pasting into the terminal. This causes problems as soon as options are used and not supplied again by the user, e.g., '-b' or '-d'. Stop making them copiable and force the user to construct a valid command line by himself to avoid failures. PR: 276102 Approved by: jrm (mentor), emaste MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D43700 --- usr.sbin/freebsd-update/freebsd-update.sh | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index b6a8911e64b7..4a6a8d78330b 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -776,7 +776,7 @@ fetch_check_params () { if ! [ -z "${TARGETRELEASE}" ]; then echo -n "`basename $0`: " - echo -n "-r option is meaningless with 'fetch' command. " + echo -n "'-r' option is meaningless with 'fetch' command. " echo "(Did you mean 'upgrade' instead?)" exit 1 fi @@ -784,8 +784,8 @@ fetch_check_params () { # Check that we have updates ready to install if [ -f ${BDHASH}-install/kerneldone -a $FORCEFETCH -eq 0 ]; then echo "You have a partially completed upgrade pending" - echo "Run '$0 install' first." - echo "Run '$0 fetch -F' to proceed anyway." + echo "Run '`basename $0` [options] install' first." + echo "Run '`basename $0` [options] fetch -F' to proceed anyway." exit 1 fi } @@ -798,7 +798,7 @@ upgrade_check_params () { NKERNCONF=${KERNCONF} # We need TARGETRELEASE set - _TARGETRELEASE_z="Release target must be specified via -r option." + _TARGETRELEASE_z="Release target must be specified via '-r' option." if [ -z "${TARGETRELEASE}" ]; then echo -n "`basename $0`: " echo "${_TARGETRELEASE_z}" @@ -863,7 +863,7 @@ install_check_params () { if ! [ -L ${BDHASH}-install ]; then echo "No updates are available to install." if [ $ISFETCHED -eq 0 ]; then - echo "Run '$0 fetch' first." + echo "Run '`basename $0` [options] fetch' first." exit 2 fi exit 0 @@ -871,7 +871,7 @@ install_check_params () { if ! [ -f ${BDHASH}-install/INDEX-OLD ] || ! [ -f ${BDHASH}-install/INDEX-NEW ]; then echo "Update manifest is corrupt -- this should never happen." - echo "Re-run '$0 fetch'." + echo "Re-run '`basename $0` [options] fetch'." exit 1 fi @@ -973,7 +973,7 @@ IDS_check_params () { _SERVERNAME_z=\ "SERVERNAME must be given via command line or configuration file." - _KEYPRINT_z="Key must be given via -k option or configuration file." + _KEYPRINT_z="Key must be given via '-k' option or configuration file." _KEYPRINT_bad="Invalid key fingerprint: " _WORKDIR_bad="Directory does not exist or is not writable: " @@ -2326,7 +2326,7 @@ upgrade_guess_components () { WARNING: This system is running a "${KCOMP}" kernel, which is not a kernel configuration distributed as part of FreeBSD ${RELNUM}. This kernel will not be updated: you MUST update the kernel manually -before running "$0 install". +before running '`basename $0` [options] install'. EOF fi @@ -2770,7 +2770,7 @@ upgrade_run () { # Remind the user that they need to run "freebsd-update install" # to install the downloaded bits, in case they didn't RTFM. - echo "To install the downloaded upgrades, run \"$0 install\"." + echo "To install the downloaded upgrades, run '`basename $0` [options] install'." } # Make sure that all the file hashes mentioned in $@ have corresponding @@ -2788,7 +2788,7 @@ install_verify () { if ! [ -f files/${HASH}.gz ]; then echo -n "Update files missing -- " echo "this should never happen." - echo "Re-run '$0 fetch'." + echo "Re-run '`basename $0` [options] fetch'." return 1 fi done < filelist @@ -3024,7 +3024,7 @@ install_files () { cat <<-EOF Kernel updates have been installed. Please reboot and run -"$0 install" again to finish installing updates. +'`basename $0` [options] install' again to finish installing updates. EOF exit 0 fi @@ -3111,8 +3111,8 @@ Kernel updates have been installed. Please reboot and run Completing this upgrade requires removing old shared object files. Please rebuild all installed 3rd party software (e.g., programs -installed from the ports tree) and then run "$0 install" -again to finish installing updates. +installed from the ports tree) and then run +'`basename $0` [options] install' again to finish installing updates. EOF rm newfiles exit 0 @@ -3492,7 +3492,7 @@ cmd_updatesready () { fi echo "There are updates available to install." - echo "Run '$0 install' to proceed." + echo "Run '`basename $0` [options] install' to proceed." } # Install downloaded updates. From nobody Wed Apr 17 06:51:50 2024 X-Original-To: dev-commits-src-branches@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 4VKBQt1j3fz5J0rZ; Wed, 17 Apr 2024 06:51:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKBQt1F58z3x7v; Wed, 17 Apr 2024 06:51:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713336710; 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=9XHeO0JQJEv89BDmGxiOgKeyjGU71CJkV4dd4gzn+P4=; b=ecJ+y1fh9aIrFRJ6a9eX1NfIbddnf/1os3eJk+Fo8I1RB0WsOPA0bZwtThffRzEGznf/yX xTflb8fhwkcfQLu8edLloyMbf/DpJpIhXytfE7vvlg6kWZPi6yM2dArMGsdPRUbhDC0hLM 1G+zUI5+9MoRg5Xbv6lhAeOjKwbNGMkFZoY8BDtTtRQzVALOGcd5wGHGEVR7I92rjbqvSS qOmVtiMr8KfJmzCJ7kma1ckQ+ncxz/LWPLosV986yPw+zEvZeKuirNKshl33TfQtuNLF/L MmAdyOAG73P/DL6YNEjTyIL/H0Yjjj09nkSEFuWJ1PkUNb6POU/gWZefyfscUA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713336710; a=rsa-sha256; cv=none; b=WSzE2HySEN4rv7MTrwBpuCvcsp2MUqFYATr/HtLnXkmhmLxuob6hrInqx6ISVIVFDFxOaK Nkz3xAIVtZLvS/t+YzXOYQh+9QUtZzYsuRk4BO9aKvSNt6rqA6H5pWuUlyvagudsZWK6jA +zjz7mnvpe1v/tMNyTSayVnxioHTuRQmB57Ph9EJlltCmNBPEzll3meZB8N2g2iXIrbJww 1GgUYGxFAnkDwhgFqg53qgJbfhIOzQuVHTWu8iv1hjGH7xhS1d+dwEhVLVyLvFmrzgVPcY 99rxS/CtdCovw+4854m8MxUu3nlpRNpQVBMZHHf+DwamzEdUmSBQj1McEDYH5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713336710; 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=9XHeO0JQJEv89BDmGxiOgKeyjGU71CJkV4dd4gzn+P4=; b=nZpmA6nejEsisUmHxwRZUn7INME5J03EobfAtt360S+b65Xd7KORovodckmlvCF7yHeiFJ CouKIM7x4Ne+CAnppUaAFrCqOHqj4QdNRvyO0rn5pWuWgilEwhF9J+l5iK+p8qQXnwSiQ0 Xz2MPsTcJrMzKvLwIu8PWm1i2+yMyxlcunTBuLRtmlWPGAxIYggrPWnIhCm20+OyU7EAU6 ETj32S3UsHE8lXtAetXsdQZYIgmMViwGwWjs4PR2utDEi9ird1g2U4Ww607ZiISQ9tOPY7 DGdTIcyhHnm1djkbjm6pXjXAIks/B5UHtx6JY9DOiXVWqPd3nZOxgeOVUZNDiw== 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 4VKBQt0r5QzGdD; Wed, 17 Apr 2024 06:51:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H6po1k021270; Wed, 17 Apr 2024 06:51:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H6po7N021267; Wed, 17 Apr 2024 06:51:50 GMT (envelope-from git) Date: Wed, 17 Apr 2024 06:51:50 GMT Message-Id: <202404170651.43H6po7N021267@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Osipov Subject: git: d596e573119e - stable/13 - freebsd-update: Don't provide copiable commands in output List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: michaelo X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d596e573119e245b2d2b53afeb523700510e5bf2 Auto-Submitted: auto-generated The branch stable/13 has been updated by michaelo: URL: https://cgit.FreeBSD.org/src/commit/?id=d596e573119e245b2d2b53afeb523700510e5bf2 commit d596e573119e245b2d2b53afeb523700510e5bf2 Author: Michael Osipov AuthorDate: 2024-01-30 16:24:45 +0000 Commit: Michael Osipov CommitDate: 2024-04-17 06:51:38 +0000 freebsd-update: Don't provide copiable commands in output Previously, freebsd-update provided ready-to-go commands for copying and pasting into the terminal. This causes problems as soon as options are used and not supplied again by the user, e.g., '-b' or '-d'. Stop making them copiable and force the user to construct a valid command line by himself to avoid failures. PR: 276102 Approved by: jrm (mentor), emaste MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D43700 --- usr.sbin/freebsd-update/freebsd-update.sh | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index b6a8911e64b7..4a6a8d78330b 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -776,7 +776,7 @@ fetch_check_params () { if ! [ -z "${TARGETRELEASE}" ]; then echo -n "`basename $0`: " - echo -n "-r option is meaningless with 'fetch' command. " + echo -n "'-r' option is meaningless with 'fetch' command. " echo "(Did you mean 'upgrade' instead?)" exit 1 fi @@ -784,8 +784,8 @@ fetch_check_params () { # Check that we have updates ready to install if [ -f ${BDHASH}-install/kerneldone -a $FORCEFETCH -eq 0 ]; then echo "You have a partially completed upgrade pending" - echo "Run '$0 install' first." - echo "Run '$0 fetch -F' to proceed anyway." + echo "Run '`basename $0` [options] install' first." + echo "Run '`basename $0` [options] fetch -F' to proceed anyway." exit 1 fi } @@ -798,7 +798,7 @@ upgrade_check_params () { NKERNCONF=${KERNCONF} # We need TARGETRELEASE set - _TARGETRELEASE_z="Release target must be specified via -r option." + _TARGETRELEASE_z="Release target must be specified via '-r' option." if [ -z "${TARGETRELEASE}" ]; then echo -n "`basename $0`: " echo "${_TARGETRELEASE_z}" @@ -863,7 +863,7 @@ install_check_params () { if ! [ -L ${BDHASH}-install ]; then echo "No updates are available to install." if [ $ISFETCHED -eq 0 ]; then - echo "Run '$0 fetch' first." + echo "Run '`basename $0` [options] fetch' first." exit 2 fi exit 0 @@ -871,7 +871,7 @@ install_check_params () { if ! [ -f ${BDHASH}-install/INDEX-OLD ] || ! [ -f ${BDHASH}-install/INDEX-NEW ]; then echo "Update manifest is corrupt -- this should never happen." - echo "Re-run '$0 fetch'." + echo "Re-run '`basename $0` [options] fetch'." exit 1 fi @@ -973,7 +973,7 @@ IDS_check_params () { _SERVERNAME_z=\ "SERVERNAME must be given via command line or configuration file." - _KEYPRINT_z="Key must be given via -k option or configuration file." + _KEYPRINT_z="Key must be given via '-k' option or configuration file." _KEYPRINT_bad="Invalid key fingerprint: " _WORKDIR_bad="Directory does not exist or is not writable: " @@ -2326,7 +2326,7 @@ upgrade_guess_components () { WARNING: This system is running a "${KCOMP}" kernel, which is not a kernel configuration distributed as part of FreeBSD ${RELNUM}. This kernel will not be updated: you MUST update the kernel manually -before running "$0 install". +before running '`basename $0` [options] install'. EOF fi @@ -2770,7 +2770,7 @@ upgrade_run () { # Remind the user that they need to run "freebsd-update install" # to install the downloaded bits, in case they didn't RTFM. - echo "To install the downloaded upgrades, run \"$0 install\"." + echo "To install the downloaded upgrades, run '`basename $0` [options] install'." } # Make sure that all the file hashes mentioned in $@ have corresponding @@ -2788,7 +2788,7 @@ install_verify () { if ! [ -f files/${HASH}.gz ]; then echo -n "Update files missing -- " echo "this should never happen." - echo "Re-run '$0 fetch'." + echo "Re-run '`basename $0` [options] fetch'." return 1 fi done < filelist @@ -3024,7 +3024,7 @@ install_files () { cat <<-EOF Kernel updates have been installed. Please reboot and run -"$0 install" again to finish installing updates. +'`basename $0` [options] install' again to finish installing updates. EOF exit 0 fi @@ -3111,8 +3111,8 @@ Kernel updates have been installed. Please reboot and run Completing this upgrade requires removing old shared object files. Please rebuild all installed 3rd party software (e.g., programs -installed from the ports tree) and then run "$0 install" -again to finish installing updates. +installed from the ports tree) and then run +'`basename $0` [options] install' again to finish installing updates. EOF rm newfiles exit 0 @@ -3492,7 +3492,7 @@ cmd_updatesready () { fi echo "There are updates available to install." - echo "Run '$0 install' to proceed." + echo "Run '`basename $0` [options] install' to proceed." } # Install downloaded updates. From nobody Wed Apr 17 08:13:38 2024 X-Original-To: dev-commits-src-branches@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 4VKDFG60h5z5J6kV; Wed, 17 Apr 2024 08:13:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFG5Pxpz49Ph; Wed, 17 Apr 2024 08:13:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341618; 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=79DNWynvSbUkSLOXJmTgCbWFl/vBzJb0PpogRAF/YX8=; b=RuXoYWS8fSofGbKFl+oA/0nWnm4THe+iA6cnPXKG4uL68EGneCPuGUwlNrmkXsnT3KKgjd hoBDHFyM5I7vbEMyLHAq+H3XMhx6wHi3ajh9SnwJ66Df6h7zx+o5hvMvD45fgbq3hNvfuI gz6FUvhCzqxkveydjwzHrtT00+Uj7PVkj37kxYME5tTTTYd1wTuA/nE5i4VmfULlZGt10M E18zKQyizhRsURNgbIcZ21V1oyRb7aOs8sBNStnE2UZ3ZGOfneWTooJ5KyXu2eXB+qHkrp zPcf2UTzEX/MWMwyH1oQ1iWvuxLUMhx6EG2BAf7sh/tSd8ce6B/DwD+gqMKqMQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341618; a=rsa-sha256; cv=none; b=WKNstft1rxhXxQRWDk9leXB5DTBw4YhCMJjN6EuxBH/D/6Alr1B9yh28+xb7LGC6zdmkFn OR5yeexhaEzACJEyDZQ52sjGXZfIyDgss2CZU8+ZbcJ+JJnvvMtBM2cHtCiURZndJfiFku lPO+yJ4WEMRHUU+4HZ3I5XaFLznM7kY9yWDscCc2sA6V/HW2MW4+zopMrN7zvbsnz72Euu Y9y/fk0jkDz0bne7fJvxH/iiUeaXQW6bzcWPBV8vCL2LOHirGTAEwCf3bTUOthEqd8keeM SR8d+RKuHzmnBnVE6ROa5wuomRlQmcoXFM4rtgNIK2CIc94XcB9s4xmuexOQ5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341618; 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=79DNWynvSbUkSLOXJmTgCbWFl/vBzJb0PpogRAF/YX8=; b=EuCxE0sGTaL4Rhfxv5BZrTuavWA6TZYKOlJnM+C22aCNiLyVFdQiUeI874iP0giogYEg55 GjgLF8U0d/dJmZUCHE6JY//sCAJvKKQYP8f+c6Cf8UKUCwZh73poqtjYRlUa1qYuwKJeOU kaSphCeODWx9yBmv61mV8ZzZLip4gdqtbP7ujtPvWt2SaucJN6ZoQfMT8WdR4gUosNgjSq oPBMj9gUyshdVG3QdbA1btSPStGS5EqCwFuhzFm2CLZ7Hj+LkS6Jlsw8DvHsLBbrEKF/bP OO41T+EEK2s4MIna+3DmGPT7g3uczAtde/kw8oNe/OkY9FBxJtVOP6cOHDKeLw== 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 4VKDFG51CpzJsQ; Wed, 17 Apr 2024 08:13:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8Dcr9062222; Wed, 17 Apr 2024 08:13:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Dcjm062219; Wed, 17 Apr 2024 08:13:38 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:38 GMT Message-Id: <202404170813.43H8Dcjm062219@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: a6caa7bc5423 - stable/13 - stop_all_proc(): skip traced or signal-stoped processes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a6caa7bc54235cdc1599038fe4164015c2931545 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=a6caa7bc54235cdc1599038fe4164015c2931545 commit a6caa7bc54235cdc1599038fe4164015c2931545 Author: Konstantin Belousov AuthorDate: 2024-04-04 19:24:32 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:17 +0000 stop_all_proc(): skip traced or signal-stoped processes (cherry picked from commit 235436d6311ea5ad00edcc1e553012f0736ea86d) --- sys/kern/kern_proc.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c index 61c389f0b345..23d2856a3d32 100644 --- a/sys/kern/kern_proc.c +++ b/sys/kern/kern_proc.c @@ -3385,7 +3385,8 @@ allproc_loop: LIST_REMOVE(cp, p_list); LIST_INSERT_AFTER(p, cp, p_list); PROC_LOCK(p); - if ((p->p_flag & (P_KPROC | P_SYSTEM | P_TOTAL_STOP)) != 0) { + if ((p->p_flag & (P_KPROC | P_SYSTEM | P_TOTAL_STOP | + P_STOPPED_SIG)) != 0) { PROC_UNLOCK(p); continue; } @@ -3406,6 +3407,16 @@ allproc_loop: PROC_UNLOCK(p); continue; } + if ((p->p_flag & P_TRACED) != 0) { + /* + * thread_single() below cannot stop traced p, + * so skip it. OTOH, we cannot require + * restart because debugger might be either + * already stopped or traced as well. + */ + PROC_UNLOCK(p); + continue; + } sx_xunlock(&allproc_lock); _PHOLD(p); r = thread_single(p, SINGLE_ALLPROC); From nobody Wed Apr 17 08:13:39 2024 X-Original-To: dev-commits-src-branches@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 4VKDFH70bXz5J6cd; Wed, 17 Apr 2024 08:13:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFH6MyHz49Pj; Wed, 17 Apr 2024 08:13:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341619; 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=vmqaatwhHv8fczQPtZXDbcxp1fs62PnvqHYKU7bzuEg=; b=sJrlVgxoj8NzpH3u7u/dpA0xReaM4Ogzdl5irjTB9Y8hXNJw4fCfrQ471GMmJg+EyAykyA mukcZx56jTZq0hEcwK3IyJ0rYlW74EFMRq5XYy4fQr75OeHpTJxOShpBeWMT+952+4O99S i0xz752oIzQh75OoLN5ZZlYG6vYMJfJwiKKvp46M/PceD4tWULwHQNAXzMlt7/FfOdB3Sq DsIehIYTtxjOsurosunb340iPQWjIzeZTnR4cSfR4AATDUN/emOVcPFpZfA5jrbhmxASv+ Q2fYewMocgiaJvrufIzUwfFxITVmEPto1nURz6yFOyz5spYLVDODZNhMhBqjTg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341619; a=rsa-sha256; cv=none; b=It1OQnW348gZIROLGSUpkmyMQq7uRzG280OrKhB76FTswKWn2UMb6qxyUksUuOxwmCCOwU pl6b9L0/y7rKYIBfQErf9M8LVMa5x8ZD10YaJgKZaceJn43cnm3D/m6a/aSlfcCHFxJkd1 42uzrm1G1aMg8cGGOFecT0ZfgxyUMinjdU6olSJs+GyzMgFtSp5uRCVo//JlvY9yb1iWWj Zw5yOrKKVkTAjKcGXEsGdYU+3rMnkRaiDEv9Zq9jiB2fUEElQkAR6Oous9l+D9sXT7PVIH pjxcJ5pBye39drcvErrKZvaNiXqKfOL+jsT4WVFuL3eoGW/UgkqRTnIIyqhQHw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341619; 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=vmqaatwhHv8fczQPtZXDbcxp1fs62PnvqHYKU7bzuEg=; b=Zn7pgZdkXInDGJJN8UWT1CcAOkxcCup6dt5Ir/JSjjtL3sEifLDt64b4GWyddhdyWin67w LRK2+PM5aIB9ifmMTOKHp3CEeUBMHOgSkySj9P9QMSBM3UxrzNiB0+zUE/rmtp3nMJzeH3 uDFipV+fWwHN4fplyKJNTKlfjiKE+KsaI6NsKZIRe+v6zJh5exzZvou5aWTlCMLRx7hS2K +5mxtp6vd7XtUS1p+8nVsP7Wbeu1mkWY/JTpezlApkIfarVBf+jCtYF+nlA1eDEYe5VHoX h9T7flfPlQFh/jf/yVdfYYBAPxHIbs0I53RiTtlgUcXWqvEWQgkr+i/t4AmyTw== 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 4VKDFH5zCgzJk1; Wed, 17 Apr 2024 08:13:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8Ddhs062276; Wed, 17 Apr 2024 08:13:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Dduj062273; Wed, 17 Apr 2024 08:13:39 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:39 GMT Message-Id: <202404170813.43H8Dduj062273@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: f77abc3526d6 - stable/13 - acpidump: silent the warning about unaligned uuid List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f77abc3526d674631afeb717d3eea3ef4f534246 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=f77abc3526d674631afeb717d3eea3ef4f534246 commit f77abc3526d674631afeb717d3eea3ef4f534246 Author: Konstantin Belousov AuthorDate: 2024-04-03 02:58:28 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:17 +0000 acpidump: silent the warning about unaligned uuid (cherry picked from commit de937ecb75ed4d61fc06dd380f9bf6be998502e9) --- usr.sbin/acpi/acpidump/acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index 61e86c09675e..d9650b9268ec 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -1597,7 +1597,7 @@ acpi_print_nfit(ACPI_NFIT_HEADER *nfit) printf("\tRangeIndex=%u\n", (u_int)sysaddr->RangeIndex); printf("\tProximityDomain=%u\n", (u_int)sysaddr->ProximityDomain); - uuid_to_string((uuid_t *)(sysaddr->RangeGuid), + uuid_to_string((uuid_t *)(uintptr_t)(sysaddr->RangeGuid), &uuidstr, &status); if (status != uuid_s_ok) errx(1, "uuid_to_string: status=%u", status); From nobody Wed Apr 17 08:13:40 2024 X-Original-To: dev-commits-src-branches@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 4VKDFK34kvz5J6r1; Wed, 17 Apr 2024 08:13:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFK0ZCCz49yf; Wed, 17 Apr 2024 08:13:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341621; 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=2nun6YWFFf01ZaUfyfVlbAB+lQVs+qxlkTFE2C5Ekbo=; b=hgu2kyUk8sLkjEUhdzBrLAVmkoxwgD/pjHZ3q77c19p9ZyGj6EvUTu8JcRBnB9lNmGD/2/ dBglobn1xx8W0/5ZtzrIypbu4GJLWKNto9xUCuBlmqYlRxxZgNlyMEQRIEuXblqvxDzs7L lh61U8pQadeVJhRmhmCaEVTIB6G9NyR1rVJQfN/NFqi8/zE7wbVdP46HId3ADbpBr6soya rMyqdAEgS3D7AEch4JGnM7reQaWdCs8OcTahEPMTgG8egCQP1iAVJch2TBXK8h33nvngoC r+aAyYKk7NsKP1Hxz1wOsdjFL9V9rn1I63lm32ksG4AbK/TxT26cbSSt8LKFkg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341621; a=rsa-sha256; cv=none; b=aVSiMlZlKlNepituwRtnj8aoToi2zBwPWxSNiHZ32oPBCmtBkbWvtofCNYIFe6CbDenZmG S8TIGSgRb6Ab39SNp13yF0xS81AVcRrsamUUjGOu/UCj5oYzo6rK217wulrTan0aUi7v+l ZeHQTkvMq9MhFpXY3wGHnH0KyW7Lt6FIVZwCVS3qZnf/Ld0g1LpY0DhFbsu9I+6PB0vqF3 ywTCq/e/Jrgl2NXmT9Nr+bID2JY7/uMM6AvgSKxcDWOL9EywgWh5Q8rQkDJNo5nRhR5Pmg zNZVpc1HZEoSAUYAt+omLu85lm2cIGiTvsI6aFy1GKzGJvM1Y/a0if5N6rTCLA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341621; 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=2nun6YWFFf01ZaUfyfVlbAB+lQVs+qxlkTFE2C5Ekbo=; b=g8qNPE6Y7mDgInKeoypvSmuPrXyZIvNVpA1ms0TLt3V3DazM/OyUulc/48IrlkOa3pwL1j yBfO/XQFEihSs8z5+NdE4eqWSGPHKM26YZ2zTc9xR/+Xq2ec4/eq/vqiAgyBViTz3deMt9 UmlgFryXHwWQZ4GQhbIVqU/YxTPgZsTiyg0smSHKUz2kXZagqMCX2vHBXpHXzMY5rxV5Cd T/MH+lrYjnuE50E9S5tuaKd+fUNwvopZ4F+khxEyckRp3unGs9Fn+v2NmFVZ0o77jQ11eA Y5gUanYCF/edhtDm3QbtwxPB6SC6gPs4Fh8xpM5lLx3Y10q066Sqeke8fnjbeQ== 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 4VKDFJ71CRzJsR; Wed, 17 Apr 2024 08:13:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8Dedq062322; Wed, 17 Apr 2024 08:13:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8De8P062319; Wed, 17 Apr 2024 08:13:40 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:40 GMT Message-Id: <202404170813.43H8De8P062319@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 930c76a733d0 - stable/13 - acpidump: the acpi_get_fadt_revision() argument is unused List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 930c76a733d098f3fcc515d1e3b44cc35b7c1129 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=930c76a733d098f3fcc515d1e3b44cc35b7c1129 commit 930c76a733d098f3fcc515d1e3b44cc35b7c1129 Author: Konstantin Belousov AuthorDate: 2024-04-04 15:42:36 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:17 +0000 acpidump: the acpi_get_fadt_revision() argument is unused (cherry picked from commit 4262ad56a074b973f18fee09bb03d52153bd35c2) --- usr.sbin/acpi/acpidump/acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index d9650b9268ec..5005c4bbe630 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -209,7 +209,7 @@ acpi_print_gas(ACPI_GENERIC_ADDRESS *gas) /* The FADT revision indicates whether we use the DSDT or X_DSDT addresses. */ static int -acpi_get_fadt_revision(ACPI_TABLE_FADT *fadt) +acpi_get_fadt_revision(ACPI_TABLE_FADT *fadt __unused) { int fadt_revision; From nobody Wed Apr 17 08:13:42 2024 X-Original-To: dev-commits-src-branches@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 4VKDFL2k0lz5J6tH; Wed, 17 Apr 2024 08:13:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFL1LPQz49tQ; Wed, 17 Apr 2024 08:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341622; 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=ZudwiySGbLWKyESo7yqCanLFVdj82SAWbXxNcTxEnhI=; b=GNlhDJ18NTX8oU3jEb362DLy58Dd4DheF4vXb5oyyY79Dh5r7ljFkpH4qF1slO1SF7/Plc BIlmz9Ueenyc4Y+raaeXw5/x8m/xtgoVVhHV+zCKYvzOLIMzWKhshBp4/vvczjqBN/iz1D ybYWjn3ymu0K46xmzodssBok2eOxzvaZa6AmTNNky0/25IsGXPb9YZA/WNLb/wcQRyECM9 Xx15wgfIb7yPhbYtMTcz573yNUnfXhw2OctMygltTq0tJDXxrTbq0RqyVUSutVi8iz36vd 0AU1uGoIM7Px7EXcGpV65R/KprtuU67OZEMN3OSdKdOhEyQD2WfdprTzYhcHpA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341622; a=rsa-sha256; cv=none; b=C6X47eONQEYkQLpzZLQ02I3ZfzIkFkG/S+zQDJPfhVIU8rZinIsg9jSu01VKCslB3In6tx 0MbOj1jnbBa9ZWB3Q//0O4UAuUOnpTFx6vIz8/ebfw3IcdceRPORNBnooSS6jVm8yGgwbM K4p8DhFPkrpvdus47wVV5V7jiEh5DTzHBUMwnxfZpxAHsUVFCnktfdPjdNUNlHehpOQd3m LTSKbL6Mie6oauiaSfwghKSRHIZHZlNPQFpqavElyU765NryMj4xdOcxax4AcNATkG6MRp Cd+bBhVY1xA0S8lgdFDexeK7GL1ZDVyw8BmDUm/nJilN0CwX9tfrFPRV1CqMBA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341622; 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=ZudwiySGbLWKyESo7yqCanLFVdj82SAWbXxNcTxEnhI=; b=liM8mrB4j+BAmPjIClvAtCON0t9MMU/PvBH0Z/dk7Gq77NKD1ydbr3BQLAe2tB9KhcLLHJ R48zh09ZHcNnuGqhJGS9HAzHJel49ROP1FXqkxqtP50jxzG7f9HX7RbIWGKcNBNlgfJgsi Y7zSWyy7yfHXOXCY6frQlCkY0+hIy0SxALk5oAm3lX9tVNHLjrun19f0sgWuWYNoLmsYC5 JwzS6/iGpmAk0pvKk6BRqMdivUpV4uJSi/fb+NWH1kG4w2eOMoQhcQnLZhNUZJZ3NdYqz6 AcsuUr4DKCmJXxNrKGIRdh0KX98X5Q1RdG7W/WHtZaiYz6aJlI8C4G8N0L3IOA== 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 4VKDFL0xRmzK9F; Wed, 17 Apr 2024 08:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DgfM062364; Wed, 17 Apr 2024 08:13:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8DgwH062361; Wed, 17 Apr 2024 08:13:42 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:42 GMT Message-Id: <202404170813.43H8DgwH062361@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 84944bf5e282 - stable/13 - acpidump: bump WARNS to 6 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 84944bf5e282d5164c9ebadde8b570aa62642d67 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=84944bf5e282d5164c9ebadde8b570aa62642d67 commit 84944bf5e282d5164c9ebadde8b570aa62642d67 Author: Konstantin Belousov AuthorDate: 2024-04-03 03:00:25 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:17 +0000 acpidump: bump WARNS to 6 (cherry picked from commit 29a6b72775eeed08a5ecb8f6c1b0c364196d73df) --- usr.sbin/acpi/acpidump/Makefile | 1 - usr.sbin/acpi/acpidump/acpidump.h | 3 +++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/usr.sbin/acpi/acpidump/Makefile b/usr.sbin/acpi/acpidump/Makefile index 9bd54a80f779..d0bb14284c1a 100644 --- a/usr.sbin/acpi/acpidump/Makefile +++ b/usr.sbin/acpi/acpidump/Makefile @@ -2,6 +2,5 @@ PROG= acpidump MAN= acpidump.8 SRCS= acpi.c acpi_user.c acpidump.c -WARNS?= 3 .include diff --git a/usr.sbin/acpi/acpidump/acpidump.h b/usr.sbin/acpi/acpidump/acpidump.h index 857d230bb871..80f86a748d76 100644 --- a/usr.sbin/acpi/acpidump/acpidump.h +++ b/usr.sbin/acpi/acpidump/acpidump.h @@ -30,9 +30,12 @@ #ifndef _ACPIDUMP_H_ #define _ACPIDUMP_H_ +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wunused-parameter" #include #include #include +#pragma GCC diagnostic pop /* GAS address space ID constants. */ #define ACPI_GAS_MEMORY 0 From nobody Wed Apr 17 08:13:43 2024 X-Original-To: dev-commits-src-branches@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 4VKDFM3rRXz5J6wj; Wed, 17 Apr 2024 08:13:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFM2KCsz49dT; Wed, 17 Apr 2024 08:13:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341623; 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=fcOmb+4jpd1fByhNt4dTtAFtjOvmpOHt9SSbYFZH7QE=; b=wpCAMKBnflFOIOFZjmwVcHtXzH7qZv3oplhNfiN0t71JVcb3fSYTGlYtam0XlCrbUaPEbK fcvPlGx2qnPA0hKnUZk1nEOgx0jjZqgPTAHcHuyjwaUzrWIXB/bUmorttmu1COhAGZ5Puo 5+FIwlWwpynJQj3+8jFAasdpjj13LSG7OsdGk8sSHX7F2JhEBhdY8mlpgwbPbTQTPqUYSt vH1coYxj/AjvLx34uTlhBAVLKapQlGxJTg/eEIgE0moE6WkoQ4W2SX1P0o8o7Vyafrad/A Cq2PxkYrQncinZHMLAvGJAi71gt1yGvlJpcewBbAv5eXPTcp0iRJY+a3YxjUOQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341623; a=rsa-sha256; cv=none; b=V7KpIQJKvy1QT0ya6rwjjtTAw1k+6WTCLr/5G+askHjmQQ/oEj+hVeNY3QpaPsQuzfygjB 9TBkZaSkQCbn50KLkTa+O5ovPCyPeQ5Faydw0MFRMEzHy2TXgUk0eAJ+194ZbepNUda6pU tCrD4RD31pTs7ojkvsGlWqLhun4Xt5ynnJPSpOYh7NN3KKJQD5/V68Ki7zAkxE4c4lYBga GUb/qma0gU0NysbAUk6DLmvkx2P0PbbG4ZvHIPVzHOFIMO7qANFjH7QG4pR+i9+yqiEDmJ phomgHZJwZK7wiVEFXxAeeIXIYybuz/fzs+tVIHE1FiSlLOoXMX3hLcwekXuiQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341623; 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=fcOmb+4jpd1fByhNt4dTtAFtjOvmpOHt9SSbYFZH7QE=; b=cg5ey/U6eWZ3lQKFfL/U7TtAqURa1yUKzaN7T7JuX4wJpnii5OZuHX5qpfz8g/aKU+H+3l CET6yG5bOQ4CbEJm3FyTvB3aecCoBp3f2PmGFwRlS++4qDeWOCbnmpAt7SASbNQ2FXWRPL fC9Trly5j6X8LKppjxWiK2UA33uueQeCnmkYFt7TAlIZBSsKoKHUMCjWTUQT1dZsdm6Abn X0yyrt07MnM8kdy2E60OL5w1Sffp5JOiZieeD6FgzdgI/5XPX+9C91h/1Rg4j9KyJ3wL4G Nb+sfmTl691tq/njecvlQyN5B36MukdA9b68Vj49PC4Vki8Dq28QUxV2XEkNyg== 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 4VKDFM1vx3zJhm; Wed, 17 Apr 2024 08:13:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DhKT062405; Wed, 17 Apr 2024 08:13:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Dh0g062402; Wed, 17 Apr 2024 08:13:43 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:43 GMT Message-Id: <202404170813.43H8Dh0g062402@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: f7fd7f8b88a1 - stable/13 - acpidump: add printfield() helper List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f7fd7f8b88a15cd70e8d5b471264875d006fcd39 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=f7fd7f8b88a15cd70e8d5b471264875d006fcd39 commit f7fd7f8b88a15cd70e8d5b471264875d006fcd39 Author: Konstantin Belousov AuthorDate: 2024-04-04 04:49:21 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 acpidump: add printfield() helper (cherry picked from commit 969a4b8be5a7d8edf55bd8945a5a071f57386b0e) --- usr.sbin/acpi/acpidump/acpi.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index 5005c4bbe630..ec7bd65b14c9 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -156,6 +156,18 @@ printflag(uint64_t var, uint64_t mask, const char *name) } } +static void +printfield(uint64_t var, int lbit, int hbit, const char *name) +{ + uint64_t mask; + int len; + + len = hbit - lbit + 1; + mask = ((1 << (len + 1)) - 1) << lbit; + printf("%c%s=%#jx", pf_sep, name, (uintmax_t)((var & mask) >> lbit)); + pf_sep = ','; +} + static void acpi_print_string(char *s, size_t length) { From nobody Wed Apr 17 08:13:44 2024 X-Original-To: dev-commits-src-branches@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 4VKDFN6BJVz5J6ch; Wed, 17 Apr 2024 08:13: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFN3MsSz4B79; Wed, 17 Apr 2024 08:13:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341624; 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=2aSGblNE1j0AvJYGXAB3fpUoCc5TMaJZ9P0ifWVeD94=; b=ZfUrCflJqT8ffhmzT6mhkg0sRLxxXU6Vo4pgneV3J9pC0rQETXlcnkQ7De7dlrlYQAKyPb KX4N0DLfcwyBSnZ+ZShPJZ8LAQ59oQEGmvMnwAxWDzoGOHCevIbAvdSa2uWXBAr3c2dP2J k4Elv2kuMx1riECiKDk1lv0PNuwqNpZ81KIqPj1A9vpS9wbY1FwpiFflXVoUXlQwWSKUn7 am5hOh+Jb8XzKHcsy+mRRtxJyslo0ag030baHU+CYj8w4xS8AJ9KNz/Xz6gVdiZqB9ptdY HYqse6UQmK78NqC6Qk9EOce5Dibiq7284dScLnWq4cWY/bfXwyaltvHfSmv0rg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341624; a=rsa-sha256; cv=none; b=pw6x8UXtCwtzX3yfimNdCFZMQ4bsVG6vW8V3yHpnX6YuDNq7uf8bI+Q81sdpKVp3YutOLo MRy7YbykbQcGnu+pEMXADMkEPo6ucDLm7XV0kBL/ku/KXYNi/WsRJuBcGV/v8pM6jsaOGp HQ1VaWLlH3mwo2oDm4IUNXzNhhE2+oZmVC8IVTfJwBKSTyt3PtIXTqWX0Aw6G6EpT9cf8H RVMq/hLKfkhbGSdJ5rkwvy2bgnfAmx2pEg9YYWCZXcFo7QQU581anCVQK0qbMuCfTWTNF2 IpfhxICbvd1/lk4sBym+ArMpRZqFNEDG5tB687nfjCEAhLs981QkE3GKxPg18A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341624; 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=2aSGblNE1j0AvJYGXAB3fpUoCc5TMaJZ9P0ifWVeD94=; b=GrLciBK0+9uqZf6/Pj0uQ6D0xZJV+ypdczA9bgLFKjZxBC2FAguklqBxyBJmEKN25OAGCS 997WXTbLvOca1rxC9IuC9+W1epp7gp3/G9LB2JXX7cTCATIIRii/RkJ1T1Ep8cHdsRfOYj a5o6oJurCua9cW+QCg2leVECxbo8y9NMzc0K9LenjFHWojC/v6vsVrMeUX5lQlaCcrScrF d/dXLnY6IPCenhZmZxmH9c6Wl1CzHnlB+l/yOMyb2VwsnOdSWvq3Xk8V7NK0JEWcbqYhWP UIVlYrsswBttdhpUVs37I65EryNmu9z/+drmp3eeNp3Lx5tavbQyLo8ygvZcsA== 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 4VKDFN30BFzJk2; Wed, 17 Apr 2024 08:13:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DiF7062466; Wed, 17 Apr 2024 08:13:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Di7j062463; Wed, 17 Apr 2024 08:13:44 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:44 GMT Message-Id: <202404170813.43H8Di7j062463@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: f95a254aa722 - stable/13 - acpidump: dump AMD IVRS table describing IOMMU layout List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f95a254aa7226160d41768112fd714a5c16bae61 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=f95a254aa7226160d41768112fd714a5c16bae61 commit f95a254aa7226160d41768112fd714a5c16bae61 Author: Konstantin Belousov AuthorDate: 2024-03-31 23:30:37 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 acpidump: dump AMD IVRS table describing IOMMU layout (cherry picked from commit 6d789b6126afe1c23b65eef2c5cf4c6bd258c26f) --- usr.sbin/acpi/acpidump/acpi.c | 372 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 372 insertions(+) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index ec7bd65b14c9..d4ab70c9ca86 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #include @@ -1496,6 +1497,375 @@ acpi_handle_dmar(ACPI_TABLE_HEADER *sdp) printf(END_COMMENT); } +static void +acpi_handle_ivrs_ivhd_header(ACPI_IVRS_HEADER *addr) +{ + printf("\n\tIVHD Type=%#x IOMMUId=%x\n\tFlags=", + addr->Type, addr->DeviceId); +#define PRINTFLAG(flag, name) printflag(addr->Flags, flag, #name) + PRINTFLAG(ACPI_IVHD_TT_ENABLE, HtTunEn); + PRINTFLAG(ACPI_IVHD_ISOC, PassPW); + PRINTFLAG(ACPI_IVHD_RES_PASS_PW, ResPassPW); + PRINTFLAG(ACPI_IVHD_ISOC, Isoc); + PRINTFLAG(ACPI_IVHD_TT_ENABLE, IotlbSup); + PRINTFLAG((1 << 5), Coherent); + PRINTFLAG((1 << 6), PreFSup); + PRINTFLAG((1 << 7), PPRSup); +#undef PRINTFLAG + PRINTFLAG_END(); +} + +static void +acpi_handle_ivrs_ivhd_dte(UINT8 dte) +{ + if (dte == 0) { + printf("\n"); + return; + } + printf(" DTE="); +#define PRINTFLAG(flag, name) printflag(dte, flag, #name) + PRINTFLAG(ACPI_IVHD_INIT_PASS, INITPass); + PRINTFLAG(ACPI_IVHD_EINT_PASS, EIntPass); + PRINTFLAG(ACPI_IVHD_NMI_PASS, NMIPass); + PRINTFLAG(ACPI_IVHD_SYSTEM_MGMT, SysMgtPass); + PRINTFLAG(ACPI_IVHD_LINT0_PASS, Lint0Pass); + PRINTFLAG(ACPI_IVHD_LINT1_PASS, Lint1Pass); +#undef PRINTFLAG + PRINTFLAG_END(); +} + +static void +acpi_handle_ivrs_ivhd_edte(UINT32 edte) +{ + if (edte == 0) + return; + printf("\t\t ExtDTE="); +#define PRINTFLAG(flag, name) printflag(edte, flag, #name) + PRINTFLAG(ACPI_IVHD_ATS_DISABLED, AtsDisabled); +#undef PRINTFLAG + PRINTFLAG_END(); +} + +static const char * +acpi_handle_ivrs_ivhd_variety(UINT8 v) +{ + switch (v) { + case ACPI_IVHD_IOAPIC: + return ("IOAPIC"); + case ACPI_IVHD_HPET: + return ("HPET"); + default: + return ("UNKNOWN"); + } +} + +static void +acpi_handle_ivrs_ivhd_devs(ACPI_IVRS_DE_HEADER *d, char *de) +{ + char *db; + ACPI_IVRS_DEVICE4 *d4; + ACPI_IVRS_DEVICE8A *d8a; + ACPI_IVRS_DEVICE8B *d8b; + ACPI_IVRS_DEVICE8C *d8c; + ACPI_IVRS_DEVICE_HID *dh; + size_t len; + UINT32 x32; + + for (; (char *)d < de; d = (ACPI_IVRS_DE_HEADER *)(db + len)) { + db = (char *)d; + if (d->Type == ACPI_IVRS_TYPE_PAD4) { + len = sizeof(*d4); + } else if (d->Type == ACPI_IVRS_TYPE_ALL) { + d4 = (ACPI_IVRS_DEVICE4 *)db; + len = sizeof(*d4); + printf("\t\tDev Type=%#x Id=ALL", d4->Header.Type); + acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_SELECT) { + d4 = (ACPI_IVRS_DEVICE4 *)db; + len = sizeof(*d4); + printf("\t\tDev Type=%#x Id=%#06x", d4->Header.Type, + d4->Header.Id); + acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_START) { + d4 = (ACPI_IVRS_DEVICE4 *)db; + len = 2 * sizeof(*d4); + printf("\t\tDev Type=%#x Id=%#06x-%#06x", + d4->Header.Type, + d4->Header.Id, (d4 + 1)->Header.Id); + acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_END) { + d4 = (ACPI_IVRS_DEVICE4 *)db; + len = 2 * sizeof(*d4); + printf("\t\tDev Type=%#x Id=%#06x BIOS BUG\n", + d4->Header.Type, d4->Header.Id); + } else if (d->Type == ACPI_IVRS_TYPE_PAD8) { + len = sizeof(*d8a); + } else if (d->Type == ACPI_IVRS_TYPE_ALIAS_SELECT) { + d8a = (ACPI_IVRS_DEVICE8A *)db; + len = sizeof(*d8a); + printf("\t\tDev Type=%#x Id=%#06x AliasId=%#06x", + d8a->Header.Type, d8a->Header.Id, d8a->UsedId); + acpi_handle_ivrs_ivhd_dte(d8a->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_ALIAS_START) { + d8a = (ACPI_IVRS_DEVICE8A *)db; + d4 = (ACPI_IVRS_DEVICE4 *)(db + sizeof(*d8a)); + len = sizeof(*d8a) + sizeof(*d4); + printf("\t\tDev Type=%#x Id=%#06x-%#06x AliasId=%#06x", + d8a->Header.Type, d8a->Header.Id, d4->Header.Id, + d8a->UsedId); + acpi_handle_ivrs_ivhd_dte(d8a->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_EXT_SELECT) { + d8b = (ACPI_IVRS_DEVICE8B *)db; + len = sizeof(*d8b); + printf("\t\tDev Type=%#x Id=%#06x", + d8a->Header.Type, d8a->Header.Id); + acpi_handle_ivrs_ivhd_dte(d8b->Header.DataSetting); + printf("\t\t"); + acpi_handle_ivrs_ivhd_edte(d8b->ExtendedData); + } else if (d->Type == ACPI_IVRS_TYPE_EXT_START) { + d8b = (ACPI_IVRS_DEVICE8B *)db; + len = sizeof(*d8b); + d4 = (ACPI_IVRS_DEVICE4 *)(db + sizeof(*d8a)); + len = sizeof(*d8a) + sizeof(*d4); + printf("\t\tDev Type=%#x Id=%#06x-%#06x", + d8a->Header.Type, d8a->Header.Id, d4->Header.Id); + acpi_handle_ivrs_ivhd_dte(d8b->Header.DataSetting); + acpi_handle_ivrs_ivhd_edte(d8b->ExtendedData); + } else if (d->Type == ACPI_IVRS_TYPE_SPECIAL) { + d8c = (ACPI_IVRS_DEVICE8C *)db; + len = sizeof(*d8c); + printf("\t\tDev Type=%#x Id=%#06x Handle=%#x " + "Variety=%d(%s)", + d8c->Header.Type, d8c->UsedId, d8c->Handle, + d8c->Variety, + acpi_handle_ivrs_ivhd_variety(d8c->Variety)); + acpi_handle_ivrs_ivhd_dte(d8c->Header.DataSetting); + } else if (d->Type == ACPI_IVRS_TYPE_HID) { + dh = (ACPI_IVRS_DEVICE_HID *)db; + len = sizeof(*dh) + dh->UidLength; + printf("\t\tDev Type=%#x Id=%#06x HID=", + dh->Header.Type, dh->Header.Id); + acpi_print_string((char *)&dh->AcpiHid, + sizeof(dh->AcpiHid)); + printf(" CID="); + acpi_print_string((char *)&dh->AcpiCid, + sizeof(dh->AcpiCid)); + printf(" UID="); + switch (dh->UidType) { + case ACPI_IVRS_UID_NOT_PRESENT: + default: + printf("none"); + break; + case ACPI_IVRS_UID_IS_INTEGER: + memcpy(&x32, dh + 1, sizeof(x32)); + printf("%#x", x32); + break; + case ACPI_IVRS_UID_IS_STRING: + acpi_print_string((char *)(dh + 1), + dh->UidLength); + break; + } + acpi_handle_ivrs_ivhd_dte(dh->Header.DataSetting); + } else { + printf("\t\tDev Type=%#x Unknown\n", d->Type); + if (d->Type <= 63) + len = sizeof(*d4); + else if (d->Type <= 127) + len = sizeof(*d8a); + else { + printf("Abort, cannot advance iterator.\n"); + return; + } + } + } +} + +static void +acpi_handle_ivrs_ivhd_10(ACPI_IVRS_HARDWARE1 *addr, bool efrsup) +{ + acpi_handle_ivrs_ivhd_header(&addr->Header); + printf("\tCapOffset=%#x Base=%#jx PCISeg=%#x Unit=%#x MSIlog=%d\n", + addr->CapabilityOffset, (uintmax_t)addr->BaseAddress, + addr->PciSegmentGroup, (addr->Info & ACPI_IVHD_UNIT_ID_MASK) >> 8, + addr->Info & ACPI_IVHD_MSI_NUMBER_MASK); + if (efrsup) { +#define PRINTFLAG(flag, name) printflag(addr->FeatureReporting, flag, #name) +#define PRINTFIELD(lbit, hbit, name) \ + printfield(addr->FeatureReporting, lbit, hbit, #name) + PRINTFIELD(30, 31, HATS); + PRINTFIELD(28, 29, GATS); + PRINTFIELD(23, 27, MsiNumPPR); + PRINTFIELD(17, 22, PNBanks); + PRINTFIELD(13, 16, PNCounters); + PRINTFIELD(8, 12, PASmax); + PRINTFLAG(1 << 7, HESup); + PRINTFLAG(1 << 6, GASup); + PRINTFLAG(1 << 5, UASup); + PRINTFIELD(3, 2, GLXSup); + PRINTFLAG(1 << 1, NXSup); + PRINTFLAG(1 << 0, XTSup); +#undef PRINTFLAG +#undef PRINTFIELD + PRINTFLAG_END(); + } + acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), + (char *)addr + addr->Header.Length); +} + +static void +acpi_handle_ivrs_ivhd_info_11(ACPI_IVRS_HARDWARE2 *addr) +{ + acpi_handle_ivrs_ivhd_header(&addr->Header); + printf("\tCapOffset=%#x Base=%#jx PCISeg=%#x Unit=%#x MSIlog=%d\n", + addr->CapabilityOffset, (uintmax_t)addr->BaseAddress, + addr->PciSegmentGroup, (addr->Info >> 8) & 0x1f, + addr->Info & 0x5); + printf("\tAttr="); +#define PRINTFIELD(lbit, hbit, name) \ + printfield(addr->Attributes, lbit, hbit, #name) + PRINTFIELD(23, 27, MsiNumPPR); + PRINTFIELD(17, 22, PNBanks); + PRINTFIELD(13, 16, PNCounters); +#undef PRINTFIELD + PRINTFLAG_END(); +} + +static void +acpi_handle_ivrs_ivhd_11(ACPI_IVRS_HARDWARE2 *addr) +{ + acpi_handle_ivrs_ivhd_info_11(addr); + printf("\tEFRreg=%#018jx\n", (uintmax_t)addr->EfrRegisterImage); + acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), + (char *)addr + addr->Header.Length); +} + +static void +acpi_handle_ivrs_ivhd_40(ACPI_IVRS_HARDWARE2 *addr) +{ + acpi_handle_ivrs_ivhd_info_11(addr); + printf("\tEFRreg=%#018jx EFR2reg=%#018jx\n", + (uintmax_t)addr->EfrRegisterImage, (uintmax_t)addr->Reserved); + acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), + (char *)addr + addr->Header.Length); +} + +static const char * +acpi_handle_ivrs_ivmd_type(ACPI_IVRS_MEMORY *addr) +{ + switch (addr->Header.Type) { + case ACPI_IVRS_TYPE_MEMORY1: + return ("ALL"); + case ACPI_IVRS_TYPE_MEMORY2: + return ("specified"); + case ACPI_IVRS_TYPE_MEMORY3: + return ("range"); + default: + return ("unknown"); + } +} + +static void +acpi_handle_ivrs_ivmd(ACPI_IVRS_MEMORY *addr) +{ + printf("\tMem Type=%#x(%s) ", + addr->Header.Type, acpi_handle_ivrs_ivmd_type(addr)); + switch (addr->Header.Type) { + case ACPI_IVRS_TYPE_MEMORY2: + printf("Id=%#06x PCISeg=%#x ", addr->Header.DeviceId, + *(UINT16 *)&addr->Reserved); + break; + case ACPI_IVRS_TYPE_MEMORY3: + printf("Id=%#06x-%#06x PCISeg=%#x", addr->Header.DeviceId, + addr->AuxData, *(UINT16 *)&addr->Reserved); + break; + } + printf("Start=%#18jx Length=%#jx Flags=", + (uintmax_t)addr->StartAddress, (uintmax_t)addr->MemoryLength); +#define PRINTFLAG(flag, name) printflag(addr->Header.Flags, flag, #name) + PRINTFLAG(ACPI_IVMD_EXCLUSION_RANGE, ExclusionRange); + PRINTFLAG(ACPI_IVMD_WRITE, IW); + PRINTFLAG(ACPI_IVMD_READ, IR); + PRINTFLAG(ACPI_IVMD_UNITY, Unity); +#undef PRINTFLAG + PRINTFLAG_END(); +} + +static int +acpi_handle_ivrs_blocks(void *addr, int remaining, bool efrsup) +{ + ACPI_IVRS_HEADER *hdr = addr; + + if (remaining < (int)sizeof(ACPI_IVRS_HEADER)) + return (-1); + + if (remaining < hdr->Length) + return (-1); + + switch (hdr->Type) { + case ACPI_IVRS_TYPE_HARDWARE1: + acpi_handle_ivrs_ivhd_10(addr, efrsup); + break; + case ACPI_IVRS_TYPE_HARDWARE2: + if (!efrsup) + printf("\t!! Found IVHD block 0x11 but !EFRsup\n"); + acpi_handle_ivrs_ivhd_11(addr); + break; + case ACPI_IVRS_TYPE_HARDWARE3: + if (!efrsup) + printf("\t!! Found IVHD block 0x40 but !EFRsup\n"); + acpi_handle_ivrs_ivhd_40(addr); + break; + case ACPI_IVRS_TYPE_MEMORY1: + case ACPI_IVRS_TYPE_MEMORY2: + case ACPI_IVRS_TYPE_MEMORY3: + acpi_handle_ivrs_ivmd(addr); + break; + default: + printf("\n"); + printf("\tType=%d\n", hdr->Type); + printf("\tLength=%d\n", hdr->Length); + break; + } + return (hdr->Length); +} + +#define ACPI_IVRS_DMAREMAP 0x00000002 +#define ACPI_IVRS_EFRSUP 0x00000001 +#define ACPI_IVRS_GVA_SIZE 0x000000e0 + +static void +acpi_handle_ivrs(ACPI_TABLE_HEADER *sdp) +{ + ACPI_TABLE_IVRS *ivrs; + char *cp; + int remaining, consumed; + bool efrsup; + + printf(BEGIN_COMMENT); + acpi_print_sdt(sdp); + ivrs = (ACPI_TABLE_IVRS *)sdp; + efrsup = (ivrs->Info & ACPI_IVRS_EFRSUP) != 0; + printf("\tVAsize=%d PAsize=%d GVAsize=%d\n", + (ivrs->Info & ACPI_IVRS_VIRTUAL_SIZE) >> 15, + (ivrs->Info & ACPI_IVRS_PHYSICAL_SIZE) >> 8, + (ivrs->Info & ACPI_IVRS_GVA_SIZE) >> 5); + printf("\tATS_resp_res=%d DMA_preboot_remap=%d EFRsup=%d\n", + (ivrs->Info & ACPI_IVRS_ATS_RESERVED) != 0, + (ivrs->Info & ACPI_IVRS_DMAREMAP) != 0, efrsup); + + remaining = sdp->Length - sizeof(ACPI_TABLE_IVRS); + while (remaining > 0) { + cp = (char *)sdp + sdp->Length - remaining; + consumed = acpi_handle_ivrs_blocks(cp, remaining, efrsup); + if (consumed <= 0) + break; + else + remaining -= consumed; + } + + printf(END_COMMENT); +} + static void acpi_print_srat_memory(ACPI_SRAT_MEM_AFFINITY *mp) { @@ -2086,6 +2456,8 @@ acpi_handle_rsdt(ACPI_TABLE_HEADER *rsdp) acpi_handle_tcpa(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_DMAR, 4)) acpi_handle_dmar(sdp); + else if (!memcmp(sdp->Signature, ACPI_SIG_IVRS, 4)) + acpi_handle_ivrs(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_NFIT, 4)) acpi_handle_nfit(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_WDDT, 4)) From nobody Wed Apr 17 08:13:45 2024 X-Original-To: dev-commits-src-branches@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 4VKDFQ1yjcz5J76w; Wed, 17 Apr 2024 08:13:46 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFP5dc5z4BPl; Wed, 17 Apr 2024 08:13:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341625; 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=gWianH62S92VduGieJ93Za4NrXP2tpBq1scPDsigRw4=; b=vmYq6ZiyZ5DG9KoSJTgMGAvwaY/CQgAR5V/PsIr6O+2GKpGhQeWCpgey3OkJBZBSdPNIdZ lnkH1KRR7xoTcOmjs5MslIY56OOL2tAW2G2KP5a3VguibKAvxO8k/NaUeSiEwLxj59KEfr TPA6wh1sOQV7UQUlc+3ksZjtVchUDBL9Cnk2lcJvHf0mVXie6KS2JNaRZAEpJmiWQ9rWJk Hn8N9cUEu2XVKIAb1J5mPbS7zQlHXXaBL+mJue6Sd+FeepUmqrEoA1l/0fpvv2v6Yl26zT dwhx+TV1+bz2uI3jeqAy5krrwsHXWRHxa1hqzALgLUbhXApE4YWc29yLjxcKcw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341625; a=rsa-sha256; cv=none; b=gOPk6Ea14hWhv0ThdqpvOb8TPdXcMuUGtSlx+osdhEFFf0bWv5kQK3MiU9S8qcvE6Y5Hog cOX7H+Wd5T0HfLrEcEGMrZ9FVhI4Elxb15/XK4fxZBq3dqt22zFSI55LZXDIXeh6WU/jH9 yVNbaBR+pXHMlpv2qzrRN7hC68qYcK7gxXF/yWhhQ/YN3/w6RT9MXwVWXh5N8RO1WXv09D IVdXGA2jCTCb5fPR2umOqCOPEB3iCg0l3HIVERCgLHRwP0xg8CpivgIfGT3BXgUKs6VBeS WZu3RZOxX8IpwBiDPxFSTA5hK/72VYlURcFSQn5y33KAaaY8dGGBDHd6bfQgaA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341625; 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=gWianH62S92VduGieJ93Za4NrXP2tpBq1scPDsigRw4=; b=EdTK65Zx8+bKkQR9W5XPFH2yAtEVrWAym59xmEtEi7NBLNsOYUGT8xtxIvW07VQ6S8recJ 4HESGvZ67y25cXNBdMJJg2gcP2YQNY3aTspOY7dkQUL4qdUob0qzh5hhZEJzTdAv5dicMm R4bFetr3339iKKtQvr2V/JaOvfVuBq0HsMI5k/3tGMMq9kL6Mjo2+U/ba9rCXXSxSRV0RD yrmAN/I8SDRSPfFN7Ft75toQiifNsMSpi5Hln4O8M38XFbq1Ya7QJAUey5a0s7g7IGXsP/ 4YwdLgQ41mn59QOaYtka70ZhQ0Tn6D3wixXGDuHAA9dpU2MBoONXSLrAO6nPwg== 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 4VKDFP401WzJhn; Wed, 17 Apr 2024 08:13:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DjNL062509; Wed, 17 Apr 2024 08:13:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8DjW5062506; Wed, 17 Apr 2024 08:13:45 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:45 GMT Message-Id: <202404170813.43H8DjW5062506@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 256ee428f5a3 - stable/13 - acpidump: add Foundation copyright List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 256ee428f5a3ccbe55c15a0b7a8551c41de3da80 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=256ee428f5a3ccbe55c15a0b7a8551c41de3da80 commit 256ee428f5a3ccbe55c15a0b7a8551c41de3da80 Author: Konstantin Belousov AuthorDate: 2024-04-05 14:57:19 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 acpidump: add Foundation copyright (cherry picked from commit f1519a8229d71fc1093c8bd27362c5a9f703dd4b) --- usr.sbin/acpi/acpidump/acpi.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index d4ab70c9ca86..1f3cb34b087f 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -4,8 +4,12 @@ * Copyright (c) 1998 Doug Rabson * Copyright (c) 2000 Mitsuru IWASAKI * Copyright (c) 2020 Alexander Motin + * Copyright (c) 2024 The FreeBSD Foundation * All rights reserved. * + * Portions of this software were developed by Konstantin Belousov + * under sponsorship from the FreeBSD Foundation. + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: From nobody Wed Apr 17 08:13:46 2024 X-Original-To: dev-commits-src-branches@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 4VKDFR1hPmz5J6kn; Wed, 17 Apr 2024 08:13:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFQ5r61z4BNH; Wed, 17 Apr 2024 08:13:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341626; 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=nH3eNYMl0dDFKiKnuEmg63io7veX5zRVnsCwbduFdOM=; b=A0Weu/Vkvg8FAvKW6EXKmSvWHlZ6ZqVM4oF2qXqGD2qQLCOC4w9mhEDP3Wq6gJzo17Xs10 oz/LqZfLY5vnG9Rl8+D2Zop+JHLsLs/gcxCGnl7ZlLruQnuIcmct43aiJVLmUAQaVoxxrE l5bTMaS4V/sktwWzW3G8aiNW6xrJ5OhwjeJd/mAMszWH8Je4LjkR0bzDotTSGumapoK+oy lRCAtVKSqx2eWiuOVnnuI+8WNGeCtc7PvzAAhf1fIMqfwMOOUeFEEZ2i6tZt1a9EwRFslL gGb4zBKcAoYQ00yqKQQYLKpXK3VUemLiHkn9+66KBIBv7mJTMFcimQQgFXodXA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341626; a=rsa-sha256; cv=none; b=o4fbF33JW1YjphzAsPT2ewm/oiTX5qsNZ1tY1UluLZ5IY8dz44f4bOERhaOuco0xdZHu+U zcAzt3YcwQwpz4V5LrV9eBQ8CeKgIW5LuqC7HWQA9/S0HXcWGcI98okIva3lqxZuAGZd6Z vWnKh9biEe9hE/nkA8NUkDSZMRrxqKfiXeCVQOvQjkuBBOTgAryJHJjUDInfQEI/b9eDGO +dC20w71ImbZYwS9dBa0HMUpEiIHQ+R1Ok7rBq7N+pmnqsmcaT6uwbH3NQb0fwMu3R/NLt 0WQzXahXR/k+X4HwClepDrq74J7TihElNqCce2Xd6sMd9sEy4ICyUWc81AOV9w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341626; 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=nH3eNYMl0dDFKiKnuEmg63io7veX5zRVnsCwbduFdOM=; b=WrpGKK0GSS6pO9HPcOT+wyE5VM/dzFGVCiFDCDiBY2twpMNjOZvv4s8BjPucp17QYtoJ+m 4iuQPJS6QM8GKqQb18y6SDBS6X3N6r5abgRGzyIE939avtPI8pC1qQKFiGrYGwz2WUyD3W d3R39WMum2V6gtBhnVwBDT2EAwWHY0gO/l9cMfADqqyie1GlxYTwwzGAdKrrpfJ2H2C/II fyrF+a80kHNS0KYJoeIn1d9U/urnE/lXmNXOVPhYt36qmAo7bUYIFHRgICvwLdAlFHsdbn 6sApURr7lK+Fg2Y5y8gSCeLALkDAwysHPjwbeiLRCzI+/a/4HOYEfeVP9wSmsw== 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 4VKDFQ4cr5zJsS; Wed, 17 Apr 2024 08:13:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8Dkc4062551; Wed, 17 Apr 2024 08:13:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Dkpr062548; Wed, 17 Apr 2024 08:13:46 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:46 GMT Message-Id: <202404170813.43H8Dkpr062548@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 6f8e8d0723cc - stable/13 - pcireg.h: add include guard List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6f8e8d0723cc6550f3fed0eb08fca42cf686ae27 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=6f8e8d0723cc6550f3fed0eb08fca42cf686ae27 commit 6f8e8d0723cc6550f3fed0eb08fca42cf686ae27 Author: Konstantin Belousov AuthorDate: 2024-04-07 01:27:46 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 pcireg.h: add include guard (cherry picked from commit 1cd9868f04c3e91929974dca3444a79047f4e602) --- sys/dev/pci/pcireg.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/dev/pci/pcireg.h b/sys/dev/pci/pcireg.h index ef9b7799f534..c94decd8ef2a 100644 --- a/sys/dev/pci/pcireg.h +++ b/sys/dev/pci/pcireg.h @@ -26,6 +26,9 @@ * */ +#ifndef __PCI_PCIREG_H +#define __PCI_PCIREG_H + /* * PCIM_xxx: mask to locate subfield in register * PCIR_xxx: config register offset @@ -1121,3 +1124,5 @@ #define PCIM_ACS_USP_MEM_TGT_ACC_CTL 0x0c00 #define PCIM_ACS_UNCLAIMED_REQ_REDIRECT_CTL 0x1000 #define PCIR_ACS_EGRESS_CONTROL_VECTOR 0x8 + +#endif /* __PCI_PCIREG_H */ From nobody Wed Apr 17 08:13:47 2024 X-Original-To: dev-commits-src-branches@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 4VKDFS1qNjz5J6wp; Wed, 17 Apr 2024 08:13:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFR6Sywz4B83; Wed, 17 Apr 2024 08:13:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341627; 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=SKoL1tdF/TQtV7TE163VlLYqPrtb/AKkch0BAQ44Sqc=; b=h373beVBz6EPNoI8fqxNw3KGU0OAr367DwDm/Dgix3tM46wW57hrrA8eN0vwU4EvugTUGH qUyzuZ+eMObLEr4DSGTtwTHYs0cCXJqKmljjm1tzYgr/mNhr6sfqrytB0ilkWRAxO2dHk6 ajRgmRYs7wvmXcOMqxx/VP/FI+cHO4XPRaZ2n5tnJ7XWAWh2bZWzlMExl1DWEmKOc64/Qx 6CQKMdNGG7IyAWE1fTOkCR1Nx+9uyzzlKxBYfQ3oqDg001bCtHjCgh6jH0bLMudP7IxfAn VHq0I2TBVIDwKXh4X2RIGuXzffyFudkpFyfS2YhO3LrxQ9XNFsh/vCEkYWXVHA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341627; a=rsa-sha256; cv=none; b=tkWGC1NKNcTsQsrNiz/8B2cRUF8DmBAab2/u1OspE3yDgPfpb5whepQwFLfXOSi+zNrRIJ 939bJhcvRdzPpHcMM4R9zJlk4DTsrbKNg+7p+fSFaf4nQSJZX5uFDvjq28i404HpG7jfn0 BFECIcs0LgF4b3CDIrPeKAOKuC/gufQ3yD4HpMUY4lWWYIyB/X2U+1X7kjlI7baYvmbQ++ Ov8auw1/XIA+xxDxqgirH8OozAWgy4QwV57nOJv8s9C0PMnpb5hssReL+VbcD44pXiVOxv XNMUyGSTf/M3d6qRUl8D1EVJGyZrM6Z8B54tTXY8llvKIPUZo84fJh4YfX6uTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341627; 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=SKoL1tdF/TQtV7TE163VlLYqPrtb/AKkch0BAQ44Sqc=; b=ZL6bzKeYAZ9d39OWJYQk807mMdN+1LTLc1Z5eNdyrMy9goaaX7M/jmI0c42/JIwI2XSoa9 iDabnd92Yd5D5Ym/8V91StncrPzv5p8ZPBxXXF8kNvva9OMrze2wLASJqUvjcpd8aRTBEq R/PMHKdZ2PxvDYA7+3y+/fNMwJj3sYBbxrJ2ec8EmYZ11wETvZERkZbv7d/9X1yPWxxJlF 8drSxmzQtxFRBZfvwDXSGL04MMB+rMSjzT/SYTv6tRTHJ0otQChtcKLMJy5REO21X5JDw4 mmdEX4SAesTTBxWT/QHpx0Qk66oSSbGKs9vfZ7Bp5lq9qtoObkAn5jvKDkYjoA== 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 4VKDFR5c0MzJw7; Wed, 17 Apr 2024 08:13:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DlHP062599; Wed, 17 Apr 2024 08:13:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8DlwT062596; Wed, 17 Apr 2024 08:13:47 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:47 GMT Message-Id: <202404170813.43H8DlwT062596@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 6b771774c5c6 - stable/13 - pcireg.h: Add AMD IOMMU Base Cap definitions List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6b771774c5c6da6286354ebf9b8e2e7432a32dde Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=6b771774c5c6da6286354ebf9b8e2e7432a32dde commit 6b771774c5c6da6286354ebf9b8e2e7432a32dde Author: Konstantin Belousov AuthorDate: 2024-04-07 01:25:46 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 pcireg.h: Add AMD IOMMU Base Cap definitions (cherry picked from commit 33adb388c78ee48efbdc9b497fe2224397fdee84) --- sys/dev/pci/pcireg.h | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/sys/dev/pci/pcireg.h b/sys/dev/pci/pcireg.h index c94decd8ef2a..623deb8b4505 100644 --- a/sys/dev/pci/pcireg.h +++ b/sys/dev/pci/pcireg.h @@ -1125,4 +1125,56 @@ #define PCIM_ACS_UNCLAIMED_REQ_REDIRECT_CTL 0x1000 #define PCIR_ACS_EGRESS_CONTROL_VECTOR 0x8 +/* + * AMD IOMMU Base Capability + * From AMD I/O Virtualization Technology (IOMMU) Specification + * Publication # 48882 Revision: 3.09-PUB Date: October 2023 + */ +#define PCIR_AMDIOMMU_CAP_HEADER 0x0000 +#define PCIR_AMDIOMMU_BASE_LOW 0x0004 +#define PCIR_AMDIOMMU_BASE_HIGH 0x0008 +#define PCIR_AMDIOMMU_RANGE 0x000c +#define PCIR_AMDIOMMU_MISC0 0x0010 +#define PCIR_AMDIOMMU_MISC1 0x0014 + +#define PCIM_AMDIOMMU_CAP_CAPEXT (1 << 28) +#define PCIM_AMDIOMMU_CAP_EFR (1 << 27) +#define PCIM_AMDIOMMU_CAP_NPCACHE (1 << 26) +#define PCIM_AMDIOMMU_CAP_HTTUN (1 << 25) +#define PCIM_AMDIOMMU_CAP_IOTLB (1 << 24) +#define PCIM_AMDIOMMU_CAP_REV_MASK (0x1f << 19) +#define PCIM_AMDIOMMU_CAP_REV_VAL (0x1 << 19) +#define PCIM_AMDIOMMU_CAP_TYPE_MASK (7 << 16) +#define PCIM_AMDIOMMU_CAP_TYPE_VAL (0x3 << 16) + +#define PCIM_AMDIOMMU_BASE_LOW_EN 0x00000001 +#define PCIM_AMDIOMMU_BASE_LOW_ADDRM 0xffffc000 + +#define PCIM_AMDIOMMU_RANGE_UNITID_MASK 0x1f +#define PCIM_AMDIOMMU_RANGE_RNGVALID (1 << 7) +#define PCIM_AMDIOMMU_RANGE_BUSNUM_MASK (0xffffu << 8) +#define PCIM_AMDIOMMU_RANGE_FIRSTDEV_MASK (0xffffu << 16) +#define PCIM_AMDIOMMU_RANGE_LASTDEV_MASK (0xffffu << 24) + +#define PCIM_AMDIOMMU_MISC0_MSINUMPPR_MASK (0x1f << 27) +#define PCIM_AMDIOMMU_MISC0_HTATSRESV (1 << 22) +#define PCIM_AMDIOMMU_MISC0_VASIZE_MASK (0x7f << 15) +#define PCIM_AMDIOMMU_MISC0_PASIZE_MASK (0x7f << 8) +#define PCIM_AMDIOMMU_MISC0_GVASIZE_MASK (0x3 << 5) +#define PCIM_AMDIOMMU_MISC0_MSINUM_MASK 0x1f + +#define PCIM_AMDIOMMU_MISC0_VASIZE_32 (0x20 << 15) +#define PCIM_AMDIOMMU_MISC0_VASIZE_40 (0x28 << 15) +#define PCIM_AMDIOMMU_MISC0_VASIZE_48 (0x30 << 15) +#define PCIM_AMDIOMMU_MISC0_VASIZE_64 (0x40 << 15) + +#define PCIM_AMDIOMMU_MISC0_PASIZE_40 (0x28 << 8) +#define PCIM_AMDIOMMU_MISC0_PASIZE_48 (0x30 << 8) +#define PCIM_AMDIOMMU_MISC0_PASIZE_52 (0x34 << 8) + +#define PCIM_AMDIOMMU_MISC0_GVASIZE_48 (0x2 << 5) +#define PCIM_AMDIOMMU_MISC0_GVASIZE_57 (0x3 << 5) + +#define PCIM_AMDIOMMU_MISC1_MSINUMGA_MASK 0x1f + #endif /* __PCI_PCIREG_H */ From nobody Wed Apr 17 08:13:48 2024 X-Original-To: dev-commits-src-branches@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 4VKDFT2M53z5J6jh; Wed, 17 Apr 2024 08:13:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDFS6zBFz4BNh; Wed, 17 Apr 2024 08:13:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341629; 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=y8LIVBmcKK/ww1LNrGGvQ3qA5dCPeLTLQzyFqmZtLQo=; b=ouuI7Wxy+zfyBVGfoKCfDZJJxADfivQyYW68MWc6IZkCun3VcEzpEc5btjggS3UActSw4M 5x/aUGw9CWERTtFIzVJheJSjuq45uq4aRiFv2FKsJa0ORFaqJdKBx6DTIiyRToZmhg1eGX 4ByUJk+dplS8dAlS6I+NeRZG9TMX/KlbFLZS4JUsMznyOPOMli14H8rhWr2NmZ0VDEr5U+ UV/e/P+X5C+po9htQu9YA9xQRoCaYsi6y3EFdZciNeGvcnrT9+tLDRDh2dti5Dmfxsx4Od O6511x58fTOE+MhPQ2v9Nb3lR+5/0FClVtdrdf6ssuyEXgDvt6WJmklnFmuSZA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713341629; a=rsa-sha256; cv=none; b=XStOyetUHpk4XjjeT1Yo7MtSreuGZjOaxUfCPJjGkqoLVX8Ed6lNEHrJ0dc5pnvJFKGFUF ikjxOBwTg5eukv+VwJEAzVpZEAuYYiVYv96RZ2jdzqajkRXOjzWIpuC+MWAeeorUfZ0Fer ZulXnmBcvt0Y/7kIrdQklH7jaFzarHOoc9SVuSrF6mcoqaE+KbNSz6vJK2JJjYk8TQpiho sHZk0r5WH85ZFo3FArTt7ZuHGbHmlgFaC8dzagLVid8qmVgQh3quj++WxjwYjGfJbbR5GU Ctd3FiT3DrlfxUNRw77GbiInx+ZQ0QIwyiINTCqwuqIQFfSmhToetp/t79ZXSQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713341629; 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=y8LIVBmcKK/ww1LNrGGvQ3qA5dCPeLTLQzyFqmZtLQo=; b=IcZMo6f4Yw0s/MY4gGelEugH5Jp2Hj6SEtXedonKl+7e+t/WLCfkScxqeMMpqCnYoaQGOO UDNmA0f92UtY5KB7l/jMTNGorHlj9+DnxFwcEeYN8E/Z2iKw5xGQvSD+OCDHt90405bGQb 5sGgHyVffBMQTOYJMjDlhEFB/XN0gK+KMO4TqCb4lPp1pIVn7pYttZvLYMgY07LAncpyaL gydlMkdEhVU8hSQAxf7sKT6ms+kVBK9gumyPBQAXrleOJjiDA7gzQVjPfvpgGfv/v4NYMT 0xVlnR6KGxyfL6YBDCHAm4C5H7r16vspBXpHt/WjMCY0VkXKwVHkp3ehfSaT9Q== 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 4VKDFS6X3TzJk3; Wed, 17 Apr 2024 08:13:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H8DmcH062644; Wed, 17 Apr 2024 08:13:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H8Dmq1062641; Wed, 17 Apr 2024 08:13:48 GMT (envelope-from git) Date: Wed, 17 Apr 2024 08:13:48 GMT Message-Id: <202404170813.43H8Dmq1062641@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 02dc74cc21af - stable/13 - pciconf(8): dump AMD IOMMU Base Capability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 02dc74cc21af0928021fb53de1c804d068de1449 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=02dc74cc21af0928021fb53de1c804d068de1449 commit 02dc74cc21af0928021fb53de1c804d068de1449 Author: Konstantin Belousov AuthorDate: 2024-04-09 22:13:59 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 08:13:18 +0000 pciconf(8): dump AMD IOMMU Base Capability (cherry picked from commit 1e6db7be692198acfa7f02dea83aa9aa1dfce273) --- usr.sbin/pciconf/cap.c | 115 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) diff --git a/usr.sbin/pciconf/cap.c b/usr.sbin/pciconf/cap.c index 7b403b90eee6..72b63db31d70 100644 --- a/usr.sbin/pciconf/cap.c +++ b/usr.sbin/pciconf/cap.c @@ -376,6 +376,118 @@ cap_subvendor(int fd, struct pci_conf *p, uint8_t ptr) printf("PCI Bridge subvendor=0x%04x subdevice=0x%04x", ssvid, ssid); } +static const char * +cap_secdev_amdiommu_decode_vasize(uint32_t misc0) +{ + switch (misc0 & PCIM_AMDIOMMU_MISC0_VASIZE_MASK) { + case PCIM_AMDIOMMU_MISC0_VASIZE_32: + return ("32bit"); + case PCIM_AMDIOMMU_MISC0_VASIZE_40: + return ("40bit"); + case PCIM_AMDIOMMU_MISC0_VASIZE_48: + return ("48bit"); + case PCIM_AMDIOMMU_MISC0_VASIZE_64: + return ("64bit"); + default: + return ("unknown"); + } +} + +static const char * +cap_secdev_amdiommu_decode_pasize(uint32_t misc0) +{ + switch (misc0 & PCIM_AMDIOMMU_MISC0_PASIZE_MASK) { + case PCIM_AMDIOMMU_MISC0_PASIZE_40: + return ("40bit"); + case PCIM_AMDIOMMU_MISC0_PASIZE_48: + return ("48bit"); + case PCIM_AMDIOMMU_MISC0_PASIZE_52: + return ("52bit"); + default: + return ("unknown"); + } +} + +static const char * +cap_secdev_amdiommu_decode_gvasize(uint32_t misc0) +{ + switch (misc0 & PCIM_AMDIOMMU_MISC0_GVASIZE_MASK) { + case PCIM_AMDIOMMU_MISC0_GVASIZE_48: + return ("48bit"); + case PCIM_AMDIOMMU_MISC0_GVASIZE_57: + return ("57bit"); + default: + return ("unknown"); + } +} + +static void +cap_secdev(int fd, struct pci_conf *p, uint8_t ptr) +{ + uint32_t cap_h; + uint32_t cap_type, cap_rev; + uint32_t base_low, base_high; + uint32_t range; + uint32_t misc0, misc1; + const char *delim; + + cap_h = read_config(fd, &p->pc_sel, ptr + PCIR_AMDIOMMU_CAP_HEADER, 4); + cap_type = cap_h & PCIM_AMDIOMMU_CAP_TYPE_MASK; + cap_rev = cap_h & PCIM_AMDIOMMU_CAP_REV_MASK; + if (cap_type != PCIM_AMDIOMMU_CAP_TYPE_VAL || + cap_rev != PCIM_AMDIOMMU_CAP_REV_VAL) { + printf("Secure Device Type=0x%1x Rev=0x%02x\n", + cap_type >> 16, cap_rev >> 19); + return; + } + base_low = read_config(fd, &p->pc_sel, ptr + PCIR_AMDIOMMU_BASE_LOW, + 4); + base_high = read_config(fd, &p->pc_sel, ptr + PCIR_AMDIOMMU_BASE_HIGH, + 4); + printf("AMD IOMMU Base Capability Base=%#018jx/%sabled", + (uintmax_t)(base_low & PCIM_AMDIOMMU_BASE_LOW_ADDRM) + + ((uintmax_t)base_high << 32), + (base_low & PCIM_AMDIOMMU_BASE_LOW_EN) != 0 ? "En" : "Dis"); + + delim = "\n\t\t"; +#define PRINTCAP(bit, name) \ + if ((cap_h & PCIM_AMDIOMMU_CAP_ ##bit) != 0) { \ + printf("%s%s", delim, #name); \ + delim = ","; \ + } + PRINTCAP(CAPEXT, CapExt); + PRINTCAP(EFR, EFRSup); + PRINTCAP(NPCACHE, NpCache); + PRINTCAP(HTTUN, HtTunnel); + PRINTCAP(IOTLB, IotlbSup); +#undef PRINTCAP + + range = read_config(fd, &p->pc_sel, ptr + PCIR_AMDIOMMU_RANGE, 4); + printf("\n\t\tUnitId=%d", range & PCIM_AMDIOMMU_RANGE_UNITID_MASK); + if ((range & PCIM_AMDIOMMU_RANGE_RNGVALID) != 0) { + printf(" BusNum=%#06x FirstDev=%#06x LastDev=%#06x", + (range & PCIM_AMDIOMMU_RANGE_BUSNUM_MASK) >> 8, + (range & PCIM_AMDIOMMU_RANGE_FIRSTDEV_MASK) >> 16, + (range & PCIM_AMDIOMMU_RANGE_LASTDEV_MASK) >> 24); + } + + misc0 = read_config(fd, &p->pc_sel, ptr + PCIR_AMDIOMMU_MISC0, 4); + printf("\n\t\tMsiNum=%d MsiNumPPR=%d HtAtsResv=%d", + misc0 & PCIM_AMDIOMMU_MISC0_MSINUM_MASK, + (misc0 & PCIM_AMDIOMMU_MISC0_MSINUMPPR_MASK) >> 27, + (misc0 & PCIM_AMDIOMMU_MISC0_HTATSRESV) != 0); + if ((cap_h & PCIM_AMDIOMMU_CAP_CAPEXT) != 0) { + misc1 = read_config(fd, &p->pc_sel, + ptr + PCIR_AMDIOMMU_MISC1, 4); + printf(" MsiNumGA=%d", + misc1 & PCIM_AMDIOMMU_MISC1_MSINUMGA_MASK); + } + printf("\n\t\tVAsize=%s PAsize=%s GVAsize=%s", + cap_secdev_amdiommu_decode_vasize(misc0), + cap_secdev_amdiommu_decode_pasize(misc0), + cap_secdev_amdiommu_decode_gvasize(misc0)); +} + #define MAX_PAYLOAD(field) (128 << (field)) static const char * @@ -809,6 +921,9 @@ list_caps(int fd, struct pci_conf *p, int level) case PCIY_SUBVENDOR: cap_subvendor(fd, p, ptr); break; + case PCIY_SECDEV: + cap_secdev(fd, p, ptr); + break; case PCIY_EXPRESS: express = 1; cap_express(fd, p, ptr); From nobody Wed Apr 17 08:22:52 2024 X-Original-To: dev-commits-src-branches@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 4VKDSB23Kdz5J7SJ; Wed, 17 Apr 2024 08:23:06 +0000 (UTC) (envelope-from zec@fer.hr) Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2137.outbound.protection.outlook.com [40.107.21.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "DigiCert Cloud Services CA-1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKDS94stdz4Gd1; Wed, 17 Apr 2024 08:23:05 +0000 (UTC) (envelope-from zec@fer.hr) Authentication-Results: mx1.freebsd.org; none ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Okt8i8okNV9TwEuDLnrEr8LDED1+mObzec5h/i0IdaqP4ofRR70KfympMf/qv1BKjr5c7xnyrLycBneneZkT62KWH/taSj3pUqb70TDVkYTBhdlr/YIfYkVgozBdhmFbv4WVTzNRo4s/k279PxGQWvd5twQrLv9pbEBu8hCtnFqB3uFEm00hjmjxxWcf/wO575KWF9ASmVSB3ETYz5WgmDmcJTbcIYqM7ps45XXCcU51GJjzlkvalNk3ThJeRNzGkVg25X9pzZ6K1HWLqQLnkSbD7m/zHTUfXHnq7KWJKsGLN/JXKLP6DX36mBQnhyid3taRPMaarrQ5HiS79uIUJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=o6T36yqdRtfvOKKJFbx21Cn6FT/vclMZ4CtGcGy33Fc=; b=WBwm9yUD7VIusaurp3R47msPyO6r3/1z9J9gG5MqaFgMio/KCumMiHEJbGxEAENAMAg/vC2eo5BiERbCTHweKVKMYsxwfvgL9OZxynFQhtWfmVhtumUY8DhGw9D05ZMU73B4OV06J4U5FB0+vuqiWNYKi52TDedLL0FAnACaYJ1ybkmWdan686gAoMRRpOVhez3mDtf5H1Vw28T5xkBiwSgvxQj5jvUNfoK+/cqArBa/Mz3MipxTeg/uMR7QljOPJ8kJUOW8840J5JYak6oPQe6BX6S5rubh5sLgaNmtVDdMmaoeFVini1JelQI+TrztwnbV5oKowsZmlaeFzlh4DQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=fer.hr; dmarc=pass action=none header.from=fer.hr; dkim=pass header.d=fer.hr; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ferhr.onmicrosoft.com; s=selector2-ferhr-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=o6T36yqdRtfvOKKJFbx21Cn6FT/vclMZ4CtGcGy33Fc=; b=X7JYE9Z3lH7I8De5pzQOjVBxGMyyzxLZ7xyDSGEsVoq9IYwT8N2iwnAcepCqtgfJPGosvzLaq5g54vq5dnErI6NTs8QgN7CB1IdlFIu5VpL+roE9B5micaXaEB00qVrH2alX0LStT8dnuCs4i9ExTyY/4ko0Rb2bk2DjK71e5eo= Received: from GV1PR08MB8257.eurprd08.prod.outlook.com (2603:10a6:150:8b::12) by PAXPR08MB6703.eurprd08.prod.outlook.com (2603:10a6:102:138::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7472.37; Wed, 17 Apr 2024 08:22:58 +0000 Received: from GV1PR08MB8257.eurprd08.prod.outlook.com ([fe80::8099:64c2:e811:e453]) by GV1PR08MB8257.eurprd08.prod.outlook.com ([fe80::8099:64c2:e811:e453%4]) with mapi id 15.20.7452.049; Wed, 17 Apr 2024 08:22:58 +0000 Date: Wed, 17 Apr 2024 10:22:52 +0200 From: Marko Zec To: Gleb Smirnoff Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: Re: git: 8062f37d1c99 - stable/14 - vtnet: set VNET context in RX handler Message-ID: <20240417102252.27e1038d@x25> In-Reply-To: <202404161558.43GFwoEt095208@gitrepo.freebsd.org> References: <202404161558.43GFwoEt095208@gitrepo.freebsd.org> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; amd64-portbld-freebsd13.2) Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-ClientProxiedBy: VI1PR0102CA0054.eurprd01.prod.exchangelabs.com (2603:10a6:803::31) To GV1PR08MB8257.eurprd08.prod.outlook.com (2603:10a6:150:8b::12) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1PR08MB8257:EE_|PAXPR08MB6703:EE_ X-MS-Office365-Filtering-Correlation-Id: 3047e1d0-3ce2-4d37-7ad8-08dc5eb796da X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: m5+fUY5slboR6NqdMtKhJqdzeY2RG+rrjIEeCw/S4b3EJ0oddTwmCRiFnNKK8J5eCFFJ+dFkdZa5aaHQc7S0F7NFMuWRsb/SDM7V1GY9wlcXzQ6WuXcyX3f9xXIXqTspJ3IUJR+wpme5K0c3FT/SqeEfc+/B4Gpz1vfWds5NUGGD03bICi+RKMIHQ1kNDrN2gLhtZfX/st78EVOPkis0JYtJfigv58Mw3odj7AMZsNzwqpU6XWKLH3Up1T+fcWMX7+/Vz1ualjuvtSt1Y5/ckQL3TKn+LVcV9+5MyYdGBZ6PPpj6efRUfkzh9oYqgz2Vaw24VNDfE2YHNcvCoIB3Bt6ZbFLdptKmssrh4xhuCNs15Lx4zsKLlWSXPOnpFwa7t51TRy7HSdVGR37pa+HgesDp84xu1v3bpSyFD9QqHMsp0ulTDrO/B/udET5uiXFsldjm7c5J3xBf6XgQb/NBRx/lMfz/lzmmKLzriqBNbyApKfUmd3xK8BpbVEPabdR538llC2/O1IO24gUcc+Pf/sZfBuFgfCX2d5J/2o2RCVFo1TGb2tSRJ/xzZ2vZgiNrGIeCJV5vgACEM+AYA7ruGyAOSfjOkQFZZCebyx+0Cqt5+puNW7jIPdccAHho2gbs5JA8gdT10h2KEFmCEj4Qylu6HInVA6aYa3K2ITAF8N0= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:GV1PR08MB8257.eurprd08.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(366007)(376005)(1800799015)(41320700004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?HFw0Wrb1Wlw1R/fq47SOUwM/drB8UtEmEa+L6qrIPGDdOFluH7fvcJ7khnAY?= =?us-ascii?Q?ZLApJjrgvFNvjz2caxMODjsJmad+rFFW5kbmk7/KpeIwc7LkU7SgYrX+t9qc?= =?us-ascii?Q?cj+mM2S920sGRJYlzAHVRbo1YN8aoETbHnH0myWNqUDcQIBzw9N9Q0ON56gD?= =?us-ascii?Q?8+ByALFYLrepiIAV7yJALBMCMrbGajqit3I+fbsnHTz5oAb4XWaTT+5aDCql?= =?us-ascii?Q?QDgnqJFCTHhpVjGJsrGJCtIW49EQnF1H3bsQKoiAgk639nHl4J/cJYC97oOD?= =?us-ascii?Q?YroiO6cjqRUZnp74fvLYLNbXYACKwqrjY7RIWKZMUDABKUVQ9e8198QtaRtk?= =?us-ascii?Q?Y58ZqAjtQ1+Dk3kL0ynJCevsMbuK4FvxDOhmHmq75HbwjUG8qxwFNO07TrHD?= =?us-ascii?Q?MN7wN/3/AqWRVUXApezmW93XyDmzbuDqy9nhczzbKEwW6sCSoq1ZlibYng0l?= =?us-ascii?Q?xv4ZzkZASpHugMwPJHIo9YG1eo280cKrPyISr9ngk+skDF2qjja89HHzZtZ3?= =?us-ascii?Q?TdnISmc5pdPnU+sKiDmCvkyOwu1TKaw2lAzjiViAjs8setaL60AE0lFrvgYV?= =?us-ascii?Q?ZalRq8o+jIBBIsFOX+RMDNLXgHfAOnb3osAPWyX8kIQ86cv1XLzTcGIkDYe3?= =?us-ascii?Q?Ypk8Y8QQGrayEplYcXzcipwYd8pLnfXvbFIY4ZDEvb61GKghJiDTpLocGRei?= =?us-ascii?Q?ZTrLQ7WjJwE8i/zjxN/YYG3XTWGi4/yvI0FvvUtrchWOpTkN1VUS3eKVWN6g?= =?us-ascii?Q?G+dcAe+U8yWoM1TgHw7tgwAngWUeDCTwAybuHQG/TZAuYkqnjKb8tJucHCaM?= =?us-ascii?Q?5pgreB2k1gMVo2rSHXCQr63iWK46xFifq4MeV5b5mYpT+mye3DfE5l7N4kku?= =?us-ascii?Q?xiqUBU3iSL5MGiZp2gOD6vZh5FMknPYVU+9sVgWb8e5ZcnMCCNn9isXa0gpg?= =?us-ascii?Q?ZEp79JjAOr5zykQlVch1CKHsNaOU6E8S8pKjKyNvGQNPiZmbGiSyWsY9RUeO?= =?us-ascii?Q?O3EL0IQqu+XFHpvpLGFYtVCRDMgLpIg2aEGAiSV1PjIZ1umxm20iVmV1c/ss?= =?us-ascii?Q?GQaJUvA/iEfuzVs21UK7b4GQ2avUwzQ5JGpvPjS/+Y9mazY5SFEweDfv9FEI?= =?us-ascii?Q?gJjfTRSQ+XAterrAjk16Pe0TlsZB4IgpKc9GS+cZIPL8eyg1LQiFIDNkMyjy?= =?us-ascii?Q?g55aEk4tMi2W3Ywz+tpBy4yap1Vh0swPngXIQZxblVnCoB4azU+2T0GcH3j4?= =?us-ascii?Q?pxE8LlrKPzmgiDPOHiAtLtDIbzcoeHPOTaC+2Oh9XExZPdb1UUMy7K9bT2eI?= =?us-ascii?Q?8Y9lFyBB3ZitvFiClqKYvd8s9Quxb8dYpAw0OSy/mpgkvfzwYqF5CrC/Ahv0?= =?us-ascii?Q?ZnlNiM5AfL2wTrd0a8/F4Z2gyKWpQGH13en9JhiVTRoi1ET9sklWwJ+bqckl?= =?us-ascii?Q?8m8KD2nSwcA/e0rMFeUw7+VqmgkZ5bZqOeOIjk1ha0O17clhy1Ch1+5df5OT?= =?us-ascii?Q?uM1f/TL9XgcCfigY5uDUrgZNBVn0yI189kzc9h6V+ALGsaXHbS9Ul+JGcA71?= =?us-ascii?Q?QHjXQdae2rexSgpUVN0=3D?= X-OriginatorOrg: fer.hr X-MS-Exchange-CrossTenant-Network-Message-Id: 3047e1d0-3ce2-4d37-7ad8-08dc5eb796da X-MS-Exchange-CrossTenant-AuthSource: GV1PR08MB8257.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Apr 2024 08:22:58.4441 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: ca71eddc-cc7b-4e5b-95bd-55b658e696be X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: rubCBVhomlSqw7gRSBC5xhdOLD6QG4KTdJGcu8kZyz/yl0+cWVo7HP4GUngkCxKC X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAXPR08MB6703 X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:8075, ipnet:40.104.0.0/14, country:US] X-Rspamd-Queue-Id: 4VKDS94stdz4Gd1 On Tue, 16 Apr 2024 15:58:50 GMT Gleb Smirnoff wrote: > The branch stable/14 has been updated by glebius: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=8062f37d1c99ded250b36ad90fb32bb5f77ee600 ... > vtnet: set VNET context in RX handler Two questions: 1) why is vnet not resolved directly via ifp->if_vnet, i.e. why do we need to go through if_getvnet() here? Not only is if_getvnet() unnecessarily making a function call to return a value of a struct member already at hand, but is doing this on a hot path. if_getvnet() arrived in 0d2684e15e415cef652e0f75e88962a674bffe04 / D38202 as an "accessor" function with a declared intent to help a vendor maintaining their private out-of-tree drivers independent of changes in struct ifnet layout. While this indeed may make sense for certain vendor-specific use cases, why do we need to take a penalty of calling if_getvnet() in internal code, here and elsewhere? if_getvnet() use is starting to get widespread, and it would be nice if we could hear the reasoning behind this school of thought, and perhaps document when the call should be used, and when prefereably not? 2) why is CURVNET_SET_QUIET() used instead of CURVNET_SET()? Which VNET recursion are you trying to quiesce with the _QUIET() version? > > The context is required for NIC-level pfil(9) filtering. > > (cherry picked from commit > 3f2b9607756d0f92ca29c844db0718b313a06634) --- > sys/dev/virtio/network/if_vtnet.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/sys/dev/virtio/network/if_vtnet.c > b/sys/dev/virtio/network/if_vtnet.c index 7d6411876b3d..245a6b6d7359 > 100644 --- a/sys/dev/virtio/network/if_vtnet.c > +++ b/sys/dev/virtio/network/if_vtnet.c > @@ -2095,6 +2095,7 @@ vtnet_rxq_eof(struct vtnet_rxq *rxq) > > VTNET_RXQ_LOCK_ASSERT(rxq); > > + CURVNET_SET_QUIET(if_getvnet(ifp)); > while (count-- > 0) { > struct mbuf *m; > uint32_t len, nbufs, adjsz; > @@ -2188,6 +2189,7 @@ vtnet_rxq_eof(struct vtnet_rxq *rxq) > #endif > virtqueue_notify(vq); > } > + CURVNET_RESTORE(); > > return (count > 0 ? 0 : EAGAIN); > } From nobody Wed Apr 17 09:41:48 2024 X-Original-To: dev-commits-src-branches@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 4VKGC05vvBz5GWLn; Wed, 17 Apr 2024 09:41:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKGC05T1Bz4P2k; Wed, 17 Apr 2024 09:41:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713346908; 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=q97UqhoWqzk8L28rUwVKjpOPLEGSF3df3zxE8QiiN8Q=; b=od5Xh9ill/g1QahlEA57n2quNSsoFlo+Ziqto/Mw3czf4AKmigM7vfRruT77lVIAAvwQvS mdiRhTv9tG/VCyO9C+4lWyH8zFqSEBZHznlYWW39i7b2LakqrbfTv7f8kiZ9eQx1UtOWyn i/a01LOUn7/ZrcgtO0S6vgb5HLbyXcOIqYu/SrR1qQYmFjb8jKd5qtUkYmg3i3T5FcFf5v Ue4tcUYZD+oXqujWBHvkeOMOA7pncWZuRhEjTaQsFbkwsUiKMJK3X5Nj1wurEhy7ZL0uTT 33SUm0M+DcDATZhav+PKjRIQD+gvC4HZL0ExfO1IC0jppgIE+XmUPH0c7/JzQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713346908; a=rsa-sha256; cv=none; b=KcVt81tj+jk3Tcf7J67jDUYflUi+vs0fSiTF6MDBSkgDl0C4ZMmsPisByYXFczuoKSUDyB BDg2tR6bmEKMNMHYCj1nH8WpU6vOJBDVAhSE1SJJQxb0SevxmnkD+DLXEB5XYbZUHaZXEB sL18ITDj+mnCA1+fPoxUVzPy7Jx4WZlLy1FnVC5kMYveUgSPvx5RITIcpkyrE6lHc3LEhS 21Y5fPwv5McXUOIxcD8m58MyfioISNKgbMqLZTzNzfkJnP6gUjQVroPLl8dxkOHYr5uGI+ deGBmrPicQDWdjVWDEvEKiRkZPViUuJeUd3u1BNcc8TNJTWNXag2bVHTFcxhvw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713346908; 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=q97UqhoWqzk8L28rUwVKjpOPLEGSF3df3zxE8QiiN8Q=; b=N/wjY1zyAugIwtCSvj3bFNkUlKZ05AfAiNHl72dL6LFuZMn9cHpkGehcXBClVAcuARR1fU 0yM5opz9NvzcchOaD62WoQNu78TtRNGWPkEAfkyr4BFfIIl5Ag7+7nrmn2LLLPoK8LXRO5 Dxj5vlbeBdUSOM3gcha+iP+GVEDGH2+dyWvYwCi5JaUtB7K+f2l96upRt8KTprZ1ViKiaK NQE501s+NVQmRQ4ZWj2jJSOY8QIaDf6qIbWfx8H8jqMqQWfzxecJx06NfUBIvH1S++gGGF 9luchT2a5jYg7vNaWZhOh1mK5DhlNZZIA0ZttJLS6ujuzY/zkQ6P4PwrGn9SPw== 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 4VKGC054JVzM0f; Wed, 17 Apr 2024 09:41:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43H9fmmG012175; Wed, 17 Apr 2024 09:41:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H9fm8E012172; Wed, 17 Apr 2024 09:41:48 GMT (envelope-from git) Date: Wed, 17 Apr 2024 09:41:48 GMT Message-Id: <202404170941.43H9fm8E012172@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 7cf0b203f57d - stable/13 - Revert "acpidump: dump AMD IVRS table describing IOMMU layout" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 7cf0b203f57d9d6659a7da9c2c029ceca9946bc7 Auto-Submitted: auto-generated The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7cf0b203f57d9d6659a7da9c2c029ceca9946bc7 commit 7cf0b203f57d9d6659a7da9c2c029ceca9946bc7 Author: Konstantin Belousov AuthorDate: 2024-04-17 09:39:36 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-17 09:40:04 +0000 Revert "acpidump: dump AMD IVRS table describing IOMMU layout" and related helping commits on stable/13. This reverts commits 256ee428f5a3ccbe55c15a0b7a8551c41de3da80 f95a254aa7226160d41768112fd714a5c16bae61 f7fd7f8b88a15cd70e8d5b471264875d006fcd39 The acpi-ca version on stable/13 is too old. --- usr.sbin/acpi/acpidump/acpi.c | 388 ------------------------------------------ 1 file changed, 388 deletions(-) diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c index 1f3cb34b087f..5005c4bbe630 100644 --- a/usr.sbin/acpi/acpidump/acpi.c +++ b/usr.sbin/acpi/acpidump/acpi.c @@ -4,12 +4,8 @@ * Copyright (c) 1998 Doug Rabson * Copyright (c) 2000 Mitsuru IWASAKI * Copyright (c) 2020 Alexander Motin - * Copyright (c) 2024 The FreeBSD Foundation * All rights reserved. * - * Portions of this software were developed by Konstantin Belousov - * under sponsorship from the FreeBSD Foundation. - * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -40,7 +36,6 @@ #include #include #include -#include #include #include #include @@ -161,18 +156,6 @@ printflag(uint64_t var, uint64_t mask, const char *name) } } -static void -printfield(uint64_t var, int lbit, int hbit, const char *name) -{ - uint64_t mask; - int len; - - len = hbit - lbit + 1; - mask = ((1 << (len + 1)) - 1) << lbit; - printf("%c%s=%#jx", pf_sep, name, (uintmax_t)((var & mask) >> lbit)); - pf_sep = ','; -} - static void acpi_print_string(char *s, size_t length) { @@ -1501,375 +1484,6 @@ acpi_handle_dmar(ACPI_TABLE_HEADER *sdp) printf(END_COMMENT); } -static void -acpi_handle_ivrs_ivhd_header(ACPI_IVRS_HEADER *addr) -{ - printf("\n\tIVHD Type=%#x IOMMUId=%x\n\tFlags=", - addr->Type, addr->DeviceId); -#define PRINTFLAG(flag, name) printflag(addr->Flags, flag, #name) - PRINTFLAG(ACPI_IVHD_TT_ENABLE, HtTunEn); - PRINTFLAG(ACPI_IVHD_ISOC, PassPW); - PRINTFLAG(ACPI_IVHD_RES_PASS_PW, ResPassPW); - PRINTFLAG(ACPI_IVHD_ISOC, Isoc); - PRINTFLAG(ACPI_IVHD_TT_ENABLE, IotlbSup); - PRINTFLAG((1 << 5), Coherent); - PRINTFLAG((1 << 6), PreFSup); - PRINTFLAG((1 << 7), PPRSup); -#undef PRINTFLAG - PRINTFLAG_END(); -} - -static void -acpi_handle_ivrs_ivhd_dte(UINT8 dte) -{ - if (dte == 0) { - printf("\n"); - return; - } - printf(" DTE="); -#define PRINTFLAG(flag, name) printflag(dte, flag, #name) - PRINTFLAG(ACPI_IVHD_INIT_PASS, INITPass); - PRINTFLAG(ACPI_IVHD_EINT_PASS, EIntPass); - PRINTFLAG(ACPI_IVHD_NMI_PASS, NMIPass); - PRINTFLAG(ACPI_IVHD_SYSTEM_MGMT, SysMgtPass); - PRINTFLAG(ACPI_IVHD_LINT0_PASS, Lint0Pass); - PRINTFLAG(ACPI_IVHD_LINT1_PASS, Lint1Pass); -#undef PRINTFLAG - PRINTFLAG_END(); -} - -static void -acpi_handle_ivrs_ivhd_edte(UINT32 edte) -{ - if (edte == 0) - return; - printf("\t\t ExtDTE="); -#define PRINTFLAG(flag, name) printflag(edte, flag, #name) - PRINTFLAG(ACPI_IVHD_ATS_DISABLED, AtsDisabled); -#undef PRINTFLAG - PRINTFLAG_END(); -} - -static const char * -acpi_handle_ivrs_ivhd_variety(UINT8 v) -{ - switch (v) { - case ACPI_IVHD_IOAPIC: - return ("IOAPIC"); - case ACPI_IVHD_HPET: - return ("HPET"); - default: - return ("UNKNOWN"); - } -} - -static void -acpi_handle_ivrs_ivhd_devs(ACPI_IVRS_DE_HEADER *d, char *de) -{ - char *db; - ACPI_IVRS_DEVICE4 *d4; - ACPI_IVRS_DEVICE8A *d8a; - ACPI_IVRS_DEVICE8B *d8b; - ACPI_IVRS_DEVICE8C *d8c; - ACPI_IVRS_DEVICE_HID *dh; - size_t len; - UINT32 x32; - - for (; (char *)d < de; d = (ACPI_IVRS_DE_HEADER *)(db + len)) { - db = (char *)d; - if (d->Type == ACPI_IVRS_TYPE_PAD4) { - len = sizeof(*d4); - } else if (d->Type == ACPI_IVRS_TYPE_ALL) { - d4 = (ACPI_IVRS_DEVICE4 *)db; - len = sizeof(*d4); - printf("\t\tDev Type=%#x Id=ALL", d4->Header.Type); - acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_SELECT) { - d4 = (ACPI_IVRS_DEVICE4 *)db; - len = sizeof(*d4); - printf("\t\tDev Type=%#x Id=%#06x", d4->Header.Type, - d4->Header.Id); - acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_START) { - d4 = (ACPI_IVRS_DEVICE4 *)db; - len = 2 * sizeof(*d4); - printf("\t\tDev Type=%#x Id=%#06x-%#06x", - d4->Header.Type, - d4->Header.Id, (d4 + 1)->Header.Id); - acpi_handle_ivrs_ivhd_dte(d4->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_END) { - d4 = (ACPI_IVRS_DEVICE4 *)db; - len = 2 * sizeof(*d4); - printf("\t\tDev Type=%#x Id=%#06x BIOS BUG\n", - d4->Header.Type, d4->Header.Id); - } else if (d->Type == ACPI_IVRS_TYPE_PAD8) { - len = sizeof(*d8a); - } else if (d->Type == ACPI_IVRS_TYPE_ALIAS_SELECT) { - d8a = (ACPI_IVRS_DEVICE8A *)db; - len = sizeof(*d8a); - printf("\t\tDev Type=%#x Id=%#06x AliasId=%#06x", - d8a->Header.Type, d8a->Header.Id, d8a->UsedId); - acpi_handle_ivrs_ivhd_dte(d8a->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_ALIAS_START) { - d8a = (ACPI_IVRS_DEVICE8A *)db; - d4 = (ACPI_IVRS_DEVICE4 *)(db + sizeof(*d8a)); - len = sizeof(*d8a) + sizeof(*d4); - printf("\t\tDev Type=%#x Id=%#06x-%#06x AliasId=%#06x", - d8a->Header.Type, d8a->Header.Id, d4->Header.Id, - d8a->UsedId); - acpi_handle_ivrs_ivhd_dte(d8a->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_EXT_SELECT) { - d8b = (ACPI_IVRS_DEVICE8B *)db; - len = sizeof(*d8b); - printf("\t\tDev Type=%#x Id=%#06x", - d8a->Header.Type, d8a->Header.Id); - acpi_handle_ivrs_ivhd_dte(d8b->Header.DataSetting); - printf("\t\t"); - acpi_handle_ivrs_ivhd_edte(d8b->ExtendedData); - } else if (d->Type == ACPI_IVRS_TYPE_EXT_START) { - d8b = (ACPI_IVRS_DEVICE8B *)db; - len = sizeof(*d8b); - d4 = (ACPI_IVRS_DEVICE4 *)(db + sizeof(*d8a)); - len = sizeof(*d8a) + sizeof(*d4); - printf("\t\tDev Type=%#x Id=%#06x-%#06x", - d8a->Header.Type, d8a->Header.Id, d4->Header.Id); - acpi_handle_ivrs_ivhd_dte(d8b->Header.DataSetting); - acpi_handle_ivrs_ivhd_edte(d8b->ExtendedData); - } else if (d->Type == ACPI_IVRS_TYPE_SPECIAL) { - d8c = (ACPI_IVRS_DEVICE8C *)db; - len = sizeof(*d8c); - printf("\t\tDev Type=%#x Id=%#06x Handle=%#x " - "Variety=%d(%s)", - d8c->Header.Type, d8c->UsedId, d8c->Handle, - d8c->Variety, - acpi_handle_ivrs_ivhd_variety(d8c->Variety)); - acpi_handle_ivrs_ivhd_dte(d8c->Header.DataSetting); - } else if (d->Type == ACPI_IVRS_TYPE_HID) { - dh = (ACPI_IVRS_DEVICE_HID *)db; - len = sizeof(*dh) + dh->UidLength; - printf("\t\tDev Type=%#x Id=%#06x HID=", - dh->Header.Type, dh->Header.Id); - acpi_print_string((char *)&dh->AcpiHid, - sizeof(dh->AcpiHid)); - printf(" CID="); - acpi_print_string((char *)&dh->AcpiCid, - sizeof(dh->AcpiCid)); - printf(" UID="); - switch (dh->UidType) { - case ACPI_IVRS_UID_NOT_PRESENT: - default: - printf("none"); - break; - case ACPI_IVRS_UID_IS_INTEGER: - memcpy(&x32, dh + 1, sizeof(x32)); - printf("%#x", x32); - break; - case ACPI_IVRS_UID_IS_STRING: - acpi_print_string((char *)(dh + 1), - dh->UidLength); - break; - } - acpi_handle_ivrs_ivhd_dte(dh->Header.DataSetting); - } else { - printf("\t\tDev Type=%#x Unknown\n", d->Type); - if (d->Type <= 63) - len = sizeof(*d4); - else if (d->Type <= 127) - len = sizeof(*d8a); - else { - printf("Abort, cannot advance iterator.\n"); - return; - } - } - } -} - -static void -acpi_handle_ivrs_ivhd_10(ACPI_IVRS_HARDWARE1 *addr, bool efrsup) -{ - acpi_handle_ivrs_ivhd_header(&addr->Header); - printf("\tCapOffset=%#x Base=%#jx PCISeg=%#x Unit=%#x MSIlog=%d\n", - addr->CapabilityOffset, (uintmax_t)addr->BaseAddress, - addr->PciSegmentGroup, (addr->Info & ACPI_IVHD_UNIT_ID_MASK) >> 8, - addr->Info & ACPI_IVHD_MSI_NUMBER_MASK); - if (efrsup) { -#define PRINTFLAG(flag, name) printflag(addr->FeatureReporting, flag, #name) -#define PRINTFIELD(lbit, hbit, name) \ - printfield(addr->FeatureReporting, lbit, hbit, #name) - PRINTFIELD(30, 31, HATS); - PRINTFIELD(28, 29, GATS); - PRINTFIELD(23, 27, MsiNumPPR); - PRINTFIELD(17, 22, PNBanks); - PRINTFIELD(13, 16, PNCounters); - PRINTFIELD(8, 12, PASmax); - PRINTFLAG(1 << 7, HESup); - PRINTFLAG(1 << 6, GASup); - PRINTFLAG(1 << 5, UASup); - PRINTFIELD(3, 2, GLXSup); - PRINTFLAG(1 << 1, NXSup); - PRINTFLAG(1 << 0, XTSup); -#undef PRINTFLAG -#undef PRINTFIELD - PRINTFLAG_END(); - } - acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), - (char *)addr + addr->Header.Length); -} - -static void -acpi_handle_ivrs_ivhd_info_11(ACPI_IVRS_HARDWARE2 *addr) -{ - acpi_handle_ivrs_ivhd_header(&addr->Header); - printf("\tCapOffset=%#x Base=%#jx PCISeg=%#x Unit=%#x MSIlog=%d\n", - addr->CapabilityOffset, (uintmax_t)addr->BaseAddress, - addr->PciSegmentGroup, (addr->Info >> 8) & 0x1f, - addr->Info & 0x5); - printf("\tAttr="); -#define PRINTFIELD(lbit, hbit, name) \ - printfield(addr->Attributes, lbit, hbit, #name) - PRINTFIELD(23, 27, MsiNumPPR); - PRINTFIELD(17, 22, PNBanks); - PRINTFIELD(13, 16, PNCounters); -#undef PRINTFIELD - PRINTFLAG_END(); -} - -static void -acpi_handle_ivrs_ivhd_11(ACPI_IVRS_HARDWARE2 *addr) -{ - acpi_handle_ivrs_ivhd_info_11(addr); - printf("\tEFRreg=%#018jx\n", (uintmax_t)addr->EfrRegisterImage); - acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), - (char *)addr + addr->Header.Length); -} - -static void -acpi_handle_ivrs_ivhd_40(ACPI_IVRS_HARDWARE2 *addr) -{ - acpi_handle_ivrs_ivhd_info_11(addr); - printf("\tEFRreg=%#018jx EFR2reg=%#018jx\n", - (uintmax_t)addr->EfrRegisterImage, (uintmax_t)addr->Reserved); - acpi_handle_ivrs_ivhd_devs((ACPI_IVRS_DE_HEADER *)(addr + 1), - (char *)addr + addr->Header.Length); -} - -static const char * -acpi_handle_ivrs_ivmd_type(ACPI_IVRS_MEMORY *addr) -{ - switch (addr->Header.Type) { - case ACPI_IVRS_TYPE_MEMORY1: - return ("ALL"); - case ACPI_IVRS_TYPE_MEMORY2: - return ("specified"); - case ACPI_IVRS_TYPE_MEMORY3: - return ("range"); - default: - return ("unknown"); - } -} - -static void -acpi_handle_ivrs_ivmd(ACPI_IVRS_MEMORY *addr) -{ - printf("\tMem Type=%#x(%s) ", - addr->Header.Type, acpi_handle_ivrs_ivmd_type(addr)); - switch (addr->Header.Type) { - case ACPI_IVRS_TYPE_MEMORY2: - printf("Id=%#06x PCISeg=%#x ", addr->Header.DeviceId, - *(UINT16 *)&addr->Reserved); - break; - case ACPI_IVRS_TYPE_MEMORY3: - printf("Id=%#06x-%#06x PCISeg=%#x", addr->Header.DeviceId, - addr->AuxData, *(UINT16 *)&addr->Reserved); - break; - } - printf("Start=%#18jx Length=%#jx Flags=", - (uintmax_t)addr->StartAddress, (uintmax_t)addr->MemoryLength); -#define PRINTFLAG(flag, name) printflag(addr->Header.Flags, flag, #name) - PRINTFLAG(ACPI_IVMD_EXCLUSION_RANGE, ExclusionRange); - PRINTFLAG(ACPI_IVMD_WRITE, IW); - PRINTFLAG(ACPI_IVMD_READ, IR); - PRINTFLAG(ACPI_IVMD_UNITY, Unity); -#undef PRINTFLAG - PRINTFLAG_END(); -} - -static int -acpi_handle_ivrs_blocks(void *addr, int remaining, bool efrsup) -{ - ACPI_IVRS_HEADER *hdr = addr; - - if (remaining < (int)sizeof(ACPI_IVRS_HEADER)) - return (-1); - - if (remaining < hdr->Length) - return (-1); - - switch (hdr->Type) { - case ACPI_IVRS_TYPE_HARDWARE1: - acpi_handle_ivrs_ivhd_10(addr, efrsup); - break; - case ACPI_IVRS_TYPE_HARDWARE2: - if (!efrsup) - printf("\t!! Found IVHD block 0x11 but !EFRsup\n"); - acpi_handle_ivrs_ivhd_11(addr); - break; - case ACPI_IVRS_TYPE_HARDWARE3: - if (!efrsup) - printf("\t!! Found IVHD block 0x40 but !EFRsup\n"); - acpi_handle_ivrs_ivhd_40(addr); - break; - case ACPI_IVRS_TYPE_MEMORY1: - case ACPI_IVRS_TYPE_MEMORY2: - case ACPI_IVRS_TYPE_MEMORY3: - acpi_handle_ivrs_ivmd(addr); - break; - default: - printf("\n"); - printf("\tType=%d\n", hdr->Type); - printf("\tLength=%d\n", hdr->Length); - break; - } - return (hdr->Length); -} - -#define ACPI_IVRS_DMAREMAP 0x00000002 -#define ACPI_IVRS_EFRSUP 0x00000001 -#define ACPI_IVRS_GVA_SIZE 0x000000e0 - -static void -acpi_handle_ivrs(ACPI_TABLE_HEADER *sdp) -{ - ACPI_TABLE_IVRS *ivrs; - char *cp; - int remaining, consumed; - bool efrsup; - - printf(BEGIN_COMMENT); - acpi_print_sdt(sdp); - ivrs = (ACPI_TABLE_IVRS *)sdp; - efrsup = (ivrs->Info & ACPI_IVRS_EFRSUP) != 0; - printf("\tVAsize=%d PAsize=%d GVAsize=%d\n", - (ivrs->Info & ACPI_IVRS_VIRTUAL_SIZE) >> 15, - (ivrs->Info & ACPI_IVRS_PHYSICAL_SIZE) >> 8, - (ivrs->Info & ACPI_IVRS_GVA_SIZE) >> 5); - printf("\tATS_resp_res=%d DMA_preboot_remap=%d EFRsup=%d\n", - (ivrs->Info & ACPI_IVRS_ATS_RESERVED) != 0, - (ivrs->Info & ACPI_IVRS_DMAREMAP) != 0, efrsup); - - remaining = sdp->Length - sizeof(ACPI_TABLE_IVRS); - while (remaining > 0) { - cp = (char *)sdp + sdp->Length - remaining; - consumed = acpi_handle_ivrs_blocks(cp, remaining, efrsup); - if (consumed <= 0) - break; - else - remaining -= consumed; - } - - printf(END_COMMENT); -} - static void acpi_print_srat_memory(ACPI_SRAT_MEM_AFFINITY *mp) { @@ -2460,8 +2074,6 @@ acpi_handle_rsdt(ACPI_TABLE_HEADER *rsdp) acpi_handle_tcpa(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_DMAR, 4)) acpi_handle_dmar(sdp); - else if (!memcmp(sdp->Signature, ACPI_SIG_IVRS, 4)) - acpi_handle_ivrs(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_NFIT, 4)) acpi_handle_nfit(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_WDDT, 4)) From nobody Wed Apr 17 13:39:43 2024 X-Original-To: dev-commits-src-branches@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 4VKMTW5YSXz5Gvn9; Wed, 17 Apr 2024 13:39:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMTW4ljDz4kpB; Wed, 17 Apr 2024 13:39:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361183; 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=CcpqgmJYqCezuoNB+goGl6cbhzcVUWPaEUoZhczllg4=; b=xEhcbNSNnyUVEfwhV0mKcudxizx3GsvMZCZ3+OrD786GtH9YKirGWhkwux6VYVYbMsSLpP V5GO1i88ufvXfE3MbvmkmD/QF3CLsDG5EO9XMcVDizr5aiNRB49cOF5JQu8j7jOz9j8zl8 wtcwv1FJBEG/s1gNSLoJPQ6eg+XqzKJQA5oHd2LQnmlPteQ1t6Az1SDYPxceB4ugscF1Kc U9yz3ibiP/BEh62N+9sn9/bsD1rXUDnJTmtX5FLrynJQ/VCCCJRhhz7UrO7ANhvKR+Z/kg 5BUhFzK6/cSf9kptBrdBxdpi01MFJQOjGsbOW2pm64LMQ+hDD4Fr2GwF4s9MUQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361183; a=rsa-sha256; cv=none; b=WHu0EToFvZ+34QZJqSYjZvc43bc2c5nB5YTOhGJ27c1ZtB8iDCotq7fhEtvHZlSoVA1Uea WRudV1aZPj6ZZ7xZmVXp1eAB0tx6Xm7MaViviIhgP+sVS06fDjvKXNJ2g3BGTHrH259odt FMnNEcUhEybSTX6OdmTMNo1q/ZfV0o9OhgIk3Pu5PmIa1nhlX9hGuuU7LgxCTWxRdZJ1At M5vyZLrroqGYczLgOILI7Hk3uJKviCLbJxc2D2K81NWBStjaCsTbT2kpb9lBp8G9x83at/ GQ8HhoNYuobH7WR07sUrFSmUWglYuSDXSqyUgRUtyWcOfJCmmmiQXzV1vr22DQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361183; 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=CcpqgmJYqCezuoNB+goGl6cbhzcVUWPaEUoZhczllg4=; b=LLD7IUTQqzC/F69sXOKbAW/M5JbM09z5RgqtJZrsdw661GfSXovoF3H2quIDGV5ZwtB32b X4ub7ZgmIzjh3iQRtv1aEsbJZ0Nep5bPquB9ZMEvIoWD+613ykF1sHA/hortZzezjbCODJ GAMZt/KUJAvUK07xCOhNGagRAoehSAc0vukl6Cx1wgwVQb0Y3F1jaAQySan1eTBM0KtWQl jxrb98niKLHiOvwiubL35pwtVkg6BGQ3OWGh73Ghjg5OWijZ56B6oAauXxDbE42Wg8q4Nk X00j1iVbN0fV6byvb3Rb81OSfiZvPVkIN6H3xo7cqFDCYvp5L+cSpkjmPSWvtA== 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 4VKMTW4LBszT9b; Wed, 17 Apr 2024 13:39:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDdhuV002341; Wed, 17 Apr 2024 13:39:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDdhxQ002338; Wed, 17 Apr 2024 13:39:43 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:39:43 GMT Message-Id: <202404171339.43HDdhxQ002338@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Motin Subject: git: e48f7ff6a12c - stable/14 - ahc/ahd: Fix target mode operation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mav X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e48f7ff6a12c591b9b1d83abfcd46934b73c90fb Auto-Submitted: auto-generated The branch stable/14 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=e48f7ff6a12c591b9b1d83abfcd46934b73c90fb commit e48f7ff6a12c591b9b1d83abfcd46934b73c90fb Author: Alexander Motin AuthorDate: 2024-04-10 20:44:00 +0000 Commit: Alexander Motin CommitDate: 2024-04-17 13:39:37 +0000 ahc/ahd: Fix target mode operation After 5e63cdb457f9 the drivers didn't clear CAM_DIS_DISCONNECT in ah*_handle_target_cmd() when needed, only set it. Reported/tested by: HP van Braam MFC after: 1 week (cherry picked from commit f1e4c095777db088645008848b3bfb87146c13ec) --- sys/dev/aic7xxx/aic79xx.c | 3 +++ sys/dev/aic7xxx/aic7xxx.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/sys/dev/aic7xxx/aic79xx.c b/sys/dev/aic7xxx/aic79xx.c index 116418dda25f..58b795a9d4ce 100644 --- a/sys/dev/aic7xxx/aic79xx.c +++ b/sys/dev/aic7xxx/aic79xx.c @@ -10317,7 +10317,10 @@ ahd_handle_target_cmd(struct ahd_softc *ahd, struct target_cmd *cmd) ahd->pending_device = lstate; ahd_freeze_ccb((union ccb *)atio); atio->ccb_h.flags |= CAM_DIS_DISCONNECT; + } else { + atio->ccb_h.flags &= ~CAM_DIS_DISCONNECT; } + xpt_done((union ccb*)atio); return (0); } diff --git a/sys/dev/aic7xxx/aic7xxx.c b/sys/dev/aic7xxx/aic7xxx.c index 4b62f76b9cf8..9934fbcc41bb 100644 --- a/sys/dev/aic7xxx/aic7xxx.c +++ b/sys/dev/aic7xxx/aic7xxx.c @@ -7843,7 +7843,10 @@ ahc_handle_target_cmd(struct ahc_softc *ahc, struct target_cmd *cmd) ahc->pending_device = lstate; aic_freeze_ccb((union ccb *)atio); atio->ccb_h.flags |= CAM_DIS_DISCONNECT; + } else { + atio->ccb_h.flags &= ~CAM_DIS_DISCONNECT; } + xpt_done((union ccb*)atio); return (0); } From nobody Wed Apr 17 13:40:19 2024 X-Original-To: dev-commits-src-branches@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 4VKMVC6WrPz5Gvvx; Wed, 17 Apr 2024 13:40:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMVC5hffz4l5r; Wed, 17 Apr 2024 13:40:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361219; 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=Lz7Kkq4TXOkxFAI1Otk2HKVLs6CLEP/a+qVUbNN5fyw=; b=D6jFibkHABaGAkEL6PQQ6S2o8YPhaw5UBT/JAD9vaqhqUc+/hJBQeDNoFEeZmff10escPo Tl4ox/Gbrg8YxZBHYnemRpqgM5gwfHh48DbWvg2gidUWWAZ3ovwSyCgt87hJ8XfyLi1zgp JyC0Jw/fMPjUjuM2F31X2K3NeJCtrUdVy+MJP8MAe7kI/44NcHW5HO36AFo+k5jUf9MbgX qChzHuPn6G7w43uTScTEdQIVHGzeAE5DWDloaFsCQgqw6uRS/qBn+mDmy6WCtOug+3V2IO ddK2+HbvvYtKOkRJaBo/rDtMno1oevEB7Ht9+1eHpyyEg9G9w5f2g28o8E5ygA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361219; a=rsa-sha256; cv=none; b=X9oKhnl5rd0wDl6qzs3ayk0aHoKkJrN8nJ0HtHp0afTks2Hpu8Qf/mz+Igl7+sSOHtq7Ja MAqNYyjZU6Pt49H7MVs+d4Vp3G0As8HXErc2elVIE5pZj7X9XCHtZO6RNRkMh81AKw9bDo wKNSudSzIqjb0i0orBEuFhxiXhyoTLqCnP5KebjAB8R2FMSaSQQze9vEXWatUy+S2rXAYr +a6WpCB67M5c69kNTWG0nCOTacJU7yS76QCVc0MI94HDhND3jt4QyVoD0hSrjurlCGaQzK Y6C+V1jfMe+m209kowNB/fwv9KRpwFrE/oZrfuQxeGZUyXEKsIGg/3hM70kgUw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361219; 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=Lz7Kkq4TXOkxFAI1Otk2HKVLs6CLEP/a+qVUbNN5fyw=; b=nGt8NXjK1ItbXk64WGEiyMi1rGma7tXts2/cWy1VEOdd7iHO9DUdM88Iis5tUWJ1Xzk4ad m8b4Op7dps+V/i278nDut1CkkTwtM0YDfIMBwnoQCUcxwfC9NIfWOW8630rAMXB/s0lEYl jHNh6uoF3k/Woq2i2Fp7a/rtvjLIfCJuG9FhhO3MYhc9YLvVAbeq5eNL3dInOeYBYEoaBZ A5PV8BW2nmErH0GQ1/qacQr1cDbbQoTSzt2j1PxA0JEvA8SzonQ2LyG0jtFbvMe2pvh12L CHYqAMEeOonwG4+/PnY6QlvcyHR0HPrf0CBUzyLNWVdpqkWmVkfssYtOdmeA8A== 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 4VKMVC5HHbzSrT; Wed, 17 Apr 2024 13:40:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDeJUp011109; Wed, 17 Apr 2024 13:40:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDeJh5011106; Wed, 17 Apr 2024 13:40:19 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:40:19 GMT Message-Id: <202404171340.43HDeJh5011106@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Motin Subject: git: 4bb54e8ec3d0 - stable/13 - ahc/ahd: Fix target mode operation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mav X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4bb54e8ec3d002b0bb822b6ca8b5ac44d9ee649d Auto-Submitted: auto-generated The branch stable/13 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=4bb54e8ec3d002b0bb822b6ca8b5ac44d9ee649d commit 4bb54e8ec3d002b0bb822b6ca8b5ac44d9ee649d Author: Alexander Motin AuthorDate: 2024-04-10 20:44:00 +0000 Commit: Alexander Motin CommitDate: 2024-04-17 13:40:06 +0000 ahc/ahd: Fix target mode operation After 5e63cdb457f9 the drivers didn't clear CAM_DIS_DISCONNECT in ah*_handle_target_cmd() when needed, only set it. Reported/tested by: HP van Braam MFC after: 1 week (cherry picked from commit f1e4c095777db088645008848b3bfb87146c13ec) --- sys/dev/aic7xxx/aic79xx.c | 3 +++ sys/dev/aic7xxx/aic7xxx.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/sys/dev/aic7xxx/aic79xx.c b/sys/dev/aic7xxx/aic79xx.c index 795cf145c575..533271a4b51a 100644 --- a/sys/dev/aic7xxx/aic79xx.c +++ b/sys/dev/aic7xxx/aic79xx.c @@ -10326,7 +10326,10 @@ ahd_handle_target_cmd(struct ahd_softc *ahd, struct target_cmd *cmd) ahd->pending_device = lstate; ahd_freeze_ccb((union ccb *)atio); atio->ccb_h.flags |= CAM_DIS_DISCONNECT; + } else { + atio->ccb_h.flags &= ~CAM_DIS_DISCONNECT; } + xpt_done((union ccb*)atio); return (0); } diff --git a/sys/dev/aic7xxx/aic7xxx.c b/sys/dev/aic7xxx/aic7xxx.c index 68f189f5dd48..91bc68121067 100644 --- a/sys/dev/aic7xxx/aic7xxx.c +++ b/sys/dev/aic7xxx/aic7xxx.c @@ -7849,7 +7849,10 @@ ahc_handle_target_cmd(struct ahc_softc *ahc, struct target_cmd *cmd) ahc->pending_device = lstate; aic_freeze_ccb((union ccb *)atio); atio->ccb_h.flags |= CAM_DIS_DISCONNECT; + } else { + atio->ccb_h.flags &= ~CAM_DIS_DISCONNECT; } + xpt_done((union ccb*)atio); return (0); } From nobody Wed Apr 17 13:42:35 2024 X-Original-To: dev-commits-src-branches@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 4VKMXr1C2tz5Gw1m; Wed, 17 Apr 2024 13:42:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMXr053Nz4lTt; Wed, 17 Apr 2024 13:42:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361356; 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=p7Gulhys2xTgcQOMe//oHO5pMApjjz0PwD/1pOe3fH4=; b=Rz1bKwaThHKW2+kk4Lu1XHPEa31OnBysskRFF2ChYdz7DOkHdB7mCbBgpssLBfHv8cE87u kKcYXHnIWMKhnow3I59m0VlStFfVXcBF6lY/2y65oS9SrlPdHDpze4t/ShP5B6Gsk6lExq wW/EEOuS6hc5Dg5bbvnZJPjMoFSdunWdMnE2UViPIZeq62FSpU0Ci3LFxNYuUu1xIIn4Xz lbVV57aDnge2riZw43kEdZmowc9Y1tFGPeCKTt+GE5NA9YCSBnL/BHkQeDmFrvzSr1TsI8 XvhX5AQmq7xBV4HSgBuf90sSatrpKd5waHsqp4tMNSs/YerQzykX7DcYgl4ESQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361356; a=rsa-sha256; cv=none; b=H2H26swrVDu6DwqRfsUKIVOi7RAXaxYxD06i1ZV1suavhUiDGMiUNMYsOyuUrl1Dt5myzL em3FM8O6PkeFXxavieLCxmDCuU/gfzfXk1914rplPqxoFwyW09kbbg7VLGR+7vkLkdZ02g nXzE6RAucvm11lwOdJnAx4xEwAqwehdf9yNUIgcPQBTLcSgiOzYxnN97jRdyTAO3AVcVFw tQeTK0ililDtyxUPzZssh6dX7Lsm+82//nz5Mq73/SMl93rrP70CGkmXFYGx9tUbR1hkxC zqECy7gzj5mkMJBWtL7WwnIpMFD9NIO2o4dDr+y06frz49IElXFoLMPVO9k90A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361356; 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=p7Gulhys2xTgcQOMe//oHO5pMApjjz0PwD/1pOe3fH4=; b=bz2ZW6uOZSxtcTl28lSRwrVOunzxEGTAMFx1cCT3n6FzTK1XS/QXhwefmNdHT522gNdp4O 4Elafgu41gS/W2k/hx31E8QRotfupEvIbDI7k7dZoe2MWte7ikPPoTbb9lvoH7MaIu/UXW +eFYfQPXPUPvMLwDxzt3Q8jTpojxQIYs+J1KKcTJlNuhfXiWfVcZdmYT3TCVJT3QiyrCxQ COhqWLuHVqD/Osi9cRyAVd2v1rIx36R6C/qHpaIyg5Zo2qecHzMmzf+EdJiyICrLNcDAXj DR2WsjiehG8s4LCPZs1Ut6ZoJmczLp8BRxM8b47cctSdRoGfH6TKntuMIWCVsg== 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 4VKMXq6pkhzSq0; Wed, 17 Apr 2024 13:42:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDgZbt018928; Wed, 17 Apr 2024 13:42:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDgZ7n018925; Wed, 17 Apr 2024 13:42:35 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:42:35 GMT Message-Id: <202404171342.43HDgZ7n018925@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 2da45e304dba - stable/14 - TCP LRO: convert TCP header fields to host byte order earlier List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2da45e304dba8004f953206a6fdfc4f801478251 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=2da45e304dba8004f953206a6fdfc4f801478251 commit 2da45e304dba8004f953206a6fdfc4f801478251 Author: Michael Tuexen AuthorDate: 2024-01-29 17:41:24 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:42:13 +0000 TCP LRO: convert TCP header fields to host byte order earlier This is a preparation for adding dtrace hooks in a follow-up commit, which are missing in the code path, where packets are directly queued to the tcpcb. The dtrace hooks expect the fields to be in host byte order. This only applies when TCP HPTS is used. No functional change intended. Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D43594 (cherry picked from commit f30c7d56546b9f36e42351fb385d96e37dbac1d5) --- sys/netinet/tcp_lro_hpts.c | 7 ++++--- sys/netinet/tcp_stacks/rack_bbr_common.c | 4 ---- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/sys/netinet/tcp_lro_hpts.c b/sys/netinet/tcp_lro_hpts.c index 7724e727d5ce..84944c8db1ce 100644 --- a/sys/netinet/tcp_lro_hpts.c +++ b/sys/netinet/tcp_lro_hpts.c @@ -74,15 +74,15 @@ build_ack_entry(struct tcp_ackent *ae, struct tcphdr *th, struct mbuf *m, ae->flags |= TSTMP_LRO; else if (m->m_flags & M_TSTMP) ae->flags |= TSTMP_HDWR; - ae->seq = ntohl(th->th_seq); - ae->ack = ntohl(th->th_ack); + ae->seq = th->th_seq; + ae->ack = th->th_ack; ae->flags |= tcp_get_flags(th); if (ts_ptr != NULL) { ae->ts_value = ntohl(ts_ptr[1]); ae->ts_echo = ntohl(ts_ptr[2]); ae->flags |= HAS_TSTMP; } - ae->win = ntohs(th->th_win); + ae->win = th->th_win; ae->codepoint = iptos; } @@ -310,6 +310,7 @@ do_bpf_strip_and_compress(struct tcpcb *tp, struct lro_ctrl *lc, th = tcp_lro_get_th(m); th->th_sum = 0; /* TCP checksum is valid. */ + tcp_fields_to_host(th); /* Check if ACK can be compressed */ can_compress = tcp_lro_ack_valid(m, th, &ts_ptr, &other_opts); diff --git a/sys/netinet/tcp_stacks/rack_bbr_common.c b/sys/netinet/tcp_stacks/rack_bbr_common.c index b265e8e6f20b..4a4a8af2bd78 100644 --- a/sys/netinet/tcp_stacks/rack_bbr_common.c +++ b/sys/netinet/tcp_stacks/rack_bbr_common.c @@ -415,10 +415,6 @@ skip_vnet: break; #endif } /* end switch */ - /* - * Convert TCP protocol specific fields to host format. - */ - tcp_fields_to_host(th); off = th->th_off << 2; if (off < sizeof (struct tcphdr) || off > tlen) { printf("off:%d < hdrlen:%zu || > tlen:%u -- dump\n", From nobody Wed Apr 17 13:43:47 2024 X-Original-To: dev-commits-src-branches@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 4VKMZD2Xkwz5GwLR; Wed, 17 Apr 2024 13:43:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMZD17MQz4lWZ; Wed, 17 Apr 2024 13:43:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361428; 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=YAG55eUnI6rh5I62ymmP5UlS1T9bzKNBnmqi6/M681o=; b=p7bM/hzU0+x5IoCh8C5r+1M8Wph80WSwh4wSxJLuJ3zV2wq3MxPtVpkJ1+gF3ZgLjeLfp3 FO3GAdoo125sQCN7o5InXclFUB8YpfULASza8pkg47S0pvu6uX8aglX68O/YSvFUcRjBXv CkX/YrubM9SO4C/VASzrlVPBsNXoos6z98WPsdYREmpkM1z0d3kLNhIPVU5XCs6efcOQ8l 4g+GKIO6+hq17HTX+A1a54iNZgTKKr69yuoXUbQmTS17rXtZCcYaOIG9AWJ3varfHlmkna DV+wk+1Vnn2mXhocgtPXfXV/acpQJi5NIGzgMPCZr5tmMlQU7kTBqCssRs1rZw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361428; a=rsa-sha256; cv=none; b=bsyU5EhQsHRyDn2slhCc2k56tmjf/j+3tZql+SUiJyKZd6PJtZPE+gduFX2XhfuQeuQxxu EwxoOOxnMljyDXkaGNK6Lj5/j65yeDPiQ0FzKh1efrGGHyUSCrlGbuccSdMogj4whUcLoA Ky9o3JVUWY7duoT84B2V2vQswOKxztsfgFJZmVmX17LDGMmqjCFirHiwJSrXh6PdHkFiPr wpqhCEQhkoIcbi3tJ0B02YYwCGL4JdKYtXUKEtCDsQR3q2x/zpm0rMupCYVKr7EyLZInWu Ez7nVb2fxcReywh7jMZAZmIgNZYvaO1lW6PoVW2rQd3ZLefYb4fzOe2PLikIGw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361428; 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=YAG55eUnI6rh5I62ymmP5UlS1T9bzKNBnmqi6/M681o=; b=r0Ok1Xmofhr9ni9HDVyBc4UIQmsszCqzu/b2W4aSJIupIuPnCCcXG/iIZGHRy7craN26GS dszH87a9uOb8MpIqfSEJZVxB0ZSg4OJ3Eb9Ou/b7k3IqZYOtE7R9yiVcbZ6EPR9RrJdhqZ NjTNmZgH7l+JXcpu7AJSJKQTAU3hzpnqhcSE3Mrsi9pJ2g24mzxLbfWqP6I9djR5XB3K50 5iRYsgZHBBhrXxXDf54cOsIAWdZafEkyK2IE9eD0WeAU48ekB7MMj39itZaAon8qA+SK9G 611UZ05nyhWpwPDsBwOfEvcrA1xqdYr6yjaVoR63NW4vEHmYesYQhiSSNT9rDA== 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 4VKMZD0k0czSTV; Wed, 17 Apr 2024 13:43:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDhlmS019253; Wed, 17 Apr 2024 13:43:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDhlJ0019250; Wed, 17 Apr 2024 13:43:47 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:43:47 GMT Message-Id: <202404171343.43HDhlJ0019250@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 307daa4f1759 - stable/14 - vnic: fix compilation of an IPv6 only kernel List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 307daa4f1759ba93e618d09c6a4a0a869ad5fc27 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=307daa4f1759ba93e618d09c6a4a0a869ad5fc27 commit 307daa4f1759ba93e618d09c6a4a0a869ad5fc27 Author: Michael Tuexen AuthorDate: 2024-02-06 21:47:16 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:43:08 +0000 vnic: fix compilation of an IPv6 only kernel Sponsored by: Netflix, Inc. (cherry picked from commit 1d3d30c8d2e41052796c5bdd9220d7e3daabccad) --- sys/dev/vnic/nicvf_queues.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sys/dev/vnic/nicvf_queues.c b/sys/dev/vnic/nicvf_queues.c index 6b6a36317f63..45d6b54b18ed 100644 --- a/sys/dev/vnic/nicvf_queues.c +++ b/sys/dev/vnic/nicvf_queues.c @@ -1749,10 +1749,15 @@ nicvf_sq_add_hdr_subdesc(struct snd_queue *sq, int qentry, struct ether_vlan_header *eh; #ifdef INET struct ip *ip; +#endif +#if defined(INET6) || defined(INET) struct tcphdr *th; #endif +#ifdef INET + int iphlen; +#endif + int ehdrlen, poff, proto; uint16_t etype; - int ehdrlen, iphlen, poff, proto; nic = sq->nic; From nobody Wed Apr 17 13:45:10 2024 X-Original-To: dev-commits-src-branches@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 4VKMbp4wCcz5GwH3; Wed, 17 Apr 2024 13:45:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMbp4M4wz4mBs; Wed, 17 Apr 2024 13:45:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361510; 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=aavjf8C+2p+9cx+glt5DNABczm2KZq2rgkCUG9wv07k=; b=pJGcdUG98JP7T47X9T08bexsXhobPX/lwrSjitOvoctAS9+95L5MsyE/2WNf54TeFPkIPu trbs4Kot9JxET+yfmOUfowDq5zhUKuGLCYp8OUC5N+TxD1Eo1P7J5U5pTCVEZwe4HO3rdm FxiBLtZmKDKgG+Ot6WDm3n97+UI1FQeLCboyh0fPFioQXj+AnoS6S9Uqi89Yq4lebDeZMO 7SsiY17PsQbOO7OUz7EWzChX76l5rtzdk+E0bn+qW4h9TCGfwbXjfxbaolTnXblv66C8p6 nLXILh2JZGTLGKEqohKsB95L9/w1EhqUHN9PNL7Tf+aROyFwEwh8fQHTVsZHBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361510; a=rsa-sha256; cv=none; b=ebhHZVnxno1A1RgBTkAQujkv3j1ce5cLMBjjki+xerd576F3/+muYjBdP1Sa0J36J0kpOB 6juNiMFS+h3D5akd1Al4YH9bNagp64+1yY7hbUwHWirWurr2cw0J+E0IF2UQAJBehFoE+L GXYfiPW5QTdgNeLyns5gMXn5IK0w1Q4QelZFCqnTYXilohAH2R6SA94rckUsI00jmnMFrF XctfhVdZMINDeVrTqQvZbPSqCNgjSM5Y/4HdDzixdY2skax2WlCKuohIJ7oaaoGvil3L9c oqB2RoDSseYqfO9xZc6kJznEBnw1ZrIi6MEigFVeL0LrROGeJfFs7R8cq1pTWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361510; 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=aavjf8C+2p+9cx+glt5DNABczm2KZq2rgkCUG9wv07k=; b=A7eAZFL1vVWR5ihcvknWlc38ncKyn4P1pW9DKijMP0kS/cLiHqdkVGt+eewX0gF7WWCYSr hg7MAxZ0ByftDEdalaQJVv6fuGLz8sJ64bZepklrYgvyfQkDBHV20KfFigjlhnJwpujWCH E09dMyUQDkDMbUGiisLAEozhoit9/Jlh5T08S9fSmyQ5dDQIAr9AF/EUB3j6MrxbfsHcVp UrSOkpfV0K6mGFVrQbgA81dnjrOAaVR//OcB+9IAnL2XHgTxmhj1/CfbZwGoq+QJIy7rJ3 crQhP31Va3/UOvhktiORwV7NTETixE3U95QceyzYQUMVi+R95TtIG75mPn0oKg== 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 4VKMbp3zJkzTBP; Wed, 17 Apr 2024 13:45:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDjA5j019604; Wed, 17 Apr 2024 13:45:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDjAq3019601; Wed, 17 Apr 2024 13:45:10 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:45:10 GMT Message-Id: <202404171345.43HDjAq3019601@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 8b2c694d3836 - stable/14 - RACK, BBR: handle EACCES like EPERM for IP output handling List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8b2c694d383623a20edc7f64aaefcb28d06be9f6 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=8b2c694d383623a20edc7f64aaefcb28d06be9f6 commit 8b2c694d383623a20edc7f64aaefcb28d06be9f6 Author: Michael Tuexen AuthorDate: 2024-02-16 11:19:24 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:44:15 +0000 RACK, BBR: handle EACCES like EPERM for IP output handling The FreeBSD TCP base stack handles them also the same way. In case of packet filters dropping packets in the output path, this avoids retranmitting the dropped packet every 10ms or so. Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D43773 (cherry picked from commit 2f4e46dfdd710c6679f233480c9de430e6c4ef9b) --- sys/netinet/tcp_stacks/bbr.c | 1 + sys/netinet/tcp_stacks/rack.c | 1 + 2 files changed, 2 insertions(+) diff --git a/sys/netinet/tcp_stacks/bbr.c b/sys/netinet/tcp_stacks/bbr.c index c643f0321099..931beba7a262 100644 --- a/sys/netinet/tcp_stacks/bbr.c +++ b/sys/netinet/tcp_stacks/bbr.c @@ -13809,6 +13809,7 @@ nomore: return (error); } case EPERM: + case EACCES: tp->t_softerror = error; /* FALLTHROUGH */ case EHOSTDOWN: diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index 354c644bec18..c3460e48329f 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -22371,6 +22371,7 @@ nomore: sendalot = 0; switch (error) { case EPERM: + case EACCES: tp->t_softerror = error; #ifdef TCP_ACCOUNTING crtsc = get_cyclecount(); From nobody Wed Apr 17 13:46:10 2024 X-Original-To: dev-commits-src-branches@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 4VKMcy2PM4z5GwVq; Wed, 17 Apr 2024 13:46:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMcy1j17z4mQl; Wed, 17 Apr 2024 13:46:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361570; 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=Vm0MxyT20f6bsNJeV9iNDzTjLnuguHKkyJt2ZtD5Vx4=; b=vKJwjqQAhNS8CgR38XBHHtDpBOB6SjrJ10V9lJSnJKIu31hZWuyeB/FgE33V/s1aUqYLpB CG5vty7N/cWztOFzvoBWusKm7+plsnMJqR0wu83nKt5Yo882MoGkyIWCZyH7RKS7RU3Y+s fzlOBck4jk77+55dn0uu1guFJMeoE58n6AUOC9PXkvb7Ma0QHbP3qBlS5mcWOyg2hJGNXx w3wC6+nFpzCa6GI1e9/++nZWQcOaKnqI4IhuVlEWYaC1y1olA8xwBjWjahKbuPZv0dEqoK Aog3CriOryfVJ9t6ikRuNNrwBFI43iPAJzTb+UjeQK4kGY6HZMNDjGOHqtxfdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361570; a=rsa-sha256; cv=none; b=dRypsxKUluCDmYBYBkmS1Fwjfq8mnV7KxHvnJfF35OXRm1Zyx4P9jUOIWS1e/0JlOiIJ5t Uq8bHKYFCTFWV+dbGtG2tnNxKZipRhGtJEAhEfvcC9WQ3ApzOlRpQbR0t+KvywQr0p9lsC EbP7EN6n7l1BolHw3Vx/8t6nl1mW9phhWVECaKn0Tjw5A3l0I0QuK3SzogZ64VLeh0m2dg wDOgdFfIGsplgNec5GSw+nyCsvWWvijxXUrkqdUgZG0EV9r6x4gtlEbnPgEm3ai/J7tgsp b8NqR0CnZaPYpcN/lY8xLhMo25cROwsDKkJ8k7C+eyu/QiemJVlMOTJzLxqdzA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361570; 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=Vm0MxyT20f6bsNJeV9iNDzTjLnuguHKkyJt2ZtD5Vx4=; b=Xq+CLBEImVwxUIdcK2v6oO13RWZPFAhWrmS3T30X/FcHAkx/7sd0sBxP12k72lD0FXUBTV JH4ldjBsesgtZG4zVrMaFqg9KO+MBWm6lfUsh+CqzNdyRpCSKPOY35J2WuZBR2pgxyvdiW 8uXKyGa4yHT3sT5YSDqNiqMhWWiPz9pKsoQQFU2xBEiP69Ll5i6C4S073TOulX4OuVU90i o0S3CtsBAmB9CSfbp3uxY7Zx844Pl/wd2zONyAKaKNNW1ttHjzDMQLY0rPcTzW22pPBo5e ummZKjeUuzGQBUTcjjArs2XixgNOGasoTVW3iusw8clGuqSmP98Oy0fYYZ+eXA== 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 4VKMcy1J4BzSq2; Wed, 17 Apr 2024 13:46:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDkAMP019870; Wed, 17 Apr 2024 13:46:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDkATp019867; Wed, 17 Apr 2024 13:46:10 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:46:10 GMT Message-Id: <202404171346.43HDkATp019867@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: c5e78e553c66 - stable/14 - dtrace: allow NULL interface pointer for ifinfo_t translator List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c5e78e553c6638fb24e7186690056fac9d78b2c9 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=c5e78e553c6638fb24e7186690056fac9d78b2c9 commit c5e78e553c6638fb24e7186690056fac9d78b2c9 Author: Michael Tuexen AuthorDate: 2024-02-16 11:28:48 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:45:40 +0000 dtrace: allow NULL interface pointer for ifinfo_t translator This is similar to other translators and will be used in static probes where the interface is not known. Reviewed by: markj Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D43728 (cherry picked from commit e00fd24262945fdc7f16198c8abd977f743e66e4) --- cddl/lib/libdtrace/ip.d | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cddl/lib/libdtrace/ip.d b/cddl/lib/libdtrace/ip.d index 172d7d54bc36..2fe98858efc2 100644 --- a/cddl/lib/libdtrace/ip.d +++ b/cddl/lib/libdtrace/ip.d @@ -262,8 +262,8 @@ inline int IFF_LOOPBACK = 0x8; #pragma D binding "1.5" translator translator ifinfo_t < struct ifnet *p > { - if_name = p->if_xname; - if_local = (p->if_flags & IFF_LOOPBACK) == 0 ? 0 : 1; + if_name = p == NULL ? "" : p->if_xname; + if_local = p == NULL ? 0 : (p->if_flags & IFF_LOOPBACK) == 0 ? 0 : 1; if_addr = (uintptr_t)p; }; From nobody Wed Apr 17 13:46:53 2024 X-Original-To: dev-commits-src-branches@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 4VKMdn2p74z5GwVy; Wed, 17 Apr 2024 13:46:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMdn2KChz4mb6; Wed, 17 Apr 2024 13:46:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361613; 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=6JYU56md1e/tUHjorehIi65K6HEJb2S/bZAngb+luWQ=; b=Phw2mF/ifbpkPgwZbTr9jXuFddXOJwAzp95+Qigzd8g0n08bYJ0LCIpKyjm9ztpiQtZoRE fQlkPnrVEAOidZWEAQkmqDZGrgq2eqO1i4MnxuIC8F6LYgqRX0QR3uAhktq2/6dujSoRb/ bsT4TcLGPsqlIihQGN133lKO98mAyRq4hEN3UsC6x0Gq5gd1Ki37XkWPSV/8chddWJmrBo fjhSFlEiSrLP40BL3iAIzJyPfCF8gYZ1PCHCjd72edMeySTvkW7dFShGgbBEdTa1j1FNLo 63DUEP5McvUAEL9Izax5eiYx+a+9Ql7X/8KVmIQlyxMpC5Bbc+NWiNkodt6N8Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361613; a=rsa-sha256; cv=none; b=kzCzuzeFpxS67HWj14p2DgheRAfDeDMXMe5bqNuEeqXb7yJ6EbR7+kLuucpZbGaCxc13pc bGALw5vdY8bR4askyfDL1F5Gd0vAJl+LFZx9kZiXODZyfXSRDRsFMLTET0Q1EYtEQvihtw 5IZBAYe+1FZPoIHfJ4b6CO01brxMlzqfApOt/WGJEC4UTXYyU7T7usLb1w0W0APN5hgeiQ jQLOAj9vof5y9+Ti5vG8YsCEZRexUGifvFEkrOskgc/k6cylHTmtQYe2JcJEwPILUatps6 /pRHgk/eZyEkk9jZeCIBtk1on8Py+AAAI0WasrCPl4wHYbEKOv2SGTrdolrcjg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361613; 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=6JYU56md1e/tUHjorehIi65K6HEJb2S/bZAngb+luWQ=; b=Mdtdk6r86NOj6NsVm1p5x4aNyA8hK5o0tWJlGFsD4NQXEdQhItVZ+Dgs+hkG62gEp7Uf+B paeZF817gYYKpv9nIE817ZZKSMkH3nv2Z13XlA2QRGURWopFMeOcAIA8lrnocrUtJ4Nbfm YZeweK9b7+4r6TylDiv64lG1S13CPqVyWfsEygNolslN7OKaAb1YKBQ+n43Bv1BcHWn7SQ IdG5077Tc6V7W+pBUL7xAd+f5bDKL2ZnbEzM+vAQaQzzP8tL4zVvRdpyVnwIdrwHHYwLDK C9m/XjkE3QjQkTWN4t5Ctrstx5/25W/ljTJexnLR7eGzzJnpOdlpqTMo6lPPiQ== 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 4VKMdn1wr8zSmp; Wed, 17 Apr 2024 13:46:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDkreT020065; Wed, 17 Apr 2024 13:46:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDkrHO020062; Wed, 17 Apr 2024 13:46:53 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:46:53 GMT Message-Id: <202404171346.43HDkrHO020062@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 49557689bf1e - stable/14 - sctp: improve consistency List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 49557689bf1e0297377eac8b42e191a439291f57 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=49557689bf1e0297377eac8b42e191a439291f57 commit 49557689bf1e0297377eac8b42e191a439291f57 Author: Michael Tuexen AuthorDate: 2024-02-23 20:40:46 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:46:32 +0000 sctp: improve consistency (cherry picked from commit 533faf21c19d0fa4bc3c0a986c67667991f90883) --- sys/netinet/sctp_output.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/netinet/sctp_output.c b/sys/netinet/sctp_output.c index d7742222a3bf..c988a8426fe8 100644 --- a/sys/netinet/sctp_output.c +++ b/sys/netinet/sctp_output.c @@ -5039,11 +5039,16 @@ sctp_arethere_unrecognized_parameters(struct mbuf *in_initpkt, at += padded_size; break; case SCTP_HAS_NAT_SUPPORT: + if (padded_size != sizeof(struct sctp_paramhdr)) { + SCTPDBG(SCTP_DEBUG_OUTPUT1, "Invalid size - error nat support %d\n", plen); + goto invalid_size; + } *nat_friendly = 1; - /* FALLTHROUGH */ + at += padded_size; + break; case SCTP_PRSCTP_SUPPORTED: if (padded_size != sizeof(struct sctp_paramhdr)) { - SCTPDBG(SCTP_DEBUG_OUTPUT1, "Invalid size - error prsctp/nat support %d\n", plen); + SCTPDBG(SCTP_DEBUG_OUTPUT1, "Invalid size - error prsctp %d\n", plen); goto invalid_size; } at += padded_size; From nobody Wed Apr 17 13:47:41 2024 X-Original-To: dev-commits-src-branches@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 4VKMfj2xtCz5Gwdt; Wed, 17 Apr 2024 13:47:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMfj2BPkz4n4F; Wed, 17 Apr 2024 13:47:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361661; 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=iaqmVMmDEm/SRsSxD0pps4wovWbpNYVaXYcIJJVyxdE=; b=pUEdn1tr+bDYqKY9Khhf4BNWaUO2O5xkl5xUOO37Gk6W8l3H63z9TmvsYF3fs3uF2sgqpG yu/E2p2JGz/bpVDxEQvnZJ2hk9tSKt0ic7AUO2Wno8Q2CAmKdJGjx5Swo014lY0lM8id5+ 2aL3ObcWR1hx/TXJswAO83hr8nRYwK4h4amdbNgZCmcu6ctRDnVc8TaEgJWCeVKCeRIYJJ E2RfXCrIbEB6bumLtqKuyuQOz3403vl4/reHUsmfIRbPZgX1wHk8/Hv2xmKD4RGzH9JZei Q3Ws8i1RQ7NmAS+5dTDWsNsnFmkzVuXEC5VhlfLmaNSM4X4pzSYtz7aYOsVoLg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361661; a=rsa-sha256; cv=none; b=Y0fD/ZxnJl1XExzG1TDW3H00dYI3q1mO2yw1IhOLYwPDpHdQCUXWa5PcG5qHfdu2aYin2T TtMgyXRj4NTutYYAFZ7aPm75vWksShF6q8l606WUNZAzWeFsBKgaoyYoqbqg6JbhXMa+rw oE8ViSEOO+z0Rhup0MIYhlISBxgQOXo9EBPVJ7+hEOYP/xSX70to1oD6vwAlv2tMTGJ8/6 oP+6V118cRdo5eLccEAMsyzX4ga/1ZgXAsnDllGRSbYEjp2Nw/YuHQATGOsDRp5LxVWcs5 iSe3g4kxjfC9HHO2lccYILn7ejv21HwnqGfyN0UQYMOamvpkYP9NBsGSCoHx0Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361661; 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=iaqmVMmDEm/SRsSxD0pps4wovWbpNYVaXYcIJJVyxdE=; b=AwhZvlXfbIaqvwgZ53fw+8AWJkgu/BSViJmT4so7kArded1yFZdi82Lwcureb7YYusPPpo h+Mcv+UrkfBMtP3TtH0PI1ci8cnO16mfRwjvyfMR+hmhEu39ufk6FzXAuwdVSaYlpjX4jo HGPZeaWaAi6C14efSGXz7Mx/sgbx8lpsq+XGMkWX5DJXNqlqLt7Iw2UrVa1TtjZVhVqNwC eJXjAJ8uYZDTO5DwCAzhbr0Vg6wz7Ec/rglN+Vff2mx9++PxMpsK5NUYpB79mb9XHktjr0 yFRPfcQfWlVv3nDHyfcOxqJZ63mjaS6kDtoMjuMq045SbiGQyhBAiGRwpxfwZw== 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 4VKMfj1nkmzSyB; Wed, 17 Apr 2024 13:47:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDlfZO020344; Wed, 17 Apr 2024 13:47:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDlfmq020341; Wed, 17 Apr 2024 13:47:41 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:47:41 GMT Message-Id: <202404171347.43HDlfmq020341@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: be7586fe468f - stable/14 - sctp: improve sending of packets containing an INIT ACK chunk List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: be7586fe468f5c3afbe8fc413e160bb9626d0497 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=be7586fe468f5c3afbe8fc413e160bb9626d0497 commit be7586fe468f5c3afbe8fc413e160bb9626d0497 Author: Michael Tuexen AuthorDate: 2024-02-24 18:16:36 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:47:17 +0000 sctp: improve sending of packets containing an INIT ACK chunk If the peer announced support of zero checksums, do so when sending packets containing an INIT ACK chunk. (cherry picked from commit 644cffe67f61ad5b36b60d621d1c630ff2a50412) --- sys/netinet/sctp_input.c | 2 +- sys/netinet/sctp_output.c | 36 ++++++++++++++++++++++++++++++++---- sys/netinet/sctp_output.h | 4 +++- 3 files changed, 36 insertions(+), 6 deletions(-) diff --git a/sys/netinet/sctp_input.c b/sys/netinet/sctp_input.c index 6937f8a2a43f..a55ef5ac1eab 100644 --- a/sys/netinet/sctp_input.c +++ b/sys/netinet/sctp_input.c @@ -406,7 +406,7 @@ sctp_process_init_ack(struct mbuf *m, int iphlen, int offset, op_err = sctp_arethere_unrecognized_parameters(m, (offset + sizeof(struct sctp_init_chunk)), &abort_flag, (struct sctp_chunkhdr *)cp, - &nat_friendly, &cookie_found); + &nat_friendly, &cookie_found, NULL); if (abort_flag) { /* Send an abort and notify peer */ sctp_abort_association(stcb->sctp_ep, stcb, m, iphlen, diff --git a/sys/netinet/sctp_output.c b/sys/netinet/sctp_output.c index c988a8426fe8..a8facff6b917 100644 --- a/sys/netinet/sctp_output.c +++ b/sys/netinet/sctp_output.c @@ -4918,7 +4918,8 @@ sctp_arethere_unrecognized_parameters(struct mbuf *in_initpkt, int param_offset, int *abort_processing, struct sctp_chunkhdr *cp, int *nat_friendly, - int *cookie_found) + int *cookie_found, + uint32_t *edmid) { /* * Given a mbuf containing an INIT or INIT-ACK with the param_offset @@ -4934,8 +4935,8 @@ sctp_arethere_unrecognized_parameters(struct mbuf *in_initpkt, * hoped that this routine may be reused in the future by new * features. */ + struct sctp_zero_checksum_acceptable zero_chksum, *zero_chksum_p; struct sctp_paramhdr *phdr, params; - struct mbuf *mat, *m_tmp, *op_err, *op_err_last; int at, limit, pad_needed; uint16_t ptype, plen, padded_size; @@ -4944,6 +4945,9 @@ sctp_arethere_unrecognized_parameters(struct mbuf *in_initpkt, if (cookie_found != NULL) { *cookie_found = 0; } + if (edmid != NULL) { + *edmid = SCTP_EDMID_NONE; + } mat = in_initpkt; limit = ntohs(cp->chunk_length) - sizeof(struct sctp_init_chunk); at = param_offset; @@ -4999,6 +5003,22 @@ sctp_arethere_unrecognized_parameters(struct mbuf *in_initpkt, } at += padded_size; break; + case SCTP_ZERO_CHECKSUM_ACCEPTABLE: + if (padded_size != sizeof(struct sctp_zero_checksum_acceptable)) { + SCTPDBG(SCTP_DEBUG_OUTPUT1, "Invalid size - error checksum acceptable %d\n", plen); + goto invalid_size; + } + if (edmid != NULL) { + phdr = sctp_get_next_param(mat, at, + (struct sctp_paramhdr *)&zero_chksum, + sizeof(struct sctp_zero_checksum_acceptable)); + if (phdr != NULL) { + zero_chksum_p = (struct sctp_zero_checksum_acceptable *)phdr; + *edmid = ntohl(zero_chksum_p->edmid); + } + } + at += padded_size; + break; case SCTP_RANDOM: if (padded_size > (sizeof(struct sctp_auth_random) + SCTP_RANDOM_MAX_SIZE)) { SCTPDBG(SCTP_DEBUG_OUTPUT1, "Invalid size - error random %d\n", plen); @@ -5513,7 +5533,9 @@ sctp_send_initiate_ack(struct sctp_inpcb *inp, struct sctp_tcb *stcb, int nat_friendly = 0; int error; struct socket *so; + uint32_t edmid; uint16_t num_ext, chunk_len, padding_len, parameter_len; + bool use_zero_crc; if (stcb) { asoc = &stcb->asoc; @@ -5554,7 +5576,7 @@ sctp_send_initiate_ack(struct sctp_inpcb *inp, struct sctp_tcb *stcb, (offset + sizeof(struct sctp_init_chunk)), &abort_flag, (struct sctp_chunkhdr *)init_chk, - &nat_friendly, NULL); + &nat_friendly, NULL, &edmid); if (abort_flag) { do_a_abort: if (op_err == NULL) { @@ -6155,12 +6177,18 @@ do_a_abort: over_addr = NULL; } + if (asoc != NULL) { + use_zero_crc = (asoc->rcv_edmid != SCTP_EDMID_NONE) && (asoc->rcv_edmid == edmid); + } else { + use_zero_crc = (inp->rcv_edmid != SCTP_EDMID_NONE) && (inp->rcv_edmid == edmid); + } + if ((error = sctp_lowlevel_chunk_output(inp, NULL, NULL, to, m, 0, NULL, 0, 0, 0, 0, inp->sctp_lport, sh->src_port, init_chk->init.initiate_tag, port, over_addr, mflowtype, mflowid, - false, /* XXXMT: Improve this! */ + use_zero_crc, SCTP_SO_NOT_LOCKED))) { SCTPDBG(SCTP_DEBUG_OUTPUT4, "Gak send error %d\n", error); if (error == ENOBUFS) { diff --git a/sys/netinet/sctp_output.h b/sys/netinet/sctp_output.h index 1a1d17221b02..88c12367346a 100644 --- a/sys/netinet/sctp_output.h +++ b/sys/netinet/sctp_output.h @@ -80,7 +80,9 @@ sctp_send_initiate_ack(struct sctp_inpcb *, struct sctp_tcb *, struct mbuf * sctp_arethere_unrecognized_parameters(struct mbuf *, int, int *, - struct sctp_chunkhdr *, int *, int *); + struct sctp_chunkhdr *, int *, int *, + uint32_t *); + void sctp_queue_op_err(struct sctp_tcb *, struct mbuf *); int From nobody Wed Apr 17 13:48:25 2024 X-Original-To: dev-commits-src-branches@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 4VKMgY3Nvdz5Gwh8; Wed, 17 Apr 2024 13:48:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMgY2qTKz4nGG; Wed, 17 Apr 2024 13:48:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361705; 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=MEoZgiATbrtX0bHCSe4bQaNjCbe44zccI4hCx0xm9is=; b=HhZjnp8ajUvQh3xBRQR0zzvz8HT76l05MrfYpi+zOtgevZuYMNsVdCXSnkJGRNYZPfjqe3 mNRqhJY4BWz0ASG21qNpqF6SAKeAt9OZHhw3a2GEGH4OIIxRdH3mKBqhVRZ2sBhlGMRHhL HC8EzLAHrvvXzhiRt3mkB0cgPkQKqjJ6Q9LjKb8KXW+cMBTL58wtuKBIoCM8Xg25g/DUs3 fZFw7k+YFV1dDnVYK+ILGxdgltCxo+ybi5KpBKnzlvQIyCySe/f3gfTeCq4RXiZTWubtMB BZdCHqpja4QuC03aZs1b8AUtrKmILER3IoLVZbzfnim0ME8naPGj7Uw+SsOU0A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361705; a=rsa-sha256; cv=none; b=SlSlO+kBDe+F1Z2Vsu9F2+xhVR9cNv25QWQ89jkHcMoer6ZF1QjjS3xlek3gnExfQj2Xyr KwgAtmRNknS3ZxJySuXxVFb99NfQRQVj9kEXUH5oQUlw1Khwa/RHMYgB9+1Mw5cmq60Bmw aMLhCTAIcXrhHqszia3zpBKY6DoUIgUxGGn2muQfa3jWpyXDZp1cLemynkXelMgO6+2J1Y TB8JGygJXtcOVFtNr9sMzf3snuFy3bnVfjRRcpGRvl+DZ+GY0ei5WgardvTxHKFLweeR6k i5c+W8i9vukoCpQIWFiIUi/Z5KkOWZdq5ARKk0CrD8HgTi1tlA1GDI8uFAmmIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361705; 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=MEoZgiATbrtX0bHCSe4bQaNjCbe44zccI4hCx0xm9is=; b=HoNItNvOMypR8kPD8wUE+OaLM1zlyt2XiuK8cBaYRmxzMKe5qvQTFEAIWFtoi6k1xdYXGA Y3NayISgvzBTsO7ViNECw0v45OM3ef1SLf65SDit2Jd8yLL5gifEzc/th0g+w1S+PYykzc 0+IPuM91t/RFd9GTPspLbx+OrwX6cym61vL1jIlM+PmTNJjh6LOT4jZ9vvcmT3S2m9MABj PrZps8wa0MFIAr14yqko/o6sp8yK8fHJg3kpv+lyn9+qkwwBDN1l7mjN43UORrLjVq6Y2e +LOY4lTE5TAs9qXu2xcnPD4pyMFSc/Bcxh+WdT2rwkxVB2YOXZqyWJhGxO7Hig== 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 4VKMgY2RRTzSs4; Wed, 17 Apr 2024 13:48:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDmP22020611; Wed, 17 Apr 2024 13:48:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDmPDY020608; Wed, 17 Apr 2024 13:48:25 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:48:25 GMT Message-Id: <202404171348.43HDmPDY020608@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 8244b35ff88c - stable/14 - TCP LRO: disable mbuf queuing when packet filter hooks are in place List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8244b35ff88c65a28bfc03d8a8d5ce56b7a023ce Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=8244b35ff88c65a28bfc03d8a8d5ce56b7a023ce commit 8244b35ff88c65a28bfc03d8a8d5ce56b7a023ce Author: Michael Tuexen AuthorDate: 2024-03-08 09:03:43 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:48:01 +0000 TCP LRO: disable mbuf queuing when packet filter hooks are in place When doing mbuf queueing, the packet filter hooks in ether_demux(), ip_input(), and ip6_input() are by-passed. This means that the packet filters don't process incoming packets, which might result in connection failures. For example bypassing the TCP sequence number validation will result in dropping valid packets. Please note that this patch is only disabling mbuf queueing, not LRO. Reported by: Herbert J. Skuhra Reviewed by: glebius, rrs, rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D43769 (cherry picked from commit d1ce01214a5540db8a7e09fdf46b7ea2d06ffc48) --- sys/netinet/tcp_lro_hpts.c | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/sys/netinet/tcp_lro_hpts.c b/sys/netinet/tcp_lro_hpts.c index 84944c8db1ce..9c0d4be91d53 100644 --- a/sys/netinet/tcp_lro_hpts.c +++ b/sys/netinet/tcp_lro_hpts.c @@ -47,6 +47,7 @@ #include #include #include +#include #include #include @@ -54,6 +55,7 @@ #include #include #include +#include #include #include #include @@ -424,7 +426,7 @@ tcp_lro_lookup(struct ifnet *ifp, struct lro_parser *pa) { struct inpcb *inp; - CURVNET_SET(ifp->if_vnet); + CURVNET_ASSERT_SET(); switch (pa->data.lro_type) { #ifdef INET6 case LRO_TYPE_IPV6_TCP: @@ -449,10 +451,8 @@ tcp_lro_lookup(struct ifnet *ifp, struct lro_parser *pa) break; #endif default: - CURVNET_RESTORE(); return (NULL); } - CURVNET_RESTORE(); return (intotcpcb(inp)); } @@ -488,9 +488,28 @@ _tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) IN6_IS_ADDR_UNSPECIFIED(&le->inner.data.s_addr.v6))) return (TCP_LRO_CANNOT); #endif + + CURVNET_SET(lc->ifp->if_vnet); + /* + * Ensure that there are no packet filter hooks which would normally + * being triggered in ether_demux(), ip_input(), or ip6_input(). + */ + if ( +#ifdef INET + PFIL_HOOKED_IN(V_inet_pfil_head) || +#endif +#ifdef INET6 + PFIL_HOOKED_IN(V_inet6_pfil_head) || +#endif + PFIL_HOOKED_IN(V_link_pfil_head)) { + CURVNET_RESTORE(); + return (TCP_LRO_CANNOT); + } + /* Lookup inp, if any. Returns locked TCP inpcb. */ tp = tcp_lro_lookup(lc->ifp, (le->inner.data.lro_type == LRO_TYPE_NONE) ? &le->outer : &le->inner); + CURVNET_RESTORE(); if (tp == NULL) return (TCP_LRO_CANNOT); From nobody Wed Apr 17 13:49:04 2024 X-Original-To: dev-commits-src-branches@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 4VKMhK1N3Zz5Gwjj; Wed, 17 Apr 2024 13:49:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMhJ6DY5z4nTQ; Wed, 17 Apr 2024 13:49:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361744; 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=fg7q5jA3Q3ykD6N2fnY6V9JZOgkhf15ZLxFs5wkhVuc=; b=cG1CzvSwhjC6l+C4Rc3sZhwpqjeUkOUHpD/zUd7F/UMwJz63BrMtTABshWrsjV9pzmeUc4 ss0dsISOJD4JKdiEOnceKd7OOLBya5msb0E4g8Ij71AVKKuCpLmwq3Q0e+38VPFGOlqqZ4 tDDXPsoOekUyCNoYF70w/22WS4RaB2j3tEHew+4c+a1qScYn5AlPnj+WGzddnjrV8n+/TP kTdf72FtpTJQy7OwHhPEPjNK3sly4eWVXSHSVkzd2C+vJzjBJv1OiHDmmjb8P9rOpqbs/v 2mli1lIhDPtbrooLskHAJce29EP4RDhmTzEyrJlqSs9tHDHsD+MNKG2bSfP1CA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361744; a=rsa-sha256; cv=none; b=o0QusgjoDZXH2T2LUM3iITbz/5g8q1EYhHVljU6diwjmSYXLg9LjAFzyDUsSAD/MB6yyk3 xcacOPcRSPDvua7Zoq0jnUEBpjt32G5sd5YpKipYgpaEQKLCFawd7RNqQVx6yQtLu/4ANb E3fqKougWrgmwHPLA4iwjwfWSRNgNRyXug4HegDMByVFuu97RAvOj/kuCE/PbnTDXnfo8u jqBtiILY9HknIttoqo2IqSQnChwf0GYpTZopH5J0ywiCEcRXaxBIh9yY/2hobfrbQ8GHeB DDOL2q8n2jWhPy6g4/aVO3PEuT4VTtLBZttqCrbZmFhtN2EJNAOfL/lJJ2mZ5A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361744; 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=fg7q5jA3Q3ykD6N2fnY6V9JZOgkhf15ZLxFs5wkhVuc=; b=ycWec9dMYkNtlfPmfSq4QCPyOuiIrTsvCuZ94zvSKNaTte5DPG/4MfIpN2oQNJwu34N3TJ mu+20byua2KLVJEuQkCiCANxVELBZL16PpKwtB/2MoKKCvc38HuAV3WlzZaYAACJnZtve4 IUxkgB/YpMb698Ebka7zVc/N/6B/JhTyLN3bJ+wxaaco/eYn3fyFPfRL1qbbomc65i8UMj 6nLDCpuuJgLcHxdXsOzEhSrX8BsSeGc0CUT+pSU5DYVTz9deazY3cx+Bl9AHIADZyw4I1o gQ5AsF7dNT2OCNwKvLROoRZ72YCjnDLsyPU+y22MVgtZWLuTnQZFUnslJlNDkQ== 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 4VKMhJ5rdxzTPd; Wed, 17 Apr 2024 13:49:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDn4rx020838; Wed, 17 Apr 2024 13:49:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDn4ds020835; Wed, 17 Apr 2024 13:49:04 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:49:04 GMT Message-Id: <202404171349.43HDn4ds020835@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: d69099e4330e - stable/14 - TCP LRO: add dtrace probe points List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d69099e4330e1e2c4aa7349a3ab3f4ce47e8dc42 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=d69099e4330e1e2c4aa7349a3ab3f4ce47e8dc42 commit d69099e4330e1e2c4aa7349a3ab3f4ce47e8dc42 Author: Michael Tuexen AuthorDate: 2024-03-08 09:21:09 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:48:45 +0000 TCP LRO: add dtrace probe points Add the IP, UDP, and TCP receive static probes to the code path, which avoids if_input. Reviewed by: rrs, markj Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D43727 (cherry picked from commit 96ad640178ea0a8a9d1772687659dce5be18fbd9) --- sys/netinet/tcp_lro_hpts.c | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/sys/netinet/tcp_lro_hpts.c b/sys/netinet/tcp_lro_hpts.c index 9c0d4be91d53..cd757d5a6164 100644 --- a/sys/netinet/tcp_lro_hpts.c +++ b/sys/netinet/tcp_lro_hpts.c @@ -50,6 +50,7 @@ #include #include +#include #include #include #include @@ -281,22 +282,64 @@ do_bpf_strip_and_compress(struct tcpcb *tp, struct lro_ctrl *lc, case LRO_TYPE_IPV4_TCP: tcp_hdr_offset -= sizeof(*le->outer.ip4); m->m_pkthdr.lro_etype = ETHERTYPE_IP; + IP_PROBE(receive, NULL, NULL, le->outer.ip4, lc->ifp, + le->outer.ip4, NULL); break; case LRO_TYPE_IPV6_TCP: tcp_hdr_offset -= sizeof(*le->outer.ip6); m->m_pkthdr.lro_etype = ETHERTYPE_IPV6; + IP_PROBE(receive, NULL, NULL, le->outer.ip6, lc->ifp, + NULL, le->outer.ip6); break; default: goto compressed; } break; case LRO_TYPE_IPV4_TCP: + switch (le->outer.data.lro_type) { + case LRO_TYPE_IPV4_UDP: + IP_PROBE(receive, NULL, NULL, le->outer.ip4, lc->ifp, + le->outer.ip4, NULL); + UDP_PROBE(receive, NULL, NULL, le->outer.ip4, NULL, + le->outer.udp); + break; + case LRO_TYPE_IPV6_UDP: + IP_PROBE(receive, NULL, NULL, le->outer.ip6, lc->ifp, + NULL, le->outer.ip6); + UDP_PROBE(receive, NULL, NULL, le->outer.ip6, NULL, + le->outer.udp); + break; + default: + __assert_unreachable(); + break; + } tcp_hdr_offset -= sizeof(*le->outer.ip4); m->m_pkthdr.lro_etype = ETHERTYPE_IP; + IP_PROBE(receive, NULL, NULL, le->inner.ip4, NULL, + le->inner.ip4, NULL); break; case LRO_TYPE_IPV6_TCP: + switch (le->outer.data.lro_type) { + case LRO_TYPE_IPV4_UDP: + IP_PROBE(receive, NULL, NULL, le->outer.ip4, lc->ifp, + le->outer.ip4, NULL); + UDP_PROBE(receive, NULL, NULL, le->outer.ip4, NULL, + le->outer.udp); + break; + case LRO_TYPE_IPV6_UDP: + IP_PROBE(receive, NULL, NULL, le->outer.ip6, lc->ifp, + NULL, le->outer.ip6); + UDP_PROBE(receive, NULL, NULL, le->outer.ip6, NULL, + le->outer.udp); + break; + default: + __assert_unreachable(); + break; + } tcp_hdr_offset -= sizeof(*le->outer.ip6); m->m_pkthdr.lro_etype = ETHERTYPE_IPV6; + IP_PROBE(receive, NULL, NULL, le->inner.ip6, NULL, NULL, + le->inner.ip6); break; default: goto compressed; @@ -313,6 +356,7 @@ do_bpf_strip_and_compress(struct tcpcb *tp, struct lro_ctrl *lc, th->th_sum = 0; /* TCP checksum is valid. */ tcp_fields_to_host(th); + TCP_PROBE5(receive, NULL, tp, m, tp, th); /* Check if ACK can be compressed */ can_compress = tcp_lro_ack_valid(m, th, &ts_ptr, &other_opts); From nobody Wed Apr 17 13:50:27 2024 X-Original-To: dev-commits-src-branches@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 4VKMjw1hmnz5Gwnl; Wed, 17 Apr 2024 13:50:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMjv6dc1z4nvG; Wed, 17 Apr 2024 13:50:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361827; 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=yCPAOvGrx/w9XS8dhS0YKnufnI8ewCNsZzf5943FVBs=; b=oJ041vyGwEy2kqZ2STGng9yT8eGctgQlt0hvZmQmorGAS1ArtzzA9+7zWZ+mve116HTgkL OiiBRxojzdFgGMlrGj6GlWlnUoVw6estOsbkXuaHispwwVCKw01aHVOmt1MDTZw6kBC03H rs0DvcvkX74VRnc2xGqpbJYYyIkeIL68Y5xk1ReTAoUqPz4g534RSCXtJUGjuVKTEB4sqi 3iThC6im+S3nVKNlw3WgaehfM30F4oSHbgf6bkTb6oWIh250Isb/oqL6l9bvjgOmbplL4h /Qwl46zuaZZfeSV5edRD+oDYOdeH0/ysc3X6MLqhtYgdtcTEW1CfF4xGB/KtXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361827; a=rsa-sha256; cv=none; b=lWrA3s9CWTrO8dF6645wRIJh9GseF/Rzko35fCxEATPovVl7HvvFlReDQMJQBiqGG4ELSz L95LWjiJJC3LA4SH5UAdQuYq7NLgbovfJ6Taz7cf7O0BTHfpD2dVMhDChigZ8xomTTq9UT qJRlaOoMxkrxZ8GgBMpwKS8ACrOGcw3Ki6WsUD+y1bvC2nfzDsgQciENcDgpOjsKwJf54c UBDXd3TIUx6SjQwjZU5iXg80zEGjWAxYPT1DyoRv1RJ/M/8EzrO0+DBSJzrq4n9IXzhfUo 0baDCdurX1+AJII3BjVBENli+4hGDifVo8Bi9GOuF4z/Ji/lBXvKcvtFquyvlA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361827; 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=yCPAOvGrx/w9XS8dhS0YKnufnI8ewCNsZzf5943FVBs=; b=KSJ7jfWecXdyKeu+EpyktTbCrRIHFe5lSUBKrsJe0+qPo1jNXfLu3NVgENyAkd07iOsM5U Iuxd7mQ8AzKRUtjmSi6WszUlo6LT9Ri6k9G6XfhuAShC+Ot7/6DqVwfBWG0+1qRdxX0Q7O XbNV2i4UlwCiFZeG0DWlOAuxLxhuJ2EBUb3/n4dT6EaRC5vWeLTufTFg4hkJlC0uFbGxkZ GTgohOAfQ0fVm4jlQEW6JvYHcDT2nv/noG012Qato1PmGCDiRnXDkmBVz+ng92o+EknKP8 lZeMU5Cft//cIxDHmxVdLxwOnir1vQ2GvGsNua7JS1neH4jpnpzeoVV36T0Eng== 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 4VKMjv6F9LzSTX; Wed, 17 Apr 2024 13:50:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDoRwC029671; Wed, 17 Apr 2024 13:50:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDoRoq029668; Wed, 17 Apr 2024 13:50:27 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:50:27 GMT Message-Id: <202404171350.43HDoRoq029668@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: fd2a580db248 - stable/14 - tcp: no data on SYN segments unless doing TFO List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: fd2a580db248502b5fd46867992e346a95298efe Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=fd2a580db248502b5fd46867992e346a95298efe commit fd2a580db248502b5fd46867992e346a95298efe Author: Michael Tuexen AuthorDate: 2024-03-22 10:12:56 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:50:02 +0000 tcp: no data on SYN segments unless doing TFO Ensure that there is no data on SYN segments unless doing TFO. This check is already in RACK and BBR. Reported by: glebius Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44384 (cherry picked from commit af700f430fd86ba3eae63e587985a12436db8f69) --- sys/netinet/tcp_output.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/netinet/tcp_output.c b/sys/netinet/tcp_output.c index 0d9fd8136554..9269ba443bd9 100644 --- a/sys/netinet/tcp_output.c +++ b/sys/netinet/tcp_output.c @@ -475,6 +475,12 @@ after_sack_rexmit: (tp->t_tfo_client_cookie_len == 0)) || (flags & TH_RST))) len = 0; + + /* Without fast-open there should never be data sent on a SYN. */ + if ((flags & TH_SYN) && !(tp->t_flags & TF_FASTOPEN)) { + len = 0; + } + if (len <= 0) { /* * If FIN has been sent but not acked, From nobody Wed Apr 17 13:51:22 2024 X-Original-To: dev-commits-src-branches@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 4VKMky2gBPz5GwdF; Wed, 17 Apr 2024 13:51:22 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMky2BxWz4psv; Wed, 17 Apr 2024 13:51:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361882; 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=5uKRLH0t+04UbOuBspskeTG1TVPhtAqlgmLr9lXPf9g=; b=jBgLEFfCFWlk52+jobdCM2w8yRkmLRucQK401V0cBkEBPfNDOlElKAxbHc1cSI0sbIrokd nD6cc1hhuBFeqnfXmeiKQQx5idn+cndLj/NuHWLfuHUC12xocg1z5SC7vhBKqtVLkv3fG0 MFa9GqEziTisy8bjTYfsTC42bJO5UwCOrrgais/7GPoFuJxKWypdNzpp+q0Z6UMan56mTj bRW4pUDOMXFFluG82YnN1sn6HiAaYwZYoZNO9IMncCoJQ6nCP/UWpghGDD2p8SkHLl/IlE MgJcv1g6kha3xfzkk3IGrms1Yar1EDVK/gHSAhCwltzjCkMVs7T+7uep01Rgag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361882; a=rsa-sha256; cv=none; b=C2jn9qzhCkyg+9s/Ntgunil7hfejqoS6t2dyQl0wu+o9pj6th0w/OYmzA77kvAXB6QkxxK 1AJsGfFpqt5jhWyLVqei6kWKCAZK7Qqv/J/acIt1s55aH65FXuFM7v7W8TLonuuvs0Z4wR hWaAfhQ2RVtNMLFlkb5tsaAtWfG83NTNjSktwrCmPfjG08ja+juZD8cxtNcE9KWVIU1Lx2 xRJ47TzPipojI3Z+mm9wcLWmRa6EyO2mFZx8KZbFiahG4UboMOvbnXruEAxhd+ElYCEQRl uyaM4AKXxsTpkSoi0h5f8zkSWk2VdsympWrLu2a2YGrJPw0cHkyv4hK+VQZxOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361882; 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=5uKRLH0t+04UbOuBspskeTG1TVPhtAqlgmLr9lXPf9g=; b=Xb6KEd+gxN6yacYujS97e6IhYYGFmGP0FXaS00Z/a4YrVDJxPaIVpQyKGGgiPeV1NTZr22 DlzqZPctkQhe+uEUyeOlL4akti4uRovVcSbA2yiNJvJxi6gS50OgZ3hkO8fkqafu9Gws3F yQYlumCCulkG6WOVwQCxA7yew3eVsNmu41CfB9Im06AT1opKPkFscmLtfmqpaLWBEKGSfi ezKy3M2UW8IdE37YHVvRob+ymf4RjMIsdCiu19es4hLoN7wCtccDxkaR+ziu0956So6/at CQUipblXUpXaIWnxwG5Hn+PamY/l1S1x0TJsBcZWaiSCLbUYQxW7RpSxMXlIQw== 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 4VKMky1VfzzTQ2; Wed, 17 Apr 2024 13:51:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDpMXD034434; Wed, 17 Apr 2024 13:51:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDpMFH034431; Wed, 17 Apr 2024 13:51:22 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:51:22 GMT Message-Id: <202404171351.43HDpMFH034431@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: fbc8dfd0ed80 - stable/14 - tcp bblog: use correct length List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: fbc8dfd0ed80ba7d12d2683c8afecf6d16ce3388 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=fbc8dfd0ed80ba7d12d2683c8afecf6d16ce3388 commit fbc8dfd0ed80ba7d12d2683c8afecf6d16ce3388 Author: Michael Tuexen AuthorDate: 2024-03-27 13:31:48 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:51:00 +0000 tcp bblog: use correct length The length of tldl_reason is TCP_LOG_REASON_LEN, not TCP_LOG_ID_LEN. No functional change intended. Reported by: Coverity Scan CID: 1418074 CID: 1418276 Reviewed by: glebius, rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44510 (cherry picked from commit ed505f893ab08aa61e2a1046ae54df357a108260) --- sys/netinet/tcp_log_buf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet/tcp_log_buf.c b/sys/netinet/tcp_log_buf.c index 5e168c5066e4..7b937958a4fb 100644 --- a/sys/netinet/tcp_log_buf.c +++ b/sys/netinet/tcp_log_buf.c @@ -2442,7 +2442,7 @@ tcp_log_dump_tp_logbuf(struct tcpcb *tp, char *reason, int how, bool force) if (reason != NULL) strlcpy(entry->tldl_reason, reason, TCP_LOG_REASON_LEN); else - strlcpy(entry->tldl_reason, "UNKNOWN", TCP_LOG_ID_LEN); + strlcpy(entry->tldl_reason, "UNKNOWN", TCP_LOG_REASON_LEN); entry->tldl_ie = inp->inp_inc.inc_ie; if (inp->inp_inc.inc_flags & INC_ISIPV6) entry->tldl_af = AF_INET6; @@ -2532,7 +2532,7 @@ tcp_log_dump_node_logbuf(struct tcp_log_id_node *tln, char *reason, int how) if (reason != NULL) strlcpy(entry->tldl_reason, reason, TCP_LOG_REASON_LEN); else - strlcpy(entry->tldl_reason, "UNKNOWN", TCP_LOG_ID_LEN); + strlcpy(entry->tldl_reason, "UNKNOWN", TCP_LOG_REASON_LEN); entry->tldl_ie = tln->tln_ie; entry->tldl_entries = tln->tln_entries; entry->tldl_count = tln->tln_count; From nobody Wed Apr 17 13:52:02 2024 X-Original-To: dev-commits-src-branches@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 4VKMlk2MSwz5GwSs; Wed, 17 Apr 2024 13:52:02 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMlk1lyWz4pw1; Wed, 17 Apr 2024 13:52:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361922; 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=3AAmTOBR6t6G1mEPZfGwB9N7dMnP+Qc9irnYD5+7JpU=; b=B8MRDS2cfFncSZcjgcCdHSt+/hv8qpQle0bmeOlzJmzV+VA1h8OMMJccuTilTrA4vGUB1v YsJ66T4EJpMGyTu1uc3SDeLvAqVt/hL6baDKjW1reAUPi4VHQ2GV986tEJRvk7saEnoObM ZOpmNq9puuMo/csQVDOuJnkyOtalCY3Q2Sdkkj0GTJCGfAOfBb078fu7MHQqGyQV5EfUp6 0I6fBDgszKbjtyvLjjR7690TemOHiuSu4SjhYIwkb4We2QMZsm/YQv2QGrtUHPlB/GfQ/5 4a0PF+lgR/gFAXywWY6xYHiTHxzoaRTsO0nUhcPvgEo53v1GKejb1rAONA4/sQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361922; a=rsa-sha256; cv=none; b=X9z7rh7MhL3hwmjVEuyozbfG4Bfm7EnGy+cFI5TfSLQTYPd4GHgKJwV1D/ZR2mueUZlUYk cHJydm/gLNojalNIKik/yu9WbiXWmk1+XGXqtHhv66yIgMM+1RTSZsunarABZB9vNYU6d1 gDiL3BTReAoHeDyYH7S3mALhMt1WoQXaPFCNZ2DzYiWXj7MAZOOoxvvVGB6FyUjg+pp2X3 66MX15TbzCsjJwdMFuA83oW18uYG/OvWtJkMkJ6qpHP1TzsqhFohpGU9bJQ20JODpwiPNL O948Mw/VOo/tKKZ+q/4QCOmOtEDr+auWrcpGQYeP39LZrj5foKliA+hAR2a4tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361922; 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=3AAmTOBR6t6G1mEPZfGwB9N7dMnP+Qc9irnYD5+7JpU=; b=uqZTUJPUWG4r3WuHlYMRMH+In7KE6WUgIjmHIJMAcLy1dumq16mSntqmQR9qAspMWrOLfx jGHzrPI7u5lZ2EKfcyP9SFEahZ1BU8xqMU0PnGk2GYJ6j2PHWiR7Q7NoMtDPUtoCq2SPuH ow+JfLJUCCgsf93Fy60smR4SkC3g7mTauI3CPIef6WU+YPPEWDg0xOyDEwjURpc4iXkgoq V/pBvVaS5Dllpilc1ptLnTe5j2ymnnVRsMqCpUa2dnsA7Pk9nh9kl7YCLo8OS5xUGXOrwz p7eq2hxgKRAEEpiF+Y6IVzRi3uQZLJtANLof20tMzGubYthUxtiaMRwlLNlLNQ== 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 4VKMlk1KCszTr7; Wed, 17 Apr 2024 13:52:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDq2mE035511; Wed, 17 Apr 2024 13:52:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDq2UI035508; Wed, 17 Apr 2024 13:52:02 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:52:02 GMT Message-Id: <202404171352.43HDq2UI035508@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 8375db082c6b - stable/14 - tcp hpts: improve consistency List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8375db082c6b486b05cd8072979d113512341fab Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=8375db082c6b486b05cd8072979d113512341fab commit 8375db082c6b486b05cd8072979d113512341fab Author: Michael Tuexen AuthorDate: 2024-04-01 19:51:59 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:51:43 +0000 tcp hpts: improve consistency The target_slot argument of max_slots_available() can be NULL. Therefore, check for this in all places. Right now, all callers provide non-NULL pointer. Reported by: Coverity Scan CID: 1527732 Reviewed by: rrs Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44527 (cherry picked from commit b600644fdd6cefb1b90d76fdd5aa595946611a7d) --- sys/netinet/tcp_hpts.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/netinet/tcp_hpts.c b/sys/netinet/tcp_hpts.c index 9d192b17c41a..89b9611e643f 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -758,7 +758,8 @@ max_slots_available(struct tcp_hpts_entry *hpts, uint32_t wheel_slot, uint32_t * * "0". */ counter_u64_add(combined_wheel_wrap, 1); - *target_slot = hpts->p_nxt_slot; + if (target_slot) + *target_slot = hpts->p_nxt_slot; return (0); } else { /* From nobody Wed Apr 17 13:52:56 2024 X-Original-To: dev-commits-src-branches@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 4VKMmm4yDkz5Gwph; Wed, 17 Apr 2024 13:52:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMmm4S3Xz4qXx; Wed, 17 Apr 2024 13:52:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361976; 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=u4YIGIj/66sd4dC8Ed9Q4XlRuCU4LOciTfBSj3b/Rtg=; b=dXe9S2+6bxno8D9odfXgFHfzJxZBXSqvzRweJK2kgiZGMJjUzpxBK5POmdD/XD7f/X4RPg jIbg7xR66dPiydO1YNDSDSpkFleHk6g9u8+x14MWILTBfs6IT8O2ZPc+Ca8Ff4BpoyCRUT /SdtTPd98guXbh5eyr6R6zdwuEHghec3BICVe9OZXBy+9eMEHk6NYp3lpPQpMeNZnZPBro oW0KUfBUcCnPImCo6GuafbdWmXGDtxS3twUYLm50cQGpf5uBkzNTyUsv7sTJknWNz21NB8 4rcZ5rthlKQlhnhGl5/w3do5EdQOEd37jceeR60XuUwgHzvVaWkTI2BY6GLNUg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713361976; a=rsa-sha256; cv=none; b=tlHguT9XFwEO7kTIajimidEcYYKLOHboDRslP0u9rTx0plYRyR7nrkB8mL9GI8puHnASZH Q+XKXNqOLUgTH+1NJPC0300IBC28TQXVRci6C+eIAUj6ns16kyjHUPJ185IoVARWD8Gk/o cG1gO5rMrZCgldZKqVbZUZrFQ83sXaeF54mU3oJGVIQ0Qj+uKbRBv9cwIkIK14bFf9Xkbp eSCFs1nJ8EzFzNVO3iXZ53/vYeCLD3aNCS705LtdmACmis/8TApHHbqXtURfgpKM8uV9Kl W0ObFKGx3Y2N7gFe8oYRP+Kqsb11fJ/jt98rooY2UDhhLUQNrIsKdJVWLvEayw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713361976; 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=u4YIGIj/66sd4dC8Ed9Q4XlRuCU4LOciTfBSj3b/Rtg=; b=wXiBX+reI7wnJegFH7vh/MWx2Ya+dQ6Nnaf7jlqy8MzRb3fm4E8Tc+xuLy3MnJaWP/NNPp JN1nKrtdcYDzJ2sMBw82VFH7EzGjksIu1//M4lms2NxCOXdqk7LNgDRC3w4PrxPyh9uZ1/ cH1kWprl+liP70+kbXOt0fJRxMoCDSyDxjRKHxWmtw52pGEfmpBmYg71SoPWJaiQx+4GTs a/ExPFdGZWO9MOu9MoE/aIYQKtbqlXjnXNHZFCEQUqWJ/rK8Ntg1Hz0td7U0TjO3lDPNol N1mdcp78p2zR5fxnUix08pHw0RKLYYhx+G8ywPlmNF6Do8K1Htis1W0X/4XPvA== 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 4VKMmm4027zTrL; Wed, 17 Apr 2024 13:52:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDqufG036683; Wed, 17 Apr 2024 13:52:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDquB6036680; Wed, 17 Apr 2024 13:52:56 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:52:56 GMT Message-Id: <202404171352.43HDquB6036680@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: be30b22fbb77 - stable/14 - tcp: fix comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: be30b22fbb77b74c2be8de28266630d979fc61c3 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=be30b22fbb77b74c2be8de28266630d979fc61c3 commit be30b22fbb77b74c2be8de28266630d979fc61c3 Author: Michael Tuexen AuthorDate: 2024-04-03 16:21:19 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:52:18 +0000 tcp: fix comment Make the comment consistent with the code. Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44611 (cherry picked from commit 5a268d868890dbbfe96361906be20d01cc252b2f) --- sys/netinet/tcp_var.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index 8e2a17204ae3..b541e3c955d9 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -925,10 +925,10 @@ struct in_conninfo; * and thus an "ALPHA" of 0.875. rttvar has 2 bits to the right of the * binary point, and is smoothed with an ALPHA of 0.75. */ -#define TCP_RTT_SCALE 32 /* multiplier for srtt; 3 bits frac. */ -#define TCP_RTT_SHIFT 5 /* shift for srtt; 3 bits frac. */ -#define TCP_RTTVAR_SCALE 16 /* multiplier for rttvar; 2 bits */ -#define TCP_RTTVAR_SHIFT 4 /* shift for rttvar; 2 bits */ +#define TCP_RTT_SCALE 32 /* multiplier for srtt; 5 bits frac. */ +#define TCP_RTT_SHIFT 5 /* shift for srtt; 5 bits frac. */ +#define TCP_RTTVAR_SCALE 16 /* multiplier for rttvar; 4 bits */ +#define TCP_RTTVAR_SHIFT 4 /* shift for rttvar; 4 bits */ #define TCP_DELTA_SHIFT 2 /* see tcp_input.c */ /* From nobody Wed Apr 17 13:53:51 2024 X-Original-To: dev-commits-src-branches@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 4VKMnq2VpVz5Gwpy; Wed, 17 Apr 2024 13:53:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMnq1bj9z4qny; Wed, 17 Apr 2024 13:53:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362031; 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=LwxVwLEqYWbzYiHcGCNkSZHSxs7xjvSmu/PEdujKQSc=; b=u/I2jrqzUZp5/mm/ko05KNESDW/7aarwJz03/fNKcavuePYiX6AXSakI9bJdhsacUnV9rD jJA/YJrjxgDGIsN9oua6RdUKm3xtXbKQVOQlLywVBmjfajEaf9HcHOTSkmnS+noA+6X+gb o3QT9AzRFjtShreN2gSD6kvgvy90tfB9rtlmELh9mRLKWiZceOwc6YrziuSu8vDRoWthh/ eowUzG1m2eVNgu07mnW9LDjIXfYdnFPL5gGf+la6WZKN1DrQR6qYgRmRiy3dXAMQf4Bf1y eql4GRIVtUUc/Gkta/UicLX/ggnYTqtGW1Ag3nc7xJAclA4GLjcBCkoRVtoAFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362031; a=rsa-sha256; cv=none; b=nHhnMCO09qTiNaAZPVKxyAX1sdabBNzo2kWEvNQudUv0ByiF/Y/+HiqAHkHzWnjKBaF1bB 7Vewk0BGnKPspeqM/CH3PvNOAZtjzB6ni+kunf3sQJ8Hc7/7+W90FVlpXJRDjxVnT6EVmX E07D4WlbGNZ/yV16XipUDY2qrbPhad/fFUm6CISX7JZkEmy6hZJlKNmDlANqPJXAv+bDaU BPpl8zcWifGmVbYmSf4ycJmeEwrB6b4FLWaxHHze7JRKBH3ZSzRd4l2o0ftSl6q5hU35h9 QfYVMmzXLmlXef7ZzZHc+oyE0rJ5P8fH2NMuNvOXt8M/jjlcLuTz+OY96MzRWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362031; 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=LwxVwLEqYWbzYiHcGCNkSZHSxs7xjvSmu/PEdujKQSc=; b=jhuQmm2sQI3ppXUC74yoAWdz7pTtxbbeYY0SxqbiHrTG+fibsB0Wf2efkv2C4vsk9yF5CQ 3hwxtRsrFufFVRZZtAiK6f/4QZZLhyZoj+sd8cdUc6qPUckFQSKDGn2YTZAqJVN7YrNFez gC9aDAUpddMWBcMnmSYrKjw7XZ2y0DiGI4LwNNz+8qySYbJfM48OomoM6aguAEc+eLN/vf ZcT0SaWiknhPCXb/LU80jgOwGw0ptMlPhWPMDB46+wL00evPeYx8RlVBM+YXRGDQP6Y58y sqFvEopkAM1GUXk6stEjaBIr6UVuGhGeAsOJRzGv2gorHra7RB7NZIwVRkAspA== 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 4VKMnq1CrFzTC8; Wed, 17 Apr 2024 13:53:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDrpRY036944; Wed, 17 Apr 2024 13:53:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDrpD6036941; Wed, 17 Apr 2024 13:53:51 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:53:51 GMT Message-Id: <202404171353.43HDrpD6036941@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 7ebfafa813ce - stable/14 - tcp: fix conversion of rttvar List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7ebfafa813ce89b2082647eb1c9e136b527ce653 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=7ebfafa813ce89b2082647eb1c9e136b527ce653 commit 7ebfafa813ce89b2082647eb1c9e136b527ce653 Author: Michael Tuexen AuthorDate: 2024-04-03 16:39:31 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:53:15 +0000 tcp: fix conversion of rttvar A wrong variable and wrong scaling factors were used. Reported by: Coverity Scan CID: 1508689 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44612 (cherry picked from commit e0bd180130b8c95f568483d0df6abff00d7d2153) --- sys/netinet/tcp_subr.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index 34150707072e..c11bfce889e6 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -4201,19 +4201,19 @@ tcp_change_time_units(struct tcpcb *tp, int granularity) uint32_t val, frac; val = USEC_2_TICKS(tp->t_rttvar); - frac = tp->t_srtt % (HPTS_USEC_IN_SEC / hz); + frac = tp->t_rttvar % (HPTS_USEC_IN_SEC / hz); tp->t_rttvar = val << TCP_RTTVAR_SHIFT; /* * frac is the fractional part here is left * over from converting to hz and shifting. - * We need to convert this to the 5 bit + * We need to convert this to the 4 bit * remainder. */ if (frac) { if (hz == 1000) { - frac = (((uint64_t)frac * (uint64_t)TCP_RTT_SCALE) / (uint64_t)HPTS_USEC_IN_MSEC); + frac = (((uint64_t)frac * (uint64_t)TCP_RTTVAR_SCALE) / (uint64_t)HPTS_USEC_IN_MSEC); } else { - frac = (((uint64_t)frac * (uint64_t)(hz) * (uint64_t)TCP_RTT_SCALE) /(uint64_t)HPTS_USEC_IN_SEC); + frac = (((uint64_t)frac * (uint64_t)(hz) * (uint64_t)TCP_RTTVAR_SCALE) /(uint64_t)HPTS_USEC_IN_SEC); } tp->t_rttvar += frac; } From nobody Wed Apr 17 13:54:36 2024 X-Original-To: dev-commits-src-branches@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 4VKMpj05YGz5GxGK; Wed, 17 Apr 2024 13:54:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMph6h79z4r4P; Wed, 17 Apr 2024 13:54:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362076; 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=VHcLa4B+Uy2ihS76+d3hpR/ZLuF/swTM5MpHzthld4k=; b=LvtjZ6D/7OzSVvpI+UnKuTZ1hsF2mkonGLlH5tuUKS/FFASdOGHR0cKYufYKyYu52w/aXu mph/ouBBrFRWwoRhLk5jLpAWUPv/HWEL1UI2dNpGHIVvhd63mr6i33CRN7E9OQv5e6PsP/ eXgP/P1uh8y33XFK+YIBDJvGyBGYpP9Zt9qqWVjiq24wlezQJB6VJyZXXTDzUyQBftXOp2 GnGknPyNCfOq+Lv/9OHatu4ZaQxjtecld2bHG6oCggZkk0m8zGzfMUgb+FKBvtF+O9ZWGl XDUgXyaqEzVvXK8vjpQkSuX7NVbisWrxeJoYYX/vGs2pq8lmMB2vYzkPoIGTdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362076; a=rsa-sha256; cv=none; b=CeNGc73dteobd9uIrE8uoFPlWubvdBD7hF6FK9nGwQXVG8sc8Q33rOa5L9nPRrdNRWZYjV kUwtzIe2DeReZQS8zyQO2lfUlYGbv/Hp1UQop77fHNUI6XLyzGzMTioAAB60PSSV/1TQTr 0V1L3+OP5JLuo0yxBe3g22w5HQC7BlaDYwo5NfWbnnoUT0+AEI1nUW/JVPlov7riOJTyHl 23sHgPrEh248Hb1UDCR98O+Q9+lf+iWQTyY2HJR9zeBHXSLGC6tnEGCjCZypMvxWayV2AK GTt5WnpzUftR0dxYCra9t4QMUXxIEDA2QWmHAxtPYqD5kMCfGM6sTMj2PRNETA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362076; 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=VHcLa4B+Uy2ihS76+d3hpR/ZLuF/swTM5MpHzthld4k=; b=kcj0XNLabr1IYjtPt4mWjtJs2hKiohpy88FTZlP+x4teqmh66N2EsK34Kkv4nv9RDOS3L9 fxES+I/SvRXvmIRIGba8UqWBq9D2hz/7+EPDPt58IseXAgpkiVDYT4YeGdfMGUwytl4u8+ u4EQB4Ra75XFM/AoWGRpz+vck77G4r1Qrylj61N1PT3y2OtBQuAy3knJy65MtWxIaD0e8G DFxYcnD8q1H3EDT3bvUNqW2gig98ea5TocluWriYX4Xs5apN3LBcghH73W7WSXMwfGQLEw 1cj/p6Qo8ltSLNrfaAyqlLz44h6ptI2p+2tmqG4YD/ukUP71lMQHX/N15qmbbQ== 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 4VKMph6GTtzTrR; Wed, 17 Apr 2024 13:54:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDsa1c037160; Wed, 17 Apr 2024 13:54:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDsame037157; Wed, 17 Apr 2024 13:54:36 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:54:36 GMT Message-Id: <202404171354.43HDsame037157@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: f3e2beb306c6 - stable/14 - tcp: address a warning List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f3e2beb306c6778ab5d3c5774ad28643d939fad4 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=f3e2beb306c6778ab5d3c5774ad28643d939fad4 commit f3e2beb306c6778ab5d3c5774ad28643d939fad4 Author: Michael Tuexen AuthorDate: 2024-04-03 22:14:59 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:54:13 +0000 tcp: address a warning t_state is an unsigned variable, so no need for testing that it is non-negative. Reported by: Coverity Scan CID: 1390885 Reviewed by: glebius Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44619 (cherry picked from commit 6b454da6bbaa3327cf9b7185d198c96ffc1b88f4) --- sys/netinet/tcp_subr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index c11bfce889e6..0ba35ea13130 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -1077,7 +1077,7 @@ tcp_default_fb_init(struct tcpcb *tp, void **ptr) /* We don't use the pointer */ *ptr = NULL; - KASSERT(tp->t_state >= 0 && tp->t_state < TCPS_TIME_WAIT, + KASSERT(tp->t_state < TCPS_TIME_WAIT, ("%s: connection %p in unexpected state %d", __func__, tp, tp->t_state)); From nobody Wed Apr 17 13:55:08 2024 X-Original-To: dev-commits-src-branches@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 4VKMqJ4Szfz5GxKG; Wed, 17 Apr 2024 13:55:08 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMqJ3wg6z4rYw; Wed, 17 Apr 2024 13:55:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362108; 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=R+fLcXHhANxmUveNp76eyTW3lLljerfjTAyWdRCunbc=; b=AnMU8WIA8rOOAbWuJ0p2j08VV1DSYS1Bav6TpaG0+zyQEVH+khxUGYPVSQPqzAjiejX9ED etCCxCBAbhcVu7dVudl6SYaIVMCJuLyIcGH8TVTxfwHnc4QswpdxAPm7M0EBWhbRXs2Kwt e9xdbCYZDdlpQBi9SGUhVmolo33e5ZpTEtMwTzkWF41FSjAgSL8NrH3eXFzcp5DCwlQgWc 15SAeqhT2xS5cyjP4ltKWiT0K4GQ8CL0ePiKxgZGWxji0WK5RJVmMRMZeO86EQ08b64eCy /BOsbU7Xr3XuK0ggWGHpD/M2jIE3iLRZa7KM5GtlcTyD/9/OPcA7gVN6nntxFA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362108; a=rsa-sha256; cv=none; b=EwLdIOe8Zoa4tL6CrfzlPC8lcepjx+qSXNfpoYRcs5Qi3MvJ58LnFhG2AiE0Yg+wJeZQu0 OGVHPlpGR2BywAeylY+Dn1ZgnCyYiluGDdq9AeKG8QGLw8LNsM15VAduRkZBYMGGDkk5D4 kC62pxkcgMkfd2qTIEFvVxfoSnOz6khgm/1oSwq97ljub2Im4bG42B1Ey4Gpq5zaLKVly5 8/QDi74bpq4RzPDX319NvoAcTkf2spo/C359Hpq/X2ZA4nXWrDYotRVVLponlaEFe4yL1z ZuFY/wlJjvCF31hQ0vfGKSgeoCivWJ0XPUMAaHNBi3HBvutxrYskGfc1DHue2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362108; 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=R+fLcXHhANxmUveNp76eyTW3lLljerfjTAyWdRCunbc=; b=ylP2idF7rNQSZJm6aCUfGuBgIQzsoJulYWDMrlpweEMUwoWBCTeybwTj9XackS2fGTomz4 dsdpft2yOrY1gviDHDOWzuAzEB6ZRdxWX2LrAriCaKiFQNlNLwTJJEug2h248NRn6I3Kg3 VZb5L0kDF6dSa9zcBMlqJbJpBF1ydW8x0s+OtQzPEdn0VtECzZhLRI+Qy32Z/XBZSjRbAV CPafEhDkw2x7hdzc7qiOK8fo/9meVj+4o6icc09wiTemdULLezeH9xhiXI/mOfq4Q3VHh0 J/Oh/MSDFoCkRmz2nO3NRLRJH052NpU2LlFNmBJDhkJoQ910VqSj0AXzZFfb/g== 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 4VKMqJ3XSdzTrL; Wed, 17 Apr 2024 13:55:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDt8nD037387; Wed, 17 Apr 2024 13:55:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDt81j037384; Wed, 17 Apr 2024 13:55:08 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:55:08 GMT Message-Id: <202404171355.43HDt81j037384@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 60898a7cef0b - stable/14 - tcp hpts: initialize variable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 60898a7cef0b47efe4b2b81460fccfc2002b819a Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=60898a7cef0b47efe4b2b81460fccfc2002b819a commit 60898a7cef0b47efe4b2b81460fccfc2002b819a Author: Michael Tuexen AuthorDate: 2024-04-05 15:30:31 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:54:52 +0000 tcp hpts: initialize variable Ensure that tv.tv_sec is zero in all code paths. Reported by: Coverity Scan CID: 1527724 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44584 (cherry picked from commit aaaa01c0c858fd703194c6cbd515dd514574381f) --- sys/netinet/tcp_hpts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/tcp_hpts.c b/sys/netinet/tcp_hpts.c index 89b9611e643f..af7b2691ff2e 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -1650,6 +1650,7 @@ tcp_hpts_thread(void *ctx) * enough activity in the system that we don't need to * run as often (if we were not directly woken). */ + tv.tv_sec = 0; if (hpts->p_direct_wake == 0) { counter_u64_add(hpts_back_tosleep, 1); if (hpts->p_on_queue_cnt >= conn_cnt_thresh) { @@ -1674,7 +1675,6 @@ tcp_hpts_thread(void *ctx) * Directly woken most likely to reset the * callout time. */ - tv.tv_sec = 0; tv.tv_usec = hpts->p_mysleep.tv_usec; } goto back_to_sleep; From nobody Wed Apr 17 13:55:56 2024 X-Original-To: dev-commits-src-branches@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 4VKMrD4DJVz5GxWr; Wed, 17 Apr 2024 13:55:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMrD3jMbz4rgN; Wed, 17 Apr 2024 13:55:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362156; 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=M59i3vkvvBGaMvBFOtuj5Gp6qrU5zQJOkWIUQd6UrcE=; b=HIGJJpkC1l9lDhQBr+rXSTT10Qv/lsB4MvaJUt9DU4VMVL0XxL0FpGXkMNb/gv85adBGYO XM5SSyMUtSb/8ZskfUHKiEByT2sDHbcBd+3JTuyNLE6nkvqg5nYkymaREUyuJZAjFGOv/Q GErQYk45zhlgtWsNn7QJt7DnL4wdIHfx0QHm/+F2zQosChfbsyltrYP6ZpghKx49m/tW07 tDDVWXF+ZU7AouDp9OAB+G+JxporLanWZPC8xVj8Ys09UumQDcMQ8ptdwQaLPXVEPIyywl HipyipCweECzX0Te2wwgobX9Y/zTN/DjoBe30M4Ae7WdBkmmJNgHStTKSJiAxw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362156; a=rsa-sha256; cv=none; b=te851774KxUjwGJbBy5GDT+v2hLEfpAG7nwKPMrS4dwIguovnNJE7L0dRZfG9kso+V7Sf5 05t2ausLVoG3E79uDftAbfVJqUjMh9qeqbV7dDPpfOrl6nunWiKtewiuJVQQd6oV4JQiur K9q6xwDkmzcQw1Qgz8aUnvpl6GTl5HsxNQKfH6veMUdo0LXlr8s7p2iokG974X9kWCYF8t 7x0Kk1BKLLrNEjzkJIhBxg/X7oGV/ofDwFc+FZ+PLvs9XrlcirRLrxYkePpDouiLI6v8Em 1X+GN/2P3eh11m4MzDMk0nCVl7vGRscOfbeiUjAJi8OfFN5DGwj2cM5EZslAuQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362156; 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=M59i3vkvvBGaMvBFOtuj5Gp6qrU5zQJOkWIUQd6UrcE=; b=Y3RLaJEkKY7ktKUNrsZHN5WXy7bIWEBSF0SawpG4f+4x293l/Mm+Kjsb+w84kOF865dIoo zJ2lj1ZL+VsjmcIdpNOOS9yWrGev42s2r2BHuwGgxPEQqgm+S7nkPX2V53yxrw250WHA3R 9FFqetFSXCoJmkEk2woO4EHgMAMW97y9QYAAlpheimvfwM+t62mKnsrR2Ja76qnxRzlBuH eL9OBiQy8/KtU/KqZDTFcrS+LHNtX0IFrt5W1jtkejvcQAlu0nndIZPuNa3/kUAY94xs13 NsTStWjpPptCIx95keubQQ5rlb0el5IGPshQ+7EZRyb5FziMgzQHmmXWCbe/Og== 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 4VKMrD3JkXzTqp; Wed, 17 Apr 2024 13:55:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDtuPD037598; Wed, 17 Apr 2024 13:55:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDtulF037595; Wed, 17 Apr 2024 13:55:56 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:55:56 GMT Message-Id: <202404171355.43HDtulF037595@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 6572d12cfc67 - stable/14 - tcp bblog: cleanup List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6572d12cfc67632127576c9e4ce16d7d433f122d Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=6572d12cfc67632127576c9e4ce16d7d433f122d commit 6572d12cfc67632127576c9e4ce16d7d433f122d Author: Michael Tuexen AuthorDate: 2024-04-05 15:36:40 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:55:27 +0000 tcp bblog: cleanup Remove redundant checks and improve error checking. Reported by: Coverity Scan CID: 1523780 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44616 (cherry picked from commit 60bc195745b8c1e1896c535a491906cdf11fe057) --- sys/netinet/tcp_log_buf.h | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sys/netinet/tcp_log_buf.h b/sys/netinet/tcp_log_buf.h index 1f5b7cf9b54f..79f96bab1345 100644 --- a/sys/netinet/tcp_log_buf.h +++ b/sys/netinet/tcp_log_buf.h @@ -418,7 +418,7 @@ static inline void tcp_set_bblog_state(struct tcpcb *tp, uint8_t ls, uint8_t bbpoint) { if ((ls == TCP_LOG_VIA_BBPOINTS) && - (tp->_t_logstate <= TCP_LOG_STATE_OFF)){ + (tp->_t_logstate == TCP_LOG_STATE_OFF)){ /* * We don't allow a BBPOINTS set to override * other types of BB logging set by other means such @@ -428,11 +428,9 @@ tcp_set_bblog_state(struct tcpcb *tp, uint8_t ls, uint8_t bbpoint) */ tp->_t_logpoint = bbpoint; tp->_t_logstate = ls; - } else if (ls != TCP_LOG_VIA_BBPOINTS) { - tp->_t_logpoint = 0; - if ((ls >= TCP_LOG_STATE_OFF) && - (ls < TCP_LOG_VIA_BBPOINTS)) - tp->_t_logstate = ls; + } else if (ls < TCP_LOG_VIA_BBPOINTS) { + tp->_t_logpoint = TCP_BBPOINT_NONE; + tp->_t_logstate = ls; } } From nobody Wed Apr 17 13:58:47 2024 X-Original-To: dev-commits-src-branches@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 4VKMvW4jdqz5GxGs; Wed, 17 Apr 2024 13:58:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMvW3v1cz4s1n; Wed, 17 Apr 2024 13:58:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362327; 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=UPeMYOOU5t+rsd0jECC2hmFxkCFSNlsPFcH8WOVnhTk=; b=yp+QdXugmkKguaOn8EJeB1zHUvWoHtG0ErWeWaNa+4VVD+U6n0Hxy4xBUqOFoV2YUcejyU HI9ZNSXk8OnMkd9+fmqRV5EYnIi9qwXS+gmJUYGe4pw/LB/uf+Op1H271lzFcSoSxZ+K5M JnaK6CyqWaKray0v/TB7oBc1lBLDAkobPum2Y4L4wW9k1urYFJuVeIyNwO7x2hK7xZ7SGq kgrJ63y0TknlhhDDWibxGtytw+JGC+ULBLjc6lIuZAvL/KjXIw4poUzhfh38VT2YB7lXX1 B62jGO7+OeoTkh1Q8+uKUKwdPPZc+iVX3bY0lzRGqPl3KYUmEZ5dNrMrX/SosA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362327; a=rsa-sha256; cv=none; b=brZzgvrq/MqBedeQQ1rRcVs8b32DpVRq9GtohtcGROaCv49dc3R5h8nh+FISen38lz0Vn1 7/cL1UM0S3BrhwgePvR8XS5PX9RcsRaknYf88v89NbBkrArenHtbTxKP8UElm4MMWH1Wz8 jzxamL63qVpPxu0YK5XdGQFQAycS4jd9or/PtrEUXC1TQnTHnieZ6HELJYyfLQTdFWrNxZ sENMRptKScvsWSzD0g66mWFIYJARL0GXdZzGM4hsg9/O7QkZkzMMmwGL4mTOh1HVVoUwST +AGQbnLAtSTbl7bGRYoPHexZCouSvRU35BIFaEp3Wrhxbnj/OKul7Z8phVGQaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362327; 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=UPeMYOOU5t+rsd0jECC2hmFxkCFSNlsPFcH8WOVnhTk=; b=SnrP2sLli0kvm9Vu5VUGYDUKQOk4z2/QIqQeT2DSCGJM05rxHXmsLZBAXFISSgc2mL06CB OlakJJnZ56KQgXwyavnMyNDBw5r+zErp8ZHRpxfR5be5NDrVUogD559V0aCfBbUxY9NYbX DuJwKGKKuIOnOLv8Klhfhcj3odzAyR5IIg2vxLSb/E/cyU5JOMmpuKEJSOl27x9VcjLz5Q ZIRVtTiGA75IgTrfKWG2Gu4939UEuP1+dBQocjEqrO0tZXGWD6bicltKCzH5EjJG9U0oAq dThvHdHQWNUgCC9STTn64PMAussCf1ZkS+gR7xvE5VnlXuFXkjP9RrTomJiN6Q== 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 4VKMvW3NcSzTCB; Wed, 17 Apr 2024 13:58:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDwlrK038141; Wed, 17 Apr 2024 13:58:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDwlEE038138; Wed, 17 Apr 2024 13:58:47 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:58:47 GMT Message-Id: <202404171358.43HDwlEE038138@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 7a019565ff6d - stable/14 - uipc_socket: handle socket buffer locks in sopeeloff List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7a019565ff6dc6efb5c6ab091343740fd6dd0377 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=7a019565ff6dc6efb5c6ab091343740fd6dd0377 commit 7a019565ff6dc6efb5c6ab091343740fd6dd0377 Author: Michael Tuexen AuthorDate: 2024-04-05 16:14:54 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:58:22 +0000 uipc_socket: handle socket buffer locks in sopeeloff PR: 278171 Reviewed by: markj Fixes: a4fc41423f7d ("sockets: enable protocol specific socket buffers") Differential Revision: https://reviews.freebsd.org/D44640 (cherry picked from commit 681711b77cde2cf3d64dc1e4951ec8287bc4f3e8) --- sys/kern/uipc_socket.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index 880dec89245b..5faf018dca11 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -924,6 +924,10 @@ sopeeloff(struct socket *head) so->so_snd.sb_timeo = head->so_snd.sb_timeo; so->so_rcv.sb_flags |= head->so_rcv.sb_flags & SB_AUTOSIZE; so->so_snd.sb_flags |= head->so_snd.sb_flags & SB_AUTOSIZE; + if ((so->so_proto->pr_flags & PR_SOCKBUF) == 0) { + so->so_snd.sb_mtx = &so->so_snd_mtx; + so->so_rcv.sb_mtx = &so->so_rcv_mtx; + } soref(so); From nobody Wed Apr 17 13:59:36 2024 X-Original-To: dev-commits-src-branches@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 4VKMwS5x6cz5Gxf2; Wed, 17 Apr 2024 13:59:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMwS5B5Gz4sBb; Wed, 17 Apr 2024 13:59:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362376; 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=ddM1JBLhhLHp+zJbJJzzd5r5m2TNbfVAMpy/BuNETM8=; b=bYt6ai79wIs8x5TDfnCybZK5Um3iEd06hAJSVGpeF+90kqLufFQPk4CRSVruJBu8lzI/f+ flKmaAHOI3JJ4k3hvXE0F5Vg9m4ESMvBkhDmxIebLnQP4KfG1/vWiTkCc54qILF4JU+KFk OtgAt3yLRuaGbB1NBCJnvNI4dPXIYF+/ujgl1m/OHqvW+ldQ/IfQFy97z4gZ3VKO7ulb9u Wp0i94tS+HYJ9C3mHRbl5FKK5l1nrQ6AGzwmlGE5iLgBpDcMgkJ3kg3PX4bHhlUGKV+RL8 z9G2zI30uC30ugof45AL/+2PSez3ffL/oV2P9mrdJAExvyMNivw92PNzKBemRg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362376; a=rsa-sha256; cv=none; b=tQbfCDtqFxDHI3+y6sKQi7WUkXSvFatnTDe7cm0t37idzSeP6AkqrqRvnfK4cvy29d9DF8 N/y28jW3tA0R2zBoMmJx1lrIRCKwLM474Aq1ATeBaEXIrIsWVokCElzlyUuxK9oSbRzw4l PX+E7+wmwm6QYhj6rmBAz+08SM586s8B1sBc9k+SoYgNO84nH5GPY2Qfzn+v7oiHuKpN5s Yh5g9gAfpcJHD6aQu+AvoQxqY3LlTrDuTuYt8w6TqQ7hA8Yy1bbKDIw/th2h7oTCrc2IsV Leva3Rsfe8XlX+j0GgWB7gspbYinWdD2cKl+VbcHn02YDQXt2HUGg+33Y7U+1A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362376; 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=ddM1JBLhhLHp+zJbJJzzd5r5m2TNbfVAMpy/BuNETM8=; b=XnovEWNFLNjlGb6c0wLqw2xdOC+xVwna9HnaGyogbpIGEZk5vxEyuUIeYMGG98XKm5osOc H8eqpBOcPxpURN/Pjusu92zGj6gWmCl5LegP6XPhMdM+AvbWxGfhHsNlChoDRlJL+/5tvB X+EaB2sHDtgFb+rm34AfcIYX+8yua468KKubDnYD5SR4uKoLQQmiOyoOoWeNvrhrf4mlFs jo2i5vDI6lslxLGnxkuMPLsSg4WnF+F0gAFNdAtOKBbcyI6qC6u/9Fn3AfiDK14e++fH1b ojIpOV7fgihI1dltuVND+3zul9JUkT2VlVOZo3yXhtxp22iGgc2vp5OgTUY5Bw== 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 4VKMwS4kNXzTrF; Wed, 17 Apr 2024 13:59:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HDxaCB038376; Wed, 17 Apr 2024 13:59:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDxa0m038373; Wed, 17 Apr 2024 13:59:36 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:59:36 GMT Message-Id: <202404171359.43HDxa0m038373@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: c6770e8c99ab - stable/14 - tcp rack: fix memory corruption List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c6770e8c99abade057bee6ef25f3c2e076ebdce1 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=c6770e8c99abade057bee6ef25f3c2e076ebdce1 commit c6770e8c99abade057bee6ef25f3c2e076ebdce1 Author: Michael Tuexen AuthorDate: 2024-04-06 07:55:46 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:59:05 +0000 tcp rack: fix memory corruption When in rack_output() jumping to the label out, don't write errno into the log buffer, since the pointer is not initialized. Reported by: Coverity Scan CID: 1523773 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44647 (cherry picked from commit d902c8f55b8da6902ab45e67ed756cc99f5a9d5a) --- sys/netinet/tcp_stacks/rack.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index c3460e48329f..fa3cd2f4f698 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -22151,12 +22151,12 @@ send: mtu = inp->inp_route.ro_nh->nh_mtu; } #endif /* INET */ - -out: if (lgb) { lgb->tlb_errno = error; lgb = NULL; } + +out: /* * In transmit state, time the transmission and arrange for the * retransmit. In persist state, just set snd_max. From nobody Wed Apr 17 14:00:40 2024 X-Original-To: dev-commits-src-branches@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 4VKMxh6vkGz5GxYL; Wed, 17 Apr 2024 14:00:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMxh6Tyqz4sc2; Wed, 17 Apr 2024 14:00:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362440; 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=gF9duBArZQFQWJn/l5oS8mW3Zr3YjFWsSTk/18cslUc=; b=LZWHfYb6LCn79b54xbOVrZLQSOgEWy5avEgVBRaGwVl1UZcvTu6g0XKzBfuayeDq1SLEIV 13yYk2gOKA39j35KuTtDybj7ebD/KxB04uar90RFfLBdN96mcjx3mjpglHmikzKBWQuXcd o6vCNeHX5baA4K5IUyR8A0pKciA6bGKeeerBrZoXcVsXQDhOqduo0JKtEIMwHBimdyhWq8 +OpXfbunKsEOdmWDWzh0FJeTHWjO6lbGp9uKXBuOMbvs7kMCKE/MVGYA8Ddz5lKiUHtkYM +nC/RDkqqrdydFMnEjIdQtbK/R+HXWl3jEpPMlBIdmXI8xy2plCvAeBzShKWeg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362440; a=rsa-sha256; cv=none; b=G+3bQcnPjAjUqRDAhpJX4PSKlWSsndk3+rpf0b80xun901bHmqnmMV9MmcJr/2SjgJR60+ CULGRF6buhUg/2W1tpAP9igkVuD0IEj8Nrl7Mxn7PE45YLNduwkYgOcJ/Hlb1VpAAVEiEm sneazupPf9B2LmOz5iP8yv3pc/K7uWXKjT7qeeYjC2ab6ad7rbvuRfDDR2ze5fi3g6KUy8 tIo2ruwPBaEr1CqROQwaTuwxOEH0sfoenZqpXYQLwywmbW0iOtDoXxPfQBNUJF3b+G7FjT YtH0gqH90FHiCm9quDv66o5pfZwicrJoNhrNyX2eW3+PBGHZRdY/9Ws8/Wf0xw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362440; 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=gF9duBArZQFQWJn/l5oS8mW3Zr3YjFWsSTk/18cslUc=; b=IDAJ/STVZs3gH5QHYk0uzYxqKC0rn9zXBL0yRJfYlTxzUVm2k8PyR1GEXfT2RjzwiR+6Jv HIEDkZQYEWRJjR6eE4QKFkNu1CvBERp09MVetaZJpeMmS9Tsra+0dIXWJLLpAq7G4GnrBS CLRzGqDgsJAi83tyIFzlbl5EXMBIktq3Z+/0KQyv1eTL+r1To31iOBAXnBwtCqlXYKLnjQ QJZRBD2GHb1ozHpRMISfemx4QkECvRRxJcUAOywk6FcevLa0VBX8bagkMhAH7rRByv3Rfs IST4W0Z1V/+KqNbnf2/0xfFIr6d59L7qJWz83EybjB7xOgiv4XOddbsTdGeWhA== 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 4VKMxh63MJzTcQ; Wed, 17 Apr 2024 14:00:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HE0eCs048274; Wed, 17 Apr 2024 14:00:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HE0eqc048271; Wed, 17 Apr 2024 14:00:40 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:00:40 GMT Message-Id: <202404171400.43HE0eqc048271@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 90cde57af8c6 - stable/14 - tcp: improve consistency List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 90cde57af8c6f14c9a898027646b8e5c6fdd1cfb Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=90cde57af8c6f14c9a898027646b8e5c6fdd1cfb commit 90cde57af8c6f14c9a898027646b8e5c6fdd1cfb Author: Michael Tuexen AuthorDate: 2024-04-06 08:02:06 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:00:09 +0000 tcp: improve consistency No functional change intended. Reported by: Coverity Scan CID: 1523781 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44645 (cherry picked from commit 3e1c8a35f741a5d114d0ba670b15191355711fe9) --- sys/netinet/tcp_input.c | 2 +- sys/netinet/tcp_timewait.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c index 2a4f3875d1b9..53fa5913311a 100644 --- a/sys/netinet/tcp_input.c +++ b/sys/netinet/tcp_input.c @@ -1941,7 +1941,7 @@ tcp_do_segment(struct tcpcb *tp, struct mbuf *m, struct tcphdr *th, tp->t_flags |= TF_DELACK; } else { tp->t_flags |= TF_ACKNOW; - tcp_output(tp); + (void) tcp_output(tp); } goto check_delack; } diff --git a/sys/netinet/tcp_timewait.c b/sys/netinet/tcp_timewait.c index 1de6a2bfec0e..6fb12ce5380e 100644 --- a/sys/netinet/tcp_timewait.c +++ b/sys/netinet/tcp_timewait.c @@ -124,7 +124,7 @@ tcp_twstart(struct tcpcb *tp) soisdisconnected(inp->inp_socket); if (tp->t_flags & TF_ACKNOW) - tcp_output(tp); + (void) tcp_output(tp); if (V_nolocaltimewait && ( #ifdef INET6 From nobody Wed Apr 17 14:01:40 2024 X-Original-To: dev-commits-src-branches@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 4VKMys05rnz5GxYQ; Wed, 17 Apr 2024 14:01:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKMyr6Vc0z4t5D; Wed, 17 Apr 2024 14:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362500; 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=GYatw+r7F3IUNe5a9bxEaee1l/2iYXjeTkc/5YrJius=; b=B4hTGLMIYMtbigzHsVcdpwGqP7wJw5nkXQn9sIeqvHMLtUSSUxsZZjoagmVfElcOzKTuxb gkwS19z5HsdmEYklh3hNzvHMaudOSturGV0wAZf/JzUG9TUEPbkyDUCM0GrOUYd9Q45EhE IIXitEXjH4q0F5F/4LrlV01wBHmvJtg0t52i2SQJEeMBtHx4NHzTfzfSrOlkXQTook2CmI hRq1wYOcYSf8PVIY+RJ45QlO2/JqOs65KaQaQOHxr8HCw7WcufYr2yfU07cktS1Yg7iEBl RHoo1YJnYQArxitcJKqU5LOBF/IpVfvlS/4OskfcCY74arRL8Y6pvPCOn4X3Ng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362500; a=rsa-sha256; cv=none; b=kmlt6bd49iVdD3iAY5xnJ8J9lIPRFfi1huKM5siXdLwTdzPEvOMlKQb2X4EJa+rvgXVSQ1 hdVhPQNqx72P4FoKwRNpiHcaDSJnh4QLCjhDYxQQprDnrDvZeNFcqD1ktoLzSNqfhO/TUr ir6RTaGe97jLivUsxmV4wpr3ZtMmEIbe71OhXREkA2pjdeW2xnIuAeA+EKchQGEg3JIsXM 5iQoLsbvsHDT4X0/NcTWUUrpE4kT6OUQ+RMopqnDDnQijDUcpyhmoK32v5GxuHoFedxuB4 TEUilG2ntAckQFLxefenAy/2KPgedrybZPj7DRs1qDd7WARB8jpGBGHKoKoE1w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362500; 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=GYatw+r7F3IUNe5a9bxEaee1l/2iYXjeTkc/5YrJius=; b=fcZQAeNLEqZIYzRKKPMN0elwiLHgdy/ER9Uz4RRWaEhkBWWIwYfT8/OYnGshSC8S9vRQxl 5cdvr3L0j5q3yy0Q8bSTlIeQft5vDvHnm0FvAtWdBmjf0tpKrTRnu99Xii4HQh54/w9hwv nfJxIuUWmHbMfsmoduNjtkne/nlgFsTIaipJMb+WCiFHgAe/YTZmn1Dvg7dCMtaqUEnfp5 3SEflw2DL3fotSyxD7pJkkk2EV47lRf+Gd5aWYKqWh2IVyUvkU1jfvOpcdOmUzz98Q+07h Z60ps/kyl8arqoaTvFp08LqNiZPoXk77vxfFxdK8Rn5/fZw3S+RZje9TlSj6KQ== 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 4VKMyr66K2zTQN; Wed, 17 Apr 2024 14:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HE1e6x052178; Wed, 17 Apr 2024 14:01:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HE1eDN052176; Wed, 17 Apr 2024 14:01:40 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:01:40 GMT Message-Id: <202404171401.43HE1eDN052176@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 5344772af985 - stable/14 - tcp: add some debug output List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5344772af985cf95e48cffacdcd2cc19f8cdfbf5 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=5344772af985cf95e48cffacdcd2cc19f8cdfbf5 commit 5344772af985cf95e48cffacdcd2cc19f8cdfbf5 Author: Michael Tuexen AuthorDate: 2024-04-07 20:41:24 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:01:12 +0000 tcp: add some debug output Also log, when dropping text or FIN after having received a FIN. This is the intended behavior described in RFC 9293. A follow-up patch will enforce this behavior for the base stack and the RACK stack. Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44669 (cherry picked from commit e8c149ab85c7834f76325864f22ca89298e65f75) --- sys/netinet/tcp_input.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c index 53fa5913311a..dbc2de17785f 100644 --- a/sys/netinet/tcp_input.c +++ b/sys/netinet/tcp_input.c @@ -3251,6 +3251,35 @@ dodata: /* XXX */ len = so->so_rcv.sb_hiwat; #endif } else { + if ((s = tcp_log_addrs(inc, th, NULL, NULL))) { + if (tlen > 0) { + if ((thflags & TH_FIN) != 0) { + log(LOG_DEBUG, "%s; %s: %s: " + "Received %d bytes of data and FIN " + "after having received a FIN, " + "just dropping both\n", + s, __func__, + tcpstates[tp->t_state], tlen); + } else { + log(LOG_DEBUG, "%s; %s: %s: " + "Received %d bytes of data " + "after having received a FIN, " + "just dropping it\n", + s, __func__, + tcpstates[tp->t_state], tlen); + } + } else { + if ((thflags & TH_FIN) != 0) { + log(LOG_DEBUG, "%s; %s: %s: " + "Received FIN " + "after having received a FIN, " + "just dropping it\n", + s, __func__, + tcpstates[tp->t_state]); + } + } + free(s, M_TCPLOG); + } m_freem(m); thflags &= ~TH_FIN; } From nobody Wed Apr 17 14:03:00 2024 X-Original-To: dev-commits-src-branches@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 4VKN0N4D8mz5GxfS; Wed, 17 Apr 2024 14:03:00 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKN0N3mpHz4tc8; Wed, 17 Apr 2024 14:03:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362580; 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=AU03WF8bbbsI+lQm5LkfrOgUHf8qtL+wJPaksCkGzAg=; b=PQjEO2DA0Ft/c8lwqBVUWfpOuZkzqU1k6svhi17oPc3jLDzqYV+ebZCcxlzEzLHdkecXd1 ZNTygkgBnzD8ncH1koNHU5OqRFf0kacIQjx59D2EdI/J1kuEs6XPCyUHkvUBmkj9ppidN3 Z5+CIaKtrDhmhjMum9yvPveuMraL1t4fsmAvAZykTMsgBZtQsH0IUSAIhS0H2WRFAq34YD KJsz+kvXFSf2U7AmEm6CBAVjw2mJHkot3B16njK0kq5e94ZqbdBUUAGnrSkrsJYHFSrH0x xuoLowrD6Xvw4fPoJFZKw6NcxE5piQw5fpc+AvzwW1hB0wtAyFXGLj/mo3zlNQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362580; a=rsa-sha256; cv=none; b=UPPd+3AV2IZZnPL2T2XGdQpby3lIt7qjcR346MTqNoqY1DdW0nN4DiP1m18DjMSWImd0q5 XNVqBbWpaI5OtFHChl1DSoj5+Q3f4yl9k27zSl7LSczGJKekvTBhwZAVdmO1CsJGdv06FX h8oN1pbsnRmhVl3ug9U38bPdpiu+PSCl/mZUeDRGOgvzLrebo/erYfDfRUUV67w2YOJ/+4 B8JxmZ256tJQrbODLFkhw9QygV1i5d5JcAze/TcH1f8GkT5+ZRLPfZSuEMCk/FWKSGLkL1 H3v48ojm0UC5JgmS6chqUwVicNzaJklSXwj/qPmRM3mT1U0OGJTR5gz5nOSTPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362580; 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=AU03WF8bbbsI+lQm5LkfrOgUHf8qtL+wJPaksCkGzAg=; b=SK/6nAfy6b10ekizCeIeykVrvB9mN8Qbi1i0c4Xm2Ibg6LlLgeOuCXasEiyZRcY6sFcrMg N4OxbMs7QZ6uX1m2hwediYcMqYHLNT+eFD1MUTLhQT0XHCWLeKqZCUHojb9uGGYR9NfS0I OW8ZfgnroNuof82SMgNDtjMLHaTscnQ7pxOQQEb8ZRwwxHVOIUMMevJTyZkvD7hH5j1K3Z OSC2wrRqxdRgVfzo0H5xKezXci2/DeFyd3fhSUE1NJLTgT808wJpkgo1joLNEqX4ton/17 l5aazbKKeLhTafVbO5jP5JEHdjo7HGY9UytPgMUGBaAywMNwTbx5fkOKHEYh6Q== 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 4VKN0N3P1JzTxy; Wed, 17 Apr 2024 14:03:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HE30kP055548; Wed, 17 Apr 2024 14:03:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HE30fu055545; Wed, 17 Apr 2024 14:03:00 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:03:00 GMT Message-Id: <202404171403.43HE30fu055545@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 14d778433227 - stable/14 - tcp bbr: improve code consistency List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 14d778433227adbcfafd7c120339f7ca27355810 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=14d778433227adbcfafd7c120339f7ca27355810 commit 14d778433227adbcfafd7c120339f7ca27355810 Author: Michael Tuexen AuthorDate: 2024-04-15 21:52:08 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:02:33 +0000 tcp bbr: improve code consistency Improve code consistency with the RACK stack. Reviewed by: gallatin, rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44800 (cherry picked from commit 605a00660eadb210ed76d49df551f3f33bbb4da7) --- sys/netinet/tcp_stacks/bbr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet/tcp_stacks/bbr.c b/sys/netinet/tcp_stacks/bbr.c index 931beba7a262..f06a35022b25 100644 --- a/sys/netinet/tcp_stacks/bbr.c +++ b/sys/netinet/tcp_stacks/bbr.c @@ -11805,7 +11805,7 @@ bbr_output_wtime(struct tcpcb *tp, const struct timeval *tv) uint32_t recwin, sendwin; int32_t sb_offset; int32_t flags, abandon, error = 0; - struct tcp_log_buffer *lgb = NULL; + struct tcp_log_buffer *lgb; struct mbuf *m; struct mbuf *mb; uint32_t if_hw_tsomaxsegcount = 0; @@ -13588,12 +13588,12 @@ send: mtu = inp->inp_route.ro_nh->nh_mtu; } #endif /* INET */ -out: - if (lgb) { lgb->tlb_errno = error; lgb = NULL; } + +out: /* * In transmit state, time the transmission and arrange for the * retransmit. In persist state, just set snd_max. From nobody Wed Apr 17 14:15:30 2024 X-Original-To: dev-commits-src-branches@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 4VKNGq1QpSz5H02G; Wed, 17 Apr 2024 14:15:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKNGq0rN5z4w3h; Wed, 17 Apr 2024 14:15:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363331; 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=XXP/TUOwDQuYJFYoNCZ38h9/agCqnQAVQxDzYALL4RM=; b=b86ySwhPpnJQulpgKR6Y0HhjCkipmUF83SyNgaHT25ukOIE/4zrk2qos2RhKRhJhoNfcd6 9uJWUA3TIGSud1J58jnJZzlxo2BVMbpVzkS+hlilguv2EbRNB7LEfwVredQ9MnDuh61R1E MMmriBKVIrWu5v+bslsUhgtV0nhI0o9bdSdMDsLSsd/jaRpL5dwTT/PQ0UF8s6E4eC4naS ZfsNR1/w9cpqOJRDd+7BYnbb1fKqiJdpZhzRXHm9DWuKUMwOXSZv6J6r0KLqoEBfNCHGiy Ahr7Q9gmzwUi6W1AsXXb+SKLRrlXs2CRIz9FM10aaoffZYkxEIQH8MDIbRpKIg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713363331; a=rsa-sha256; cv=none; b=OtHy0RgiJpn62CRra9ZpPUXSgOADqcaZ2U2XLkIQwB86sYzukOxtWNyrA4mNItVLcQfbzx pnLImg4W/Mt0VbJ646V7URhZ4U8csW+Qs5hte+kkkdozAeTjdowxj+GUpQNjzn0YoNSsH5 wGOG9tKitLXQrDtK3AhZMn0UcMtfgRFKwHjScgXENGcV/2GgqaMxYQNbCTjgQv0aLICAPm eMDRRblSn/9LiXC+8nvI2uK7PtVltpOnNd5SYah8u7JgTNGak8F5k3mWHkNOFV5ODVYmGS i0q4x4PMvJEjM5WYuwt7Nmj/BxV7VrgPNgtZeKwXavNRcNx6lVRs/e19hV7fug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363331; 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=XXP/TUOwDQuYJFYoNCZ38h9/agCqnQAVQxDzYALL4RM=; b=xHrfhQLpxXZhzRsYdCXY45i8Pf7hpwab6LXwFuLTfdOBx9nJJkxcP8r61sygWhtwaX3GyS Eap7gtKST7cTuedO6WpH6bE8JROkQWF7GdxexuvUbDhsHhp2TACz0E/OQrTTnv0zwdpJF5 6OygGuXXyhJk9G0BhIUQHnMWXoqyttcoih87N0MFqDpuNiK17gnz2VpsTIRBFl/5KT7p3U ZbFHDgCDwOYNFeEdmyRuXQCbAHGG79rXtvvbie0UcedWc5KrDU+XQ6Tsboj6r0SwshpWut dTZ8n1LSEgV7RaoweRW12Ml+oW3Yi26sG/gtrI8z2T8A6O7IUOCEkb7awJwF3A== 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 4VKNGq0RW1zVn3; Wed, 17 Apr 2024 14:15:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HEFUTh072323; Wed, 17 Apr 2024 14:15:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HEFU7F072320; Wed, 17 Apr 2024 14:15:30 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:15:30 GMT Message-Id: <202404171415.43HEFU7F072320@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: b5ee7411bfab - stable/14 - tcp rack: fix sending List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b5ee7411bfabaf85f226fdfc4f2d8e0515d66691 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=b5ee7411bfabaf85f226fdfc4f2d8e0515d66691 commit b5ee7411bfabaf85f226fdfc4f2d8e0515d66691 Author: Michael Tuexen AuthorDate: 2024-04-05 15:47:03 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:15:03 +0000 tcp rack: fix sending In rack_output(), idle is used as a boolean variable. So don't use it as an int and don't clear it afterwards. This avoids setting idle to false, when it is not intended. Reported by: olivier Reviewed by: rrs, rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44610 (cherry picked from commit 7df0ef5f48e1c67b3f1df7c7964bfa59bc56f4e4) --- sys/netinet/tcp_stacks/rack.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index fa3cd2f4f698..b05d19f5cbc2 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -19927,6 +19927,10 @@ rack_output(struct tcpcb *tp) #endif int32_t idle, sendalot; +<<<<<<< HEAD +======= + uint32_t tot_idle; +>>>>>>> 7df0ef5f48e1 (tcp rack: fix sending) int32_t sub_from_prr = 0; volatile int32_t sack_rxmit; struct rack_sendmap *rsm = NULL; @@ -20164,8 +20168,8 @@ rack_output(struct tcpcb *tp) if ((tp->snd_una == tp->snd_max) && rack->r_ctl.rc_went_idle_time && TSTMP_GT(cts, rack->r_ctl.rc_went_idle_time)) { - idle = cts - rack->r_ctl.rc_went_idle_time; - if (idle > rack_min_probertt_hold) { + tot_idle = (cts - rack->r_ctl.rc_went_idle_time); + if (tot_idle > rack_min_probertt_hold) { /* Count as a probe rtt */ if (rack->in_probe_rtt == 0) { rack->r_ctl.rc_lower_rtt_us_cts = cts; @@ -20176,7 +20180,6 @@ rack_output(struct tcpcb *tp) rack_exit_probertt(rack, cts); } } - idle = 0; } if (rack_use_fsb && (rack->r_ctl.fsb.tcp_ip_hdr) && From nobody Wed Apr 17 14:17:30 2024 X-Original-To: dev-commits-src-branches@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 4VKNK706VSz5Gyx6; Wed, 17 Apr 2024 14:17:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKNK66dK2z4wDN; Wed, 17 Apr 2024 14:17:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363450; 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=6II7020D4/GFuFf3GSCaX/Vco+lnO/mYaLRnDcgoGGg=; b=wqRTLTFG4Vtwkpd1cCVC8YYaQcMEOIhNZr9yqPliB+wF1QuZ/UV3QxZiMgz2+Fm7JVIHVr V2Uy1Mm6n8trp13ZFlxe7PdO4OJVGahFRBNCUnaYaa2UWkZnBbjUDE1MlfeZmCq9SbHWlK D2aKsW9gIzZffs2cRWYMeJV9BpbkEsC5mFY0f0OKarlKxyByCTC1zItiUrY5h72k4/0pOS QHuTOozEV8ZXFEbUULEvSVTK+WPhHFPImANMWvaehSYpwhvXdc7WDQR/jaS+0blPoDkzMj onL3B5PyFEwtA7NqzxIonTFBRyfzUk6WGS8zMzwRz/ZU1CFNE72Um64aaTSulQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713363450; a=rsa-sha256; cv=none; b=NQYI8+R5FAYqW/9NNOCDkMrVE2l6HHormaq3Bb7im5WAnHsAipBjOYuLXF3doiRdfDTfZP WC5cjK7bMWgPFFowJZDcrJmjYvjLy2wCJpspaif3VpU1gGUS9T/1CbZgRwpoINCy3keu9E 4AlE9KRAHGG8xyrEa03oRaYLqZxJ99ezfWinqkDmRaYKIN8zWjm/I09258IL19ojvtJ9mQ EyrlRN5HdDIYFQIHCk7nLgPojp+05KPE6xceaGN8TI+dWhwqMKFOIGQyZN8Rzlej3P0RZv Onq4YBBCug4EybXrag6Umln1UCMIxVct8qkxrYjTjjyQyrtJgK+L1DiayfqFtA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363450; 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=6II7020D4/GFuFf3GSCaX/Vco+lnO/mYaLRnDcgoGGg=; b=E73eHTzRBeLgAIPfIT2tJeECh/uCq93J8p4B7ktuRbdx1W+ox+0ar6olIdwbM7L6mA/3wA t2Y/zHbgz1EgzDkbT/dW3nBEG4s9pSHrxjHMhfP1GxZURhvHheKDSVZ8EXihIK1u54xNpA 5JtWr2UIvrhczIt0WKaiWIio6xnztI5NW+7fvnc1c9ZNTPMRHRRxY5hJCnNhuszcfvwPgf VrbSaNwGAsGSFA4JILYJ1u/WsdcLL2LI/FdPgvaLgTBMiODPTx10FgBfN+lv0KQwE8ptD5 T9/VgXi63jQXOyGVzMN66P2Wzy9N7sqrmwXstxt1j6l0VO5Y10Ei+Q7HbOdrnw== 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 4VKNK666hNzVnW; Wed, 17 Apr 2024 14:17:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HEHU9X072689; Wed, 17 Apr 2024 14:17:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HEHUUW072686; Wed, 17 Apr 2024 14:17:30 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:17:30 GMT Message-Id: <202404171417.43HEHUUW072686@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 134884436681 - stable/14 - Revert "tcp rack: fix sending" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 134884436681a8eaf23b26435153c637302482d7 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=134884436681a8eaf23b26435153c637302482d7 commit 134884436681a8eaf23b26435153c637302482d7 Author: Michael Tuexen AuthorDate: 2024-04-17 14:17:03 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:17:03 +0000 Revert "tcp rack: fix sending" This reverts commit b5ee7411bfabaf85f226fdfc4f2d8e0515d66691. --- sys/netinet/tcp_stacks/rack.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index b05d19f5cbc2..fa3cd2f4f698 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -19927,10 +19927,6 @@ rack_output(struct tcpcb *tp) #endif int32_t idle, sendalot; -<<<<<<< HEAD -======= - uint32_t tot_idle; ->>>>>>> 7df0ef5f48e1 (tcp rack: fix sending) int32_t sub_from_prr = 0; volatile int32_t sack_rxmit; struct rack_sendmap *rsm = NULL; @@ -20168,8 +20164,8 @@ rack_output(struct tcpcb *tp) if ((tp->snd_una == tp->snd_max) && rack->r_ctl.rc_went_idle_time && TSTMP_GT(cts, rack->r_ctl.rc_went_idle_time)) { - tot_idle = (cts - rack->r_ctl.rc_went_idle_time); - if (tot_idle > rack_min_probertt_hold) { + idle = cts - rack->r_ctl.rc_went_idle_time; + if (idle > rack_min_probertt_hold) { /* Count as a probe rtt */ if (rack->in_probe_rtt == 0) { rack->r_ctl.rc_lower_rtt_us_cts = cts; @@ -20180,6 +20176,7 @@ rack_output(struct tcpcb *tp) rack_exit_probertt(rack, cts); } } + idle = 0; } if (rack_use_fsb && (rack->r_ctl.fsb.tcp_ip_hdr) && From nobody Wed Apr 17 14:19:44 2024 X-Original-To: dev-commits-src-branches@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 4VKNMj1zyWz5H0HN; Wed, 17 Apr 2024 14:19:45 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKNMj11Ckz4wVm; Wed, 17 Apr 2024 14:19:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363585; 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=T4Hrcc6PrUhGlNsQv/C4i39xggQSpOz9FuEvlu1GTUI=; b=DN6S1ayRCzkmFf430IovT1DryXxnTR7dRse4vPf4KhN1j18/8YaSqEbJI1SCNnDYxIVaYb v5DciTKLW8AmjD1HG6+lmu3mui736h6OMj5X9keSorA9wzsAgSIEzASfG3hNgcZyeWX1SR CiDp9KmtN+9OQc9/vrSL2ExZTtKMLrtI3RmfokyB429U76kdrRrMz91LKIxlsIdrmsRG3F KbsXQtgqhgI2HSIVOIaQ8HAcQnsfUNuSMiCGOpCTdtgJLesGBedPyf5Gmjjk1GjC1ZSIsB gcxQMB6WZkW1da/IgcBOeyCpz0BAsTvN+FU1cV3X8X4myIsFfODspLUs5CktrA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713363585; a=rsa-sha256; cv=none; b=Bb/uoqcHbVA325GW324gpDB12ZRIsH5COUeM25iXHNa2JyH2hd4oSTd30ZQs68y/XC8zbB xfNOvzOKok+manuUwZpVzcgJNtiNVFwW4rvPSQVmunmXvQ7iGzSxQtuR9JxuMNDrb0KNQV j3DAxbscBAEp13DDgwzujHDkyYVHOJqbOsrPfb559QT0CiBgZfJF6IIctjl427X1gw3bhG 4Uzk5CTgo8Yr1/bIeYz7q3/zXtl1xMKYdzIm7VH8piIr/aIwProZN7oOxTF6CDxJTNfhxP e3ctN7fhWz2t8pVJMXKVcU/p47rHAYhc+nC76jcNew3gzfhoROD3cIOaW1/KzA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713363585; 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=T4Hrcc6PrUhGlNsQv/C4i39xggQSpOz9FuEvlu1GTUI=; b=bpafaR/vhffmcZcUDWHADUiPXSudSFqn7S8imct3fFPyM7vjODc3pcR/fMSvImC1hPMTpW NhCGB7gEmXKMtJ+psP5mRrAJpK0f9ooIAvnc9PYsucndnzg1E57uC3H83+s5noPY2C19Nj FAxyLxX0P9hqyV4itcWI2PbrDRVzMEzUgYShSKRtfPtlSqtR6aVRPc/6RDhRUfhRMesYFo IAVfg5pnJKGAuZJ2hk2cHhWgGbpANtxhUJJYN2GAVs1bdinJXE1dwKzJ8nxs67QJFJtuf6 /0emZ55qFuhOFCu/jfi/Xvq9IxDYDUBMrvxn41xguIwiE9VkqjxI/55RSCLgHw== 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 4VKNMj0cdNzVGd; Wed, 17 Apr 2024 14:19:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HEJiKU073129; Wed, 17 Apr 2024 14:19:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HEJin8073126; Wed, 17 Apr 2024 14:19:44 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:19:44 GMT Message-Id: <202404171419.43HEJin8073126@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 994f9c9e3c2c - stable/14 - tcp rack: fix sending List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 994f9c9e3c2cafc2182703c4a43580a2bd390f30 Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=994f9c9e3c2cafc2182703c4a43580a2bd390f30 commit 994f9c9e3c2cafc2182703c4a43580a2bd390f30 Author: Michael Tuexen AuthorDate: 2024-04-05 15:47:03 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 14:19:20 +0000 tcp rack: fix sending In rack_output(), idle is used as a boolean variable. So don't use it as an int and don't clear it afterwards. This avoids setting idle to false, when it is not intended. Reported by: olivier Reviewed by: rrs, rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44610 (cherry picked from commit 7df0ef5f48e1c67b3f1df7c7964bfa59bc56f4e4) --- sys/netinet/tcp_stacks/rack.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index fa3cd2f4f698..889622b7ff90 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -19927,6 +19927,7 @@ rack_output(struct tcpcb *tp) #endif int32_t idle, sendalot; + uint32_t tot_idle; int32_t sub_from_prr = 0; volatile int32_t sack_rxmit; struct rack_sendmap *rsm = NULL; @@ -20164,8 +20165,8 @@ rack_output(struct tcpcb *tp) if ((tp->snd_una == tp->snd_max) && rack->r_ctl.rc_went_idle_time && TSTMP_GT(cts, rack->r_ctl.rc_went_idle_time)) { - idle = cts - rack->r_ctl.rc_went_idle_time; - if (idle > rack_min_probertt_hold) { + tot_idle = (cts - rack->r_ctl.rc_went_idle_time); + if (tot_idle > rack_min_probertt_hold) { /* Count as a probe rtt */ if (rack->in_probe_rtt == 0) { rack->r_ctl.rc_lower_rtt_us_cts = cts; @@ -20176,7 +20177,6 @@ rack_output(struct tcpcb *tp) rack_exit_probertt(rack, cts); } } - idle = 0; } if (rack_use_fsb && (rack->r_ctl.fsb.tcp_ip_hdr) && From nobody Wed Apr 17 14:34:47 2024 X-Original-To: dev-commits-src-branches@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 4VKNj41VWZz5H1sd; Wed, 17 Apr 2024 14:34:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKNj36YwNz4xv9; Wed, 17 Apr 2024 14:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713364487; 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=RNiAD4nxhatRH3JCG8soeeLVRjI5ohWZymkhoYhzIAk=; b=WhdcdY+Vj7BmKPAQkuvJtXPWkwVdfsUZ7sJMRup91ZqQ3PNknBh/ybmOGohLiawL+Kdwc3 Wn2Y9XZIRveNoc4dANwcY8UkxdpNAaVJqFaENHqc4F4c0xzLGL04o5pd4RAgYbglCQ5P6d jzo6k0pDN28UoDHopQYu+wurg0uMXr3dBO+Jay2sqr+L/kdQLvs2QNawzgKu6U2sZOTPIF ckH9TPWmk7g4KSUX1LprYOwgithvm1wMYkKpOFsTznnouSOp6Sb0MKMbyC6rVci14GQWQT dpIE82DuvltmDzXquWgvs9W1bunRhUO/VyWWYgkuO5YFIWuwVYtp+7L2wyqsFg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713364487; a=rsa-sha256; cv=none; b=aEpC0VrDAVfwDFVTjZaNkDatLUCRhAuxO0kSoYTWgCY7kqGtVuhmQL9UHDVOPVeFHCb0Qu ywkU9RnGsb+njGUyOSowgkEhGPfUOp3cSJvtqWrbGX1z0r8oWPgsiHuhe2l7GEE/s32ZC0 w+gK9VWR5evBPs29Xkwp3oFJve1pZJ30Iw5AcZrzOOQS3VVHcQIQUl9BR70v1xCl/YwLke uHB8czK+yszbd5RQ5Ryfihl+KVkmZ8UitAOJl4XnhqHLdVf6OH9PqX4CFEkM2/Rr4Xl8c9 gNi+/kTD4RDUatoyoQb5amJ3JB6SBzJGswi0fN1qWkIX9lOOjHxMtcRGNNyrWw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713364487; 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=RNiAD4nxhatRH3JCG8soeeLVRjI5ohWZymkhoYhzIAk=; b=hX4M5yVHnqAhwQ84z6Smof8WPygVycQyN3lVeNowh0pxiUvpWrQ/nBWFIyy7sEx7TvYuwB oIrgvGNZG9YBiMtt871Ka+KudcoOiyPX3jQYmCOaLFgd4PAWkBcCsvhGdvgHRNm6bVbbnL UY5tpHzPBn0JznZl4YncJkqbK4qNDBK6YUjSCiH5tG8al8AdRT0oyOAAw160OKgNGVCO8p lZ3aTWdoKERnfpStM1AG5bV0OwM/u9/+qSnxrD72Wv130N85DKeIXwySqaorNdfi5IW4vU fpQOGCVxkXlx8H2HFnl/xEPwQmKakWzrBv8fX16bxJKL8Nkc3f8U/pxw1x69Jg== 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 4VKNj362twzW8r; Wed, 17 Apr 2024 14:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HEYlKi006478; Wed, 17 Apr 2024 14:34:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HEYlxM006475; Wed, 17 Apr 2024 14:34:47 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:34:47 GMT Message-Id: <202404171434.43HEYlxM006475@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 1f85f062768d - stable/14 - vm_reserv_reclaim_contig: Return NULL not false List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1f85f062768dd2c5be8bd78af56e72dd5f95950e Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=1f85f062768dd2c5be8bd78af56e72dd5f95950e commit 1f85f062768dd2c5be8bd78af56e72dd5f95950e Author: Minsoo Choo AuthorDate: 2024-04-10 12:49:26 +0000 Commit: Mark Johnston CommitDate: 2024-04-17 14:33:26 +0000 vm_reserv_reclaim_contig: Return NULL not false Reviewed by: dougm, zlei MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44667 (cherry picked from commit 989a2cf19d053954f0bad28790114a374b05c9c1) --- sys/vm/vm_reserv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/vm/vm_reserv.c b/sys/vm/vm_reserv.c index 7b4a39a34906..640a580e7edb 100644 --- a/sys/vm/vm_reserv.c +++ b/sys/vm/vm_reserv.c @@ -1192,7 +1192,7 @@ vm_reserv_find_contig(vm_reserv_t rv, int npages, int lo, * Searches the partially populated reservation queue for the least recently * changed reservation with free pages that satisfy the given request for * contiguous physical memory. If a satisfactory reservation is found, it is - * broken. Returns true if a reservation is broken and false otherwise. + * broken. Returns a page if a reservation is broken and NULL otherwise. */ vm_page_t vm_reserv_reclaim_contig(int domain, u_long npages, vm_paddr_t low, @@ -1208,7 +1208,7 @@ vm_reserv_reclaim_contig(int domain, u_long npages, vm_paddr_t low, KASSERT(powerof2(alignment), ("alignment is not a power of 2")); KASSERT(powerof2(boundary), ("boundary is not a power of 2")); if (npages > VM_LEVEL_0_NPAGES - 1) - return (false); + return (NULL); size = npages << PAGE_SHIFT; /* * Ensure that a free range starting at a boundary-multiple From nobody Wed Apr 17 14:34:48 2024 X-Original-To: dev-commits-src-branches@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 4VKNj52RRqz5H1sf; Wed, 17 Apr 2024 14:34:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKNj50mq7z4xrS; Wed, 17 Apr 2024 14:34:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713364489; 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=ew6BnP4iryXyO2xjcTmVsDBaHJiVrScJ/13irvt7/tg=; b=QCA11SP1gSsY2my+Bvm8pzX8FcgpGLvIsXoPNaQLSeNePof4Fx85w/1qPEkaSKeaOuBhMy a9pY9ZzJrAIdqWuysE9ZWbQjaQZrFJR8xA0fLZc/fGvSHABmrxbvPZj9dN0Cy1H+CWa6X3 Nv0OLrfFKQJj6Ew5Z2BQJXY52Q1Ud3p4EnqYIAGJ5iRGWbl3GUtBR7pNi0LPDO8MaBYbNg 2JLAO/wFrhGd0Ob8vqCufXpRYv33o/CZ0kjIz0zRxqzB6nGIZddsCPgwgwfE5hFbzy7Wnt hDGFDq8QVkqVT3BwCs50H8bELfRwfvJ6yMFxQY7vmg81eM+xbX2Mh+fbgRn4Nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713364489; a=rsa-sha256; cv=none; b=xXx0YWEohqez+DHtm2QrLNXFJ4I4nV7nmtg++B3uiPyAo926s+v5uHvJteNSo6i0KHBeL8 AlGCo5KO42LROveJVo1E+hNxtFoWWeaklR1o1PDYkTpNfZfYy5D+ipxvs62BuXRbshyDlc +yoScqTDK09+cFdyYg9n1QvbdwNs9r+3p3bnVryACpCVqhTB6T6PyvDg25/T7MOl3BWMpg HQu29+wj+9fv9yopM45dtiU9I2z3NAZj7wgeWEjaL5apWBgDe7qpHsSBZPeFluBlgQkiBI lblhbFuuitHLoQxAElrb6XgU3UxdEEYy5fnSBxIN+IGT18qiDI37Ifv0adReUg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713364489; 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=ew6BnP4iryXyO2xjcTmVsDBaHJiVrScJ/13irvt7/tg=; b=tqZtinrLI9UPCn6Mf7Vrdv4kPrtHVFkqL5ZypcM1YDGWMQ0qZ1Rs6my4ygWfyqew2pItHf F8d1vPHH8XlrMexcH26sMd0U7StH+6O9IPbZD6RSYwQZJQwH/yOqL0fIVZjB2mfO+Yg/ui afHSdUp9+IVYfHU6MJ/0sYl32ylNJ0ZQuDzLVTUm1U/GWekerQGNO07DWyJkDxldQfe5wU MHrXJaF7LpEFvM5vgVXfSgg53LZ7OdGa4l8zYhZwHfQKi/OAj7GvQqdVOmAMErRePR2wkd zADjYb61Ld5j5jmG74HIIMcfYaiAqFGep7zOJuQNbQyOTFl7q6Ck5WizRYq3vA== 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 4VKNj46RMqzW26; Wed, 17 Apr 2024 14:34:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43HEYmo2006522; Wed, 17 Apr 2024 14:34:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HEYmFT006519; Wed, 17 Apr 2024 14:34:48 GMT (envelope-from git) Date: Wed, 17 Apr 2024 14:34:48 GMT Message-Id: <202404171434.43HEYmFT006519@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: ca8e2e4c91cc - stable/14 - tcp: Make tcp_var.h more self-contained List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ca8e2e4c91cc40ce963b9d82531a14beb1a95e5a Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=ca8e2e4c91cc40ce963b9d82531a14beb1a95e5a commit ca8e2e4c91cc40ce963b9d82531a14beb1a95e5a Author: Mark Johnston AuthorDate: 2024-04-08 17:37:25 +0000 Commit: Mark Johnston CommitDate: 2024-04-17 14:33:27 +0000 tcp: Make tcp_var.h more self-contained struct tcpcb embeds a struct osd and a struct callout. Rather than forcing all consumers to pull in the same headers, include the headers directly. No functional change intended. Reviewed by: glebius MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44685 (cherry picked from commit 1d14e88e5332cfddbec1893f6b5332f81d378d61) --- sys/netinet/tcp_var.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index b541e3c955d9..1dc40c790b3e 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -88,6 +88,9 @@ #define TCP_EI_BITS_2MS_TIMER 0x400 /* 2 MSL timer expired */ #if defined(_KERNEL) || defined(_WANT_TCPCB) +#include +#include + #include /* TCP segment queue entry */ From nobody Thu Apr 18 00:50:37 2024 X-Original-To: dev-commits-src-branches@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 4VKfMd5Dx5z5HVD2; Thu, 18 Apr 2024 00:50:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKfMd4hJYz4ry1; Thu, 18 Apr 2024 00:50:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713401437; 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=t2+cdAcdzm15ly9OPnWgxt26+FR/apEtj341sudBBIw=; b=qSSe/5o7VdmAl2xyuIcN2zdUbVi67thpDW/TZxfS16WEDxQ4hfaLtCUH1vaW3ybm+OxvZh jDEjRmQvAxwTCyGi4OjC27czzSu6qGHJIq8bltriRdiihQom59qZ866rQKNA7+O9TbN1A4 c/JPZcoj6lqZYuQaVg3SgVYBnmY9MtSzGnxJPZg1Dzx3cynu7koeu/VHpVLsyFvEjyEwqg Z2kH4cMoFmEqKu7INlpsmpIpS+/JkSW007Pb6PZhaYnh1huf+R7hgniDXF9sJ0xPq4mSP+ RfjFBKK8ABap2hv3iBy7OaBDO9khBbWCHAPWitFkyEp+OSUPTYVUwLo/u2s5Ig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713401437; a=rsa-sha256; cv=none; b=Bh/h5KEDDK6HOCfPLLNOONmBwg1tMtIfk/zPp2BX6doJt3QA5KajPqQSJaX7J2LD5YmPn6 eCNXT5hvHPR7NQDnoBgk1sb84nv5GkzI3RQCyLEAxtA3LQz0sn5C/lMNksL64TjO4ZKREd 3xs4VIctlWAxKxP3aMwo+Ql1XbZMPWDYWBRAJA1rOej15gnd/ZP1ZSbYYet46NlP9ARtcm y8aPkyy0+EUMjpxyrfHGeJS2BI1EH0Y3r6E7W3DVTEuiutUPAbightK8E36Hz3hrXzpeeq P1bR9jinBf2CfuUNmPXxcJ6veALX/i9pwhCDEpat2J5IYHXkJOK3mLVlJ8vIAw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713401437; 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=t2+cdAcdzm15ly9OPnWgxt26+FR/apEtj341sudBBIw=; b=uYXVWgqqL4Kf5Oytqk39MFRst8kp9bcStLfrMnZmrOC/qbtmZLt/wcv0PIDWMsCchcwvU9 2+qY19OJ8VaKRqesjra4JqJuJC4c5GmdYB0LUjf9u84yE0By2D2SQJTfObiZz7ojd3VTqL 0Xu/54k6yV+KJDx049q0jvQahjJu9z8+K/80X+7WRPIXtnxHazCLzvKuOn/E75ArVTnWBF Cd4KPZ8Dl5vAbSLIWkIvXJx7lyu2fJLMhjTOfqB04y6oee6JFqO3e2MEreBUz/KXSvvlfe lrswqwDIOmMrvUcjJRTAIOY3DyWxWhiUac1hxirU+XS3Ko4jXPB1YgtdzFKB6Q== 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 4VKfMd4JL9zp7q; Thu, 18 Apr 2024 00:50:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43I0obua046966; Thu, 18 Apr 2024 00:50:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43I0obsM046963; Thu, 18 Apr 2024 00:50:37 GMT (envelope-from git) Date: Thu, 18 Apr 2024 00:50:37 GMT Message-Id: <202404180050.43I0obsM046963@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Rick Macklem Subject: git: 40631b79b5fe - stable/14 - nfscl: Purge name cache when readdir_plus is done List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 40631b79b5fedc53045c98eccb0e38e6c3d27ba8 Auto-Submitted: auto-generated The branch stable/14 has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=40631b79b5fedc53045c98eccb0e38e6c3d27ba8 commit 40631b79b5fedc53045c98eccb0e38e6c3d27ba8 Author: Zaphrod Beeblebrox AuthorDate: 2024-04-11 20:27:27 +0000 Commit: Rick Macklem CommitDate: 2024-04-18 00:49:10 +0000 nfscl: Purge name cache when readdir_plus is done The author reported that this patch was needed to avoid crashes on a fairly busy RISC-V system. The author did not provide details w.r.t. the crashes. Although I have not seen any such crash, the patch looks reasonable and I have not found any regressions when testing it. Since "rdirplus" is not a default option, the patch is only needed if you are doing NFS mounts with the "rdirplus" mount option and seeing crashes related to the name cache. (cherry picked from commit d00c64bb2347cc620d31a178c7755aa7e594f065) --- sys/fs/nfsclient/nfs_clvnops.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c index 0b8c587a542c..85c0ebd7a10f 100644 --- a/sys/fs/nfsclient/nfs_clvnops.c +++ b/sys/fs/nfsclient/nfs_clvnops.c @@ -2459,6 +2459,16 @@ nfs_readdir(struct vop_readdir_args *ap) return (EINVAL); uio->uio_resid -= left; + /* + * For readdirplus, if starting to read the directory, + * purge the name cache, since it will be reloaded by + * this directory read. + * This removes potentially stale name cache entries. + */ + if (uio->uio_offset == 0 && + (VFSTONFS(vp->v_mount)->nm_flag & NFSMNT_RDIRPLUS) != 0) + cache_purge(vp); + /* * Call ncl_bioread() to do the real work. */ From nobody Thu Apr 18 04:34:38 2024 X-Original-To: dev-commits-src-branches@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 4VKlL66Fqjz5Hpgj; Thu, 18 Apr 2024 04:34:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKlL64L5nz4Kqx; Thu, 18 Apr 2024 04:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713414878; 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=cXmvgbDl3J2HPH/zgY2G+tMcp1gW8SciXt5yDILvXAU=; b=sm3+J+GparfmJtN891o8bIM7SHgGMF27Ubh6+12RSLj05WmFHSOuRtJpsmJ4ZW4a0WH2eB x0dPLfCjA2Q0DS1mAqurA+Td+7mX3DfWD5daCu5b8vxJ9Z59r4xhOhw5zqbHf/0eJmR+4G IFw9iMyXvqfcidDJFMbMGnhPK+tW0MVU8+h37s6AtfDPq4FQAXZJuR6OhpqW74pyLReVfJ t+oM/X7QR79cYCbfLeuNXS0WQOwYWif0IqSFSBtzcReZ1pAahzvsLu3GbIElM1vYdqItzX EQl5mgcUxndy3xMI91TySSIi0TFc6052FJ191mWq9FUnz1X94AJR3ity8wbinA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713414878; a=rsa-sha256; cv=none; b=cugANVLOEUyHDm5z50h+vtB5nw2PI/vQhNN5lddMkboRJXyWincILVUFAEQDczIXsX4Edi Kw8PtDNaJeiy6S7j+EzFcDocvl+o3s9UmUtxvdwTvV+8eMIs7ykDiyBRYpekbH3kjWN6yp QKcMFJ8Z1w2P3fsXNlACY59aR3G3vr+CfbG6UcQn0EsReoovw/5VIJETPgMjcvBpvZeMDY TFcOfy0av/+AdyH6VyS8Ad6Zke9jCyQppSrfQaa68+p7JC8p3gQ1cpRz6fqL/aH1Ae3iFI OuNU8TkRTDovMqhx7sDcsitoJklONUqgRv57R3Yla+qiXpyfpuDyaVlYRVekTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713414878; 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=cXmvgbDl3J2HPH/zgY2G+tMcp1gW8SciXt5yDILvXAU=; b=XE3i6JAaHqml2TOCsvlMg0g9KSItcgrIZFvb98lQoca2+LQsfTxvwLfBzON1ug4UISZy1j P1mDW82msxOzsxSsj36ZgST5NE9UGHKlsNH02Zg6pX5m5qz+YXuQIwpc782lLP95XmwGnL WqAJY+dZ6EDHxJFofjhc14PkU9WJvr1LFiyD4/CkQUGu3Mx4BLpAIH4orLy1W1n31kWWkf SFJHgD0nq6UUMZmhCRDXy+CV1e5BFzIIXtPcUvRMSvZ40f3Un2glGaz0tujVDGZaoFayfK fdWDMEzyy25qxF283SmyXEMSoqKSox0G3KJX8l1Ntt7OJ6pJnnZVmZCf8SGQJw== 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 4VKlL63b9LzwCg; Thu, 18 Apr 2024 04:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43I4Ycpx024922; Thu, 18 Apr 2024 04:34:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43I4YcQY024919; Thu, 18 Apr 2024 04:34:38 GMT (envelope-from git) Date: Thu, 18 Apr 2024 04:34:38 GMT Message-Id: <202404180434.43I4YcQY024919@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: cfa4bd59df08 - stable/14 - atrtc(4): Fix a typo in a sysctl description List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cfa4bd59df081c0bd8c38201c6019e45c7827887 Auto-Submitted: auto-generated The branch stable/14 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=cfa4bd59df081c0bd8c38201c6019e45c7827887 commit cfa4bd59df081c0bd8c38201c6019e45c7827887 Author: Gordon Bergling AuthorDate: 2024-04-12 12:32:48 +0000 Commit: Gordon Bergling CommitDate: 2024-04-18 04:34:26 +0000 atrtc(4): Fix a typo in a sysctl description - s/emtpy/empty/ (cherry picked from commit 38cc6c3d95d4d1156960a9c5ba69c360e36f9976) --- sys/x86/isa/atrtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/x86/isa/atrtc.c b/sys/x86/isa/atrtc.c index 7c42cc28566e..df0acdd499be 100644 --- a/sys/x86/isa/atrtc.c +++ b/sys/x86/isa/atrtc.c @@ -62,7 +62,7 @@ /* tunable to detect a power loss of the rtc */ static bool atrtc_power_lost = false; SYSCTL_BOOL(_machdep, OID_AUTO, atrtc_power_lost, CTLFLAG_RD, &atrtc_power_lost, - false, "RTC lost power on last power cycle (probably caused by an emtpy cmos battery)"); + false, "RTC lost power on last power cycle (probably caused by an empty cmos battery)"); /* * atrtc_lock protects low-level access to individual hardware registers. From nobody Thu Apr 18 04:35:03 2024 X-Original-To: dev-commits-src-branches@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 4VKlLc0Sfnz5HpbB; Thu, 18 Apr 2024 04:35:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKlLb73Psz4L64; Thu, 18 Apr 2024 04:35:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713414904; 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=F20caYa1nAQazKJwdH8kx99Y5jY/O0Tq2Sdt4z1AFRg=; b=UjxyEhfCyt5JZ1cN+h260YJR5bA47HkGQRj+jfnVnQKwd6PsUdvpHPIGHQd2Cmhg5p6A7r AP82JKGr3jBW+xTbApaltnD9ABq9CqyZepPB/aobfwIGM1KDzQV9Jl1Db7MyKZMQhWXH5c +BXpmZXcHKTthdBt+YSceQgKslgr8QMRXpFqMyE10A9AlV+q0tkQjQWPp8UI6+gMGKXvjv 7Gt4GvJ7sL0tF17LhpUy+YR9QjE+kgH6EGZaI5RGOOcahGWYBgY0auBegyVr44MOYLVXvQ HU3QuwRHlwea58JI449SVx/+66ZMYitLgPypejjIxr3v4k++8csbdC7gZ+HSgQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713414904; a=rsa-sha256; cv=none; b=Gvd4Yii3GoRqu0r8GfahIabq1OLigpmH/KlYu3LfeMwHRjkw2BrgLvqwCkSvdLGGfTqBfy vsv0DlfAwVkuogau79629mHNKfkTaXwc6xqmDubvQqZx6KtCST5voYorbYNAVDW+x+iQ/g 05xbxrx+iPdCFsXBz0bKY10tWsuDIyTDgY9kYmXbqlSv8msKmVYowKhEIvA2Q3a0IOXrVB dq30OP5Btm4K98OrVyDwDCduUsB9m2PiFUfr0QtxiZY5biROL/k2VcKnnOFkpL4LWOVtTc JqeW4UAPil23Ofpodlb5NGLRy4RuADfioQm03D2tVBWEPuezkj8BFjqXJsMGIw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713414904; 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=F20caYa1nAQazKJwdH8kx99Y5jY/O0Tq2Sdt4z1AFRg=; b=BGBNCvVUy5IUPtguK5x5KFjaHf377aKU9qgTRZLn1PZNI6tNX9uHMsWFAA1qUULjgRv1TY 3cy0u4JRU5DT2XxVPw5DQ0HKPvIK1HyWkQn1KBj7GcxOsFhPl/eeduFuBYeYRGXWT6upc8 NeVlZqneCzUltjy6n9MqE65OvX54c3z+pYiY9GmEKqnCD3lUBKqS26tWG/Q8cSFKd8DPNw R52rEqOuk8KI0BD9ydHxL88gkeNnVVYP4rFKxCBCkJlBAeDzvZqG/ABSh157XnXvfB6hL6 bN0FTou4oQcE40cgQRduadyIkHB1Ipz1jssSpXiPJNgto3qa8+RWG87N2MrZuA== 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 4VKlLb6g0ZzwCh; Thu, 18 Apr 2024 04:35:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43I4Z3I4025112; Thu, 18 Apr 2024 04:35:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43I4Z3EG025109; Thu, 18 Apr 2024 04:35:03 GMT (envelope-from git) Date: Thu, 18 Apr 2024 04:35:03 GMT Message-Id: <202404180435.43I4Z3EG025109@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: da013f1d5fee - stable/13 - atrtc(4): Fix a typo in a sysctl description List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: da013f1d5feeaab20caa0769f52cfbab3718b943 Auto-Submitted: auto-generated The branch stable/13 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=da013f1d5feeaab20caa0769f52cfbab3718b943 commit da013f1d5feeaab20caa0769f52cfbab3718b943 Author: Gordon Bergling AuthorDate: 2024-04-12 12:32:48 +0000 Commit: Gordon Bergling CommitDate: 2024-04-18 04:34:52 +0000 atrtc(4): Fix a typo in a sysctl description - s/emtpy/empty/ (cherry picked from commit 38cc6c3d95d4d1156960a9c5ba69c360e36f9976) --- sys/x86/isa/atrtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/x86/isa/atrtc.c b/sys/x86/isa/atrtc.c index 102f93feeadf..668834307eb2 100644 --- a/sys/x86/isa/atrtc.c +++ b/sys/x86/isa/atrtc.c @@ -62,7 +62,7 @@ /* tunable to detect a power loss of the rtc */ static bool atrtc_power_lost = false; SYSCTL_BOOL(_machdep, OID_AUTO, atrtc_power_lost, CTLFLAG_RD, &atrtc_power_lost, - false, "RTC lost power on last power cycle (probably caused by an emtpy cmos battery)"); + false, "RTC lost power on last power cycle (probably caused by an empty cmos battery)"); /* * atrtc_lock protects low-level access to individual hardware registers. From nobody Thu Apr 18 12:39:56 2024 X-Original-To: dev-commits-src-branches@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 4VKy6509XQz5Gn4p; Thu, 18 Apr 2024 12:39:57 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKy6474M5z44Qs; Thu, 18 Apr 2024 12:39:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443997; 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=VgX5CqsLXcf0XS5J54f9c6Wk1lAqKGLtNdhYIVLCak8=; b=Agd9iG4rAtxyhoK8rQPBzChr5leV+mya2MPciidazd9FQ7UAsabwQl9sXn86maBE0OPzOS H/RsATcwNyM9NnpW2L9fqCwYfQoOA7++fInRR/uxgrjcZ5FMM7RcRDY1Dj4uAyk8mT9yox bvkCZNs0NPj3hQBi6vaIjfnD3TzrG/v3aq6YpHSIFbacerKoGR0ij49jqJd4AlpY4EVNoq WToC0EOVK/FcGp7v8hOkHYh5wBMfEXG4OCvPGRQnFGTPSPbekO8oV4tBkeiaHRun4ELEVT KGqgSHzKQpLfLc9yYVv17MEn2QbHoeRR7P+pgqPoZ5U8FSG+yT9TOWrQYcc6xA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713443997; a=rsa-sha256; cv=none; b=N3lhvugmKv9Y+xmFgpxUvVh0M33IvsX404njuKHyTxFcwsbDGiyZ8ONL1Uuy6qhE9i2Tn8 RJN3hgbAgs0N+OkOlcAfuCAP9lxIxnOJtI3tfb7WA0muGf5D3mCZdQAW744UmpDOixZGpd uXsvEViLnV6SfWXmi+Znm2mn4sAA+UjEF/tIRtN44RaCn1arWpY3Ez9TaXAtBCLt/gHcXO Io6F42GSvSHpqFC5b9Ktm0w5Ijtj1QtKVnlLstbSzk44uShNnL9sQpqFouo4iKYiKRDB9a cTNOOColFITKdqeIUDKdvOsqaJNUQvLtN21WRz2rMh36bgeZ08UnRX95GiqfcQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443997; 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=VgX5CqsLXcf0XS5J54f9c6Wk1lAqKGLtNdhYIVLCak8=; b=BXtsSJ1Kc4z7NykDOPgQXL/niScrgPgSIDrIfgM6zmyHd2PWB6Jt2h6HlqjU+6MogSVfo2 2jLm7XodRHl33drQMD77Hiif3pgtJuNnscfera+C2oO5WFneF/mtGf8RWT9HXAXHTerH43 q2gxtKchPIMdQLV6OaVoSuwlv3kJm+p4Ry72B+g9V33/LtEGOE74cJit2yTjfHGKUVSNfu ZH2osljS2JCtTLMtUSBMR/aNcfH7/QN1ji//7ETsu/V+mjEoXrhylsBxFxkscf4ED36nxW e0pogOoy7gQKQyhCfauurl0p/cyqP04HPc8m651Eka4cHdDNsb3PWBagAGtUgw== 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 4VKy646gQPz18hJ; Thu, 18 Apr 2024 12:39:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43ICdudp036146; Thu, 18 Apr 2024 12:39:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43ICduRF036144; Thu, 18 Apr 2024 12:39:56 GMT (envelope-from git) Date: Thu, 18 Apr 2024 12:39:56 GMT Message-Id: <202404181239.43ICduRF036144@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: e6c51f6db8d7 - stable/14 - sound: Get rid of snd_clone and use DEVFS_CDEVPRIV(9) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e6c51f6db8d7126b1040af5e5544a9b1208519f4 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=e6c51f6db8d7126b1040af5e5544a9b1208519f4 commit e6c51f6db8d7126b1040af5e5544a9b1208519f4 Author: Christos Margiolis AuthorDate: 2024-04-11 18:06:30 +0000 Commit: Christos Margiolis CommitDate: 2024-04-18 12:39:26 +0000 sound: Get rid of snd_clone and use DEVFS_CDEVPRIV(9) Currently the snd_clone framework creates device nodes on-demand for every channel, through the dsp_clone() callback, and is responsible for routing audio to the appropriate channel(s). This patch gets rid of the whole snd_clone framework (including any related sysctls) and instead uses DEVFS_CDEVPRIV(9) to handle device opening, channel allocation and audio routing. This results in a significant reduction in code size as well as complexity. Behavior that is preserved: - hw.snd.basename_clone. - Exclusive access of an audio device (i.e VCHANs disabled). - Multiple processes can read from/write to the device. - A device can only be opened as many times as the maximum allowed channel number (see SND_MAXHWCHAN in pcm/sound.h). - OSSv4 compatibility aliases are preserved. Behavior changes: Only one /dev/dspX device node is created (on attach) for each audio device, as opposed to the current /dev/dspX.Y devices created by snd_clone. According to the sound(4) man page, devices are not meant to be opened through /dev/dspX.Y anyway, so it is best if we do not create device nodes for them in the first place. As a result of this, modify dsp_oss_audioinfo() to print /dev/dspX in the "ai->devnode", instead of /dev/dspX.Y. Sponsored by: The FreeBSD Foundation MFC after: 2 months Reviewed by: dev_submerge.ch, bapt, markj Differential Revision: https://reviews.freebsd.org/D44411 (cherry picked from commit e8c0d15a64fadb4a330f2da7244becaac161bb70) --- share/man/man4/pcm.4 | 53 +- sys/conf/files | 1 - sys/dev/sound/clone.c | 705 ------------------------- sys/dev/sound/clone.h | 127 ----- sys/dev/sound/pcm/dsp.c | 1051 ++++++++++++-------------------------- sys/dev/sound/pcm/dsp.h | 7 +- sys/dev/sound/pcm/sound.c | 194 +------ sys/dev/sound/pcm/sound.h | 6 +- sys/modules/sound/sound/Makefile | 2 +- 9 files changed, 332 insertions(+), 1814 deletions(-) diff --git a/share/man/man4/pcm.4 b/share/man/man4/pcm.4 index 17ac499e6bb3..e406bd2c8343 100644 --- a/share/man/man4/pcm.4 +++ b/share/man/man4/pcm.4 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd January 10, 2024 +.Dd March 24, 2024 .Dt SOUND 4 .Os .Sh NAME @@ -513,14 +513,6 @@ device state on each tick using a mechanism. Disabled by default and currently only available for a few device drivers. .El -.Ss Recording Channels -On devices that have more than one recording source (ie: mic and line), -there is a corresponding -.Pa /dev/dsp%d.r%d -device. -The -.Xr mixer 8 -utility can be used to start and stop recording from an specific device. .Ss Statistics Channel statistics are only kept while the device is open. So with situations involving overruns and underruns, consider the output @@ -542,36 +534,24 @@ functions. .Sh FILES The .Nm -drivers may create the following -device nodes: +drivers may create the following device nodes: .Pp -.Bl -tag -width ".Pa /dev/audio%d.%d" -compact -.It Pa /dev/audio%d.%d -Sparc-compatible audio device. -.It Pa /dev/dsp%d.%d -Digitized voice device. -.It Pa /dev/dspW%d.%d -Like -.Pa /dev/dsp , -but 16 bits per sample. -.It Pa /dev/dsp%d.p%d -Playback channel. -.It Pa /dev/dsp%d.r%d -Record channel. -.It Pa /dev/dsp%d.vp%d -Virtual playback channel. -.It Pa /dev/dsp%d.vr%d -Virtual recording channel. +.Bl -tag -width ".Pa /dev/sndstat" -compact +.It Pa /dev/dsp%d +Audio device. +The number represents the unit number of the device. +.It Pa /dev/dsp +Alias of +.Pa /dev/dsp${hw.snd.default_unit} . +Available only if +.Pa hw.snd.basename_clone +is set. .It Pa /dev/sndstat Current .Nm status, including all channels and drivers. .El .Pp -The first number in the device node -represents the unit number of the -.Nm -device. All .Nm devices are listed @@ -581,15 +561,6 @@ Additional messages are sometimes recorded when the device is probed and attached, these messages can be viewed with the .Xr dmesg 8 utility. -.Pp -The above device nodes are only created on demand through the dynamic -.Xr devfs 5 -clone handler. -Users are strongly discouraged to access them directly. -For specific sound card access, please instead use -.Pa /dev/dsp -or -.Pa /dev/dsp%d . .Sh EXAMPLES Use the sound metadriver to load all .Nm diff --git a/sys/conf/files b/sys/conf/files index 0bfced5287ec..c4e9f0698c4f 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -3060,7 +3060,6 @@ dev/smc/if_smc.c optional smc dev/smc/if_smc_acpi.c optional smc acpi dev/smc/if_smc_fdt.c optional smc fdt dev/snp/snp.c optional snp -dev/sound/clone.c optional sound dev/sound/unit.c optional sound dev/sound/pci/als4000.c optional snd_als4000 pci dev/sound/pci/atiixp.c optional snd_atiixp pci diff --git a/sys/dev/sound/clone.c b/sys/dev/sound/clone.c deleted file mode 100644 index 4cac5f050ee2..000000000000 --- a/sys/dev/sound/clone.c +++ /dev/null @@ -1,705 +0,0 @@ -/*- - * SPDX-License-Identifier: BSD-2-Clause - * - * Copyright (c) 2007 Ariff Abdullah - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include -#include -#include -#include -#include -#include - -#ifdef HAVE_KERNEL_OPTION_HEADERS -#include "opt_snd.h" -#endif - -#if defined(SND_DIAGNOSTIC) || defined(SND_DEBUG) -#include -#endif - -#include - -/* - * So here we go again, another clonedevs manager. Unlike default clonedevs, - * this clone manager is designed to withstand various abusive behavior - * (such as 'while : ; do ls /dev/whatever ; done', etc.), reusable object - * after reaching certain expiration threshold, aggressive garbage collector, - * transparent device allocator and concurrency handling across multiple - * thread/proc. Due to limited information given by dev_clone EVENTHANDLER, - * we don't have much clues whether the caller wants a real open() or simply - * making fun of us with things like stat(), mtime() etc. Assuming that: - * 1) Time window between dev_clone EH <-> real open() should be small - * enough and 2) mtime()/stat() etc. always looks like a half way / stalled - * operation, we can decide whether a new cdev must be created, old - * (expired) cdev can be reused or an existing cdev can be shared. - * - * Most of the operations and logics are generic enough and can be applied - * on other places (such as if_tap, snp, etc). Perhaps this can be - * rearranged to complement clone_*(). However, due to this still being - * specific to the sound driver (and as a proof of concept on how it can be - * done), si_drv2 is used to keep the pointer of the clone list entry to - * avoid expensive lookup. - */ - -/* clone entry */ -struct snd_clone_entry { - TAILQ_ENTRY(snd_clone_entry) link; - struct snd_clone *parent; - struct cdev *devt; - struct timespec tsp; - uint32_t flags; - pid_t pid; - int unit; -}; - -/* clone manager */ -struct snd_clone { - TAILQ_HEAD(link_head, snd_clone_entry) head; - struct timespec tsp; - int refcount; - int size; - int typemask; - int maxunit; - int deadline; - uint32_t flags; -}; - -#ifdef SND_DIAGNOSTIC -#define SND_CLONE_ASSERT(x, y) do { \ - if (!(x)) \ - panic y; \ -} while (0) -#else -#define SND_CLONE_ASSERT(...) KASSERT(__VA_ARGS__) -#endif - -/* - * snd_clone_create() : Return opaque allocated clone manager. - */ -struct snd_clone * -snd_clone_create(int typemask, int maxunit, int deadline, uint32_t flags) -{ - struct snd_clone *c; - - SND_CLONE_ASSERT(!(typemask & ~SND_CLONE_MAXUNIT), - ("invalid typemask: 0x%08x", typemask)); - SND_CLONE_ASSERT(maxunit == -1 || - !(maxunit & ~(~typemask & SND_CLONE_MAXUNIT)), - ("maxunit overflow: typemask=0x%08x maxunit=%d", - typemask, maxunit)); - SND_CLONE_ASSERT(!(flags & ~SND_CLONE_MASK), - ("invalid clone flags=0x%08x", flags)); - - c = malloc(sizeof(*c), M_DEVBUF, M_WAITOK | M_ZERO); - c->refcount = 0; - c->size = 0; - c->typemask = typemask; - c->maxunit = (maxunit == -1) ? (~typemask & SND_CLONE_MAXUNIT) : - maxunit; - c->deadline = deadline; - c->flags = flags; - getnanouptime(&c->tsp); - TAILQ_INIT(&c->head); - - return (c); -} - -int -snd_clone_busy(struct snd_clone *c) -{ - struct snd_clone_entry *ce; - - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - if (c->size == 0) - return (0); - - TAILQ_FOREACH(ce, &c->head, link) { - if ((ce->flags & SND_CLONE_BUSY) || - (ce->devt != NULL && ce->devt->si_threadcount != 0)) - return (EBUSY); - } - - return (0); -} - -/* - * snd_clone_enable()/disable() : Suspend/resume clone allocation through - * snd_clone_alloc(). Everything else will not be affected by this. - */ -int -snd_clone_enable(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - if (c->flags & SND_CLONE_ENABLE) - return (EINVAL); - - c->flags |= SND_CLONE_ENABLE; - - return (0); -} - -int -snd_clone_disable(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - if (!(c->flags & SND_CLONE_ENABLE)) - return (EINVAL); - - c->flags &= ~SND_CLONE_ENABLE; - - return (0); -} - -/* - * Getters / Setters. Not worth explaining :) - */ -int -snd_clone_getsize(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - return (c->size); -} - -int -snd_clone_getmaxunit(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - return (c->maxunit); -} - -int -snd_clone_setmaxunit(struct snd_clone *c, int maxunit) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - SND_CLONE_ASSERT(maxunit == -1 || - !(maxunit & ~(~c->typemask & SND_CLONE_MAXUNIT)), - ("maxunit overflow: typemask=0x%08x maxunit=%d", - c->typemask, maxunit)); - - c->maxunit = (maxunit == -1) ? (~c->typemask & SND_CLONE_MAXUNIT) : - maxunit; - - return (c->maxunit); -} - -int -snd_clone_getdeadline(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - return (c->deadline); -} - -int -snd_clone_setdeadline(struct snd_clone *c, int deadline) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - c->deadline = deadline; - - return (c->deadline); -} - -uint32_t -snd_clone_getflags(struct snd_clone *c) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - return (c->flags); -} - -uint32_t -snd_clone_setflags(struct snd_clone *c, uint32_t flags) -{ - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - SND_CLONE_ASSERT(!(flags & ~SND_CLONE_MASK), - ("invalid clone flags=0x%08x", flags)); - - c->flags = flags; - - return (c->flags); -} - -uint32_t -snd_clone_getdevflags(struct cdev *dev) -{ - struct snd_clone_entry *ce; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - - ce = dev->si_drv2; - if (ce == NULL) - return (0xffffffff); - - SND_CLONE_ASSERT(ce->parent != NULL, ("NULL parent")); - - return (ce->flags); -} - -uint32_t -snd_clone_setdevflags(struct cdev *dev, uint32_t flags) -{ - struct snd_clone_entry *ce; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - SND_CLONE_ASSERT(!(flags & ~SND_CLONE_DEVMASK), - ("invalid clone dev flags=0x%08x", flags)); - - ce = dev->si_drv2; - if (ce == NULL) - return (0xffffffff); - - SND_CLONE_ASSERT(ce->parent != NULL, ("NULL parent")); - - ce->flags = flags; - - return (ce->flags); -} - -/* Elapsed time conversion to ms */ -#define SND_CLONE_ELAPSED(x, y) \ - ((((x)->tv_sec - (y)->tv_sec) * 1000) + \ - (((y)->tv_nsec > (x)->tv_nsec) ? \ - (((1000000000L + (x)->tv_nsec - \ - (y)->tv_nsec) / 1000000) - 1000) : \ - (((x)->tv_nsec - (y)->tv_nsec) / 1000000))) - -#define SND_CLONE_EXPIRED(x, y, z) \ - ((x)->deadline < 1 || \ - ((y)->tv_sec - (z)->tv_sec) > ((x)->deadline / 1000) || \ - SND_CLONE_ELAPSED(y, z) > (x)->deadline) - -/* - * snd_clone_gc() : Garbage collector for stalled, expired objects. Refer to - * clone.h for explanations on GC settings. - */ -int -snd_clone_gc(struct snd_clone *c) -{ - struct snd_clone_entry *ce, *tce; - struct timespec now; - int pruned; - - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - if (!(c->flags & SND_CLONE_GC_ENABLE) || c->size == 0) - return (0); - - getnanouptime(&now); - - /* - * Bail out if the last clone handler was invoked below the deadline - * threshold. - */ - if ((c->flags & SND_CLONE_GC_EXPIRED) && - !SND_CLONE_EXPIRED(c, &now, &c->tsp)) - return (0); - - pruned = 0; - - /* - * Visit each object in reverse order. If the object is still being - * referenced by a valid open(), skip it. Look for expired objects - * and either revoke its clone invocation status or mercilessly - * throw it away. - */ - TAILQ_FOREACH_REVERSE_SAFE(ce, &c->head, link_head, link, tce) { - if (!(ce->flags & SND_CLONE_BUSY) && - (!(ce->flags & SND_CLONE_INVOKE) || - SND_CLONE_EXPIRED(c, &now, &ce->tsp))) { - if ((c->flags & SND_CLONE_GC_REVOKE) || - ce->devt->si_threadcount != 0) { - ce->flags &= ~SND_CLONE_INVOKE; - ce->pid = -1; - } else { - TAILQ_REMOVE(&c->head, ce, link); - destroy_dev(ce->devt); - free(ce, M_DEVBUF); - c->size--; - } - pruned++; - } - } - - /* return total pruned objects */ - return (pruned); -} - -void -snd_clone_destroy(struct snd_clone *c) -{ - struct snd_clone_entry *ce, *tmp; - - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - - ce = TAILQ_FIRST(&c->head); - while (ce != NULL) { - tmp = TAILQ_NEXT(ce, link); - if (ce->devt != NULL) - destroy_dev(ce->devt); - free(ce, M_DEVBUF); - ce = tmp; - } - - free(c, M_DEVBUF); -} - -/* - * snd_clone_acquire() : The vital part of concurrency management. Must be - * called somewhere at the beginning of open() handler. ENODEV is not really - * fatal since it just tell the caller that this is not cloned stuff. - * EBUSY is *real*, don't forget that! - */ -int -snd_clone_acquire(struct cdev *dev) -{ - struct snd_clone_entry *ce; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - - ce = dev->si_drv2; - if (ce == NULL) - return (ENODEV); - - SND_CLONE_ASSERT(ce->parent != NULL, ("NULL parent")); - - ce->flags &= ~SND_CLONE_INVOKE; - - if (ce->flags & SND_CLONE_BUSY) - return (EBUSY); - - ce->flags |= SND_CLONE_BUSY; - - return (0); -} - -/* - * snd_clone_release() : Release busy status. Must be called somewhere at - * the end of close() handler, or somewhere after fail open(). - */ -int -snd_clone_release(struct cdev *dev) -{ - struct snd_clone_entry *ce; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - - ce = dev->si_drv2; - if (ce == NULL) - return (ENODEV); - - SND_CLONE_ASSERT(ce->parent != NULL, ("NULL parent")); - - ce->flags &= ~SND_CLONE_INVOKE; - - if (!(ce->flags & SND_CLONE_BUSY)) - return (EBADF); - - ce->flags &= ~SND_CLONE_BUSY; - ce->pid = -1; - - return (0); -} - -/* - * snd_clone_ref/unref() : Garbage collector reference counter. To make - * garbage collector run automatically, the sequence must be something like - * this (both in open() and close() handlers): - * - * open() - 1) snd_clone_acquire() - * 2) .... check check ... if failed, snd_clone_release() - * 3) Success. Call snd_clone_ref() - * - * close() - 1) .... check check check .... - * 2) Success. snd_clone_release() - * 3) snd_clone_unref() . Garbage collector will run at this point - * if this is the last referenced object. - */ -int -snd_clone_ref(struct cdev *dev) -{ - struct snd_clone_entry *ce; - struct snd_clone *c; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - - ce = dev->si_drv2; - if (ce == NULL) - return (0); - - c = ce->parent; - SND_CLONE_ASSERT(c != NULL, ("NULL parent")); - SND_CLONE_ASSERT(c->refcount >= 0, ("refcount < 0")); - - return (++c->refcount); -} - -int -snd_clone_unref(struct cdev *dev) -{ - struct snd_clone_entry *ce; - struct snd_clone *c; - - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - - ce = dev->si_drv2; - if (ce == NULL) - return (0); - - c = ce->parent; - SND_CLONE_ASSERT(c != NULL, ("NULL parent")); - SND_CLONE_ASSERT(c->refcount > 0, ("refcount <= 0")); - - c->refcount--; - - /* - * Run automatic garbage collector, if needed. - */ - if ((c->flags & SND_CLONE_GC_UNREF) && - (!(c->flags & SND_CLONE_GC_LASTREF) || - (c->refcount == 0 && (c->flags & SND_CLONE_GC_LASTREF)))) - (void)snd_clone_gc(c); - - return (c->refcount); -} - -void -snd_clone_register(struct snd_clone_entry *ce, struct cdev *dev) -{ - SND_CLONE_ASSERT(ce != NULL, ("NULL snd_clone_entry")); - SND_CLONE_ASSERT(dev != NULL, ("NULL dev")); - SND_CLONE_ASSERT(dev->si_drv2 == NULL, ("dev->si_drv2 not NULL")); - SND_CLONE_ASSERT((ce->flags & SND_CLONE_ALLOC) == SND_CLONE_ALLOC, - ("invalid clone alloc flags=0x%08x", ce->flags)); - SND_CLONE_ASSERT(ce->devt == NULL, ("ce->devt not NULL")); - SND_CLONE_ASSERT(ce->unit == dev2unit(dev), - ("invalid unit ce->unit=0x%08x dev2unit=0x%08x", - ce->unit, dev2unit(dev))); - - SND_CLONE_ASSERT(ce->parent != NULL, ("NULL parent")); - - dev->si_drv2 = ce; - ce->devt = dev; - ce->flags &= ~SND_CLONE_ALLOC; - ce->flags |= SND_CLONE_INVOKE; -} - -struct snd_clone_entry * -snd_clone_alloc(struct snd_clone *c, struct cdev **dev, int *unit, int tmask) -{ - struct snd_clone_entry *ce, *after, *bce, *cce, *nce, *tce; - struct timespec now; - int cunit, allocunit; - pid_t curpid; - - SND_CLONE_ASSERT(c != NULL, ("NULL snd_clone")); - SND_CLONE_ASSERT(dev != NULL, ("NULL dev pointer")); - SND_CLONE_ASSERT((c->typemask & tmask) == tmask, - ("invalid tmask: typemask=0x%08x tmask=0x%08x", - c->typemask, tmask)); - SND_CLONE_ASSERT(unit != NULL, ("NULL unit pointer")); - SND_CLONE_ASSERT(*unit == -1 || !(*unit & (c->typemask | tmask)), - ("typemask collision: typemask=0x%08x tmask=0x%08x *unit=%d", - c->typemask, tmask, *unit)); - - if (!(c->flags & SND_CLONE_ENABLE) || - (*unit != -1 && *unit > c->maxunit)) - return (NULL); - - ce = NULL; - after = NULL; - bce = NULL; /* "b"usy candidate */ - cce = NULL; /* "c"urthread/proc candidate */ - nce = NULL; /* "n"ull, totally unbusy candidate */ - tce = NULL; /* Last "t"ry candidate */ - cunit = 0; - allocunit = (*unit == -1) ? 0 : *unit; - curpid = curthread->td_proc->p_pid; - - getnanouptime(&now); - - TAILQ_FOREACH(ce, &c->head, link) { - /* - * Sort incrementally according to device type. - */ - if (tmask > (ce->unit & c->typemask)) { - if (cunit == 0) - after = ce; - continue; - } else if (tmask < (ce->unit & c->typemask)) - break; - - /* - * Shoot.. this is where the grumpiness begin. Just - * return immediately. - */ - if (*unit != -1 && *unit == (ce->unit & ~tmask)) - goto snd_clone_alloc_out; - - cunit++; - /* - * Simmilar device type. Sort incrementally according - * to allocation unit. While here, look for free slot - * and possible collision for new / future allocation. - */ - if (*unit == -1 && (ce->unit & ~tmask) == allocunit) - allocunit++; - if ((ce->unit & ~tmask) < allocunit) - after = ce; - /* - * Clone logic: - * 1. Look for non busy, but keep track of the best - * possible busy cdev. - * 2. Look for the best (oldest referenced) entry that is - * in a same process / thread. - * 3. Look for the best (oldest referenced), absolute free - * entry. - * 4. Lastly, look for the best (oldest referenced) - * any entries that doesn't fit with anything above. - */ - if (ce->flags & SND_CLONE_BUSY) { - if (ce->devt != NULL && (bce == NULL || - timespeccmp(&ce->tsp, &bce->tsp, <))) - bce = ce; - continue; - } - if (ce->pid == curpid && - (cce == NULL || timespeccmp(&ce->tsp, &cce->tsp, <))) - cce = ce; - else if (!(ce->flags & SND_CLONE_INVOKE) && - (nce == NULL || timespeccmp(&ce->tsp, &nce->tsp, <))) - nce = ce; - else if (tce == NULL || timespeccmp(&ce->tsp, &tce->tsp, <)) - tce = ce; - } - if (*unit != -1) - goto snd_clone_alloc_new; - else if (cce != NULL) { - /* Same proc entry found, go for it */ - ce = cce; - goto snd_clone_alloc_out; - } else if (nce != NULL) { - /* - * Next, try absolute free entry. If the calculated - * allocunit is smaller, create new entry instead. - */ - if (allocunit < (nce->unit & ~tmask)) - goto snd_clone_alloc_new; - ce = nce; - goto snd_clone_alloc_out; - } else if (allocunit > c->maxunit) { - /* - * Maximum allowable unit reached. Try returning any - * available cdev and hope for the best. If the lookup is - * done for things like stat(), mtime() etc. , things should - * be ok. Otherwise, open() handler should do further checks - * and decide whether to return correct error code or not. - */ - if (tce != NULL) { - ce = tce; - goto snd_clone_alloc_out; - } else if (bce != NULL) { - ce = bce; - goto snd_clone_alloc_out; - } - return (NULL); - } - -snd_clone_alloc_new: - /* - * No free entries found, and we still haven't reached maximum - * allowable units. Allocate, setup a minimal unique entry with busy - * status so nobody will monkey on this new entry. Unit magic is set - * right here to avoid collision with other contesting handler. - * The caller must be carefull here to maintain its own - * synchronization, as long as it will not conflict with malloc(9) - * operations. - * - * That said, go figure. - */ - ce = malloc(sizeof(*ce), M_DEVBUF, - ((c->flags & SND_CLONE_WAITOK) ? M_WAITOK : M_NOWAIT) | M_ZERO); - if (ce == NULL) { - if (*unit != -1) - return (NULL); - /* - * We're being dense, ignorance is bliss, - * Super Regulatory Measure (TM).. TRY AGAIN! - */ - if (nce != NULL) { - ce = nce; - goto snd_clone_alloc_out; - } else if (tce != NULL) { - ce = tce; - goto snd_clone_alloc_out; - } else if (bce != NULL) { - ce = bce; - goto snd_clone_alloc_out; - } - return (NULL); - } - /* Setup new entry */ - ce->parent = c; - ce->unit = tmask | allocunit; - ce->pid = curpid; - ce->tsp = now; - ce->flags |= SND_CLONE_ALLOC; - if (after != NULL) { - TAILQ_INSERT_AFTER(&c->head, after, ce, link); - } else { - TAILQ_INSERT_HEAD(&c->head, ce, link); - } - c->size++; - c->tsp = now; - /* - * Save new allocation unit for caller which will be used - * by make_dev(). - */ - *unit = allocunit; - - return (ce); - -snd_clone_alloc_out: - /* - * Set, mark, timestamp the entry if this is a truly free entry. - * Leave busy entry alone. - */ - if (!(ce->flags & SND_CLONE_BUSY)) { - ce->pid = curpid; - ce->tsp = now; - ce->flags |= SND_CLONE_INVOKE; - } - c->tsp = now; - *dev = ce->devt; - - return (NULL); -} diff --git a/sys/dev/sound/clone.h b/sys/dev/sound/clone.h deleted file mode 100644 index 38b57b85b3e4..000000000000 --- a/sys/dev/sound/clone.h +++ /dev/null @@ -1,127 +0,0 @@ -/*- - * SPDX-License-Identifier: BSD-2-Clause - * - * Copyright (c) 2007 Ariff Abdullah - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#ifndef _SND_CLONE_H_ -#define _SND_CLONE_H_ - -struct snd_clone_entry; -struct snd_clone; - -/* - * 750 milisecond default deadline. Short enough to not cause excessive - * garbage collection, long enough to indicate stalled VFS. - */ -#define SND_CLONE_DEADLINE_DEFAULT 750 - -/* - * Fit within 24bit MAXMINOR. - */ -#define SND_CLONE_MAXUNIT 0xffffff - -/* - * Creation flags, mostly related to the behaviour of garbage collector. - * - * SND_CLONE_ENABLE - Enable clone allocation. - * SND_CLONE_GC_ENABLE - Enable garbage collector operation, automatically - * or if explicitly called upon. - * SND_CLONE_GC_UNREF - Garbage collect during unref operation. - * SND_CLONE_GC_LASTREF - Garbage collect during last reference - * (refcount = 0) - * SND_CLONE_GC_EXPIRED - Don't garbage collect unless the global clone - * handler has been expired. - * SND_CLONE_GC_REVOKE - Revoke clone invocation status which has been - * expired instead of removing and freeing it. - * SND_CLONE_WAITOK - malloc() is allowed to sleep while allocating - * clone entry. - */ -#define SND_CLONE_ENABLE 0x00000001 -#define SND_CLONE_GC_ENABLE 0x00000002 -#define SND_CLONE_GC_UNREF 0x00000004 -#define SND_CLONE_GC_LASTREF 0x00000008 -#define SND_CLONE_GC_EXPIRED 0x00000010 -#define SND_CLONE_GC_REVOKE 0x00000020 -#define SND_CLONE_WAITOK 0x80000000 - -#define SND_CLONE_GC_MASK (SND_CLONE_GC_ENABLE | \ - SND_CLONE_GC_UNREF | \ - SND_CLONE_GC_LASTREF | \ - SND_CLONE_GC_EXPIRED | \ - SND_CLONE_GC_REVOKE) - -#define SND_CLONE_MASK (SND_CLONE_ENABLE | SND_CLONE_GC_MASK | \ - SND_CLONE_WAITOK) - -/* - * Runtime clone device flags - * - * These are mostly private to the clone manager operation: - * - * SND_CLONE_NEW - New clone allocation in progress. - * SND_CLONE_INVOKE - Cloning being invoked, waiting for next VFS operation. - * SND_CLONE_BUSY - In progress, being referenced by living thread/proc. - */ -#define SND_CLONE_NEW 0x00000001 -#define SND_CLONE_INVOKE 0x00000002 -#define SND_CLONE_BUSY 0x00000004 - -/* - * Nothing important, just for convenience. - */ -#define SND_CLONE_ALLOC (SND_CLONE_NEW | SND_CLONE_INVOKE | \ - SND_CLONE_BUSY) - -#define SND_CLONE_DEVMASK SND_CLONE_ALLOC - -struct snd_clone *snd_clone_create(int, int, int, uint32_t); -int snd_clone_busy(struct snd_clone *); -int snd_clone_enable(struct snd_clone *); -int snd_clone_disable(struct snd_clone *); -int snd_clone_getsize(struct snd_clone *); -int snd_clone_getmaxunit(struct snd_clone *); -int snd_clone_setmaxunit(struct snd_clone *, int); -int snd_clone_getdeadline(struct snd_clone *); -int snd_clone_setdeadline(struct snd_clone *, int); *** 1945 LINES SKIPPED *** From nobody Thu Apr 18 12:39:57 2024 X-Original-To: dev-commits-src-branches@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 4VKy6628NGz5GmxR; Thu, 18 Apr 2024 12:39:58 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKy6617Ztz44KX; Thu, 18 Apr 2024 12:39:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443998; 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=2wqDgJV6sMOvc7MIc1lvLzRHp46wATZBiwIyhpH3z+8=; b=XMfDwwBhODE8ewlMN3D3ozEZEEeFczYbOE+UYbgVDxpEWVZnoWmnqOVKJBzm0gIeIJRL9I qEWWdNTAVj+Hzl9+GRFGGB56c6y9QiMPzfhAZPw9Okm7mNgCY6p3I1L2kH7C9aCMiVJKZP 3DzJ2Ggd9jZV3GMK9wPW8Dzm5FXR052fnEAilcQG98yzCdylqPdoluwFOamu5MMkvjvDKq 8yVQnXkMwhozdh71LqOLm+LpSiUHjty019puYNVe3+XwUUucOsC5aiF80iOFO8CcyI6Twx k72F71jWBiEhRG+0lmC8I8EwzrlEORjQlUzo9ygWdCm6N3GnWBoGQ27uGNsTuA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713443998; a=rsa-sha256; cv=none; b=Ya4w2YmwDmKvHrRw5DCMBuio5VhAirxXEp3huoJbsRM4yBcS64qmFqhYmRZaK0J1pVT5CH ATCMyKPuOvHkf6S9eupbNnsJKjEgyIDofy9JNltxDwazFaEYy/8e3ZLevcM1AJvT2BIzEx OTvjIWimMHL0LJvEJQrkfhVaqzm117TE3dNdi4pEjXepHTipiRnuJGsxjKlNiyFTTSuMJC Cei2wuotGJUxKd1AuD1bCgbwu9oWU9+cTra9fDmneLXumTAh2nrgxJc+6q4ZJ9b6XrkvvM GVhkiVKEtkDTx3Xn+kgmwpM8o7tQqGEwqL2KdaVitQVqE8NtEsZEkTv0VFQDRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443998; 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=2wqDgJV6sMOvc7MIc1lvLzRHp46wATZBiwIyhpH3z+8=; b=R+H5JN+K5H1EPzfo0cbKqiWvyOGObJX0Zb43F5oQBfXHsxoe7NGWZRK8jYPIVGt/xqEJq4 R52SDIx1Khg77B15LArjdEKl9MUPk1OPq7vnrWazs9OLmC4gLT6WsV2+MEC942s8lwhu3R 8EV/5RpvCSI/tIJh/Jr78UzTdgD87wdsGo4DiWrW0ue7ICfPLFvAlHkY++wXRBUaVPbWh/ QffcI0L/x/GxoS4jLiq8NB/i+3uPJsamgO70t7pxrqP0haTb8nswgWtdU7WUVKdvT7xysS o5qa+6i7mg4pWUJH8deoXgaVL3oK/tYmO2o1Y6A7wATMQ8GU2phCa9SX1zlNjA== 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 4VKy660l6vz18KK; Thu, 18 Apr 2024 12:39:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43ICdwa4036194; Thu, 18 Apr 2024 12:39:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43ICdv0W036191; Thu, 18 Apr 2024 12:39:57 GMT (envelope-from git) Date: Thu, 18 Apr 2024 12:39:57 GMT Message-Id: <202404181239.43ICdv0W036191@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: d692c314d29a - stable/14 - sound: Implement asynchronous device detach List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d692c314d29a310efe875e9be05b0ccebe6b241d Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=d692c314d29a310efe875e9be05b0ccebe6b241d commit d692c314d29a310efe875e9be05b0ccebe6b241d Author: Christos Margiolis AuthorDate: 2024-04-11 18:06:50 +0000 Commit: Christos Margiolis CommitDate: 2024-04-18 12:39:31 +0000 sound: Implement asynchronous device detach Hot-unplugging a sound device, such as a USB sound card, whilst being consumed by an application, results in an infinite loop until either the application closes the device's file descriptor, or the channel automatically times out after hw.snd.timeout seconds. In the case of a detach however, the timeout approach is still not ideal, since we want all resources to be released immediatelly, without waiting for N seconds until we can use the bus again. The timeout mechanism works by calling chn_sleep() in chn_read() and chn_write() (see pcm/channel.c) in order to send the thread to sleep, using cv_timedwait_sig(). Since chn_sleep() sets the CHN_F_SLEEPING flag while waiting for cv_timedwait_sig() to return, we can test this flag in pcm_unregister() (called during detach) and wakeup the sleeping thread(s) to immediately kill the channel(s) being consumed. Sponsored by: The FreeBSD Foundation MFC after: 2 months PR: 194727 Reviewed by: dev_submerge.ch, bapt, markj Differential Revision: https://reviews.freebsd.org/D43545 (cherry picked from commit 44e128fe9d92c1a544b801cb56e907a66ef34691) --- share/man/man4/snd_uaudio.4 | 11 +---------- sys/dev/sound/pcm/dsp.c | 2 +- sys/dev/sound/pcm/mixer.c | 11 ----------- sys/dev/sound/pcm/sound.c | 24 ++++++++++-------------- sys/dev/sound/usb/uaudio.c | 13 +++---------- 5 files changed, 15 insertions(+), 46 deletions(-) diff --git a/share/man/man4/snd_uaudio.4 b/share/man/man4/snd_uaudio.4 index b6a6c06a2312..6e2509b8f2ac 100644 --- a/share/man/man4/snd_uaudio.4 +++ b/share/man/man4/snd_uaudio.4 @@ -27,7 +27,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd January 29, 2024 +.Dd March 26, 2024 .Dt SND_UAUDIO 4 .Os .Sh NAME @@ -156,15 +156,6 @@ and modified for by .An Hiten Pandya Aq Mt hmp@FreeBSD.org . .Sh BUGS -The PCM framework in -.Fx -only supports synchronous device detach. -That means all mixer and DSP character devices belonging to a given -USB audio device must be closed when receiving an error on a DSP read, -a DSP write or a DSP IOCTL request. -Else the USB audio driver will wait for this to happen, preventing -enumeration of new devices on the parenting USB controller. -.Pp Some USB audio devices might refuse to work properly unless the sample rate is configured the same for both recording and playback, even if only simplex is used. diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index 003e57446a69..4112e87ba527 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -274,7 +274,7 @@ dsp_close(void *data) d = priv->sc; /* At this point pcm_unregister() will destroy all channels anyway. */ - if (!PCM_REGISTERED(d)) + if (PCM_DETACHING(d)) goto skip; PCM_GIANT_ENTER(d); diff --git a/sys/dev/sound/pcm/mixer.c b/sys/dev/sound/pcm/mixer.c index ee1ed11a8ed0..cc8cf5b1ceea 100644 --- a/sys/dev/sound/pcm/mixer.c +++ b/sys/dev/sound/pcm/mixer.c @@ -817,17 +817,6 @@ mixer_uninit(device_t dev) KASSERT(m->type == MIXER_TYPE_PRIMARY, ("%s(): illegal mixer type=%d", __func__, m->type)); - snd_mtxlock(m->lock); - - if (m->busy) { - snd_mtxunlock(m->lock); - return EBUSY; - } - - /* destroy dev can sleep --hps */ - - snd_mtxunlock(m->lock); - pdev->si_drv1 = NULL; destroy_dev(pdev); diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index 53cde49c4905..1517126210c4 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -1001,26 +1001,22 @@ pcm_unregister(device_t dev) CHN_FOREACH(ch, d, channels.pcm) { CHN_LOCK(ch); - if (ch->refcount > 0) { - device_printf(dev, - "unregister: channel %s busy (pid %d)\n", - ch->name, ch->pid); - CHN_UNLOCK(ch); - PCM_RELEASE_QUICK(d); - return (EBUSY); + if (ch->flags & CHN_F_SLEEPING) { + /* + * We are detaching, so do not wait for the timeout in + * chn_read()/chn_write(). Wake up the thread and kill + * the channel immediately. + */ + CHN_BROADCAST(&ch->intr_cv); + ch->flags |= CHN_F_DEAD; } + chn_abort(ch); CHN_UNLOCK(ch); } dsp_destroy_dev(dev); - if (mixer_uninit(dev) == EBUSY) { - device_printf(dev, "unregister: mixer busy\n"); - PCM_LOCK(d); - PCM_RELEASE(d); - PCM_UNLOCK(d); - return (EBUSY); - } + (void)mixer_uninit(dev); /* remove /dev/sndstat entry first */ sndstat_unregister(dev); diff --git a/sys/dev/sound/usb/uaudio.c b/sys/dev/sound/usb/uaudio.c index 5d7396c527e0..2351c2522021 100644 --- a/sys/dev/sound/usb/uaudio.c +++ b/sys/dev/sound/usb/uaudio.c @@ -1255,20 +1255,13 @@ uaudio_detach_sub(device_t dev) unsigned i = uaudio_get_child_index_by_dev(sc, dev); int error = 0; -repeat: if (sc->sc_child[i].pcm_registered) { error = pcm_unregister(dev); - } else { - if (sc->sc_child[i].mixer_init) - error = mixer_uninit(dev); + } else if (sc->sc_child[i].mixer_init) { + error = mixer_uninit(dev); } - if (error) { - device_printf(dev, "Waiting for sound application to exit!\n"); - usb_pause_mtx(NULL, 2 * hz); - goto repeat; /* try again */ - } - return (0); /* success */ + return (error); } static int From nobody Thu Apr 18 12:39:59 2024 X-Original-To: dev-commits-src-branches@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 4VKy674X7dz5Gn0s; Thu, 18 Apr 2024 12:39:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKy6727t8z44Tg; Thu, 18 Apr 2024 12:39:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443999; 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=Go6VXPeQl86uc27AhW5A6lGRAqtqZpcagukxJjqoaL4=; b=Tsg7HDkLPp+uU8mzqg6RfoXTTh+SAXwlpBI3cO7R5C1r9nmLBpXjLWicZyb+2jIa8Wl1/m L1aXDVHbrr4LdCmK0LqzM78IQqYVZObyjr5rj+u21IMmtIYSnnnzyW/cGAfEbdjxi9uTZE xhvSD85SPOOjICYTYXZSO6T+gPRU6EcHquRH11C/F/F+R6uswGCeRy/PAFO1BGNm6VjD18 cipm11d8KIsNiGqFK/4bo67Td2Uy4GfBzeIdGdMEbBnNXyYty+MIsFDVorpFNyUx8sI2Y1 mO0OIUePerYTQr9s0IzS8wN6DlyO5cKtkKElmt4AtntFn2dVSa5l/Ach4CltRg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713443999; a=rsa-sha256; cv=none; b=t+noDorLEIux9WUcNDw0D/kOtbU6Pet5gNagBx49dD+g/ptpPclozqOgf3pkh57s0M+39W 4Dk3jee5jmgfUUAiNVyZhioV8mvqZv7FZEUeM6fWxYJRMMp0HQsNYxt1Ile2M4TZ8c//4M zSRMoQ8Ds9M5xP36xPPWofdRqY/NG7GDpoRcBNRQCK5LGFotrrXjudgupTcWsnjy34CNCZ OUTBM0SD6suUX9JyO6YyndQ8faIxJ9APiJQF4HG9HSgES2hR7wQaH7ioBTsmzhLkB78Zcf 9/j1BepMJ0lZHeRVIuysyOqEh8mXeYmQPGM/LSWBuj7mElP58SLFKoHwU58r8g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713443999; 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=Go6VXPeQl86uc27AhW5A6lGRAqtqZpcagukxJjqoaL4=; b=UpZHfkdFoo4lLIB8NfQzpRP9RiRU4gPWufJv1sXoXHPiQJ8Cz/nhWrdCYfEaPQbf0dVjLL 3ddUfqMc1fCdhDc1yUmgg7p5oQkunkSrFCuEzFjE6WPZAsEoIvr0pQxXOuVJNG6Ln8OKPj 8bO4ODaVYXyh7FDtH7ZJfFK52DzN+OJo/9O+/eXs/KfLEMq4l4cxfhMw6w2ZFb649ec7F/ gemNtzlXi9T8dOFuxLlq9jKRpQKvnEV+t9G3P/EijThuLCVSHzY/WwkI5qcS52dGKIaB16 xdzeyC6hDbaWzKij9Fyjv/f6p+rvXvHFy9BhfLdOItFxZcbQy3OFbqe9CKzl4g== 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 4VKy671lycz18c1; Thu, 18 Apr 2024 12:39:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43ICdxhx036242; Thu, 18 Apr 2024 12:39:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43ICdxfJ036239; Thu, 18 Apr 2024 12:39:59 GMT (envelope-from git) Date: Thu, 18 Apr 2024 12:39:59 GMT Message-Id: <202404181239.43ICdxfJ036239@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 51abcd0c477a - stable/14 - sound: Update some LICENSE headers List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 51abcd0c477a80d9b13b92b9a4baf4010a71c806 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=51abcd0c477a80d9b13b92b9a4baf4010a71c806 commit 51abcd0c477a80d9b13b92b9a4baf4010a71c806 Author: Christos Margiolis AuthorDate: 2024-04-12 18:34:27 +0000 Commit: Christos Margiolis CommitDate: 2024-04-18 12:39:36 +0000 sound: Update some LICENSE headers The following commits introduced substantial changes to pcm/dsp.c, pcm/sndstat.c and pcm/sound.c. 9da3b645dbaaad724d524727d003fed7be05ff7c ("sound: Move sndstat_prepare_pcm() to pcm/sndstat.c and remove sndstat_entry->handler") e8c0d15a64fadb4a330f2da7244becaac161bb70 ("sound: Get rid of snd_clone and use DEVFS_CDEVPRIV(9)") Sponsored by: The FreeBSD Foundation MFC after: 1 week Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D44757 (cherry picked from commit 4f854658c5d6ca98c822491991052574d948617d) --- sys/dev/sound/pcm/dsp.c | 4 ++++ sys/dev/sound/pcm/sndstat.c | 4 ++++ sys/dev/sound/pcm/sound.c | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index 4112e87ba527..f685d7e38f6d 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -5,6 +5,10 @@ * Portions Copyright (c) Ryan Beasley - GSoC 2006 * Copyright (c) 1999 Cameron Grant * All rights reserved. + * Copyright (c) 2024 The FreeBSD Foundation + * + * Portions of this software were developed by Christos Margiolis + * under sponsorship from the FreeBSD Foundation. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions diff --git a/sys/dev/sound/pcm/sndstat.c b/sys/dev/sound/pcm/sndstat.c index 0279060181b3..ef006a580d40 100644 --- a/sys/dev/sound/pcm/sndstat.c +++ b/sys/dev/sound/pcm/sndstat.c @@ -5,6 +5,10 @@ * Copyright (c) 2001 Cameron Grant * Copyright (c) 2020 The FreeBSD Foundation * All rights reserved. + * Copyright (c) 2024 The FreeBSD Foundation + * + * Portions of this software were developed by Christos Margiolis + * under sponsorship from the FreeBSD Foundation. * * Portions of this software were developed by Ka Ho Ng * under sponsorship from the FreeBSD Foundation. diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index 1517126210c4..52ead91853e9 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -6,6 +6,10 @@ * Copyright (c) 1999 Cameron Grant * Copyright (c) 1997 Luigi Rizzo * All rights reserved. + * Copyright (c) 2024 The FreeBSD Foundation + * + * Portions of this software were developed by Christos Margiolis + * under sponsorship from the FreeBSD Foundation. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions From nobody Thu Apr 18 12:40:00 2024 X-Original-To: dev-commits-src-branches@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 4VKy684LX8z5Gn2J; Thu, 18 Apr 2024 12:40:00 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKy682lbPz44N8; Thu, 18 Apr 2024 12:40:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713444000; 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=F5aq9/lJ2bixMJW1xrg2ivsrLB62Z0JFG6hT1xICqJQ=; b=HQHuDx+Yg1Dv0Kw16vavXrOCsHTnpLNPB4vd7gsOzVnrSRjZ9vYk4+Ca9LJjDPTuVTu1J+ RrksUSEmCNoRgC1zYwGT9iuM3Q7O3rmpKncYz1wc1dkwjF7VkWj9CtbF6DIFKZqE1VIrsT k904E0cVW5fuRWOT6rvUMOY3OFb2EYiHf+ozSXGohvnXMGLwNdoE4LE4FuVy06kLRrKHbP MzLxITOnRf4VLKRZTBpGh51vHxa90xXF1i0uJK4jjE3GkXowJ66m0/y0FTmHShd4kywMo2 NGpIZEQFJhSoL/PO/cSnAhrrTqf59I92LOMGUdOjftkdtKJCau57HOLUo7NLPQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713444000; a=rsa-sha256; cv=none; b=Wmd0oemGd5V1+2kkAEYHMHOzw4TrhuUUoORjU6WvB3/FI/YOEoSXBER/xi6bogIp5tvLKU tP0t6UxH+A8/No3pNkRmT2OSVIarpglkwjgYUmsz+abGDt147/mZeJkf1pUCYvDvYa9GKN RpxbOcSioObGSGTM4kVAePhm+Wx4AR4k7xYniKcyKgLbqh6bBckKZ0uGH6vhGWHAkux/Kl T59+fTMPcaPtSDlh+Xt957Xh329auzURzsiPxKL42swj50jP793OAWBRbiFrlsrGjenqtC f5e89zSdyM1mGI1pzwTzN+dBeAY6DeZkEIfh4qlq/cG5fOxGvkCoQd1jKg/Bug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713444000; 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=F5aq9/lJ2bixMJW1xrg2ivsrLB62Z0JFG6hT1xICqJQ=; b=aEvxc6B+nyQZcDsJd2hX59Yw8/ooyx3MwtUEbf6spEzvE3e+ijGapWQ531LLwkhMO6dmYd EiN5XFbWmbhsVrUolfSZmGm9vEAu8GXe8TD0n1XqA1LLUiBNF3f+snKo3r0JpFDAZBer4z 6hc+K/aUTDw1yXX5vml9g/GL5Uqr+uWscyPj6mapQEXYAebnQF6Gs3nhGIU1+lfZPaLlI+ elsjWbotwn4M4RodGcN3e2apkm+z+WkT8N3QqaCQN5IA1Ukgch98vhRf/ei2XIisx32YOG FGFLWFjONhXbsqMMPTSC3mQm8zLxWMisG37u2SpyVD44eIOKde0/74+teo7jUw== 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 4VKy682LPRz1970; Thu, 18 Apr 2024 12:40:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43ICe03b036327; Thu, 18 Apr 2024 12:40:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43ICe0TY036324; Thu, 18 Apr 2024 12:40:00 GMT (envelope-from git) Date: Thu, 18 Apr 2024 12:40:00 GMT Message-Id: <202404181240.43ICe0TY036324@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 5abbbb7c6401 - stable/14 - sound: Remove leftover references to snd_clone List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5abbbb7c640185c50762ee216b19429e8f562938 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=5abbbb7c640185c50762ee216b19429e8f562938 commit 5abbbb7c640185c50762ee216b19429e8f562938 Author: Christos Margiolis AuthorDate: 2024-04-13 17:12:27 +0000 Commit: Christos Margiolis CommitDate: 2024-04-18 12:39:41 +0000 sound: Remove leftover references to snd_clone The snd_clone framework does not exist as of e8c0d15a64fadb4a330f2da7244becaac161bb70 ("sound: Get rid of snd_clone and use DEVFS_CDEVPRIV(9)"), so remove leftover references to it from unit.c. Sponsored by: The FreeBSD Foundation MFC after: 2 months Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D44758 (cherry picked from commit 068c675ca7aec11d3546c3f908e842a7eca2ccae) --- sys/dev/sound/unit.c | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/sys/dev/sound/unit.c b/sys/dev/sound/unit.c index 1f1b889b42ce..28ffbde1f7ec 100644 --- a/sys/dev/sound/unit.c +++ b/sys/dev/sound/unit.c @@ -44,24 +44,17 @@ * * eg: dsp0.p1 - u=0, d=p, c=1 * dsp1.vp0 - u=1, d=vp, c=0 - * dsp0.10 - u=0, d=clone, c=allocated clone (see further explanation) * - * Maximum unit of soundcards can be tuned through "hw.snd.maxunit", which - * is between SND_UNIT_UMIN (16) and SND_UNIT_UMAX (2048). By design, - * maximum allowable allocated channel is 256, with exception for clone - * devices which doesn't have any notion of channel numbering. The use of - * channel numbering in a clone device is simply to provide uniqueness among - * allocated clones. This also means that the maximum allowable clonable - * device is largely dependant and dynamically tuned depending on - * hw.snd.maxunit. + * Maximum unit of soundcards can be tuned through "hw.snd.maxunit", which is + * between SND_UNIT_UMIN (16) and SND_UNIT_UMAX (2048). By design, the maximum + * allowable allocated channel is 256. */ /* Default width */ static int snd_u_shift = 9; /* 0 - 0x1ff : 512 distinct soundcards */ static int snd_d_shift = 5; /* 0 - 0x1f : 32 distinct device types */ static int snd_c_shift = 10; /* 0 - 0x3ff : 1024 distinct channels - (256 limit "by design", - except for clone devices) */ + (256 limit "by design") */ static int snd_unit_initialized = 0; @@ -184,10 +177,7 @@ snd_unit_init(void) snd_u_shift++) ; - /* - * Make room for channels/clones allocation unit - * to fit within 24bit MAXMINOR limit. - */ + /* Make room for channels to fit within 24bit MAXMINOR limit. */ snd_c_shift = 24 - snd_u_shift - snd_d_shift; } From nobody Thu Apr 18 13:37:05 2024 X-Original-To: dev-commits-src-branches@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 4VKzN13MX9z5Gt0v; Thu, 18 Apr 2024 13:37:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKzN12nXfz4KdB; Thu, 18 Apr 2024 13:37:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713447425; 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=2sGrEGmkOE7eG9MIgj21edlg6dsCFSakn2JgWcGogKk=; b=Vd3gu+2FXCt03mWdpHN7C+YrQ2HAxoVgAic9r/UyeDYAkrF5yRgkXdFxJHB0FAXsghiIVm 3HF3pErvIBmCzoHpPFasadd5Eo+kLVkj+C3jqsUjVBV/1HGnsZMcpCAR1Bxy4FRsyV7Twm nr2lLEM2Jx2pCfprRyPSQgxlMLXBohLG5rmSqbgKYNbgSgF+KyW6HSmQRQHm59wCwFnUeo yM/686CMrbL/wDI5F0NvYTJaZfsoMrBZ3onSgNn0R7SRYsVthVMUicORa7L6IsGnHONL1B JTItgBBHF01qWotKhrXwGYOG6yxZ5zjC58X6usoHRRt1Hw5a/tKMzs6Sgjkecg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713447425; a=rsa-sha256; cv=none; b=uwoXmeJJ42pNAR36hl0ee9tHg85qa6E6PpR2N+7kLvGa5WR9xHL2O+/0y0smABGozpJUNL U58RTKZy5m98nsJInQXqeXsk98wKFMvbCRd6FpiWMnk3J81cmozfJHbaWehe0j6RFx0UAb S8iqVP4ovkMNC+FvFhyRWuFTnyUzM6W3czBDAvfevBzH8MSrT0dYv6yEo9aZxyMpnpC5Qy n1E62k6JStcpAqHtkGCrxEdH9QyCGLKpbQEo6iD4a0h/ixmLkXSDPEm+jEHsWgcBo7d4O3 w2BQMl5JRFrOVWUGYsqxMqC2X5ibi63jT0umaWGUmCOKxhVLbwiuigfhqJn8jg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713447425; 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=2sGrEGmkOE7eG9MIgj21edlg6dsCFSakn2JgWcGogKk=; b=W8I0QyFTtfvh5eGpn+KISvuvPKpbQ9G57jmkJ2ASw5eF9jF9C5J5NUnCb78SJSFbQUsNvw KotcosRbWtOSzXcATK5Zvsyy4RU88/CvmywBcfZxJBMSylQF2pVUIoxa82vDh/9cII5pSr 7CL6H2p/c45PvV8y4WMKTeHr9lyxdwfUdjM0BEHs5CUM1buwDRqoF/BkF6MYQvuLKdFpHk smsM1q7P/9sfdF9hD8co/vLR5bCLX+CJbWMhkLbqZGRiVoPZ0drnhFIY1//M+gYCmDj08v UTZ+BpPD+mDVx1R2WSN+YxUasOYYZxqS09R1fiwz8NB1WcCvL3UmSYxHjplGGA== 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 4VKzN12Gj8z1B2v; Thu, 18 Apr 2024 13:37:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IDb55b041440; Thu, 18 Apr 2024 13:37:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IDb5Kl041437; Thu, 18 Apr 2024 13:37:05 GMT (envelope-from git) Date: Thu, 18 Apr 2024 13:37:05 GMT Message-Id: <202404181337.43IDb5Kl041437@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: dc16f5fe1422 - stable/14 - tcpdump: cope with incorrect packet lengths List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: dc16f5fe14226da84ea4e77b04d31efa5c5f6853 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=dc16f5fe14226da84ea4e77b04d31efa5c5f6853 commit dc16f5fe14226da84ea4e77b04d31efa5c5f6853 Author: Kristof Provost AuthorDate: 2024-04-01 09:42:14 +0000 Commit: Kristof Provost CommitDate: 2024-04-18 13:35:52 +0000 tcpdump: cope with incorrect packet lengths It's possible for the capture buffer to be smaller than indicated by the header length. However, pfsync_print() only took the header length into account. As a result we could read outside of the buffer. Check that we have at least the expected amount of data before we start parsing. PR: 278034 MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D44580 (cherry picked from commit 4848eb3af2a91b133c4b70cb9b71dd92ffec7f46) --- contrib/tcpdump/print-pfsync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/tcpdump/print-pfsync.c b/contrib/tcpdump/print-pfsync.c index 5710e36ded6c..6bf9abaf3903 100644 --- a/contrib/tcpdump/print-pfsync.c +++ b/contrib/tcpdump/print-pfsync.c @@ -86,7 +86,7 @@ pfsync_ip_print(netdissect_options *ndo , const u_char *bp, u_int len) { struct pfsync_header *hdr = (struct pfsync_header *)bp; - if (len < PFSYNC_HDRLEN) + if (len < PFSYNC_HDRLEN || !ND_TTEST_LEN(bp, len)) ND_PRINT("[|pfsync]"); else pfsync_print(ndo, hdr, bp + sizeof(struct pfsync_header), From nobody Thu Apr 18 13:37:17 2024 X-Original-To: dev-commits-src-branches@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 4VKzNF33Kkz5Gt7q; Thu, 18 Apr 2024 13:37:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VKzNF2Wbmz4KlH; Thu, 18 Apr 2024 13:37:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713447437; 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=NL2caFVu6op1hZtqe0tAZI6j2NHDDDbcqpDK1SHnIrY=; b=UakXXgd7GBZmTGaHaCVkFhsOx7nd4yob6BZnAmQLsnBqsvZAP/nIHomSSqX2lSC3QNSdvA Ca0y3C78MsGXm96Qq0jAp8dO0iR9SZ5lK24ay2KrURuOVxjgDMdXQhyYWfhcJXWWoP9kKk wIaIm4PrHiTaCm02fIDW/OJirDQWls82MA8EA8Kc/ssMFCh0J/dVU4D9XtHw6coKJWGsS1 StqMgZyREgB/EPAEmU5hMYu4T/m0Ul0I43vuxMhcGxcsxDqK9eBSbjBMu/iQcVqbenu86T 7kK3uUFxe5oxast9CH4Z3/+uMumbe1doscG7WsbN9fg1Ji6cCOdmdLnWL1iIvw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713447437; a=rsa-sha256; cv=none; b=GVk63AZ+CP14pAip0yHS9mXR+MD0JwJr7uYUSHo5MB8H5swHojLevjyX4kpqnFPJgAzUNw UNYv9AorBY32vuIXWR1kBdZOnxeqlYTBxqCvAdkKKxIc2HsPbxq56yXDyfSZHUyPCM0xCW FaVQPfoKJBYYLDWH+/dp5KRlOZpBs1SuthN39wL0+F3/HaVwsQTsAJGTNEJJWpGRjPE07s K2lZSY8afR1k9oYe4JoCxfue06Sem+KHFexenEfQAyF7rry+aaeziLedT/xp854FQViU+Y qE2KtSPAvUqUAlp4Tqn07kmBRJlNyKrkDQhAMjK8lOcd+OoFKb1tkbPUxYQfXg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713447437; 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=NL2caFVu6op1hZtqe0tAZI6j2NHDDDbcqpDK1SHnIrY=; b=o0eTIwyjywdxoTibyuNv+4tRX0Wq2erlmB3t8RGWBVF8CPBB5z/58tBKHsjaJIH0OYEY+P kfmF+f8ohJOfWUWt9o54r+caV+oh/kLHtmh3ePi3XSPg8yopGLwKwyN7SNPk3cONRGBYSq oYMwDRwEEVdRGdM2c7q9PtAav7v7MZmJUUvfkVTCAVpoaD2NQbxVooptuW0b2ubddyBZRy EauRJc3WhJS+0wZjCI/juN0pvW49SaXdmR/AZNtw3ueXw+xXD86imxfzLLqmIVs4houJwl AKnUpWO+BqXcpDpYQ26daYOFdKeigYNi8xYu6cVOA2fyH0eRnLdT89oiiJKPbA== 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 4VKzNF272wz1BbF; Thu, 18 Apr 2024 13:37:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IDbH55041600; Thu, 18 Apr 2024 13:37:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IDbHtW041597; Thu, 18 Apr 2024 13:37:17 GMT (envelope-from git) Date: Thu, 18 Apr 2024 13:37:17 GMT Message-Id: <202404181337.43IDbHtW041597@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: bf0700716a2e - stable/13 - tcpdump: cope with incorrect packet lengths List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: bf0700716a2e04464311e0b585b947d7d3e825b9 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=bf0700716a2e04464311e0b585b947d7d3e825b9 commit bf0700716a2e04464311e0b585b947d7d3e825b9 Author: Kristof Provost AuthorDate: 2024-04-01 09:42:14 +0000 Commit: Kristof Provost CommitDate: 2024-04-18 07:41:28 +0000 tcpdump: cope with incorrect packet lengths It's possible for the capture buffer to be smaller than indicated by the header length. However, pfsync_print() only took the header length into account. As a result we could read outside of the buffer. Check that we have at least the expected amount of data before we start parsing. PR: 278034 MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D44580 (cherry picked from commit 4848eb3af2a91b133c4b70cb9b71dd92ffec7f46) --- contrib/tcpdump/print-pfsync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/tcpdump/print-pfsync.c b/contrib/tcpdump/print-pfsync.c index dc1cd039f5b0..cb1c3f3828fa 100644 --- a/contrib/tcpdump/print-pfsync.c +++ b/contrib/tcpdump/print-pfsync.c @@ -86,7 +86,7 @@ pfsync_ip_print(netdissect_options *ndo , const u_char *bp, u_int len) { struct pfsync_header *hdr = (struct pfsync_header *)bp; - if (len < PFSYNC_HDRLEN) + if (len < PFSYNC_HDRLEN || !ND_TTEST_LEN(bp, len)) ND_PRINT((ndo, "[|pfsync]")); else pfsync_print(ndo, hdr, bp + sizeof(struct pfsync_header), From nobody Thu Apr 18 14:05:15 2024 X-Original-To: dev-commits-src-branches@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 4VL00X1jHQz5GwJP; Thu, 18 Apr 2024 14:05:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL00W6s11z4RTT; Thu, 18 Apr 2024 14:05:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449116; 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=bK6s4hdqrSNd3mSiwGP0/G4j9T7hQL86iLgwgrrFsKo=; b=T3RNzz8wB7nty+CkXDpzj+7rkGmkwu5EWV6BnjzZOzvAELtmQqfTcqyhcpshtJuxG9ISlL 1lb/z8XgoGWj8tmx8IMEkSaTOY+NU4+effTwOo5apAcguyH1NzfKf0CYPglNNKMAk2jfR+ BeFm14Mp21otC/KBnQwvdXuz3KS3olyc4QWgsxLpHCzM+ogR6nYLacOEKL0UBx4n4gTvRr hq201WVK7SvO0DEVOPA00QnOIJhqt0Wj1ySGu/UWnB5Q6DL1qRXliYOGFhKkjdQ6GK3rw/ esJu8xX+BAH78xcEDW/020Fw8o5yABt12Z5SWYQf9/uFisnyyefXX6PvhwzsRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713449116; a=rsa-sha256; cv=none; b=cTTVrCZz+VAqv+izMraEzGngQaqkM0eQMn8L2Bkp781epSRNbFbmTFXFITZDPId0kI4m/I H5VrW9owyqlGo7irfm6FuWp4A4BWSXA5xxnshm+ZkEyLxTQepxP22/sA4jJQIkNv4v6nki ec54DiDiKr9bhi17hwDQ+Rcwvpp7iN/woZ46tuanebTvpswDxHe2Iaxhqv7yeSXkADv74x JlMA60bfi/ih6RuEzxFI6frrLsmrtRJur9Z+rAp3XwoHmHsagTLj8b1k4VN2ijGW9uuXjc 7hCb5stdVkKmgVOJzAnlMKs2k+DQw59l5QVySll5oHKwChpLLcP9JCat4vY1HA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449116; 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=bK6s4hdqrSNd3mSiwGP0/G4j9T7hQL86iLgwgrrFsKo=; b=s7bsRSsi+uFwCoL25Nn33xXgwBmH+JGDD3lRBgP7b9kz1EbY/uUgSw2Alwi0EEzKVdpOwZ SM5B0tsUlacXfNYXiBfL7eZqepdDkogwPlVuCiEj0VAtI8MLIkKAhJYRI+vXdCfXLtwjGa xDug8IljfNWZPFbPAwFPZHWac43y8JplgVKvjvv9GuR+zNYn6iXmSuPeWcjTTddvrZ6G0l IZqq7kPYDwi7c8Rdro0XsMvqguEPTje4y66rfhL7Kd4F+arnB3svaA76hcO0RGbrAbiuIq kNp70EvtW9puRz5WFbJmh1eKqwZbnENVLWqA7Tcp7+rj8S5hS8Ej+LmCKrNR5Q== 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 4VL00W6QzYz1CNf; Thu, 18 Apr 2024 14:05:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IE5FOP093369; Thu, 18 Apr 2024 14:05:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IE5FRD093366; Thu, 18 Apr 2024 14:05:15 GMT (envelope-from git) Date: Thu, 18 Apr 2024 14:05:15 GMT Message-Id: <202404181405.43IE5FRD093366@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 7e3c7de28d11 - stable/14 - tzsetup: be explicit about *timezone* abbreviation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7e3c7de28d11c8e7070b492e692f45ae49bdeebb Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=7e3c7de28d11c8e7070b492e692f45ae49bdeebb commit 7e3c7de28d11c8e7070b492e692f45ae49bdeebb Author: Ed Maste AuthorDate: 2024-03-25 20:25:23 +0000 Commit: Ed Maste CommitDate: 2024-04-18 14:05:01 +0000 tzsetup: be explicit about *timezone* abbreviation During the install process tzsetup asks a question like Does the abbreviation `EDT' look reasonable? The installer asks lots of questions, some that relate to the previous screen or topic and some that do not. A new user installed FreeBSD for the first time and was confused by this question, not realizing that it was asking whether the abbreviation is correct for the selected timezone. Reviewed by: bapt, brooks, imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44500 (cherry picked from commit 40b57cb616ca19aee3de104acd058da289c936bb) --- usr.sbin/tzsetup/tzsetup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/tzsetup/tzsetup.c b/usr.sbin/tzsetup/tzsetup.c index f6440a0ea736..eca7358df1df 100644 --- a/usr.sbin/tzsetup/tzsetup.c +++ b/usr.sbin/tzsetup/tzsetup.c @@ -709,7 +709,7 @@ confirm_zone(const char *filename) tm = localtime(&t); snprintf(prompt, sizeof(prompt), - "Does the abbreviation `%s' look reasonable?", tm->tm_zone); + "Does the timezone abbreviation `%s' look reasonable?", tm->tm_zone); conf.title = "Confirmation"; rv = (bsddialog_yesno(&conf, prompt, 5, 72) == BSDDIALOG_YES); return (rv); From nobody Thu Apr 18 14:19:00 2024 X-Original-To: dev-commits-src-branches@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 4VL0JN4xDdz5Gxk9; Thu, 18 Apr 2024 14:19:00 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL0JN4Rjqz4WnK; Thu, 18 Apr 2024 14:19:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449940; 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=eIJUxdrZB5ziXQxXUOO6tgdRMPDNDMH/VNhHAigIenk=; b=hnyQT5heNsB1nrys+HU5SU/uuN4CsGV5AX/acu56MYVySC9L3X9W8Jaxy/MdflKE+9IxHg YAsMaEBRq6OClUCVpdFe290GQQIOV77oHabqPnjhEj/S6m8Z4YepikASDMT29g5Ylav6Ud 7C47+833D6ne6Rj56ko4WFN6HBuKD/kXVhCyFkXrL+Q3FPGNypsJ1zMoATMHO5OL6crirp hE7jPynVJtrXd1rChJd6hauJtGMjJDvMsak/YxgG4zWj+eukPW8++uemDj9ne5HrTarpAl F3BQvdo2A4hYK1ZowsMLRTDBlQtW9ecrxqeVdAfrcz+uxZQ8z837uVvJdolGig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713449940; a=rsa-sha256; cv=none; b=Bf4sefjMrTcLR+zY0Gj1fK/LOzar8fpBAYPKjZRa+3HlQ1i0179Uqfq0aJm3IFshZ41eK+ N57hOouskUANQhnnl0blR7vVYsV1JYxFjbs9G6xRkEKH3YE+QAt0K45RRzG7gm4K2Lr0t1 K1MGlddKeO2Kwk9smjUNWXuOlVplY+tA0nOb1VIwNGrHT3GEztZhbtilhj55cayUtGfKci XdQl/nf93GrSC7n05ljvrNmPzRgdJ6JBAu5Sr5pXMtlugSRHA/+WD1kQ1lu3/783/RVRDx cLzidTaHqR1Cxcl4O8xIbVWT7vDyGn4RYeMsmWtJtzONodLQPK5K/T2crq168A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449940; 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=eIJUxdrZB5ziXQxXUOO6tgdRMPDNDMH/VNhHAigIenk=; b=EIaz0HY573lX0xHmDNz88jUOkQucUCooCaiHpZJrUMIpJYy7hezJMfbOsginrEuumxlz78 skq6MZKnYi9ixkpSivrsNaHg/kb4jJklvkPy6j3lzksz6kYZCleCURu3wGfMBAesq0A+Vw KUSPq2fRi8TNDiBruCM13Dg1oxXn84oE2WHh1XcnTmwwT3HXOm/dsGL0dof7VYoOHxqBxj YsvwalpSdXCs9eVIeoKI9nGbaVi+7lOmd5kM4J58AcctDk970z79rhGlUm/9Lp3JPE5t5d zGcMPX0VV453Y9R76HWkRmY/M33/eqG/cIbVvUlPQPPHplVVHlg5+SBBQwR2Dw== 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 4VL0JN4228z1CPM; Thu, 18 Apr 2024 14:19:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IEJ0fo010443; Thu, 18 Apr 2024 14:19:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IEJ0uK010440; Thu, 18 Apr 2024 14:19:00 GMT (envelope-from git) Date: Thu, 18 Apr 2024 14:19:00 GMT Message-Id: <202404181419.43IEJ0uK010440@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: ea3b15d005c2 - stable/14 - bsdlabel: emit deprecation notice when run List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ea3b15d005c25860c742663cfc87145cd00fb61b Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=ea3b15d005c25860c742663cfc87145cd00fb61b commit ea3b15d005c25860c742663cfc87145cd00fb61b Author: Ed Maste AuthorDate: 2024-01-24 19:33:35 +0000 Commit: Ed Maste CommitDate: 2024-04-18 14:05:01 +0000 bsdlabel: emit deprecation notice when run Reviewed by: imp Sponsored by: The FreeBSD Foundation Differential Reision: https://reviews.freebsd.org/D43586 (cherry picked from commit 3661658c76ce028a6dcdd54b00a822159a3ae6f3) --- sbin/bsdlabel/bsdlabel.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sbin/bsdlabel/bsdlabel.c b/sbin/bsdlabel/bsdlabel.c index 56190bbf6858..9febd670cf35 100644 --- a/sbin/bsdlabel/bsdlabel.c +++ b/sbin/bsdlabel/bsdlabel.c @@ -148,6 +148,10 @@ main(int argc, char *argv[]) error = 0; name = NULL; + fprintf(stderr, + "WARNING: bsdlabel is deprecated and is not available in FreeBSD 15 or later.\n" + "Please use gpart instead.\n\n"); + while ((ch = getopt(argc, argv, "ABb:efm:nRrw")) != -1) switch (ch) { case 'A': From nobody Thu Apr 18 14:19:26 2024 X-Original-To: dev-commits-src-branches@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 4VL0Jt4DXJz5Gxgl; Thu, 18 Apr 2024 14:19:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL0Jt3krnz4X18; Thu, 18 Apr 2024 14:19:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449966; 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=FJCqDs9K1VJsl33l9V+5ALTJW3ouF4LDU3laQbUlKpY=; b=MCZlDcX1eSXFtXHEFweY7Yd+McklPb/fO3ILX/oeEkJmIZk0XFxs1sz7h9p39j06wDbps9 EDMuAxEtKq35p3gk6yjx6A4MM/7oHegNwksb1mT0/R3rXVZ8PbyOPgP4sWl7e6xKpnfPHB 2P/Kla67cMXPYRNHUECd5qCv6V96Oi5VhefUDgLUZbfttvZAt9eyEMzOXif/hpO4C+gtva MRcQcv6QBJevfUbZWaz8j1YOrvYj7IX0KcAJUJ38VqqeSR7K+jEdJ65bVOCvKQz32+VhyI kpAwh7fNA0qW9QMCOVlbS4185uFtvWMikgCJj9AJ5H5eaAOBTcJyl/VVsDOXuQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713449966; a=rsa-sha256; cv=none; b=owTt10eUnsp7FN8MYnvrFe37LyHTbcIAyq/KkNVaVtdjQIeFM9M46YGSNtedQyZh9YEcDJ f5vb0C7AIA5xBFpwHSMU0ORobUAfkpmwp6wbP+jbmiebyzn+Gy3MMveL67RsFPCs6ISycA So+AqOJ7xibRFGE/R1WRgpuma/mUj0fIdJLARydDefZQm9ki3kP8vKE9qoTOEqD6qnGuy0 XkFCJ1vbJXPM+w92wEgzlZtjFCW5eVmux4Xve+N4vBpyD8krx3VBM6Gmz0+kbSAzJzheY9 0rVwuzwFQ0UvGpzjjxbnmIWIZf9vamm8jFMZsO5J8c8UNpG13lBKV6Q8J9mwxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713449966; 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=FJCqDs9K1VJsl33l9V+5ALTJW3ouF4LDU3laQbUlKpY=; b=ooEgVFmjngBj6tPwu2MNSVuX1HLw0ezwZDs2xQgL/dpG+xg1Selpo4A1Bzr1XgSwIk+Z7o z5ff4HS6vfuavucHQBGyanDjbBivM4Rv0Ic85zo7o1aJtpI05oWWp3wFks8n8D9rM8lfdI 8uTKiki2GE2U3FLBZpykZIC8Ak3WfEWfOOqeINPYaQf+mtF5EG+cgTZ5Q2NvstBJvdPsxG E8nLXtnQ0e2Wh6gwbP8VMPKtmcl9gR3jppX8cDfDYjPO/maZv0WHcx6f04JcS3xUXuprTY unPSZ5kLpws8NOLCx1uPpyFsnYKB+NOuPufg2GawmOfIu0OW8ow7ePbvMMk1jw== 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 4VL0Jt3KM7z1C8r; Thu, 18 Apr 2024 14:19:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IEJQUD010636; Thu, 18 Apr 2024 14:19:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IEJQrS010633; Thu, 18 Apr 2024 14:19:26 GMT (envelope-from git) Date: Thu, 18 Apr 2024 14:19:26 GMT Message-Id: <202404181419.43IEJQrS010633@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: c0e5d8f9bda7 - stable/14 - mergemaster: postpone removal to FreeBSD 15 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c0e5d8f9bda7907c83901d25d1d123a5b180443f Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=c0e5d8f9bda7907c83901d25d1d123a5b180443f commit c0e5d8f9bda7907c83901d25d1d123a5b180443f Author: Ed Maste AuthorDate: 2024-04-16 14:19:14 +0000 Commit: Ed Maste CommitDate: 2024-04-18 14:05:01 +0000 mergemaster: postpone removal to FreeBSD 15 Mergemaster has been deprecated for quite some time, but was not removed prior to FreeBSD 14.0. Update the deprecation notice in the man page to reflect this. PR: 274967 Reported by: naddy Sponsored by: The FreeBSD Foundation (cherry picked from commit 73cce7d8886bc59284c757decb49deba046e73fc) --- usr.sbin/mergemaster/mergemaster.8 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/mergemaster/mergemaster.8 b/usr.sbin/mergemaster/mergemaster.8 index 695f1bba3474..20d746de347c 100644 --- a/usr.sbin/mergemaster/mergemaster.8 +++ b/usr.sbin/mergemaster/mergemaster.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd March 2, 2023 +.Dd April 16, 2024 .Dt MERGEMASTER 8 .Os .Sh NAME @@ -45,7 +45,7 @@ The .Nm utility is deprecated and may not be available in -.Fx 14.0 +.Fx 15.0 or later. Users are advised to use .Xr etcupdate 8 From nobody Thu Apr 18 14:54:49 2024 X-Original-To: dev-commits-src-branches@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 4VL15m2Mjmz5H1wF; Thu, 18 Apr 2024 14:54:52 +0000 (UTC) (envelope-from glebius@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL15m1pCsz4f4S; Thu, 18 Apr 2024 14:54:52 +0000 (UTC) (envelope-from glebius@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713452092; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Ng309tOzMlmuIJZK52IAgF4h4b3Zzc476eaTbMztQMI=; b=tqG5PzfhUT+cljHKVIREYcI8Ojd0fsDbEPaC+/OMuwdqZAG6DgEyqX3vr6isR6i+WltUDb B0UgIiXmsmwJRQaSXeJcFqi3JtQR3HWqKR7hqUdIgXWtjMCYtjU5Oz60mEW0BF6HMlJxEc YNGzB1f+B3ysa/pXIQw/bkLtMlYWZM8RiI9T2EchLibUHrSf1zT8SRkwVXJDmRQvOI1Sia yKOi4XYFMoV6ItuM74uqdP4q9LNQumaf6Q+4nIu60XIj8uZKjk/yTGy3p/TH3rQGnUsxIs LP0fiCyOaBTJdzG/eaL4GHfbIgZCPqL9LhQzDlmqleGY8Zdhx/Sb4M+SMIoDXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713452092; a=rsa-sha256; cv=none; b=upo0jJ4TELZDn9bmNULoa88EVNk3Ig9sPUjddlGsZgXnVE0R7EzOqHm6ht2JQ5ed+f1liF j9tmn3mEIaz5L3HV+SlsVSxskyNJaDh9ekOsxfCf4o1JRESoAY9q69aLE8rYGpOH6TBLHA IBu1JD4hY78a/p/SmTjEPlWYcA93gBbNEXY5f/4bprCMCFhTpk/gQaGnXAGRXt+0tMVvAL Y0xHUPGGqfMt1lGqUGZ7U5V1sgK5WtU8gJt32IwhF4CGmOVAGODi9TxXtFRXgMP8bUlcWL tPzAV14opUnAwvvtlXN/XzrKcWO8Verc4Os0jsw7BE7OzjnpPPiCw1evux1dvg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713452092; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Ng309tOzMlmuIJZK52IAgF4h4b3Zzc476eaTbMztQMI=; b=tFWOSFoFA+U2E9xgvPzcViAsq/dE9jXLZRW148JmTS4kFlhTqbn5gZS98ER6sbSWpg+2Ph GHmS2lEVVCKQELrkG4sxwOWqoRpWdkPgW4qZvVKtps109xihaf+Bt63bnCvi0Bo30rzvY9 5uHAJL1OYeu0rlrzQQs1Lmp8TXGYrvn9mW4H4aCgZ0lR2Y+vUsGUX8Dmr7nv40V92b912T kkR74rHL2Z8D/qqdidgn3Ok/CF1q7UZQP/G9durIpcXvpvufvetCCafux+scI1SPdjXm+b pleVdXp0aM5urTTWuBKOeOqe7115+l4Yp0TbAkgOrk1PC42MS1Y+KT0ZfOf0ow== Received: from cell.glebi.us (glebi.us [162.251.186.162]) (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) (Authenticated sender: glebius) by smtp.freebsd.org (Postfix) with ESMTPSA id 4VL15l4wHpz1Mfy; Thu, 18 Apr 2024 14:54:51 +0000 (UTC) (envelope-from glebius@freebsd.org) Date: Thu, 18 Apr 2024 07:54:49 -0700 From: Gleb Smirnoff To: Marko Zec Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-branches@freebsd.org Subject: Re: git: 8062f37d1c99 - stable/14 - vtnet: set VNET context in RX handler Message-ID: References: <202404161558.43GFwoEt095208@gitrepo.freebsd.org> <20240417102252.27e1038d@x25> List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240417102252.27e1038d@x25> Marko, On Wed, Apr 17, 2024 at 10:22:52AM +0200, Marko Zec wrote: M> > https://cgit.FreeBSD.org/src/commit/?id=8062f37d1c99ded250b36ad90fb32bb5f77ee600 M> ... M> > vtnet: set VNET context in RX handler M> M> Two questions: M> M> 1) why is vnet not resolved directly via ifp->if_vnet, i.e. why do we M> need to go through if_getvnet() here? Not only is if_getvnet() M> unnecessarily making a function call to return a value of a struct M> member already at hand, but is doing this on a hot path. if_getvnet() M> arrived in 0d2684e15e415cef652e0f75e88962a674bffe04 / D38202 as an M> "accessor" function with a declared intent to help a vendor maintaining M> their private out-of-tree drivers independent of changes in struct ifnet M> layout. While this indeed may make sense for certain vendor-specific M> use cases, why do we need to take a penalty of calling if_getvnet() in M> internal code, here and elsewhere? if_getvnet() use is starting to get M> widespread, and it would be nice if we could hear the reasoning behind M> this school of thought, and perhaps document when the call should be M> used, and when prefereably not? The intent to have struct ifnet opaque to drivers is already over 10 years old. Initially I had quite a radical branch in subversion, which was not finished. Later Juniper came with less radical changes, where they just hide every field under accessor function and we agreed it is all right as an intermediate step (which potentally can last very long). For vendor maintained drivers it is a clear win, for in house drivers not so clear. If the KPI fully hides ifnet, then resturcturings in sys/net can happen without touching a single driver in the tree. What you suggest is allowing two KPIs to exist in parallel officially - one for in house drivers and the other for vendor maintained. And allow that for an immesurable performance gain. I'd argue it is totally immesurable as we are talking about VirtIO driver - a driver that runs in a virtual machine, where no one can make a reproducible benchmark that would be able to detect such a micro optimization. I'd also argue that if somebody cares about performance at a level of optimizing out function calls, they'd probably be running without VIMAGE already and unlikely running in the virtual environment, as well. M> 2) why is CURVNET_SET_QUIET() used instead of CURVNET_SET()? Which VNET M> recursion are you trying to quiesce with the _QUIET() version? That's a good point, thanks! I will correct this. P.S. I'd really appreciate commits to main being reviewed before merge to stable/14. -- Gleb Smirnoff From nobody Thu Apr 18 15:56:23 2024 X-Original-To: dev-commits-src-branches@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 4VL2Sl5rsXz5H75r; Thu, 18 Apr 2024 15:56:23 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL2Sl5KYtz4tJW; Thu, 18 Apr 2024 15:56:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713455783; 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=dE+NonOoHG7y/GhpB45+j+VUNeOb0C77t9ULKcSSmJA=; b=t9d/mAH/W+4XaQZnwSKU0xzxZ//LxF4Zje20A94qEBZyapbkRIQR9SH6HPxhzL57YrIS0+ R431o3erdLIPRTTPsekW52qZUaN76PcOhcqh2O1xmT0bBWoiAOAHscks5Rx/Q4v+0Zk9Rz mbWNqPqph9+LYc2wWurO0iJV/NbHiymAEbrL+PUWqbFQojasR+GY7tdmvOJjDSHUPSWrwC aVO7Op8QvOw2oh0mUcmmkBU/sRaD2vzSjzI3urVf2hjk0YfStOmf3A225fdphNO7tg3AeH V5J+b9Cq0FkEvTsSnf9hER3Mwup+X51h6rR2t/E3VDeWnko0lbzZbrOy1dOaMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713455783; a=rsa-sha256; cv=none; b=BqRXvgtAhskYLQuVihtEgiMd+Ohv+G57JKXIS7Ezdgikai3Kb4ZWAw0bGIszYFylNGF5Ll JrjGuhj63dyJwJB8hbbfZVOaHSXh4UY9c1qNfxVXHUw3dqejHx8wJO3/5mTGruHtAXyeL7 mnWQJBJ3roEQf8ffTVjNI90/25LclabF9DKnPLKhOfrTRWWJ3VlAmhMDWA7B/L1TeDdhH5 Ebs3JDP9SwRwtEMxaEIExu7siXSaySU5/+L5DeKu5b1+vp79O4LQXnTAXpJ+h1YIwEv1pA v2zgQphVMKu7t17xoelEbePdeNr4LBCYyJRUTz6cUgLr85kCkatDSlm7UP8uQQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713455783; 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=dE+NonOoHG7y/GhpB45+j+VUNeOb0C77t9ULKcSSmJA=; b=ILufD5baKrgwTugQfa3NnRX3n/+/0CNpuhrAQQRvsQeytcQwvW7S+VlGd7L4kBV8nuxikx cLjhF7MwDHgjze1WDflahxGU6lSi1SfALt7DJ54seLZf/lxmvS7weEf5l/p8w/fQzETvWf 1tvKqnSod2OENhr8eUMnAkIiEJtHBM0EE+J7r8dcI0iLLbYGDXbjTjMIzreE3zz6px8jI/ /BPOya4ZhE9pT0+asWl1+IYjU+/5xGkGuhmEjcZj+7EY+vnfpdVGQ7yONqXDmRRCdA+aBK XUjxcfnUQO71VMAlac1yJipzmmSIaHh96k6AgOYEMNBUPhxKdw3Btgj9LPn6DQ== 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 4VL2Sl4wp1zGJq; Thu, 18 Apr 2024 15:56:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IFuNud079012; Thu, 18 Apr 2024 15:56:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IFuNTB079009; Thu, 18 Apr 2024 15:56:23 GMT (envelope-from git) Date: Thu, 18 Apr 2024 15:56:23 GMT Message-Id: <202404181556.43IFuNTB079009@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 02ea70eff39c - stable/13 - tcpdump: fix build List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 02ea70eff39c19157b232f154e0dad21950ca23e Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=02ea70eff39c19157b232f154e0dad21950ca23e commit 02ea70eff39c19157b232f154e0dad21950ca23e Author: Kristof Provost AuthorDate: 2024-04-18 15:55:34 +0000 Commit: Kristof Provost CommitDate: 2024-04-18 15:55:34 +0000 tcpdump: fix build Apply the change that was supposed to be in bf0700716a2e --- contrib/tcpdump/print-pfsync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/tcpdump/print-pfsync.c b/contrib/tcpdump/print-pfsync.c index cb1c3f3828fa..8a11b3a10463 100644 --- a/contrib/tcpdump/print-pfsync.c +++ b/contrib/tcpdump/print-pfsync.c @@ -86,7 +86,7 @@ pfsync_ip_print(netdissect_options *ndo , const u_char *bp, u_int len) { struct pfsync_header *hdr = (struct pfsync_header *)bp; - if (len < PFSYNC_HDRLEN || !ND_TTEST_LEN(bp, len)) + if (len < PFSYNC_HDRLEN || !ND_TTEST2(*bp, len)) ND_PRINT((ndo, "[|pfsync]")); else pfsync_print(ndo, hdr, bp + sizeof(struct pfsync_header), From nobody Thu Apr 18 18:12:23 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tg4ZY7z5HKTq; Thu, 18 Apr 2024 18:12:23 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tg3pr8z3ytw; Thu, 18 Apr 2024 18:12:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463943; 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=FmMGf21YnfAS5ffyAGuS9mKsW7XOK0hrT8VWQ2PtV0g=; b=q1idh3AGr98JGvV9WS9qvT5xR/fhrPWNgPHs58TTH7S8WY2FIKq4aHwopKRtPdjmzZd/cv fQ66b6bp7jwmpNnCbsVEIjFqEA41n8lxgW2YX2aFaz4cXrKALdnZnur2Hb2wZ7NgtrWeVD SahrXe9M8Vb5KYGuUU46TjsaE5xnc+JYaIu4eXU/MatHqESa4vqO99bK7xi/yISwNADG1P 0helGd6XNd8CWPjKrfYfTR+QV865JaKM1a7VSjLOB3b80qQHO+zGBOJeAyEnZRywASDVde zzL9o45CJQYP57Opx6YNvSUSGypp/mRN1mU0vp2/DYJLIh96fUp/ogAaKqE5iA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463943; a=rsa-sha256; cv=none; b=QlC4HQwIdmHhBGS7Iy6cBK/BljS4TfGbcWdI6B8zkq2esAm0t5gIfOzK27WrDGQkAE5VbE DDMRw++ca3OO0xlc2m505fATvwI1ZNYXHEDinJwFQaF2DwM3I0q8NFZigTAUkv8yQ89MuZ Ta+SuUwGTPSoZsHpTM3FltR2uKu7v+2aD04hMCFg+2Dw3BV8VLPAekmq9wekp2oqMpviWQ sOB5it0u3m25+DQWzXnDUWlhSzNXXaic1aTX/zk/y6p0oqKGVZv7ehbDGnX8UCMIcccYmj aHFZakM7hGPahPQuTtiSQUyFbs2IMERekFGkJ7uqHknFav1k/dA8MaVwBC0qhQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463943; 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=FmMGf21YnfAS5ffyAGuS9mKsW7XOK0hrT8VWQ2PtV0g=; b=F0OI2Mcx6kwJys4yMkm0Pk9iNqXrgBbpUdHUEqrnHaejXDLL5lTats18Mqx3HL7Y0ylpQo 5T+GSHaz2NFfvbEgZMFo87nBfaIWXspdU1wzYkmwi2oAZEwE3RmwuXX+JfquXG8YgNK5hi O8r96tKDYjFkXDgGKw/fjX58u/hrx2S53EWV4ISSdupXbhC1eKZADcIJrI0nqFH1a5IOOj UjYrkjOarrr79ibapKuOGLGI7bFwy9KPRUr9TUhLJrBTQz5id93C5tyQ/aHN2q/2hHWkk3 WykCGUFwWwKrkXxGHjx0z5G1am1bWhl0HaSPZgO34so9SrzMAoNM0QI71UmnhQ== 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 4VL5Tg3618zKjs; Thu, 18 Apr 2024 18:12:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICNjk016068; Thu, 18 Apr 2024 18:12:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICNsa016065; Thu, 18 Apr 2024 18:12:23 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:23 GMT Message-Id: <202404181812.43IICNsa016065@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 4e997a32db3d - stable/14 - riscv: Introduce support for APLIC interrupt controller List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4e997a32db3dd22503dcb8188d9fae84c8b79c1c Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=4e997a32db3dd22503dcb8188d9fae84c8b79c1c commit 4e997a32db3dd22503dcb8188d9fae84c8b79c1c Author: Himanshu Chauhan AuthorDate: 2024-02-14 15:31:26 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:09:02 +0000 riscv: Introduce support for APLIC interrupt controller This patch introduces support for the RISC-V APLIC interrupt controller [1]. Currently, it is only supports direct mode, i.e. without an IMSIC and functionally replacing the legacy RISC-V PLIC. Work on IMSIC support is in progress. [1] https://github.com/riscv/riscv-aia/releases/tag/1.0 Reviewed by: mhorne Discussed with: jrtc27 MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D43293 (cherry picked from commit ee91dae43d23a3fa94dca1c905157e66c73c45de) --- sys/conf/files.riscv | 1 + sys/riscv/riscv/aplic.c | 554 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 555 insertions(+) diff --git a/sys/conf/files.riscv b/sys/conf/files.riscv index 975f9d3f576e..cf121811ba23 100644 --- a/sys/conf/files.riscv +++ b/sys/conf/files.riscv @@ -27,6 +27,7 @@ libkern/memset.c standard libkern/strcmp.c standard libkern/strlen.c standard libkern/strncmp.c standard +riscv/riscv/aplic.c standard riscv/riscv/autoconf.c standard riscv/riscv/bus_machdep.c standard riscv/riscv/bus_space_asm.S standard diff --git a/sys/riscv/riscv/aplic.c b/sys/riscv/riscv/aplic.c new file mode 100644 index 000000000000..19b80409c0f2 --- /dev/null +++ b/sys/riscv/riscv/aplic.c @@ -0,0 +1,554 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2024 Himanshu Chauhan + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include + +#include "pic_if.h" + +#define APLIC_MAX_IRQS 1023 + +/* Smaller priority number means higher priority */ +#define APLIC_INTR_DEF_PRIO 1 + +static pic_disable_intr_t aplic_disable_intr; +static pic_enable_intr_t aplic_enable_intr; +static pic_map_intr_t aplic_map_intr; +static pic_setup_intr_t aplic_setup_intr; +static pic_post_ithread_t aplic_post_ithread; +static pic_pre_ithread_t aplic_pre_ithread; +static pic_bind_intr_t aplic_bind_intr; + +struct aplic_irqsrc { + struct intr_irqsrc isrc; + u_int irq; +}; + +struct aplic_softc { + device_t dev; + struct resource *mem_res; + struct resource *irq_res; + void *ih; + struct aplic_irqsrc isrcs[APLIC_MAX_IRQS + 1]; + unsigned int hart_indices[MAXCPU]; + int ndev; +}; + +#define APLIC_DOMAIN_CFG_IE (1UL << 8) /* Enable domain IRQs */ +#define APLIC_DOMAIN_CFG_DM (1UL << 2) /* IRQ delivery mode */ +#define APLIC_DOMAIN_CFG_BE (1UL << 0) /* Endianess */ + +#define APLIC_MODE_DIRECT 0 /* Direct delivery mode */ +#define APLIC_MODE_MSI 1 /* MSI delivery mode */ + +#define APLIC_SRC_CFG_DLGT (1UL << 10) /* Source delegation */ +#define APLIC_SRC_CFG_SM_SHIFT 0 +#define APLIC_SRC_CFG_SM_MASK (0x7UL << APLIC_SRC_CFG_SM_SHIFT) + +#define APLIC_SRC_CFG_SM_INACTIVE 0 /* APLIC inactive in domain */ +#define APLIC_SRC_CFG_SM_DETACHED 1 /* Detached from source wire */ +#define APLIC_SRC_CFG_SM_EDGE_RSE 4 /* Asserted on rising edge */ +#define APLIC_SRC_CFG_SM_EDGE_FLL 5 /* Asserted on falling edge */ +#define APLIC_SRC_CFG_SM_LVL_HI 6 /* Asserted when high */ +#define APLIC_SRC_CFG_SM_LVL_LO 7 /* Asserted when low */ + +/* Register offsets in APLIC configuration space */ +#define APLIC_DOMAIN_CFG 0x0000 +#define APLIC_SRC_CFG(_idx) (0x0004 + (((_idx) - 1) * 4)) +#define APLIC_TARGET(_idx) (0x3004 + (((_idx) - 1) * 4)) +#define APLIC_MMSIADDRCFG 0x1BC0 +#define APLIC_MMSIADDRCFGH 0x1BC4 +#define APLIC_SMSIADDRCFG 0x1BC8 +#define APLIC_SMSIADDRCFGH 0x1BCC +#define APLIC_SETIPNUM 0x1CDC +#define APLIC_CLRIPNUM 0x1DDC +#define APLIC_SETIENUM 0x1EDC +#define APLIC_CLRIENUM 0x1FDC +#define APLIC_SETIPNUM_LE 0x2000 +#define APLIC_SETIPNUM_BE 0x2004 +#define APLIC_GENMSI 0x3000 +#define APLIC_IDC_BASE 0x4000 + +#define APLIC_SETIE_BASE 0x1E00 +#define APLIC_CLRIE_BASE 0x1F00 + +/* Interrupt delivery control structure */ +#define APLIC_IDC_IDELIVERY_OFFS 0x0000 +#define APLIC_IDC_IFORCE_OFFS 0x0004 +#define APLIC_IDC_ITHRESHOLD_OFFS 0x0008 +#define APLIC_IDC_TOPI_OFFS 0x0018 +#define APLIC_IDC_CLAIMI_OFFS 0x001C + +#define APLIC_IDC_SZ 0x20 + +#define APLIC_IDC_IDELIVERY_DISABLE 0 +#define APLIC_IDC_IDELIVERY_ENABLE 1 +#define APLIC_IDC_ITHRESHOLD_DISABLE 0 + +#define APLIC_IDC_CLAIMI_PRIO_MASK 0xff +#define APLIC_IDC_CLAIMI_IRQ_SHIFT 16 +#define APLIC_IDC_CLAIMI_IRQ_MASK 0x3ff + +#define APLIC_IDC_CLAIMI_IRQ(_claimi) \ + (((_claimi) >> APLIC_IDC_CLAIMI_IRQ_SHIFT) \ + & APLIC_IDC_CLAIMI_IRQ_MASK) + +#define APLIC_IDC_CLAIMI_PRIO(_claimi) ((_claimi) & APLIC_IDC_CLAIMI_PRIO_MASK) + +#define APLIC_IDC_REG(_sc, _cpu, _field) \ + (APLIC_IDC_BASE + APLIC_IDC_##_field##_OFFS + \ + ((_sc->hart_indices[_cpu]) * APLIC_IDC_SZ)) + +#define APLIC_IDC_IDELIVERY(_sc, _cpu) \ + APLIC_IDC_REG(_sc, _cpu, IDELIVERY) + +#define APLIC_IDC_IFORCE(_sc, _cpu) \ + APLIC_IDC_REG(_sc, _cpu, IFORCE) + +#define APLIC_IDC_ITHRESHOLD(_sc, _cpu) \ + APLIC_IDC_REG(_sc, _cpu, ITHRESHOLD) + +#define APLIC_IDC_TOPI(_sc, _cpu) \ + APLIC_IDC_REG(_sc, _cpu, TOPI) + +#define APLIC_IDC_CLAIMI(_sc, _cpu) \ + APLIC_IDC_REG(_sc, _cpu, CLAIMI) + +#define APLIC_MK_IRQ_TARGET(_sc, _cpu, _prio) \ + (_sc->hart_indices[_cpu] << 18 | ((_prio) & 0xff)) + +#define aplic_read(sc, reg) bus_read_4(sc->mem_res, (reg)) +#define aplic_write(sc, reg, val) bus_write_4(sc->mem_res, (reg), (val)) + +static u_int aplic_irq_cpu; + +static inline int +riscv_cpu_to_hartid(int cpu) +{ + return pcpu_find(cpu)->pc_hart; +} + +static inline int +riscv_hartid_to_cpu(int hartid) +{ + int cpu; + + CPU_FOREACH(cpu) { + if (riscv_cpu_to_hartid(cpu) == hartid) + return cpu; + } + + return (-1); +} + +static int +fdt_get_hartid(device_t dev, phandle_t aplic) +{ + int hartid; + + /* Check the interrupt controller layout. */ + if (OF_searchencprop(aplic, "#interrupt-cells", &hartid, + sizeof(hartid)) == -1) { + device_printf(dev, + "Could not find #interrupt-cells for phandle %u\n", aplic); + return (-1); + } + + /* + * The parent of the interrupt-controller is the CPU we are + * interested in, so search for its hart ID. + */ + if (OF_searchencprop(OF_parent(aplic), "reg", (pcell_t *)&hartid, + sizeof(hartid)) == -1) { + device_printf(dev, "Could not find hartid\n"); + return (-1); + } + + return (hartid); +} + +static inline void +aplic_irq_dispatch(struct aplic_softc *sc, u_int irq, u_int prio, + struct trapframe *tf) +{ + struct aplic_irqsrc *src; + + src = &sc->isrcs[irq]; + + if (intr_isrc_dispatch(&src->isrc, tf) != 0) + if (bootverbose) + device_printf(sc->dev, "Stray irq %u detected\n", irq); +} + +static int +aplic_intr(void *arg) +{ + struct aplic_softc *sc; + struct trapframe *tf; + u_int claimi, prio, irq; + int cpu; + + sc = arg; + cpu = PCPU_GET(cpuid); + + /* Claim any pending interrupt. */ + claimi = aplic_read(sc, APLIC_IDC_CLAIMI(sc, cpu)); + prio = APLIC_IDC_CLAIMI_PRIO(claimi); + irq = APLIC_IDC_CLAIMI_IRQ(claimi); + + KASSERT((irq != 0), ("Invalid IRQ 0")); + + tf = curthread->td_intr_frame; + aplic_irq_dispatch(sc, irq, prio, tf); + + return (FILTER_HANDLED); +} + +static void +aplic_disable_intr(device_t dev, struct intr_irqsrc *isrc) +{ + struct aplic_softc *sc; + struct aplic_irqsrc *src; + + sc = device_get_softc(dev); + src = (struct aplic_irqsrc *)isrc; + + /* Disable the interrupt source */ + aplic_write(sc, APLIC_CLRIENUM, src->irq); +} + +static void +aplic_enable_intr(device_t dev, struct intr_irqsrc *isrc) +{ + struct aplic_softc *sc; + struct aplic_irqsrc *src; + + sc = device_get_softc(dev); + src = (struct aplic_irqsrc *)isrc; + + /* Enable the interrupt source */ + aplic_write(sc, APLIC_SETIENUM, src->irq); +} + +static int +aplic_map_intr(device_t dev, struct intr_map_data *data, + struct intr_irqsrc **isrcp) +{ + struct intr_map_data_fdt *daf; + struct aplic_softc *sc; + + sc = device_get_softc(dev); + + if (data->type != INTR_MAP_DATA_FDT) + return (ENOTSUP); + + daf = (struct intr_map_data_fdt *)data; + if (daf->ncells != 2 || daf->cells[0] > sc->ndev) { + device_printf(dev, "Invalid cell data\n"); + return (EINVAL); + } + + *isrcp = &sc->isrcs[daf->cells[0]].isrc; + + return (0); +} + +static int +aplic_probe(device_t dev) +{ + if (!ofw_bus_status_okay(dev)) + return (ENXIO); + + if (!ofw_bus_is_compatible(dev, "riscv,aplic")) + return (ENXIO); + + device_set_desc(dev, "Advanced Platform-Level Interrupt Controller"); + + return (BUS_PROBE_DEFAULT); +} + +/* + * Setup APLIC in direct mode. + */ +static int +aplic_setup_direct_mode(device_t dev) +{ + struct aplic_irqsrc *isrcs; + struct aplic_softc *sc; + struct intr_pic *pic; + const char *name; + phandle_t node, xref, iparent; + pcell_t *cells, cell; + int error = ENXIO; + u_int irq; + int cpu, hartid, rid, i, nintr, idc; + + sc = device_get_softc(dev); + node = ofw_bus_get_node(dev); + + sc->dev = dev; + + if ((OF_getencprop(node, "riscv,num-sources", &sc->ndev, + sizeof(sc->ndev))) < 0) { + device_printf(dev, "Error: could not get number of devices\n"); + return (error); + } + + if (sc->ndev > APLIC_MAX_IRQS) { + device_printf(dev, "Error: invalid ndev (%d)\n", sc->ndev); + return (error); + } + + /* Request memory resources */ + rid = 0; + sc->mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, + RF_ACTIVE); + if (sc->mem_res == NULL) { + device_printf(dev, + "Error: could not allocate memory resources\n"); + return (error); + } + + /* Set APLIC in direct mode and enable all interrupts */ + aplic_write(sc, APLIC_DOMAIN_CFG, + APLIC_MODE_DIRECT | APLIC_DOMAIN_CFG_IE); + + /* Register the interrupt sources */ + isrcs = sc->isrcs; + name = device_get_nameunit(sc->dev); + for (irq = 1; irq <= sc->ndev; irq++) { + isrcs[irq].irq = irq; + + error = intr_isrc_register(&isrcs[irq].isrc, sc->dev, + 0, "%s,%u", name, irq); + if (error != 0) + goto fail; + + aplic_write(sc, APLIC_SRC_CFG(irq), + APLIC_SRC_CFG_SM_DETACHED); + } + + nintr = OF_getencprop_alloc_multi(node, "interrupts-extended", + sizeof(uint32_t), (void **)&cells); + if (nintr <= 0) { + device_printf(dev, "Could not read interrupts-extended\n"); + goto fail; + } + + /* interrupts-extended is a list of phandles and interrupt types. */ + for (i = 0, idc = 0; i < nintr; i += 2, idc++) { + /* Skip M-mode external interrupts */ + if (cells[i + 1] != IRQ_EXTERNAL_SUPERVISOR) + continue; + + /* Get the hart ID from the CLIC's phandle. */ + hartid = fdt_get_hartid(dev, OF_node_from_xref(cells[i])); + if (hartid < 0) { + OF_prop_free(cells); + goto fail; + } + + /* Get the corresponding cpuid. */ + cpu = riscv_hartid_to_cpu(hartid); + if (cpu < 0) { + device_printf(dev, "Invalid cpu for hart %d\n", hartid); + OF_prop_free(cells); + goto fail; + } + + sc->hart_indices[cpu] = idc; + } + OF_prop_free(cells); + + /* Turn off the interrupt delivery for all CPUs within or out domain */ + CPU_FOREACH(cpu) { + aplic_write(sc, APLIC_IDC_IDELIVERY(sc, cpu), + APLIC_IDC_IDELIVERY_DISABLE); + aplic_write(sc, APLIC_IDC_ITHRESHOLD(sc, cpu), + APLIC_IDC_ITHRESHOLD_DISABLE); + } + + iparent = OF_xref_from_node(ofw_bus_get_node(intr_irq_root_dev)); + cell = IRQ_EXTERNAL_SUPERVISOR; + irq = ofw_bus_map_intr(dev, iparent, 1, &cell); + error = bus_set_resource(dev, SYS_RES_IRQ, 0, irq, 1); + if (error != 0) { + device_printf(dev, "Unable to register IRQ resource\n"); + return (ENXIO); + } + + rid = 0; + sc->irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid, + RF_ACTIVE); + if (sc->irq_res == NULL) { + device_printf(dev, + "Error: could not allocate IRQ resources\n"); + return (ENXIO); + } + + xref = OF_xref_from_node(node); + pic = intr_pic_register(sc->dev, xref); + if (pic == NULL) { + error = ENXIO; + goto fail; + } + + error = bus_setup_intr(dev, sc->irq_res, INTR_TYPE_CLK, + aplic_intr, NULL, sc, &sc->ih); + if (error != 0) { + device_printf(dev, "Unable to setup IRQ resource\n"); + return (ENXIO); + } + +fail: + return (error); +} + +static int +aplic_attach(device_t dev) +{ + int rc; + + /* APLIC with IMSIC on hart is not supported */ + if (ofw_bus_has_prop(dev, "msi-parent")) { + device_printf(dev, "APLIC with IMSIC is unsupported\n"); + return (ENXIO); + } + + rc = aplic_setup_direct_mode(dev); + + return (rc); +} + +static void +aplic_pre_ithread(device_t dev, struct intr_irqsrc *isrc) +{ + aplic_disable_intr(dev, isrc); +} + +static void +aplic_post_ithread(device_t dev, struct intr_irqsrc *isrc) +{ + aplic_enable_intr(dev, isrc); +} + +static int +aplic_setup_intr(device_t dev, struct intr_irqsrc *isrc, struct resource *res, + struct intr_map_data *data) +{ + struct aplic_irqsrc *src; + struct aplic_softc *sc; + + CPU_ZERO(&isrc->isrc_cpu); + + sc = device_get_softc(dev); + src = (struct aplic_irqsrc *)isrc; + + aplic_write(sc, APLIC_SRC_CFG(src->irq), APLIC_SRC_CFG_SM_EDGE_RSE); + + /* + * In uniprocessor system, bind_intr will not be called. + * So bind the interrupt on this CPU. If secondary CPUs + * are present, then bind_intr will be called again and + * interrupts will rebind to those CPUs. + */ + aplic_bind_intr(dev, isrc); + + return (0); +} + +static int +aplic_bind_intr(device_t dev, struct intr_irqsrc *isrc) +{ + struct aplic_softc *sc; + struct aplic_irqsrc *src; + uint32_t cpu, hartid; + + sc = device_get_softc(dev); + src = (struct aplic_irqsrc *)isrc; + + /* Disable the interrupt source */ + aplic_write(sc, APLIC_CLRIENUM, src->irq); + + if (CPU_EMPTY(&isrc->isrc_cpu)) { + cpu = aplic_irq_cpu = intr_irq_next_cpu(aplic_irq_cpu, + &all_cpus); + CPU_SETOF(cpu, &isrc->isrc_cpu); + } else { + cpu = CPU_FFS(&isrc->isrc_cpu) - 1; + } + + hartid = riscv_cpu_to_hartid(cpu); + + if (bootverbose) + device_printf(dev, "Bind irq %d to cpu%d (hart %d)\n", src->irq, + cpu, hartid); + + aplic_write(sc, APLIC_TARGET(src->irq), + APLIC_MK_IRQ_TARGET(sc, cpu, APLIC_INTR_DEF_PRIO)); + aplic_write(sc, APLIC_IDC_IDELIVERY(sc, cpu), + APLIC_IDC_IDELIVERY_ENABLE); + aplic_enable_intr(dev, isrc); + + return (0); +} + +static device_method_t aplic_methods[] = { + DEVMETHOD(device_probe, aplic_probe), + DEVMETHOD(device_attach, aplic_attach), + + DEVMETHOD(pic_disable_intr, aplic_disable_intr), + DEVMETHOD(pic_enable_intr, aplic_enable_intr), + DEVMETHOD(pic_map_intr, aplic_map_intr), + DEVMETHOD(pic_pre_ithread, aplic_pre_ithread), + DEVMETHOD(pic_post_ithread, aplic_post_ithread), + DEVMETHOD(pic_post_filter, aplic_post_ithread), + DEVMETHOD(pic_setup_intr, aplic_setup_intr), + DEVMETHOD(pic_bind_intr, aplic_bind_intr), + + DEVMETHOD_END +}; + +DEFINE_CLASS_0(aplic, aplic_driver, aplic_methods, sizeof(struct aplic_softc)); + +EARLY_DRIVER_MODULE(aplic, simplebus, aplic_driver, 0, 0, + BUS_PASS_INTERRUPT + BUS_PASS_ORDER_MIDDLE); From nobody Thu Apr 18 18:12:25 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tk0rrDz5HKN9; Thu, 18 Apr 2024 18:12:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tj5VVQz3yvF; Thu, 18 Apr 2024 18:12:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463945; 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=/CF2CWUjrDa/7Rr/hGqmYXb7hwn+TE0+Aflss/0P+Y0=; b=xKpKUWkTjMvWwPrUty4qAjxNSqqlxmfUhF1Lbt3viludimA5gGEjxzT5QGwyfXPbH7Okof 9juDoqvEvbb7wDNKOx+GzD98kDuXVnXktt0M3AvH0mtFX4MEYsPPd65Buj2eosPCnv+tSk 1DOXR36HXFO2dDbKFlxFx4gI3sU6DJNtFQy9jgQ34AaLg0Bv5bqINOrwNlki9LpUlx10qd vni97m9WlyLMyxZTnxBXX+mdjs92YypnrljA0L2qMx36+uIfX55oVKwPASi2vdQXj+pErj pAqZc+ST7i+pg6+jGGOzIh5A3hcBXXNwGP8IrDyxex/7DZ7fOvMTnkiGel6R8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463945; a=rsa-sha256; cv=none; b=rxGDLqI9sV5g1vL+twthl+VluOIu1ckXhBEj5ESml3O7tAan1ghonWOEVl0h3LT+2/Froe W2PW9lm3B9DnwsFhpbnAxK1EEpr/Xka87/YHzery97AmDGlx9Q/27QmT5wWQMHXXQSxibm gRibkOoRWWPCkWnVd6h6C7P+z6EcE2MC6PeMYusaUtHF2rzW73BhJ+0f/qTziVvdYzwkb0 bqgW5bTUZ0rWp5WZdqmRLn7bU5FDTQWeTwU8tJV/d6AZCxlqZIoaJsNtRZBbOZ8CMtp6X4 eTXVkgQTYm2YriT07MlJOu/SaCyOyzuyvc/qVHKfMgUbnc5+UCNpLkYWZN++lA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463945; 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=/CF2CWUjrDa/7Rr/hGqmYXb7hwn+TE0+Aflss/0P+Y0=; b=BzpMWmApxeMTl5wkPLNttwlaCTNd9EzQBHMqHBv+qIZvAon5MLtmDeftO29Et7W2xY9660 vQDQegBYo6JDG2egvMyUjnq6VvFhHWAabXBGO7NmQXo8wEyp7vlYMnaNWlCjawkoTqQfyi 6Co5kcqsyN9qJaDht1vQwQrK1/LaqDMxtEpOPfO9HTD8aRvksIptl+Sol7U1vrdAwnQO0m MwZLusPXsvPENfSXBT7Iq3/bHXGsVvaYw/OIk266d7RBIjNpHhzTDgCQN4u4Oxzt6Ae2ZP XIeBNIiaF+ith4uKIAbZ5jzx/nHf7dW5iF6py4cuIoems1jerk6W8qc3f7rvbw== 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 4VL5Tj55tgzL1F; Thu, 18 Apr 2024 18:12:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICPOp016157; Thu, 18 Apr 2024 18:12:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICP5P016154; Thu, 18 Apr 2024 18:12:25 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:25 GMT Message-Id: <202404181812.43IICP5P016154@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 9050a43e8e2c - stable/14 - intro.9: minor changes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9050a43e8e2c458f7a93b55dc3f2c642dd26dbc1 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=9050a43e8e2c458f7a93b55dc3f2c642dd26dbc1 commit 9050a43e8e2c458f7a93b55dc3f2c642dd26dbc1 Author: Graham Perrin AuthorDate: 2023-08-06 17:34:03 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:11:30 +0000 intro.9: minor changes A correction: 'and' -> 'an'. Plus, several tweaks for brevity or clarity. Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/813 (cherry picked from commit 712fd5ac9181b544d8ffcf88ab6313233c8ddaed) --- share/man/man9/intro.9 | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/share/man/man9/intro.9 b/share/man/man9/intro.9 index 458ee0ab4697..e13566725976 100644 --- a/share/man/man9/intro.9 +++ b/share/man/man9/intro.9 @@ -6,7 +6,7 @@ .\" This manual page was written by Mitchell Horne under .\" sponsorship from the FreeBSD Foundation. .\" -.Dd August 2, 2023 +.Dd January 30, 2024 .Dt INTRO 9 .Os .Sh NAME @@ -16,7 +16,7 @@ Welcome to the .Fx kernel documentation. -Outside of the source code itself, this set of +Outside the source code itself, this set of .Xr man 1 pages is the primary resource for information on usage of the numerous programming interfaces available within the kernel. @@ -177,9 +177,10 @@ The kernel interface for file systems is File system implementations register themselves with .Xr vfsconf 9 . .Pp -The abstract and filesystem-independent representation of a file, directory, or -other file-like entity within the kernel is the -.Xr vnode 9 . +The +.Xr vnode 9 +is the abstract and filesystem-independent representation of a file, +directory, or other file-like entity within the kernel. .Pp The implementation of access control lists for filesystems is described by .Xr acl 9 . @@ -371,7 +372,7 @@ Signals can be sent to processes or process groups using the functions described by .Xr psignal 9 . .Ss Security -See the generic security overview in +See the overview in .Xr security 7 . .Pp The basic structure for user credentials is @@ -397,7 +398,7 @@ see .Xr mac 9 . .Pp Cryptographic services are provided by the OpenCrypto framework. -This API provides and interface for both consumers and crypto drivers; +This API provides an interface for both consumers and crypto drivers; see .Xr crypto 9 . .Pp @@ -409,9 +410,9 @@ and The interfaces for declaring loadable kernel modules are described by .Xr module 9 . .Ss Interrupts -The machine-independent portion of the interrupt framework supporting the -registration and execution of interrupt handlers is described by -.Xr intr_event 9 . +.Xr intr_event 9 +describes the machine-independent portion of the interrupt framework +that supports registration and execution of interrupt handlers. .Pp Software interrupts are provided by .Xr swi 9 . @@ -450,17 +451,16 @@ Kernel sanitizers can perform additional compiler-assisted checks against memory use/access. These runtimes are capable of detecting difficult-to-identify classes of bugs, at the cost of a large overhead. -Supported is the Kernel Address Sanitizer -.Xr KASAN 9 , -and the Kernel Memory Sanitizer -.Xr KMSAN 9 . +The Kernel Address Sanitizer +.Xr KASAN 9 +and Kernel Memory Sanitizer +.Xr KMSAN 9 +are supported. .Pp The -.Cd LOCK_PROFILING +.Xr LOCK_PROFILING 9 kernel config option enables extra code to assist with profiling and/or -debugging lock performance; -see -.Xr LOCK_PROFILING 9 . +debugging lock performance. .Ss Driver Tools Defined functions/APIs for specific types of devices. .Bl -tag -width "Xr usbdi 9" @@ -514,6 +514,6 @@ The kernel object implementation is described by .Xr man 1 , .Xr style 9 .Rs -.%T "The FreeBSD Architecture Handbook" -.%U "https://docs.freebsd.org/en/books/arch-handbook/" +.%T The FreeBSD Architecture Handbook +.%U https://docs.freebsd.org/en/books/arch-handbook/ .Re From nobody Thu Apr 18 18:12:24 2024 X-Original-To: dev-commits-src-branches@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 4VL5Th6t23z5HK3h; Thu, 18 Apr 2024 18:12:24 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Th4W72z3yv7; Thu, 18 Apr 2024 18:12:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463944; 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=YVQKBcdP/jxJ4sC6hZORqTMveEBEKyGdzd2cHS5ZWys=; b=ZsbXrrTOJsQhfi+6g+g15lX0ynIYCeuzCmrfSEeyewnsUxJ9gcpVlHLXltret/tbj06wSx /f8DUbel2zfpXr2N1+xoA//M/m4bg4XeCAOtUOpG+VzderjNrKwQdm3+h/uIQe2mn1/5pc TexY82G5aDU/0GGehzazYMCQqbYgql4HDbQY3fffp1i2vuBhmPI/Cv4WttUndGW8u4aYfd s0zbVcKYnkPUv9I5RtRXvAqM1OaCNAIwp+kEYbH2tluarDLj1+afSJcGuxACOm3t1OTrht RupE8qcAaje49NLZ92s0E571XRfPe6Nyr/wCBkhr16Mft5/LYVJ7pMOOcqMsNw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463944; a=rsa-sha256; cv=none; b=J/xHw9WeSfCh/sduHKqLXE9dKgMalwcu86Z3/SZkcKdgDCUN1fa0K3g8LI+WU6syLqa2bG bKhPH3yVTH2nnWBBts98rghKvNIeMapwf67eS5LJySHZ/RXdBvK+vZfa0SJQftNAAKNjog GBPZOsZua4Z8nK4IpbRfFF2zSQXj3xYT0KfxXlWoXFflZ3JQ87FKaAj0M/VRwk44jOdbZT GdqDuTALYgldSbnUqxu7GuYCtDf9AtT6HtSHi/2vQ1hutSIGZ+fAn1TTs+HAtrilw5nXiL r+PzE/zZN/78ZldfbqTkcBb21PQShw32Jgm3zZeJoByDX6eElvyhHGqeNi/EEA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463944; 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=YVQKBcdP/jxJ4sC6hZORqTMveEBEKyGdzd2cHS5ZWys=; b=b2GEXY593T5m0dNweLsGqf+tYjHXgwzE58+ZphwLwFmepRQIjtSjjRcwYyjHANgQScwJ7h OwqIZ2/FnxxiHs9zI6FjRVaPiXZXBgaqSmfJR/sq9wGHT5yrq7XrXnFbW2GkMJKfXRcKi8 GteHbNenS90B7LxevcA22G3NBw0E5/YhC7N7WFnu1VV9K6clrPAMiLrXTzOE180lJZHmpg cpoYPqa+vmBc761ErqNJ859fZfchOruFwMm+lo09mcPFqC6ky+SSRImYuv6kR9pMG61rA8 0LwlxnMFeQFaUAkmA1lh4UFyg8DH3csB40ce3Fsvx0Fz7yP5sSv+P88xiqdJEA== 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 4VL5Th47jszKjt; Thu, 18 Apr 2024 18:12:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICO2e016121; Thu, 18 Apr 2024 18:12:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICOsq016118; Thu, 18 Apr 2024 18:12:24 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:24 GMT Message-Id: <202404181812.43IICOsq016118@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 0a40193a6e0f - stable/14 - busdma: fix page miscount for small segment sizes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0a40193a6e0fdf73b618aec3bccfb05bd1d0ddf0 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=0a40193a6e0fdf73b618aec3bccfb05bd1d0ddf0 commit 0a40193a6e0fdf73b618aec3bccfb05bd1d0ddf0 Author: Mitchell Horne AuthorDate: 2021-05-25 21:04:56 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:09:02 +0000 busdma: fix page miscount for small segment sizes For small segments (< PAGE_SIZE) there is a mismatch between how required bounce pages are counted in _bus_dmamap_count_pages() and bounce_bus_dmamap_load_buffer(). This problem has been observed on the RISC-V VisionFive v2 SoC (and earlier revisions of the hardware) which has memory physically addressed above 4GB. This requires some bouncing for the dwmmc driver, which has has a maximum segment size of 2048 bytes. When attempting to load a page-aligned 4-page buffer that requires bouncing, we can end up counting 4 bounce pages for an 8-segment transfer. These pages will be incorrectly configured to cover only the first half of the transfer (4 x 2048 bytes). Fix the immediate issue by adding the maxsegsz check to _bus_dmamap_count_pages(); this is what _bus_dmamap_count_phys() does already. The result is that we will inefficiently allocate a separate bounce page for each segment (8 pages for the example above), but the transfer will proceed in its entirety. The more complete fix is to address the shortcomings in how small segments are assigned to bounce pages, so that we opportunistically batch multiple segments to a page whenever they fit (e.g. two 2048 bytes segments per 4096 page). This will be addressed more holistically in the future. For now this change will prevent the (silent) incomplete transfers that have been observed. PR: 273694 Reported by: Jari Sihvola Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D34118 (cherry picked from commit b134c10d658c3b350e04aa8dbd2628e955ddcce0) --- sys/arm/arm/busdma_machdep.c | 11 ++++++----- sys/arm64/arm64/busdma_bounce.c | 1 + sys/powerpc/powerpc/busdma_machdep.c | 1 + sys/riscv/riscv/busdma_bounce.c | 1 + sys/x86/x86/busdma_bounce.c | 1 + 5 files changed, 10 insertions(+), 5 deletions(-) diff --git a/sys/arm/arm/busdma_machdep.c b/sys/arm/arm/busdma_machdep.c index a4f2c803f30a..a24dcf94fe08 100644 --- a/sys/arm/arm/busdma_machdep.c +++ b/sys/arm/arm/busdma_machdep.c @@ -873,6 +873,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, pmap_t pmap, bus_dmamap_t map, vm_offset_t vaddr; vm_offset_t vendaddr; bus_addr_t paddr; + bus_size_t sg_len; if (map->pagesneeded == 0) { CTR5(KTR_BUSDMA, "lowaddr= %d, boundary= %d, alignment= %d" @@ -887,16 +888,16 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, pmap_t pmap, bus_dmamap_t map, vendaddr = (vm_offset_t)buf + buflen; while (vaddr < vendaddr) { + sg_len = MIN(vendaddr - vaddr, + (PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK))); + sg_len = MIN(sg_len, dmat->maxsegsz); if (__predict_true(pmap == kernel_pmap)) paddr = pmap_kextract(vaddr); else paddr = pmap_extract(pmap, vaddr); - if (must_bounce(dmat, map, paddr, - min(vendaddr - vaddr, (PAGE_SIZE - ((vm_offset_t)vaddr & - PAGE_MASK)))) != 0) { + if (must_bounce(dmat, map, paddr, sg_len) != 0) map->pagesneeded++; - } - vaddr += (PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK)); + vaddr += sg_len; } CTR1(KTR_BUSDMA, "pagesneeded= %d", map->pagesneeded); } diff --git a/sys/arm64/arm64/busdma_bounce.c b/sys/arm64/arm64/busdma_bounce.c index c1028f35ba7f..cd7655300dc4 100644 --- a/sys/arm64/arm64/busdma_bounce.c +++ b/sys/arm64/arm64/busdma_bounce.c @@ -717,6 +717,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, bus_dmamap_t map, pmap_t pmap, while (vaddr < vendaddr) { sg_len = PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK); + sg_len = MIN(sg_len, dmat->common.maxsegsz); if (pmap == kernel_pmap) paddr = pmap_kextract(vaddr); else diff --git a/sys/powerpc/powerpc/busdma_machdep.c b/sys/powerpc/powerpc/busdma_machdep.c index 873a67458dfc..6b70c0b34ede 100644 --- a/sys/powerpc/powerpc/busdma_machdep.c +++ b/sys/powerpc/powerpc/busdma_machdep.c @@ -573,6 +573,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, bus_dmamap_t map, pmap_t pmap, bus_size_t sg_len; sg_len = PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK); + sg_len = MIN(sg_len, dmat->maxsegsz); if (pmap == kernel_pmap) paddr = pmap_kextract(vaddr); else diff --git a/sys/riscv/riscv/busdma_bounce.c b/sys/riscv/riscv/busdma_bounce.c index 6b50dc527b66..dcd287806eaf 100644 --- a/sys/riscv/riscv/busdma_bounce.c +++ b/sys/riscv/riscv/busdma_bounce.c @@ -552,6 +552,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, bus_dmamap_t map, pmap_t pmap, while (vaddr < vendaddr) { sg_len = PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK); + sg_len = MIN(sg_len, dmat->common.maxsegsz); if (pmap == kernel_pmap) paddr = pmap_kextract(vaddr); else diff --git a/sys/x86/x86/busdma_bounce.c b/sys/x86/x86/busdma_bounce.c index b9943ad3792e..c60e239a5109 100644 --- a/sys/x86/x86/busdma_bounce.c +++ b/sys/x86/x86/busdma_bounce.c @@ -562,6 +562,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dmat, bus_dmamap_t map, pmap_t pmap, while (vaddr < vendaddr) { sg_len = PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK); + sg_len = MIN(sg_len, dmat->common.maxsegsz); if (pmap == kernel_pmap) paddr = pmap_kextract(vaddr); else From nobody Thu Apr 18 18:12:26 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tl1f9Hz5HK3j; Thu, 18 Apr 2024 18:12:27 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tk6VkLz3yvZ; Thu, 18 Apr 2024 18:12:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463946; 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=cFqbWD3irAuIcTbUvAVnW3UMOYmHUUUuTykO00UAHoY=; b=mY0neaPNBlLn3gC9Gs5jUzbBGlakTAo/jTUR7FJs85teXhsxLci9Zfs40vCbodHV4bVV8l 77xQifdXv1/izhdW1hLSWeRkjoD8/UYUNWK3kaL0aTsDSd0xOFSXGl9H99ohZDxXnXveqT ISmtPDBHLhtfotsNa0GTgbLTOHQSUS7WALkddIUusRkcwTx47qiqeKP3vxXJnQp+/Lk2N4 4Yx5tTtC/6gvM7NevAjIj7WYHMhjVuoZZw30I7Vh4bAnD8w3v6eA/DrsxUEJoWfnH7talz XdufZD+VF/v51w1BjqBSEwzoE9iImSaP2t+fW+s/Ph4cjjbnZwHJftugo9IOAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463946; a=rsa-sha256; cv=none; b=djgJLV17zzRNDRd/fz/p+4VTWlxqQCjRubcn93vn5RjsDvYzT7BP10jVEV3+3Xzc+1z8A2 p+b7Ks5yeNShfBLm6xmD4wkOYdpCTPO6wcVYCHDgmoHMzAmRCU0N4pMjSpNY5zZaHyuMXd uL+6m55qD1i37luuNJrEZYtKRDerxUHFdL2f6CkA+1wqXjxbI+IsyB1H8NJgMbJtvvkNWm YPA1letOdLLVKtExgZEnXffA3IlGc3plGDszKX6sM8CXJTfeXSVfXsbhnqba3hQAGBHx7w bBPe3hUDAVASksW0k3L0nAtA9ufBwTzSXxoO8X5H9i8VS7I7gPFS03iIXR9CnQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463946; 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=cFqbWD3irAuIcTbUvAVnW3UMOYmHUUUuTykO00UAHoY=; b=FbonUj2b19Nmx1AonkT7TBshmbqboOSg2xCujOk3HlToCK52I35dt3DupbZvUUqD0QdSjQ N0DRzeZpgdxWmSEaHzC0S+Puw77KvCxW6i4j9Leh/STr1k8VUFuHPCecreamEh9GlGqM/O KWsLI2CwwB77cytqJqDZ6Nyc9HGzGuPoJOlrji0yX4YVrpgbVOMGBRvMqm1nZeQekw6jcI vM9Z9CPGxi5CqAZiIDpMkngGnRm5fhbF5CxxkODUOO5xFPUY09/ZTR8Cjn5z9W1NQGjYQz KD3mkktNd09Ft+jUQTEy48/SjetMosbn2SoRqXBYiZv2kgyAZwfzj4yZudzcUQ== 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 4VL5Tk66z8zL1G; Thu, 18 Apr 2024 18:12:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICQDv016198; Thu, 18 Apr 2024 18:12:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICQXL016195; Thu, 18 Apr 2024 18:12:26 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:26 GMT Message-Id: <202404181812.43IICQXL016195@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 327987597bff - stable/14 - clkdom_dump(): improve output text List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 327987597bff4db5984d7704e7235647cc76c931 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=327987597bff4db5984d7704e7235647cc76c931 commit 327987597bff4db5984d7704e7235647cc76c931 Author: Mitchell Horne AuthorDate: 2024-03-08 14:09:08 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:11:31 +0000 clkdom_dump(): improve output text If the call to clknode_get_freq() returns an error (unlikely), report this, rather than printing the error code as the clock frequency. If the clock has no parent (e.g. a fixed reference clock), print "none" rather than "(NULL)(-1)". This is a more human-legible presentation of the same information. Reviewed by: manu MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44267 (cherry picked from commit 08635c51d1e34f8a3e42c7cf35dc7264a5b68118) --- sys/dev/extres/clk/clk.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/sys/dev/extres/clk/clk.c b/sys/dev/extres/clk/clk.c index c569b05b6189..46a1aaaf6fd9 100644 --- a/sys/dev/extres/clk/clk.c +++ b/sys/dev/extres/clk/clk.c @@ -512,10 +512,20 @@ clkdom_dump(struct clkdom * clkdom) CLK_TOPO_SLOCK(); TAILQ_FOREACH(clknode, &clkdom->clknode_list, clkdom_link) { rv = clknode_get_freq(clknode, &freq); - printf("Clock: %s, parent: %s(%d), freq: %ju\n", clknode->name, - clknode->parent == NULL ? "(NULL)" : clknode->parent->name, - clknode->parent_idx, - (uintmax_t)((rv == 0) ? freq: rv)); + if (rv != 0) { + printf("Clock: %s, error getting frequency: %d\n", + clknode->name, rv); + continue; + } + + if (clknode->parent != NULL) { + printf("Clock: %s, parent: %s(%d), freq: %ju\n", + clknode->name, clknode->parent->name, + clknode->parent_idx, (uintmax_t)freq); + } else { + printf("Clock: %s, parent: none, freq: %ju\n", + clknode->name, (uintmax_t)freq); + } } CLK_TOPO_UNLOCK(); } From nobody Thu Apr 18 18:12:27 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tm20cJz5HKNP; Thu, 18 Apr 2024 18:12:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tm0RN2z400w; Thu, 18 Apr 2024 18:12:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463948; 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=o9E1iy4wBa6pJyryHuSo5E5lANuPqJ3UL3YeBttrwG0=; b=ZOk02wIepViAHRhTXcWUAKaaTHIawwAf2AXCVJQhiVMsyzC/I0jS4y+Ij20amYtJSZTRfT K0nfufo460LkOKeUUP0XoOdw/oyFtajkN83OUO1wc1wGkJm9nX/SjTJzKfieCd4+xM9GJ2 FYi5nJER1UVPiRbzlyUJN7aQCVaI9Vme3MjT6/6HjBkxykP+ZCTnKYKqpo1LMwsjWz6fd5 3bBZgFRS60JD79iYgfvYzoKpOqmT2mlEipsqEDoaOoj1uiPjCUjUqWjgOmoBu+yJ/aaJg5 9xCxgANidJQLSgIuYXl6y40Att8URyPBiNpVo6cHaVz103OzEWXMjxPqAHW/Ng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463948; a=rsa-sha256; cv=none; b=G/CQPMYzuti2oYksPzEcj6TKHN/2Q5mGsx92NFnE18fKUlSgowI6JiZ9Ln6cQ9AhMkWx9k Tj4fS54Pbr6ABefCx4kXlUn2WWh4WA5B4sXsv2oxS8/3RYixZxZT3FWswzgWQUsJB9j56o TlWsqNd0npOD6bqAL5m5AmyTwtOfHbC3/QrRRc7oXRNn3SejD/u2jUzf5Dr2dTE5n2zJ3I wNwonJdEwFMTizerqqWYN71ZbJOFASex44I5Used+/XwGQWjovhrOJh0L6j0hGeHnYR9Er UfUVAd18dJcUNk5BpEvw2HUbQMlGshrJCwvYkeIlto5eN4wVPrH959Q7xUG8yQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463948; 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=o9E1iy4wBa6pJyryHuSo5E5lANuPqJ3UL3YeBttrwG0=; b=naLcZe6USFh08CL2yJjnUCULSxQpwCkLc/h9hnd01Y8kJXv9MIQcoUouZUwwSiRkgp1MS+ WK8+Cg332Hk7gjFlnZVlEBwk2TpLimUcqevKQPGWrLWbwwrKv4Tm835YUVMgeatuTZcglZ wnxiohHNvI9vMcRJT4aBH5Xu7Eh7Om4ZYJNH2bOSzmTINYx5dFwIl3FroTJxeRI4MypJYC uzHuOKZaNNuMpv2Tzu0mPHGHynqp+LwrOEEcN7SgCj3j8Rp5PVf2S68484muOzBMQXQgir ekYmGwlEMg/oqN5u+DEVUatMS4bwKXYSqEtsSHopJ/CfvFIKYthMwseU9sKEFQ== 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 4VL5Tm01WBzL1H; Thu, 18 Apr 2024 18:12:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICRao016237; Thu, 18 Apr 2024 18:12:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICRhv016234; Thu, 18 Apr 2024 18:12:27 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:27 GMT Message-Id: <202404181812.43IICRhv016234@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 5eb27a0d68f5 - stable/14 - clk_fixed: quiet by default List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5eb27a0d68f5b7cd64d5a269b727c5f22185a40c Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=5eb27a0d68f5b7cd64d5a269b727c5f22185a40c commit 5eb27a0d68f5b7cd64d5a269b727c5f22185a40c Author: Mitchell Horne AuthorDate: 2024-03-08 14:08:49 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:11:31 +0000 clk_fixed: quiet by default We may attach several of these devices, but there is no meaningful information added to dmesg. For example: ofwbus0: clk_fixed0: on ofwbus0 clk_fixed1: on ofwbus0 clk_fixed2: on ofwbus0 clk_fixed3: on ofwbus0 clk_fixed4: on ofwbus0 clk_fixed5: on ofwbus0 clk_fixed6: on ofwbus0 clk_fixed7: on ofwbus0 clk_fixed8: on ofwbus0 clk_fixed9: on ofwbus0 clk_fixed10: on ofwbus0 clk_fixed11: on ofwbus0 To reduce this noise, quiet the devices for by default. For verbose boot, the message will be emitted. Reviewed by: manu MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44266 (cherry picked from commit 1cb9f6f6413e9d242de47e730ec7d4ce3e5688fe) --- sys/dev/extres/clk/clk_fixed.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/dev/extres/clk/clk_fixed.c b/sys/dev/extres/clk/clk_fixed.c index e5ca6b31d000..1a61f0013bb2 100644 --- a/sys/dev/extres/clk/clk_fixed.c +++ b/sys/dev/extres/clk/clk_fixed.c @@ -163,13 +163,18 @@ clk_fixed_probe(device_t dev) return (ENXIO); } device_set_desc(dev, "Fixed clock"); - return (BUS_PROBE_DEFAULT); + break; case CLK_TYPE_FIXED_FACTOR: device_set_desc(dev, "Fixed factor clock"); - return (BUS_PROBE_DEFAULT); + break; default: return (ENXIO); } + + if (!bootverbose) + device_quiet(dev); + + return (BUS_PROBE_DEFAULT); } static int From nobody Thu Apr 18 18:12:29 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tn2xG6z5HK3r; Thu, 18 Apr 2024 18:12:29 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tn18LPz40C7; Thu, 18 Apr 2024 18:12:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463949; 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=FL1uJztGcrVxWad3demoT/Qd3iyIawd9mZnul49vxNk=; b=IvV4XYeuYcB7nmHt2Jbr96J942j4fzvP45XdQjjnuJdpNBukNGGQCxROBq+lWwBKXIRPUc ukBv8bq8y2ub/qT5fJNWH7efMQCcfImVMMoXT02wpExl6SAUgfa6M3ElQfeaToT1kqb+a8 1EnDwyzRbMyAqUJmJDKPggSASaQR2ttZ5jv+nnwq0sqnfcUO8uq9CLhicRFWAKZOlPYd7a C65UKTSlfjcmxwHjkNO4CerUJVO8tJTeQQGuriGJVfGvrK1UNNm2+Go8n3nmqW47BAFRZm Ym0ogW3inSlugB10ITH3snU22hdJ0dZZbTmbmAtjBSzfqncB9Nz9mxIyqEh2gA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463949; a=rsa-sha256; cv=none; b=Wq8nay/C9GpJJAsKrz74e7MJREI8Zxk2Zuq90lpmx/L1Laf8viN5vhhjtNmXtoDN/sX9vl EurZcyz6XmSlgbXPP21Z56Eh1gmWJWCUi6knPijThGgwNntvvtiaEN814sIOXF1xk8CPxk 1WMTjIpt6ZNZAjzceVu3B2lN1gW3ditSo3iW+tVIftJetUtbogR0tfD9tBAZhdCP0UzwkP xuPqeEiHIO972YDkq7PkI0fy57crstqlTe3OYFzPcTHyoUC+u7zJWkc81IltK5+lbJ5XZZ g8JidSj6vFl4OFVv0HAJnrldSAvfFzLKcjTG5tavq2pMPK6uTuc8+oM7drlUYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463949; 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=FL1uJztGcrVxWad3demoT/Qd3iyIawd9mZnul49vxNk=; b=RJ6cgxVPpGnusEb3//ByBP10NcjOtjPJxgqFCSEa/r5i3THMYGmUdgWe/axOX79uUrcbGy XmE7C63lED1xH2SAxVpLwOy/FqymXGihZRfPVSrz52olEtnDtmMU7Y16uico6d+UsqTKzE 7Lor+5njoyAp1L1+Yn7idltDcNtbjWMwSFo71t4L0OET/7h4GSHySp9M7c3wfN9CEqZ9/A JCTSk2/HmN0PgnIFfZYvRXdAhNujo9quFlOC8amLumNtFbizRTt6iQkJEG5y1h2qiThohC QNDEWpigsgxKOvsa22iX75eM46UtHY2RflPEBhYr/wspuIsT4siMHgBcq3ydjQ== 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 4VL5Tn0kX2zL1J; Thu, 18 Apr 2024 18:12:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICT4p016282; Thu, 18 Apr 2024 18:12:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICTs7016279; Thu, 18 Apr 2024 18:12:29 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:29 GMT Message-Id: <202404181812.43IICTs7016279@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 29701960b3ba - stable/14 - clk_fixed: call clkdom_dump() for verbose boot List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 29701960b3ba792c8897cce23605ee79ec91c89e Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=29701960b3ba792c8897cce23605ee79ec91c89e commit 29701960b3ba792c8897cce23605ee79ec91c89e Author: Mitchell Horne AuthorDate: 2024-03-08 14:08:22 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:11:31 +0000 clk_fixed: call clkdom_dump() for verbose boot This is standard practice for clock drivers that register clocks dynamically. Nothing else uses the CLK_DEBUG macro. The result is that the name and frequency of the fixed clock is printed for a verbose boot, which may aid in debugging. Reviewed by: manu MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44265 (cherry picked from commit 6e66bb9fc3d026765113fa1258cd12292da9309a) --- sys/dev/extres/clk/clk_fixed.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/dev/extres/clk/clk_fixed.c b/sys/dev/extres/clk/clk_fixed.c index 1a61f0013bb2..62c094a65da8 100644 --- a/sys/dev/extres/clk/clk_fixed.c +++ b/sys/dev/extres/clk/clk_fixed.c @@ -263,9 +263,10 @@ clk_fixed_attach(device_t dev) rv = ENXIO; goto fail; } -#ifdef CLK_DEBUG - clkdom_dump(sc->clkdom); -#endif + + if (bootverbose) + clkdom_dump(sc->clkdom); + OF_prop_free(__DECONST(char *, def.clkdef.name)); OF_prop_free(def.clkdef.parent_names); return (bus_generic_attach(dev)); From nobody Thu Apr 18 18:12:30 2024 X-Original-To: dev-commits-src-branches@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 4VL5Tp4d0Kz5HKLQ; Thu, 18 Apr 2024 18:12:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5Tp25Ypz400Z; Thu, 18 Apr 2024 18:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463950; 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=rnKNZqH9P9MqTJq0gnhafU3I9HnUXlATmX7Qw3ZlwwI=; b=Vl1UfSVIs9klSNiw97xMir6jJgKf95BMZd5r9BcAifJcXjytiIIyu7ER8N1vdX5CNQW9lr snZjj12sOZK8Z0GOgwyNW/ficrkcOSxRfsSxECiVoY4h3EoxztPfkjUhlZ1+6Gv2BF/jNz dkoKI3JSTWo6NqAqPOiDfuhlk7B6kBgTlpHeUuidlD5D/e6emi91RlNYWutZpiC35I93+a 0IS8V3U9vTnoq/cHzPB3EZWNIOIySXYTUNHFfTN++vhL7dRFk5hJD8XonIhHRw1XKDsBoy TR+AL4gUCsSAQ/DF9egb/IcmJsLgrpHo3vbysBCLdAmR8JrTqaom6QLm5SqJMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713463950; a=rsa-sha256; cv=none; b=gJwN3P26NQqGOtVfOS4XLB8BSJ/6SyaO/pBN8r/65TkCyFGTgwIpaonQ8zAyCfV2GzSVRs Rm0G62wOqyq0L0ezfGia6o1E1sbIls82vYRa2gNEAN7i9V1RdVAvbKem6h/HONlQDZIGF2 kTHWfs10MNs5mJe7Nm/73KVbRAw8+0NUaqCtWr0BeFqfWVgA3tB9tETBXS5z7iQzcV4WS3 Htpteudum2HkjKQBWlg38EJI/J1VNOqHU5mwvR+CEuq3IScQwE2CohQLw9PZU7ailZ71ou t4+WFUGAgRdDEflfOflKakEJNYU8gIo0sqGuwGOiXbf7bqPQmUqfZQuiYeuQ8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713463950; 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=rnKNZqH9P9MqTJq0gnhafU3I9HnUXlATmX7Qw3ZlwwI=; b=Qw8uwp7nmwnA9EtvvXOnrmlrGfSxmf7UD8tbURzPsXGkaTmFvbwx6b/yc7C95kb3sze5Re DzqaCnFeFUV6VqtOv1/p9nAIOXU5bjrN9xNd95W9V0qcIsPaVtBvWywI4AoU6uOcDVISuo 4tI7GvKuRc8aGqbzpeM2lFs4530pZ0DEJVNheZtUw5xXebvn1lt//NsJtWmfktOHjSrl9v 5UpMvFMt1PSTVjYjGoTUiYwI1DEf3MI3y/QX5Io131O7Sh5tDjSiHVvDlx2TBXuLAnNTk4 wTyHpq1ty7IZQnXkgxiD7PdQIxazwBZEO0yY1Ao+NNWAe8aW7ziB5+DfZtgDtA== 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 4VL5Tp1jXPzJxd; Thu, 18 Apr 2024 18:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IICUO4016326; Thu, 18 Apr 2024 18:12:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IICUTb016323; Thu, 18 Apr 2024 18:12:30 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:12:30 GMT Message-Id: <202404181812.43IICUTb016323@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 9319a8a11a6f - stable/14 - simple_mfd: don't attach children twice List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9319a8a11a6fcebc87109f8bf0f5dc362dd1fe07 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=9319a8a11a6fcebc87109f8bf0f5dc362dd1fe07 commit 9319a8a11a6fcebc87109f8bf0f5dc362dd1fe07 Author: Mitchell Horne AuthorDate: 2024-03-08 14:09:17 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:11:31 +0000 simple_mfd: don't attach children twice Trying to probe+attach the child device at the point it is added comes before the syscon handle is set up (if relevant). It will therefore be unavailable to the attach method which is expecting it, and the first attempt to attach the device will fail. Just rely on the call to bus_generic_attach() at the end of the function to perform probe+attach of dev's children. Reviewed by: manu MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44268 (cherry picked from commit accda781531788a814bc438e1e96ef544c12aeaf) --- sys/dev/fdt/simple_mfd.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/dev/fdt/simple_mfd.c b/sys/dev/fdt/simple_mfd.c index 888de7756f39..865cd0e2b9ab 100644 --- a/sys/dev/fdt/simple_mfd.c +++ b/sys/dev/fdt/simple_mfd.c @@ -169,7 +169,6 @@ simple_mfd_attach(device_t dev) { struct simple_mfd_softc *sc; phandle_t node, child; - device_t cdev; int rid; sc = device_get_softc(dev); @@ -204,9 +203,7 @@ simple_mfd_attach(device_t dev) /* Attach child devices */ for (child = OF_child(node); child > 0; child = OF_peer(child)) { - cdev = simple_mfd_add_device(dev, child, 0, NULL, -1, NULL); - if (cdev != NULL) - device_probe_and_attach(cdev); + (void)simple_mfd_add_device(dev, child, 0, NULL, -1, NULL); } if (ofw_bus_is_compatible(dev, "syscon")) { From nobody Thu Apr 18 18:18:59 2024 X-Original-To: dev-commits-src-branches@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 4VL5dH6nsrz5HKnw; Thu, 18 Apr 2024 18:18:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dH66Hvz41qH; Thu, 18 Apr 2024 18:18:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464339; 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=ENojOBW5cI4DEBWCscZmfgTEu2XP3h1Vn+Dv316kD+4=; b=P+RMdR+gGmtUCcyCiYKgalZJmGODZlwExpAKYM7mTTcVszXdUlb73Qe5HdLmqpmHUMajoH sutNgkdPoy74X6FBJG58flg59sOclcE4m9M8ZNV4FKYG81fJ0Qbd8KMx+Cwscal/2cQ54f MdvqgVsjenGw66/aPre+cyOZ9CXiJBQdFvrjJQOZqbOZ2xz8blZ3o1rUj2A6eMhhCPq68F Ptue+0a9Jbd7DjkeBJQPhK8nu+DiWnNn7ALgDEQi70w+WYdI0zKrmOgbNVVp/09ToZbmzV e6BMNe8JO7/c1NEGIGFTpA3vonWweXTB8uV9KpsxCcqRWB0SuOcjp79KG8PUPg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464339; a=rsa-sha256; cv=none; b=H2a3fW9lmUEnzgLwtKWrV+X1mjvOD6kRYgX1C/o6zBE3CE10PphkS7+hdKrmTs7OCPWjTc eaat2xIRyhSkF3gxiDt18euGJBweeVYJUMrcD9jNKA3bANOUqj50l67ODv38CXbk4Abgt+ dhpIDpQ03VkM6vbNOIk0pQqucCun2uoGrpPF91W6ULRAztsxvpkWNG6JvnZxo8zY2bgOzB AeNI8NfoUXUmnI5NwGy+NkU7H/N0z3vr9K+vuGRV9dkijMjfkjfdEpkfiKZHQd0ecFko/r s3moBxF9G1ozpqc4e3g6hfSyvJtPVoOE56n6169ElS1mx03YBWXNQEzqEvdQNg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464339; 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=ENojOBW5cI4DEBWCscZmfgTEu2XP3h1Vn+Dv316kD+4=; b=Mai1thud65Q4Q7Ya96IaFnxIgHkqhUZDuqhy0AvAx2PKlFL45xN/1IUMwUlw/aeyUxzAjk 0gjoZ6/gYGanILrcBb+M/EfPqURdweIQiP+Auw7pdS3S7OxxUoozcvxiuIp2XhjB7LztJ+ p1VfhC7wUZ3W3KqhY98NvTHpWLClz0nrlACl6v3Zn7X39cjktYeTygfxxKij2NogBoiMGw CDLHrwFXB51kip/7sJeIW8ovDF6tVm1b5UPBx2tRbRZY5RDoKmjwb1JsBtlNuQLUdU9LQZ Z/+5DShudvxMfPoX51lox3lgeYfpUPJ+g+qGFWitT9Iw+PIYVT0BSPOZSRuSOA== 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 4VL5dH5bBqzKk5; Thu, 18 Apr 2024 18:18:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIIxAD017418; Thu, 18 Apr 2024 18:18:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIIxLi017413; Thu, 18 Apr 2024 18:18:59 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:18:59 GMT Message-Id: <202404181818.43IIIxLi017413@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 5f375fdbdfdb - stable/14 - em.4: add interfaces to name section List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5f375fdbdfdb8ca48cf668069d4259dc7d48e4a6 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=5f375fdbdfdb8ca48cf668069d4259dc7d48e4a6 commit 5f375fdbdfdb8ca48cf668069d4259dc7d48e4a6 Author: Alexander Ziaee AuthorDate: 2024-03-20 17:15:51 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:16:56 +0000 em.4: add interfaces to name section Improving first-glance comprehension that this manual page applies to igb/lem interfaces provided by the em(4) driver. While here, tag SPDX, link the framework, and shuffle a sentence to fix linter warning. Co-authored-by: mhorne Reviewed by: mhorne MFC after: 1 week Pull Request: https://github.com/freebsd/freebsd-src/pull/1134 (cherry picked from commit 501f7e7bf847c66e3869b533805e76897e4685b9) --- share/man/man4/em.4 | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) diff --git a/share/man/man4/em.4 b/share/man/man4/em.4 index 13bbfbf148bc..0e9c08560545 100644 --- a/share/man/man4/em.4 +++ b/share/man/man4/em.4 @@ -1,3 +1,6 @@ +.\"- +.\" SPDX-License-Identifier: BSD-3-Clause +.\" .\" Copyright (c) 2001-2003, Intel Corporation .\" All rights reserved. .\" @@ -29,11 +32,13 @@ .\" .\" * Other names and brands may be claimed as the property of others. .\" -.Dd August 3, 2023 +.Dd March 20, 2024 .Dt EM 4 .Os .Sh NAME -.Nm em +.Nm em , +.Nm lem , +.Nm igb .Nd "Intel(R) PRO/1000 Gigabit Ethernet adapter driver" .Sh SYNOPSIS To compile this driver into the kernel, @@ -72,9 +77,9 @@ Controller Hub (ICH) and Platform Controller Hub (PCH) including Intel The .Nm driver provides support for PCI Express Gigabit Ethernet adapters -based on the Intel 82575, 82576, 82580, i210, i211, and i35x. These -appear as -.Cm igb +based on the Intel 82575, 82576, 82580, i210, i211, and i35x. +These appear as +.Nm igb interfaces to maintain compatibility with existing infrastructure. .Pp The driver supports Transmit/Receive checksum offload and Jumbo Frames @@ -319,7 +324,12 @@ The device driver first appeared in .Fx 4.4 . .Nm -was merged with the lem and igb device driver and converted to the iflib +was merged with the +.Nm lem +and +.Nm igb +device drivers and converted to the +.Xr iflib 4 framework in .Fx 12.0 . .Sh AUTHORS @@ -328,7 +338,11 @@ The .Nm driver was originally written by .An Intel Corporation Aq Mt freebsd@intel.com . -It was merged with igb driver and converted to the iflib framework by +It was merged with the +.Nm igb +driver and converted to the +.Xr iflib 4 +framework by .An Matthew Macy Aq Mt mmacy@mattmacy.io and .An Sean Bruno Aq Mt sbruno@FreeBSD.org . From nobody Thu Apr 18 18:19:00 2024 X-Original-To: dev-commits-src-branches@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 4VL5dK18K2z5HKyD; Thu, 18 Apr 2024 18:19:01 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dJ70B3z41s8; Thu, 18 Apr 2024 18:19:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464341; 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=IwvBS3fnxYu2ttv8Yl62wSh2eMEE15ATcGkc3bGL1oM=; b=u4eGYGiXq3DRYYQ63lz44vbbRfnPXcEXlIspUlxctnTvaum05FNfHoPh1399qMSgSzcwni C/kkAqozSHywd6rBZs2hApWX31BAlOijsZhahbbLFAoZgP4/s6dWot7AYPi8QylTi8V+qK 7DDXGvZ1XVw/jvPfHx+/CdWfbS7pZFXSA4kAFGFiSgw9Lcwhr1kodCaRInQnmjWiKmqOYR rJXh3qo1rPenDTBv4kcfwXtfLnwrDTnCGr0KqTmCBfrXi/0o5yT9CMXAD9Bw16exJpFNV+ bVL+eUbK58970yiLMseS5KVTrnx1glObPNeLw14MFo+M5/wPl6IZxZvoSndhmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464341; a=rsa-sha256; cv=none; b=Xi9fmbSFKgtsXd8v1c8SYXdtx42/OUWuuo+jW54nbaMJx74aT5PzQpgkFS8l98G1r0zNnP dH067aiswpPHPPLTjAAp9b5HalJLuKjgdopYaJahz/niJJat/ju0DhpMrTRTAYcNlvQrZO 1nhB7Xi2y/HHBGRRWA8/2jCt2WYL2879pN4U07H4bUJG1jijK2oUwvP2gOsFoYYSfZrre/ DHbKTZAVi0poWHM8JUmuJm9Ov61/R+FMhaqBAD4ErZl8MB/jbemA+AMtan5ZgVpDnd9QqL kUVBPwhP3womH1DT7hMZP/mIf28P/pz8Jk4gQlUV/15n7ycMWqpPPhs69VicDg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464341; 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=IwvBS3fnxYu2ttv8Yl62wSh2eMEE15ATcGkc3bGL1oM=; b=aCgq/9KDJRlQ7aD1UtUM/7POdUA2zj5rrmfTADOX+92TkvhsDKQtOMkMC0ubXfj3O1b+Ls LEhc1gSsyPetMrFba6So9ELqmrQdsY/qNFhbsgQAsNLBUSYuSbkGErskPc4GQxTYhq+10U 3codldZm7/wIrWfHj2AQiILvIr+kAx7kqvxicHaHp+rlEWhYxRMez3+JuD0yj3E8Spuh8x rTLuryz76sg7a9pnqyzayCCFrDgNyaeMUnZSk9mZDYtzS3FbhKT11OepW0eea0FzCJw077 Lz/9YpPI45AK/nBNuQ1V41DyyP2xVk/R9ksb26F+v+aovPvmnyw+F4ZPkn7i8w== 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 4VL5dJ6btyzKxp; Thu, 18 Apr 2024 18:19:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ0Pw017473; Thu, 18 Apr 2024 18:19:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ0to017470; Thu, 18 Apr 2024 18:19:00 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:00 GMT Message-Id: <202404181819.43IIJ0to017470@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 74b1a9ccf9a7 - stable/14 - cp: Remove useless ssize_t cast List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 74b1a9ccf9a7eab1d4c4c0e4ffc2e901bc040e48 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=74b1a9ccf9a7eab1d4c4c0e4ffc2e901bc040e48 commit 74b1a9ccf9a7eab1d4c4c0e4ffc2e901bc040e48 Author: Collin Funk AuthorDate: 2024-02-13 02:52:58 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:16:57 +0000 cp: Remove useless ssize_t cast Both wcount and wresid are ssize_t so this cast is not needed. Just remove it so the code is easier to read. Signed-off-by: Collin Funk Reviewed by: emaste, zlei Pull Request: https://github.com/freebsd/freebsd-src/pull/1116 (cherry picked from commit 8b864151856fbba97fed16b1200248cf9f6f3ccf) --- bin/cp/utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/cp/utils.c b/bin/cp/utils.c index 0bb5157e3f57..353d35214844 100644 --- a/bin/cp/utils.c +++ b/bin/cp/utils.c @@ -97,7 +97,7 @@ copy_fallback(int from_fd, int to_fd) wcount = write(to_fd, bufp, wresid); if (wcount <= 0) break; - if (wcount >= (ssize_t)wresid) + if (wcount >= wresid) break; } return (wcount < 0 ? wcount : rcount); From nobody Thu Apr 18 18:19:01 2024 X-Original-To: dev-commits-src-branches@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 4VL5dL3bp9z5HKqy; Thu, 18 Apr 2024 18:19:02 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dL16H4z4237; Thu, 18 Apr 2024 18:19:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464342; 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=2ipSIoL0WULuyGDyZKMOUCwl8dzBudK/Zo6HIe+wpD4=; b=F3YjNWNCnma1fw4kgT5cvlfFBlfEfSiw8NhYcgP1wVQcSwsrvgMFtjKNphLzKvxNKuK6kF sS8wzjJPerJ3QrdkyUQm7avolfrQUpSOs/hUPjZ4jCeoE5HeJwRc1d4Vc8mHVL38kTqh8d zd1t96L/Vo2X3J3tkfpHwi+SsMmGrhaE1KjinexjIJOOB/GAeDxVxMWI01OZNUqOBTY/r6 GzgFkiSIm0VlP/8InlJ61BgYg/+Z5mCV4j6UebMZWD4HPuRc23AzNxYgPa3+zz8dEdGIwZ a7i+t0SFLl4PnRQ3uAw10DOvzZv/J9Ixpk7rkzpDf5BzZogpQUXgsocwPxQa4A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464342; a=rsa-sha256; cv=none; b=yxbGiWA3jlBLzke/njo900hEEAWzY0yjhvOZ4dE6Q47h2CvJLSSanniz9QqRCKdi6Uqr6J Hf6xd1XAOsLMIWD3ZxcR/cYGcm2JcGjNN1xCM7Yy16TRp7x4IzPKur/Xsi6m7l1UrpDoY8 49mdoSZw1yY5lIJz5Xi6HzmNBAH7+8jcfMTgssv9j7ESNrm2Jmi2dXuM/tBFO/yRI/Ln2r qln7nHdOeyahUneHws+ztHC2uHhymDU+6jkkn8v/6/bi4mDtZmo5exqcKOPGcV2Ry/7qol OtNTYIl9nuO3p+qmRTa+Sm+11sze8+UUYWqDwQluO1TXghbKhibanLvxqe2Gww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464342; 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=2ipSIoL0WULuyGDyZKMOUCwl8dzBudK/Zo6HIe+wpD4=; b=CbRL0segKDlDgy4lGHoLqwFcs+OU/8ptzHkE3qVeLBYnQQuMbHMltW+QMTldekYn5OUpc7 Rx+YCW7do5IEgfZ7xqMHDyp4wMM6c6yBHVw8Dx5YvjFxqYwjJWKL8mzKiuL5dYTXgX76Qp SN4rAKAzcxMm1IStcSNqTjELg1zf11G5os1aZxRS6mNjB6sO/pQOYjGZ47Z/17FqMxFXIs Dxi2dxaCzm2tDoUjzK0LfE6Z+yTDd/QKfvvrrluruyzpdMwklTqARzXEXxkZaRzVRYkdgf C6ScG7vEzMDFOCcU5NcaqjPBPcYhxtRd/aQqI67udqK8/D8x/aGsjbl9V5ulAA== 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 4VL5dL0W9XzKk6; Thu, 18 Apr 2024 18:19:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ1ht017515; Thu, 18 Apr 2024 18:19:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ12S017512; Thu, 18 Apr 2024 18:19:01 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:01 GMT Message-Id: <202404181819.43IIJ12S017512@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 929d8ef0f71e - stable/14 - KASSERT(9): add assertion message guidelines List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 929d8ef0f71e347ab5921179f2efecb53565c5bd Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=929d8ef0f71e347ab5921179f2efecb53565c5bd commit 929d8ef0f71e347ab5921179f2efecb53565c5bd Author: Mitchell Horne AuthorDate: 2024-03-21 14:54:49 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:17:52 +0000 KASSERT(9): add assertion message guidelines Add some text describing how to create useful assertion messages. Improve and add to the EXAMPLES. See the discussion prompting this on -hackers: https://mail-archive.freebsd.org/cgi/mid.cgi?57o4rnnq-013s-3nsn-59n5-4ssn1pq81s94 Reviewed by: emaste Discussed with: imp, bz MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44434 (cherry picked from commit 83a426d13a6a384e63e75d8252c03dd40af3817e) --- share/man/man9/KASSERT.9 | 72 ++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 67 insertions(+), 5 deletions(-) diff --git a/share/man/man9/KASSERT.9 b/share/man/man9/KASSERT.9 index 1d28ce80c9fb..8d9dd98014a8 100644 --- a/share/man/man9/KASSERT.9 +++ b/share/man/man9/KASSERT.9 @@ -2,7 +2,7 @@ .\" .\" Copyright (c) 2000 Jonathan M. Bresler .\" All rights reserved. -.\" Copyright (c) 2023 The FreeBSD Foundation +.\" Copyright (c) 2023-2024 The FreeBSD Foundation .\" .\" Portions of this documentation were written by Mitchell Horne .\" under sponsorship from the FreeBSD Foundation. @@ -29,7 +29,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd March 16, 2023 +.Dd March 19, 2024 .Dt KASSERT 9 .Os .Sh NAME @@ -93,8 +93,37 @@ The macro (read as: "must-pass") is a convenience wrapper around .Fn KASSERT -that automatically generates a sensible assertion message including file and -line information. +that automatically generates a simple assertion message including file and line +information. +.Ss Assertion Guidelines +When adding new assertions, keep in mind their primary purpose: to aid in +identifying and debugging of complex error conditions. +.Pp +The panic messages resulting from assertion failures should be useful without +the resulting kernel dump; the message may be included in a bug report, and +should contain the relevant information needed to discern how the assertion was +violated. +This is especially important when the error condition is difficult or +impossible for the developer to reproduce locally. +.Pp +Therefore, assertions should adhere to the following guidelines: +.Bl -enum +.It +Whenever possible, the value of a runtime variable checked by an assertion +condition should appear in its message. +.It +Unrelated conditions must appear in separate assertions. +.It +Multiple related conditions should be distinguishable (e.g. by value), or split +into separate assertions. +.It +When in doubt, print more information, not less. +.El +.Pp +Combined, this gives greater clarity into the exact cause of an assertion +panic; see +.Sx EXAMPLES +below. .Sh EXAMPLES A hypothetical .Vt struct foo @@ -106,11 +135,19 @@ foo_dealloc(struct foo *fp) { KASSERT((fp->foo_flags & FOO_ACTIVE) == 0, - ("%s: fp %p is still active", __func__, fp)); + ("%s: fp %p is still active, flags=%x", __func__, fp, + fp->foo_flags)); ... } .Ed .Pp +This assertion provides the full flag set for the object, as well as the memory +pointer, which may be used by a debugger to examine the object in detail +.Po +for example with a 'show foo' command in +.Xr ddb 4 +.Pc . +.Pp The assertion .Bd -literal -offset indent MPASS(td == curthread); @@ -121,6 +158,31 @@ message: .Bd -literal -offset indent panic: Assertion td == curthread failed at foo.c:87 .Ed +.Pp +This is a simple condition, and the message provides enough information to +investigate the failure. +.Pp +The assertion +.Bd -literal -offset indent +MPASS(td == curthread && (sz >= SIZE_MIN && sz <= SIZE_MAX)); +.Ed +.Pp +is +.Em NOT +useful enough. +The message doesn't indicate which part of the assertion was violated, nor +does it report the value of +.Dv sz , +which may be critical to understanding +.Em why +the assertion failed. +.Pp +According to the guidelines above, this would be correctly expressed as: +.Bd -literal -offset indent +MPASS(td == curthread); +KASSERT(sz >= SIZE_MIN && sz <= SIZE_MAX, + ("invalid size argument: %u", sz)); +.Ed .Sh SEE ALSO .Xr panic 9 .Sh AUTHORS From nobody Thu Apr 18 18:19:03 2024 X-Original-To: dev-commits-src-branches@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 4VL5dM3fXBz5HL4h; Thu, 18 Apr 2024 18:19:03 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dM1rrZz41sb; Thu, 18 Apr 2024 18:19:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464343; 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=n4I7IUkzY2p9Z8nqL5ZRLkyz4XDAzhTsOdFu8f8l0AY=; b=dJMd3yzmy6S1xWST5jEoneSRcBskBUk++Zng9tj7SYx/Y7/LvmZqX/VleGaANZdydrvkbE 2kuy4nidt4r/8fSTmj4IXhxjr+sbJ8zf+QHiTa/bjbKZsvHibr8T7B9vgF+ATyJ2W8ueaO B5FJkB7ERcVPFVFR8hVG/7pHLhnF9C0+gGeR5QMJ/RidUKixY7IPcssvDt4g26f40NYRMi ho8E9bCG8TvAvKly+qvANfXZMBvTLGi+cFsN8nst9WBZoi76sOWK1YfFrUy1lqT1qxo3cK ryvSkb6dxZxDKC+CFxaLl2+gIh2mREjNFMokx1XZ1golZyY9+zbcT86lwLo+9A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464343; a=rsa-sha256; cv=none; b=WXOwnFvRodITNd4r/g5Lg16uLn4F1X9aE7/zsiXTVsAvxb+exJoZRdlU0NYwcqfpSxyn/+ YBA02bwawSHsxNCToK+rRBgOkgHI8WXBsuW17elZVYxYnk1RR+lQqm57kSee37WK5LJ3tp LM34GsTAn6XjJ3cnjfEgq3ijDB+fqeMXVYzGR5oPb0N5GU/d/HUznm2Fuiv2Af/nlP7jdC VKpmIYnh6vJL1mDGDgfjKkhBpUNuDrMFzom01g9an9tIdfbdjlYSfxKqb9rXAFszv6DKdy CFAIglnHfj23AqgSBm0dnqj94JesUVEzp+KtDLCED9jl9+dg+/3ealKpcqRKpw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464343; 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=n4I7IUkzY2p9Z8nqL5ZRLkyz4XDAzhTsOdFu8f8l0AY=; b=Dbqf6M6ycU1V4zRdr8IZbBGh0nc1cocxz/8uixjAASf3Cpbq9s3BQXJBkrni0oE/AOnAx7 5Tll0UnLt+/yZ4cDah1b9NdAVlnoj6PqKW+0IDwh/Ox8S19FhgyApkSnEKLtZ915/dh+cx /R95cyTiCX8PMVw7lfMEgsUoBU37HKsTvkvNwaXa5EM57nVQLUTSJTn2cd+yLnZHof7yB+ DihH3HwjmutwWmUFsVnyQddV1VW/sRIWkUtEU1ffFFeM3mTnq4sWNWeU2FaATqRRqi0TmX C3JdLYFDA9zjpP9LEWhtiYgKIiCor2tyc5xGTPDRvv6Ga3VXE1IrOC6NFBtNfA== 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 4VL5dM1FDczKP1; Thu, 18 Apr 2024 18:19:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ3Wf017557; Thu, 18 Apr 2024 18:19:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ3Uq017554; Thu, 18 Apr 2024 18:19:03 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:03 GMT Message-Id: <202404181819.43IIJ3Uq017554@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: e9d06e89ce63 - stable/14 - KASSERT(9): describe history of MPASS List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e9d06e89ce638ba9b82c37567da29102f8ef0201 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=e9d06e89ce638ba9b82c37567da29102f8ef0201 commit e9d06e89ce638ba9b82c37567da29102f8ef0201 Author: Mitchell Horne AuthorDate: 2024-03-21 15:21:04 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:17:52 +0000 KASSERT(9): describe history of MPASS The macro originates from BSD/OS, with a different etymology than what is presented. Add a brief HISTORY section to capture this. Reviewed by: emaste MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44439 (cherry picked from commit 5d956e11ed3713ff769d51b71f7b4ee6ce0085fe) --- share/man/man9/KASSERT.9 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/share/man/man9/KASSERT.9 b/share/man/man9/KASSERT.9 index 8d9dd98014a8..bab8efe5cfac 100644 --- a/share/man/man9/KASSERT.9 +++ b/share/man/man9/KASSERT.9 @@ -183,6 +183,15 @@ MPASS(td == curthread); KASSERT(sz >= SIZE_MIN && sz <= SIZE_MAX, ("invalid size argument: %u", sz)); .Ed +.Sh HISTORY +The +.Nm MPASS +macro first appeared in +.Bsx +and was imported into +.Fx 5.0 . +The name originates as an acronym of "multi-processor assert", but has evolved +to mean "must pass", or "must-pass assert". .Sh SEE ALSO .Xr panic 9 .Sh AUTHORS From nobody Thu Apr 18 18:19:04 2024 X-Original-To: dev-commits-src-branches@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 4VL5dN3mMvz5HKwH; Thu, 18 Apr 2024 18:19:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dN2drTz427t; Thu, 18 Apr 2024 18:19:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464344; 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=rYuBPVxMcONnBbBuOdrN6fh9RYMehXTLS9wznk5Hygk=; b=lFj+iJ1gtaEnxb6bKpJuEiqScy4gESXgxVJdue8x5EcpVz1qY4hAKzTanzQS/4KU3R5TtJ X/QQAUwU7qixBQbgkwAbQdbSVPWHJndhcg0LFCPG8cawnlwOuUVrVVuaPfHJ+bBQZ7NsKI uGa6EcBnZ1RtuKRJ27T2SeBQ9Rh45WvUTCRx0UzPODAwDvo/cBidikaeaAP1xme1zqvqo8 vBr7xELMRBhLQVbXkvpRvT6sVsNuji8pnkL/3vt8wbVgsMcK1wFYFp9zvGodbMCk7tFbMO ZMKZfF/Ba6K+nbClw4CCcpLrIZjf9iM2cv0We3m235XpHl5amhmaIdBPXwfaqA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464344; a=rsa-sha256; cv=none; b=pEVe3uP3cpKxqlYubn/M0vMxyr5zl8R10gIJ5hbXdmbhPN+16hDszdr/keuAqTdPS1qtHv TIa4Y+GePDapwHBOuxU0q9uHTw8F4ZzUzv9tL1tVYYypMTpvsSwvaxuidEBu1xMqegal4w 3Dpe2znDgfQ4z+jQMilslYfitU+OJd36GR3gwdwe93nauRPN3j8h9XMw7Ek2CIrXRlg7DR J02HEK4xtdwwmjkx+DSO7n6Fy7hsiySybzcQdJJD2iupSUFbMeEBLjOY4AFmf4SJIUVivU 8b37Y1Kmh+rXksrnwmMbtawk0HWfo0qcpf/Hg8oL79Z4dJvh4h+q1rkYgIHLlQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464344; 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=rYuBPVxMcONnBbBuOdrN6fh9RYMehXTLS9wznk5Hygk=; b=cQ5+gQ9BnQuNPSdrvL9h7yXVGYB+B4gNdRVsqyqmJ6Ctq6fp5v0r+FeZEt79A0Lh4UWu8I WiBTmhaxaCGbTb4vodvxor9ziK+BYMZqre5EvbdCJ0obCjPd+ouqmMs0MUFibl0d8PqSXm rBjph9FBkGiV++gAox0T0skSWw+BNA8vuVKW234tehx2nFLdZbPa9mI+MJtzweZbOuxrqa +i5mxhsI/kSQkT0ZpDz7TVFWvDq2bO/yrKuAO5f5w7WJg/R/ytOvLhBXYlCcaUH5WX6T23 e1A1hgUhsxlaPVcRWuHOBJJypkiGRyJwN9FEJIS7PTqPRO4EfUAKUuwVpFkkxg== 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 4VL5dN2GGyzJxg; Thu, 18 Apr 2024 18:19:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ4iJ017602; Thu, 18 Apr 2024 18:19:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ4Ms017599; Thu, 18 Apr 2024 18:19:04 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:04 GMT Message-Id: <202404181819.43IIJ4Ms017599@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 0c62a06b84ab - stable/14 - kassert.h: update MPASS definition commentary List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0c62a06b84abde27e170d783b1c8cce3402831ca Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=0c62a06b84abde27e170d783b1c8cce3402831ca commit 0c62a06b84abde27e170d783b1c8cce3402831ca Author: Mitchell Horne AuthorDate: 2024-03-21 15:21:41 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:17:52 +0000 kassert.h: update MPASS definition commentary We now have a detailed man page describing both MPASS and KASSERT. Give a warning that careless use of MPASS can result in inadequate assertion messages, and point to the MPASS(9) page which describes this. While here add a comment above the KASSERT definitions pointing to the man page. Suggested by: bz Reviewed by: emaste MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D44438 (cherry picked from commit 36de8bb226671ef9fe373d8d95f77cdb76157738) --- sys/sys/kassert.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/sys/kassert.h b/sys/sys/kassert.h index da7b66854a14..8e22e0e2c9f9 100644 --- a/sys/sys/kassert.h +++ b/sys/sys/kassert.h @@ -112,6 +112,9 @@ void kassert_panic(const char *fmt, ...) __printflike(1, 2); # endif /* defined(WITNESS) || defined(INVARIANT_SUPPORT) */ #endif /* _STANDALONE */ +/* + * Kernel assertion; see KASSERT(9) for details. + */ #if (defined(_KERNEL) && defined(INVARIANTS)) || defined(_STANDALONE) #define KASSERT(exp,msg) do { \ if (__predict_false(!(exp))) \ @@ -124,8 +127,11 @@ void kassert_panic(const char *fmt, ...) __printflike(1, 2); #ifdef _KERNEL /* - * Helpful macros for quickly coming up with assertions with informative - * panic messages. + * Macros for generating panic messages based on the exact condition text. + * + * NOTE: Use these with care, as the resulting message might omit key + * information required to understand the assertion failure. Consult the + * MPASS(9) man page for guidance. */ #define MPASS(ex) MPASS4(ex, #ex, __FILE__, __LINE__) #define MPASS2(ex, what) MPASS4(ex, what, __FILE__, __LINE__) From nobody Thu Apr 18 18:19:05 2024 X-Original-To: dev-commits-src-branches@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 4VL5dQ0HwWz5HKwJ; Thu, 18 Apr 2024 18:19:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dP40CJz4262; Thu, 18 Apr 2024 18:19:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464345; 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=5PSFBh/DVm7OjEQQDtqYBoQvvL9MQFsSjXnGfpwXQ0o=; b=BGJHqZy7N38GC7OiAPvMSQH+wgInh5SYE3mhcHUUJBil6iCST39S7SsJBahhoNYzxX2BWH wXcvPJaBPl7DvHosqTCFxOhilSIZUMX4f+AVcZNTYQn7SxoTA9kmgA7royeOFaImWpKtFM +p23y2L4uK/wKXBM7bxBi1JpGfROJXAzx46tTOw9lNPrstwGGcwyjJwc3oBwRv7yEelWhs 7CzMtMxWK7NIzXwKglyWwfa4Xhxq8IJGn497wJG3ge4ClrTseuIM5uM1OhiLHAO8OH5jD8 sl7GapFqsIEoSogHA3Ty08QrA/ZhRhttJddLudVGYa7ci6qlOSTvUvgp5UZljg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464345; a=rsa-sha256; cv=none; b=mI11UTOORaKAIKEd/32DyJcImfnAd3xrIKGxIRpxTmYCZTlgdm59J3kuSdKo/icSVxOM8A u2rc/tDE9FPSYZZtPeuqVuKL/+r517D2JYu7+TlziETm4loKaa7t7f6nsrYchK0GUGjMGo rF7QgYlYKx6BlxhNARxluGYI4KCaePnUzkKVaiZCVxRhSEkJmDFjmVXH/fJoA0fivZHFKf 3sHXG2xPpROhqhoV5+LoKyUsz5Mtu9M/1iQe30q5MkNpYJrmL/e1ki82ShdgkkfyFoXCR6 DfbLDgcj+owHU29QBeIysdbfJOi6nHLAyHh2X89cIr83Ljq3PGJUeJjplDmjPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464345; 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=5PSFBh/DVm7OjEQQDtqYBoQvvL9MQFsSjXnGfpwXQ0o=; b=V7QSkPQp9LkIK+EkpJJE+l0cGvWiAwmzq5v44OeNwS9idwaxK8U6pvkKSQJCZHXt8a/ksX LZz+M6wZ/LQ4OpM2KPMM1ZuWRN1ElF95ygR8grN+cuZ4YVjmowMYZCoqJiRVnAqupX3B+u zPhtAXpaU3w2CpjaXQ4nqom0DIkVVOukj83SOC4/fMRSLXTo8MpgrmJJsu2fGaNzSGDdP8 iWcUxXz+MLPydS3KFitZ54WHnhHkKoFzh7nQupI2tVY32Jm7K9kNUDA8nsOoHcTGznJnCp 1Ggllidj0gtdOjcpwwvKsqwWe17AivFbnMkju8gQGyLamQ/3d20ubh8tZ5pHiw== 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 4VL5dP3ctQzL1P; Thu, 18 Apr 2024 18:19:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ59Y017659; Thu, 18 Apr 2024 18:19:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ5GC017655; Thu, 18 Apr 2024 18:19:05 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:05 GMT Message-Id: <202404181819.43IIJ5GC017655@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: c8aac78681e5 - stable/14 - assert.3: Update manual page based on mandoc -Tlint List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c8aac78681e505908673aa2f1497035c5126c84f Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=c8aac78681e505908673aa2f1497035c5126c84f commit c8aac78681e505908673aa2f1497035c5126c84f Author: Christopher Davidson AuthorDate: 2024-03-05 03:39:52 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 assert.3: Update manual page based on mandoc -Tlint Execute the mandoc -Tlint option on assert(3). This results in two areas of updates: Remove invalid Rs block Remove invalid Re block Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1132 (cherry picked from commit 3f72f36cf2f92e00a248f729d50803232ff4cef8) --- share/man/man3/assert.3 | 4 ---- 1 file changed, 4 deletions(-) diff --git a/share/man/man3/assert.3 b/share/man/man3/assert.3 index 5d29f242ae45..9ec0aed9ec1c 100644 --- a/share/man/man3/assert.3 +++ b/share/man/man3/assert.3 @@ -122,19 +122,15 @@ If none is provided, it only points at the constraint. .Xr abort2 2 , .Xr abort 3 .Sh STANDARDS -.Rs The .Fn assert macro conforms to .St -isoC-99 . -.Re .Pp -.Rs The .Fn static_assert macro conforms to .St -isoC-2011 . -.Re .Sh HISTORY An .Nm From nobody Thu Apr 18 18:19:06 2024 X-Original-To: dev-commits-src-branches@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 4VL5dQ6PSSz5HKwL; Thu, 18 Apr 2024 18:19:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dQ4nw7z41yd; Thu, 18 Apr 2024 18:19:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464346; 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=XjJ2gCgJ7aACaXolF0H9JfNFeXuGH9cdlWgYrYA3Uqw=; b=Fe4kfn+OSDKyAnNxIAaSnv7RG7EOpR8ZQtnQAhkJOatliEC58QFQ72QpKHL+0Bl+ou/stk jEGw/fy1Ve6fbAbujQ8c/GvwbQR8T8eCgfcRDSlsMq+1rqEM72wiXgpOGYHS8uehnUWCZD l8uIQzhgarCrGgalwI92o+107b1RAzmbdBtDxsGd2KQ0t3QQjWazUhMxxzHu69B2BmosZY 94Zgri7XsESHiKGjis+gUcm5y9ge9xjqnNnmTwlEgEyWWM73KMwoaLv9hBw1Ps6G5k0I9w JO1z3x03v3WiGfYIrAhuBniVH28NG5wDJxZeg3sGRpfEuyYROcl5QnLnuI+wJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464346; a=rsa-sha256; cv=none; b=twafF41N9qeytmdLw2d0ZqTZSZ6gPw/TEKJlEQVoSz/7zD4MREDoYQYQnslvxouiRw8Vby bvQ8QNlxDiJaHgoVN8idt51/wP5350pl9S9WWQj+8dpyphwHan2frBUA803jhE9YsrSxlN VplbkjPLJL6nTcj/ZZmuGvEi52VAw8/PjiFTT5m5pyPqFfg6qEWbPlI5pTOlmgXSY4GdA0 sAoEIBsOGeQJu4u+9u/fljhDM0BLvwyqmgBc1cOjBLWPuloNAnv9HFEggNfI4lmFTrN11y TewO+jqRN7md5C1LvvJiE0x0FMaPIAFZ/MTv0n3QHnNinw8Ix8CxN1EshgzRLg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464346; 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=XjJ2gCgJ7aACaXolF0H9JfNFeXuGH9cdlWgYrYA3Uqw=; b=c3sDd/8HB+MWECY/zu/k9OzSpTu4G+8/Kf5GexaMa/gY1tX2fpcU53pus4kFHte+Qt6UXC 20dzbNIgMKUMVoPBQsFdP4jAz+WTX46YGh0fNHja+Tag3Ie2z6hS0zlI1YguDLfyDFpkns BWSBOu7ZxI7E+031noZAKI1LfdD5bhpGNM352Ln+elPSE63n3mi9KDY8Lytqou0/r8Km4T vzXXJgQfOSyTgIhqqDUHdbyqhqBGWGcVaYRQ0w54EXgQx5b6DbyA80qq0klh5A7k5lKDNL Xu3DtyzY+eYhj1Nl5gYV7WF8kNUqwbtX0bE6VIn2UAo6xV+/E7d7sPPow8mayA== 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 4VL5dQ4PNZzKk7; Thu, 18 Apr 2024 18:19:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ627017709; Thu, 18 Apr 2024 18:19:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ6aG017706; Thu, 18 Apr 2024 18:19:06 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:06 GMT Message-Id: <202404181819.43IIJ6aG017706@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: ac4ddd8b1f67 - stable/14 - open.2: remove self-reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ac4ddd8b1f67f378330cc3bcc66ccdbdd5aa34e2 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=ac4ddd8b1f67f378330cc3bcc66ccdbdd5aa34e2 commit ac4ddd8b1f67f378330cc3bcc66ccdbdd5aa34e2 Author: Christopher Davidson AuthorDate: 2024-04-03 16:38:41 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 open.2: remove self-reference Change .Xr reference to .Fn, which quiets a mandoc warning. Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1135 (cherry picked from commit d3de1bd429bc51fbbcb37fadaf2581461edf848b) --- lib/libc/sys/open.2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libc/sys/open.2 b/lib/libc/sys/open.2 index 383dd58b2a31..aac3ef1318f8 100644 --- a/lib/libc/sys/open.2 +++ b/lib/libc/sys/open.2 @@ -323,7 +323,7 @@ by the descriptor at the time of the call. .Pp .Dv O_PATH returns a file descriptor that can be used as a directory file descriptor for -.Xr openat 2 +.Fn openat and other system calls taking a file descriptor argument, like .Xr fstatat 2 and others. From nobody Thu Apr 18 18:19:07 2024 X-Original-To: dev-commits-src-branches@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 4VL5dS2Rktz5HKwM; Thu, 18 Apr 2024 18:19:08 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dR5m0Tz421w; Thu, 18 Apr 2024 18:19:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464347; 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=RX2q85wde+3TPQ8HIt3lwkJXvaHb+HIkbhmIvZGxLKU=; b=br/FW2/QF9gMEtbCIjiw3P3KKsAIbkUhalqyQV+e4Is0XVk1aM4NT+NV0jNq/UuMPZkPkh Y/YVkwnVjk/KDAs2GKxYzLSn8CKMHukQrwv7w8uD+A0F9U7nawzEr3U6h8R7gkzPNDt0Bf ySYbcXD+M4koTinncSnkTOBt0NksJyoF9pPeuJkHLVJUL5JE7n99kSaFGp1DpUjW4VpOt8 t2h7gazggLmhHSFToNvhdITqv7cDSxnSzCWkisYunkyCE8qyZT6Hm/1pBbL0EkSGIiPhAt tkrWPRyFMohVCqV6thC8wPKA1ugvCmz+rYkM2GOyP2tIScWrPmZpXBu3Miq0cA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464347; a=rsa-sha256; cv=none; b=PUWledl0Q/DNenehjd5hTVxyq+vHKB2ed3y5bQmLvWA1Et4kxLxC7Lxd3bjjmwAcPIyOsd GuXT2XcFhhQl4geTv6hjL39mJ3H+vArDu/yf3kPyLA4H0ItPBWIkikqcpUoscVRZoAoRmG co6UEvDU9FAcVXmqGjWKI2OAXlE32Kht3vzpj9/oTbqYvEzFjkT+Msq2voTL7K6+fM2azU BeoKG3VjzWudKXOut4nnsQM/+HGuzSQWoJGsOe4J7h3M79V+uEkR1nI2g17ghevZcHrtAj trt0bCNO2yFquTUY2ARE3/fH9UT7W7ejafa1ESV03h7uwFCvJuV97VtcZsthUw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464347; 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=RX2q85wde+3TPQ8HIt3lwkJXvaHb+HIkbhmIvZGxLKU=; b=mDvQAJXDZcegDOaLADFeck3E8u5Bl5kNdJ0xhT8ndjK2I520DUbtnWXXGJ04WvXZIuWQuc /MiPU1WSLoJLTiRgHh57gDjeP1k2ByWA87mXSyb+7ElwHsgtmZGbYbrgCr0XrIjZ2Rj8u0 AjUtzqwTnjStzDiUU81/A7YCrt5pcf2ynctAPsNBIYa+t0vMoXTRzFwbVckdAziuKg9Zje nlU51ORX5SRvwBJNKMps9YuoW1YXqKezCZCk/HLRPHY5B9OIdYJpE90FGBLHHtoQyKn7/6 7obKYsobVEElhtbunSCV2LWn5Y/GE89+NhXnDdCDmlgu4M4N+CsiLYow5tUCOw== 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 4VL5dR5MZQzKP2; Thu, 18 Apr 2024 18:19:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ7WZ017745; Thu, 18 Apr 2024 18:19:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ7Ln017742; Thu, 18 Apr 2024 18:19:07 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:07 GMT Message-Id: <202404181819.43IIJ7Ln017742@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 7f1fc5dbc694 - stable/14 - mount_mfs.8: remove self-reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7f1fc5dbc694d5a22f2a1e4207591809416e3c0a Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=7f1fc5dbc694d5a22f2a1e4207591809416e3c0a commit 7f1fc5dbc694d5a22f2a1e4207591809416e3c0a Author: Christopher Davidson AuthorDate: 2024-04-03 16:43:51 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 mount_mfs.8: remove self-reference Change .Xr instances to .Nm, which quiets several mandoc warnings. Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1135 (cherry picked from commit 2ebc7806a1e4f4cd82a21a123ee5078ca6c4b113) --- sbin/mdmfs/mdmfs.8 | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sbin/mdmfs/mdmfs.8 b/sbin/mdmfs/mdmfs.8 index 6824e5ccac03..50819bfee0c6 100644 --- a/sbin/mdmfs/mdmfs.8 +++ b/sbin/mdmfs/mdmfs.8 @@ -61,7 +61,7 @@ filesystem The .Nm utility is designed to be a work-alike and look-alike of the deprecated -.Xr mount_mfs 8 . +.Nm mount_mfs . The end result is essentially the same, but is accomplished in a completely different way. Based on @@ -149,7 +149,7 @@ it uses the default arguments to all the helper programs. The following options are available. Where possible, the option letter matches the one used by -.Xr mount_mfs 8 +.Nm mount_mfs for the same thing. .Bl -tag -width indent .It Fl a Ar maxcontig @@ -404,10 +404,10 @@ Mount a vnode-backed cd9660 file system using automatic device numbering: The .Nm utility, while designed to be compatible with -.Xr mount_mfs 8 , +.Nm mount_mfs , can be useful by itself. Since -.Xr mount_mfs 8 +.Nm mount_mfs had some silly defaults, a .Dq compatibility mode is provided for the case where bug-to-bug compatibility is desired. @@ -421,7 +421,7 @@ or (as returned by .Xr getprogname 3 ) . In this mode, the following behavior, as done by -.Xr mount_mfs 8 , +.Nm mount_mfs , is duplicated: .Bl -bullet -offset indent .It From nobody Thu Apr 18 18:19:08 2024 X-Original-To: dev-commits-src-branches@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 4VL5dT1m8Cz5HKtm; Thu, 18 Apr 2024 18:19:09 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dS6nSLz42FD; Thu, 18 Apr 2024 18:19:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464348; 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=/f1UadGptffcpDxjUi6dZfLlMV7UilKRXB8jtMXZH3E=; b=ndo+EA7DregwBxTMnPKhfsYnhIzf7Du156IiOUyEr+/gVXOs1R6LFaxSKyOTJ/U+nYlUiQ v5HamGYldmsalVNnKZ4eU7E/dtLpwSZwmyKUlD2jf9XX/peOyAhXwn8LV4U5aIJIjQ/xmh WaJbMyFd+bTEfeBrJ2HX9Lv0L7GXYO1/gTEqPTny68tSeTNnA7RWdJMJtRgk09McTz/BXm n3vyMgDAMnEfuu2ef3FoKwTDMeM12UUOJZqNknRjIOw9OXuJIEMEOEc+HiuoTznZALDrsg AkPa3QSL11sgm4k1i+ZsPGbqMHNk5f3O3AZgNqKL//hq2AkWsV2YleyikYOonQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464348; a=rsa-sha256; cv=none; b=uD/jnDTV6G0ofegC6mqlPwgowcHDyQbf1c0SGVHt8+KToAaBtOPkemsmJyzrFFLWIiP+25 j54BAeYKJ/A4eAc1lxG0kHWsG8xQBNcMfm7ZQ+tnV+hUPPh5igmhJug739dTImiEemCWdJ iSgUY3Jqt4NxDId0ex4St2uD472dz39OK9jh8mYpcwLzzgT7OPmrZSdaADVjBoKyy3oiWr mIszf77rpTvQDy+ljE+BYduwLuK3ZLPCUx5WPoEzxtqTtp93OUTOkhRwgjhr1n/WjruOdI 5kvxmWFOlOJfwL8B6R4+w2cM4O0Qf0c8UTZGSC+ZtNmx2nc+iDbQFnf+oh6vEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464348; 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=/f1UadGptffcpDxjUi6dZfLlMV7UilKRXB8jtMXZH3E=; b=cXhQ7vpyst1UhbTQzSUCwF5HuNzVrjRj3WTwrm3m8ydNV1OIq6pvB/AmuVFJ5WGGOQVnjB 1uwmJW57+OzFfsML3nds2mN5rAeu7eBKkQo8xOD0NZAPO1JFSPVzcIK05lGQrERB1uf/DT GIxAHCDqIqFneN2/5ad+Tx/DGHZJNGLMhO3Nrq9XV09qKWnjJL9/WubwIPs2swN7/d/+Dy MeQaxFsYYAPQEh0dgoFhWJ2uRBQfkqGRcGNfqISh4K+ROlfgTAc659N77ckEIwaJfwvrci mW4MLNrayTze84S2Bewh1pf0lHO/e8K82l7FzYpZi2ZQ86Mepx+a2KQGcaMjtA== 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 4VL5dS6MjDzKk8; Thu, 18 Apr 2024 18:19:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ8jV017781; Thu, 18 Apr 2024 18:19:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ8ks017778; Thu, 18 Apr 2024 18:19:08 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:08 GMT Message-Id: <202404181819.43IIJ8ks017778@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: ac3bd5959b82 - stable/14 - cfumass.4: remove self-reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ac3bd5959b8275490e4705b557335ff890e15b49 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=ac3bd5959b8275490e4705b557335ff890e15b49 commit ac3bd5959b8275490e4705b557335ff890e15b49 Author: Christopher Davidson AuthorDate: 2024-04-03 16:47:14 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 cfumass.4: remove self-reference Change .Xr to .Nm, which quiets a mandoc warning. Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1135 (cherry picked from commit f8ce29b63181912e01625addb47168e987d9bbed) --- share/man/man4/cfumass.4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man4/cfumass.4 b/share/man/man4/cfumass.4 index ff7225b66314..bde9b2d6a598 100644 --- a/share/man/man4/cfumass.4 +++ b/share/man/man4/cfumass.4 @@ -57,7 +57,7 @@ To use .Nm : .Bl -bullet .It -.Xr cfumass 4 +.Nm cfumass must be loaded as a module or compiled into the kernel. .It The USB Mass Storage template must be chosen by setting the From nobody Thu Apr 18 18:19:09 2024 X-Original-To: dev-commits-src-branches@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 4VL5dV2Fzmz5HL1r; Thu, 18 Apr 2024 18:19:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dV0fHmz42Ht; Thu, 18 Apr 2024 18:19:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464350; 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=W/S+/0H15Jdh90IHRiL7UI6tR/tTlhYOA714JOh76I8=; b=djLfP+y/PktApVKK1gRpVhWpQGj8ktVgC2EoXSSy+MlcYTNsQTdVen1yD94gpnoXSDrYB/ ABGZ2io0jPQ9MHO1zd2szC2GuWKtsBTOSK14h5CsC6elxatfUlOQA4wTm/qb0Ce9Bv9EZx Nf6O4RJDnzLIiuDuC2MwN/gI4atDolKJKtKJ+KlaV/VJ6b3537HXNQahbUxpfTgWwmw4qZ nP+vWeiL0fHnQ66+6TPuloWZkf6VR773fIAeLGQlZGGp6bv8NURNFxp2QM8svcY4vhnTxe YoWhgbCLfmUiCwXNMr/HGVks2UEUmyjhAUCxESHR9s3cSHF/TKoInHUgro1drw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464350; a=rsa-sha256; cv=none; b=uUBF85bcWq/mk9ZuOGIXOYecQXb7irx4YcxRDzzdg6M/L2t+ojyznA6cUj+lknoDqbizrT 8Rbz1Iv64ZS6FnNMmsCA6kH7XW9D626Z+a1196bkNy2MO4a5bbtRgqT0LA3Gt3YXjL1tqI 1BGANNGNAOGsv+vQ5jtHg+nF9yzdgLf6OT5x0IxO+kHyItJre+omyMdHE90ctGSnxUaDLD 9cyk2/55g9KIK7FBsvRoAMOGVDK8onwgJH2Haxqpw6mGDA+gsFsn2I6hdVhD/FNXzbcHPr pZF8fcFGFDY3W0ZC0N4JWmTXL/PJWTL6rwR1Xg6eDClUIXmuR6X62x/gdRN1rg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464350; 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=W/S+/0H15Jdh90IHRiL7UI6tR/tTlhYOA714JOh76I8=; b=D4L7c4OA6Z0X6a803T3tp34c0GT/++acQ3p8oFk0X2a+9pUqPS32puIOjW/ByABwDmm6BY 8KZ0S1mQ8t/VESY1Ag15SBk1bgfrLX7lNjOe0KO8alXRbYMJ1HIkdm7XitA5W+2Jt4IrqK D5l3Uzsu+3SRjKyy6DCxR7q8FSJj+DxsVCXvZzin3SZYJs6vDMlV5aSv2Mh2TU36hOT/vg 3H3AKkkKBomwlEpjO5qSadZB5W57M3xWLvL2IdexUROR3mwryuGfWkTMuLvezYv9jDVTAl JfA+Spybg1Ip4LVfgnen0lWES7BICTCq4OA9oXlJEFu6zyvD2D3Z8lbVZN3mfg== 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 4VL5dV0GlCzKtv; Thu, 18 Apr 2024 18:19:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJ9b2017817; Thu, 18 Apr 2024 18:19:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJ9CP017814; Thu, 18 Apr 2024 18:19:09 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:09 GMT Message-Id: <202404181819.43IIJ9CP017814@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: de436a4fbf79 - stable/14 - device_add_child.9: remove self-reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: de436a4fbf790c8af2f67dc4d21f5fdc4c9ae499 Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=de436a4fbf790c8af2f67dc4d21f5fdc4c9ae499 commit de436a4fbf790c8af2f67dc4d21f5fdc4c9ae499 Author: Christopher Davidson AuthorDate: 2024-04-03 16:48:40 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 device_add_child.9: remove self-reference Change .Xr to .Nm, which quiets a mandoc warning Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1135 (cherry picked from commit f9ea7b6e8253273ebb1023c4380a305e6d3cf02b) --- share/man/man9/device_add_child.9 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/share/man/man9/device_add_child.9 b/share/man/man9/device_add_child.9 index 7e97f7de4963..423869d6ff6b 100644 --- a/share/man/man9/device_add_child.9 +++ b/share/man/man9/device_add_child.9 @@ -111,10 +111,10 @@ When adding a child to another device node, such as in an identify routine, use .Xr BUS_ADD_CHILD 9 instead of -.Xr device_add_child 9 . +.Fn device_add_child . .Xr BUS_ADD_CHILD 9 will call -.Xr device_add_child 9 +.Fn device_add_child and add the proper bus-specific data to the new child. .Fn device_add_child does not call From nobody Thu Apr 18 18:19:11 2024 X-Original-To: dev-commits-src-branches@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 4VL5dW48jrz5HKyR; Thu, 18 Apr 2024 18:19:11 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL5dW1WNmz4270; Thu, 18 Apr 2024 18:19:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464351; 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=zyZrL/2HQy82s6fhLpT1JyGrhSds3QGZDo0rS69WHQI=; b=KxEHdx4qJ86IrVpVuMDLm5lLqfwOk1dK9LDgYeS+qs6+ikpLbgtdXT0BSJbIdBJ2PBG7oM cNiiBDaPxAF6L49j3aCVWibMFdNzITANb/rUturXSzs1/3d6djYRXv6avQBL6Ov2me3KP9 79jRrPiHRyYmW4EVKuVsJFteGvgWXhAJSp2Jf+FJvZIepnKO/XtUAqynaTJrO1uVUgdm/9 UmhCpJAcRvwBTvlwDfSk+9YV46oQxo+BpsqEmEShoKbIkIUgvNGtDG2YmVpDTsCbHW5oSG s+dPzkj/dpHxCFIR9F07L2bTls7h5YsQSzR9sPHjMENSBMxSLljh0eAW7bxqLw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713464351; a=rsa-sha256; cv=none; b=W5GylG8u/LqPiybbtJODgU3Lp88mf0oIpOiIqGXCIaRf3X1m6syERQV8P3N+zUnbEDFmJs t8md+hUNxW5MrlrKUs0PAg4VPOAUBK/V5rdimcwj2WiWlhnNJCHu8sFFqOHsDLVZTO+kaF WE1++IkyWvFx520nd7pRxtQ8yzM7XCgJYWi7MxmE+MqIe5azpKYLZQiVtTNY4n+U+LtlIU 4Y7bXYZA9DbA54VA00W93V3MlNlFUYy+wYJfGn9mLN+ulCRTxjEE7LFd7ZSSgjoiOGNzod hyAop1oiRnkuIWLoF020D2yE++7DClxEJxZEmzwBowqwcbvs+VdgSVxqgFI8EQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713464351; 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=zyZrL/2HQy82s6fhLpT1JyGrhSds3QGZDo0rS69WHQI=; b=JMjTWOnfRtvymGu6q3e7oQ0usoEd+sqvpfZdzXfNzRH+X8EIJNm36l2ryeBynlvrQfkRkg OdDJMgs0F0XvTMHkPCZnPzVibV8GmZgWg3c53wgj6WS67bzaaC8UD9tistb7Z97129S+/j lVnjqI1deW0bi2/RR/mMt2m5jwMHXX43fWCoDRGZNQzYfKKnorlDzE4HHISikIUfScOQBE 5bcIpXno+zrVAJlwYhwyvrkdwgC0YlowcPeecqvXbMz8mOq9XsTL9b7z+A+MaLodrslLZ+ Ve9dk/e52Q4aapzej2Dr6Ja/Rl+/gxNF416cg8fkRdaD9pyZSlfj03RmEzuN/w== 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 4VL5dW180CzKxq; Thu, 18 Apr 2024 18:19:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IIJBo3017855; Thu, 18 Apr 2024 18:19:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IIJBTH017852; Thu, 18 Apr 2024 18:19:11 GMT (envelope-from git) Date: Thu, 18 Apr 2024 18:19:11 GMT Message-Id: <202404181819.43IIJBTH017852@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: d16abff36292 - stable/14 - bhnd_erom.9: remove self-reference List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d16abff36292cf1410b7e4d9894b5a0a6d53471e Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=d16abff36292cf1410b7e4d9894b5a0a6d53471e commit d16abff36292cf1410b7e4d9894b5a0a6d53471e Author: Christopher Davidson AuthorDate: 2024-04-03 16:51:48 +0000 Commit: Mitchell Horne CommitDate: 2024-04-18 18:18:34 +0000 bhnd_erom.9: remove self-reference Change .Xr to .Fn, which quiets a mandoc warning. Reviewed by: mhorne MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/1135 (cherry picked from commit 81727a3dd38287d437d1e7e416dd89107a706e55) --- share/man/man9/bhnd_erom.9 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man9/bhnd_erom.9 b/share/man/man9/bhnd_erom.9 index f55472d71bd7..1e8101f011cf 100644 --- a/share/man/man9/bhnd_erom.9 +++ b/share/man/man9/bhnd_erom.9 @@ -204,7 +204,7 @@ hardware core must be provided using the .Fa eio argument. The registers can be mapped using -.Xr bhnd_erom_io_map 9 . +.Fn bhnd_erom_io_map . .Pp On devices that do not provide standard .Xr bhnd_chipc 4 From nobody Thu Apr 18 19:37:10 2024 X-Original-To: dev-commits-src-branches@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 4VL7MV6NNSz5HRwW; Thu, 18 Apr 2024 19:37:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL7MV5pVxz4FPl; Thu, 18 Apr 2024 19:37:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469030; 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=vFI1+cc97hEmu6NeZGD3pjALlAz5FTtSEfRoctvch9I=; b=MNuR3gP7fpc71H82l6WaJQbmNLvVHerhhAa8eHpJ2EIYclZOluXQe2F9GYlbeatKCMKIqC mIb7IA5nqWhFiD1TMXAsP2/zPzJOEXYGLl/S09h/3ex7Y3PVrrCzlIqbH3MsF11eYnO8xu 6LHAlL7RVOEBrFxG87w3oetF4ktVhIz/KgGNq6s3LQTVykEMKmBWZs9IaK+kQ0jIjHEihN o/aQyul9exCmhq38MsTsfz7F/cKUBgGlLpqEhu0ChpSjJl4eH6S19/huFVF3Y6+X+D39NV 1TujOlygfnQBPfFH1gJXPu1+On31QnZEwfwhq0X67eF7i9cFEMX8PAmy++s5nA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713469030; a=rsa-sha256; cv=none; b=HkrNQ+n4jK4VWIQF8HZXzk4unXvOP4exhAhdEefNIuMh30NkY1yoZNwLRovUxhfpwBbKY7 hUjM/8K9r1jKvajEW0jP4QoDy+elmFerxTy/6VzHccgHEB4XnvbO4MSeBP79azK6heEmw+ cQVFI1XPyky8eKIJ/2FHoS1G5iahF6KruYmY2JMHr7c1JXbVABAR0p4EHRHQOOADZtrmZ7 Obb4VNJ6uI0ZOQ4AZvJe4D+ttmxXNwqIL2Hgr90xQxBGMY/iG84O8EKy55imOmtSaurIj+ AstIkiGpSoXRrRABPdj3vElwLX9r7AZ+3i9GcIGISZDUybZiQpVGrfSRdNq1Hw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469030; 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=vFI1+cc97hEmu6NeZGD3pjALlAz5FTtSEfRoctvch9I=; b=mA57BHfscg5J/gExatjUcdNGz8vmDNpfo/QXw0zy0jEad/OGR7AwR6n2tolIQyOJyj6PU/ AsrET2odHjM+kMwIJeMTDCz/NydUOKfOyghtYnI+mSO7tVmotdNptR2AX+ZNmmd/KpCNlS nwmbwh/OWs8ICstDe5rsilei3SStcIotEYEu8zfDSh38M92GrzwTZ9l7zU3Gw0nlpBm/c+ jGH7uMpkzY2x7Kvt7vDk5dyyhwuW4bpCpVo7AJiIXgVvx0YWrmpPBuy2y9j+xCzR2WQUj4 pcsfUJmbgOKDH5cGa5RBbTwGg/EQOVkkv0MldFccZVHgIlxqQtqDz7CCSDTAmQ== 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 4VL7MV5J9dzNMW; Thu, 18 Apr 2024 19:37:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IJbAZw053753; Thu, 18 Apr 2024 19:37:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IJbArP053750; Thu, 18 Apr 2024 19:37:10 GMT (envelope-from git) Date: Thu, 18 Apr 2024 19:37:10 GMT Message-Id: <202404181937.43IJbArP053750@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Marius Strobl Subject: git: 954bb7642175 - stable/14 - fib_algo(4): Lower level of algorithm switching messages to LOG_INFO List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: marius X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 954bb76421759e9cacd89d44cfd49ca27404bd29 Auto-Submitted: auto-generated The branch stable/14 has been updated by marius: URL: https://cgit.FreeBSD.org/src/commit/?id=954bb76421759e9cacd89d44cfd49ca27404bd29 commit 954bb76421759e9cacd89d44cfd49ca27404bd29 Author: Marius Strobl AuthorDate: 2024-02-05 19:36:13 +0000 Commit: Marius Strobl CommitDate: 2024-04-18 19:30:33 +0000 fib_algo(4): Lower level of algorithm switching messages to LOG_INFO Otherwise, with the default flm_debug_level of LOG_NOTICE, it's rather easy to trigger debug messages such as: [fib_algo] inet.0 (bsearch4#18) rebuild_fd_flm: switching algo to radix4_lockless Also, the "severity" of these events generally only justifies LOG_INFO and not LOG_NOTICE. Reviewed by: melifaro (cherry picked from commit ed81a15517b8a8f587fd7282c3690513bb798242) --- sys/net/route/fib_algo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/route/fib_algo.c b/sys/net/route/fib_algo.c index 1e37acf620a9..25370f18934f 100644 --- a/sys/net/route/fib_algo.c +++ b/sys/net/route/fib_algo.c @@ -1382,7 +1382,7 @@ rebuild_fd_flm(struct fib_data *fd, struct fib_lookup_module *flm_new) if (flm_new == fd->fd_flm) fd_tmp = fd; else - FD_PRINTF(LOG_NOTICE, fd, "switching algo to %s", flm_new->flm_name); + FD_PRINTF(LOG_INFO, fd, "switching algo to %s", flm_new->flm_name); result = setup_fd_instance(flm_new, fd->fd_rh, fd_tmp, &fd_new, true); if (result != FLM_SUCCESS) { From nobody Thu Apr 18 19:42:16 2024 X-Original-To: dev-commits-src-branches@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 4VL7TP1FGBz5HS3F; Thu, 18 Apr 2024 19:42:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL7TP0qlRz4GbV; Thu, 18 Apr 2024 19:42:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469337; 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=YVMEJnq7/SUmQUbDLpItqSckj2916fdAo1z1x1VxoxM=; b=OBUEIFXNzUn1MM0kj7ul4dZmUGP3xfacGDt/KRS+h+5NADg45b6r9dKjduOilCE/qDBhQb QRHEHulKpPeY6p8Ic2I7TnFgkNoykHlVmeBeFyokd5asU3jn53u0wMDsb6lhfOKOuezbTG kTbqJrR8tADQ1t5IEmtwlvhj3OVUeD/UGe6oBGGzMqZ8qumZIUby058fkz0teNkQNT7R1g WA4gvVEYxGwzObVhb8NiBVSb4afQ+MWfCmGeC8konmoK6gXG4fM0+IuZjZ2JI2simFWct3 w1OsD21SVI33nfG+Ok6cbbiKLRQyoDDzGzN74GgrNMCDZ/JYd9VWjhrG/Zw2uA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713469337; a=rsa-sha256; cv=none; b=BKFlYMn1xracYA4lCEj4ALIAtgsJHLiibJuJLPHrxzYPiH7iMmVOdNtFV+mtdH7QyXIKSG QXSNGrbqFOXq2p27ERhTPcIrHQfHgURHMDenJvjtaV+9TGLvkTxc1ZKN5S4AeiMmRZnLHU 8FLFmnOVKBenzqdBvQDb7SyQTtJXvFXJ7x2pRjUDqwdhnM36DoHs7kqSsbzBgFUi/vyQZD qxj5U1IxwehbSghsOg7IuGsyKIbxJTFK0YWrLOfIRcZFw9jd2NrbjJhDVN3Zos31B/Okmr Bk0CLXqBmIdPWv/tZB4eLiToTnfyitsBtYy7ABeseyeZS2DFB6kIvlakIeAM2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469337; 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=YVMEJnq7/SUmQUbDLpItqSckj2916fdAo1z1x1VxoxM=; b=iNGxN35O01zuyKr9BEY5hbepOdUpFWiql/8ZbdGARyhggV/sBM6rmUxHL0bNJ+JflPpwW/ qNY7e8gvO7AeMFRxAs68Zf3dcCildCukw4nWCzk27byuDTY1ECi+mrS0qrBpZKUfsAWp0o PneLyZZGJYadn+tkEq3B5b/N1N+BQKFPWk5hXzjDS2RqJ0m0GCNdGABrTy+cqmgb/jWulM olJltYUZiP6MjLFoTTzAPV107dw2Z+dbLLPjp3SIWvyKafcgBb9gOzDYufd0VsEewqzSsr uN0j1bdm8QIwrYs4lsoA9z16om28cvocKOY5XVnwUuO9zvCak5+t+ui7z9TaSA== 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 4VL7TP0R9lzNWw; Thu, 18 Apr 2024 19:42:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IJgGxC066097; Thu, 18 Apr 2024 19:42:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IJgGID066094; Thu, 18 Apr 2024 19:42:16 GMT (envelope-from git) Date: Thu, 18 Apr 2024 19:42:16 GMT Message-Id: <202404181942.43IJgGID066094@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Marius Strobl Subject: git: 3d1d7c2c161d - stable/13 - fib_algo(4): Lower level of algorithm switching messages to LOG_INFO List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: marius X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3d1d7c2c161d58cffd0bcd2c77ae580db394879d Auto-Submitted: auto-generated The branch stable/13 has been updated by marius: URL: https://cgit.FreeBSD.org/src/commit/?id=3d1d7c2c161d58cffd0bcd2c77ae580db394879d commit 3d1d7c2c161d58cffd0bcd2c77ae580db394879d Author: Marius Strobl AuthorDate: 2024-02-05 19:36:13 +0000 Commit: Marius Strobl CommitDate: 2024-04-18 19:41:36 +0000 fib_algo(4): Lower level of algorithm switching messages to LOG_INFO Otherwise, with the default flm_debug_level of LOG_NOTICE, it's rather easy to trigger debug messages such as: [fib_algo] inet.0 (bsearch4#18) rebuild_fd_flm: switching algo to radix4_lockless Also, the "severity" of these events generally only justifies LOG_INFO and not LOG_NOTICE. Reviewed by: melifaro (cherry picked from commit ed81a15517b8a8f587fd7282c3690513bb798242) --- sys/net/route/fib_algo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/route/fib_algo.c b/sys/net/route/fib_algo.c index 1e37acf620a9..25370f18934f 100644 --- a/sys/net/route/fib_algo.c +++ b/sys/net/route/fib_algo.c @@ -1382,7 +1382,7 @@ rebuild_fd_flm(struct fib_data *fd, struct fib_lookup_module *flm_new) if (flm_new == fd->fd_flm) fd_tmp = fd; else - FD_PRINTF(LOG_NOTICE, fd, "switching algo to %s", flm_new->flm_name); + FD_PRINTF(LOG_INFO, fd, "switching algo to %s", flm_new->flm_name); result = setup_fd_instance(flm_new, fd->fd_rh, fd_tmp, &fd_new, true); if (result != FLM_SUCCESS) { From nobody Thu Apr 18 19:42:18 2024 X-Original-To: dev-commits-src-branches@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 4VL7TQ2yXpz5HS8f; Thu, 18 Apr 2024 19:42:18 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VL7TQ1q5zz4Ggm; Thu, 18 Apr 2024 19:42:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469338; 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=6R1wHhSzF9GltNRrb3SMme/q5W9U089GtA56beMHNVg=; b=NiX5rUprlZ7a0eHRaPGA4c+YZpmxbexE/q+ck7T6M7n1iThHIsWIbYq/cfcUk7ST1qisW0 CQkqUC29ULgVR76Uv6yLHgHK4GOknLgek5VsAQMPppiUKU0wjuYMBtxYhQP6N+R9zYSNbI Tm8baurTVwsUIa5IEGrv3AWRwTGfqUxkgy8e7Ht+DR+4TlVREDdHiWOA8W7Rd4Qr7vWAYi B4vvvfL3+891Xz2sOctZ0IFAgkI0eBCV98ax86Y+DIgU80VuM21F2Bob4ta65XekSvqLSe uDGYkaHcYAHZOLDsODuHozD6tLiRPUoNwt5wmyJ7Af9Pe+ws5vQkfVx9pz+ctg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713469338; a=rsa-sha256; cv=none; b=WQLJ1hoG8byjMjS8CGHIStVcU3/4SW9Y+WlNWq3dyoxVTdvqCmnJMaVcU+q4g82L6HNWAw B60JwjD7TJLRLi53mt6sMdYUpZGT1XUu5TQS3Y2dlYSsOjFJN6dri7+qSp+B5/qvJKo4Q4 0Y1jsnOuj1laMKOigT5jW2jS1Nr23EXkbXtcTw4tyCVHIhUvmzQqcSpE3vzgSFxG7afEpg zGfo1T/gRW60x611NAvKpT9dx0ZYMt8663nnyObcedRX5bzwqT3FQ/yd12s7jBmRdQAlvw dV1vyXO/qAIFtVsVGVvCgdFU5IOLnNJVtS+CHEQA1gH18edTtIuzvSxVjWOY+w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713469338; 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=6R1wHhSzF9GltNRrb3SMme/q5W9U089GtA56beMHNVg=; b=tjrTWKICKAeLbgu9MzQL7n0gWxpu+RpysCrWi9niZtCOkUigr00QOIkWqbC2Cy3yT27YgW S+lvIlp8TMUFwym5rSjsreWHQIDSB2/OQCFIoMjj7+yfK0R3+DVFEPrM2rYXXZsofjmmhf mIhLXPfznMvphEUORhDI75fgRKS0R+zclI8xeA8nrEUYj/ZOPc+GgAKK+EJfReRlFHMn13 7qYbuWxKfjTuJWUKKEtPZjceLRWNVse4CPmXbPFXxI/pbr+MtIfkwFpEg4VV4B0lg3a7bI Pg7x1TrLbNa9lt5H8bftH6CZ1O5unRwbZZJs5vSKBF5uz/5Q1Y0ef+7XVKopLg== 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 4VL7TQ1QmlzNWy; Thu, 18 Apr 2024 19:42:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43IJgINZ066154; Thu, 18 Apr 2024 19:42:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43IJgI9a066151; Thu, 18 Apr 2024 19:42:18 GMT (envelope-from git) Date: Thu, 18 Apr 2024 19:42:18 GMT Message-Id: <202404181942.43IJgI9a066151@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Marius Strobl Subject: git: 8ee68ab86778 - stable/13 - Fix "set but not used" for the sym driver. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: marius X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8ee68ab867785b90a77c9c0e6c2ef92fc8a265b1 Auto-Submitted: auto-generated The branch stable/13 has been updated by marius: URL: https://cgit.FreeBSD.org/src/commit/?id=8ee68ab867785b90a77c9c0e6c2ef92fc8a265b1 commit 8ee68ab867785b90a77c9c0e6c2ef92fc8a265b1 Author: Scott Long AuthorDate: 2021-12-03 22:18:39 +0000 Commit: Marius Strobl CommitDate: 2024-04-18 19:41:36 +0000 Fix "set but not used" for the sym driver. Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 5045cb8f18f9f79354f93174ba7f9fd2f7ea6994) --- sys/dev/sym/sym_hipd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/dev/sym/sym_hipd.c b/sys/dev/sym/sym_hipd.c index 8517d79124b0..d4f220871452 100644 --- a/sys/dev/sym/sym_hipd.c +++ b/sys/dev/sym/sym_hipd.c @@ -5460,7 +5460,7 @@ out_reject: */ static int sym_compute_residual(hcb_p np, ccb_p cp) { - int dp_sg, dp_sgmin, resid = 0; + int dp_sg, resid = 0; int dp_ofs = 0; /* @@ -5507,7 +5507,6 @@ static int sym_compute_residual(hcb_p np, ccb_p cp) * We are now full comfortable in the computation * of the data residual (2's complement). */ - dp_sgmin = SYM_CONF_MAX_SG - cp->segments; resid = -cp->ext_ofs; for (dp_sg = cp->ext_sg; dp_sg < SYM_CONF_MAX_SG; ++dp_sg) { u_int tmp = scr_to_cpu(cp->phys.data[dp_sg].size); From nobody Fri Apr 19 02:50:32 2024 X-Original-To: dev-commits-src-branches@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 4VLJzX5ww2z5Hd4B; Fri, 19 Apr 2024 02:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLJzX5Q7wz44VH; Fri, 19 Apr 2024 02:50:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713495032; 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=ADMUp4KYlbQdRRWv0IOih7JYy3BiPExoAiqM/pE5Jpo=; b=cXKtlODk2ERZuSVICK7WoLBhPQ2BUih5DoCYi43AYxYhbg67r9RQjNG2Zx/tdZqIbQYjth x9wZ5pbc48i30OCRg7AtKZahBz0n2gAkE0jKutUTA2zD7lslCRsYNdmnlNnAFLfFN2/0uK wfGHzo0WJZA/SjnxDVE7mmAIj6h2xuz4oBbQtRBPbwPQTsFZp2PA98KkFJ83JYUYV1SG8H IZeSyE3ldeHm0cIICF9T4AJc8HQOBeHFOeJU8ZY11AoSnxXEjfZyXSxishjS8cGq7BIJSX ltxZS3iRaEJk+OLMbp0aHzFV6U+3/Ff+fqtA5/+bmYwwp5yak4lh8obodGICIw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713495032; a=rsa-sha256; cv=none; b=ac7phuguGPB0yE0aehZWDA8PtickzX1NbvB37bYKHZR5QSYDclapQM9mtlsc4GzNNiWYAu FbUURzbtrMVxZaMer6geSuZRDI3d2nP0w0Undwu03ZfBljf5eB13PukdYNa10UpDEJbip8 bEHfHSWuozXk/CQIhmhC8szDK8B2zJI/Gss57JoYkvH+duKPV5cD15eVvZClpdRcFaNxKt +J0UJBvvYMdP5MOI4afYTHK2LmTY6wm8zhoPHnEY8/5Mr9aX88gcTQaSAWk1iILeesY3pK TSWSMcVsVtz5bXjoVE6tlWV6EAuvUPlNegkl80UEfe40KwF6JmPmAxNZKN3zXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713495032; 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=ADMUp4KYlbQdRRWv0IOih7JYy3BiPExoAiqM/pE5Jpo=; b=ga2n0u59zvDchqhKWYR6u99GHuiIMMFIaPM5xUhFtweQmcKgM6gjDcBE8WNbg+4iTV17em dOI6DXyoDZcM4Kqnlacevfh4whgBOIT38hxFWScWAEgo8bwV0OWfnabEqBIDkMixKoo5GL 6UslohHsfqqXQ8NqYooPNp5TszKgPfuieVfctEZISZgG/DewKwhuAXY23IrnV5z7vuRrVo MF1ty3vozjKOMFb9tMHM//kXE0onCtCogmKYvILwvg84kivY5R/XuFBm87ZPmUgZZ5u2Mc OY8MzkwV2WQIwdGAO0bG8sGk+7regx4CXJQFYXyl6/vJrO02ck0sCAxU3txcfw== 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 4VLJzX51ZTzbpS; Fri, 19 Apr 2024 02:50:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J2oWCG091348; Fri, 19 Apr 2024 02:50:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J2oWG4091345; Fri, 19 Apr 2024 02:50:32 GMT (envelope-from git) Date: Fri, 19 Apr 2024 02:50:32 GMT Message-Id: <202404190250.43J2oWG4091345@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 7a2c2599a760 - stable/14 - 14.1: update stable/14 to -PRERELEASE List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7a2c2599a760156d8ef8bdf741adc1abd4ad26fc Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=7a2c2599a760156d8ef8bdf741adc1abd4ad26fc commit 7a2c2599a760156d8ef8bdf741adc1abd4ad26fc Author: Colin Percival AuthorDate: 2024-04-19 02:49:36 +0000 Commit: Colin Percival CommitDate: 2024-04-19 02:49:36 +0000 14.1: update stable/14 to -PRERELEASE This marks the start of the FreeBSD 14.1 release cycle; the stable/14 tree is now in "code slush". Developers are encouraged to prioritize fixing bugs (and/or merging bug fixes from HEAD) over new features at this time. Commit approval from re@ is not required but if new features introduce problems they may be removed from the release. Approved by: re (implicit) --- sys/conf/newvers.sh | 4 ++-- usr.bin/yacc/config.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index 8416d073482b..144584e90147 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -52,8 +52,8 @@ # TYPE="FreeBSD" -REVISION="14.0" -BRANCH="STABLE" +REVISION="14.1" +BRANCH="PRERELEASE" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi diff --git a/usr.bin/yacc/config.h b/usr.bin/yacc/config.h index c9a9fe59139b..16c6abfc32f5 100644 --- a/usr.bin/yacc/config.h +++ b/usr.bin/yacc/config.h @@ -92,7 +92,7 @@ /* #undef STDC_NORETURN */ /* Define to the system name. */ -#define SYSTEM_NAME "freebsd14.0" +#define SYSTEM_NAME "freebsd14.1" /* "Define to 1 if you want to use dbmalloc for testing." */ /* #undef USE_DBMALLOC */ From nobody Fri Apr 19 03:17:25 2024 X-Original-To: dev-commits-src-branches@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 4VLKZZ0GfXz5HgK3; Fri, 19 Apr 2024 03:17:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLKZY6c1pz46Z6; Fri, 19 Apr 2024 03:17:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713496645; 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=Udo9XnrhX9gXuuMZ/V05AoaNNfLvPHAjqIIu8jfGajY=; b=Vc1h3vmTjwHdbSU7Jh+AxD12M78rG9alPK3frVp3O20TfQ3UgCEOavVVpgZnME8kR5JWN8 8ujbSLAob2bTUlJ/RAINeKN7xZtLFtMfZ38QLftXDyFPF9oZI3MpMXEihcfePhp91/6z/k c52QEKOy9x8lIY7kF22XM/V8cTUBs75CoXuS3nzE3f1ck0D3VjXZiD1f2NnD+QboJuOamH 17BE+2j44lmpdOrcXsKaEWI9Cbsq2ocjb9bGs1WDBwNCjhiXmn2O6j2m1vJhHxxzowYSMw 8gKVZT/TLh9Q8NpHWqTJyqFAgVbn23Z1BYLAHDxyhz8ZqtEbaQWZnm1haHAwFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713496645; a=rsa-sha256; cv=none; b=rb2jJVODmOOiA54wyPihOMN7ENggvN5PeXe5x6euD/lLYgx37ZEvtTRFFQD9OC7H2OWfxn 18KnPhWIHBqaOUgRRqIALJupth72HLA98KAua9/JQuCV5dkSWYqWDKRazG/0A4tVaURv3v ZVv0nOLQ0jfHN1koOtwfMZxGXVaF5ygJ01+r3ATDbKYWesEd8hk8wuxvbGtbIAlQFIRPGu TTiGNUIp1EdfK9gan4ffjFo5+6A1hbSGy/nLnt9+hUa4M7gohP72sRvA8jGVu1DAcpPwKP yUbblARDpv9P14TrUdpziZKePdZ8ii9WRYQNIG/0XeIel2ZIV2wDRh4MKrBmCQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713496645; 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=Udo9XnrhX9gXuuMZ/V05AoaNNfLvPHAjqIIu8jfGajY=; b=bbt5AnyKDTL5QLMvSIwour36btTCa6aCqkMjWZ9h5OCC01X+8p84rlZAFwkhed0TYlhf8o vEtlrzTCXXIfMXImRTd9tYSeKegroYu2Q9HMNLD5rfxYrJKZv8Ipll7WUoO9zkUgm8PQF5 NuOAicBDCkGVeywogmnJIR50OshP2A7T4dUCjXw2W16J3ASQe0GyMypLoqb/xRpy5EjDeL Tm3jQidy0IwDG7ZiSCdhzE2kB1BA1LSebCtrl+7DqASggALjlmnKHJU99Z0g8MSZD/TS20 TxIYnYttvcVyscaLuXr7kBpswifHiAWFsVcqwQ/rGRb29SpblWLwl5jqOC98OA== 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 4VLKZY6CXkzcrs; Fri, 19 Apr 2024 03:17:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J3HP5K035569; Fri, 19 Apr 2024 03:17:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J3HPIF035566; Fri, 19 Apr 2024 03:17:25 GMT (envelope-from git) Date: Fri, 19 Apr 2024 03:17:25 GMT Message-Id: <202404190317.43J3HPIF035566@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 788987e034b1 - stable/14 - acpi_battery: avoid divide-by-zero when no devices have capacity info List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 788987e034b1c73d779a3aa179f79f672bbdb366 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=788987e034b1c73d779a3aa179f79f672bbdb366 commit 788987e034b1c73d779a3aa179f79f672bbdb366 Author: Josef 'Jeff' Sipek AuthorDate: 2024-04-16 23:01:28 +0000 Commit: Ed Maste CommitDate: 2024-04-19 03:16:52 +0000 acpi_battery: avoid divide-by-zero when no devices have capacity info On laptops with builtin batteries, disconnecting the battery may show up as a battery without any capacity information. (The theory is that one is disconnecting the cells but the electronics identifying the battery are still connected.) As a result, the loop over all batteries in acpi_battery_get_battinfo results in total_lfcap == 0. So, just check that total_lfcap is non-zero to avoid a division by zero (triggerable by sysctl hw.acpi.battery). Reported by: Stefano Marinelli Tested by: Stefano Marinelli Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D44818 (cherry picked from commit 2e850b832f5d2adb9b230d191277d67c00caaab9) --- sys/dev/acpica/acpi_battery.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sys/dev/acpica/acpi_battery.c b/sys/dev/acpica/acpi_battery.c index 7455c6afc6a6..cfd8261d5eab 100644 --- a/sys/dev/acpica/acpi_battery.c +++ b/sys/dev/acpica/acpi_battery.c @@ -266,7 +266,14 @@ acpi_battery_get_battinfo(device_t dev, struct acpi_battinfo *battinfo) */ if (valid_units > 0) { if (dev == NULL) { - battinfo->cap = (total_cap * 100) / total_lfcap; + /* + * Avoid division by zero if none of the batteries had valid + * capacity info. + */ + if (total_lfcap > 0) + battinfo->cap = (total_cap * 100) / total_lfcap; + else + battinfo->cap = 0; battinfo->min = total_min; battinfo->state = batt_stat; battinfo->rate = valid_rate; From nobody Fri Apr 19 06:57:34 2024 X-Original-To: dev-commits-src-branches@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 4VLQSZ4BfPz5J08J; Fri, 19 Apr 2024 06:57:34 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLQSZ3hLsz4TTC; Fri, 19 Apr 2024 06:57:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713509854; 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=Kwy9/o/wcr/SqZqFrTsNvnVJY8kOPMPE9FMdYysEUJ8=; b=YS1DGCQbRmQMJbxgqPhGMe+nsb/l5YWBrdiz0rw02vcXVQYBvy33yP4MTKDcCQqsF7jPQ3 XQ2YNqdyO9bxuz2TbacN/ufgAH3npouptrviGd6FpjVEDspbPtRIuvJ1Uad4LRxd3tOlLq N70zKVj+BA8YHAGMvkW/G4fG28D3NhKFxVYBDHY10UaFfDKmHh94Sta81Z3p6lIvWW4gYS PTDXh4KhTTl/m/NhWli/TPcJ9YRNwSf47rJsjBT0qR1sYe3FzLc2RjobYMg3n12BXeYdum kOd9AYVfzldATFXq14Wz2+Q1ghmoIAjyqYSEfQAtApgMGVXTU/bVjn0wPr2e+Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713509854; a=rsa-sha256; cv=none; b=Zdjg2YRV+bUeJ+2p4CHsWhU+p8ustbxiBZPWNPWDVgAQZ5c6+MuIdEilD+e6gK2bxSsFmB vcTHdowa28lPa8coII2kmiKprmGuHR+TlgOvx6zGEIkxXfh5zou5GRWQQ1EetHrj7SuMa3 vP57h4KvO6wbJxtNnDW4TShZLax4gd952xksie0EOtF3N7t3YHzSoRm7NlRyzuw9W5nCfB w2aA0feKf0UClUPEWMGYTDwbOcxJeJP/joAYfejI1V93H5iO54CD55L1VSNa1bvK15IhgX fuUKIsjA1oM5tbQhiqouWMl+tzT89mU198RsJUwtBy2ZFS/rxvKdbgo1Ng/BNw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713509854; 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=Kwy9/o/wcr/SqZqFrTsNvnVJY8kOPMPE9FMdYysEUJ8=; b=Ew9oArVnICEjVculsYFCmmYVsF4o+FI2RQ0w4NqDXSYfnzP4nIZW7qfdRuayShsWHkn+nD HXYT9A4a1yOlN0WA0a8kzsoUevWQ5ENu1cgr89Q7Qafed4h2cDzma4EYI0/OufGBxFva36 12hVgZr1QlzvrJGO1eIrP43wMq+5/I/z7fZfaMvk4O7LaiEL1vH3qR5JQ5hyocs0zH96pU X4kFGu8i9iA6uLHP9VUv7sE2Yj/3pE0Yx6QaMndsQjJQMkKdBYr2YCyGSS0TbvOaQy7Cbw rF2Jck2pchLQSmUSXcd6czi3FgEWf0bX+y7Jjchny5erRKkJHhpUZHjQzndwPQ== 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 4VLQSZ3Fqxzk0K; Fri, 19 Apr 2024 06:57:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J6vYIT005723; Fri, 19 Apr 2024 06:57:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J6vY4M005720; Fri, 19 Apr 2024 06:57:34 GMT (envelope-from git) Date: Fri, 19 Apr 2024 06:57:34 GMT Message-Id: <202404190657.43J6vY4M005720@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Zhilin Subject: git: 0a902d7561ff - stable/14 - snd_hda: Add the full Intel Meteor/Arrow/Lunar Lake HD Audio PCI IDs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mizhka X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0a902d7561ff4e86c02807717fc07fef2767e7d3 Auto-Submitted: auto-generated The branch stable/14 has been updated by mizhka: URL: https://cgit.FreeBSD.org/src/commit/?id=0a902d7561ff4e86c02807717fc07fef2767e7d3 commit 0a902d7561ff4e86c02807717fc07fef2767e7d3 Author: Michael Zhilin AuthorDate: 2024-04-13 09:57:59 +0000 Commit: Michael Zhilin CommitDate: 2024-04-19 06:37:07 +0000 snd_hda: Add the full Intel Meteor/Arrow/Lunar Lake HD Audio PCI IDs This is based off the Linux file sound/hda/intel-dsp-config.c. Tested on: Lenovo Thinkbook 16 G6+ IMH MFC after: 3 days Reviewed by: markj, christos Differential Revision: https://reviews.freebsd.org/D44777 Sponsored by: Postgres Professional (cherry picked from commit 1dd1a696c58fb275aa0e01666d57861eeb51878d) --- sys/dev/sound/pci/hda/hdac.c | 4 ++++ sys/dev/sound/pci/hda/hdac.h | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index 704bcad3822c..f3dff2052b51 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -118,6 +118,10 @@ static const struct { { HDA_INTEL_ALLKPS, "Intel Alder Lake-PS", 0, 0 }, { HDA_INTEL_RPTLK1, "Intel Raptor Lake-P", 0, 0 }, { HDA_INTEL_RPTLK2, "Intel Raptor Lake-P", 0, 0 }, + { HDA_INTEL_MTL, "Intel Meteor Lake-P", 0, 0 }, + { HDA_INTEL_ARLS, "Intel Arrow Lake-S", 0, 0 }, + { HDA_INTEL_ARL, "Intel Arrow Lake", 0, 0 }, + { HDA_INTEL_LNLP, "Intel Lunar Lake-P", 0, 0 }, { HDA_INTEL_82801F, "Intel 82801F", 0, 0 }, { HDA_INTEL_63XXESB, "Intel 631x/632xESB", 0, 0 }, { HDA_INTEL_82801G, "Intel 82801G", 0, 0 }, diff --git a/sys/dev/sound/pci/hda/hdac.h b/sys/dev/sound/pci/hda/hdac.h index 53c101f3119b..4dd589ed2a09 100644 --- a/sys/dev/sound/pci/hda/hdac.h +++ b/sys/dev/sound/pci/hda/hdac.h @@ -98,6 +98,10 @@ #define HDA_INTEL_CMLKLP HDA_MODEL_CONSTRUCT(INTEL, 0x02c8) #define HDA_INTEL_CMLKH HDA_MODEL_CONSTRUCT(INTEL, 0x06c8) #define HDA_INTEL_TGLK HDA_MODEL_CONSTRUCT(INTEL, 0xa0c8) +#define HDA_INTEL_MTL HDA_MODEL_CONSTRUCT(INTEL, 0x7e28) +#define HDA_INTEL_ARLS HDA_MODEL_CONSTRUCT(INTEL, 0x7f50) +#define HDA_INTEL_ARL HDA_MODEL_CONSTRUCT(INTEL, 0x7728) +#define HDA_INTEL_LNLP HDA_MODEL_CONSTRUCT(INTEL, 0xa828) #define INTEL_A100ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xa100) #define INTEL_D400ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xd400) #define INTEL_D401ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xd401) From nobody Fri Apr 19 06:57:35 2024 X-Original-To: dev-commits-src-branches@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 4VLQSb4vHVz5J0Gx; Fri, 19 Apr 2024 06:57:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLQSb4MHfz4TMx; Fri, 19 Apr 2024 06:57:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713509855; 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=lBM615z3r0na/pToQ3fRUBYtubfTSeFYFYU84jVShgI=; b=rtDEgiXiYgaPPdI8qKUVntE5liXrE1cgPYpay4Dx7GuXVyMQroI84UevBJdb1MKjr4an/N IIagyI6A45tr3lv5+Po5Sqif1WCXwDfeJQl93qTAxOCz/eAgUXdP+8IimvzFW3VwFdBoHu Q79v+LiePaS6GpZgC/90ULCe2thCeN2qL4TBukDfOfLJo6xES35ol3FvqjnEhZhkj7/vDm mQ8KX8rbPtRApiHc8+ijKBmdvZjxl3v3gR2/WOkYWtYj0qEqhcGiifE5PR1tXjF5sEPYvt VkE9bzy+KoFVBtdB/wYcGaVdBt0RlSHZkxu+eDVnSc91OTWHwBbQr1LQwHZTZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713509855; a=rsa-sha256; cv=none; b=cp4FRB6SQ3zDla5dxVR8Qhl9UaWBKXJmF7NwPXxMTd1gKTazSNmSghOqDrYE7DAUW+aucc tNhWNxMfKTzU8Hihir5+1VyJDQhkRFAI+gL14a6N3Bnxrucy1mPGk+WNXqg1KneGHQrHaM g7DpFKkk6zqT9EVf3+5TULnhibYJNstPwyAIJIbla0i8lHtXM4yjGHxAqyE3fzIH/5kP7t DkI/9tG9GgNh5Utr2s03ZHc8EwwXgdwFHYTOcVEChOpXALhRB75nkomYIuYEC1Q4am6y6s caLC8Bvn58R0uVjyszd6zrKTI8qGQiOu1VATlz2kV8CJXNe4qJgRQQIpncB+Mw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713509855; 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=lBM615z3r0na/pToQ3fRUBYtubfTSeFYFYU84jVShgI=; b=I4CK9tea8Ghf4I960V73t5dXFrAXcf4dj5JZR38nL/hnkOe7Yaay8PccPwVbXcClD0oFQQ rOjwnUIjZOUCKuoT531nLyeY9P0VNYHTJ6dEjcGQz2zZ58F0er6344X1PozOjDBDaYZNN7 Uv66i1Add5OyU2KXkaFfzw2vqNOI5Ra2G5RaOqhDWoekiq3zPgtHPdtlXxu3LjI09YXlZi E5WsZOQ+5x4g6PFBblFekUDbJ8wMkYO88FVE3tBsV49NSs4s5SeaON+eeVIpMITm6KKakj 9ku87V/UHhBx/LthN4IrquQbpC/gPhG3NZsgSYiN5BGjHLlU0YZmu8UK+CJkUg== 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 4VLQSb3xYDzjjX; Fri, 19 Apr 2024 06:57:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J6vZY6005781; Fri, 19 Apr 2024 06:57:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J6vZnZ005778; Fri, 19 Apr 2024 06:57:35 GMT (envelope-from git) Date: Fri, 19 Apr 2024 06:57:35 GMT Message-Id: <202404190657.43J6vZnZ005778@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Zhilin Subject: git: 2a66844f606a - stable/14 - snd_hda: fix "duplicated free" on module unloading List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mizhka X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2a66844f606a35d68ad8a8061f4bea204274b3bc Auto-Submitted: auto-generated The branch stable/14 has been updated by mizhka: URL: https://cgit.FreeBSD.org/src/commit/?id=2a66844f606a35d68ad8a8061f4bea204274b3bc commit 2a66844f606a35d68ad8a8061f4bea204274b3bc Author: Michael Zhilin AuthorDate: 2024-04-13 09:59:24 +0000 Commit: Michael Zhilin CommitDate: 2024-04-19 06:37:08 +0000 snd_hda: fix "duplicated free" on module unloading This is trivial fix of hdacc_detach to avoid duplicated free on snd_hda unloading. The first try of detaching (kldunload) may results into "device busy" error, but codec->fgs is freed by detach. Second try attempts to free codec->fgs again and system panicks. Here is example: pcm0: unregister: channel pcm0:virtual:dsp0.vp0 busy (pid 3428) pulseaudio[3428] [oss] module-oss.c: DSP shutdown. pcm0: detached hdaa0: detached panic: Duplicate free of 0xfffff80412ee7d20 from zone 0xfffffe006bc0ba00 (malloc-32) slab 0xfffff80412ee7fc8(105) cpuid = 6 time = 1712999565 KDB: stack backtrace: db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe0202f859e0 vpanic() at vpanic+0x135/frame 0xfffffe0202f85b10 panic() at panic+0x43/frame 0xfffffe0202f85b70 uma_dbg_free() at uma_dbg_free+0x105/frame 0xfffffe0202f85b90 uma_zfree_arg() at uma_zfree_arg+0x95/frame 0xfffffe0202f85be0 free() at free+0xa1/frame 0xfffffe0202f85c20 hdacc_detach() at hdacc_detach+0x2f/frame 0xfffffe0202f85c40 device_detach() at device_detach+0x197/frame 0xfffffe0202f85c80 devclass_driver_deleted() at devclass_driver_deleted+0x66/frame 0xfffffe0202f85c devclass_delete_driver() at devclass_delete_driver+0x81/frame 0xfffffe0202f85d00 driver_module_handler() at driver_module_handler+0xff/frame 0xfffffe0202f85d50 module_unload() at module_unload+0x32/frame 0xfffffe0202f85d70 linker_file_unload() at linker_file_unload+0x1eb/frame 0xfffffe0202f85db0 kern_kldunload() at kern_kldunload+0x18e/frame 0xfffffe0202f85e00 amd64_syscall() at amd64_syscall+0x153/frame 0xfffffe0202f85f30 fast_syscall_common() at fast_syscall_common+0xf8/frame 0xfffffe0202f85f30 MFC after: 3 days Reviewed by: markj, christos Differential Revision: https://reviews.freebsd.org/D44778 Sponsored by: Postgres Professional (cherry picked from commit bed0b2146faa2e9a445d9f9196c7b46f50034631) --- sys/dev/sound/pci/hda/hdacc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/dev/sound/pci/hda/hdacc.c b/sys/dev/sound/pci/hda/hdacc.c index 123c64d9c487..009c9098ac3b 100644 --- a/sys/dev/sound/pci/hda/hdacc.c +++ b/sys/dev/sound/pci/hda/hdacc.c @@ -539,9 +539,10 @@ hdacc_detach(device_t dev) struct hdacc_softc *codec = device_get_softc(dev); int error; - error = device_delete_children(dev); + if ((error = device_delete_children(dev)) != 0) + return (error); free(codec->fgs, M_HDACC); - return (error); + return (0); } static int From nobody Fri Apr 19 07:23:50 2024 X-Original-To: dev-commits-src-branches@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 4VLR2v0sfHz5J1pF; Fri, 19 Apr 2024 07:23:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLR2v08Hlz4Wbv; Fri, 19 Apr 2024 07:23:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713511431; 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=Vs7XEvuKSU7J1L/PaZkVPwVGUc5qwo0SE38PZBef8oM=; b=RvXz3WICdXuIXoDtFJnibFHYpPJ1Aam3murFFa3Q8rfxXOme0Cz5F1w19FtPlU7iBrYhsz CRZzSt3tGYQP9Gv5XwqjaqZJBzJJseEs0X9RyGI8bAQ6xgDSYLmVS8oozO6bSglDHfyoQM YKSpbC8jwNE1PC+0k8RS695WxKE/0S9RgjMla/Smrjq97/5D6WgWTQsu5JvSHtYBN0tWgW NvcBA1A3k5q9ek3rmb4bmvG1bjawWXUevE8FQFcqQDdVU9JXU1T9O1YwDJz72MFvFUulsr B2lyHEbu45gKLEJSkR6t9QEYI32jitPrc4aKBQ5WAtObhFOXdz84cjY0E3PycQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713511431; a=rsa-sha256; cv=none; b=Qm5is4Tg4XrD6nxpzi60xS4b7292llKUfbgrjwB2zsFQerXqBZWkpihBbwgA3saQq0PX/9 KE965oHoZM/fiFbYjmki0jj3rlVmFFJlIzaS5iwSs/VtFJNbRyRglztDC9YS8UyMvuGStx dV6UT/pDH9h/fTLH8AShog8ta7qmHxsDqDcGLbrINl8UJL8lueQG7MvohObc+mwFi6AOjI y2TKTj57PAzdYE9TOMZVuq7IYLn4B+xx9AC/vnivWmipZebh868edT7aZsFxBkQgGncHvD XnrjPUetCNshTNW6YCSXztrG+10iF0AXfStxxPbdYQambu8JVKYtlvFl+x1GTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713511431; 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=Vs7XEvuKSU7J1L/PaZkVPwVGUc5qwo0SE38PZBef8oM=; b=ahSgr8ykj9mUrc4Kv+GI/Mbv/K1rzpt4chjqqHZbQo+WaAIek/blszr907H8w5Cp4K36wR BY7/RuIzDNRyOSxVmVea+wCw0G5OPokPtx7HBbAjByqMXnmq6jKF+9lRcy7NgIxf4YAMaI HY8OoH7LiV0H7YM0owoGg0E8iJv85cfAEBrUL2X4Vfyq3TRWQAhGAgQdIxe+Rbj4xRBY7G 2P1fuuwHtluw7skNC28E0vuhncA4UCpyZv/0TKsA/KIhCJERMD+0q++vEwjJafBa9C0hgY z9YZfiJQdr8qA/IMcFUwYynQSM3L9jwYow2hHlTBq9KrrSgDmrJEtn3nZWF/nA== 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 4VLR2t6s0Pzkk2; Fri, 19 Apr 2024 07:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J7NoOB056096; Fri, 19 Apr 2024 07:23:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J7NomI056093; Fri, 19 Apr 2024 07:23:50 GMT (envelope-from git) Date: Fri, 19 Apr 2024 07:23:50 GMT Message-Id: <202404190723.43J7NomI056093@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Zhilin Subject: git: 792937105454 - stable/13 - snd_hda: Add the full Intel Meteor/Arrow/Lunar Lake HD Audio PCI IDs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mizhka X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 792937105454bed3bd23ff169fe2841265be095f Auto-Submitted: auto-generated The branch stable/13 has been updated by mizhka: URL: https://cgit.FreeBSD.org/src/commit/?id=792937105454bed3bd23ff169fe2841265be095f commit 792937105454bed3bd23ff169fe2841265be095f Author: Michael Zhilin AuthorDate: 2024-04-13 09:57:59 +0000 Commit: Michael Zhilin CommitDate: 2024-04-19 07:23:36 +0000 snd_hda: Add the full Intel Meteor/Arrow/Lunar Lake HD Audio PCI IDs This is based off the Linux file sound/hda/intel-dsp-config.c. Tested on: Lenovo Thinkbook 16 G6+ IMH MFC after: 3 days Reviewed by: markj, christos Differential Revision: https://reviews.freebsd.org/D44777 Sponsored by: Postgres Professional (cherry picked from commit 1dd1a696c58fb275aa0e01666d57861eeb51878d) --- sys/dev/sound/pci/hda/hdac.c | 4 ++++ sys/dev/sound/pci/hda/hdac.h | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index f5be149ae117..4d80bebb1195 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -120,6 +120,10 @@ static const struct { { HDA_INTEL_ALLKPS, "Intel Alder Lake-PS", 0, 0 }, { HDA_INTEL_RPTLK1, "Intel Raptor Lake-P", 0, 0 }, { HDA_INTEL_RPTLK2, "Intel Raptor Lake-P", 0, 0 }, + { HDA_INTEL_MTL, "Intel Meteor Lake-P", 0, 0 }, + { HDA_INTEL_ARLS, "Intel Arrow Lake-S", 0, 0 }, + { HDA_INTEL_ARL, "Intel Arrow Lake", 0, 0 }, + { HDA_INTEL_LNLP, "Intel Lunar Lake-P", 0, 0 }, { HDA_INTEL_82801F, "Intel 82801F", 0, 0 }, { HDA_INTEL_63XXESB, "Intel 631x/632xESB", 0, 0 }, { HDA_INTEL_82801G, "Intel 82801G", 0, 0 }, diff --git a/sys/dev/sound/pci/hda/hdac.h b/sys/dev/sound/pci/hda/hdac.h index bcda5d563524..5079811d6f84 100644 --- a/sys/dev/sound/pci/hda/hdac.h +++ b/sys/dev/sound/pci/hda/hdac.h @@ -98,6 +98,10 @@ #define HDA_INTEL_CMLKLP HDA_MODEL_CONSTRUCT(INTEL, 0x02c8) #define HDA_INTEL_CMLKH HDA_MODEL_CONSTRUCT(INTEL, 0x06c8) #define HDA_INTEL_TGLK HDA_MODEL_CONSTRUCT(INTEL, 0xa0c8) +#define HDA_INTEL_MTL HDA_MODEL_CONSTRUCT(INTEL, 0x7e28) +#define HDA_INTEL_ARLS HDA_MODEL_CONSTRUCT(INTEL, 0x7f50) +#define HDA_INTEL_ARL HDA_MODEL_CONSTRUCT(INTEL, 0x7728) +#define HDA_INTEL_LNLP HDA_MODEL_CONSTRUCT(INTEL, 0xa828) #define INTEL_A100ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xa100) #define INTEL_D400ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xd400) #define INTEL_D401ID_SUBVENDOR HDA_MODEL_CONSTRUCT(INTEL, 0xd401) From nobody Fri Apr 19 07:23:52 2024 X-Original-To: dev-commits-src-branches@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 4VLR2w35Y1z5J1Xr; Fri, 19 Apr 2024 07:23:52 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLR2w1VK5z4WPj; Fri, 19 Apr 2024 07:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713511432; 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=AUcphNGBlNwXZAVDciqEIfVz9zkYLBXK3M872fsqmm0=; b=OfijNxtL46fM7VYojtc1Ax9h9oxVB4eG4Jri/OnXNCsWiinxiDGbhyBAp6B/ZVSLyWoWR/ ASEhRNUvpfjaFbnwfcd7JQqp8UKp+DgVG8ibnJXqL6JndSiKlxUF6GSQ1RTaEtCQXqo/Sb BKpjZWLxxYC2X0JPM14upwdsQhJiuyMGdIvtIhtVWwfGU0ApHgDEtdV4iRn++bx2xUj1Mk S0OQ6wQQfnGqgE197Tg3BkABGzS8hsxs+TFjcLXQU34fTm5PM5/rNloI6kSTRlRZUfRyMx CRasO3r363glvstE4qQPjci784NZ5Ikjh+VMUWju6ctDroGZqcBZQDBIt/YPmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713511432; a=rsa-sha256; cv=none; b=W7pZrNA8fgxlDrpLw8z62NiLzegQkVNb+0pMarw+ehvq62/8YzrOC6wXEpRg6658rEzTds N9ZhBE4Tvqy2ldUaaQDwI4+1IPhadzfOXWJcdl6SdocaGJ3IrNkzSEyZP+f+axbyZEmK4V z+KFzTXLUUm7TOvmrRvGLF50XVVRDczSgfuTwOJuy0cqWIsEbohfe8c41ktFuLZSrRCU8a zXwhQfmNQ1kEYNWBWnOmmjR6c6ItlukMd8u0Z8lwoliz7aepqipjk9erVIKFog8FCufkmO wWw+kZUQFAXOee9HLRaclR+cNrlMM4quMzcZknk33j4AyiIj+rTbpB64c4kU2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713511432; 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=AUcphNGBlNwXZAVDciqEIfVz9zkYLBXK3M872fsqmm0=; b=UoqRtNR7u/T/gipKOYaNfB23R5I9pUSidgryqj6NMwk22HiyiRX/Y5+lZVk+zu/4pshBuV 3NNp+omFjkpxUCfWknzPTvnh1ThKuSS7lmuo2knpmrEHKTQXluUCKdFfoOuO+HxnnfHZRr g6UjPg9fNq/tkvweqgeEbKijdq6+h2Afsbma7ew62SyWoQ9vXHx61SwuJxAZgJVgOgNDJs Ru6WA57TdfHcULvxl9YBPPItoZxX2mfAA1X3yATWTOtlTt9FWcjCJLVjYhsSQQQ7JoSnbB xMSsrd9Yw+JxbIiWoup2XSLHvCEckvm39taApjHxp3QQyDWE1xrae2vPWm1b2g== 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 4VLR2w0nfLzk9P; Fri, 19 Apr 2024 07:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43J7NqPG056144; Fri, 19 Apr 2024 07:23:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43J7NqIa056141; Fri, 19 Apr 2024 07:23:52 GMT (envelope-from git) Date: Fri, 19 Apr 2024 07:23:52 GMT Message-Id: <202404190723.43J7NqIa056141@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Zhilin Subject: git: e7a1904fe1ce - stable/13 - snd_hda: fix "duplicated free" on module unloading List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mizhka X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e7a1904fe1ced461b2a31f03b6592ae6564a243a Auto-Submitted: auto-generated The branch stable/13 has been updated by mizhka: URL: https://cgit.FreeBSD.org/src/commit/?id=e7a1904fe1ced461b2a31f03b6592ae6564a243a commit e7a1904fe1ced461b2a31f03b6592ae6564a243a Author: Michael Zhilin AuthorDate: 2024-04-13 09:59:24 +0000 Commit: Michael Zhilin CommitDate: 2024-04-19 07:23:36 +0000 snd_hda: fix "duplicated free" on module unloading This is trivial fix of hdacc_detach to avoid duplicated free on snd_hda unloading. The first try of detaching (kldunload) may results into "device busy" error, but codec->fgs is freed by detach. Second try attempts to free codec->fgs again and system panicks. Here is example: pcm0: unregister: channel pcm0:virtual:dsp0.vp0 busy (pid 3428) pulseaudio[3428] [oss] module-oss.c: DSP shutdown. pcm0: detached hdaa0: detached panic: Duplicate free of 0xfffff80412ee7d20 from zone 0xfffffe006bc0ba00 (malloc-32) slab 0xfffff80412ee7fc8(105) cpuid = 6 time = 1712999565 KDB: stack backtrace: db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe0202f859e0 vpanic() at vpanic+0x135/frame 0xfffffe0202f85b10 panic() at panic+0x43/frame 0xfffffe0202f85b70 uma_dbg_free() at uma_dbg_free+0x105/frame 0xfffffe0202f85b90 uma_zfree_arg() at uma_zfree_arg+0x95/frame 0xfffffe0202f85be0 free() at free+0xa1/frame 0xfffffe0202f85c20 hdacc_detach() at hdacc_detach+0x2f/frame 0xfffffe0202f85c40 device_detach() at device_detach+0x197/frame 0xfffffe0202f85c80 devclass_driver_deleted() at devclass_driver_deleted+0x66/frame 0xfffffe0202f85c devclass_delete_driver() at devclass_delete_driver+0x81/frame 0xfffffe0202f85d00 driver_module_handler() at driver_module_handler+0xff/frame 0xfffffe0202f85d50 module_unload() at module_unload+0x32/frame 0xfffffe0202f85d70 linker_file_unload() at linker_file_unload+0x1eb/frame 0xfffffe0202f85db0 kern_kldunload() at kern_kldunload+0x18e/frame 0xfffffe0202f85e00 amd64_syscall() at amd64_syscall+0x153/frame 0xfffffe0202f85f30 fast_syscall_common() at fast_syscall_common+0xf8/frame 0xfffffe0202f85f30 MFC after: 3 days Reviewed by: markj, christos Differential Revision: https://reviews.freebsd.org/D44778 Sponsored by: Postgres Professional (cherry picked from commit bed0b2146faa2e9a445d9f9196c7b46f50034631) --- sys/dev/sound/pci/hda/hdacc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/dev/sound/pci/hda/hdacc.c b/sys/dev/sound/pci/hda/hdacc.c index afcc145626e1..86c50a88f3e0 100644 --- a/sys/dev/sound/pci/hda/hdacc.c +++ b/sys/dev/sound/pci/hda/hdacc.c @@ -541,9 +541,10 @@ hdacc_detach(device_t dev) struct hdacc_softc *codec = device_get_softc(dev); int error; - error = device_delete_children(dev); + if ((error = device_delete_children(dev)) != 0) + return (error); free(codec->fgs, M_HDACC); - return (error); + return (0); } static int From nobody Sat Apr 20 10:31:53 2024 X-Original-To: dev-commits-src-branches@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 4VM79d3Xn0z5HWFT; Sat, 20 Apr 2024 10:32:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79d3GM5z4P7h; Sat, 20 Apr 2024 10:32:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609125; 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=7QDUPjWimYDJDRM7kB5hXv1SQcLfl7oPA4TrlJCKYJ8=; b=dm0lS5fK4FvuX5Fg78vPrfqYxYWVoeR1knG/QSDKWGXNjqKocdr2dqrGUN0nRMei2ssFTZ HUfznSebwyM1d1e9ndBpw+1lwfiN4PuTavpvM0+ZKJHFMxV8qJj+Kk6d47HDKri8W3sYGs GaVRKzjR/XU1f2JfVX/VjXX2x0dkjP0IX1XDH2HEYdPQzbMfflhS5HTzaK/UiW/41D1jZQ mpTso/7tssU2KoLNSAy9EaWrU/C4JHHZLvyxRzRJUZlQ3/BoD+kPu3ph6Dksp99m39GzIx frE16vAHcmeHav9K1CKKd+R+02A3g5XQB8k1Ke+4sJoOKrljtKZZ2O5M1c9EYQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609125; a=rsa-sha256; cv=none; b=AMUnMz+8+ibZL1N45Cm/nKj4jwIOskG7w4uUc2p1AH9hyKZ/RtEYP/isExR+nY6YJqw8n4 AngP9XvD/xw9YVlNw590cx5WlGMqmlmZQ0lxzHC9WCpElabz925Q0mRjufmh0aFVQwSyc0 3/f7YfdPGudspeIMMvI7niFFPDDjxmtGeuNUYHBNOPeB7cMkOQHx2hd7tnFwFFn6Qi5Oin wBJlINkioCRwCn1j/Xsr2ULuoDlMOWMIYqNsXHX0Hlb70p5bExe/uvnsJAnEYfK0UYOLnG PIV/OD+O1EEyfsV0aaPcmJ0NlkOdX+qt7j1STRr1zF8gLFL70b+H0ffpHX3Ecg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609125; 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=7QDUPjWimYDJDRM7kB5hXv1SQcLfl7oPA4TrlJCKYJ8=; b=mcagzxwayQnJnx+JHO2xf48V0XuGfQeQ0aKdG3KKfOMPxF/HsjKhO5XqTWi69zbkKA/S8l bHv7IarSQ5Fg11lGPqOd0SBr33cv8dD5LE4CykBm8iDORiKpVwml4BrLB9STyrYEQF5RLB yHIcrj6A7eqyGVwtArCv8Rwi+c+fGqoRD82hCa7Xb84FgyKfo2LAbHrOQiE8gy9MdLOcsC otL4gAsfvbiFAtJ77dNmo21putN3D1GLGTags5a1I6sNtXBcaGWuDMJbxlsSehJyZPKaO2 wyOV3l3khv045D1jRC6f23PJDUBX53szp+I3DoxeaNq3fRnfuVKUU2nfCkFt4g== 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 4VM79d2s2rzYTw; Sat, 20 Apr 2024 10:32:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAW5kV009312; Sat, 20 Apr 2024 10:32:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAVr53009284; Sat, 20 Apr 2024 10:31:53 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:31:53 GMT Message-Id: <202404201031.43KAVr53009284@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: c9157d925c48 - stable/14 - Merge llvm-project main llvmorg-18-init-15088-gd14ee76181fb List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: c9157d925c489f07ba9c0b2ce47e5149b75969a5 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=c9157d925c489f07ba9c0b2ce47e5149b75969a5 commit c9157d925c489f07ba9c0b2ce47e5149b75969a5 Author: Dimitry Andric AuthorDate: 2023-12-18 20:30:12 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:12:03 +0000 Merge llvm-project main llvmorg-18-init-15088-gd14ee76181fb This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-15088-gd14ee76181fb. PR: 276104 MFC after: 1 month (cherry picked from commit 5f757f3ff9144b609b3c433dfd370cc6bdc191ad) --- ObsoleteFiles.inc | 441 + contrib/llvm-project/FREEBSD-Xlist | 32 +- .../clang/include/clang-c/BuildSystem.h | 6 +- contrib/llvm-project/clang/include/clang-c/Index.h | 7 +- .../clang/include/clang/APINotes/APINotesManager.h | 175 + .../clang/include/clang/APINotes/APINotesOptions.h | 34 + .../clang/include/clang/APINotes/APINotesReader.h | 200 + .../clang/include/clang/APINotes/APINotesWriter.h | 110 + .../include/clang/APINotes/APINotesYAMLCompiler.h | 11 + .../clang/include/clang/APINotes/Types.h | 59 +- .../clang/include/clang/ARCMigrate/ARCMT.h | 2 +- .../clang/include/clang/ARCMigrate/FileRemapper.h | 16 +- .../llvm-project/clang/include/clang/AST/APValue.h | 8 + .../clang/include/clang/AST/ASTConcept.h | 116 +- .../clang/include/clang/AST/ASTContext.h | 69 +- .../llvm-project/clang/include/clang/AST/ASTFwd.h | 1 + .../clang/include/clang/AST/ASTLambda.h | 15 + .../clang/include/clang/AST/ASTNodeTraverser.h | 20 +- .../include/clang/AST/ASTStructuralEquivalence.h | 12 +- .../clang/include/clang/AST/ASTTypeTraits.h | 6 + .../llvm-project/clang/include/clang/AST/Attr.h | 11 +- .../clang/include/clang/AST/CXXInheritance.h | 2 +- .../llvm-project/clang/include/clang/AST/Comment.h | 286 +- .../clang/include/clang/AST/CommentSema.h | 3 +- .../clang/include/clang/AST/CommentVisitor.h | 5 +- .../llvm-project/clang/include/clang/AST/Decl.h | 218 +- .../clang/include/clang/AST/DeclBase.h | 188 +- .../llvm-project/clang/include/clang/AST/DeclCXX.h | 76 +- .../clang/include/clang/AST/DeclFriend.h | 1 + .../clang/include/clang/AST/DeclObjC.h | 49 +- .../clang/include/clang/AST/DeclOpenMP.h | 22 +- .../clang/include/clang/AST/DeclTemplate.h | 166 +- .../clang/include/clang/AST/DeclarationName.h | 3 +- .../clang/include/clang/AST/DependentDiagnostic.h | 2 + .../llvm-project/clang/include/clang/AST/Expr.h | 261 +- .../llvm-project/clang/include/clang/AST/ExprCXX.h | 111 +- .../clang/include/clang/AST/ExprConcepts.h | 91 +- .../clang/include/clang/AST/ExprObjC.h | 41 +- .../clang/include/clang/AST/JSONNodeDumper.h | 9 + .../llvm-project/clang/include/clang/AST/Mangle.h | 4 +- .../clang/include/clang/AST/OpenMPClause.h | 181 +- .../clang/include/clang/AST/OperationKinds.def | 1 + .../clang/include/clang/AST/PrettyPrinter.h | 40 +- .../clang/include/clang/AST/PropertiesBase.td | 4 +- .../clang/include/clang/AST/RawCommentList.h | 1 + .../clang/include/clang/AST/RecursiveASTVisitor.h | 90 +- .../llvm-project/clang/include/clang/AST/Stmt.h | 195 +- .../clang/include/clang/AST/StmtOpenMP.h | 77 +- .../clang/include/clang/AST/TemplateBase.h | 11 + .../clang/include/clang/AST/TemplateName.h | 2 +- .../clang/include/clang/AST/TextNodeDumper.h | 7 + .../llvm-project/clang/include/clang/AST/Type.h | 409 +- .../llvm-project/clang/include/clang/AST/TypeLoc.h | 111 +- .../clang/include/clang/AST/TypeProperties.td | 4 + .../clang/include/clang/AST/VTableBuilder.h | 2 +- .../clang/include/clang/ASTMatchers/ASTMatchers.h | 37 +- .../include/clang/Analysis/Analyses/Dominators.h | 2 +- .../clang/Analysis/Analyses/IntervalPartition.h | 109 +- .../include/clang/Analysis/Analyses/ThreadSafety.h | 8 +- .../clang/Analysis/Analyses/ThreadSafetyCommon.h | 2 +- .../clang/Analysis/Analyses/UnsafeBufferUsage.h | 65 +- .../Analysis/Analyses/UnsafeBufferUsageGadgets.def | 1 + .../clang/include/clang/Analysis/CFG.h | 39 +- .../clang/include/clang/Analysis/CFGStmtMap.h | 2 + .../include/clang/Analysis/FlowSensitive/Arena.h | 23 +- .../Analysis/FlowSensitive/ControlFlowContext.h | 14 +- .../Analysis/FlowSensitive/DataflowAnalysis.h | 84 +- .../FlowSensitive/DataflowAnalysisContext.h | 122 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 201 +- .../Analysis/FlowSensitive/DataflowWorklist.h | 26 +- .../include/clang/Analysis/FlowSensitive/Formula.h | 17 +- .../include/clang/Analysis/FlowSensitive/Logger.h | 4 +- .../clang/Analysis/FlowSensitive/MatchSwitch.h | 4 + .../Models/UncheckedOptionalAccessModel.h | 24 +- .../clang/Analysis/FlowSensitive/NoopAnalysis.h | 12 +- .../clang/Analysis/FlowSensitive/RecordOps.h | 38 +- .../Analysis/FlowSensitive/SimplifyConstraints.h | 49 + .../clang/Analysis/FlowSensitive/StorageLocation.h | 52 +- .../FlowSensitive/TypeErasedDataflowAnalysis.h | 19 - .../include/clang/Analysis/FlowSensitive/Value.h | 64 +- .../include/clang/Basic/AArch64SVEACLETypes.def | 2 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 298 +- .../clang/include/clang/Basic/AttrDocs.td | 769 +- .../include/clang/Basic/AttrSubjectMatchRules.h | 4 +- .../include/clang/Basic/AttributeCommonInfo.h | 30 +- .../clang/include/clang/Basic/Attributes.h | 4 +- .../clang/include/clang/Basic/Builtins.def | 52 +- .../clang/include/clang/Basic/BuiltinsAArch64.def | 17 +- .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 40 +- .../include/clang/Basic/BuiltinsLoongArch.def | 45 +- .../include/clang/Basic/BuiltinsLoongArchBase.def | 53 + .../include/clang/Basic/BuiltinsLoongArchLASX.def | 982 + .../include/clang/Basic/BuiltinsLoongArchLSX.def | 953 + .../clang/include/clang/Basic/BuiltinsNVPTX.def | 25 +- .../clang/include/clang/Basic/BuiltinsPPC.def | 3 + .../clang/include/clang/Basic/BuiltinsRISCV.def | 4 +- .../clang/include/clang/Basic/BuiltinsSystemZ.def | 46 +- .../clang/include/clang/Basic/BuiltinsX86.def | 852 +- .../clang/include/clang/Basic/BuiltinsX86_64.def | 3 + .../clang/include/clang/Basic/CodeGenOptions.def | 94 +- .../clang/include/clang/Basic/CodeGenOptions.h | 27 +- .../llvm-project/clang/include/clang/Basic/Cuda.h | 11 +- .../clang/include/clang/Basic/DebugOptions.def | 146 + .../clang/include/clang/Basic/DeclNodes.td | 1 - .../clang/include/clang/Basic/Diagnostic.h | 12 +- .../include/clang/Basic/DiagnosticASTKinds.td | 25 +- .../include/clang/Basic/DiagnosticCommonKinds.td | 57 +- .../include/clang/Basic/DiagnosticDriverKinds.td | 53 +- .../include/clang/Basic/DiagnosticFrontendKinds.td | 8 + .../clang/include/clang/Basic/DiagnosticGroups.td | 91 +- .../clang/include/clang/Basic/DiagnosticIDs.h | 8 +- .../include/clang/Basic/DiagnosticLexKinds.td | 50 +- .../clang/include/clang/Basic/DiagnosticOptions.h | 5 + .../include/clang/Basic/DiagnosticParseKinds.td | 78 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 342 +- .../clang/Basic/DiagnosticSerializationKinds.td | 7 +- .../clang/include/clang/Basic/DirectoryEntry.h | 74 - .../clang/include/clang/Basic/FPOptions.def | 4 +- .../clang/include/clang/Basic/Features.def | 7 +- .../clang/include/clang/Basic/FileEntry.h | 94 +- .../clang/include/clang/Basic/FileManager.h | 17 +- .../clang/include/clang/Basic/IdentifierTable.h | 306 +- .../clang/include/clang/Basic/JsonSupport.h | 2 +- .../clang/include/clang/Basic/LangOptions.def | 26 +- .../clang/include/clang/Basic/LangOptions.h | 32 +- .../clang/include/clang/Basic/LangStandard.h | 7 +- .../clang/include/clang/Basic/LangStandards.def | 18 +- .../clang/include/clang/Basic/Linkage.h | 54 +- .../clang/include/clang/Basic/Module.h | 61 +- .../clang/include/clang/Basic/ObjCRuntime.h | 4 +- .../clang/include/clang/Basic/OpenACCKinds.h | 74 + .../clang/include/clang/Basic/OpenMPKinds.def | 10 + .../clang/include/clang/Basic/OpenMPKinds.h | 12 + .../clang/include/clang/Basic/ParsedAttrInfo.h | 16 + .../clang/include/clang/Basic/PragmaKinds.h | 8 + .../clang/include/clang/Basic/RISCVVTypes.def | 91 +- .../clang/include/clang/Basic/Sanitizers.h | 6 +- .../clang/include/clang/Basic/SourceLocation.h | 5 +- .../clang/include/clang/Basic/SourceManager.h | 88 +- .../clang/include/clang/Basic/SourceMgrAdapter.h | 85 + .../clang/include/clang/Basic/Specifiers.h | 20 +- .../clang/include/clang/Basic/StmtNodes.td | 1 + .../clang/include/clang/Basic/SyncScope.h | 69 +- .../clang/include/clang/Basic/TargetBuiltins.h | 2 +- .../clang/include/clang/Basic/TargetInfo.h | 27 +- .../clang/include/clang/Basic/TargetOSMacros.def | 55 + .../clang/include/clang/Basic/TargetOptions.h | 16 +- .../clang/include/clang/Basic/TokenKinds.def | 55 +- .../clang/include/clang/Basic/Visibility.h | 28 +- .../clang/include/clang/Basic/arm_neon.td | 5 + .../clang/include/clang/Basic/arm_sme.td | 174 +- .../clang/include/clang/Basic/arm_sve.td | 442 +- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 13 +- .../include/clang/Basic/riscv_sifive_vector.td | 154 +- .../clang/include/clang/Basic/riscv_vector.td | 908 +- .../include/clang/Basic/riscv_vector_common.td | 467 + .../clang/include/clang/CodeGen/BackendUtil.h | 4 +- .../clang/include/clang/CodeGen/CGFunctionInfo.h | 5 + .../include/clang/CodeGen/ConstantInitBuilder.h | 7 +- .../clang/include/clang/Driver/ClangOptionDocs.td | 6 +- .../clang/include/clang/Driver/Distro.h | 3 +- .../clang/include/clang/Driver/Driver.h | 5 +- .../clang/include/clang/Driver/Multilib.h | 18 +- .../clang/include/clang/Driver/OffloadBundler.h | 39 +- .../clang/include/clang/Driver/Options.h | 40 +- .../clang/include/clang/Driver/Options.td | 3551 +- .../clang/include/clang/Driver/SanitizerArgs.h | 1 + .../clang/include/clang/Driver/ToolChain.h | 17 +- .../clang/include/clang/Driver/Types.def | 4 +- .../clang/include/clang/Driver/Types.h | 2 +- .../clang/include/clang/ExtractAPI/API.h | 811 +- .../clang/ExtractAPI/DeclarationFragments.h | 149 +- .../include/clang/ExtractAPI/ExtractAPIVisitor.h | 754 +- .../ExtractAPI/Serialization/SerializerBase.h | 190 + .../Serialization/SymbolGraphSerializer.h | 58 + .../clang/include/clang/Format/Format.h | 254 +- .../clang/include/clang/Frontend/ASTUnit.h | 31 +- .../include/clang/Frontend/CompilerInstance.h | 103 +- .../include/clang/Frontend/CompilerInvocation.h | 325 +- .../clang/Frontend/DependencyOutputOptions.h | 6 + .../clang/include/clang/Frontend/FrontendActions.h | 3 + .../clang/include/clang/Frontend/FrontendOptions.h | 50 +- .../clang/include/clang/Frontend/MigratorOptions.h | 4 + .../clang/Frontend/PreprocessorOutputOptions.h | 16 + .../include/clang/Frontend/TextDiagnosticPrinter.h | 1 + .../clang/Frontend/VerifyDiagnosticConsumer.h | 163 +- .../SerializablePathCollection.h | 2 +- .../include/clang/Interpreter/CodeCompletion.h | 30 + .../clang/include/clang/Lex/DirectoryLookup.h | 4 + .../clang/include/clang/Lex/HeaderMap.h | 3 +- .../clang/include/clang/Lex/HeaderSearch.h | 62 +- .../clang/include/clang/Lex/HeaderSearchOptions.h | 54 +- .../llvm-project/clang/include/clang/Lex/Lexer.h | 38 +- .../clang/include/clang/Lex/LiteralSupport.h | 11 +- .../clang/include/clang/Lex/MacroInfo.h | 3 + .../clang/include/clang/Lex/ModuleMap.h | 58 +- .../clang/include/clang/Lex/PPCallbacks.h | 10 +- .../clang/include/clang/Lex/PreprocessingRecord.h | 3 + .../clang/include/clang/Lex/Preprocessor.h | 84 +- .../clang/include/clang/Lex/PreprocessorLexer.h | 2 +- .../clang/include/clang/Lex/PreprocessorOptions.h | 3 + .../clang/include/clang/Lex/VariadicMacroSupport.h | 5 + .../clang/include/clang/Parse/LoopHint.h | 6 +- .../clang/include/clang/Parse/Parser.h | 84 +- .../include/clang/Parse/RAIIObjectsForParser.h | 19 + .../include/clang/Sema/CodeCompleteConsumer.h | 7 +- .../clang/include/clang/Sema/DeclSpec.h | 13 +- .../include/clang/Sema/HLSLExternalSemaSource.h | 4 +- .../clang/include/clang/Sema/IdentifierResolver.h | 3 + .../llvm-project/clang/include/clang/Sema/Lookup.h | 67 +- .../clang/include/clang/Sema/Overload.h | 8 +- .../clang/include/clang/Sema/Ownership.h | 276 +- .../clang/include/clang/Sema/ParsedAttr.h | 15 + .../clang/include/clang/Sema/ScopeInfo.h | 14 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 562 +- .../clang/include/clang/Sema/Template.h | 6 +- .../clang/include/clang/Sema/TypoCorrection.h | 12 +- .../include/clang/Serialization/ASTBitCodes.h | 19 +- .../clang/include/clang/Serialization/ASTReader.h | 95 +- .../include/clang/Serialization/ASTRecordReader.h | 9 +- .../include/clang/Serialization/ASTRecordWriter.h | 3 + .../clang/include/clang/Serialization/ASTWriter.h | 82 +- .../clang/Serialization/GlobalModuleIndex.h | 8 +- .../clang/include/clang/Serialization/ModuleFile.h | 20 +- .../clang/Serialization/ModuleFileExtension.h | 3 +- .../clang/StaticAnalyzer/Checkers/Checkers.td | 139 +- .../clang/StaticAnalyzer/Checkers/SValExplainer.h | 10 +- .../clang/StaticAnalyzer/Core/AnalyzerOptions.h | 4 +- .../StaticAnalyzer/Core/BugReporter/BugReporter.h | 5 +- .../Core/BugReporter/BugSuppression.h | 53 + .../StaticAnalyzer/Core/BugReporter/BugType.h | 33 +- .../include/clang/StaticAnalyzer/Core/Checker.h | 4 +- .../StaticAnalyzer/Core/PathSensitive/CallEvent.h | 99 +- .../Core/PathSensitive/ConstraintManager.h | 16 + .../Core/PathSensitive/DynamicExtent.h | 5 + .../Core/PathSensitive/DynamicType.h | 1 - .../Core/PathSensitive/SValBuilder.h | 17 + .../Core/PathSensitive/SValVisitor.h | 55 +- .../StaticAnalyzer/Core/PathSensitive/SVals.def | 38 +- .../StaticAnalyzer/Core/PathSensitive/SVals.h | 226 +- .../include/clang/Support/RISCVVIntrinsicUtils.h | 53 +- .../DependencyScanningFilesystem.h | 2 +- .../DependencyScanning/DependencyScanningService.h | 26 +- .../DependencyScanning/DependencyScanningTool.h | 37 +- .../DependencyScanning/DependencyScanningWorker.h | 4 +- .../DependencyScanning/ModuleDepCollector.h | 59 +- .../clang/Tooling/Inclusions/HeaderAnalysis.h | 4 +- .../clang/include/clang/Tooling/Tooling.h | 3 + .../include/clang/Tooling/Transformer/SourceCode.h | 6 + .../llvm-project/clang/include/module.modulemap | 4 + .../clang/lib/APINotes/APINotesFormat.h | 92 +- .../clang/lib/APINotes/APINotesManager.cpp | 458 + .../clang/lib/APINotes/APINotesReader.cpp | 2049 + .../clang/lib/APINotes/APINotesWriter.cpp | 1384 + .../clang/lib/APINotes/APINotesYAMLCompiler.cpp | 521 +- .../llvm-project/clang/lib/ARCMigrate/ARCMT.cpp | 27 +- .../clang/lib/ARCMigrate/FileRemapper.cpp | 107 +- .../llvm-project/clang/lib/ARCMigrate/ObjCMT.cpp | 22 +- .../clang/lib/ARCMigrate/PlistReporter.cpp | 2 +- .../clang/lib/ARCMigrate/TransAutoreleasePool.cpp | 4 +- .../clang/lib/ARCMigrate/TransUnbridgedCasts.cpp | 2 +- .../clang/lib/ARCMigrate/TransformActions.cpp | 2 +- .../clang/lib/ARCMigrate/Transforms.cpp | 2 +- contrib/llvm-project/clang/lib/AST/APValue.cpp | 18 +- contrib/llvm-project/clang/lib/AST/ASTConcept.cpp | 29 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 706 +- .../llvm-project/clang/lib/AST/ASTDiagnostic.cpp | 1 + contrib/llvm-project/clang/lib/AST/ASTDumper.cpp | 15 + contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 468 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 49 +- .../llvm-project/clang/lib/AST/ASTTypeTraits.cpp | 8 + contrib/llvm-project/clang/lib/AST/Comment.cpp | 30 +- contrib/llvm-project/clang/lib/AST/CommentSema.cpp | 52 +- .../clang/lib/AST/ComputeDependence.cpp | 9 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 252 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 89 +- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 100 +- contrib/llvm-project/clang/lib/AST/DeclObjC.cpp | 14 +- contrib/llvm-project/clang/lib/AST/DeclOpenMP.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclPrinter.cpp | 196 +- .../llvm-project/clang/lib/AST/DeclTemplate.cpp | 38 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 355 +- contrib/llvm-project/clang/lib/AST/ExprCXX.cpp | 65 +- .../clang/lib/AST/ExprClassification.cpp | 18 +- .../llvm-project/clang/lib/AST/ExprConcepts.cpp | 83 +- .../llvm-project/clang/lib/AST/ExprConstShared.h | 59 + .../llvm-project/clang/lib/AST/ExprConstant.cpp | 747 +- .../llvm-project/clang/lib/AST/FormatString.cpp | 32 +- .../llvm-project/clang/lib/AST/Interp/Boolean.h | 12 +- .../clang/lib/AST/Interp/ByteCodeEmitter.cpp | 104 +- .../clang/lib/AST/Interp/ByteCodeEmitter.h | 13 +- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 2144 +- .../clang/lib/AST/Interp/ByteCodeExprGen.h | 102 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.cpp | 110 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.h | 9 +- .../llvm-project/clang/lib/AST/Interp/Context.cpp | 69 +- .../llvm-project/clang/lib/AST/Interp/Context.h | 15 +- .../clang/lib/AST/Interp/Descriptor.cpp | 128 +- .../llvm-project/clang/lib/AST/Interp/Descriptor.h | 56 +- .../llvm-project/clang/lib/AST/Interp/Disasm.cpp | 6 + .../clang/lib/AST/Interp/EvalEmitter.cpp | 49 +- .../clang/lib/AST/Interp/EvalEmitter.h | 17 +- .../llvm-project/clang/lib/AST/Interp/Floating.h | 62 +- contrib/llvm-project/clang/lib/AST/Interp/Frame.h | 2 +- .../llvm-project/clang/lib/AST/Interp/Function.cpp | 10 +- .../llvm-project/clang/lib/AST/Interp/Function.h | 39 +- .../llvm-project/clang/lib/AST/Interp/Integral.h | 22 +- .../llvm-project/clang/lib/AST/Interp/IntegralAP.h | 291 + .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 144 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 429 +- .../clang/lib/AST/Interp/InterpBlock.h | 37 +- .../clang/lib/AST/Interp/InterpBuiltin.cpp | 861 +- .../clang/lib/AST/Interp/InterpFrame.cpp | 27 +- .../clang/lib/AST/Interp/InterpFrame.h | 5 +- .../clang/lib/AST/Interp/InterpStack.cpp | 20 +- .../clang/lib/AST/Interp/InterpStack.h | 5 + .../clang/lib/AST/Interp/InterpState.cpp | 14 +- .../clang/lib/AST/Interp/InterpState.h | 3 + .../llvm-project/clang/lib/AST/Interp/Opcodes.td | 96 +- .../llvm-project/clang/lib/AST/Interp/Pointer.cpp | 83 +- .../llvm-project/clang/lib/AST/Interp/Pointer.h | 140 +- .../llvm-project/clang/lib/AST/Interp/PrimType.cpp | 1 + .../llvm-project/clang/lib/AST/Interp/PrimType.h | 47 +- .../llvm-project/clang/lib/AST/Interp/Program.cpp | 31 +- .../llvm-project/clang/lib/AST/Interp/Program.h | 8 +- contrib/llvm-project/clang/lib/AST/Interp/Record.h | 6 +- .../llvm-project/clang/lib/AST/Interp/Source.cpp | 14 + contrib/llvm-project/clang/lib/AST/Interp/Source.h | 11 +- .../llvm-project/clang/lib/AST/Interp/State.cpp | 10 +- contrib/llvm-project/clang/lib/AST/Interp/State.h | 4 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 782 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 122 +- contrib/llvm-project/clang/lib/AST/Mangle.cpp | 12 +- .../llvm-project/clang/lib/AST/MicrosoftCXXABI.cpp | 10 +- .../llvm-project/clang/lib/AST/MicrosoftMangle.cpp | 149 +- .../llvm-project/clang/lib/AST/ODRDiagsEmitter.cpp | 6 +- contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 75 +- .../llvm-project/clang/lib/AST/OpenMPClause.cpp | 57 +- .../clang/lib/AST/PrintfFormatString.cpp | 2 +- .../llvm-project/clang/lib/AST/QualTypeNames.cpp | 4 +- .../llvm-project/clang/lib/AST/RawCommentList.cpp | 4 +- .../clang/lib/AST/RecordLayoutBuilder.cpp | 91 +- .../clang/lib/AST/ScanfFormatString.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Stmt.cpp | 7 +- contrib/llvm-project/clang/lib/AST/StmtOpenMP.cpp | 34 +- contrib/llvm-project/clang/lib/AST/StmtPrinter.cpp | 24 +- contrib/llvm-project/clang/lib/AST/StmtProfile.cpp | 27 +- .../llvm-project/clang/lib/AST/TemplateBase.cpp | 15 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 245 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 268 +- contrib/llvm-project/clang/lib/AST/TypeLoc.cpp | 45 +- contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 86 +- .../llvm-project/clang/lib/AST/VTableBuilder.cpp | 37 +- .../clang/lib/ASTMatchers/ASTMatchFinder.cpp | 28 +- .../clang/lib/ASTMatchers/ASTMatchersInternal.cpp | 18 +- .../clang/lib/ASTMatchers/Dynamic/Parser.cpp | 6 +- .../clang/lib/ASTMatchers/Dynamic/Registry.cpp | 3 + .../clang/lib/ASTMatchers/GtestMatchers.cpp | 1 - .../llvm-project/clang/lib/Analysis/BodyFarm.cpp | 6 +- contrib/llvm-project/clang/lib/Analysis/CFG.cpp | 78 +- .../llvm-project/clang/lib/Analysis/CallGraph.cpp | 2 +- .../clang/lib/Analysis/CalledOnceCheck.cpp | 2 +- .../clang/lib/Analysis/CocoaConventions.cpp | 11 +- .../llvm-project/clang/lib/Analysis/Consumed.cpp | 4 +- .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 28 +- .../clang/lib/Analysis/FlowSensitive/Arena.cpp | 195 +- .../Analysis/FlowSensitive/ControlFlowContext.cpp | 20 +- .../FlowSensitive/DataflowAnalysisContext.cpp | 180 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 668 +- .../lib/Analysis/FlowSensitive/DebugSupport.cpp | 6 +- .../clang/lib/Analysis/FlowSensitive/Formula.cpp | 18 +- .../lib/Analysis/FlowSensitive/HTMLLogger.cpp | 131 +- .../lib/Analysis/FlowSensitive/HTMLLogger.css | 27 +- .../lib/Analysis/FlowSensitive/HTMLLogger.html | 23 +- .../clang/lib/Analysis/FlowSensitive/Logger.cpp | 19 +- .../FlowSensitive/Models/ChromiumCheckModel.cpp | 4 +- .../Models/UncheckedOptionalAccessModel.cpp | 481 +- .../clang/lib/Analysis/FlowSensitive/RecordOps.cpp | 72 +- .../Analysis/FlowSensitive/SimplifyConstraints.cpp | 180 + .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 303 +- .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 129 +- .../clang/lib/Analysis/FlowSensitive/Value.cpp | 28 +- .../FlowSensitive/WatchedLiteralsSolver.cpp | 216 +- .../clang/lib/Analysis/IntervalPartition.cpp | 215 +- .../clang/lib/Analysis/PathDiagnostic.cpp | 8 +- .../clang/lib/Analysis/RetainSummaryManager.cpp | 69 +- .../clang/lib/Analysis/ThreadSafety.cpp | 259 +- .../clang/lib/Analysis/ThreadSafetyCommon.cpp | 23 +- .../clang/lib/Analysis/UninitializedValues.cpp | 2 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 1038 +- .../llvm-project/clang/lib/Basic/Attributes.cpp | 28 +- .../clang/lib/Basic/CodeGenOptions.cpp | 35 + contrib/llvm-project/clang/lib/Basic/Cuda.cpp | 7 + .../llvm-project/clang/lib/Basic/Diagnostic.cpp | 11 +- .../llvm-project/clang/lib/Basic/DiagnosticIDs.cpp | 2 +- .../llvm-project/clang/lib/Basic/FileManager.cpp | 87 +- .../clang/lib/Basic/IdentifierTable.cpp | 82 +- .../llvm-project/clang/lib/Basic/LangOptions.cpp | 6 +- .../llvm-project/clang/lib/Basic/LangStandards.cpp | 33 + contrib/llvm-project/clang/lib/Basic/Module.cpp | 51 +- .../llvm-project/clang/lib/Basic/OpenMPKinds.cpp | 25 + .../llvm-project/clang/lib/Basic/ProfileList.cpp | 4 +- .../clang/lib/Basic/SanitizerSpecialCaseList.cpp | 3 +- contrib/llvm-project/clang/lib/Basic/Sarif.cpp | 17 +- .../clang/lib/Basic/SourceLocation.cpp | 5 + .../llvm-project/clang/lib/Basic/SourceManager.cpp | 317 +- .../clang/lib/Basic/SourceMgrAdapter.cpp | 136 + .../llvm-project/clang/lib/Basic/TargetInfo.cpp | 10 +- contrib/llvm-project/clang/lib/Basic/Targets.cpp | 48 +- .../clang/lib/Basic/Targets/AArch64.cpp | 72 +- .../llvm-project/clang/lib/Basic/Targets/AArch64.h | 3 + .../clang/lib/Basic/Targets/AMDGPU.cpp | 91 +- .../llvm-project/clang/lib/Basic/Targets/AMDGPU.h | 19 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 4 +- .../llvm-project/clang/lib/Basic/Targets/BPF.cpp | 33 +- contrib/llvm-project/clang/lib/Basic/Targets/BPF.h | 2 +- .../clang/lib/Basic/Targets/LoongArch.cpp | 12 +- .../clang/lib/Basic/Targets/LoongArch.h | 5 + .../llvm-project/clang/lib/Basic/Targets/M68k.cpp | 34 +- .../llvm-project/clang/lib/Basic/Targets/M68k.h | 1 + .../llvm-project/clang/lib/Basic/Targets/Mips.cpp | 6 +- .../llvm-project/clang/lib/Basic/Targets/Mips.h | 13 + .../llvm-project/clang/lib/Basic/Targets/NVPTX.cpp | 7 +- .../llvm-project/clang/lib/Basic/Targets/NVPTX.h | 2 + .../clang/lib/Basic/Targets/OSTargets.cpp | 3 + .../clang/lib/Basic/Targets/OSTargets.h | 57 +- .../llvm-project/clang/lib/Basic/Targets/PPC.cpp | 31 +- contrib/llvm-project/clang/lib/Basic/Targets/PPC.h | 3 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 164 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 10 + .../llvm-project/clang/lib/Basic/Targets/SPIR.cpp | 11 +- .../llvm-project/clang/lib/Basic/Targets/SPIR.h | 54 +- .../llvm-project/clang/lib/Basic/Targets/Sparc.cpp | 76 +- .../llvm-project/clang/lib/Basic/Targets/SystemZ.h | 2 +- .../clang/lib/Basic/Targets/WebAssembly.cpp | 12 + .../clang/lib/Basic/Targets/WebAssembly.h | 1 + .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 140 +- contrib/llvm-project/clang/lib/Basic/Targets/X86.h | 53 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 8 +- .../clang/lib/CodeGen/BackendConsumer.h | 166 + .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 227 +- .../llvm-project/clang/lib/CodeGen/CGAtomic.cpp | 308 +- .../llvm-project/clang/lib/CodeGen/CGBlocks.cpp | 100 +- contrib/llvm-project/clang/lib/CodeGen/CGBuilder.h | 17 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 1850 +- .../llvm-project/clang/lib/CodeGen/CGCUDANV.cpp | 173 +- .../llvm-project/clang/lib/CodeGen/CGCUDARuntime.h | 14 +- .../llvm-project/clang/lib/CodeGen/CGCXXABI.cpp | 8 +- contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 168 +- contrib/llvm-project/clang/lib/CodeGen/CGCall.h | 36 +- contrib/llvm-project/clang/lib/CodeGen/CGClass.cpp | 55 +- .../llvm-project/clang/lib/CodeGen/CGCleanup.cpp | 14 +- .../llvm-project/clang/lib/CodeGen/CGCoroutine.cpp | 95 +- .../llvm-project/clang/lib/CodeGen/CGDebugInfo.cpp | 154 +- .../llvm-project/clang/lib/CodeGen/CGDebugInfo.h | 14 +- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 62 +- .../llvm-project/clang/lib/CodeGen/CGDeclCXX.cpp | 53 +- .../llvm-project/clang/lib/CodeGen/CGException.cpp | 75 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 385 +- .../llvm-project/clang/lib/CodeGen/CGExprCXX.cpp | 43 +- .../clang/lib/CodeGen/CGExprComplex.cpp | 170 +- .../clang/lib/CodeGen/CGExprConstant.cpp | 73 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 80 +- .../clang/lib/CodeGen/CGGPUBuiltin.cpp | 15 +- .../clang/lib/CodeGen/CGHLSLRuntime.cpp | 66 +- .../llvm-project/clang/lib/CodeGen/CGHLSLRuntime.h | 2 +- .../llvm-project/clang/lib/CodeGen/CGLoopInfo.cpp | 24 +- .../llvm-project/clang/lib/CodeGen/CGLoopInfo.h | 6 + .../clang/lib/CodeGen/CGNonTrivialStruct.cpp | 4 +- contrib/llvm-project/clang/lib/CodeGen/CGObjC.cpp | 37 +- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 186 +- .../llvm-project/clang/lib/CodeGen/CGObjCMac.cpp | 149 +- .../clang/lib/CodeGen/CGObjCRuntime.cpp | 4 +- .../clang/lib/CodeGen/CGOpenCLRuntime.cpp | 50 +- .../clang/lib/CodeGen/CGOpenCLRuntime.h | 3 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 1169 +- .../clang/lib/CodeGen/CGOpenMPRuntime.h | 77 +- .../clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp | 517 +- .../clang/lib/CodeGen/CGOpenMPRuntimeGPU.h | 40 +- .../clang/lib/CodeGen/CGRecordLayoutBuilder.cpp | 13 +- contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 46 +- .../clang/lib/CodeGen/CGStmtOpenMP.cpp | 44 +- contrib/llvm-project/clang/lib/CodeGen/CGVTT.cpp | 5 + .../llvm-project/clang/lib/CodeGen/CGVTables.cpp | 82 +- .../clang/lib/CodeGen/CodeGenAction.cpp | 671 +- .../clang/lib/CodeGen/CodeGenFunction.cpp | 89 +- .../clang/lib/CodeGen/CodeGenFunction.h | 52 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 460 +- .../llvm-project/clang/lib/CodeGen/CodeGenModule.h | 100 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 21 +- .../llvm-project/clang/lib/CodeGen/CodeGenTBAA.cpp | 33 +- .../clang/lib/CodeGen/CodeGenTypeCache.h | 7 +- .../clang/lib/CodeGen/CodeGenTypes.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/CodeGenTypes.h | 4 + .../clang/lib/CodeGen/CoverageMappingGen.cpp | 32 +- .../clang/lib/CodeGen/CoverageMappingGen.h | 4 +- .../llvm-project/clang/lib/CodeGen/EHScopeStack.h | 4 +- .../clang/lib/CodeGen/ItaniumCXXABI.cpp | 120 +- .../clang/lib/CodeGen/LinkInModulesPass.cpp | 29 + .../clang/lib/CodeGen/LinkInModulesPass.h | 42 + .../clang/lib/CodeGen/MicrosoftCXXABI.cpp | 100 +- .../CodeGen/ObjectFilePCHContainerOperations.cpp | 3 + .../clang/lib/CodeGen/SwiftCallingConv.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.cpp | 2 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.h | 3 + .../clang/lib/CodeGen/Targets/AArch64.cpp | 19 +- .../clang/lib/CodeGen/Targets/AMDGPU.cpp | 159 +- .../clang/lib/CodeGen/Targets/LoongArch.cpp | 24 +- .../clang/lib/CodeGen/Targets/NVPTX.cpp | 71 +- .../llvm-project/clang/lib/CodeGen/Targets/PPC.cpp | 23 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 4 +- .../clang/lib/CodeGen/Targets/SPIR.cpp | 6 +- .../clang/lib/CodeGen/Targets/Sparc.cpp | 2 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 58 +- .../clang/lib/CodeGen/Targets/XCore.cpp | 2 +- .../clang/lib/CrossTU/CrossTranslationUnit.cpp | 10 +- .../linux/DirectoryWatcher-linux.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Distro.cpp | 15 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 316 +- .../clang/lib/Driver/DriverOptions.cpp | 5 +- contrib/llvm-project/clang/lib/Driver/Job.cpp | 8 +- contrib/llvm-project/clang/lib/Driver/Multilib.cpp | 116 +- .../clang/lib/Driver/OffloadBundler.cpp | 591 +- .../clang/lib/Driver/SanitizerArgs.cpp | 2 + .../llvm-project/clang/lib/Driver/ToolChain.cpp | 112 +- .../clang/lib/Driver/ToolChains/AIX.cpp | 31 +- .../llvm-project/clang/lib/Driver/ToolChains/AIX.h | 6 +- .../clang/lib/Driver/ToolChains/AMDGPU.cpp | 82 +- .../clang/lib/Driver/ToolChains/AMDGPU.h | 2 +- .../clang/lib/Driver/ToolChains/AVR.cpp | 61 +- .../llvm-project/clang/lib/Driver/ToolChains/AVR.h | 2 +- .../clang/lib/Driver/ToolChains/Ananas.cpp | 148 - .../clang/lib/Driver/ToolChains/Ananas.h | 65 - .../clang/lib/Driver/ToolChains/Arch/AArch64.cpp | 17 +- .../clang/lib/Driver/ToolChains/Arch/ARM.cpp | 35 +- .../clang/lib/Driver/ToolChains/Arch/LoongArch.cpp | 32 + .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 11 +- .../clang/lib/Driver/ToolChains/Arch/Sparc.cpp | 4 - .../clang/lib/Driver/ToolChains/Arch/VE.cpp | 7 +- .../clang/lib/Driver/ToolChains/Arch/X86.cpp | 42 +- .../clang/lib/Driver/ToolChains/BareMetal.cpp | 31 +- .../clang/lib/Driver/ToolChains/BareMetal.h | 3 +- .../clang/lib/Driver/ToolChains/CSKYToolChain.cpp | 5 +- .../clang/lib/Driver/ToolChains/CSKYToolChain.h | 2 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 845 +- .../clang/lib/Driver/ToolChains/Clang.h | 4 +- .../clang/lib/Driver/ToolChains/CloudABI.cpp | 151 - .../clang/lib/Driver/ToolChains/CloudABI.h | 70 - .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 400 +- .../clang/lib/Driver/ToolChains/CommonArgs.h | 34 +- .../clang/lib/Driver/ToolChains/Contiki.cpp | 27 - .../clang/lib/Driver/ToolChains/Contiki.h | 39 - .../clang/lib/Driver/ToolChains/CrossWindows.h | 4 +- .../clang/lib/Driver/ToolChains/Cuda.cpp | 21 +- .../clang/lib/Driver/ToolChains/Cuda.h | 6 +- .../clang/lib/Driver/ToolChains/Darwin.cpp | 133 +- .../clang/lib/Driver/ToolChains/DragonFly.cpp | 152 +- .../clang/lib/Driver/ToolChains/DragonFly.h | 14 +- .../clang/lib/Driver/ToolChains/Flang.cpp | 263 +- .../clang/lib/Driver/ToolChains/Flang.h | 14 + .../clang/lib/Driver/ToolChains/FreeBSD.cpp | 104 +- .../clang/lib/Driver/ToolChains/FreeBSD.h | 12 +- .../clang/lib/Driver/ToolChains/Fuchsia.cpp | 23 +- .../clang/lib/Driver/ToolChains/Fuchsia.h | 2 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 269 +- .../llvm-project/clang/lib/Driver/ToolChains/Gnu.h | 3 +- .../clang/lib/Driver/ToolChains/HIPAMD.cpp | 16 +- .../clang/lib/Driver/ToolChains/HIPAMD.h | 2 +- .../clang/lib/Driver/ToolChains/HIPSPV.cpp | 4 - .../clang/lib/Driver/ToolChains/HIPSPV.h | 2 +- .../clang/lib/Driver/ToolChains/HIPUtility.cpp | 8 + .../clang/lib/Driver/ToolChains/HLSL.cpp | 8 - .../clang/lib/Driver/ToolChains/Haiku.cpp | 257 +- .../clang/lib/Driver/ToolChains/Haiku.h | 40 +- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 24 +- .../clang/lib/Driver/ToolChains/Hexagon.h | 4 +- .../clang/lib/Driver/ToolChains/Hurd.cpp | 4 +- .../clang/lib/Driver/ToolChains/Linux.cpp | 2 +- .../clang/lib/Driver/ToolChains/MSP430.cpp | 4 +- .../clang/lib/Driver/ToolChains/MSP430.h | 2 +- .../clang/lib/Driver/ToolChains/MSVC.cpp | 10 +- .../clang/lib/Driver/ToolChains/MSVC.h | 2 +- .../clang/lib/Driver/ToolChains/MinGW.cpp | 19 +- .../clang/lib/Driver/ToolChains/MinGW.h | 4 +- .../clang/lib/Driver/ToolChains/Minix.cpp | 116 - .../clang/lib/Driver/ToolChains/Minix.h | 64 - .../clang/lib/Driver/ToolChains/Myriad.cpp | 293 - .../clang/lib/Driver/ToolChains/Myriad.h | 103 - .../clang/lib/Driver/ToolChains/NaCl.cpp | 9 +- .../clang/lib/Driver/ToolChains/NaCl.h | 2 +- .../clang/lib/Driver/ToolChains/NetBSD.cpp | 150 +- .../clang/lib/Driver/ToolChains/NetBSD.h | 6 +- .../clang/lib/Driver/ToolChains/OpenBSD.cpp | 77 +- .../clang/lib/Driver/ToolChains/OpenBSD.h | 6 +- .../clang/lib/Driver/ToolChains/PPCLinux.cpp | 4 +- .../clang/lib/Driver/ToolChains/PS4CPU.cpp | 15 +- .../clang/lib/Driver/ToolChains/PS4CPU.h | 4 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.cpp | 9 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.h | 2 +- .../clang/lib/Driver/ToolChains/ROCm.h | 13 + .../clang/lib/Driver/ToolChains/SPIRV.h | 2 +- .../clang/lib/Driver/ToolChains/Solaris.cpp | 212 +- .../clang/lib/Driver/ToolChains/Solaris.h | 18 +- .../clang/lib/Driver/ToolChains/VEToolchain.cpp | 14 +- .../clang/lib/Driver/ToolChains/WebAssembly.cpp | 37 +- .../clang/lib/Driver/ToolChains/WebAssembly.h | 2 +- .../clang/lib/Driver/ToolChains/XCore.cpp | 3 +- .../clang/lib/Driver/ToolChains/XCore.h | 4 +- .../clang/lib/Driver/ToolChains/ZOS.cpp | 16 +- .../llvm-project/clang/lib/Driver/ToolChains/ZOS.h | 6 +- contrib/llvm-project/clang/lib/Driver/Types.cpp | 4 +- contrib/llvm-project/clang/lib/Edit/Commit.cpp | 2 +- .../clang/lib/Edit/RewriteObjCFoundationAPI.cpp | 8 +- contrib/llvm-project/clang/lib/ExtractAPI/API.cpp | 275 +- .../clang/lib/ExtractAPI/DeclarationFragments.cpp | 772 +- .../clang/lib/ExtractAPI/ExtractAPIConsumer.cpp | 27 +- .../Serialization/SymbolGraphSerializer.cpp | 470 +- .../clang/lib/Format/BreakableToken.cpp | 158 +- .../llvm-project/clang/lib/Format/BreakableToken.h | 44 + .../clang/lib/Format/ContinuationIndenter.cpp | 291 +- .../clang/lib/Format/ContinuationIndenter.h | 3 + .../clang/lib/Format/DefinitionBlockSeparator.cpp | 8 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 206 +- .../llvm-project/clang/lib/Format/FormatToken.cpp | 3 +- .../llvm-project/clang/lib/Format/FormatToken.h | 75 +- .../clang/lib/Format/FormatTokenLexer.cpp | 41 +- .../clang/lib/Format/FormatTokenSource.h | 2 +- .../clang/lib/Format/MacroCallReconstructor.cpp | 49 +- .../clang/lib/Format/MacroExpander.cpp | 4 +- .../clang/lib/Format/NamespaceEndCommentsFixer.cpp | 14 +- .../lib/Format/ObjCPropertyAttributeOrderFixer.cpp | 220 + .../lib/Format/ObjCPropertyAttributeOrderFixer.h | 51 + .../clang/lib/Format/QualifierAlignmentFixer.cpp | 30 +- .../clang/lib/Format/QualifierAlignmentFixer.h | 9 +- .../clang/lib/Format/SortJavaScriptImports.cpp | 18 +- .../clang/lib/Format/TokenAnnotator.cpp | 693 +- .../llvm-project/clang/lib/Format/TokenAnnotator.h | 17 + .../clang/lib/Format/UnwrappedLineFormatter.cpp | 88 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 335 +- .../clang/lib/Format/UnwrappedLineParser.h | 36 +- .../clang/lib/Format/WhitespaceManager.cpp | 334 +- .../clang/lib/Format/WhitespaceManager.h | 2 +- .../llvm-project/clang/lib/Frontend/ASTMerge.cpp | 2 +- .../llvm-project/clang/lib/Frontend/ASTUnit.cpp | 54 +- .../clang/lib/Frontend/CompilerInstance.cpp | 57 +- .../clang/lib/Frontend/CompilerInvocation.cpp | 1089 +- .../clang/lib/Frontend/DependencyFile.cpp | 2 +- .../clang/lib/Frontend/DependencyGraph.cpp | 2 +- .../clang/lib/Frontend/FrontendAction.cpp | 42 +- .../clang/lib/Frontend/FrontendActions.cpp | 33 +- .../clang/lib/Frontend/HeaderIncludeGen.cpp | 2 +- .../clang/lib/Frontend/InitPreprocessor.cpp | 47 +- .../clang/lib/Frontend/LogDiagnosticPrinter.cpp | 4 +- .../clang/lib/Frontend/PrecompiledPreamble.cpp | 18 +- .../clang/lib/Frontend/PrintPreprocessedOutput.cpp | 232 +- .../clang/lib/Frontend/Rewrite/FixItRewriter.cpp | 3 +- .../clang/lib/Frontend/Rewrite/HTMLPrint.cpp | 2 +- .../lib/Frontend/Rewrite/InclusionRewriter.cpp | 47 +- .../lib/Frontend/Rewrite/RewriteModernObjC.cpp | 45 +- .../clang/lib/Frontend/Rewrite/RewriteObjC.cpp | 36 +- .../clang/lib/Frontend/SARIFDiagnostic.cpp | 7 +- .../clang/lib/Frontend/TextDiagnostic.cpp | 9 +- .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 47 +- .../lib/FrontendTool/ExecuteCompilerInvocation.cpp | 6 +- .../lib/Headers/__clang_cuda_device_functions.h | 4 +- .../lib/Headers/__clang_cuda_libdevice_declares.h | 4 +- .../clang/lib/Headers/__clang_cuda_math.h | 4 +- .../lib/Headers/__clang_cuda_runtime_wrapper.h | 4 +- .../clang/lib/Headers/__clang_hip_math.h | 363 +- .../lib/Headers/__clang_hip_runtime_wrapper.h | 60 +- .../clang/lib/Headers/__stdarg___gnuc_va_list.h | 13 + .../clang/lib/Headers/__stdarg___va_copy.h | 12 + .../clang/lib/Headers/__stdarg_va_arg.h | 22 + .../clang/lib/Headers/__stdarg_va_copy.h | 12 + .../clang/lib/Headers/__stdarg_va_list.h | 13 + .../clang/lib/Headers/__stddef_max_align_t.h | 2 +- .../llvm-project/clang/lib/Headers/__stddef_null.h | 29 + .../clang/lib/Headers/__stddef_nullptr_t.h | 24 + .../clang/lib/Headers/__stddef_offsetof.h | 12 + .../clang/lib/Headers/__stddef_ptrdiff_t.h | 15 + .../clang/lib/Headers/__stddef_rsize_t.h | 15 + .../clang/lib/Headers/__stddef_size_t.h | 15 + .../clang/lib/Headers/__stddef_unreachable.h | 12 + .../clang/lib/Headers/__stddef_wchar_t.h | 23 + .../clang/lib/Headers/__stddef_wint_t.h | 15 + contrib/llvm-project/clang/lib/Headers/altivec.h | 43 +- contrib/llvm-project/clang/lib/Headers/ammintrin.h | 8 +- contrib/llvm-project/clang/lib/Headers/arm_acle.h | 15 + .../llvm-project/clang/lib/Headers/avx2intrin.h | 27 +- .../clang/lib/Headers/avx512bf16intrin.h | 5 +- .../clang/lib/Headers/avx512bitalgintrin.h | 5 +- .../clang/lib/Headers/avx512bwintrin.h | 66 +- .../clang/lib/Headers/avx512cdintrin.h | 4 +- .../clang/lib/Headers/avx512dqintrin.h | 6 +- .../llvm-project/clang/lib/Headers/avx512fintrin.h | 10 +- .../clang/lib/Headers/avx512fp16intrin.h | 10 +- .../clang/lib/Headers/avx512ifmaintrin.h | 4 +- .../clang/lib/Headers/avx512ifmavlintrin.h | 10 +- .../clang/lib/Headers/avx512pfintrin.h | 5 - .../clang/lib/Headers/avx512vbmi2intrin.h | 2 +- .../clang/lib/Headers/avx512vbmiintrin.h | 5 +- .../clang/lib/Headers/avx512vbmivlintrin.h | 11 +- .../clang/lib/Headers/avx512vlbf16intrin.h | 14 +- .../clang/lib/Headers/avx512vlbitalgintrin.h | 10 +- .../clang/lib/Headers/avx512vlbwintrin.h | 10 +- .../clang/lib/Headers/avx512vlcdintrin.h | 11 +- .../clang/lib/Headers/avx512vldqintrin.h | 10 +- .../clang/lib/Headers/avx512vlfp16intrin.h | 4 +- .../clang/lib/Headers/avx512vlintrin.h | 10 +- .../clang/lib/Headers/avx512vlvbmi2intrin.h | 10 +- .../clang/lib/Headers/avx512vlvnniintrin.h | 10 +- .../clang/lib/Headers/avx512vlvp2intersectintrin.h | 10 +- .../clang/lib/Headers/avx512vnniintrin.h | 5 +- .../clang/lib/Headers/avx512vp2intersectintrin.h | 5 +- .../clang/lib/Headers/avx512vpopcntdqintrin.h | 4 +- .../clang/lib/Headers/avx512vpopcntdqvlintrin.h | 8 +- contrib/llvm-project/clang/lib/Headers/avxintrin.h | 14 +- contrib/llvm-project/clang/lib/Headers/bmiintrin.h | 22 +- contrib/llvm-project/clang/lib/Headers/emmintrin.h | 20 +- .../llvm-project/clang/lib/Headers/gfniintrin.h | 29 +- .../clang/lib/Headers/hlsl/hlsl_intrinsics.h | 722 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 4 +- contrib/llvm-project/clang/lib/Headers/intrin.h | 16 + .../llvm-project/clang/lib/Headers/lasxintrin.h | 3860 ++ contrib/llvm-project/clang/lib/Headers/limits.h | 6 +- .../clang/lib/Headers/llvm_libc_wrappers/assert.h | 34 + .../clang/lib/Headers/llvm_libc_wrappers/ctype.h | 17 + .../clang/lib/Headers/llvm_libc_wrappers/stdio.h | 18 + .../clang/lib/Headers/llvm_libc_wrappers/stdlib.h | 5 +- .../clang/lib/Headers/llvm_libc_wrappers/string.h | 65 +- .../clang/lib/Headers/llvm_libc_wrappers/time.h | 34 + contrib/llvm-project/clang/lib/Headers/lsxintrin.h | 3726 ++ contrib/llvm-project/clang/lib/Headers/mmintrin.h | 12 +- .../clang/lib/Headers/module.modulemap | 159 +- .../llvm-project/clang/lib/Headers/opencl-c-base.h | 5 + .../clang/lib/Headers/openmp_wrappers/cmath | 2 +- contrib/llvm-project/clang/lib/Headers/pmmintrin.h | 5 +- .../clang/lib/Headers/ppc_wrappers/smmintrin.h | 50 +- .../clang/lib/Headers/riscv_bitmanip.h | 179 + .../llvm-project/clang/lib/Headers/riscv_crypto.h | 170 + .../llvm-project/clang/lib/Headers/riscv_ntlh.h | 8 +- contrib/llvm-project/clang/lib/Headers/smmintrin.h | 6 +- contrib/llvm-project/clang/lib/Headers/stdalign.h | 4 +- contrib/llvm-project/clang/lib/Headers/stdarg.h | 90 +- contrib/llvm-project/clang/lib/Headers/stdatomic.h | 8 +- contrib/llvm-project/clang/lib/Headers/stdckdint.h | 42 + contrib/llvm-project/clang/lib/Headers/stddef.h | 166 +- contrib/llvm-project/clang/lib/Headers/stdint.h | 67 +- .../llvm-project/clang/lib/Headers/stdnoreturn.h | 4 +- contrib/llvm-project/clang/lib/Headers/tmmintrin.h | 9 +- .../llvm-project/clang/lib/Headers/usermsrintrin.h | 30 + .../llvm-project/clang/lib/Headers/vaesintrin.h | 6 +- contrib/llvm-project/clang/lib/Headers/vecintrin.h | 416 +- .../llvm-project/clang/lib/Headers/x86gprintrin.h | 5 + contrib/llvm-project/clang/lib/Headers/xmmintrin.h | 14 +- .../llvm-project/clang/lib/Index/CommentToXML.cpp | 54 +- contrib/llvm-project/clang/lib/Index/IndexBody.cpp | 29 +- .../llvm-project/clang/lib/Index/IndexSymbol.cpp | 33 +- .../clang/lib/Index/IndexingContext.cpp | 5 +- .../llvm-project/clang/lib/Index/IndexingContext.h | 2 +- .../llvm-project/clang/lib/Index/USRGeneration.cpp | 63 +- .../SerializablePathCollection.cpp | 10 +- .../clang/lib/Interpreter/CodeCompletion.cpp | 211 + .../clang/lib/Interpreter/DeviceOffload.cpp | 2 +- .../clang/lib/Interpreter/IncrementalExecutor.cpp | 10 +- .../clang/lib/Interpreter/IncrementalParser.cpp | 9 +- .../clang/lib/Interpreter/IncrementalParser.h | 4 +- .../clang/lib/Interpreter/Interpreter.cpp | 7 +- .../llvm-project/clang/lib/Interpreter/Value.cpp | 17 +- .../clang/lib/Lex/DependencyDirectivesScanner.cpp | 5 +- contrib/llvm-project/clang/lib/Lex/HeaderMap.cpp | 15 +- .../llvm-project/clang/lib/Lex/HeaderSearch.cpp | 170 +- .../clang/lib/Lex/InitHeaderSearch.cpp | 116 +- contrib/llvm-project/clang/lib/Lex/Lexer.cpp | 212 +- .../llvm-project/clang/lib/Lex/LiteralSupport.cpp | 33 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 162 +- contrib/llvm-project/clang/lib/Lex/PPCaching.cpp | 6 +- .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 134 +- .../llvm-project/clang/lib/Lex/PPExpressions.cpp | 10 +- .../llvm-project/clang/lib/Lex/PPLexerChange.cpp | 24 +- .../clang/lib/Lex/PPMacroExpansion.cpp | 24 +- contrib/llvm-project/clang/lib/Lex/Pragma.cpp | 8 +- .../llvm-project/clang/lib/Lex/Preprocessor.cpp | 129 +- .../clang/lib/Lex/PreprocessorLexer.cpp | 3 +- .../clang/lib/Parse/ParseCXXInlineMethods.cpp | 5 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 307 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 79 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 116 +- .../llvm-project/clang/lib/Parse/ParseExprCXX.cpp | 227 +- contrib/llvm-project/clang/lib/Parse/ParseInit.cpp | 8 +- contrib/llvm-project/clang/lib/Parse/ParseObjc.cpp | 64 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 527 + .../llvm-project/clang/lib/Parse/ParseOpenMP.cpp | 205 +- .../llvm-project/clang/lib/Parse/ParsePragma.cpp | 183 +- contrib/llvm-project/clang/lib/Parse/ParseStmt.cpp | 83 +- .../llvm-project/clang/lib/Parse/ParseTemplate.cpp | 15 +- .../clang/lib/Parse/ParseTentative.cpp | 31 + contrib/llvm-project/clang/lib/Parse/Parser.cpp | 70 +- .../llvm-project/clang/lib/Rewrite/Rewriter.cpp | 17 +- .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 133 +- .../clang/lib/Sema/CodeCompleteConsumer.cpp | 14 +- contrib/llvm-project/clang/lib/Sema/DeclSpec.cpp | 17 +- .../clang/lib/Sema/HLSLExternalSemaSource.cpp | 95 +- .../clang/lib/Sema/IdentifierResolver.cpp | 7 +- contrib/llvm-project/clang/lib/Sema/ParsedAttr.cpp | 13 +- contrib/llvm-project/clang/lib/Sema/ScopeInfo.cpp | 8 + contrib/llvm-project/clang/lib/Sema/Sema.cpp | 66 +- contrib/llvm-project/clang/lib/Sema/SemaAttr.cpp | 26 +- .../clang/lib/Sema/SemaAvailability.cpp | 23 + contrib/llvm-project/clang/lib/Sema/SemaCUDA.cpp | 95 +- .../clang/lib/Sema/SemaCXXScopeSpec.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaCast.cpp | 17 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 1239 +- .../clang/lib/Sema/SemaCodeComplete.cpp | 215 +- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 62 +- .../llvm-project/clang/lib/Sema/SemaCoroutine.cpp | 116 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 943 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 471 +- .../llvm-project/clang/lib/Sema/SemaDeclCXX.cpp | 846 +- .../llvm-project/clang/lib/Sema/SemaDeclObjC.cpp | 76 +- .../clang/lib/Sema/SemaExceptionSpec.cpp | 65 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 908 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 385 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 94 +- .../llvm-project/clang/lib/Sema/SemaExprObjC.cpp | 56 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 366 +- contrib/llvm-project/clang/lib/Sema/SemaLambda.cpp | 156 +- contrib/llvm-project/clang/lib/Sema/SemaLookup.cpp | 142 +- contrib/llvm-project/clang/lib/Sema/SemaModule.cpp | 74 +- .../clang/lib/Sema/SemaObjCProperty.cpp | 32 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 342 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 1399 +- .../clang/lib/Sema/SemaPseudoObject.cpp | 7 +- .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 71 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 33 +- .../llvm-project/clang/lib/Sema/SemaStmtAsm.cpp | 3 +- .../llvm-project/clang/lib/Sema/SemaStmtAttr.cpp | 103 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 492 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 222 +- .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 108 +- .../clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 253 +- .../clang/lib/Sema/SemaTemplateVariadic.cpp | 7 + contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 434 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 289 +- .../llvm-project/clang/lib/Sema/TypeLocBuilder.h | 3 + .../clang/lib/Serialization/ASTCommon.cpp | 1 - .../clang/lib/Serialization/ASTReader.cpp | 725 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 352 +- .../clang/lib/Serialization/ASTReaderInternals.h | 4 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 149 +- .../clang/lib/Serialization/ASTWriter.cpp | 446 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 606 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 84 +- .../clang/lib/Serialization/GeneratePCH.cpp | 12 +- .../clang/lib/Serialization/GlobalModuleIndex.cpp | 66 +- .../clang/lib/Serialization/ModuleManager.cpp | 64 +- .../clang/lib/Serialization/MultiOnDiskHashTable.h | 8 +- .../StaticAnalyzer/Checkers/ArrayBoundChecker.cpp | 10 +- .../Checkers/ArrayBoundCheckerV2.cpp | 464 +- .../Checkers/BasicObjCFoundationChecks.cpp | 12 +- .../Checkers/BitwiseShiftChecker.cpp | 370 + .../Checkers/BoolAssignmentChecker.cpp | 4 +- .../Checkers/BuiltinFunctionChecker.cpp | 28 +- .../lib/StaticAnalyzer/Checkers/CStringChecker.cpp | 97 +- .../StaticAnalyzer/Checkers/CXXDeleteChecker.cpp | 248 + .../Checkers/CallAndMessageChecker.cpp | 30 +- .../StaticAnalyzer/Checkers/CastSizeChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/CheckObjCDealloc.cpp | 4 +- .../Checkers/CheckSecuritySyntaxOnly.cpp | 115 +- .../lib/StaticAnalyzer/Checkers/ChrootChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/ConversionChecker.cpp | 5 +- .../StaticAnalyzer/Checkers/DeadStoresChecker.cpp | 2 +- .../lib/StaticAnalyzer/Checkers/DebugCheckers.cpp | 2 +- .../Checkers/DeleteWithNonVirtualDtorChecker.cpp | 155 - .../Checkers/DynamicTypePropagation.cpp | 20 +- .../Checkers/EnumCastOutOfRangeChecker.cpp | 62 +- .../lib/StaticAnalyzer/Checkers/ErrnoModeling.cpp | 12 - .../lib/StaticAnalyzer/Checkers/ErrnoModeling.h | 16 +- .../Checkers/ExprInspectionChecker.cpp | 18 +- .../Checkers/FixedAddressChecker.cpp | 15 +- .../Checkers/FuchsiaHandleChecker.cpp | 15 +- .../Checkers/GCDAntipatternChecker.cpp | 2 +- .../lib/StaticAnalyzer/Checkers/GTestChecker.cpp | 8 +- .../Checkers/GenericTaintChecker.cpp | 27 +- .../Checkers/IteratorRangeChecker.cpp | 2 +- .../Checkers/IvarInvalidationChecker.cpp | 4 +- .../Checkers/LocalizationChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/MallocChecker.cpp | 51 +- .../Checkers/MmapWriteExecChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/NSErrorChecker.cpp | 4 +- .../Checkers/NonNullParamChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/NullabilityChecker.cpp | 14 +- .../StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp | 14 +- .../Checkers/ObjCMissingSuperCallChecker.cpp | 4 +- .../Checkers/ObjCPropertyChecker.cpp | 2 +- .../Checkers/PointerArithChecker.cpp | 29 +- .../StaticAnalyzer/Checkers/PointerSubChecker.cpp | 14 +- .../RetainCountChecker/RetainCountChecker.h | 1 - .../RetainCountChecker/RetainCountDiagnostics.cpp | 3 - .../Checkers/ReturnPointerRangeChecker.cpp | 13 +- .../StaticAnalyzer/Checkers/ReturnUndefChecker.cpp | 22 +- .../Checkers/SimpleStreamChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/SmartPtrModeling.cpp | 3 +- .../Checkers/StackAddrEscapeChecker.cpp | 37 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 149 +- .../StaticAnalyzer/Checkers/StdVariantChecker.cpp | 298 + .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 238 +- .../StaticAnalyzer/Checkers/TaggedUnionModeling.h | 99 + .../Checkers/TestAfterDivZeroChecker.cpp | 4 +- .../StaticAnalyzer/Checkers/UndefBranchChecker.cpp | 6 +- .../Checkers/UndefCapturedBlockVarChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/UndefResultChecker.cpp | 74 +- .../Checkers/UndefinedArraySubscriptChecker.cpp | 2 +- .../Checkers/UndefinedAssignmentChecker.cpp | 3 +- .../UninitializedObjectChecker.cpp | 4 +- .../lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp | 3 +- .../lib/StaticAnalyzer/Checkers/VforkChecker.cpp | 9 +- .../Checkers/WebKit/NoUncountedMembersChecker.cpp | 3 +- .../Checkers/WebKit/PtrTypesSemantics.cpp | 65 +- .../Checkers/WebKit/PtrTypesSemantics.h | 8 +- .../WebKit/RefCntblBaseVirtualDtorChecker.cpp | 49 +- .../Checkers/WebKit/UncountedCallArgsChecker.cpp | 3 +- .../Checkers/WebKit/UncountedLocalVarsChecker.cpp | 1 - .../clang/lib/StaticAnalyzer/Checkers/Yaml.h | 2 +- .../Checkers/cert/InvalidPtrChecker.cpp | 145 +- .../lib/StaticAnalyzer/Core/BasicValueFactory.cpp | 12 +- .../clang/lib/StaticAnalyzer/Core/BugReporter.cpp | 35 +- .../StaticAnalyzer/Core/BugReporterVisitors.cpp | 61 +- .../lib/StaticAnalyzer/Core/BugSuppression.cpp | 169 + .../clang/lib/StaticAnalyzer/Core/CallEvent.cpp | 41 +- .../lib/StaticAnalyzer/Core/CheckerContext.cpp | 5 +- .../StaticAnalyzer/Core/CheckerRegistryData.cpp | 6 +- .../lib/StaticAnalyzer/Core/ConstraintManager.cpp | 2 +- .../clang/lib/StaticAnalyzer/Core/CoreEngine.cpp | 4 +- .../lib/StaticAnalyzer/Core/DynamicExtent.cpp | 72 +- .../clang/lib/StaticAnalyzer/Core/ExprEngine.cpp | 18 +- .../clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp | 3 +- .../lib/StaticAnalyzer/Core/ExprEngineCXX.cpp | 18 +- .../Core/ExprEngineCallAndReturn.cpp | 2 +- .../lib/StaticAnalyzer/Core/ExprEngineObjC.cpp | 35 +- .../lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp | 29 +- .../clang/lib/StaticAnalyzer/Core/LoopWidening.cpp | 6 +- .../lib/StaticAnalyzer/Core/PlistDiagnostics.cpp | 2 +- .../StaticAnalyzer/Core/RangeConstraintManager.cpp | 22 + .../clang/lib/StaticAnalyzer/Core/SValBuilder.cpp | 51 +- .../clang/lib/StaticAnalyzer/Core/SVals.cpp | 87 +- .../Core/SimpleConstraintManager.cpp | 4 +- .../lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp | 144 +- .../clang/lib/StaticAnalyzer/Core/Store.cpp | 2 +- .../StaticAnalyzer/Frontend/AnalysisConsumer.cpp | 62 +- .../StaticAnalyzer/Frontend/AnalyzerHelpFlags.cpp | 10 +- .../StaticAnalyzer/Frontend/CheckerRegistry.cpp | 4 +- .../lib/StaticAnalyzer/Frontend/ModelInjector.cpp | 3 +- .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 105 +- .../clang/lib/Tooling/ASTDiff/ASTDiff.cpp | 2 +- .../clang/lib/Tooling/ArgumentsAdjusters.cpp | 14 +- .../clang/lib/Tooling/CompilationDatabase.cpp | 2 +- .../clang/lib/Tooling/Core/Replacement.cpp | 5 +- .../DependencyScanningFilesystem.cpp | 4 +- .../DependencyScanningService.cpp | 4 +- .../DependencyScanning/DependencyScanningTool.cpp | 23 +- .../DependencyScanningWorker.cpp | 98 +- .../DependencyScanning/ModuleDepCollector.cpp | 233 +- .../clang/lib/Tooling/DumpTool/ClangSrcLocDump.cpp | 6 +- .../lib/Tooling/Inclusions/HeaderAnalysis.cpp | 11 +- .../lib/Tooling/Inclusions/HeaderIncludes.cpp | 18 +- *** 875030 LINES SKIPPED *** From nobody Sat Apr 20 10:32:06 2024 X-Original-To: dev-commits-src-branches@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 4VM79f5Hx9z5HVjQ; Sat, 20 Apr 2024 10:32:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79f3vC4z4Nv3; Sat, 20 Apr 2024 10:32:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609126; 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=vW2rAnmVju+ngN45xNk4SN4NvQCTR5eokZNCGbYANN4=; b=JiicaUiU8VIGttKz26nvK24posU10VQ5kpMfh/RqWYfpFTbFp/ue1Jl1cmi0zeZzAAJBgE h+GZsuE+GzpBi1C26dCOUhynxfvEMszejItum53I87jTrmvzWKOzjIJ+LeSWXbIJ/TTNLK xNHFj3MsTPxcYmIQTnH3sRXSbDLCzQ/lfnryuzAbnY7UtX81OefJLtFSqSFyCR9QJe+KAP joN06eQFyDVfX07xM0YrVyvl3bzKLWmF5fbziIGfmsi5EZ/eLg1gbjl1SVZ8KCSKt1bLNa JuI4ZbgyI0GGM4cGzr9LeWAlLP8m9cVz02Dl3hVheer6oJxnvq540sJGbGluGA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609126; a=rsa-sha256; cv=none; b=HbDs1OPkIsLf11nxaRzQIarQjSRpHS3W10Ry52PWlGTLHLrZnIoakZ12x0FkmI2b3G+xZU mgbR3HnfavjKbZtssKp7rmvOCPcCCrJGlUfBkUm9YuNfIKGzJdSch3LmgBd88yuAyzaiEX XnWhWJvdxoeXoNW19fuDdI5ctlAed2tAQ0obJ5USHnkkN5pnGsFoUR1PrM8q8nxr4CQfyH pPih5X4y3xPs71dfclkNo+tKM02nlr2gy5AOldVsISQObX69f/5pM18VaN+/LHKrTt4i7Z e9KBpsL7R2yb+QtbyN2kLBaypF73imIbc87ZsBXj8fMb5FE3nZg7hNgTmjBzfA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609126; 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=vW2rAnmVju+ngN45xNk4SN4NvQCTR5eokZNCGbYANN4=; b=Yaiyk27YLAaac/XklIWVUlon4UFlQjcCwynBeAooEE0ZW0uweGqiOxObTfdH6m5hqidslL Q2EPb1osTJYCQ48Dad1dtQmXSXScDxL0xZvAWra/huJ4A8NCo4jTzd6HvVZH5tKTpag6Ys IAGWgyiMA52KHgkjRSj927dzI+aVf3G3RFDoUpxYGJF4R4Ao6fkTZ9Rl7mkgzf1esyltjF JfvDl6jYlZ/Y7sXo/nqs7rPdiIfmQcTAFVdRTofqV+doLDISXhobvvSvFqJ8u6h40fkZ5F WgS45xxhwFxNjY+BoKTHdYZZQo/b6vLJ5dZ/1pTNX2vRmBLoba72fzEFEglEeQ== 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 4VM79f3WGxzYm2; Sat, 20 Apr 2024 10:32:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAW6eh009348; Sat, 20 Apr 2024 10:32:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAW6Qu009345; Sat, 20 Apr 2024 10:32:06 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:06 GMT Message-Id: <202404201032.43KAW6Qu009345@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: 1bc094c4a0e7 - stable/14 - Tentatively apply https://github.com/llvm/llvm-project/pull/76175 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 1bc094c4a0e74dba87a5eb98cf138426a19f702d Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=1bc094c4a0e74dba87a5eb98cf138426a19f702d commit 1bc094c4a0e74dba87a5eb98cf138426a19f702d Author: Dimitry Andric AuthorDate: 2023-12-21 22:30:02 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:12:21 +0000 Tentatively apply https://github.com/llvm/llvm-project/pull/76175 This fixes libsa including compiler-rt builtins. PR: 276104 MFC after: 1 month (cherry picked from commit 3d68ee6cbdb244de9fab1df8a2525d2fa592571e) --- contrib/llvm-project/compiler-rt/lib/builtins/int_types.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h b/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h index 18bf0a7f3bf9..0d4ed224fa72 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h +++ b/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h @@ -139,7 +139,6 @@ typedef union { udwords u; double f; } double_bits; -#endif typedef struct { #if _YUGA_LITTLE_ENDIAN @@ -220,7 +219,6 @@ typedef union { #define CRT_HAS_TF_MODE #endif -#if CRT_HAS_FLOATING_POINT #if __STDC_VERSION__ >= 199901L typedef float _Complex Fcomplex; typedef double _Complex Dcomplex; From nobody Sat Apr 20 10:32:07 2024 X-Original-To: dev-commits-src-branches@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 4VM79l0Cwdz5HWFW; Sat, 20 Apr 2024 10:32:11 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79k5Jblz4P2J; Sat, 20 Apr 2024 10:32:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609130; 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=LiXtGKvt/T0/tcYIM59bUL0NTEOPkd5YlA2z1OJFtqM=; b=ZeQpsy/2Xz/0sist42pYHREL6mryt9WuR1XOKjs8jFhtzjZcuvLY22HjYRnkTPUu5sBDPH bazb8RnGj+5aGj36b1r+hmqoULHUoS5bsW4gAyzI7PsjJtjI4N9EfA9uDMRrazYBDqEULt d/h2HbPODpvb+SoMmP8TdaA2PGiYtCIVQxTSpCiiqOw++tM05IjuuzYVcygUwqplYH/Cvu Nhf7VtBSlJ0Efgj0Xwaqb2WlCVu6WazHJcY0OiPIy2cL8e84U1LbhHauHxxHBWzMLq6CCw 7Y/5ZCDDnU1v3CqCUEp1aZfnGK496gOvlY3Tdm9cu5FuqPmFqETu6ldUPA5eYQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609130; a=rsa-sha256; cv=none; b=VA3cMbRVI5qKR1N5ldZClcr5Z+N/SZb5iBp/wc5Uw3D1N2wjyCEBgQJBLKjF+AM5oHLumH SbzZpoa8RJPmGyLGZyeKQi/vY/bFdYFf5JKAGimNNzZlKpbSDrlcVLSUI7WjhhN41oBVwP JhWjWXcyRErRnahesb2A7KZFpk5sZYRBH6TdsapPhuS86CdAJIxUpb7jJzeVEEhpb6qLSo kU18vsPxPp5npnIhBmiSgm11vvgYXWiBwuRSBBvAJUSlE4+4Z+4zQuEJ0Tro6eiJleDPf0 pYY3Jw2Pdf0ZlxCMeH3WEKPcRDcrSVCcGMBLsPyMnSomXaD66F5dUMLblRPMqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609130; 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=LiXtGKvt/T0/tcYIM59bUL0NTEOPkd5YlA2z1OJFtqM=; b=TC7vdUB7upPkHRD3MSOqBEtM+L4LE8vfxAp7YU/m1BToGcCHytkHikxS4DPhXF0gtGOAuP kVkl2elRADck+QQXqqYhhef6qZzOEzgEf+X5XgQjkNaeG0a96c80h1IoGo0agg8X2uuoOf aa8onfo3YR45O2r2IK0cD9yWvOWF+LbY3gBUTGbHHQRoJd+E2tDFRcK4oF/nQ1OT1RS1M4 SHmwAlf6yw8baOG76s60LHg7ZkpjN7CLChoYBCv8wzOTCpW2UCOXonrD4NsszmJ4Bw7ZXH NAO/TgQJgbR6FAVa5PFMJvEF9LEy0XKo4ku6Q+jpJmjgD4lzmFdWTwxjwjkE1Q== 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 4VM79k4rwyzYjy; Sat, 20 Apr 2024 10:32:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWAcn009390; Sat, 20 Apr 2024 10:32:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAW7aI009386; Sat, 20 Apr 2024 10:32:07 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:07 GMT Message-Id: <202404201032.43KAW7aI009386@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: e710425beb3d - stable/14 - Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: e710425beb3de4adcf4d601da2f224503f876b6d Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=e710425beb3de4adcf4d601da2f224503f876b6d commit e710425beb3de4adcf4d601da2f224503f876b6d Author: Dimitry Andric AuthorDate: 2023-12-25 17:35:41 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:12:22 +0000 Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-15692-g007ed0dccd6a. PR: 276104 MFC after: 1 month (cherry picked from commit cb14a3fe5122c879eae1fb480ed7ce82a699ddb6) --- .../llvm-project/clang/include/clang/AST/Decl.h | 27 +- .../clang/include/clang/AST/DeclBase.h | 10 - .../clang/include/clang/AST/RecursiveASTVisitor.h | 7 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 80 +- .../clang/Analysis/FlowSensitive/RecordOps.h | 12 +- .../include/clang/Analysis/FlowSensitive/Value.h | 40 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 18 - .../clang/include/clang/Basic/AttrDocs.td | 66 - .../clang/include/clang/Basic/DiagnosticGroups.td | 6 +- .../include/clang/Basic/DiagnosticParseKinds.td | 4 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 28 +- .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Basic/OpenACCKinds.h | 24 + .../clang/include/clang/Basic/PlistSupport.h | 3 +- .../clang/include/clang/Basic/TargetInfo.h | 1 + .../clang/include/clang/Basic/Version.h | 3 + .../clang/include/clang/Basic/arm_sme.td | 317 + .../clang/include/clang/Basic/arm_sve.td | 1399 +-- .../clang/include/clang/Basic/riscv_vector.td | 18 +- .../clang/include/clang/Driver/Options.td | 5 +- .../include/clang/Interpreter/CodeCompletion.h | 25 +- .../clang/include/clang/Interpreter/Interpreter.h | 1 + .../llvm-project/clang/include/clang/Sema/Sema.h | 7 +- .../clang/include/clang/Sema/TypoCorrection.h | 12 +- .../clang/include/clang/Serialization/ASTReader.h | 2 + .../clang/include/clang/Serialization/ASTWriter.h | 88 +- .../include/clang/Support/RISCVVIntrinsicUtils.h | 7 +- .../clang/lib/APINotes/APINotesManager.cpp | 2 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 48 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 12 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 41 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 74 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 83 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 90 +- .../Models/UncheckedOptionalAccessModel.cpp | 31 +- .../clang/lib/Analysis/FlowSensitive/RecordOps.cpp | 33 +- .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 25 +- .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 2 +- .../clang/lib/Basic/Targets/AArch64.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 4 + .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 1 + contrib/llvm-project/clang/lib/Basic/Version.cpp | 18 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 3 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 209 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 129 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 26 +- .../clang/lib/CodeGen/CGHLSLRuntime.cpp | 63 +- .../llvm-project/clang/lib/CodeGen/CGHLSLRuntime.h | 2 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 148 +- .../clang/lib/CodeGen/CodeGenFunction.h | 16 - .../clang/lib/CodeGen/CodeGenModule.cpp | 10 +- .../clang/lib/CodeGen/Targets/AArch64.cpp | 2 + .../clang/lib/Driver/ToolChains/AIX.cpp | 6 + .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 4 + .../clang/lib/Driver/ToolChains/Clang.cpp | 15 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 59 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 127 +- .../clang/lib/Format/ContinuationIndenter.cpp | 20 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 8 +- .../clang/lib/Format/MatchFilePath.cpp | 122 + .../llvm-project/clang/lib/Format/MatchFilePath.h | 22 + .../clang/lib/Format/TokenAnnotator.cpp | 3 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 6 +- contrib/llvm-project/clang/lib/Headers/adcintrin.h | 160 + contrib/llvm-project/clang/lib/Headers/adxintrin.h | 143 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 8 +- .../clang/lib/Headers/riscv_bitmanip.h | 24 +- .../clang/lib/Interpreter/CodeCompletion.cpp | 223 +- .../clang/lib/Interpreter/Interpreter.cpp | 4 + .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 22 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 92 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 77 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 45 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 90 - contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 28 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 4 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 214 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 13 + .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 19 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 7 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 28 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 52 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 405 +- .../clang/lib/Serialization/ASTWriter.cpp | 15 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 574 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 241 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 86 + .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 2 +- .../clang/tools/clang-repl/ClangRepl.cpp | 24 +- .../clang/utils/TableGen/NeonEmitter.cpp | 28 + .../clang/utils/TableGen/RISCVVEmitter.cpp | 40 +- .../clang/utils/TableGen/SveEmitter.cpp | 87 + .../llvm-project/clang/utils/TableGen/TableGen.cpp | 18 + .../clang/utils/TableGen/TableGenBackends.h | 3 + .../compiler-rt/lib/asan/asan_posix.cpp | 51 +- .../compiler-rt/lib/asan/asan_rtl_x86_64.S | 10 + .../compiler-rt/lib/builtins/cpu_model/aarch64.c | 151 + .../lib/builtins/cpu_model/aarch64/fmv/android.inc | 36 + .../lib/builtins/cpu_model/aarch64/fmv/apple.inc | 69 + .../lib/builtins/cpu_model/aarch64/fmv/freebsd.inc | 27 + .../lib/builtins/cpu_model/aarch64/fmv/fuchsia.inc | 51 + .../lib/builtins/cpu_model/aarch64/fmv/mrs.inc | 196 + .../lib/builtins/cpu_model/aarch64/fmv/sysauxv.inc | 21 + .../cpu_model/aarch64/fmv/unimplemented.inc | 8 + .../lib/builtins/cpu_model/aarch64/hwcap.inc | 180 + .../cpu_model/aarch64/lse_atomics/android.inc | 28 + .../cpu_model/aarch64/lse_atomics/freebsd.inc | 5 + .../cpu_model/aarch64/lse_atomics/fuchsia.inc | 12 + .../cpu_model/aarch64/lse_atomics/sysauxv.inc | 6 + .../compiler-rt/lib/builtins/cpu_model/cpu_model.h | 41 + .../lib/builtins/{cpu_model.c => cpu_model/x86.c} | 692 +- .../lib/dfsan/dfsan_chained_origin_depot.cpp | 6 + .../lib/dfsan/dfsan_chained_origin_depot.h | 3 + .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 12 +- .../compiler-rt/lib/hwasan/hwasan_linux.cpp | 46 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 68 +- .../compiler-rt/lib/lsan/lsan_posix.cpp | 33 +- .../lib/msan/msan_chained_origin_depot.cpp | 8 +- .../lib/msan/msan_chained_origin_depot.h | 4 +- .../compiler-rt/lib/msan/msan_linux.cpp | 32 +- .../compiler-rt/lib/orc/macho_platform.cpp | 4 + .../lib/profile/InstrProfilingPlatformWindows.c | 10 + .../sanitizer_chained_origin_depot.cpp | 6 +- .../sanitizer_chained_origin_depot.h | 4 +- .../lib/sanitizer_common/sanitizer_stack_store.cpp | 9 +- .../lib/sanitizer_common/sanitizer_stackdepot.cpp | 8 +- .../lib/sanitizer_common/sanitizer_stackdepot.h | 4 +- .../sanitizer_common/sanitizer_stackdepotbase.h | 9 +- .../sanitizer_common/sanitizer_suppressions.cpp | 5 +- .../sanitizer_symbolizer_posix_libcdep.cpp | 27 +- .../symbolizer/sanitizer_symbolize.cpp | 6 +- .../compiler-rt/lib/scudo/standalone/combined.h | 13 - .../lib/tsan/rtl/tsan_interceptors_posix.cpp | 19 + .../libcxx/include/__algorithm/binary_search.h | 20 +- .../libcxx/include/__algorithm/comp_ref_type.h | 66 +- .../libcxx/include/__algorithm/copy_backward.h | 16 +- .../libcxx/include/__algorithm/copy_if.h | 23 +- .../libcxx/include/__algorithm/copy_move_common.h | 25 +- .../libcxx/include/__algorithm/copy_n.h | 59 +- .../libcxx/include/__algorithm/equal.h | 29 +- .../libcxx/include/__algorithm/equal_range.h | 11 +- .../llvm-project/libcxx/include/__algorithm/fill.h | 26 +- .../libcxx/include/__algorithm/fill_n.h | 20 +- .../llvm-project/libcxx/include/__algorithm/find.h | 19 + .../libcxx/include/__algorithm/find_end.h | 92 +- .../libcxx/include/__algorithm/find_first_of.h | 21 +- .../llvm-project/libcxx/include/__algorithm/fold.h | 125 + .../libcxx/include/__algorithm/for_each_n.h | 5 +- .../libcxx/include/__algorithm/generate.h | 10 +- .../libcxx/include/__algorithm/generate_n.h | 16 +- .../libcxx/include/__algorithm/half_positive.h | 14 +- .../libcxx/include/__algorithm/in_found_result.h | 2 +- .../libcxx/include/__algorithm/in_fun_result.h | 2 +- .../libcxx/include/__algorithm/in_in_out_result.h | 14 +- .../libcxx/include/__algorithm/in_in_result.h | 6 +- .../libcxx/include/__algorithm/in_out_out_result.h | 14 +- .../libcxx/include/__algorithm/in_out_result.h | 8 +- .../libcxx/include/__algorithm/includes.h | 31 +- .../libcxx/include/__algorithm/inplace_merge.h | 304 +- .../libcxx/include/__algorithm/is_heap.h | 20 +- .../libcxx/include/__algorithm/is_heap_until.h | 56 +- .../libcxx/include/__algorithm/is_partitioned.h | 21 +- .../libcxx/include/__algorithm/is_permutation.h | 177 +- .../libcxx/include/__algorithm/is_sorted.h | 20 +- .../libcxx/include/__algorithm/is_sorted_until.h | 33 +- .../libcxx/include/__algorithm/iter_swap.h | 3 +- .../include/__algorithm/iterator_operations.h | 67 +- .../include/__algorithm/lexicographical_compare.h | 49 +- .../libcxx/include/__algorithm/lower_bound.h | 15 +- .../libcxx/include/__algorithm/make_heap.h | 16 +- .../libcxx/include/__algorithm/make_projected.h | 47 +- .../llvm-project/libcxx/include/__algorithm/max.h | 39 +- .../libcxx/include/__algorithm/max_element.h | 33 +- .../libcxx/include/__algorithm/merge.h | 65 +- .../llvm-project/libcxx/include/__algorithm/min.h | 39 +- .../libcxx/include/__algorithm/min_element.h | 23 +- .../libcxx/include/__algorithm/min_max_result.h | 2 +- .../libcxx/include/__algorithm/minmax.h | 48 +- .../libcxx/include/__algorithm/minmax_element.h | 31 +- .../libcxx/include/__algorithm/mismatch.h | 25 +- .../llvm-project/libcxx/include/__algorithm/move.h | 3 +- .../libcxx/include/__algorithm/move_backward.h | 6 +- .../libcxx/include/__algorithm/next_permutation.h | 61 +- .../libcxx/include/__algorithm/nth_element.h | 386 +- .../libcxx/include/__algorithm/partial_sort.h | 39 +- .../libcxx/include/__algorithm/partial_sort_copy.h | 94 +- .../libcxx/include/__algorithm/partition.h | 84 +- .../libcxx/include/__algorithm/partition_copy.h | 36 +- .../libcxx/include/__algorithm/partition_point.h | 34 +- .../libcxx/include/__algorithm/pop_heap.h | 18 +- .../libcxx/include/__algorithm/prev_permutation.h | 64 +- .../libcxx/include/__algorithm/push_heap.h | 24 +- .../libcxx/include/__algorithm/ranges_contains.h | 61 + .../libcxx/include/__algorithm/ranges_max.h | 5 +- .../libcxx/include/__algorithm/ranges_min.h | 5 +- .../libcxx/include/__algorithm/ranges_minmax.h | 5 +- .../libcxx/include/__algorithm/remove.h | 26 +- .../libcxx/include/__algorithm/remove_copy.h | 20 +- .../libcxx/include/__algorithm/remove_copy_if.h | 20 +- .../libcxx/include/__algorithm/remove_if.h | 26 +- .../libcxx/include/__algorithm/replace.h | 12 +- .../libcxx/include/__algorithm/replace_copy.h | 23 +- .../libcxx/include/__algorithm/replace_copy_if.h | 23 +- .../libcxx/include/__algorithm/replace_if.h | 12 +- .../libcxx/include/__algorithm/reverse.h | 40 +- .../libcxx/include/__algorithm/reverse_copy.h | 12 +- .../libcxx/include/__algorithm/rotate.h | 264 +- .../libcxx/include/__algorithm/rotate_copy.h | 8 +- .../libcxx/include/__algorithm/sample.h | 83 +- .../libcxx/include/__algorithm/search.h | 123 +- .../libcxx/include/__algorithm/search_n.h | 96 +- .../libcxx/include/__algorithm/set_difference.h | 2 +- .../libcxx/include/__algorithm/shift_left.h | 43 +- .../libcxx/include/__algorithm/shift_right.h | 123 +- .../libcxx/include/__algorithm/shuffle.h | 127 +- .../libcxx/include/__algorithm/sift_down.h | 141 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 245 +- .../libcxx/include/__algorithm/sort_heap.h | 16 +- .../libcxx/include/__algorithm/stable_partition.h | 487 +- .../libcxx/include/__algorithm/stable_sort.h | 332 +- .../libcxx/include/__algorithm/swap_ranges.h | 9 +- .../libcxx/include/__algorithm/transform.h | 29 +- .../uniform_random_bit_generator_adaptor.h | 14 +- .../libcxx/include/__algorithm/unwrap_iter.h | 10 +- .../llvm-project/libcxx/include/__atomic/atomic.h | 812 +- .../libcxx/include/__atomic/atomic_base.h | 321 +- .../libcxx/include/__atomic/atomic_flag.h | 246 +- .../libcxx/include/__atomic/atomic_lock_free.h | 52 +- .../libcxx/include/__atomic/atomic_sync.h | 90 +- .../libcxx/include/__atomic/check_memory_order.h | 22 +- .../libcxx/include/__atomic/contention_t.h | 4 +- .../libcxx/include/__atomic/cxx_atomic_impl.h | 560 +- .../llvm-project/libcxx/include/__atomic/fence.h | 16 +- .../libcxx/include/__atomic/kill_dependency.h | 6 +- .../libcxx/include/__atomic/memory_order.h | 11 +- contrib/llvm-project/libcxx/include/__availability | 82 +- .../llvm-project/libcxx/include/__bit/bit_cast.h | 3 +- .../llvm-project/libcxx/include/__bit/bit_ceil.h | 2 +- .../llvm-project/libcxx/include/__bit/byteswap.h | 11 +- contrib/llvm-project/libcxx/include/__bit/countl.h | 84 +- contrib/llvm-project/libcxx/include/__bit/countr.h | 17 +- contrib/llvm-project/libcxx/include/__bit/endian.h | 2 +- .../llvm-project/libcxx/include/__bit/popcount.h | 15 +- .../libcxx/include/__chrono/calendar.h | 12 +- .../libcxx/include/__chrono/convert_to_timespec.h | 15 +- contrib/llvm-project/libcxx/include/__chrono/day.h | 91 +- .../libcxx/include/__chrono/duration.h | 693 +- .../libcxx/include/__chrono/file_clock.h | 24 +- .../libcxx/include/__chrono/formatter.h | 63 +- .../libcxx/include/__chrono/hh_mm_ss.h | 117 +- .../include/__chrono/high_resolution_clock.h | 3 +- .../libcxx/include/__chrono/literals.h | 24 +- .../llvm-project/libcxx/include/__chrono/month.h | 94 +- .../libcxx/include/__chrono/month_weekday.h | 104 +- .../libcxx/include/__chrono/monthday.h | 134 +- .../libcxx/include/__chrono/steady_clock.h | 18 +- .../libcxx/include/__chrono/system_clock.h | 24 +- .../libcxx/include/__chrono/time_point.h | 186 +- .../llvm-project/libcxx/include/__chrono/weekday.h | 201 +- .../llvm-project/libcxx/include/__chrono/year.h | 104 +- .../libcxx/include/__chrono/year_month.h | 102 +- .../libcxx/include/__chrono/year_month_day.h | 460 +- .../libcxx/include/__chrono/year_month_weekday.h | 369 +- .../include/__compare/common_comparison_category.h | 27 +- .../__compare/compare_partial_order_fallback.h | 68 +- .../__compare/compare_strong_order_fallback.h | 62 +- .../libcxx/include/__compare/compare_three_way.h | 19 +- .../include/__compare/compare_three_way_result.h | 23 +- .../__compare/compare_weak_order_fallback.h | 62 +- .../libcxx/include/__compare/ordering.h | 164 +- .../libcxx/include/__compare/partial_order.h | 63 +- .../libcxx/include/__compare/strong_order.h | 173 +- .../include/__compare/three_way_comparable.h | 36 +- .../libcxx/include/__compare/weak_order.h | 115 +- contrib/llvm-project/libcxx/include/__config | 4 +- .../libcxx/include/__coroutine/coroutine_handle.h | 257 +- .../libcxx/include/__coroutine/coroutine_traits.h | 9 +- .../include/__coroutine/noop_coroutine_handle.h | 103 +- .../include/__coroutine/trivial_awaitables.h | 18 +- .../libcxx/include/__debug_utils/randomize_range.h | 3 +- .../libcxx/include/__expected/expected.h | 205 +- .../libcxx/include/__filesystem/copy_options.h | 50 +- .../libcxx/include/__filesystem/directory_entry.h | 251 +- .../include/__filesystem/directory_iterator.h | 73 +- .../include/__filesystem/directory_options.h | 44 +- .../libcxx/include/__filesystem/file_status.h | 28 +- .../libcxx/include/__filesystem/file_type.h | 14 +- .../libcxx/include/__filesystem/operations.h | 224 +- .../libcxx/include/__filesystem/path.h | 652 +- .../libcxx/include/__filesystem/path_iterator.h | 50 +- .../libcxx/include/__filesystem/perm_options.h | 39 +- .../libcxx/include/__filesystem/perms.h | 56 +- .../__filesystem/recursive_directory_iterator.h | 85 +- .../libcxx/include/__filesystem/u8path.h | 48 +- .../llvm-project/libcxx/include/__format/buffer.h | 52 +- .../libcxx/include/__format/concepts.h | 2 +- .../libcxx/include/__format/format_arg.h | 32 +- .../libcxx/include/__format/format_arg_store.h | 10 +- .../libcxx/include/__format/format_args.h | 5 +- .../libcxx/include/__format/format_context.h | 72 +- .../libcxx/include/__format/format_error.h | 17 +- .../libcxx/include/__format/format_functions.h | 184 +- .../libcxx/include/__format/format_parse_context.h | 30 +- .../libcxx/include/__format/format_string.h | 20 +- .../libcxx/include/__format/formatter.h | 4 +- .../include/__format/formatter_floating_point.h | 92 +- .../libcxx/include/__format/formatter_integer.h | 37 +- .../libcxx/include/__format/formatter_integral.h | 77 +- .../libcxx/include/__format/formatter_output.h | 58 +- .../libcxx/include/__format/formatter_pointer.h | 9 +- .../libcxx/include/__format/formatter_string.h | 18 +- .../include/__format/parser_std_format_spec.h | 79 +- .../llvm-project/libcxx/include/__format/unicode.h | 10 +- .../libcxx/include/__format/write_escaped.h | 19 +- .../libcxx/include/__functional/binary_function.h | 16 +- .../libcxx/include/__functional/binary_negate.h | 25 +- .../libcxx/include/__functional/bind.h | 385 +- .../libcxx/include/__functional/bind_back.h | 34 +- .../libcxx/include/__functional/bind_front.h | 21 +- .../libcxx/include/__functional/binder1st.h | 35 +- .../libcxx/include/__functional/binder2nd.h | 35 +- .../include/__functional/boyer_moore_searcher.h | 128 +- .../libcxx/include/__functional/compose.h | 25 +- .../libcxx/include/__functional/default_searcher.h | 31 +- .../libcxx/include/__functional/function.h | 1645 ++-- .../libcxx/include/__functional/hash.h | 682 +- .../libcxx/include/__functional/identity.h | 20 +- .../libcxx/include/__functional/invoke.h | 30 +- .../libcxx/include/__functional/is_transparent.h | 3 +- .../libcxx/include/__functional/mem_fn.h | 36 +- .../libcxx/include/__functional/mem_fun_ref.h | 183 +- .../libcxx/include/__functional/not_fn.h | 25 +- .../libcxx/include/__functional/operations.h | 540 +- .../libcxx/include/__functional/perfect_forward.h | 48 +- .../__functional/pointer_to_binary_function.h | 20 +- .../__functional/pointer_to_unary_function.h | 20 +- .../include/__functional/ranges_operations.h | 24 +- .../include/__functional/reference_wrapper.h | 97 +- .../libcxx/include/__functional/unary_function.h | 12 +- .../libcxx/include/__functional/unary_negate.h | 25 +- .../libcxx/include/__functional/weak_result_type.h | 225 +- contrib/llvm-project/libcxx/include/__fwd/get.h | 48 +- contrib/llvm-project/libcxx/include/__fwd/span.h | 3 +- .../libcxx/include/__fwd/string_view.h | 8 +- .../llvm-project/libcxx/include/__fwd/subrange.h | 2 +- contrib/llvm-project/libcxx/include/__hash_table | 3216 +++---- contrib/llvm-project/libcxx/include/__ios/fpos.h | 9 +- .../libcxx/include/__iterator/access.h | 67 +- .../libcxx/include/__iterator/advance.h | 57 +- .../include/__iterator/back_insert_iterator.h | 53 +- .../libcxx/include/__iterator/common_iterator.h | 211 +- .../libcxx/include/__iterator/concepts.h | 338 +- .../libcxx/include/__iterator/counted_iterator.h | 200 +- .../llvm-project/libcxx/include/__iterator/data.h | 32 +- .../libcxx/include/__iterator/default_sentinel.h | 2 +- .../libcxx/include/__iterator/distance.h | 49 +- .../llvm-project/libcxx/include/__iterator/empty.h | 19 +- .../libcxx/include/__iterator/erase_if_container.h | 4 +- .../include/__iterator/front_insert_iterator.h | 51 +- .../include/__iterator/incrementable_traits.h | 33 +- .../include/__iterator/indirectly_comparable.h | 3 +- .../libcxx/include/__iterator/insert_iterator.h | 57 +- .../libcxx/include/__iterator/istream_iterator.h | 95 +- .../include/__iterator/istreambuf_iterator.h | 131 +- .../libcxx/include/__iterator/iter_move.h | 68 +- .../libcxx/include/__iterator/iter_swap.h | 100 +- .../libcxx/include/__iterator/iterator.h | 16 +- .../libcxx/include/__iterator/iterator_traits.h | 397 +- .../libcxx/include/__iterator/mergeable.h | 15 +- .../libcxx/include/__iterator/move_iterator.h | 419 +- .../libcxx/include/__iterator/move_sentinel.h | 21 +- .../llvm-project/libcxx/include/__iterator/next.h | 13 +- .../libcxx/include/__iterator/ostream_iterator.h | 55 +- .../include/__iterator/ostreambuf_iterator.h | 61 +- .../libcxx/include/__iterator/permutable.h | 3 +- .../llvm-project/libcxx/include/__iterator/prev.h | 13 +- .../libcxx/include/__iterator/readable_traits.h | 46 +- .../libcxx/include/__iterator/reverse_access.h | 60 +- .../libcxx/include/__iterator/reverse_iterator.h | 366 +- .../llvm-project/libcxx/include/__iterator/size.h | 32 +- .../libcxx/include/__iterator/sortable.h | 4 +- .../include/__iterator/unreachable_sentinel.h | 5 +- .../libcxx/include/__iterator/wrap_iter.h | 258 +- contrib/llvm-project/libcxx/include/__locale | 2434 +++-- .../locale_base_api/bsd_locale_defaults.h | 28 +- .../locale_base_api/bsd_locale_fallbacks.h | 144 +- .../__locale_dir/locale_base_api/locale_guard.h | 67 +- contrib/llvm-project/libcxx/include/__mbstate_t.h | 16 +- .../libcxx/include/__memory/addressof.h | 35 +- .../libcxx/include/__memory/aligned_alloc.h | 42 +- .../libcxx/include/__memory/allocate_at_least.h | 10 +- .../libcxx/include/__memory/allocation_guard.h | 98 +- .../libcxx/include/__memory/allocator.h | 331 +- .../libcxx/include/__memory/allocator_arg_t.h | 45 +- .../libcxx/include/__memory/allocator_destructor.h | 24 +- .../libcxx/include/__memory/allocator_traits.h | 379 +- .../libcxx/include/__memory/assume_aligned.h | 3 +- .../libcxx/include/__memory/auto_ptr.h | 94 +- .../include/__memory/builtin_new_allocator.h | 23 +- .../libcxx/include/__memory/compressed_pair.h | 81 +- .../libcxx/include/__memory/concepts.h | 15 +- .../libcxx/include/__memory/construct_at.h | 65 +- .../libcxx/include/__memory/destruct_n.h | 61 +- .../libcxx/include/__memory/pointer_traits.h | 174 +- .../libcxx/include/__memory/ranges_construct_at.h | 28 +- .../__memory/ranges_uninitialized_algorithms.h | 89 +- .../libcxx/include/__memory/raw_storage_iterator.h | 66 +- .../libcxx/include/__memory/shared_ptr.h | 2495 ++--- .../libcxx/include/__memory/temp_value.h | 32 +- .../libcxx/include/__memory/temporary_buffer.h | 78 +- .../include/__memory/uninitialized_algorithms.h | 461 +- .../libcxx/include/__memory/unique_ptr.h | 373 +- .../libcxx/include/__memory/uses_allocator.h | 27 +- contrib/llvm-project/libcxx/include/__node_handle | 224 +- .../libcxx/include/__numeric/accumulate.h | 28 +- .../libcxx/include/__numeric/adjacent_difference.h | 57 +- .../libcxx/include/__numeric/exclusive_scan.h | 2 +- .../libcxx/include/__numeric/gcd_lcm.h | 82 +- .../libcxx/include/__numeric/inclusive_scan.h | 9 +- .../libcxx/include/__numeric/inner_product.h | 34 +- .../llvm-project/libcxx/include/__numeric/iota.h | 10 +- .../libcxx/include/__numeric/midpoint.h | 61 +- .../libcxx/include/__numeric/partial_sum.h | 53 +- .../llvm-project/libcxx/include/__numeric/reduce.h | 8 +- .../include/__numeric/transform_exclusive_scan.h | 33 +- .../include/__numeric/transform_inclusive_scan.h | 42 +- .../libcxx/include/__numeric/transform_reduce.h | 24 +- .../include/__random/bernoulli_distribution.h | 160 +- .../include/__random/binomial_distribution.h | 291 +- .../libcxx/include/__random/cauchy_distribution.h | 194 +- .../include/__random/chi_squared_distribution.h | 161 +- .../libcxx/include/__random/clamp_to_integral.h | 22 +- .../libcxx/include/__random/discard_block_engine.h | 256 +- .../include/__random/discrete_distribution.h | 340 +- .../include/__random/exponential_distribution.h | 171 +- .../include/__random/extreme_value_distribution.h | 196 +- .../include/__random/fisher_f_distribution.h | 194 +- .../libcxx/include/__random/gamma_distribution.h | 280 +- .../libcxx/include/__random/generate_canonical.h | 28 +- .../include/__random/geometric_distribution.h | 157 +- .../include/__random/independent_bits_engine.h | 331 +- .../libcxx/include/__random/is_seed_sequence.h | 8 +- .../libcxx/include/__random/is_valid.h | 53 +- .../include/__random/linear_congruential_engine.h | 491 +- .../llvm-project/libcxx/include/__random/log2.h | 39 +- .../include/__random/lognormal_distribution.h | 189 +- .../include/__random/mersenne_twister_engine.h | 1224 ++- .../__random/negative_binomial_distribution.h | 232 +- .../libcxx/include/__random/normal_distribution.h | 278 +- .../__random/piecewise_constant_distribution.h | 508 +- .../__random/piecewise_linear_distribution.h | 537 +- .../libcxx/include/__random/poisson_distribution.h | 392 +- .../libcxx/include/__random/random_device.h | 87 +- .../llvm-project/libcxx/include/__random/ranlux.h | 2 +- .../libcxx/include/__random/seed_seq.h | 231 +- .../libcxx/include/__random/shuffle_order_engine.h | 355 +- .../include/__random/student_t_distribution.h | 169 +- .../include/__random/subtract_with_carry_engine.h | 468 +- .../include/__random/uniform_int_distribution.h | 403 +- .../__random/uniform_random_bit_generator.h | 14 +- .../include/__random/uniform_real_distribution.h | 194 +- .../libcxx/include/__random/weibull_distribution.h | 185 +- .../llvm-project/libcxx/include/__ranges/access.h | 237 +- contrib/llvm-project/libcxx/include/__ranges/all.h | 55 +- .../libcxx/include/__ranges/common_view.h | 83 +- .../libcxx/include/__ranges/concepts.h | 126 +- .../llvm-project/libcxx/include/__ranges/counted.h | 62 +- .../llvm-project/libcxx/include/__ranges/data.h | 91 +- .../libcxx/include/__ranges/drop_view.h | 303 +- .../llvm-project/libcxx/include/__ranges/empty.h | 71 +- .../libcxx/include/__ranges/empty_view.h | 40 +- .../libcxx/include/__ranges/enable_view.h | 11 +- .../libcxx/include/__ranges/filter_view.h | 381 +- .../libcxx/include/__ranges/iota_view.h | 569 +- .../libcxx/include/__ranges/istream_view.h | 3 +- .../libcxx/include/__ranges/join_view.h | 647 +- .../libcxx/include/__ranges/lazy_split_view.h | 245 +- .../include/__ranges/non_propagating_cache.h | 129 +- .../libcxx/include/__ranges/owning_view.h | 106 +- .../libcxx/include/__ranges/range_adaptor.h | 32 +- .../llvm-project/libcxx/include/__ranges/rbegin.h | 67 +- .../libcxx/include/__ranges/ref_view.h | 80 +- .../llvm-project/libcxx/include/__ranges/rend.h | 71 +- .../libcxx/include/__ranges/reverse_view.h | 297 +- .../libcxx/include/__ranges/single_view.h | 16 +- .../llvm-project/libcxx/include/__ranges/size.h | 52 +- .../libcxx/include/__ranges/subrange.h | 356 +- .../libcxx/include/__ranges/take_view.h | 194 +- .../libcxx/include/__ranges/transform_view.h | 300 +- .../libcxx/include/__ranges/view_interface.h | 94 +- .../llvm-project/libcxx/include/__ranges/views.h | 2 +- .../libcxx/include/__ranges/zip_view.h | 235 +- contrib/llvm-project/libcxx/include/__split_buffer | 604 +- .../libcxx/include/__string/char_traits.h | 1093 ++- .../libcxx/include/__system_error/errc.h | 172 +- .../libcxx/include/__thread/formatter.h | 62 +- .../libcxx/include/__thread/poll_with_backoff.h | 37 +- .../libcxx/include/__thread/this_thread.h | 63 +- .../llvm-project/libcxx/include/__thread/thread.h | 324 +- .../libcxx/include/__thread/timed_backoff_policy.h | 28 +- .../libcxx/include/__threading_support | 410 +- contrib/llvm-project/libcxx/include/__tree | 3613 ++++---- .../libcxx/include/__tuple/make_tuple_types.h | 24 +- .../libcxx/include/__tuple/sfinae_helpers.h | 136 +- .../libcxx/include/__tuple/tuple_element.h | 64 +- .../libcxx/include/__tuple/tuple_indices.h | 10 +- .../libcxx/include/__tuple/tuple_like_ext.h | 24 +- .../libcxx/include/__tuple/tuple_size.h | 47 +- .../libcxx/include/__tuple/tuple_types.h | 3 +- .../libcxx/include/__type_traits/datasizeof.h | 11 +- .../libcxx/include/__utility/as_const.h | 4 +- .../llvm-project/libcxx/include/__utility/cmp.h | 73 +- .../libcxx/include/__utility/convert_to_integral.h | 50 +- .../libcxx/include/__utility/exchange.h | 14 +- .../libcxx/include/__utility/in_place.h | 12 +- .../libcxx/include/__utility/integer_sequence.h | 104 +- .../libcxx/include/__utility/is_pointer_in_range.h | 2 +- .../llvm-project/libcxx/include/__utility/pair.h | 1162 +-- .../libcxx/include/__utility/piecewise_construct.h | 4 +- .../libcxx/include/__utility/priority_tag.h | 6 +- .../libcxx/include/__utility/rel_ops.h | 41 +- .../libcxx/include/__utility/to_underlying.h | 6 +- .../libcxx/include/__utility/unreachable.h | 4 +- .../libcxx/include/__variant/monostate.h | 2 +- .../llvm-project/libcxx/include/__verbose_abort | 4 +- contrib/llvm-project/libcxx/include/algorithm | 30 + contrib/llvm-project/libcxx/include/any | 788 +- contrib/llvm-project/libcxx/include/array | 535 +- contrib/llvm-project/libcxx/include/barrier | 356 +- contrib/llvm-project/libcxx/include/bitset | 1290 ++- contrib/llvm-project/libcxx/include/cctype | 29 +- contrib/llvm-project/libcxx/include/cmath | 173 +- contrib/llvm-project/libcxx/include/codecvt | 776 +- contrib/llvm-project/libcxx/include/complex | 1921 ++-- .../llvm-project/libcxx/include/condition_variable | 223 +- contrib/llvm-project/libcxx/include/cstddef | 52 +- contrib/llvm-project/libcxx/include/ctype.h | 28 +- contrib/llvm-project/libcxx/include/cuchar | 2 +- contrib/llvm-project/libcxx/include/deque | 3722 ++++---- contrib/llvm-project/libcxx/include/errno.h | 522 +- contrib/llvm-project/libcxx/include/expected | 1 - .../libcxx/include/experimental/__config | 22 +- .../libcxx/include/experimental/__memory | 90 +- .../libcxx/include/experimental/__simd/abi_tag.h | 55 - .../include/experimental/__simd/aligned_tag.h | 13 +- .../include/experimental/__simd/declaration.h | 52 +- .../experimental/__simd/internal_declaration.h | 41 - .../libcxx/include/experimental/__simd/scalar.h | 2 +- .../libcxx/include/experimental/__simd/simd.h | 2 - .../libcxx/include/experimental/__simd/simd_mask.h | 2 - .../libcxx/include/experimental/__simd/traits.h | 15 +- .../libcxx/include/experimental/__simd/vec_ext.h | 6 +- .../libcxx/include/experimental/iterator | 69 +- .../libcxx/include/experimental/propagate_const | 305 +- .../llvm-project/libcxx/include/experimental/simd | 1 - .../libcxx/include/experimental/type_traits | 69 +- .../libcxx/include/experimental/utility | 2 +- contrib/llvm-project/libcxx/include/ext/__hash | 130 +- contrib/llvm-project/libcxx/include/ext/hash_map | 1132 +-- contrib/llvm-project/libcxx/include/ext/hash_set | 634 +- contrib/llvm-project/libcxx/include/fenv.h | 70 +- contrib/llvm-project/libcxx/include/float.h | 12 +- contrib/llvm-project/libcxx/include/forward_list | 2031 ++-- contrib/llvm-project/libcxx/include/fstream | 2095 ++--- contrib/llvm-project/libcxx/include/future | 2551 +++-- .../llvm-project/libcxx/include/initializer_list | 71 +- contrib/llvm-project/libcxx/include/inttypes.h | 10 +- contrib/llvm-project/libcxx/include/iomanip | 754 +- contrib/llvm-project/libcxx/include/ios | 953 +- contrib/llvm-project/libcxx/include/iosfwd | 65 +- contrib/llvm-project/libcxx/include/istream | 2051 ++-- contrib/llvm-project/libcxx/include/latch | 98 +- contrib/llvm-project/libcxx/include/limits | 1078 ++- contrib/llvm-project/libcxx/include/list | 2390 ++--- contrib/llvm-project/libcxx/include/locale | 6071 ++++++------ contrib/llvm-project/libcxx/include/locale.h | 2 +- contrib/llvm-project/libcxx/include/map | 2618 +++--- contrib/llvm-project/libcxx/include/math.h | 81 +- .../libcxx/include/module.modulemap.in | 4 +- contrib/llvm-project/libcxx/include/mutex | 467 +- contrib/llvm-project/libcxx/include/new | 220 +- contrib/llvm-project/libcxx/include/numbers | 93 +- contrib/llvm-project/libcxx/include/optional | 1759 ++-- contrib/llvm-project/libcxx/include/ostream | 1349 ++- contrib/llvm-project/libcxx/include/print | 14 +- contrib/llvm-project/libcxx/include/queue | 1008 +- contrib/llvm-project/libcxx/include/ranges | 2 +- contrib/llvm-project/libcxx/include/ratio | 396 +- contrib/llvm-project/libcxx/include/regex | 8356 +++++++---------- .../llvm-project/libcxx/include/scoped_allocator | 821 +- contrib/llvm-project/libcxx/include/semaphore | 193 +- contrib/llvm-project/libcxx/include/set | 1577 ++-- contrib/llvm-project/libcxx/include/span | 701 +- contrib/llvm-project/libcxx/include/sstream | 1274 ++- contrib/llvm-project/libcxx/include/stack | 349 +- contrib/llvm-project/libcxx/include/stdatomic.h | 18 +- contrib/llvm-project/libcxx/include/stdbool.h | 10 +- contrib/llvm-project/libcxx/include/stddef.h | 28 +- contrib/llvm-project/libcxx/include/stdexcept | 232 +- contrib/llvm-project/libcxx/include/stdint.h | 6 +- contrib/llvm-project/libcxx/include/stdio.h | 36 +- contrib/llvm-project/libcxx/include/stdlib.h | 86 +- contrib/llvm-project/libcxx/include/streambuf | 530 +- contrib/llvm-project/libcxx/include/string | 4686 +++++----- contrib/llvm-project/libcxx/include/string.h | 2 +- contrib/llvm-project/libcxx/include/string_view | 1135 +-- contrib/llvm-project/libcxx/include/strstream | 334 +- contrib/llvm-project/libcxx/include/thread | 2 +- contrib/llvm-project/libcxx/include/tuple | 2126 ++--- contrib/llvm-project/libcxx/include/typeindex | 65 +- contrib/llvm-project/libcxx/include/typeinfo | 242 +- contrib/llvm-project/libcxx/include/uchar.h | 12 +- contrib/llvm-project/libcxx/include/unordered_map | 3111 +++---- contrib/llvm-project/libcxx/include/unordered_set | 1953 ++-- contrib/llvm-project/libcxx/include/valarray | 4682 ++++------ contrib/llvm-project/libcxx/include/variant | 1235 +-- contrib/llvm-project/libcxx/include/vector | 3840 ++++---- contrib/llvm-project/libcxx/include/version | 6 +- contrib/llvm-project/libcxx/include/wchar.h | 157 +- contrib/llvm-project/libcxx/include/wctype.h | 43 +- .../llvm-project/libcxx/modules/std/algorithm.inc | 16 +- .../llvm-project/libcxx/modules/std/ostream.inc | 5 +- contrib/llvm-project/libcxx/src/any.cpp | 16 +- contrib/llvm-project/libcxx/src/atomic.cpp | 216 +- contrib/llvm-project/libcxx/src/barrier.cpp | 106 +- contrib/llvm-project/libcxx/src/bind.cpp | 23 +- contrib/llvm-project/libcxx/src/call_once.cpp | 62 +- contrib/llvm-project/libcxx/src/charconv.cpp | 33 +- contrib/llvm-project/libcxx/src/chrono.cpp | 118 +- .../llvm-project/libcxx/src/condition_variable.cpp | 95 +- .../libcxx/src/condition_variable_destructor.cpp | 20 +- contrib/llvm-project/libcxx/src/exception.cpp | 28 +- .../libcxx/src/filesystem/directory_entry.cpp | 9 +- .../libcxx/src/filesystem/directory_iterator.cpp | 84 +- contrib/llvm-project/libcxx/src/filesystem/error.h | 24 +- .../libcxx/src/filesystem/file_descriptor.h | 53 +- .../libcxx/src/filesystem/filesystem_clock.cpp | 20 +- .../libcxx/src/filesystem/filesystem_error.cpp | 12 +- .../libcxx/src/filesystem/int128_builtins.cpp | 14 +- .../libcxx/src/filesystem/operations.cpp | 323 +- .../llvm-project/libcxx/src/filesystem/path.cpp | 79 +- .../libcxx/src/filesystem/path_parser.h | 58 +- .../libcxx/src/filesystem/posix_compat.h | 231 +- .../libcxx/src/filesystem/time_utils.h | 164 +- contrib/llvm-project/libcxx/src/functional.cpp | 10 +- contrib/llvm-project/libcxx/src/future.cpp | 319 +- contrib/llvm-project/libcxx/src/hash.cpp | 899 +- .../libcxx/src/include/apple_availability.h | 34 +- .../libcxx/src/include/atomic_support.h | 156 +- .../llvm-project/libcxx/src/include/config_elast.h | 18 +- .../llvm-project/libcxx/src/include/refstring.h | 137 +- contrib/llvm-project/libcxx/src/include/ryu/ryu.h | 1 - .../libcxx/src/include/sso_allocator.h | 81 +- contrib/llvm-project/libcxx/src/ios.cpp | 569 +- contrib/llvm-project/libcxx/src/iostream.cpp | 165 +- contrib/llvm-project/libcxx/src/locale.cpp | 9786 +++++++++----------- contrib/llvm-project/libcxx/src/memory.cpp | 229 +- contrib/llvm-project/libcxx/src/mutex.cpp | 207 +- .../llvm-project/libcxx/src/mutex_destructor.cpp | 20 +- contrib/llvm-project/libcxx/src/optional.cpp | 14 +- contrib/llvm-project/libcxx/src/ostream.cpp | 42 + contrib/llvm-project/libcxx/src/random.cpp | 181 +- contrib/llvm-project/libcxx/src/random_shuffle.cpp | 35 +- contrib/llvm-project/libcxx/src/regex.cpp | 293 +- contrib/llvm-project/libcxx/src/std_stream.h | 572 +- contrib/llvm-project/libcxx/src/string.cpp | 368 +- .../libcxx/src/support/ibm/mbsnrtowcs.cpp | 30 +- .../libcxx/src/support/ibm/wcsnrtombs.cpp | 27 +- .../libcxx/src/support/ibm/xlocale_zos.cpp | 44 +- .../src/support/runtime/exception_fallback.ipp | 139 +- .../src/support/runtime/exception_glibcxx.ipp | 18 +- .../src/support/runtime/exception_libcxxabi.ipp | 15 +- .../src/support/runtime/exception_libcxxrt.ipp | 11 +- .../libcxx/src/support/runtime/exception_msvc.ipp | 145 +- .../support/runtime/exception_pointer_cxxabi.ipp | 73 +- .../support/runtime/exception_pointer_glibcxx.ipp | 61 +- .../src/support/runtime/exception_pointer_msvc.ipp | 22 +- .../runtime/exception_pointer_unimplemented.ipp | 43 +- .../src/support/runtime/stdexcept_default.ipp | 8 +- .../src/support/runtime/stdexcept_vcruntime.ipp | 2 +- contrib/llvm-project/libcxx/src/system_error.cpp | 225 +- contrib/llvm-project/libcxx/src/thread.cpp | 222 +- contrib/llvm-project/libcxx/src/typeinfo.cpp | 30 +- contrib/llvm-project/libcxx/src/valarray.cpp | 56 +- contrib/llvm-project/libcxx/src/variant.cpp | 6 +- contrib/llvm-project/libcxx/src/vector.cpp | 8 +- contrib/llvm-project/libcxx/src/verbose_abort.cpp | 6 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 20 + contrib/llvm-project/lld/ELF/InputSection.cpp | 22 +- contrib/llvm-project/lld/MachO/InputFiles.h | 2 +- contrib/llvm-project/lld/MachO/Options.td | 2 +- .../lldb/bindings/python/python-typemaps.swig | 2 +- .../lldb/include/lldb/Core/ValueObject.h | 8 - .../lldb/include/lldb/Host/HostGetOpt.h | 4 - .../lldb/include/lldb/Utility/FileSpec.h | 19 - contrib/llvm-project/lldb/source/API/SBValue.cpp | 11 +- .../llvm-project/lldb/source/Core/ValueObject.cpp | 40 - .../lldb/source/Host/common/FileSystem.cpp | 1 - .../lldb/source/Interpreter/CommandInterpreter.cpp | 6 +- .../SymbolFile/DWARF/DWARFASTParserClang.cpp | 2 +- .../lldb/source/Target/JITLoaderList.cpp | 2 +- .../llvm-project/llvm/include/llvm/ADT/StringRef.h | 8 +- contrib/llvm-project/llvm/include/llvm/ADT/Twine.h | 2 +- .../llvm/include/llvm/Analysis/LazyValueInfo.h | 9 +- .../llvm/include/llvm/Analysis/TargetLibraryInfo.h | 10 + .../include/llvm/Analysis/TargetTransformInfo.h | 4 + .../llvm/include/llvm/Analysis/ValueLattice.h | 5 +- .../llvm/include/llvm/Analysis/ValueTracking.h | 5 + .../llvm/include/llvm/Analysis/VecFuncs.def | 2 + .../llvm/include/llvm/Analysis/VectorUtils.h | 10 + .../llvm/include/llvm/CodeGen/AccelTable.h | 8 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 9 +- .../llvm/include/llvm/CodeGen/LowerEmuTLS.h | 29 + .../include/llvm/CodeGen/MachinePassRegistry.def | 7 +- .../llvm/include/llvm/CodeGen/MacroFusion.h | 12 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 2 + .../llvm/include/llvm/CodeGen/TargetLowering.h | 6 + .../llvm/CodeGen/TargetLoweringObjectFileImpl.h | 2 + .../llvm/include/llvm/Frontend/HLSL/HLSLResource.h | 27 +- .../llvm-project/llvm/include/llvm/IR/Constants.h | 7 +- .../llvm/include/llvm/IR/DiagnosticHandler.h | 1 + .../llvm/IR/GenericConvergenceVerifierImpl.h | 13 +- .../llvm/include/llvm/IR/GlobalValue.h | 4 + .../llvm/include/llvm/IR/IntrinsicInst.h | 24 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 28 +- .../llvm/include/llvm/IR/IntrinsicsRISCV.td | 2 +- .../llvm/include/llvm/IR/PatternMatch.h | 26 + .../llvm-project/llvm/include/llvm/MC/MCAsmInfo.h | 3 +- .../llvm/include/llvm/MC/MCTargetOptions.h | 2 + .../llvm/include/llvm/Object/ELFObjectFile.h | 1 + .../llvm-project/llvm/include/llvm/Object/Wasm.h | 1 - .../llvm/ProfileData/Coverage/CoverageMapping.h | 2 +- .../llvm/include/llvm/ProfileData/InstrProf.h | 26 +- .../include/llvm/ProfileData/RawMemProfReader.h | 11 +- .../llvm/include/llvm/ProfileData/SampleProf.h | 4 +- .../llvm/include/llvm/Support/CommandLine.h | 27 +- .../llvm/include/llvm/Support/YAMLTraits.h | 17 +- .../llvm/include/llvm/Support/raw_ostream.h | 49 - .../llvm/include/llvm/Support/raw_socket_stream.h | 66 + .../llvm/TargetParser/AArch64TargetParser.h | 9 +- .../llvm/TargetParser/ARMTargetParserCommon.h | 1 + .../llvm/include/llvm/TextAPI/DylibReader.h | 48 + .../llvm/include/llvm/TextAPI/Record.h | 13 +- .../llvm/include/llvm/TextAPI/RecordVisitor.h | 54 + .../llvm/include/llvm/TextAPI/RecordsSlice.h | 14 +- .../llvm/include/llvm/TextAPI/TextAPIError.h | 3 +- .../llvm-project/llvm/include/llvm/TextAPI/Utils.h | 34 + .../llvm/include/llvm/Transforms/IPO/Attributor.h | 10 + .../llvm/Transforms/IPO/ProfiledCallGraph.h | 5 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 2 +- .../llvm/lib/Analysis/LazyValueInfo.cpp | 18 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 2 +- .../llvm/lib/Analysis/MemoryDependenceAnalysis.cpp | 18 +- .../llvm/lib/Analysis/ScalarEvolution.cpp | 7 +- .../llvm/lib/Analysis/TargetLibraryInfo.cpp | 10 + .../llvm/lib/Analysis/VFABIDemangling.cpp | 4 +- .../llvm/lib/Analysis/ValueTracking.cpp | 126 +- .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 28 + .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 4 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 1 + .../CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 62 +- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.h | 45 +- .../llvm/lib/CodeGen/LiveRangeEdit.cpp | 3 +- .../llvm-project/llvm/lib/CodeGen/LowerEmuTLS.cpp | 53 +- .../llvm/lib/CodeGen/MachineInstrBundle.cpp | 6 +- .../llvm-project/llvm/lib/CodeGen/MacroFusion.cpp | 12 +- .../llvm-project/llvm/lib/CodeGen/RegAllocFast.cpp | 139 +- .../llvm/lib/CodeGen/RegisterClassInfo.cpp | 3 +- .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 57 +- .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 211 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 19 +- .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 3 +- .../CodeGen/SelectionDAG/FunctionLoweringInfo.cpp | 3 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 18 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 23 + .../CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp | 17 + .../llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h | 2 + .../lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp | 12 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 6 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 3 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 24 +- .../llvm/lib/CodeGen/ShadowStackGCLowering.cpp | 7 +- .../lib/CodeGen/TargetLoweringObjectFileImpl.cpp | 7 + .../llvm/lib/CodeGen/TargetPassConfig.cpp | 1 + .../llvm/lib/CodeGen/TwoAddressInstructionPass.cpp | 3 +- .../lib/ExecutionEngine/JITLink/MachO_arm64.cpp | 32 +- .../lib/ExecutionEngine/JITLink/MachO_x86_64.cpp | 32 +- .../llvm/lib/Frontend/HLSL/HLSLResource.cpp | 17 +- contrib/llvm-project/llvm/lib/IR/ConstantFold.cpp | 2 +- contrib/llvm-project/llvm/lib/IR/Globals.cpp | 12 +- contrib/llvm-project/llvm/lib/IR/LLVMContext.cpp | 11 +- contrib/llvm-project/llvm/lib/IR/Metadata.cpp | 2 +- contrib/llvm-project/llvm/lib/IR/Type.cpp | 2 + contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 11 +- contrib/llvm-project/llvm/lib/MC/MCAsmStreamer.cpp | 5 +- contrib/llvm-project/llvm/lib/MC/MCContext.cpp | 14 +- contrib/llvm-project/llvm/lib/MC/MCExpr.cpp | 24 +- .../llvm/lib/ObjCopy/ELF/ELFObject.cpp | 2 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 69 + .../llvm/lib/Object/ModuleSymbolTable.cpp | 16 +- .../llvm/lib/Object/WasmObjectFile.cpp | 52 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassRegistry.def | 1 + .../llvm/lib/ProfileData/InstrProf.cpp | 36 +- .../llvm/lib/ProfileData/InstrProfReader.cpp | 9 +- .../llvm/lib/ProfileData/RawMemProfReader.cpp | 25 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 78 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 83 +- contrib/llvm-project/llvm/lib/Support/Signals.cpp | 2 +- .../llvm-project/llvm/lib/Support/raw_ostream.cpp | 163 +- .../llvm/lib/Support/raw_socket_stream.cpp | 179 + .../llvm/lib/Target/AArch64/AArch64.td | 19 +- .../llvm/lib/Target/AArch64/AArch64Combine.td | 11 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 18 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 11 +- .../llvm/lib/Target/AArch64/AArch64InstrFormats.td | 126 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 36 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.h | 3 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.td | 75 +- .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 229 + .../Target/AArch64/AArch64MachineFunctionInfo.cpp | 28 +- .../Target/AArch64/AArch64MachineFunctionInfo.h | 18 + .../llvm/lib/Target/AArch64/AArch64PointerAuth.cpp | 86 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 61 +- .../llvm/lib/Target/AArch64/AArch64SchedA64FX.td | 9 +- .../lib/Target/AArch64/AArch64SchedNeoverseN2.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV1.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV2.td | 2 +- .../lib/Target/AArch64/AArch64SystemOperands.td | 27 + .../Target/AArch64/AsmParser/AArch64AsmParser.cpp | 47 + .../AArch64/Disassembler/AArch64Disassembler.cpp | 18 + .../AArch64/GISel/AArch64InstructionSelector.cpp | 62 - .../AArch64/GISel/AArch64PostLegalizerLowering.cpp | 21 + .../AArch64/MCTargetDesc/AArch64AsmBackend.cpp | 14 + .../MCTargetDesc/AArch64ELFObjectWriter.cpp | 4 + .../AArch64/MCTargetDesc/AArch64FixupKinds.h | 5 + .../AArch64/MCTargetDesc/AArch64MCCodeEmitter.cpp | 29 + .../llvm/lib/Target/AArch64/SMEInstrFormats.td | 26 +- .../llvm/lib/Target/AArch64/SVEInstrFormats.td | 31 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 4 +- .../llvm/lib/Target/AMDGPU/AMDGPUIGroupLP.cpp | 29 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 37 +- .../Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp | 8 +- .../llvm/lib/Target/AMDGPU/AMDGPULibCalls.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp | 18 + .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 7 + .../Target/AMDGPU/AMDGPUTargetTransformInfo.cpp | 8 + .../lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h | 10 + .../llvm/lib/Target/AMDGPU/DSInstructions.td | 12 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 5 + .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 21 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 20 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 79 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 3 + .../llvm/lib/Target/ARM/ARMFrameLowering.cpp | 33 +- .../llvm/lib/Target/ARM/ARMFrameLowering.h | 3 + .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 58 + .../llvm/lib/Target/ARM/ARMISelLowering.h | 10 + .../llvm/lib/Target/ARM/ARMInstrVFP.td | 1 + .../llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp | 6 +- .../llvm/lib/Target/DirectX/DXILResource.cpp | 92 +- .../llvm/lib/Target/DirectX/DXILResource.h | 37 +- .../DirectX/DXILWriter/DXILBitcodeWriter.cpp | 3 +- .../lib/Target/Hexagon/HexagonConstPropagation.cpp | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 6 +- .../Target/Hexagon/HexagonLoopIdiomRecognition.cpp | 6 +- .../Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp | 2 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 78 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 9 +- .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 4 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 9 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | 8 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.td | 3 + .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 7 +- .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 9 + .../llvm/lib/Target/RISCV/RISCVFeatures.td | 86 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 3 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 182 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 7 +- .../llvm/lib/Target/RISCV/RISCVInstrFormats.td | 9 + .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 8 - .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 125 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td | 12 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZvk.td | 2 +- .../llvm/lib/Target/RISCV/RISCVMacroFusion.cpp | 82 +- .../llvm/lib/Target/RISCV/RISCVProcessors.td | 27 +- .../llvm/lib/Target/RISCV/RISCVSchedSiFive7.td | 1 + .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 18 +- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 2 +- .../llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp | 4 +- .../llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp | 6 +- .../llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp | 6 +- .../llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp | 2 +- .../llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.h | 2 +- .../llvm/lib/Target/SPIRV/SPIRVPreLegalizer.cpp | 2 +- .../SystemZ/MCTargetDesc/SystemZMCAsmInfo.cpp | 1 + .../llvm/lib/Target/SystemZ/SystemZAsmPrinter.cpp | 35 +- .../lib/Target/SystemZ/SystemZFrameLowering.cpp | 6 + .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 3 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 10 + .../llvm/lib/Target/SystemZ/SystemZISelLowering.h | 8 +- .../llvm-project/llvm/lib/Target/TargetMachine.cpp | 4 +- .../llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp | 36 +- .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 2 +- .../llvm/lib/Target/X86/X86FastISel.cpp | 7 +- .../llvm/lib/Target/X86/X86FloatingPoint.cpp | 3 +- .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 31 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 36 +- .../llvm/lib/Target/X86/X86InsertPrefetch.cpp | 6 +- .../llvm/lib/Target/X86/X86InstrAMX.td | 30 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 1082 +-- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1457 ++- .../llvm/lib/Target/X86/X86InstrAsmAlias.td | 13 + .../llvm/lib/Target/X86/X86InstrCompiler.td | 17 + .../llvm/lib/Target/X86/X86InstrFPStack.td | 8 +- .../llvm/lib/Target/X86/X86InstrFormats.td | 7 +- .../llvm/lib/Target/X86/X86InstrInfo.cpp | 8 +- .../llvm-project/llvm/lib/Target/X86/X86InstrKL.td | 22 +- .../llvm/lib/Target/X86/X86InstrMMX.td | 24 +- .../llvm/lib/Target/X86/X86InstrMisc.td | 211 +- .../llvm/lib/Target/X86/X86InstrRAOINT.td | 8 +- .../llvm/lib/Target/X86/X86InstrSGX.td | 6 +- .../llvm/lib/Target/X86/X86InstrSNP.td | 12 +- .../llvm/lib/Target/X86/X86InstrSSE.td | 952 +- .../llvm/lib/Target/X86/X86InstrShiftRotate.td | 28 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 141 +- .../llvm/lib/Target/X86/X86InstrTBM.td | 4 +- .../llvm/lib/Target/X86/X86InstrTDX.td | 14 +- .../llvm/lib/Target/X86/X86InstrTSX.td | 4 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 284 +- .../llvm/lib/Target/X86/X86InstrVMX.td | 38 +- .../llvm/lib/Target/X86/X86InstrXOP.td | 28 +- .../llvm/lib/Target/X86/X86MacroFusion.cpp | 3 +- .../llvm/lib/Target/X86/X86Subtarget.cpp | 9 +- .../lib/TargetParser/ARMTargetParserCommon.cpp | 6 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 52 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 15 +- .../llvm/lib/TextAPI/BinaryReader/DylibReader.cpp | 429 + .../llvm/lib/TextAPI/RecordVisitor.cpp | 65 + .../llvm-project/llvm/lib/TextAPI/RecordsSlice.cpp | 120 +- contrib/llvm-project/llvm/lib/TextAPI/Utils.cpp | 40 + .../lib/ToolDrivers/llvm-dlltool/DlltoolDriver.cpp | 2 +- .../lib/Transforms/IPO/AttributorAttributes.cpp | 53 +- .../llvm/lib/Transforms/IPO/OpenMPOpt.cpp | 18 +- .../llvm/lib/Transforms/IPO/SampleProfile.cpp | 13 +- .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 49 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 59 +- .../Transforms/InstCombine/InstCombineInternal.h | 17 +- .../InstCombine/InstCombineMulDivRem.cpp | 7 + .../Transforms/InstCombine/InstCombineSelect.cpp | 4 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 134 +- .../InstCombine/InstCombineVectorOps.cpp | 44 +- .../InstCombine/InstructionCombining.cpp | 106 +- .../Instrumentation/AddressSanitizer.cpp | 2 +- .../lib/Transforms/Instrumentation/MemProfiler.cpp | 2 +- .../Instrumentation/SanitizerCoverage.cpp | 2 +- .../lib/Transforms/Scalar/ConstantHoisting.cpp | 5 +- .../Transforms/Scalar/ConstraintElimination.cpp | 75 +- .../Scalar/CorrelatedValuePropagation.cpp | 6 +- .../lib/Transforms/Scalar/DFAJumpThreading.cpp | 2 +- .../llvm/lib/Transforms/Scalar/GVN.cpp | 2 +- .../llvm/lib/Transforms/Scalar/LoopFlatten.cpp | 5 +- .../lib/Transforms/Scalar/LoopStrengthReduce.cpp | 2 +- *** 229498 LINES SKIPPED *** From nobody Sat Apr 20 10:32:11 2024 X-Original-To: dev-commits-src-branches@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 4VM79m11ZKz5HW0K; Sat, 20 Apr 2024 10:32:12 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79l6JQvz4P6h; Sat, 20 Apr 2024 10:32:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609131; 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=MmrI62zOiosAxQxb8BWiseBFRhKmcdtCtHJtd+h605Y=; b=fVJ/EHR36Q+UDhPkq78RZI3crec7U24wTDg2vIPsUMPnyE7WSTBS56fGKOOgbOVSmxaQXd mJmCsx+j4hX650EWYRxDxE387dLXUGpmrhF4L01siCXMZH/y0M36fu0C7BIkReDtw8ghBC ykSNinb5DLVqCO90R1yExpu9Si0/85rB2SNTFsPraKxuMBivEQfM1z8gNs8CqMg9MdkB/w 9jfSvt3sG7MNnZCAano7VEGXJ0+TX/lB2UnsUfkZwSWtOPsbebZLET3OfmBDFgkN5dUyde +KmcuHwHUtBYWVRY2eFfkirxXs54KFbG9bcaLctltuIJQ7gtltU5mynDTT54fA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609131; a=rsa-sha256; cv=none; b=S8nKOeUFP/BPcbmGNVS/IMmZeEBaUKuN5UrGTxv7TQz5FFtJ8q1ZHCwFG1UlJUrBhBajtc FjcQGidTNHv3ayq7w6OW9qn54lHuhhqQRmJqHDKpFUx7DH+xz/MLMf6vUcxpCF8ft88V+j 6piRdCpw7aMygnlMhS0yM8MBApvpfKOASqMCkpNW7cGEu+OdGDbQbJD29kZ+eAUoH+a78A t9SJV26AeG5wtt9Z6GUFoUOsSHMZwr04rnmme1Hgl7n0SmjIoyRFckixJGAbyQVi4YFgrA 19hMO7eO8pm0dcoX6TFI9ecY0yYam3fypHfpE5kXmU1JyKDp/PcUQTqfyiTPtA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609131; 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=MmrI62zOiosAxQxb8BWiseBFRhKmcdtCtHJtd+h605Y=; b=Yj/Eq0GdtO1kEq4mDDHKgFO9QrFO0Tce/6ZFQJCoYrBNVMdciVDDKuLNr16SgKtLTl7EjL 1mlVvKQFyOj62wCnHELWbw5sIXvwQ+nQ4Jlbnrs2TT+oiVyLzcpb23PC6tgaOjld+KytO0 8MNgu/C6XT4i6UhV+vqLILzwGcUxsIKKiucyrQWRHX/faQi7Q8RVubctMV2A6BdcfQhziJ yj0SyEz9Pcys0ZdIlfXt/AN9RNkJBTt/DttzhR0l+3Auvx/weWyC6Lf8hsgGtUKbXGQZz2 7eM/ghEfZTjKViYARNJYg91UZhEOD8SlXjzMkS98H90s9H4uDfZheS2kVLCnmw== 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 4VM79l5wY7zYTx; Sat, 20 Apr 2024 10:32:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWBPo009441; Sat, 20 Apr 2024 10:32:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWBwN009438; Sat, 20 Apr 2024 10:32:11 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:11 GMT Message-Id: <202404201032.43KAWBwN009438@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: 7e83d42fa416 - stable/14 - Revert commit 0e46b49de433 from llvm-project (by Matt Arsenault): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 7e83d42fa4164d54298ae7263fe44bddfe156536 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7e83d42fa4164d54298ae7263fe44bddfe156536 commit 7e83d42fa4164d54298ae7263fe44bddfe156536 Author: Dimitry Andric AuthorDate: 2024-01-02 16:07:31 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:12:23 +0000 Revert commit 0e46b49de433 from llvm-project (by Matt Arsenault): Reapply "RegisterCoalescer: Add implicit-def of super register when coalescing SUBREG_TO_REG" This reverts commit c398fa009a47eb24f88383d5e911e59e70f8db86. PPC backend was fixed in 2f82662ce901c6666fceb9c6c5e0de216a1c9667 Since it causes an assertion failure building /sys/dev/fb/vga.c: https://github.com/llvm/llvm-project/issues/76416 PR: 276104 MFC after: 1 month (cherry picked from commit edc2dc17b1f2dfe45dc85e6cc0ff54bca1ac8214) --- .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 51 ++++------------------ 1 file changed, 9 insertions(+), 42 deletions(-) diff --git a/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp b/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp index 3fbb93795075..cbb1a74049fb 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp @@ -305,11 +305,7 @@ namespace { /// number if it is not zero. If DstReg is a physical register and the /// existing subregister number of the def / use being updated is not zero, /// make sure to set it to the correct physical subregister. - /// - /// If \p IsSubregToReg, we are coalescing a DstReg = SUBREG_TO_REG - /// SrcReg. This introduces an implicit-def of DstReg on coalesced users. - void updateRegDefsUses(Register SrcReg, Register DstReg, unsigned SubIdx, - bool IsSubregToReg); + void updateRegDefsUses(Register SrcReg, Register DstReg, unsigned SubIdx); /// If the given machine operand reads only undefined lanes add an undef /// flag. @@ -1347,7 +1343,8 @@ bool RegisterCoalescer::reMaterializeTrivialDef(const CoalescerPair &CP, if (DstReg.isPhysical()) { Register NewDstReg = DstReg; - unsigned NewDstIdx = TRI->composeSubRegIndices(CP.getSrcIdx(), DefSubIdx); + unsigned NewDstIdx = TRI->composeSubRegIndices(CP.getSrcIdx(), + DefMI->getOperand(0).getSubReg()); if (NewDstIdx) NewDstReg = TRI->getSubReg(DstReg, NewDstIdx); @@ -1496,7 +1493,7 @@ bool RegisterCoalescer::reMaterializeTrivialDef(const CoalescerPair &CP, MRI->setRegClass(DstReg, NewRC); // Update machine operands and add flags. - updateRegDefsUses(DstReg, DstReg, DstIdx, false); + updateRegDefsUses(DstReg, DstReg, DstIdx); NewMI.getOperand(0).setSubReg(NewIdx); // updateRegDefUses can add an "undef" flag to the definition, since // it will replace DstReg with DstReg.DstIdx. If NewIdx is 0, make @@ -1816,7 +1813,7 @@ void RegisterCoalescer::addUndefFlag(const LiveInterval &Int, SlotIndex UseIdx, } void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, - unsigned SubIdx, bool IsSubregToReg) { + unsigned SubIdx) { bool DstIsPhys = DstReg.isPhysical(); LiveInterval *DstInt = DstIsPhys ? nullptr : &LIS->getInterval(DstReg); @@ -1856,8 +1853,6 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, if (DstInt && !Reads && SubIdx && !UseMI->isDebugInstr()) Reads = DstInt->liveAt(LIS->getInstructionIndex(*UseMI)); - bool FullDef = true; - // Replace SrcReg with DstReg in all UseMI operands. for (unsigned i = 0, e = Ops.size(); i != e; ++i) { MachineOperand &MO = UseMI->getOperand(Ops[i]); @@ -1865,13 +1860,9 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, // Adjust flags in case of sub-register joins. We don't want to // turn a full def into a read-modify-write sub-register def and vice // versa. - if (SubIdx && MO.isDef()) { + if (SubIdx && MO.isDef()) MO.setIsUndef(!Reads); - if (!Reads) - FullDef = false; - } - // A subreg use of a partially undef (super) register may be a complete // undef use now and then has to be marked that way. if (MO.isUse() && !DstIsPhys) { @@ -1903,25 +1894,6 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, MO.substVirtReg(DstReg, SubIdx, *TRI); } - if (IsSubregToReg && !FullDef) { - // If the coalesed instruction doesn't fully define the register, we need - // to preserve the original super register liveness for SUBREG_TO_REG. - // - // We pretended SUBREG_TO_REG was a regular copy for coalescing purposes, - // but it introduces liveness for other subregisters. Downstream users may - // have been relying on those bits, so we need to ensure their liveness is - // captured with a def of other lanes. - - // FIXME: Need to add new subrange if tracking subranges. We could also - // skip adding this if we knew the other lanes are dead, and only for - // other lanes. - - assert(!MRI->shouldTrackSubRegLiveness(DstReg) && - "this should update subranges"); - MachineInstrBuilder MIB(*MF, UseMI); - MIB.addReg(DstReg, RegState::ImplicitDefine); - } - LLVM_DEBUG({ dbgs() << "\t\tupdated: "; if (!UseMI->isDebugInstr()) @@ -2121,8 +2093,6 @@ bool RegisterCoalescer::joinCopy(MachineInstr *CopyMI, bool &Again) { }); } - const bool IsSubregToReg = CopyMI->isSubregToReg(); - ShrinkMask = LaneBitmask::getNone(); ShrinkMainRange = false; @@ -2190,12 +2160,9 @@ bool RegisterCoalescer::joinCopy(MachineInstr *CopyMI, bool &Again) { // Rewrite all SrcReg operands to DstReg. // Also update DstReg operands to include DstIdx if it is set. - if (CP.getDstIdx()) { - assert(!IsSubregToReg && "can this happen?"); - updateRegDefsUses(CP.getDstReg(), CP.getDstReg(), CP.getDstIdx(), false); - } - updateRegDefsUses(CP.getSrcReg(), CP.getDstReg(), CP.getSrcIdx(), - IsSubregToReg); + if (CP.getDstIdx()) + updateRegDefsUses(CP.getDstReg(), CP.getDstReg(), CP.getDstIdx()); + updateRegDefsUses(CP.getSrcReg(), CP.getDstReg(), CP.getSrcIdx()); // Shrink subregister ranges if necessary. if (ShrinkMask.any()) { From nobody Sat Apr 20 10:32:12 2024 X-Original-To: dev-commits-src-branches@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 4VM79n6dQRz5HW4Z; Sat, 20 Apr 2024 10:32:13 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79n43z5z4Nw7; Sat, 20 Apr 2024 10:32:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609133; 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=wp1i/C1UUng/LtHwrHIBOorxyTLdGPgKTe2zL8dflQY=; b=Noc+/+V7pB3F+TgxbK25FuULUjlfNECQuDei5+ZYtakIkwbgzDb9RkV7Owa4IS+saiXWPc /rIhGr/nygLA1Jz1shlpSMDCTOEhXznjr4infZ+xBBi+SDeaYtKLFmTd85iQxwGFJBmL3p 3X7NlvLPWQYPoUmA4QI2oJd7FJd6N/m6jwEg99H8ePOVsZiujt5guGOaYihdsHwTr5GaSW YEwtdSH7b8KqCwS/QjnWrzR9fcOa2H43zgbwTVlvYYxxVvS9tj/Ofkfyo03Xush2QcP61O uJhUxcNFMKmrfpxpwgPGzJzDkGfm43b4a6S9+o0yO7YTcMjA81zuMIINrtN8Tg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609133; a=rsa-sha256; cv=none; b=s3Lsj6ykI3Q2LbVDMN+GTcytAO66Al3k4Okcqkv6k/J+NFRRP3yP4l/sLytOrw9tzeBHe8 GUGszCupCiIsV0wEhEu93hPklPh35wDNvVAiH+PAnqRsczpU+T5FsVDslhsgkTzHuI0kDh e3jYLAQF9x1KjiBspnkIY4pvougubsVHD/pWUpzKTkD3IGF1z7UptraxSCLbMo+y/AOmNZ zi/1osEbf732SpDMDMYP0krg6+olDn/ii7VjYWLEzVF/WvWOR2iNfebom2YgaEDPC6Ow52 DGzEOV4h1Il+yvSgsYIMwn3ojLqbbVRLUHkQhlQHzXS+iuym3bAn8flNr+0UiQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609133; 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=wp1i/C1UUng/LtHwrHIBOorxyTLdGPgKTe2zL8dflQY=; b=qQlfli5J6VYsja0Bg7RsbKYMcNrBIc8Ju8v+gxsE6nqJH8s7Yz0gU9fT87LE6o4GUQuKLp GmM5jg3imUexuJC+JO8a92Bvxvio4z0qzDeuc/4W0sL7y3+ACs0c4gPWewjKVAKL6MY3sr PZUE9ur32wLHeeXYeX/grYoIMMEDXpmXteSBNuYnnS8oDfJ4aTABHYfd7aXDnCw+gzA0ul 7ye9/7aY9u4toPbOXNho7N34xzAhAuOzM4qbfkQ6HqXtdejoLpCCE4DvVojOdjIKGlVX9d 4V51H4j25c49+UieZilotgDmvPzWVkM1rNhDV4icWkXxSw7R8t6saW3xhidj3w== 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 4VM79n3g45zYk1; Sat, 20 Apr 2024 10:32:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWD7R009486; Sat, 20 Apr 2024 10:32:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWCg3009483; Sat, 20 Apr 2024 10:32:12 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:12 GMT Message-Id: <202404201032.43KAWCg3009483@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: de8261c4acc0 - stable/14 - Merge llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: de8261c4acc05c067efbbc8dbcbe7a72b439adef Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=de8261c4acc05c067efbbc8dbcbe7a72b439adef commit de8261c4acc05c067efbbc8dbcbe7a72b439adef Author: Dimitry Andric AuthorDate: 2024-01-03 18:04:11 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:13:53 +0000 Merge llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4. PR: 276104 MFC after: 1 month (cherry picked from commit 647cbc5de815c5651677bf8582797f716ec7b48d) --- ObsoleteFiles.inc | 105 +- .../llvm-project/clang/include/clang/AST/Type.h | 26 - .../clang/include/clang/Basic/BuiltinsAArch64.def | 3 + .../include/clang/Basic/riscv_sifive_vector.td | 28 +- .../clang/include/clang/Basic/riscv_vector.td | 8 +- .../include/clang/Basic/riscv_vector_common.td | 2 +- .../Core/BugReporter/CommonBugCategories.h | 1 + .../include/clang/StaticAnalyzer/Core/Checker.h | 14 +- .../clang/StaticAnalyzer/Core/CheckerManager.h | 11 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 1 - .../clang/lib/ASTMatchers/Dynamic/Parser.cpp | 6 +- .../clang/lib/Basic/IdentifierTable.cpp | 3 +- .../clang/lib/Basic/Targets/AArch64.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 3 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 6 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 20 + .../clang/lib/CodeGen/CGStmtOpenMP.cpp | 61 +- .../clang/lib/CodeGen/CodeGenAction.cpp | 3 +- .../clang/lib/CodeGen/Targets/LoongArch.cpp | 7 - contrib/llvm-project/clang/lib/Driver/Driver.cpp | 14 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 13 +- .../clang/lib/Driver/ToolChains/Arch/X86.cpp | 4 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 7 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 23 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 12 +- .../clang/lib/Driver/ToolChains/Solaris.cpp | 3 +- .../clang/lib/Format/ContinuationIndenter.cpp | 2 +- .../clang/lib/Format/MatchFilePath.cpp | 4 +- .../clang/lib/Frontend/DependencyGraph.cpp | 3 +- .../clang/lib/Frontend/LayoutOverrideSource.cpp | 9 +- .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 3 +- .../llvm-project/clang/lib/Headers/usermsrintrin.h | 21 + .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 47 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 8 + contrib/llvm-project/clang/lib/Sema/SemaModule.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 2 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 2 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 11 +- .../StaticAnalyzer/Checkers/ArrayBoundChecker.cpp | 7 +- .../Checkers/BasicObjCFoundationChecks.cpp | 2 +- .../Checkers/BlockInCriticalSectionChecker.cpp | 57 +- .../Checkers/BoolAssignmentChecker.cpp | 7 +- .../lib/StaticAnalyzer/Checkers/CStringChecker.cpp | 382 +++--- .../StaticAnalyzer/Checkers/CXXDeleteChecker.cpp | 24 +- .../Checkers/CallAndMessageChecker.cpp | 9 +- .../StaticAnalyzer/Checkers/CastSizeChecker.cpp | 6 +- .../StaticAnalyzer/Checkers/CheckObjCDealloc.cpp | 48 +- .../Checkers/CheckSecuritySyntaxOnly.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/ChrootChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/CloneChecker.cpp | 15 +- .../StaticAnalyzer/Checkers/ConversionChecker.cpp | 7 +- .../Checkers/DebugContainerModeling.cpp | 15 +- .../Checkers/DebugIteratorModeling.cpp | 15 +- .../lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp | 16 +- .../StaticAnalyzer/Checkers/DynamicTypeChecker.cpp | 10 +- .../Checkers/EnumCastOutOfRangeChecker.cpp | 8 +- .../Checkers/ExprInspectionChecker.cpp | 8 +- .../Checkers/FixedAddressChecker.cpp | 6 +- .../Checkers/InvalidatedIteratorChecker.cpp | 28 +- .../clang/lib/StaticAnalyzer/Checkers/Iterator.cpp | 14 +- .../clang/lib/StaticAnalyzer/Checkers/Iterator.h | 15 +- .../StaticAnalyzer/Checkers/IteratorModeling.cpp | 49 +- .../Checkers/IteratorRangeChecker.cpp | 20 +- .../Checkers/LocalizationChecker.cpp | 12 +- .../Checkers/MPI-Checker/MPIBugReporter.cpp | 6 +- .../Checkers/MPI-Checker/MPIBugReporter.h | 21 +- .../Checkers/MacOSKeychainAPIChecker.cpp | 22 +- .../StaticAnalyzer/Checkers/MacOSXAPIChecker.cpp | 10 +- .../Checkers/MismatchedIteratorChecker.cpp | 49 +- .../Checkers/MmapWriteExecChecker.cpp | 16 +- .../Checkers/NSAutoreleasePoolChecker.cpp | 9 +- .../Checkers/NonNullParamChecker.cpp | 21 +- .../StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp | 17 +- .../Checkers/ObjCContainersChecker.cpp | 11 +- .../Checkers/ObjCSelfInitChecker.cpp | 9 +- .../Checkers/ObjCSuperDeallocChecker.cpp | 19 +- .../lib/StaticAnalyzer/Checkers/PaddingChecker.cpp | 9 +- .../Checkers/PointerArithChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/PointerSubChecker.cpp | 6 +- .../Checkers/ReturnPointerRangeChecker.cpp | 10 +- .../StaticAnalyzer/Checkers/ReturnUndefChecker.cpp | 15 +- .../Checkers/SimpleStreamChecker.cpp | 27 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 16 +- .../StaticAnalyzer/Checkers/TaggedUnionModeling.h | 2 +- .../StaticAnalyzer/Checkers/TaintTesterChecker.cpp | 5 +- .../Checkers/TestAfterDivZeroChecker.cpp | 10 +- .../StaticAnalyzer/Checkers/UndefBranchChecker.cpp | 89 +- .../Checkers/UndefCapturedBlockVarChecker.cpp | 8 +- .../StaticAnalyzer/Checkers/UndefResultChecker.cpp | 8 +- .../Checkers/UndefinedArraySubscriptChecker.cpp | 7 +- .../Checkers/UndefinedAssignmentChecker.cpp | 11 +- .../UninitializedObject/UninitializedObject.h | 2 +- .../UninitializedObjectChecker.cpp | 11 +- .../lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp | 32 +- .../lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp | 20 +- .../lib/StaticAnalyzer/Checkers/VforkChecker.cpp | 7 +- .../StaticAnalyzer/Core/CommonBugCategories.cpp | 1 + .../clang/lib/StaticAnalyzer/Core/Environment.cpp | 2 +- .../clang/lib/StaticAnalyzer/Core/RegionStore.cpp | 6 +- .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 2 +- .../clang/lib/Tooling/Refactoring/Lookup.cpp | 4 +- contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 4 +- .../clang/tools/clang-format/ClangFormat.cpp | 69 +- .../clang/utils/TableGen/RISCVVEmitter.cpp | 2 +- .../clang/utils/TableGen/SveEmitter.cpp | 19 + .../compiler-rt/lib/asan/asan_linux.cpp | 13 +- .../compiler-rt/lib/asan/asan_new_delete.cpp | 9 - .../compiler-rt/lib/builtins/cpu_model/x86.c | 2 +- .../llvm-project/compiler-rt/lib/builtins/fp_lib.h | 12 - .../compiler-rt/lib/builtins/int_types.h | 2 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 11 +- .../compiler-rt/lib/memprof/memprof_linux.cpp | 1 - .../sanitizer_common_interceptors.inc | 4 +- .../lib/sanitizer_common/sanitizer_flat_map.h | 4 + .../lib/sanitizer_common/sanitizer_freebsd.h | 137 -- .../lib/sanitizer_common/sanitizer_linux.cpp | 9 +- .../sanitizer_common/sanitizer_linux_libcdep.cpp | 8 +- .../sanitizer_platform_interceptors.h | 5 +- .../sanitizer_platform_limits_freebsd.h | 2 + .../sanitizer_platform_limits_posix.h | 1 + .../sanitizer_common/sanitizer_procmaps_bsd.cpp | 11 - .../sanitizer_common/sanitizer_stackdepotbase.h | 22 +- .../compiler-rt/lib/tsan/rtl/tsan_platform.h | 32 + .../lib/tsan/rtl/tsan_platform_linux.cpp | 8 +- contrib/llvm-project/libcxx/include/__config | 10 + .../libcxx/include/__memory/shared_ptr.h | 4 +- .../libcxx/include/__memory/unique_ptr.h | 4 - .../libcxx/include/__ranges/chunk_by_view.h | 3 +- .../libcxx/include/__ranges/drop_view.h | 7 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 2 +- .../libcxx/include/__ranges/movable_box.h | 62 +- .../libcxx/include/__ranges/repeat_view.h | 4 +- .../libcxx/include/__ranges/single_view.h | 4 +- .../libcxx/include/__ranges/take_while_view.h | 3 +- .../libcxx/include/__ranges/transform_view.h | 3 +- contrib/llvm-project/libcxx/include/memory | 2 +- contrib/llvm-project/lld/COFF/Driver.cpp | 3 + contrib/llvm-project/lld/COFF/Writer.cpp | 2 +- .../llvm/include/llvm/ADT/GenericUniformityImpl.h | 6 + .../llvm/include/llvm/ADT/SmallString.h | 65 +- .../llvm/include/llvm/Analysis/ConstraintSystem.h | 7 - .../include/llvm/Analysis/TargetTransformInfo.h | 22 + .../llvm/Analysis/TargetTransformInfoImpl.h | 7 + .../llvm/CodeGen/GlobalISel/CombinerHelper.h | 18 +- .../include/llvm/Frontend/OpenMP/OMPIRBuilder.h | 7 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 10 +- .../include/llvm/Support/AMDHSAKernelDescriptor.h | 44 +- .../llvm/Support/X86DisassemblerDecoderCommon.h | 9 +- .../llvm/include/llvm/Target/GlobalISel/Combine.td | 15 +- .../llvm/lib/Analysis/ConstraintSystem.cpp | 10 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 32 +- .../llvm/lib/Analysis/LazyValueInfo.cpp | 163 ++- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 9 + .../llvm/lib/Analysis/ValueTracking.cpp | 34 - .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 2 + .../llvm/lib/Bitcode/Reader/BitcodeReader.cpp | 3 + .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 353 +++++- .../llvm/lib/CodeGen/MachineCopyPropagation.cpp | 42 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 16 +- .../llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp | 9 +- .../lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp | 3 +- .../lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp | 8 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 4 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 3 +- .../Orc/Debugging/DebugInfoSupport.cpp | 3 +- .../llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | 6 +- .../llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp | 12 +- .../llvm-project/llvm/lib/FuzzMutate/FuzzerCLI.cpp | 16 +- contrib/llvm-project/llvm/lib/IR/DebugInfo.cpp | 4 + .../llvm-project/llvm/lib/MC/WasmObjectWriter.cpp | 3 +- .../llvm/lib/Object/WasmObjectFile.cpp | 21 +- .../llvm/lib/ProfileData/InstrProfReader.cpp | 2 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 11 +- .../llvm-project/llvm/lib/Support/Windows/Path.inc | 5 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 39 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 59 +- .../AArch64/Disassembler/AArch64Disassembler.cpp | 2 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 14 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 18 +- .../llvm/lib/Target/AMDGPU/AMDGPUInstructions.td | 1 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 1 + .../llvm/lib/Target/AMDGPU/AMDGPURegisterBanks.td | 2 +- .../Target/AMDGPU/AMDGPUResourceUsageAnalysis.cpp | 3 +- .../lib/Target/AMDGPU/AMDGPURewriteUndefForPHI.cpp | 1 - .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 1 + .../AMDGPU/AMDGPUUnifyDivergentExitNodes.cpp | 3 - .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 9 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 57 +- .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 11 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp | 4 +- .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 6 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 58 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 24 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 10 + .../llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp | 12 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 76 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 2 - .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 22 +- .../llvm/lib/Target/ARC/ARCISelLowering.cpp | 2 +- .../llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp | 9 +- .../llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp | 28 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 69 +- .../llvm/lib/Target/AVR/AVRISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/AVR/AVRISelLowering.cpp | 5 +- .../llvm/lib/Target/BPF/BPFISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/CSKY/CSKYISelLowering.cpp | 4 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 34 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 6 +- .../lib/Target/Hexagon/HexagonISelLowering.cpp | 9 +- .../lib/Target/Hexagon/HexagonISelLoweringHVX.cpp | 4 +- .../llvm/lib/Target/Lanai/LanaiISelLowering.cpp | 4 +- .../LoongArch/AsmParser/LoongArchAsmParser.cpp | 12 +- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 59 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 1 + .../lib/Target/LoongArch/LoongArchLASXInstrInfo.td | 50 +- .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 4 +- .../MCTargetDesc/LoongArchMCCodeEmitter.cpp | 13 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.cpp | 7 +- .../LoongArch/MCTargetDesc/LoongArchMCExpr.h | 8 +- .../llvm/lib/Target/M68k/M68kExpandPseudo.cpp | 10 + .../llvm/lib/Target/M68k/M68kISelLowering.cpp | 243 ++-- .../llvm/lib/Target/M68k/M68kISelLowering.h | 9 + .../llvm/lib/Target/M68k/M68kInstrArithmetic.td | 70 +- .../llvm/lib/Target/M68k/M68kInstrData.td | 3 + .../llvm/lib/Target/M68k/M68kInstrFormats.td | 20 +- .../llvm/lib/Target/M68k/M68kInstrInfo.td | 30 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 6 +- .../llvm/lib/Target/Mips/Mips64InstrInfo.td | 12 +- .../llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp | 20 + .../llvm/lib/Target/Mips/MipsISelDAGToDAG.h | 1 + .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 4 +- .../llvm/lib/Target/Mips/MipsInstrCompiler.td | 33 + .../llvm/lib/Target/Mips/MipsInstrInfo.td | 13 +- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 8 +- .../llvm/lib/Target/Mips/MipsSEISelLowering.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 6 +- .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 5 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 134 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 45 +- .../RISCV/Disassembler/RISCVDisassembler.cpp | 31 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 2 +- .../Target/RISCV/MCTargetDesc/RISCVBaseInfo.cpp | 1 - .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 14 +- .../Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp | 5 +- .../llvm/lib/Target/RISCV/RISCVCallingConv.td | 4 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 29 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 6 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 230 +++- .../llvm/lib/Target/RISCV/RISCVInsertWriteVXRM.cpp | 14 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 11 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.td | 11 +- .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 152 +-- .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 58 + .../llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td | 83 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZc.td | 5 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZcmop.td | 34 + .../llvm/lib/Target/RISCV/RISCVInstrInfoZicfiss.td | 72 ++ .../llvm/lib/Target/RISCV/RISCVInstrInfoZimop.td | 59 + .../llvm/lib/Target/RISCV/RISCVProcessors.td | 3 +- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.cpp | 3 + .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 7 + .../llvm/lib/Target/RISCV/RISCVSystemOperands.td | 55 +- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 3 +- .../llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp | 6 +- .../llvm/lib/Target/Sparc/SparcISelLowering.cpp | 4 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 76 +- .../llvm/lib/Target/SystemZ/SystemZOperators.td | 4 +- .../llvm/lib/Target/VE/VEISelLowering.cpp | 14 +- .../llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp | 10 +- .../Target/X86/Disassembler/X86Disassembler.cpp | 6 +- .../X86/Disassembler/X86DisassemblerDecoder.h | 1 + .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 13 +- .../X86/MCTargetDesc/X86InstPrinterCommon.cpp | 3 + .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 43 +- contrib/llvm-project/llvm/lib/Target/X86/X86.td | 11 +- .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 10 +- .../llvm/lib/Target/X86/X86InsertPrefetch.cpp | 3 +- .../llvm/lib/Target/X86/X86InstrAMX.td | 68 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 11 + .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1306 +++++++++----------- .../llvm/lib/Target/X86/X86InstrFormats.td | 2 + .../llvm/lib/Target/X86/X86InstrPredicates.td | 3 +- .../llvm/lib/Target/X86/X86InstrSSE.td | 94 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 4 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 426 ++++++- .../llvm/lib/Target/X86/X86InstrVecCompiler.td | 9 + .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 26 +- .../llvm/lib/Target/X86/X86TargetTransformInfo.h | 5 + .../llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/XCore/XCoreISelLowering.cpp | 56 +- .../llvm/lib/TargetParser/ARMTargetParser.cpp | 6 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 2 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 3 +- .../llvm/lib/TargetParser/X86TargetParser.cpp | 4 +- .../llvm-project/llvm/lib/TextAPI/TextStubV5.cpp | 7 +- .../llvm/lib/Transforms/Coroutines/CoroFrame.cpp | 6 +- .../llvm/lib/Transforms/IPO/FunctionAttrs.cpp | 46 +- .../Transforms/InstCombine/InstCombineAddSub.cpp | 4 +- .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 14 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 6 + .../Transforms/InstCombine/InstCombineCompares.cpp | 196 ++- .../Transforms/InstCombine/InstCombineInternal.h | 7 +- .../Transforms/InstCombine/InstCombineSelect.cpp | 71 +- .../InstCombine/InstructionCombining.cpp | 58 +- .../Transforms/Scalar/ConstraintElimination.cpp | 64 +- .../Transforms/Utils/CanonicalizeFreezeInLoops.cpp | 60 +- .../llvm/lib/Transforms/Utils/Local.cpp | 5 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 63 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 146 ++- .../llvm/lib/Transforms/Vectorize/VPlan.h | 30 + .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 65 +- .../llvm/lib/Transforms/Vectorize/VPlanValue.h | 1 + .../llvm-project/llvm/tools/llvm-ar/llvm-ar.cpp | 3 +- .../llvm/tools/llvm-diff/llvm-diff.cpp | 3 +- .../llvm/utils/TableGen/X86DisassemblerTables.cpp | 21 +- .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 18 +- .../llvm/utils/TableGen/X86RecognizableInstr.cpp | 37 +- .../llvm/utils/TableGen/X86RecognizableInstr.h | 4 +- lib/clang/include/Plugins/Plugins.def | 1 + lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Config/AsmParsers.def | 23 + lib/clang/include/llvm/Config/AsmPrinters.def | 23 + lib/clang/include/llvm/Config/Disassemblers.def | 23 + lib/clang/include/llvm/Config/TargetMCAs.def | 23 + lib/clang/include/llvm/Config/Targets.def | 22 + lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/liblldb/Makefile | 1 + lib/clang/libllvm/Makefile | 1 + 335 files changed, 5221 insertions(+), 3749 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 53619e89e47e..6d3ba576de86 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -136,11 +136,14 @@ OLD_FILES+=usr/lib/clang/17/include/cmpccxaddintrin.h OLD_FILES+=usr/lib/clang/17/include/cpuid.h OLD_FILES+=usr/lib/clang/17/include/crc32intrin.h OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/algorithm +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/basic_string.h +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/basic_string.tcc OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/shared_ptr_base.h OLD_DIRS+=usr/lib/clang/17/include/cuda_wrappers/bits OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/cmath OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/complex OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/new +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/shared_ptr_base.h OLD_DIRS+=usr/lib/clang/17/include/cuda_wrappers OLD_FILES+=usr/lib/clang/17/include/emmintrin.h OLD_FILES+=usr/lib/clang/17/include/enqcmdintrin.h @@ -440,57 +443,57 @@ OLD_DIRS+=usr/lib/clang/17/share OLD_DIRS+=usr/lib/clang/17 # 20240419: new libc++ import which bumps version from 17 to 18 -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/algorithm_fwd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/algorithm_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/execution_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/execution_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_algorithm_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_algorithm_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_memory_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_memory_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_numeric_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_numeric_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/memory_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/numeric_fwd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/numeric_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_for.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_for_each.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_invoke.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_merge.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_scan.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_stable_partial_sort.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_stable_sort.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_transform_reduce.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_transform_scan.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/util.h -OLD_DIRS+=usr/include/include/c++/v1/__pstl/internal/omp -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_omp.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_serial.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_tbb.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_utils.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/unseq_backend_simd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/utils.h -OLD_DIRS+=usr/include/include/c++/v1/__pstl/internal -OLD_DIRS+=usr/include/include/c++/v1/__pstl -OLD_FILES+=usr/include/include/c++/v1/__pstl_algorithm -OLD_FILES+=usr/include/include/c++/v1/__pstl_memory -OLD_FILES+=usr/include/include/c++/v1/__pstl_numeric -OLD_FILES+=usr/include/include/c++/v1/__type_traits/predicate_traits.h -OLD_FILES+=usr/include/include/c++/v1/__utility/terminate_on_exception.h -OLD_FILES+=usr/include/include/c++/v1/experimental/deque -OLD_FILES+=usr/include/include/c++/v1/experimental/forward_list -OLD_FILES+=usr/include/include/c++/v1/experimental/list -OLD_FILES+=usr/include/include/c++/v1/experimental/map -OLD_FILES+=usr/include/include/c++/v1/experimental/memory_resource -OLD_FILES+=usr/include/include/c++/v1/experimental/regex -OLD_FILES+=usr/include/include/c++/v1/experimental/set -OLD_FILES+=usr/include/include/c++/v1/experimental/string -OLD_FILES+=usr/include/include/c++/v1/experimental/unordered_map -OLD_FILES+=usr/include/include/c++/v1/experimental/unordered_set -OLD_FILES+=usr/include/include/c++/v1/experimental/vector -OLD_FILES+=usr/include/include/c++/v1/limits.h -OLD_FILES+=usr/include/include/c++/v1/setjmp.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/algorithm_fwd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/algorithm_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/execution_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/execution_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_algorithm_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_algorithm_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_memory_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_memory_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_numeric_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_numeric_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/memory_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/numeric_fwd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/numeric_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_for.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_for_each.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_invoke.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_merge.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_scan.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_stable_partial_sort.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_stable_sort.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_transform_reduce.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_transform_scan.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/util.h +OLD_DIRS+=usr/include/c++/v1/__pstl/internal/omp +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_omp.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_serial.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_tbb.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_utils.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/unseq_backend_simd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/utils.h +OLD_DIRS+=usr/include/c++/v1/__pstl/internal +OLD_DIRS+=usr/include/c++/v1/__pstl +OLD_FILES+=usr/include/c++/v1/__pstl_algorithm +OLD_FILES+=usr/include/c++/v1/__pstl_memory +OLD_FILES+=usr/include/c++/v1/__pstl_numeric +OLD_FILES+=usr/include/c++/v1/__type_traits/predicate_traits.h +OLD_FILES+=usr/include/c++/v1/__utility/terminate_on_exception.h +OLD_FILES+=usr/include/c++/v1/experimental/deque +OLD_FILES+=usr/include/c++/v1/experimental/forward_list +OLD_FILES+=usr/include/c++/v1/experimental/list +OLD_FILES+=usr/include/c++/v1/experimental/map +OLD_FILES+=usr/include/c++/v1/experimental/memory_resource +OLD_FILES+=usr/include/c++/v1/experimental/regex +OLD_FILES+=usr/include/c++/v1/experimental/set +OLD_FILES+=usr/include/c++/v1/experimental/string +OLD_FILES+=usr/include/c++/v1/experimental/unordered_map +OLD_FILES+=usr/include/c++/v1/experimental/unordered_set +OLD_FILES+=usr/include/c++/v1/experimental/vector +OLD_FILES+=usr/include/c++/v1/limits.h +OLD_FILES+=usr/include/c++/v1/setjmp.h # 20240213: caroot bundle updated OLD_FILES+=usr/share/certs/trusted/Security_Communication_Root_CA.pem diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index b3ae66e6e769..1afa69367286 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -2383,10 +2383,6 @@ public: /// Check if the type is the CUDA device builtin texture type. bool isCUDADeviceBuiltinTextureType() const; - bool isRVVType(unsigned ElementCount) const; - - bool isRVVType(unsigned Bitwidth, bool IsFloat, bool IsBFloat = false) const; - /// Return the implicit lifetime for this type, which must not be dependent. Qualifiers::ObjCLifetime getObjCARCImplicitLifetime() const; @@ -7283,28 +7279,6 @@ inline bool Type::isOpenCLSpecificType() const { isQueueT() || isReserveIDT() || isPipeType() || isOCLExtOpaqueType(); } -inline bool Type::isRVVType(unsigned ElementCount) const { - bool Ret = false; -#define RVV_VECTOR_TYPE(Name, Id, SingletonId, NumEls, ElBits, NF, IsSigned, \ - IsFP, IsBF) \ - if (NumEls == ElementCount) \ - Ret |= isSpecificBuiltinType(BuiltinType::Id); -#include "clang/Basic/RISCVVTypes.def" - return Ret; -} - -inline bool Type::isRVVType(unsigned Bitwidth, bool IsFloat, - bool IsBFloat) const { - bool Ret = false; -#define RVV_TYPE(Name, Id, SingletonId) -#define RVV_VECTOR_TYPE(Name, Id, SingletonId, NumEls, ElBits, NF, IsSigned, \ - IsFP, IsBF) \ - if (ElBits == Bitwidth && IsFloat == IsFP && IsBFloat == IsBF) \ - Ret |= isSpecificBuiltinType(BuiltinType::Id); -#include "clang/Basic/RISCVVTypes.def" - return Ret; -} - inline bool Type::isTemplateTypeParmType() const { return isa(CanonicalType); } diff --git a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def index 82a1ba3c82ad..31ec84143f65 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def +++ b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def @@ -68,6 +68,9 @@ TARGET_BUILTIN(__builtin_arm_ldg, "v*v*", "t", "mte") TARGET_BUILTIN(__builtin_arm_stg, "vv*", "t", "mte") TARGET_BUILTIN(__builtin_arm_subp, "Uiv*v*", "t", "mte") +// SME state function +BUILTIN(__builtin_arm_get_sme_state, "vULi*ULi*", "n") + // Memory Operations TARGET_BUILTIN(__builtin_arm_mops_memset_tag, "v*v*iz", "", "mte,mops") diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td index bb54e2664186..0d471f6c554c 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td @@ -109,10 +109,10 @@ multiclass RVVVFWMACCBuiltinSet> suffixes_prototypes> { Name = NAME, HasMasked = false, Log2LMUL = [-2, -1, 0, 1, 2] in - defm NAME : RVVOutOp1Op2BuiltinSet; + defm NAME : RVVOutOp1Op2BuiltinSet; } -multiclass RVVVQMACCBuiltinSet> suffixes_prototypes> { +multiclass RVVVQMACCDODBuiltinSet> suffixes_prototypes> { let OverloadedName = NAME, Name = NAME, HasMasked = false, @@ -120,6 +120,14 @@ multiclass RVVVQMACCBuiltinSet> suffixes_prototypes> { defm NAME : RVVOutOp1Op2BuiltinSet; } +multiclass RVVVQMACCQOQBuiltinSet> suffixes_prototypes> { + let OverloadedName = NAME, + Name = NAME, + HasMasked = false, + Log2LMUL = [-1, 0, 1, 2] in + defm NAME : RVVOutOp1Op2BuiltinSet; +} + multiclass RVVVFNRCLIPBuiltinSet { let Log2LMUL = [-3, -2, -1, 0, 1, 2], Name = NAME, @@ -130,18 +138,18 @@ multiclass RVVVFNRCLIPBuiltinSet; - defm sf_vqmacc_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; - defm sf_vqmaccus_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; - defm sf_vqmaccsu_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; + defm sf_vqmaccu_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; + defm sf_vqmacc_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; + defm sf_vqmaccus_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; + defm sf_vqmaccsu_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; } let UnMaskedPolicyScheme = HasPolicyOperand in let RequiredFeatures = ["Xsfvqmaccqoq"] in { - defm sf_vqmaccu_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; - defm sf_vqmacc_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; - defm sf_vqmaccus_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; - defm sf_vqmaccsu_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; + defm sf_vqmaccu_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; + defm sf_vqmacc_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)Sv(FixedSEW:8)v"]]>; + defm sf_vqmaccus_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)SUv(FixedSEW:8)v"]]>; + defm sf_vqmaccsu_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; } let UnMaskedPolicyScheme = HasPolicyOperand in diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td index f2dde7f540fb..e7d78b03511f 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td @@ -2441,11 +2441,9 @@ let HasMasked = false, HasVL = false, IRName = "" in { return Builder.CreateInsertVector(ResultType, Ops[0], Ops[2], Ops[1]); } }] in { - let Log2LMUL = [0, 1, 2] in { - foreach dst_lmul = ["(LFixedLog2LMUL:1)", "(LFixedLog2LMUL:2)", "(LFixedLog2LMUL:3)"] in { - def : RVVBuiltin<"v" # dst_lmul # "v", dst_lmul # "v" # dst_lmul # "vKzv", "csilxfd">; - def : RVVBuiltin<"Uv" # dst_lmul # "Uv", dst_lmul # "Uv" # dst_lmul #"UvKzUv", "csil">; - } + foreach dst_lmul = ["(LFixedLog2LMUL:1)", "(LFixedLog2LMUL:2)", "(LFixedLog2LMUL:3)"] in { + def : RVVBuiltin<"v" # dst_lmul # "v", dst_lmul # "v" # dst_lmul # "vKzv", "csilxfd">; + def : RVVBuiltin<"Uv" # dst_lmul # "Uv", dst_lmul # "Uv" # dst_lmul #"UvKzUv", "csil">; } foreach nf = NFList in { defvar T = "(Tuple:" # nf # ")"; diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td index 4036ce8e6903..040db6f0cdbf 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td @@ -41,7 +41,7 @@ // x: float16_t (half) // f: float32_t (float) // d: float64_t (double) -// b: bfloat16_t (bfloat16) +// y: bfloat16_t (bfloat16) // // This way, given an LMUL, a record with a TypeRange "sil" will cause the // definition of 3 builtins. Each type "t" in the TypeRange (in this example diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h index 5d2c96e5bc9d..45187433c069 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h @@ -13,6 +13,7 @@ namespace clang { namespace ento { namespace categories { +extern const char *const AppleAPIMisuse; extern const char *const CoreFoundationObjectiveC; extern const char *const LogicError; extern const char *const MemoryRefCount; diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h index 8a46282a595e..2ec54a837c42 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h @@ -193,9 +193,8 @@ public: class Location { template - static void _checkLocation(void *checker, - const SVal &location, bool isLoad, const Stmt *S, - CheckerContext &C) { + static void _checkLocation(void *checker, SVal location, bool isLoad, + const Stmt *S, CheckerContext &C) { ((const CHECKER *)checker)->checkLocation(location, isLoad, S, C); } @@ -209,8 +208,7 @@ public: class Bind { template - static void _checkBind(void *checker, - const SVal &location, const SVal &val, const Stmt *S, + static void _checkBind(void *checker, SVal location, SVal val, const Stmt *S, CheckerContext &C) { ((const CHECKER *)checker)->checkBind(location, val, S, C); } @@ -456,10 +454,8 @@ namespace eval { class Assume { template - static ProgramStateRef _evalAssume(void *checker, - ProgramStateRef state, - const SVal &cond, - bool assumption) { + static ProgramStateRef _evalAssume(void *checker, ProgramStateRef state, + SVal cond, bool assumption) { return ((const CHECKER *)checker)->evalAssume(state, cond, assumption); } diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h index 39583c443eda..a45ba1bc573e 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h @@ -488,13 +488,11 @@ public: using CheckCallFunc = CheckerFn; - using CheckLocationFunc = - CheckerFn; + using CheckLocationFunc = CheckerFn; using CheckBindFunc = - CheckerFn; + CheckerFn; using CheckEndAnalysisFunc = CheckerFn; @@ -530,8 +528,7 @@ public: RegionAndSymbolInvalidationTraits *ITraits)>; using EvalAssumeFunc = - CheckerFn; + CheckerFn; using EvalCallFunc = CheckerFn; diff --git a/contrib/llvm-project/clang/lib/AST/Interp/Interp.h b/contrib/llvm-project/clang/lib/AST/Interp/Interp.h index a240d74d6342..828d4ea35526 100644 --- a/contrib/llvm-project/clang/lib/AST/Interp/Interp.h +++ b/contrib/llvm-project/clang/lib/AST/Interp/Interp.h @@ -37,7 +37,6 @@ namespace clang { namespace interp { -using APInt = llvm::APInt; using APSInt = llvm::APSInt; /// Convert a value to an APValue. diff --git a/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp b/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp index 27096a83b8dd..6a16c2184fcf 100644 --- a/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp +++ b/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp @@ -299,10 +299,8 @@ private: /// Consume all leading whitespace from \c Code. void consumeWhitespace() { - Code = Code.drop_while([](char c) { - // Don't trim newlines. - return StringRef(" \t\v\f\r").contains(c); - }); + // Don't trim newlines. + Code = Code.ltrim(" \t\v\f\r"); } SourceLocation currentLocation() { diff --git a/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp b/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp index 5902c6dc3ce0..d0d8316385b4 100644 --- a/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp +++ b/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp @@ -628,8 +628,7 @@ ObjCMethodFamily Selector::getMethodFamilyImpl(Selector sel) { return OMF_performSelector; // The other method families may begin with a prefix of underscores. - while (!name.empty() && name.front() == '_') - name = name.substr(1); + name = name.ltrim('_'); if (name.empty()) return OMF_None; switch (name.front()) { diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 3ee39133fcee..2f8395cb8932 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -1365,8 +1365,7 @@ bool AArch64TargetInfo::validateConstraintModifier( StringRef Constraint, char Modifier, unsigned Size, std::string &SuggestedModifier) const { // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); switch (Constraint[0]) { default: diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp index 6e1842fc64e5..01f9e844da12 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp @@ -1230,8 +1230,7 @@ bool ARMTargetInfo::validateConstraintModifier( bool isInOut = (Constraint[0] == '+'); // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); switch (Constraint[0]) { default: diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp index 685462961ee3..6bc57a83a2d5 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp @@ -416,8 +416,7 @@ static void handleFullArchString(StringRef FullArchStr, Features.push_back("__RISCV_TargetAttrNeedOverride"); auto RII = llvm::RISCVISAInfo::parseArchString( FullArchStr, /* EnableExperimentalExtension */ true); - if (!RII) { - consumeError(RII.takeError()); + if (llvm::errorToBool(RII.takeError())) { // Forward the invalid FullArchStr. Features.push_back("+" + FullArchStr.str()); } else { diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp index b97f88647fa4..3deaa19f8d4f 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp @@ -1613,8 +1613,7 @@ bool X86TargetInfo::validateOutputSize(const llvm::StringMap &FeatureMap, StringRef Constraint, unsigned Size) const { // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); return validateOperandSize(FeatureMap, Constraint, Size); } diff --git a/contrib/llvm-project/clang/lib/Basic/Warnings.cpp b/contrib/llvm-project/clang/lib/Basic/Warnings.cpp index bab1af4f03b6..92954cab6fb0 100644 --- a/contrib/llvm-project/clang/lib/Basic/Warnings.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Warnings.cpp @@ -96,11 +96,7 @@ void clang::ProcessWarningOptions(DiagnosticsEngine &Diags, // Check to see if this warning starts with "no-", if so, this is a // negative form of the option. - bool isPositive = true; - if (Opt.starts_with("no-")) { - isPositive = false; - Opt = Opt.substr(3); - } + bool isPositive = !Opt.consume_front("no-"); // Figure out how this option affects the warning. If -Wfoo, map the // diagnostic to a warning, if -Wno-foo, map it to ignore. diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp index 5081062da286..f71dbf1729a1 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp @@ -10430,6 +10430,26 @@ Value *CodeGenFunction::EmitAArch64BuiltinExpr(unsigned BuiltinID, return Builder.CreateCall(F, llvm::ConstantInt::get(Int32Ty, HintID)); } + if (BuiltinID == clang::AArch64::BI__builtin_arm_get_sme_state) { + // Create call to __arm_sme_state and store the results to the two pointers. + CallInst *CI = EmitRuntimeCall(CGM.CreateRuntimeFunction( + llvm::FunctionType::get(StructType::get(CGM.Int64Ty, CGM.Int64Ty), {}, + false), + "__arm_sme_state")); + auto Attrs = + AttributeList() + .addFnAttribute(getLLVMContext(), "aarch64_pstate_sm_compatible") + .addFnAttribute(getLLVMContext(), "aarch64_pstate_za_preserved"); + CI->setAttributes(Attrs); + CI->setCallingConv( + llvm::CallingConv:: + AArch64_SME_ABI_Support_Routines_PreserveMost_From_X2); + Builder.CreateStore(Builder.CreateExtractValue(CI, 0), + EmitPointerWithAlignment(E->getArg(0))); + return Builder.CreateStore(Builder.CreateExtractValue(CI, 1), + EmitPointerWithAlignment(E->getArg(1))); + } + if (BuiltinID == clang::AArch64::BI__builtin_arm_rbit) { assert((getContext().getTypeSize(E->getType()) == 32) && "rbit of unusual size!"); diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp index ed426098ac69..e362c9da51fe 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp @@ -6406,13 +6406,11 @@ static void emitOMPAtomicCaptureExpr(CodeGenFunction &CGF, } } -static void emitOMPAtomicCompareExpr(CodeGenFunction &CGF, - llvm::AtomicOrdering AO, const Expr *X, - const Expr *V, const Expr *R, - const Expr *E, const Expr *D, - const Expr *CE, bool IsXBinopExpr, - bool IsPostfixUpdate, bool IsFailOnly, - SourceLocation Loc) { +static void emitOMPAtomicCompareExpr( + CodeGenFunction &CGF, llvm::AtomicOrdering AO, llvm::AtomicOrdering FailAO, + const Expr *X, const Expr *V, const Expr *R, const Expr *E, const Expr *D, + const Expr *CE, bool IsXBinopExpr, bool IsPostfixUpdate, bool IsFailOnly, + SourceLocation Loc) { llvm::OpenMPIRBuilder &OMPBuilder = CGF.CGM.getOpenMPRuntime().getOMPBuilder(); @@ -6477,13 +6475,21 @@ static void emitOMPAtomicCompareExpr(CodeGenFunction &CGF, R->getType().isVolatileQualified()}; } - CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( - CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, - IsPostfixUpdate, IsFailOnly)); + if (FailAO == llvm::AtomicOrdering::NotAtomic) { + // fail clause was not mentionend on the + // "#pragma omp atomic compare" construct. + CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( + CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, + IsPostfixUpdate, IsFailOnly)); + } else + CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( + CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, + IsPostfixUpdate, IsFailOnly, FailAO)); } static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, - llvm::AtomicOrdering AO, bool IsPostfixUpdate, + llvm::AtomicOrdering AO, + llvm::AtomicOrdering FailAO, bool IsPostfixUpdate, const Expr *X, const Expr *V, const Expr *R, const Expr *E, const Expr *UE, const Expr *D, const Expr *CE, bool IsXLHSInRHSPart, @@ -6504,12 +6510,8 @@ static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, IsXLHSInRHSPart, Loc); break; case OMPC_compare: { - emitOMPAtomicCompareExpr(CGF, AO, X, V, R, E, D, CE, IsXLHSInRHSPart, - IsPostfixUpdate, IsFailOnly, Loc); - break; - } - case OMPC_fail: { - //TODO + emitOMPAtomicCompareExpr(CGF, AO, FailAO, X, V, R, E, D, CE, + IsXLHSInRHSPart, IsPostfixUpdate, IsFailOnly, Loc); break; } default: @@ -6519,6 +6521,8 @@ static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, void CodeGenFunction::EmitOMPAtomicDirective(const OMPAtomicDirective &S) { llvm::AtomicOrdering AO = llvm::AtomicOrdering::Monotonic; + // Fail Memory Clause Ordering. + llvm::AtomicOrdering FailAO = llvm::AtomicOrdering::NotAtomic; bool MemOrderingSpecified = false; if (S.getSingleClause()) { AO = llvm::AtomicOrdering::SequentiallyConsistent; @@ -6572,12 +6576,27 @@ void CodeGenFunction::EmitOMPAtomicDirective(const OMPAtomicDirective &S) { } } + if (KindsEncountered.contains(OMPC_compare) && + KindsEncountered.contains(OMPC_fail)) { + Kind = OMPC_compare; + const auto *FailClause = S.getSingleClause(); + if (FailClause) { + OpenMPClauseKind FailParameter = FailClause->getFailParameter(); + if (FailParameter == llvm::omp::OMPC_relaxed) + FailAO = llvm::AtomicOrdering::Monotonic; + else if (FailParameter == llvm::omp::OMPC_acquire) + FailAO = llvm::AtomicOrdering::Acquire; + else if (FailParameter == llvm::omp::OMPC_seq_cst) + FailAO = llvm::AtomicOrdering::SequentiallyConsistent; + } + } + LexicalScope Scope(*this, S.getSourceRange()); EmitStopPoint(S.getAssociatedStmt()); - emitOMPAtomicExpr(*this, Kind, AO, S.isPostfixUpdate(), S.getX(), S.getV(), - S.getR(), S.getExpr(), S.getUpdateExpr(), S.getD(), - S.getCondExpr(), S.isXLHSInRHSPart(), S.isFailOnly(), - S.getBeginLoc()); + emitOMPAtomicExpr(*this, Kind, AO, FailAO, S.isPostfixUpdate(), S.getX(), + S.getV(), S.getR(), S.getExpr(), S.getUpdateExpr(), + S.getD(), S.getCondExpr(), S.isXLHSInRHSPart(), + S.isFailOnly(), S.getBeginLoc()); } static void emitCommonOMPTargetDirective(CodeGenFunction &CGF, diff --git a/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp b/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp index 753a8fd74fa6..f8038497d90a 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp @@ -1139,8 +1139,7 @@ CodeGenAction::loadModule(MemoryBufferRef MBRef) { // Strip off a leading diagnostic code if there is one. StringRef Msg = Err.getMessage(); - if (Msg.starts_with("error: ")) - Msg = Msg.substr(7); + Msg.consume_front("error: "); unsigned DiagID = CI.getDiagnostics().getCustomDiagID(DiagnosticsEngine::Error, "%0"); diff --git a/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp b/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp index 7b2c31139b0b..63b9a1fdb988 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp *** 18251 LINES SKIPPED *** From nobody Sat Apr 20 10:32:14 2024 X-Original-To: dev-commits-src-branches@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 4VM79p6QtRz5HVtH; Sat, 20 Apr 2024 10:32:14 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79p52HWz4PT4; Sat, 20 Apr 2024 10:32:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609134; 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=aV/Yk+5tM1yQj1xsx4v2CvPGqKwWNMcRjpCuQzWB9w8=; b=Wwr7jR2qqCoyRShLB3HZBRIoMIWx1h0WQ0/b5ixHFLgy4/UK5wQLk6uS/jRQYR94B3OjjL Oagb86sEDzsdxek1fB9Ky8MI2Po7e0VtSNfpFj+utoAKybDE3kxO5osCdC8TOFQdTzn43l L3ch8koUsf97/zIL0BnfrktRuxrKDHHf6779v4+9NPsq0pGl05x/LVYPrBtVqDWyvnlL4z 5g2XY6JyFEawV5rnjXSbm1puxUWINJ38LkFXgmpJprKGE2IKyKAVA3cleftL9NXYPlB/zt 9qikkvcWE8voj0lTOt0FCFkDeenPlqs7B1xCBdIOGhXLKPebOOgrcggWKnFBRA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609134; a=rsa-sha256; cv=none; b=V0AeVZCaLbw4jIKpwtSukkyg2LIGQ2U2pi4hPlJ9z8nCKUfI7KTiEdcscHFsX9ml+VsZv2 Wyo6ftYmFOjj1zYBfYknuvckrL7zhtifVQqI/1EhAIYmORatkWast9N9gmUiDWjAXzXlXa gGeb8yyX6cD2GpW/LzveS4uOwEpZDCQOlHhM5E6oZN0UEiChdgjFq+U/VBhL4nJjoerXaS KifWIWxxfU543l8PXouQoeq8pY3n3IKfE8iESkhQHnBcGIU8WjDRIKfPGRNmfVukDQA7Z3 i473jDHu/svjQ0berLeBP/Jjygzpsu3YMwLxDyX/GelsmPzwoUHmcH/endFh7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609134; 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=aV/Yk+5tM1yQj1xsx4v2CvPGqKwWNMcRjpCuQzWB9w8=; b=TKcQkjzgW7N1cbbD5n3EmOgCdIrpeIbmIKvICZWmNsMQStCcxDwn7DZFOwZByB61r7xExE wV+ME18fxUm21TJscoiQEk07QhhPc5eu9eweV9/i29CiD18Xlk+g3ecpxj3y/ZTsBsZUcD wrppituRrB89LjmzE9Tq02Ig6Is93ujY3GMUvJYsbi7JPHppNf2jN+AKXasz4TsCPEnaeU wlZzp0AoEZhvzdcKnTgfezDDTi7VjYLDblyVXEogV8I8xdtwj0VczMIprh8+PGomOxabS4 nhh1yupczaGE5dNEGt6WRmYJnytluPZOl5/pfWMR/PmGCciWeuSKm5JXCzK30w== 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 4VM79p4fgtzZ0v; Sat, 20 Apr 2024 10:32:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWEQ6009522; Sat, 20 Apr 2024 10:32:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWE7k009519; Sat, 20 Apr 2024 10:32:14 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:14 GMT Message-Id: <202404201032.43KAWE7k009519@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: 7a0ffb5e054a - stable/14 - Tentatively merge https://github.com/llvm/llvm-project/pull/77242 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 7a0ffb5e054a644a21b6de36a8f1ae51b223eed0 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7a0ffb5e054a644a21b6de36a8f1ae51b223eed0 commit 7a0ffb5e054a644a21b6de36a8f1ae51b223eed0 Author: Dimitry Andric AuthorDate: 2024-01-07 16:03:13 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:10 +0000 Tentatively merge https://github.com/llvm/llvm-project/pull/77242 [libcxx] Re-include in __config for FreeBSD In 0a97720d0197 some changes were made to `__config` for assuming that `__BYTE_ORDER__` is always present. However, this deleted a `` include for FreeBSD, which is required to get the value of `__FreeBSD_version`, and that is used later in the file to determine whether `_LIBCPP_C_HAS_NO_GETS` needs to be enabled. Include `` just after the other includes used for feature detection, to fix this. Note that when FreeBSD 13 is EOLed, this can be removed, as then all supported FreeBSD versions will no longer have `gets()`. PR: 276104 MFC after: 1 month (cherry picked from commit 653487bbc8006839d0895811942bb8a2fcdd5aa8) --- contrib/llvm-project/libcxx/include/__config | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 40e6da8bc03a..f52fb0441293 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -477,6 +477,10 @@ _LIBCPP_HARDENING_MODE_DEBUG # include // for __NATIVE_ASCII_F # endif +# ifdef __FreeBSD__ +# include // for __FreeBSD_version +# endif + # ifndef __BYTE_ORDER__ # error \ "Your compiler doesn't seem to define __BYTE_ORDER__, which is required by libc++ to know the endianness of your target platform" From nobody Sat Apr 20 10:32:15 2024 X-Original-To: dev-commits-src-branches@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 4VM79r3Lwbz5HW4g; Sat, 20 Apr 2024 10:32:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79q66mtz4PP3; Sat, 20 Apr 2024 10:32:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609135; 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=DIVhCP0Dpl3KW5fIsY6evqXwOMtxHhXjA1RBCqWM4IA=; b=CODTPmHVmJe7jMHORwuxycW+nidUmFMmPjy3paBIpiojsSIggbLjopVAv3HWNTZu/vgUKZ tJUnWI4ddGzp8QyWUpAminSfRe0ph3zykS/cY558Gx33IulU/BAipPlXZfFGHszrBDkf/q UehnZXxt+t1rXCinLER3jZoWlyqJPuVNGTG2xn+OmjZlFktrgDEl7hg6iJRKmPpVJIiBXJ q6qQsL3OtfnPxDm2Ygrf2asQVbdwsXknbWwHwzp3Dh4du93b4jYWE86tdnNIQVVFx3lyVT TM7RFFVs+ZmG59YuqSGeEHLIu0daA0BVI0CRHqt+Rt1NMe6ULSIGpR3hJ38ZNw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609135; a=rsa-sha256; cv=none; b=w2ped51yALj4iyWOYjbMO+e8EE7x+pPJE51vYKQPBnZ1ZYXOaNUVHmsJFIUq9nL6hI0C8P 6fRq2lSXu1/QrRx7US7KT88oUOBl7QR+lYrFTKwsJhoPLCMhxyDQM/UCozL+Z6x/BCfIlf 9uskPwmWVTqzEnl3VgYNUCoFz4weNDWi5ET2jpKxhgltRVqeuOVCof7GjTnruSF7WSfZOR 3aqjygSrvH3WYY6T2c9AeTQNjLhTAN81C1yMRKV34whqquYw1Rozb3DyfLKd6tfa2cPAaU DaeKdGjIr+tB1Bo2plRNfPdQLjZ1bvant9EAlELCWAxtI1Ynztf1DyOzpi31mg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609135; 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=DIVhCP0Dpl3KW5fIsY6evqXwOMtxHhXjA1RBCqWM4IA=; b=qS226x9VxoNCQRG9FyVUv229Dc94Mgp6PF3eD7EEL90CXUDQG/FnVn07dB2KjTcyT39BZ+ t3OpITBkQgybmbfaFxP2pCufUQemsqG+fDRBY7AQKeQHg835uO6OC7aAGQ75w/r/mN2RNU Z2r9iZpMqpEvJC6rN1f8fIke+Umjq9zpdras4yuureXX5JrVT1uAzEFDDCgFgsnkrGXJdz kbLWsTnlFl3EzDgQADbFOZiy/KXQ9i4+530f2uMUgSnYN9VrxQwLaXEhm2UqGSFQhAVYwe h6LEZeRAc6abxQUOQxgOqxrlALAkkdceBKwJB0VXgpM4adA8XYgIlkUKSS1+MA== 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 4VM79q5hNRzZ1t; Sat, 20 Apr 2024 10:32:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWFiV009571; Sat, 20 Apr 2024 10:32:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWF1p009568; Sat, 20 Apr 2024 10:32:15 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:15 GMT Message-Id: <202404201032.43KAWF1p009568@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: 7adf29b6244f - stable/14 - Add two FreeBSD customizations to libc++ List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 7adf29b6244fe016ef869f287a66048195f9af29 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7adf29b6244fe016ef869f287a66048195f9af29 commit 7adf29b6244fe016ef869f287a66048195f9af29 Author: Dimitry Andric AuthorDate: 2024-01-07 11:32:29 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:10 +0000 Add two FreeBSD customizations to libc++ This is intended to better support ports usage of older clang versions: * Add _LIBCPP_ENABLE_COMPILER_VERSION_CHECKS block around compiler version checks, to avoid any warnings about support. This makes some ports that use -Werror fall over. * When using clang < 15.0, avoid using a type visibility attribute on the std namespace, as older versions of clang do not support this. PR: 276104 MFC after: 1 month (cherry picked from commit 412fa3436f0d1fe4a7e5e3b66783aa40f599125e) --- contrib/llvm-project/libcxx/include/__config | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index f52fb0441293..959082502a49 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -32,6 +32,7 @@ // Warn if a compiler version is used that is not supported anymore // LLVM RELEASE Update the minimum compiler versions +#if defined(_LIBCPP_ENABLE_COMPILER_VERSION_CHECKS) // FreeBSD customization # if defined(_LIBCPP_CLANG_VER) # if _LIBCPP_CLANG_VER < 1600 # warning "Libc++ only supports Clang 16 and later" @@ -45,6 +46,7 @@ # warning "Libc++ only supports GCC 13 and later" # endif # endif +#endif // _LIBCPP_ENABLE_COMPILER_VERSION_CHECKS // The attributes supported by clang are documented at https://clang.llvm.org/docs/AttributeReference.html @@ -725,7 +727,8 @@ typedef __char32_t char32_t; # define _LIBCPP_TEMPLATE_VIS # endif -# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) +# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) \ + && _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization # define _LIBCPP_TYPE_VISIBILITY_DEFAULT __attribute__((__type_visibility__("default"))) # else # define _LIBCPP_TYPE_VISIBILITY_DEFAULT From nobody Sat Apr 20 10:32:16 2024 X-Original-To: dev-commits-src-branches@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 4VM79t3NNBz5HVwq; Sat, 20 Apr 2024 10:32:18 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79t16vwz4PZ1; Sat, 20 Apr 2024 10:32:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609138; 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=gbKPsun16gW8nfCnPot1DPqQVJwS3Ut1A3uvHXG3CcU=; b=iicGmqvzF6JRUzzctWayV9aDIO870PmFQ7jsuIIfFr3kZXs8OClJgOgYeYVUx88Y0mwII1 fGeAc2hMJ3VHr04Vh87wBQXDHxgeJ4j9/J7fG0meVHhVjHmkvn82nMsv5PXihvJukw08I1 ELjBRPLKOyy8RAs2EEbRyKUHo/ev8jiU/7gj/hqssVTpgfL27vkviRIaRCa8qnMYdMuoOa EnJkM9Uj817lc9oM61Yu/M3wATfNj/k8QeN6+TKLTlrbuGWjNZRUumfpO59h7dKwHRLAQG 3C4Oyqf9zJ8BNWQlTsU4uLAWpHS2qR4/1zDYPCyiop1lyuRmeAwdhirFbso4CQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609138; a=rsa-sha256; cv=none; b=dgVzsUA5IXte9Oc5C506VJcseRTveV2c3YUqY4poBrkfjNKAF+Uqp72jPRZlXlxx+rqpW0 +s4JG72g6nTzHEeWyERsf8T2FDTyLcdb95hKZuuQ6uoF4oxHuEv8M5BmeBkTDJCOU/3vs6 ZTyJdDEqGlWfHUGIYHW/nba0c51ArArLdnLHLN0Wt28s4SV5t8/UeKkXC+zqUBI8euOY3B pCWNkFhILmJgNla6GaQDpV8l762cbMEGsm+GPiLNwKSTCXgqHxI5U7N+bfC19H905kYv43 jsTa04W2EpOJzNxVLKH1KBjU3kUag01tUZaksQeyaWXPevD/5NZ93J9t0yXYwA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609138; 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=gbKPsun16gW8nfCnPot1DPqQVJwS3Ut1A3uvHXG3CcU=; b=P+4HydHJQvIIId9xwzVtOM4Xed4Zptmmp5aofmWpA7oxtbn/K4mMnOPzycN7xWgKxLqPqg f2Y+4Y29BYBnta5pMxm1/pU8PyrRZWhDpikOvJrlR3fbsNSMeVC3AZnGS0coB9rUEzJXw6 Y6qpfLzwbbLIyD5iUqasHBtoZDsVSZ/dhBM9lojM/4xlFmYQU1w615ZKnVXwGeg4C/gcfK 62s60rLu28oa20HlJiZwrFWRNagRMLcOz3L8BiU+7NfjwiPW6h1atJQIjVBmetuAigTkxo 5L5fyatt4KksfltV3lMwxjcMpSoNhRNXQ5mVTqZqy2f5ywLOz2rl973P6GOEvw== 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 4VM79t0CQ7zZ0x; Sat, 20 Apr 2024 10:32:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWHIE009616; Sat, 20 Apr 2024 10:32:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWGnm009607; Sat, 20 Apr 2024 10:32:16 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:16 GMT Message-Id: <202404201032.43KAWGnm009607@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: cdc20ff6a7f1 - stable/14 - Merge llvm-project main llvmorg-18-init-16595-g7c00a5be5cde List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: cdc20ff6a7f12464aed70d9b6e67ea07da9f0399 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=cdc20ff6a7f12464aed70d9b6e67ea07da9f0399 commit cdc20ff6a7f12464aed70d9b6e67ea07da9f0399 Author: Dimitry Andric AuthorDate: 2024-01-09 20:00:28 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:10 +0000 Merge llvm-project main llvmorg-18-init-16595-g7c00a5be5cde This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16595-g7c00a5be5cde. PR: 276104 MFC after: 1 month (cherry picked from commit 1db9f3b21e39176dd5b67cf8ac378633b172463e) --- .../llvm-project/clang/include/clang/AST/Attr.h | 1 + .../llvm-project/clang/include/clang/AST/DeclCXX.h | 8 + .../clang/include/clang/AST/TextNodeDumper.h | 2 + .../llvm-project/clang/include/clang/AST/Type.h | 2 + .../clang/Analysis/Analyses/UnsafeBufferUsage.h | 2 +- .../Analysis/Analyses/UnsafeBufferUsageGadgets.def | 1 + .../clang/include/clang/Analysis/CFG.h | 4 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 23 + .../clang/include/clang/Basic/AttrDocs.td | 35 +- .../clang/include/clang/Basic/CodeGenOptions.def | 1 + .../include/clang/Basic/DiagnosticCommonKinds.td | 3 + .../include/clang/Basic/DiagnosticDriverKinds.td | 3 + .../include/clang/Basic/DiagnosticParseKinds.td | 2 + .../include/clang/Basic/DiagnosticSemaKinds.td | 14 +- .../clang/include/clang/Basic/ObjCRuntime.h | 28 +- .../clang/include/clang/Basic/OpenACCKinds.h | 39 +- .../clang/include/clang/Basic/arm_sve.td | 115 ++- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 1 + .../include/clang/Basic/riscv_sifive_vector.td | 10 +- .../clang/include/clang/Driver/Options.td | 12 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 15 +- .../clang/include/clang/Sema/Template.h | 1 + contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 23 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 39 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 13 +- .../clang/lib/AST/ComputeDependence.cpp | 2 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 50 +- .../llvm-project/clang/lib/AST/FormatString.cpp | 1 - .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 4 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 6 - .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 10 + contrib/llvm-project/clang/lib/AST/Type.cpp | 7 + .../clang/lib/Analysis/PathDiagnostic.cpp | 7 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 38 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 64 ++ contrib/llvm-project/clang/lib/Basic/Targets/ARM.h | 13 + contrib/llvm-project/clang/lib/Basic/Targets/AVR.h | 4 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 23 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 3 + contrib/llvm-project/clang/lib/CodeGen/CGClass.cpp | 6 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 61 +- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 2 + contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 14 +- .../clang/lib/CodeGen/CodeGenFunction.cpp | 98 +- .../clang/lib/CodeGen/CodeGenFunction.h | 58 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 4 + .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 263 ++++- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.h | 14 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 405 +++++++- .../clang/lib/CodeGen/CoverageMappingGen.h | 12 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 3 + contrib/llvm-project/clang/lib/Driver/Driver.cpp | 11 + .../clang/lib/Driver/ToolChains/Arch/Mips.cpp | 8 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 6 +- .../clang/lib/Driver/ToolChains/BareMetal.cpp | 5 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 11 + .../clang/lib/Driver/ToolChains/Gnu.cpp | 9 + .../clang/lib/Driver/ToolChains/MinGW.cpp | 25 +- .../clang/lib/Format/TokenAnnotator.cpp | 8 + contrib/llvm-project/clang/lib/Headers/arm_acle.h | 59 ++ .../clang/lib/Headers/llvm_libc_wrappers/stdio.h | 34 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 4 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 3 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 2 + .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 129 ++- .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 23 +- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 17 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 94 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 19 + contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 44 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 55 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 56 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 90 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 11 + .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 79 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 78 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 20 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 1 + contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 8 +- .../clang/utils/TableGen/ClangASTNodesEmitter.cpp | 103 +- .../clang/utils/TableGen/SveEmitter.cpp | 3 + .../llvm-project/clang/utils/TableGen/TableGen.cpp | 3 +- .../clang/utils/TableGen/TableGenBackends.h | 10 +- .../compiler-rt/lib/asan/asan_suppressions.cpp | 7 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 6 +- .../compiler-rt/lib/lsan/lsan_common.cpp | 7 +- contrib/llvm-project/compiler-rt/lib/msan/msan.h | 34 +- .../compiler-rt/lib/msan/msan_allocator.cpp | 40 +- .../compiler-rt/lib/msan/msan_new_delete.cpp | 26 +- .../compiler-rt/lib/orc/executor_symbol_def.h | 151 +++ .../orc/tests/unit/executor_symbol_def_test.cpp | 19 + .../unit/simple_packed_serialization_test.cpp | 20 +- .../tests/unit/simple_packed_serialization_utils.h | 34 + .../lib/sanitizer_common/sanitizer_common.h | 3 + .../sanitizer_platform_interceptors.h | 3 +- .../sanitizer_stacktrace_libcdep.cpp | 12 +- .../lib/sanitizer_common/sanitizer_symbolizer.h | 20 + .../sanitizer_symbolizer_report.cpp | 25 +- .../compiler-rt/lib/tsan/rtl/tsan_report.cpp | 26 +- .../compiler-rt/lib/ubsan/ubsan_diag.cpp | 2 +- .../compiler-rt/lib/ubsan/ubsan_diag.h | 20 - .../libcxx/include/__algorithm/pop_heap.h | 3 +- .../libcxx/include/__algorithm/sift_down.h | 2 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 4 +- .../libcxx/include/__charconv/to_chars_base_10.h | 6 +- .../libcxx/include/__charconv/to_chars_integral.h | 2 +- .../libcxx/include/__charconv/traits.h | 4 +- .../include/__chrono/parser_std_format_spec.h | 7 +- contrib/llvm-project/libcxx/include/__config | 7 + .../include/__filesystem/directory_iterator.h | 3 +- .../libcxx/include/__filesystem/path_iterator.h | 4 +- .../llvm-project/libcxx/include/__format/buffer.h | 12 +- .../libcxx/include/__format/format_arg.h | 2 +- .../libcxx/include/__format/format_arg_store.h | 8 +- .../libcxx/include/__format/formatter_bool.h | 2 +- .../include/__format/formatter_floating_point.h | 55 +- .../libcxx/include/__format/formatter_integral.h | 16 +- .../libcxx/include/__format/formatter_output.h | 6 +- .../libcxx/include/__format/formatter_string.h | 5 +- .../include/__format/parser_std_format_spec.h | 7 +- .../libcxx/include/__format/range_formatter.h | 5 +- .../llvm-project/libcxx/include/__format/unicode.h | 14 +- .../libcxx/include/__format/write_escaped.h | 2 +- contrib/llvm-project/libcxx/include/__hash_table | 5 +- .../libcxx/include/__iterator/advance.h | 13 +- .../llvm-project/libcxx/include/__iterator/next.h | 6 +- .../llvm-project/libcxx/include/__iterator/prev.h | 6 +- .../__random/negative_binomial_distribution.h | 7 +- .../libcxx/include/__ranges/chunk_by_view.h | 20 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 3 +- .../llvm-project/libcxx/include/__thread/thread.h | 2 +- .../libcxx/include/__utility/exception_guard.h | 2 +- .../libcxx/include/__utility/unreachable.h | 2 +- contrib/llvm-project/libcxx/include/fstream | 50 + contrib/llvm-project/libcxx/include/print | 8 +- contrib/llvm-project/libcxx/include/regex | 23 +- contrib/llvm-project/libcxx/include/set | 32 +- contrib/llvm-project/libcxx/include/span | 18 + contrib/llvm-project/libcxx/include/sstream | 6 +- contrib/llvm-project/libcxx/include/tuple | 32 +- contrib/llvm-project/libcxx/include/version | 4 +- contrib/llvm-project/libcxx/src/filesystem/error.h | 2 +- .../libcxx/src/filesystem/format_string.h | 2 +- .../libcxx/src/filesystem/posix_compat.h | 6 +- contrib/llvm-project/libcxx/src/fstream.cpp | 37 + .../libcxx/src/include/to_chars_floating_point.h | 20 +- .../llvm-project/libcxx/src/memory_resource.cpp | 2 +- contrib/llvm-project/libcxx/src/strstream.cpp | 2 +- contrib/llvm-project/libcxx/src/system_error.cpp | 2 +- .../llvm-project/libunwind/src/UnwindCursor.hpp | 77 +- contrib/llvm-project/lld/COFF/Config.h | 4 +- contrib/llvm-project/lld/ELF/Arch/AArch64.cpp | 3 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 42 + contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 2 + contrib/llvm-project/lld/ELF/InputSection.cpp | 11 +- contrib/llvm-project/lld/ELF/LinkerScript.cpp | 4 + contrib/llvm-project/lld/ELF/Relocations.cpp | 6 +- contrib/llvm-project/lld/ELF/ScriptParser.cpp | 27 +- contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 24 +- contrib/llvm-project/lld/ELF/SyntheticSections.h | 6 +- contrib/llvm-project/lld/ELF/Target.h | 10 + contrib/llvm-project/lld/ELF/Writer.cpp | 21 +- contrib/llvm-project/lld/ELF/Writer.h | 1 + .../lldb/include/lldb/API/SBBreakpoint.h | 2 + .../include/lldb/Breakpoint/BreakpointIDList.h | 6 +- .../lldb/include/lldb/Symbol/CompileUnit.h | 23 +- .../lldb/include/lldb/Symbol/SymbolFile.h | 2 +- .../lldb/include/lldb/Symbol/SymbolFileOnDemand.h | 2 +- .../lldb/include/lldb/Utility/FileSpecList.h | 106 +- .../lldb/include/lldb/Utility/StructuredData.h | 28 +- .../llvm-project/lldb/source/API/SBCompileUnit.cpp | 2 +- .../lldb/source/Breakpoint/BreakpointIDList.cpp | 21 +- .../Breakpoint/BreakpointResolverAddress.cpp | 12 +- .../source/Breakpoint/BreakpointResolverName.cpp | 8 +- .../source/Commands/CommandObjectBreakpoint.cpp | 4 +- .../lldb/source/Commands/CommandObjectSource.cpp | 2 +- .../llvm-project/lldb/source/Core/ModuleList.cpp | 2 +- .../ExpressionParser/Clang/ClangUserExpression.cpp | 12 +- .../Clang/CppModuleConfiguration.cpp | 6 +- .../TSan/InstrumentationRuntimeTSan.cpp | 5 +- .../source/Plugins/JITLoader/GDB/JITLoaderGDB.cpp | 2 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.cpp | 5 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.h | 3 +- .../source/Plugins/SymbolFile/CTF/SymbolFileCTF.h | 2 +- .../SymbolFile/DWARF/DWARFASTParserClang.cpp | 34 +- .../Plugins/SymbolFile/DWARF/DWARFASTParserClang.h | 1 + .../source/Plugins/SymbolFile/DWARF/DWARFIndex.cpp | 20 + .../source/Plugins/SymbolFile/DWARF/DWARFIndex.h | 14 + .../SymbolFile/DWARF/DebugNamesDWARFIndex.cpp | 2 +- .../SymbolFile/DWARF/DebugNamesDWARFIndex.h | 2 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 116 ++- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.h | 9 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp | 4 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.h | 2 +- .../Plugins/SymbolFile/JSON/SymbolFileJSON.h | 2 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.cpp | 7 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.h | 2 +- .../Plugins/SymbolFile/PDB/SymbolFilePDB.cpp | 2 +- .../source/Plugins/SymbolFile/PDB/SymbolFilePDB.h | 2 +- .../Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp | 2 +- .../Plugins/SymbolFile/Symtab/SymbolFileSymtab.h | 2 +- .../lldb/source/Symbol/CompileUnit.cpp | 13 +- .../lldb/source/Symbol/SymbolFileOnDemand.cpp | 2 +- .../lldb/source/Target/DynamicRegisterInfo.cpp | 15 +- .../lldb/source/Utility/FileSpecList.cpp | 58 +- .../llvm/include/llvm/Analysis/AliasSetTracker.h | 1 + .../llvm/include/llvm/Analysis/AssumptionCache.h | 2 + .../include/llvm/Analysis/BlockFrequencyInfo.h | 2 + .../include/llvm/Analysis/BranchProbabilityInfo.h | 2 + .../llvm/include/llvm/Analysis/CFGSCCPrinter.h | 1 + .../llvm/include/llvm/Analysis/CallGraph.h | 4 + .../llvm/include/llvm/Analysis/CallPrinter.h | 2 + .../llvm/include/llvm/Analysis/CostModel.h | 2 + .../llvm/include/llvm/Analysis/CycleAnalysis.h | 2 + .../llvm-project/llvm/include/llvm/Analysis/DDG.h | 1 + .../llvm/include/llvm/Analysis/DDGPrinter.h | 1 + .../llvm/include/llvm/Analysis/Delinearization.h | 1 + .../llvm/include/llvm/Analysis/DemandedBits.h | 2 + .../include/llvm/Analysis/DependenceAnalysis.h | 2 + .../llvm/include/llvm/Analysis/DominanceFrontier.h | 2 + .../llvm/Analysis/FunctionPropertiesAnalysis.h | 2 + .../include/llvm/Analysis/IRSimilarityIdentifier.h | 1 + .../llvm/include/llvm/Analysis/InlineAdvisor.h | 3 +- .../llvm/include/llvm/Analysis/InlineCost.h | 1 + .../llvm/Analysis/InlineSizeEstimatorAnalysis.h | 2 + .../llvm/include/llvm/Analysis/LazyCallGraph.h | 4 + .../llvm/include/llvm/Analysis/LazyValueInfo.h | 2 + .../llvm/include/llvm/Analysis/LoopCacheAnalysis.h | 2 + .../llvm/include/llvm/Analysis/LoopInfo.h | 2 + .../llvm/include/llvm/Analysis/LoopNestAnalysis.h | 2 + .../llvm/include/llvm/Analysis/MemDerefPrinter.h | 1 + .../llvm/include/llvm/Analysis/MemoryBuiltins.h | 165 ++-- .../llvm/include/llvm/Analysis/MemorySSA.h | 5 + .../include/llvm/Analysis/ModuleDebugInfoPrinter.h | 1 + .../llvm/include/llvm/Analysis/MustExecute.h | 2 + .../llvm/include/llvm/Analysis/PhiValues.h | 1 + .../llvm/include/llvm/Analysis/PostDominators.h | 2 + .../include/llvm/Analysis/ProfileSummaryInfo.h | 1 + .../llvm/include/llvm/Analysis/RegionInfo.h | 3 + .../llvm/include/llvm/Analysis/ScalarEvolution.h | 3 + .../llvm/include/llvm/Analysis/StackLifetime.h | 1 + .../include/llvm/Analysis/StackSafetyAnalysis.h | 2 + .../llvm/include/llvm/Analysis/StructuralHash.h | 2 + .../include/llvm/Analysis/TargetTransformInfo.h | 8 + .../llvm/Analysis/TargetTransformInfoImpl.h | 4 +- .../include/llvm/Analysis/UniformityAnalysis.h | 2 + .../llvm/include/llvm/Analysis/ValueTracking.h | 9 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 36 + .../llvm/include/llvm/BinaryFormat/ELF.h | 1 + .../llvm/BinaryFormat/ELFRelocs/LoongArch.def | 23 + .../llvm/include/llvm/Bitstream/BitstreamWriter.h | 6 +- .../llvm/include/llvm/CodeGen/AccelTable.h | 15 +- .../llvm/CodeGen/BasicBlockSectionsProfileReader.h | 83 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 25 +- .../llvm/include/llvm/CodeGen/CodeGenPrepare.h | 35 + .../llvm/include/llvm/CodeGen/FastISel.h | 14 + .../llvm/include/llvm/CodeGen/GCMetadata.h | 11 + .../include/llvm/CodeGen/GlobalISel/IRTranslator.h | 4 + .../GlobalISel/LegalizationArtifactCombiner.h | 21 +- .../llvm/CodeGen/GlobalISel/LegalizerHelper.h | 18 +- .../llvm/CodeGen/GlobalISel/LegalizerInfo.h | 10 +- .../include/llvm/CodeGen/MachinePassRegistry.def | 9 +- .../llvm/CodeGen/NonRelocatableStringpool.h | 3 +- .../llvm/include/llvm/CodeGen/Passes.h | 4 +- .../llvm/include/llvm/CodeGen/RuntimeLibcalls.h | 6 + .../llvm/include/llvm/CodeGen/SelectionDAGNodes.h | 20 +- .../include/llvm/CodeGen/ShadowStackGCLowering.h | 24 + .../llvm/include/llvm/CodeGen/StackProtector.h | 93 +- .../include/llvm/CodeGen/SwitchLoweringUtils.h | 16 + .../AddressesMap.h | 10 +- .../llvm/DWARFLinker/{ => Classic}/DWARFLinker.h | 216 +--- .../{ => Classic}/DWARFLinkerCompileUnit.h | 12 +- .../{ => Classic}/DWARFLinkerDeclContext.h | 12 +- .../llvm/DWARFLinker/{ => Classic}/DWARFStreamer.h | 28 +- .../DWARFFile.h | 17 +- .../include/llvm/DWARFLinker/DWARFLinkerBase.h | 100 ++ .../Parallel}/DWARFLinker.h | 108 +- .../StringPool.h | 25 +- .../include/llvm/DebugInfo/DWARF/DWARFDebugMacro.h | 9 +- .../llvm/include/llvm/DebugInfo/DWARF/DWARFUnit.h | 6 +- .../llvm/include/llvm/Demangle/Demangle.h | 5 +- .../llvm/include/llvm/Demangle/ItaniumDemangle.h | 22 +- .../include/llvm/ExecutionEngine/JITLink/JITLink.h | 5 + .../llvm/include/llvm/ExecutionEngine/Orc/Core.h | 10 +- .../Orc/EPCDynamicLibrarySearchGenerator.h | 23 +- .../ExecutionEngine/Orc/EPCGenericDylibManager.h | 7 +- .../llvm/ExecutionEngine/Orc/ExecutionUtils.h | 20 +- .../ExecutionEngine/Orc/Shared/ExecutorSymbolDef.h | 58 ++ .../llvm/ExecutionEngine/Orc/Shared/OrcRTBridge.h | 3 +- .../Orc/Shared/TargetProcessControlTypes.h | 3 +- .../Orc/TargetProcess/JITLoaderGDB.h | 26 + .../Orc/TargetProcess/SimpleExecutorDylibManager.h | 5 +- .../llvm-project/llvm/include/llvm/IR/Dominators.h | 3 + .../include/llvm/IR/GetElementPtrTypeIterator.h | 57 +- .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 7 +- .../llvm/include/llvm/IR/IntrinsicsSPIRV.td | 1 + .../llvm/include/llvm/IR/PatternMatch.h | 2 +- .../llvm/include/llvm/IR/SafepointIRVerifier.h | 2 + .../llvm/include/llvm/InitializePasses.h | 4 +- contrib/llvm-project/llvm/include/llvm/LTO/LTO.h | 4 +- .../llvm-project/llvm/include/llvm/LinkAllPasses.h | 2 +- .../llvm/include/llvm/MC/MCAsmBackend.h | 6 +- .../llvm/include/llvm/Object/ELFObjectFile.h | 36 + .../llvm/include/llvm/Object/ELFTypes.h | 3 + .../llvm/include/llvm/Object/ObjectFile.h | 1 + .../include/llvm/Passes/StandardInstrumentations.h | 2 +- .../llvm/include/llvm/Support/RISCVISAInfo.h | 6 +- .../llvm/Target/GlobalISel/SelectionDAGCompat.td | 1 + .../include/llvm/Target/TargetInstrPredicate.td | 6 + .../llvm/include/llvm/Target/TargetMachine.h | 4 +- .../llvm/include/llvm/Target/TargetSchedule.td | 113 +++ .../llvm/include/llvm/Target/TargetSelectionDAG.td | 13 + .../llvm/TargetParser/AArch64TargetParser.h | 7 +- .../llvm/include/llvm/TargetParser/Triple.h | 6 + .../llvm/Transforms/Scalar/IVUsersPrinter.h | 1 + .../Transforms/Scalar/LoopAccessAnalysisPrinter.h | 1 + .../include/llvm/Transforms/Utils/PredicateInfo.h | 2 + .../llvm/lib/Analysis/AssumptionCache.cpp | 13 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 61 +- .../llvm/lib/Analysis/ConstraintSystem.cpp | 4 +- .../llvm-project/llvm/lib/Analysis/InlineCost.cpp | 2 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 14 +- contrib/llvm-project/llvm/lib/Analysis/Local.cpp | 2 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 5 +- .../llvm-project/llvm/lib/Analysis/LoopInfo.cpp | 4 +- .../llvm/lib/Analysis/MemoryBuiltins.cpp | 308 +++--- .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 17 +- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 9 + .../llvm/lib/Analysis/VFABIDemangling.cpp | 9 +- .../llvm/lib/Analysis/ValueTracking.cpp | 11 +- .../lib/BinaryFormat/AMDGPUMetadataVerifier.cpp | 1 + .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 67 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 80 +- .../llvm/lib/CodeGen/BasicBlockPathCloning.cpp | 11 +- .../llvm/lib/CodeGen/BasicBlockSections.cpp | 8 +- .../CodeGen/BasicBlockSectionsProfileReader.cpp | 52 +- contrib/llvm-project/llvm/lib/CodeGen/CodeGen.cpp | 2 +- .../llvm/lib/CodeGen/CodeGenPrepare.cpp | 127 ++- .../llvm/lib/CodeGen/GCRootLowering.cpp | 33 +- .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 81 +- .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 312 +++++- .../llvm/lib/CodeGen/NonRelocatableStringpool.cpp | 3 - .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 160 +-- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 10 +- .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 329 ++++--- .../llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp | 4 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 26 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 48 +- .../CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp | 17 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h | 2 + .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 10 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 14 +- .../SelectionDAG/SelectionDAGAddressAnalysis.cpp | 19 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 117 +-- .../lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h | 6 - .../CodeGen/SelectionDAG/SelectionDAGDumper.cpp | 5 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 19 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 72 +- .../llvm/lib/CodeGen/ShadowStackGCLowering.cpp | 97 +- .../llvm/lib/CodeGen/StackProtector.cpp | 154 ++- .../llvm/lib/CodeGen/SwitchLoweringUtils.cpp | 81 ++ .../llvm/lib/CodeGen/TargetLoweringBase.cpp | 40 +- .../llvm/lib/CodeGen/TargetPassConfig.cpp | 4 +- .../lib/DWARFLinker/{ => Classic}/DWARFLinker.cpp | 66 +- .../{ => Classic}/DWARFLinkerCompileUnit.cpp | 7 +- .../{ => Classic}/DWARFLinkerDeclContext.cpp | 7 +- .../DWARFLinker/{ => Classic}/DWARFStreamer.cpp | 36 +- .../Parallel}/AcceleratorRecordsSaver.cpp | 8 +- .../Parallel}/AcceleratorRecordsSaver.h | 14 +- .../Parallel}/ArrayList.h | 18 +- .../Parallel}/DIEAttributeCloner.cpp | 8 +- .../Parallel}/DIEAttributeCloner.h | 14 +- .../Parallel}/DIEGenerator.h | 14 +- .../Parallel}/DWARFEmitterImpl.cpp | 10 +- .../Parallel}/DWARFEmitterImpl.h | 16 +- .../Parallel}/DWARFLinker.cpp | 12 +- .../Parallel}/DWARFLinkerCompileUnit.cpp | 5 +- .../Parallel}/DWARFLinkerCompileUnit.h | 16 +- .../Parallel}/DWARFLinkerGlobalData.h | 24 +- .../Parallel}/DWARFLinkerImpl.cpp | 207 ++-- .../Parallel}/DWARFLinkerImpl.h | 20 +- .../Parallel}/DWARFLinkerTypeUnit.cpp | 7 +- .../Parallel}/DWARFLinkerTypeUnit.h | 14 +- .../Parallel}/DWARFLinkerUnit.cpp | 8 +- .../Parallel}/DWARFLinkerUnit.h | 18 +- .../Parallel}/DebugLineSectionEmitter.h | 31 +- .../Parallel}/DependencyTracker.cpp | 8 +- .../Parallel}/DependencyTracker.h | 14 +- .../Parallel}/IndexedValuesMap.h | 14 +- .../Parallel}/OutputSections.cpp | 27 +- .../Parallel}/OutputSections.h | 34 +- .../StringEntryToDwarfStringPoolEntryMap.h | 16 +- .../Parallel}/SyntheticTypeNameBuilder.cpp | 8 +- .../Parallel}/SyntheticTypeNameBuilder.h | 14 +- .../Parallel}/TypePool.h | 35 +- .../Parallel}/Utils.h | 14 +- .../StringPool.cpp => DWARFLinker/Utils.cpp} | 4 +- .../llvm/lib/DWARFLinkerParallel/DWARFFile.cpp | 17 - .../llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | 9 +- .../llvm-project/llvm/lib/Demangle/Demangle.cpp | 5 +- .../llvm/lib/Demangle/ItaniumDemangle.cpp | 4 +- .../lib/ExecutionEngine/Interpreter/Execution.cpp | 2 +- .../llvm/lib/ExecutionEngine/JITLink/JITLink.cpp | 35 + .../lib/ExecutionEngine/JITLink/JITLinkGeneric.cpp | 14 + .../Orc/EPCDebugObjectRegistrar.cpp | 3 +- .../Orc/EPCDynamicLibrarySearchGenerator.cpp | 16 +- .../ExecutionEngine/Orc/EPCGenericDylibManager.cpp | 10 +- .../lib/ExecutionEngine/Orc/ExecutionUtils.cpp | 12 +- .../ExecutionEngine/Orc/ExecutorProcessControl.cpp | 6 +- .../ExecutionEngine/Orc/LookupAndRecordAddrs.cpp | 2 +- .../llvm/lib/ExecutionEngine/Orc/MachOPlatform.cpp | 2 + .../lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp | 14 +- .../Orc/TargetProcess/JITLoaderGDB.cpp | 23 - .../TargetProcess/SimpleExecutorDylibManager.cpp | 9 +- contrib/llvm-project/llvm/lib/IR/AsmWriter.cpp | 13 +- contrib/llvm-project/llvm/lib/IR/AutoUpgrade.cpp | 499 +++++----- contrib/llvm-project/llvm/lib/IR/DataLayout.cpp | 5 +- contrib/llvm-project/llvm/lib/IR/Operator.cpp | 12 +- contrib/llvm-project/llvm/lib/IR/Value.cpp | 2 +- contrib/llvm-project/llvm/lib/LTO/LTO.cpp | 36 +- contrib/llvm-project/llvm/lib/MC/MCAssembler.cpp | 6 +- contrib/llvm-project/llvm/lib/MC/MCExpr.cpp | 6 + contrib/llvm-project/llvm/lib/Object/ELF.cpp | 7 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 2 +- .../llvm-project/llvm/lib/Object/ObjectFile.cpp | 11 +- .../llvm/lib/Object/WasmObjectFile.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 9 +- .../llvm-project/llvm/lib/Passes/PassRegistry.def | 6 + .../llvm/lib/Passes/StandardInstrumentations.cpp | 52 +- .../llvm/lib/ProfileData/InstrProf.cpp | 27 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 9 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 41 +- .../llvm-project/llvm/lib/Target/AArch64/AArch64.h | 1 + .../llvm/lib/Target/AArch64/AArch64.td | 2 +- .../llvm/lib/Target/AArch64/AArch64FastISel.cpp | 19 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 6 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 15 +- .../llvm/lib/Target/AArch64/AArch64InstrFormats.td | 1 + .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 828 ++++++++++++++++ .../lib/Target/AArch64/AArch64LoopIdiomTransform.h | 25 + .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 5 +- .../lib/Target/AArch64/AArch64SelectionDAGInfo.cpp | 2 +- .../lib/Target/AArch64/AArch64TargetMachine.cpp | 11 + .../llvm/lib/Target/AArch64/AArch64TargetMachine.h | 4 + .../Target/AArch64/AArch64TargetTransformInfo.h | 2 + .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 59 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.h | 4 +- .../llvm/lib/Target/AArch64/SVEInstrFormats.td | 12 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUCallingConv.td | 26 +- .../llvm/lib/Target/AMDGPU/AMDGPUCombine.td | 9 +- .../Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 23 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 14 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 58 +- .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 8 +- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 29 +- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.h | 4 +- .../llvm/lib/Target/AMDGPU/AMDGPULibCalls.cpp | 32 +- .../lib/Target/AMDGPU/AMDGPUMachineFunction.cpp | 39 +- .../llvm/lib/Target/AMDGPU/AMDGPUMachineFunction.h | 7 + .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 34 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 168 +++- .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.h | 5 + .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.h | 3 +- .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 37 +- .../llvm/lib/Target/AMDGPU/BUFInstructions.td | 10 +- .../llvm/lib/Target/AMDGPU/DSDIRInstructions.td | 192 ++++ .../llvm/lib/Target/AMDGPU/DSInstructions.td | 1 - .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 6 + .../llvm/lib/Target/AMDGPU/EXPInstructions.td | 1 + .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 46 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 9 +- .../llvm/lib/Target/AMDGPU/LDSDIRInstructions.td | 116 --- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 139 ++- .../Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h | 10 +- .../AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.cpp | 19 +- .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 8 +- .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 148 ++- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 287 +++++- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 2 + .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 10 + .../llvm/lib/Target/AMDGPU/SIInstrFormats.td | 2 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 210 +++- .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 6 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 19 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 174 +++- .../llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp | 70 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 8 +- .../llvm/lib/Target/AMDGPU/SIWholeQuadMode.cpp | 4 +- .../llvm/lib/Target/AMDGPU/SMInstructions.td | 44 +- .../llvm/lib/Target/AMDGPU/SOPInstructions.td | 52 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 106 +- .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 11 +- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 2 +- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 18 +- .../llvm/lib/Target/ARC/ARCISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/ARC/ARCISelLowering.cpp | 2 + .../llvm/lib/Target/ARC/ARCTargetMachine.cpp | 7 + .../llvm/lib/Target/ARM/ARMFastISel.cpp | 2 +- .../llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp | 24 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 19 +- .../llvm/lib/Target/ARM/ARMLegalizerInfo.cpp | 10 +- .../llvm/lib/Target/ARM/ARMLegalizerInfo.h | 4 +- .../llvm/lib/Target/AVR/AVRISelLowering.cpp | 4 +- .../llvm/lib/Target/BPF/BPFISelLowering.cpp | 1 + .../llvm/lib/Target/BPF/BPFTargetMachine.cpp | 5 +- .../llvm/lib/Target/BPF/BPFTargetMachine.h | 3 +- .../llvm/lib/Target/DirectX/DXILResourceAnalysis.h | 1 + .../lib/Target/DirectX/DirectXTargetMachine.cpp | 3 +- .../llvm/lib/Target/DirectX/DirectXTargetMachine.h | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 2 +- .../lib/Target/Hexagon/HexagonISelLoweringHVX.cpp | 6 +- .../lib/Target/Hexagon/HexagonTargetMachine.cpp | 3 +- .../llvm/lib/Target/Hexagon/HexagonTargetMachine.h | 3 +- .../llvm/lib/Target/Lanai/LanaiISelLowering.cpp | 2 + .../llvm/lib/Target/Lanai/LanaiTargetMachine.cpp | 7 + .../LoongArch/AsmParser/LoongArchAsmParser.cpp | 61 ++ .../LoongArch/LoongArchExpandPseudoInsts.cpp | 521 +++++----- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 65 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 7 +- .../lib/Target/LoongArch/LoongArchInstrInfo.td | 106 +- .../lib/Target/LoongArch/LoongArchMCInstLower.cpp | 3 + .../lib/Target/LoongArch/LoongArchRegisterInfo.cpp | 23 + .../lib/Target/LoongArch/LoongArchRegisterInfo.h | 1 + .../Target/LoongArch/LoongArchTargetMachine.cpp | 4 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 69 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 3 + .../LoongArch/MCTargetDesc/LoongArchBaseInfo.h | 1 + .../MCTargetDesc/LoongArchELFObjectWriter.cpp | 2 + .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 5 +- .../MCTargetDesc/LoongArchMCCodeEmitter.cpp | 3 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.cpp | 3 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.h | 1 + .../llvm/lib/Target/M68k/GISel/M68kLegalizerInfo.h | 1 - .../llvm/lib/Target/M68k/M68kISelLowering.cpp | 4 +- .../llvm/lib/Target/MSP430/MSP430ISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 7 +- .../llvm/lib/Target/MSP430/MSP430TargetMachine.cpp | 7 + .../llvm/lib/Target/Mips/MipsFastISel.cpp | 2 +- .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 3 +- .../llvm/lib/Target/Mips/MipsLegalizerInfo.cpp | 5 +- .../llvm/lib/Target/Mips/MipsLegalizerInfo.h | 3 +- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 3 +- .../llvm/lib/Target/NVPTX/NVPTXTargetMachine.cpp | 3 +- .../llvm/lib/Target/NVPTX/NVPTXTargetMachine.h | 3 +- .../lib/Target/NVPTX/NVPTXTargetTransformInfo.cpp | 34 - .../llvm/lib/Target/PowerPC/PPCFastISel.cpp | 2 +- .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 13 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 16 +- .../llvm/lib/Target/PowerPC/PPCRegisterInfo.td | 9 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 9 +- .../lib/Target/RISCV/GISel/RISCVCallLowering.cpp | 2 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 7 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.h | 4 +- .../lib/Target/RISCV/MCA/RISCVCustomBehaviour.cpp | 33 +- .../Target/RISCV/MCTargetDesc/RISCVAsmBackend.cpp | 9 +- .../Target/RISCV/MCTargetDesc/RISCVAsmBackend.h | 4 +- .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 1 - .../lib/Target/RISCV/MCTargetDesc/RISCVMCExpr.cpp | 2 - .../llvm/lib/Target/RISCV/RISCVAsmPrinter.cpp | 3 - .../lib/Target/RISCV/RISCVExpandPseudoInsts.cpp | 10 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 6 + .../Target/RISCV/RISCVGatherScatterLowering.cpp | 2 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 10 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 375 +++---- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 13 +- .../llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp | 5 + .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 7 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.td | 54 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoA.td | 12 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoD.td | 2 + .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 2 + .../lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td | 16 + .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 122 +-- .../llvm/lib/Target/RISCV/RISCVInstrInfoZa.td | 44 + .../llvm/lib/Target/RISCV/RISCVOptWInstrs.cpp | 6 +- .../llvm/lib/Target/RISCV/RISCVProcessors.td | 3 +- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 2 +- .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 7 + .../lib/Target/RISCV/RISCVTargetTransformInfo.cpp | 114 ++- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 3 + .../llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp | 7 +- .../llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp | 125 ++- .../llvm/lib/Target/SPIRV/SPIRVLegalizerInfo.cpp | 5 +- .../llvm/lib/Target/SPIRV/SPIRVLegalizerInfo.h | 3 +- .../llvm/lib/Target/SPIRV/SPIRVPreLegalizer.cpp | 59 +- .../llvm/lib/Target/SPIRV/SPIRVTargetMachine.cpp | 14 + .../llvm/lib/Target/SPIRV/SPIRVUtils.cpp | 4 +- .../llvm/lib/Target/SPIRV/SPIRVUtils.h | 2 +- .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 8 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 27 +- .../lib/Target/WebAssembly/WebAssemblyFastISel.cpp | 2 +- .../Target/WebAssembly/WebAssemblyISelLowering.cpp | 7 +- .../llvm/lib/Target/X86/GISel/X86LegalizerInfo.h | 1 - .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 16 - .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 3 + contrib/llvm-project/llvm/lib/Target/X86/X86.h | 8 +- .../X86/{X86EvexToVex.cpp => X86CompressEVEX.cpp} | 168 ++-- .../llvm/lib/Target/X86/X86DomainReassignment.cpp | 67 +- .../llvm/lib/Target/X86/X86FastISel.cpp | 12 +- .../llvm/lib/Target/X86/X86FlagsCopyLowering.cpp | 1 - .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 122 ++- .../llvm/lib/Target/X86/X86ISelLowering.h | 10 - .../llvm/lib/Target/X86/X86ISelLoweringCall.cpp | 37 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 248 ++--- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1030 ++++++++++++-------- .../llvm/lib/Target/X86/X86InstrFormats.td | 6 - .../llvm/lib/Target/X86/X86InstrInfo.h | 4 +- .../llvm/lib/Target/X86/X86InstrMisc.td | 120 +-- .../llvm/lib/Target/X86/X86InstrPredicates.td | 33 + .../llvm/lib/Target/X86/X86InstrShiftRotate.td | 2 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 13 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 10 +- .../llvm/lib/Target/X86/X86MCInstLower.cpp | 7 +- .../llvm/lib/Target/X86/X86TargetMachine.cpp | 4 +- .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 1 + .../llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp | 2 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 3 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 7 +- .../llvm/lib/Transforms/Coroutines/CoroFrame.cpp | 12 +- .../lib/Transforms/IPO/AttributorAttributes.cpp | 6 +- .../Transforms/InstCombine/InstCombineAddSub.cpp | 7 - .../Transforms/InstCombine/InstCombineCalls.cpp | 62 +- .../Transforms/InstCombine/InstCombineCompares.cpp | 68 +- .../Transforms/InstCombine/InstCombineInternal.h | 23 +- .../InstCombine/InstCombineMulDivRem.cpp | 7 - .../InstCombine/InstructionCombining.cpp | 135 ++- .../Instrumentation/AddressSanitizer.cpp | 50 +- .../Transforms/Instrumentation/BoundsChecking.cpp | 8 +- .../Transforms/Instrumentation/InstrProfiling.cpp | 10 +- .../Instrumentation/PGOInstrumentation.cpp | 51 +- .../Transforms/Scalar/ConstraintElimination.cpp | 91 +- .../Scalar/CorrelatedValuePropagation.cpp | 51 +- .../llvm/lib/Transforms/Scalar/SROA.cpp | 6 +- .../Scalar/SeparateConstOffsetFromGEP.cpp | 6 +- .../Scalar/StraightLineStrengthReduce.cpp | 2 +- .../lib/Transforms/Utils/InjectTLIMappings.cpp | 46 +- .../llvm/lib/Transforms/Utils/SCCPSolver.cpp | 10 +- .../llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 35 +- .../llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp | 20 +- .../Transforms/Vectorize/LoadStoreVectorizer.cpp | 2 +- .../Vectorize/LoopVectorizationPlanner.h | 27 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 481 ++++----- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 24 +- .../lib/Transforms/Vectorize/VPRecipeBuilder.h | 7 +- .../llvm/lib/Transforms/Vectorize/VPlan.cpp | 1 + .../llvm/lib/Transforms/Vectorize/VPlan.h | 34 +- .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 88 +- .../lib/Transforms/Vectorize/VPlanTransforms.cpp | 23 +- .../llvm-project/llvm/tools/lli/ExecutionUtils.cpp | 32 +- .../llvm/tools/lli/ForwardingMemoryManager.h | 9 +- contrib/llvm-project/llvm/tools/lli/lli.cpp | 9 +- .../llvm-project/llvm/tools/llvm-cxxfilt/Opts.td | 2 + .../llvm/tools/llvm-cxxfilt/llvm-cxxfilt.cpp | 10 +- .../llvm/tools/llvm-dwarfutil/DebugInfoLinker.cpp | 32 +- .../llvm/tools/llvm-profdata/llvm-profdata.cpp | 23 +- .../llvm/tools/llvm-readobj/ELFDumper.cpp | 1 + contrib/llvm-project/llvm/tools/opt/opt.cpp | 2 +- .../utils/TableGen/GlobalISelCombinerEmitter.cpp | 16 +- .../TableGen/MacroFusionPredicatorEmitter.cpp | 236 +++++ .../llvm/utils/TableGen/PredicateExpander.cpp | 8 + .../llvm/utils/TableGen/PredicateExpander.h | 1 + .../TableGen/X86CompressEVEXTablesEmitter.cpp | 206 ++++ .../utils/TableGen/X86EVEX2VEXTablesEmitter.cpp | 210 ---- .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 6 +- .../utils/TableGen/X86ManualCompressEVEXTables.def | 331 +++++++ contrib/llvm-project/openmp/runtime/src/kmp.h | 7 + .../openmp/runtime/src/kmp_config.h.cmake | 2 +- .../openmp/runtime/src/kmp_ftn_entry.h | 2 +- .../llvm-project/openmp/runtime/src/kmp_global.cpp | 2 +- .../openmp/runtime/src/kmp_gsupport.cpp | 3 +- contrib/llvm-project/openmp/runtime/src/kmp_os.h | 9 +- .../llvm-project/openmp/runtime/src/kmp_platform.h | 32 +- .../openmp/runtime/src/kmp_runtime.cpp | 8 +- .../openmp/runtime/src/kmp_settings.cpp | 4 +- .../openmp/runtime/src/kmp_wrapper_getpid.h | 5 + .../openmp/runtime/src/z_Linux_util.cpp | 21 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 7 +- usr.bin/clang/llvm-tblgen/Makefile | 3 +- 691 files changed, 13954 insertions(+), 6431 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/Attr.h b/contrib/llvm-project/clang/include/clang/AST/Attr.h index 1b831c9511e2..8e9b7ad8b468 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Attr.h +++ b/contrib/llvm-project/clang/include/clang/AST/Attr.h @@ -25,6 +25,7 @@ #include "clang/Basic/Sanitizers.h" #include "clang/Basic/SourceLocation.h" #include "llvm/Frontend/HLSL/HLSLResource.h" +#include "llvm/Support/CodeGen.h" #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/VersionTuple.h" #include "llvm/Support/raw_ostream.h" diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h index 432293583576..984a4d8bab5e 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h @@ -2044,6 +2044,14 @@ public: // Implement isa/cast/dyncast/etc. static bool classof(const Decl *D) { return classofKind(D->getKind()); } static bool classofKind(Kind K) { return K == RequiresExprBody; } + + static DeclContext *castToDeclContext(const RequiresExprBodyDecl *D) { + return static_cast(const_cast(D)); + } + + static RequiresExprBodyDecl *castFromDeclContext(const DeclContext *DC) { + return static_cast(const_cast(DC)); + } }; /// Represents a static or instance method of a struct/union/class. diff --git a/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h b/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h index 2f4ed082a0c7..732749ad305e 100644 --- a/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h +++ b/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h @@ -252,6 +252,8 @@ public: void VisitGotoStmt(const GotoStmt *Node); void VisitCaseStmt(const CaseStmt *Node); void VisitReturnStmt(const ReturnStmt *Node); + void VisitCoawaitExpr(const CoawaitExpr *Node); + void VisitCoreturnStmt(const CoreturnStmt *Node); void VisitCompoundStmt(const CompoundStmt *Node); void VisitConstantExpr(const ConstantExpr *Node); void VisitCallExpr(const CallExpr *Node); diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index 1afa69367286..9e9f896ebef7 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -4224,6 +4224,8 @@ public: ExceptionSpecInfo() = default; ExceptionSpecInfo(ExceptionSpecificationType EST) : Type(EST) {} + + void instantiate(); }; /// Extra information about a function prototype. ExtProtoInfo is not diff --git a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h index 8a2d56668e32..b28f2c6b99c5 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h +++ b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h @@ -66,7 +66,7 @@ public: /// Invoked when an unsafe operation over raw pointers is found. virtual void handleUnsafeOperation(const Stmt *Operation, - bool IsRelatedToDecl) = 0; + bool IsRelatedToDecl, ASTContext &Ctx) = 0; /// Invoked when a fix is suggested against a variable. This function groups /// all variables that must be fixed together (i.e their types must be changed diff --git a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def index 757ee452ced7..c97661688365 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def +++ b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def @@ -30,6 +30,7 @@ WARNING_GADGET(Decrement) WARNING_GADGET(ArraySubscript) WARNING_GADGET(PointerArithmetic) WARNING_GADGET(UnsafeBufferUsageAttr) +WARNING_GADGET(DataInvocation) FIXABLE_GADGET(ULCArraySubscript) // `DRE[any]` in an Unspecified Lvalue Context FIXABLE_GADGET(DerefSimplePtrArithFixable) FIXABLE_GADGET(PointerDereference) diff --git a/contrib/llvm-project/clang/include/clang/Analysis/CFG.h b/contrib/llvm-project/clang/include/clang/Analysis/CFG.h index 67383bb316d3..9f776ca6cc26 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/CFG.h +++ b/contrib/llvm-project/clang/include/clang/Analysis/CFG.h @@ -1215,7 +1215,9 @@ public: //===--------------------------------------------------------------------===// class BuildOptions { - std::bitset alwaysAddMask; + // Stmt::lastStmtConstant has the same value as the last Stmt kind, + // so make sure we add one to account for this! + std::bitset alwaysAddMask; public: using ForcedBlkExprs = llvm::DenseMap; diff --git a/contrib/llvm-project/clang/include/clang/Basic/Attr.td b/contrib/llvm-project/clang/include/clang/Basic/Attr.td index db17211747b1..d5eabaad4889 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/Attr.td +++ b/contrib/llvm-project/clang/include/clang/Basic/Attr.td @@ -143,6 +143,11 @@ def ExternalGlobalVar : SubsetSubjectisLocalExternDecl()}], "external global variables">; +def NonTLSGlobalVar : SubsetSubjecthasGlobalStorage() && + S->getTLSKind() == 0}], + "non-TLS global variables">; + def InlineFunction : SubsetSubjectisInlineSpecified()}], "inline functions">; @@ -431,6 +436,7 @@ def TargetAArch64 : TargetArch<["aarch64", "aarch64_be", "aarch64_32"]>; def TargetAnyArm : TargetArch; def TargetAVR : TargetArch<["avr"]>; def TargetBPF : TargetArch<["bpfel", "bpfeb"]>; +def TargetLoongArch : TargetArch<["loongarch32", "loongarch64"]>; def TargetMips32 : TargetArch<["mips", "mipsel"]>; def TargetAnyMips : TargetArch<["mips", "mipsel", "mips64", "mips64el"]>; def TargetMSP430 : TargetArch<["msp430"]>; @@ -1121,6 +1127,14 @@ def CoroLifetimeBound : InheritableAttr { let SimpleHandler = 1; } +def CoroDisableLifetimeBound : InheritableAttr { + let Spellings = [Clang<"coro_disable_lifetimebound">]; + let Subjects = SubjectList<[Function]>; + let LangOpts = [CPlusPlus]; + let Documentation = [CoroLifetimeBoundDoc]; + let SimpleHandler = 1; +} + // OSObject-based attributes. def OSConsumed : InheritableParamAttr { let Spellings = [Clang<"os_consumed">]; @@ -2730,6 +2744,15 @@ def PragmaClangTextSection : InheritableAttr { let Documentation = [InternalOnly]; } +def CodeModel : InheritableAttr, TargetSpecificAttr { + let Spellings = [GCC<"model">]; + let Args = [EnumArgument<"Model", "llvm::CodeModel::Model", + ["normal", "medium", "extreme"], ["Small", "Medium", "Large"], + /*opt=*/0, /*fake=*/0, /*isExternalType=*/1>]; + let Subjects = SubjectList<[NonTLSGlobalVar], ErrorDiag>; + let Documentation = [CodeModelDocs]; +} + def Sentinel : InheritableAttr { let Spellings = [GCC<"sentinel">]; let Args = [DefaultIntArgument<"Sentinel", 0>, diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 98a7ecc7fd7d..5416a0cbdd07 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -57,6 +57,15 @@ global variable or function should be in after translation. let Heading = "section, __declspec(allocate)"; } +def CodeModelDocs : Documentation { + let Category = DocCatVariable; + let Content = [{ +The ``model`` attribute allows overriding the translation unit's +code model (specified by ``-mcmodel``) for a specific global variable. + }]; + let Heading = "model"; +} + def UsedDocs : Documentation { let Category = DocCatFunction; let Content = [{ @@ -7671,9 +7680,12 @@ The ``[[clang::coro_lifetimebound]]`` is a class attribute which can be applied to a coroutine return type (`CRT`_) (i.e. it should also be annotated with ``[[clang::coro_return_type]]``). -All parameters of a function are considered to be lifetime bound. See `documentation`_ -of ``[[clang::lifetimebound]]`` for more details. -if the function returns a coroutine return type (CRT) annotated with ``[[clang::coro_lifetimebound]]``. +All parameters of a function are considered to be lifetime bound if the function returns a +coroutine return type (CRT) annotated with ``[[clang::coro_lifetimebound]]``. +This lifetime bound analysis can be disabled for a coroutine wrapper or a coroutine by annotating the function +with ``[[clang::coro_disable_lifetimebound]]`` function attribute . +See `documentation`_ of ``[[clang::lifetimebound]]`` for details about lifetime bound analysis. + Reference parameters of a coroutine are susceptible to capturing references to temporaries or local variables. @@ -7703,7 +7715,7 @@ Both coroutines and coroutine wrappers are part of this analysis. }; Task coro(const int& a) { co_return a + 1; } - Task [[clang::coro_wrapper]] coro_wrapper(const int& a, const int& b) { + [[clang::coro_wrapper]] Task coro_wrapper(const int& a, const int& b) { return a > b ? coro(a) : coro(b); } Task temporary_reference() { @@ -7718,6 +7730,21 @@ Both coroutines and coroutine wrappers are part of this analysis. return coro(a); // warning: returning address of stack variable `a`. } +This analysis can be disabled for all calls to a particular function by annotating the function +with function attribute ``[[clang::coro_disable_lifetimebound]]``. +For example, this could be useful for coroutine wrappers which accept reference parameters +but do not pass them to the underlying coroutine or pass them by value. + +.. code-block:: c++ + + Task coro(int a) { co_return a + 1; } + [[clang::coro_wrapper, clang::coro_disable_lifetimebound]] Task coro_wrapper(const int& a) { + return coro(a + 1); + } + void use() { + auto task = coro_wrapper(1); // use of temporary is fine as the argument is not lifetime bound. + } + .. _`documentation`: https://clang.llvm.org/docs/AttributeReference.html#lifetimebound .. _`CRT`: https://clang.llvm.org/docs/AttributeReference.html#coro-return-type }]; diff --git a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def index 0acb5ae134ea..2c4fb6745bc1 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def @@ -209,6 +209,7 @@ CODEGENOPT(CoverageMapping , 1, 0) ///< Generate coverage mapping regions to ///< enable code coverage analysis. CODEGENOPT(DumpCoverageMapping , 1, 0) ///< Dump the generated coverage mapping ///< regions. +CODEGENOPT(MCDCCoverage , 1, 0) ///< Enable MC/DC code coverage criteria. /// If -fpcc-struct-return or -freg-struct-return is specified. ENUM_CODEGENOPT(StructReturnConvention, StructReturnConventionKind, 2, SRCK_Default) diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td index 65a33f61a694..72952b08c04a 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td @@ -349,6 +349,9 @@ def warn_invalid_feature_combination : Warning< def warn_target_unrecognized_env : Warning< "mismatch between architecture and environment in target triple '%0'; did you mean '%1'?">, InGroup; +def warn_knl_knm_isa_support_removed : Warning< + "KNL, KNM related Intel Xeon Phi CPU's specific ISA's supports will be removed in LLVM 19.">, + InGroup>; // Source manager def err_cannot_open_file : Error<"cannot open file '%0': %1">, DefaultFatal; diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td index 676f1a62b49d..0a8a77fadbeb 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td @@ -786,4 +786,7 @@ def warn_android_unversioned_fallback : Warning< " directories will not be used in Clang 19. Provide a versioned directory" " for the target version or lower instead.">, InGroup>; + +def err_drv_triple_version_invalid : Error< + "version '%0' in target triple '%1' is invalid">; } diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td index e4b1069cde18..088f8b74983c 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td @@ -1364,6 +1364,8 @@ def err_acc_invalid_clause : Error<"invalid OpenACC clause %0">; def err_acc_missing_directive : Error<"expected OpenACC directive">; def err_acc_invalid_open_paren : Error<"expected clause-list or newline in OpenACC directive">; +def err_acc_invalid_default_clause_kind + : Error<"invalid value for 'default' clause; expected 'present' or 'none'">; // OpenMP support. def warn_pragma_omp_ignored : Warning< diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index cb68ded1f38c..e81d1a4fc288 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td *** 39310 LINES SKIPPED *** From nobody Sat Apr 20 10:32:20 2024 X-Original-To: dev-commits-src-branches@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 4VM79x2tWsz5HW4q; Sat, 20 Apr 2024 10:32:21 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79w6cvrz4PQ1; Sat, 20 Apr 2024 10:32:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609140; 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=RigoxpQpOhM0L34CuIHd+ma7Xh071h6HrLMFQGplW+E=; b=eaGPm7MLO9ICr7INwCVNMgxExqBueb0wsu/Ow3u5HRXOCmE3qAzWYf9SxV4qHXjG+GZbBu mR8MxuOhzMBiSJP5Wqq2d1oveJYpHeeYpC1iNFj5JKRrQn+K4B1bplBD/g5gZlPaVIjxhM C/RKevuEKSFbFUnib2vnhZFo96Dd2AoSTa7D76y4GFjHBnnvzbXs6chgAR2mZVZicR2wFE 89Sw6alGNWw3Y/Im/OG7K9aNEOhDuzbjrtNdQfxbV7UQwJuqw3xcwX/k5aw02+KMOIP7SQ Ts55Bm89bwmizjNliOL0Lbr6hfvxvo9JyXtthMwF+EoNat1IgngroBPnM9zs9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609140; a=rsa-sha256; cv=none; b=csroTP+stwQSBQS5bYdSpNHMklhWVDC/v4QPDafxY91NMP257a59NjWNriGrTv6Cy/ebN4 NQ495OisCoeDOLfzRvwooqruX6VDH1e3/7LbTD74vOXSR2KHuZotT4SdsmXcW5qwwDVNOs 377XfuJemWGq+XX1EdTzOJ5Nzkzop4E/YG0oRkpO2f1GvJeyICW5rUu75CLgUXUwQC7Axu tWD3jfzFf+hlmly7iHpq39lSXzLozv1pvCwpc3QH1e0lLZQ/9gYTkdv887MWMDctXhRfn8 qfyYebKIhWoNYQkqEmPgA6e2Xqcl9SqZPWo4/xLwLfo8reJPBSsnWb0lGv52HQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609140; 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=RigoxpQpOhM0L34CuIHd+ma7Xh071h6HrLMFQGplW+E=; b=gcisImj+qO9XPWiyOtVs80yCW/y2AFd5IE1y3rQ7B1JbN9L3fbu0pTkTW10ZvxRTy2k7Ie sTCFAGWzzRo73ijgKVH4ivUK0eIgt2xJTA++hm+7Z25LM9yaIAuFOoSmTiqhSzr1gLE+uF o6lrPO2BvGf8lWAg7QsLy9KKAILBcUD/GriSNlaMDiJvUsYuUKoSbe7Kgj+eqe6bBogF4d T4OKq4nU2H2LjgEbee9OfDRrjAbkmTUddGlOV2iBy/jZ4XF36UvEXUVtlklslo2q/JpUOd WOPcKUSUzyIlNpjVp8E9SWkmMLcHeSybAclTkdjBvyLgsqIXfGO9kJnSov+zCA== 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 4VM79w5wNyzYm6; Sat, 20 Apr 2024 10:32:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWKCg009691; Sat, 20 Apr 2024 10:32:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWKd3009688; Sat, 20 Apr 2024 10:32:20 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:20 GMT Message-Id: <202404201032.43KAWKd3009688@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: c8734e140f63 - stable/14 - Redo libc++ customizations List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: c8734e140f632b76ff5e638afcde7258bd688d2f Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=c8734e140f632b76ff5e638afcde7258bd688d2f commit c8734e140f632b76ff5e638afcde7258bd688d2f Author: Dimitry Andric AuthorDate: 2024-01-14 13:20:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:12 +0000 Redo libc++ customizations * Remove osreldate include because _LIBCPP_HAS_NO_GETS has disappeared * Instead, add direct major __FreeBSD__ check for using ::gets declaration * Mark EINTEGRITY values as FreeBSD customization * Reformat _LIBCPP_TYPE_VISIBILITY_DEFAULT customization PR: 276104 MFC after: 1 month (cherry picked from commit 46c59ea9b61755455ff6bf9f3e7b834e1af634ea) --- contrib/llvm-project/libcxx/include/__config | 8 ++------ contrib/llvm-project/libcxx/include/__system_error/errc.h | 4 ++-- contrib/llvm-project/libcxx/include/cstdio | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index ce4cece198b1..9154be8d8577 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -486,10 +486,6 @@ _LIBCPP_HARDENING_MODE_DEBUG # include // for __NATIVE_ASCII_F # endif -# ifdef __FreeBSD__ -# include // for __FreeBSD_version -# endif - # ifndef __BYTE_ORDER__ # error \ "Your compiler doesn't seem to define __BYTE_ORDER__, which is required by libc++ to know the endianness of your target platform" @@ -734,8 +730,8 @@ typedef __char32_t char32_t; # define _LIBCPP_TEMPLATE_VIS # endif -# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) \ - && _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization +# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) && \ + _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization # define _LIBCPP_TYPE_VISIBILITY_DEFAULT __attribute__((__type_visibility__("default"))) # else # define _LIBCPP_TYPE_VISIBILITY_DEFAULT diff --git a/contrib/llvm-project/libcxx/include/__system_error/errc.h b/contrib/llvm-project/libcxx/include/__system_error/errc.h index a14ec56070c4..b0cdacc5ec1d 100644 --- a/contrib/llvm-project/libcxx/include/__system_error/errc.h +++ b/contrib/llvm-project/libcxx/include/__system_error/errc.h @@ -45,7 +45,7 @@ enum class errc identifier_removed, // EIDRM illegal_byte_sequence, // EILSEQ inappropriate_io_control_operation, // ENOTTY - integrity_check_failed, // EINTEGRITY + integrity_check_failed, // EINTEGRITY // FreeBSD customization interrupted, // EINTR invalid_argument, // EINVAL invalid_seek, // ESPIPE @@ -143,7 +143,7 @@ _LIBCPP_DECLARE_STRONG_ENUM(errc){ illegal_byte_sequence = EILSEQ, inappropriate_io_control_operation = ENOTTY, #ifdef EINTEGRITY - integrity_check_failed = EINTEGRITY, + integrity_check_failed = EINTEGRITY, // FreeBSD customization #endif interrupted = EINTR, invalid_argument = EINVAL, diff --git a/contrib/llvm-project/libcxx/include/cstdio b/contrib/llvm-project/libcxx/include/cstdio index 0a867cec1a38..383655036d5f 100644 --- a/contrib/llvm-project/libcxx/include/cstdio +++ b/contrib/llvm-project/libcxx/include/cstdio @@ -159,7 +159,7 @@ using ::tmpfile _LIBCPP_USING_IF_EXISTS; using ::tmpnam _LIBCPP_USING_IF_EXISTS; using ::getchar _LIBCPP_USING_IF_EXISTS; -#if _LIBCPP_STD_VER <= 11 +#if _LIBCPP_STD_VER <= 11 && !(defined(__FreeBSD__) && __FreeBSD__ >= 13) // FreeBSD customization using ::gets _LIBCPP_USING_IF_EXISTS; #endif using ::scanf _LIBCPP_USING_IF_EXISTS; From nobody Sat Apr 20 10:32:19 2024 X-Original-To: dev-commits-src-branches@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 4VM79v6p4Tz5HWK0; Sat, 20 Apr 2024 10:32:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM79v5qs5z4PcZ; Sat, 20 Apr 2024 10:32:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609139; 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=Ynn/IuNPQj1cbR1Gu1Zihi2zo8fKOlsRXVE67Xr606U=; b=uomPrEUZv+StvJDFGQhTHUar6+84Vjg09c8n5vrFpL2cv25C0X3F7LBps96RzIF/9CuIH6 A2k/0fzWbwkfcMWUJtsyrrxnfGs5Vz3fD4z0I2eXPFoh2lguZ25BZWTxMo6q+yeRHzs10j sP2KgvTQjMd1RL14UgV0diybE/7srnchdFLRRRHJlJKbTMvVVzwsmLsp+7/FlmEg229DhW neINgODTZ11stHli4fRMVXid52MBi4rP88TtHT3EJd1xRTTelWk70yBVtzOu+IXUSkA2vz MZkW21+ROERRh/TK3gA5NhAPug/p9WAqwsLE1KPRAHk4WVfwnzbCdIREGk28/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609139; a=rsa-sha256; cv=none; b=pcL/IvvRBgRvdqO2FKB3oJRA7PuRvV889ObaUXb/DySX/FczvxCXh6YVFSMeJUZl+rzi3H XF/B1Rpgn+wuBRZ75y4AhizI6xC2kf5j6iwGliT5/IPYwIXfBKiedUv3zVuiwhyT9jLZFL 4Bij3d5QOc8yWupoMg1dWNkYDqzlh0t2IFbXYRKidRWybouzXK+bVvBS40v67FeRyccLE+ DWOv7mZLg7YVyNPAQbdO0aVEqKlCsrhvlBTYvAX56wrxVV//4JY8UY1qQtWHWYZumxlJNm KGtJUJuuvtx5bw1qpsdzyX4p30VY9aSygOcVe2yGiv/xTJMX29I888H55lOHlg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609139; 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=Ynn/IuNPQj1cbR1Gu1Zihi2zo8fKOlsRXVE67Xr606U=; b=Jo+bbhJKluilhUYTL+76keUOkLgvMV7qIPv0XN+XwTlRo43RZuNR6lJhzJQ1b8aDUvajZI fWASMnMWvVkXDVW3eTwoK4aj6drsJWUJ//G7WmN7vi3TbgLzOzFfuVG3aju6YjDU7qnbKk c4GJajPgUMWsJWqPOustQclbGUqcgpP1qVoVLq8xaDXrvfdaQWSzU/qkZyM1m0byEkr/Qc KbwgWqCHtRqeWrCqJWgzMJYG8HFpKiHa8CMLCpgg9ssbfggf07ya9C6HG8zwIo7pWGBA4X QrpGshdNYOImX2W1A2IHlX58wfQQWYgpSGsrF7avgJzJr+k0ba8OH3KLKiQQkg== 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 4VM79v4y8gzYm5; Sat, 20 Apr 2024 10:32:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWJ6k009655; Sat, 20 Apr 2024 10:32:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWJ5j009652; Sat, 20 Apr 2024 10:32:19 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:19 GMT Message-Id: <202404201032.43KAWJ5j009652@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: 6c20abcd5625 - stable/14 - Merge llvm-project main llvmorg-18-init-16864-g3b3ee1f53424 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 6c20abcd5625af907434441af2abcf626ab4c18b Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=6c20abcd5625af907434441af2abcf626ab4c18b commit 6c20abcd5625af907434441af2abcf626ab4c18b Author: Dimitry Andric AuthorDate: 2024-01-11 18:29:01 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:12 +0000 Merge llvm-project main llvmorg-18-init-16864-g3b3ee1f53424 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16864-g3b3ee1f53424. PR: 276104 MFC after: 1 month (cherry picked from commit 297eecfb02bb25902531dbb5c3b9a88caf8adf29) --- .../clang/include/clang/AST/DeclBase.h | 10 + .../llvm-project/clang/include/clang/AST/DeclCXX.h | 3 + .../llvm-project/clang/include/clang/AST/Stmt.h | 6 +- .../llvm-project/clang/include/clang/AST/Type.h | 3 + .../llvm-project/clang/include/clang/Basic/Attr.td | 18 + .../clang/include/clang/Basic/AttrDocs.td | 78 +++ .../include/clang/Basic/DiagnosticFrontendKinds.td | 2 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 15 + .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Basic/TargetInfo.h | 1 + .../clang/include/clang/Basic/arm_sve.td | 22 +- .../clang/include/clang/Driver/Options.td | 18 +- .../clang/include/clang/Format/Format.h | 20 +- .../clang/include/clang/Parse/Parser.h | 24 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 3 + .../clang/include/clang/Sema/TypoCorrection.h | 12 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 7 + contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 37 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 74 ++- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 13 + contrib/llvm-project/clang/lib/AST/Expr.cpp | 83 +--- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 7 + .../clang/lib/AST/Interp/Descriptor.cpp | 6 +- .../llvm-project/clang/lib/AST/Interp/Descriptor.h | 7 +- .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 12 + .../clang/lib/AST/Interp/InterpBuiltin.cpp | 33 +- .../llvm-project/clang/lib/AST/Interp/Program.cpp | 16 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 34 +- .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 355 +++++++------- .../clang/lib/Basic/Targets/AArch64.cpp | 7 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 5 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 244 +++++++++- contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 2 + .../llvm-project/clang/lib/CodeGen/CGException.cpp | 7 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 340 +++++++++++++- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 35 +- .../clang/lib/CodeGen/CodeGenFunction.h | 22 + .../clang/lib/CodeGen/CodeGenModule.cpp | 2 + .../clang/lib/CodeGen/CoverageMappingGen.cpp | 13 +- .../clang/lib/CodeGen/Targets/AArch64.cpp | 2 + .../clang/lib/Driver/ToolChains/Clang.cpp | 6 +- .../clang/lib/Driver/ToolChains/Flang.cpp | 57 ++- .../clang/lib/Driver/ToolChains/Flang.h | 7 + .../clang/lib/Driver/ToolChains/Gnu.cpp | 8 +- .../clang/lib/Driver/ToolChains/Linux.cpp | 8 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 30 +- .../llvm-project/clang/lib/Format/FormatToken.cpp | 4 +- .../llvm-project/clang/lib/Format/FormatToken.h | 25 +- .../clang/lib/Format/TokenAnnotator.cpp | 14 +- .../clang/lib/Format/UnwrappedLineFormatter.cpp | 10 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 4 +- .../clang/lib/Format/WhitespaceManager.cpp | 9 +- .../clang/lib/Format/WhitespaceManager.h | 1 + .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 15 +- .../llvm-project/clang/lib/Headers/ia32intrin.h | 376 +++++++-------- .../clang/lib/Interpreter/Interpreter.cpp | 1 + contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 8 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 26 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 65 +-- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 6 + .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 133 ++++++ contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 3 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 10 + contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 2 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 20 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 21 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 59 ++- .../clang/tools/clang-format/ClangFormat.cpp | 65 ++- .../compiler-rt/include/profile/InstrProfData.inc | 2 + .../lib/profile/InstrProfilingPlatformLinux.c | 9 - .../lib/sanitizer_common/sanitizer_flags.inc | 3 + .../sanitizer_symbolizer_report.cpp | 36 +- .../sanitizer_thread_arg_retval.cpp | 23 +- .../sanitizer_common/sanitizer_thread_arg_retval.h | 1 + .../lib/scudo/standalone/condition_variable.h | 2 +- contrib/llvm-project/libcxx/include/__config | 5 - .../libcxx/include/__memory/shared_ptr.h | 4 +- contrib/llvm-project/libcxx/include/cstdio | 2 +- contrib/llvm-project/libcxx/include/regex | 3 + contrib/llvm-project/libcxx/include/tuple | 2 +- contrib/llvm-project/lld/ELF/Arch/AArch64.cpp | 3 + contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 110 ++--- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 7 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 10 +- contrib/llvm-project/lld/ELF/Target.h | 2 +- .../llvm-project/lldb/include/lldb/Core/Module.h | 6 + .../llvm-project/lldb/include/lldb/Symbol/Type.h | 4 + .../lldb/include/lldb/Utility/StreamString.h | 2 +- contrib/llvm-project/lldb/source/Core/Module.cpp | 17 + .../ExpressionParser/Clang/ClangASTImporter.cpp | 51 +- .../Language/CPlusPlus/CPlusPlusLanguage.cpp | 35 ++ .../source/Plugins/Language/CPlusPlus/LibCxx.cpp | 57 +++ .../source/Plugins/Language/CPlusPlus/LibCxx.h | 8 + .../source/Plugins/SymbolFile/DWARF/DWARFDIE.cpp | 44 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 11 +- .../intel-pt/CommandObjectTraceStartIntelPT.cpp | 4 +- .../Plugins/Trace/intel-pt/DecodedThread.cpp | 32 +- .../source/Plugins/Trace/intel-pt/DecodedThread.h | 26 +- .../Plugins/Trace/intel-pt/LibiptDecoder.cpp | 4 +- .../Plugins/Trace/intel-pt/TraceCursorIntelPT.cpp | 4 +- .../Trace/intel-pt/TraceIntelPTBundleLoader.cpp | 13 +- contrib/llvm-project/lldb/source/Symbol/Type.cpp | 4 + .../lldb/source/Target/ProcessTrace.cpp | 2 + .../lldb/source/Utility/StreamString.cpp | 2 +- .../llvm-project/llvm/include/llvm/ADT/STLExtras.h | 29 +- .../llvm-project/llvm/include/llvm/ADT/StringRef.h | 4 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 190 ++++---- .../llvm/BinaryFormat/ELFRelocs/AArch64.def | 1 + .../include/llvm/BinaryFormat/ELFRelocs/RISCV.def | 3 +- .../llvm/CodeGen/AssignmentTrackingAnalysis.h | 29 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 1 + .../llvm/CodeGen/GlobalISel/CombinerHelper.h | 3 + .../llvm/CodeGen/GlobalISel/GenericMachineInstrs.h | 18 + .../include/llvm/CodeGen/GlobalISel/Localizer.h | 7 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 16 + .../llvm/include/llvm/CodeGen/SelectionDAGNodes.h | 7 + .../Parallel => include/llvm/DWARFLinker}/Utils.h | 36 +- .../llvm/include/llvm/Frontend/OpenACC/ACC.td | 66 +-- .../llvm/include/llvm/IR/IntrinsicsAArch64.td | 6 +- .../llvm/include/llvm/IR/IntrinsicsNVVM.td | 10 + .../llvm/include/llvm/IR/ModuleSummaryIndex.h | 6 + .../llvm/include/llvm/IR/PatternMatch.h | 36 ++ .../llvm/include/llvm/ProfileData/InstrProf.h | 3 +- .../include/llvm/ProfileData/InstrProfData.inc | 2 + .../llvm/include/llvm/Support/RISCVISAInfo.h | 22 +- .../llvm/include/llvm/Support/TargetOpcodes.def | 3 + .../llvm/include/llvm/Target/GenericOpcodes.td | 21 + .../llvm/Target/GlobalISel/SelectionDAGCompat.td | 3 + .../llvm/include/llvm/Target/TargetPfmCounters.td | 21 + .../llvm/TargetParser/ARMTargetParserCommon.h | 1 + .../llvm/lib/Analysis/LazyValueInfo.cpp | 8 +- .../llvm/lib/Bitcode/Writer/BitcodeWriter.cpp | 17 +- .../lib/CodeGen/AssignmentTrackingAnalysis.cpp | 34 ++ .../llvm/lib/CodeGen/BranchFolding.cpp | 17 + .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 84 ++++ .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 12 + .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 10 + .../llvm/lib/CodeGen/GlobalISel/Localizer.cpp | 55 ++- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 9 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 74 +-- .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 2 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 12 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 48 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 5 +- .../lib/CodeGen/TargetLoweringObjectFileImpl.cpp | 11 +- .../llvm/lib/DWARFLinker/Classic/DWARFLinker.cpp | 15 +- .../Parallel/AcceleratorRecordsSaver.cpp | 2 +- .../Parallel/DWARFLinkerCompileUnit.cpp | 23 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.cpp | 2 +- .../DWARFLinker/Parallel/DebugLineSectionEmitter.h | 38 +- .../llvm-project/llvm/lib/DWARFLinker/Utils.cpp | 2 + contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 11 + .../llvm/lib/MC/MCParser/ELFAsmParser.cpp | 6 +- contrib/llvm-project/llvm/lib/MC/MCSectionELF.cpp | 18 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassRegistry.def | 4 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 331 +++++++------ contrib/llvm-project/llvm/lib/TableGen/Record.cpp | 15 +- .../llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp | 5 + .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 4 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 3 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 3 + .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 64 ++- .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 2 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 18 +- .../Target/AArch64/AArch64TargetTransformInfo.cpp | 98 ++-- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 3 +- .../MCTargetDesc/AArch64ELFObjectWriter.cpp | 8 +- .../llvm/lib/Target/AArch64/SMEInstrFormats.td | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUCombine.td | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 12 +- .../lib/Target/AMDGPU/AMDGPULowerModuleLDSPass.cpp | 52 ++ .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 46 +- .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 43 +- .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 17 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 2 + .../Target/AMDGPU/MCTargetDesc/AMDGPUMCAsmInfo.cpp | 1 - .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 8 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 5 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 33 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 33 +- .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 55 ++- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 14 +- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 13 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 9 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 13 +- .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 6 +- .../llvm/lib/Target/NVPTX/NVPTXInstrInfo.td | 3 + .../llvm/lib/Target/NVPTX/NVPTXIntrinsics.td | 13 + .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 2 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.td | 2 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 77 ++- .../RISCV/Disassembler/RISCVDisassembler.cpp | 6 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 40 ++ .../RISCV/MCTargetDesc/RISCVELFObjectWriter.cpp | 2 + .../Target/RISCV/MCTargetDesc/RISCVELFStreamer.cpp | 7 + .../lib/Target/RISCV/RISCVExpandPseudoInsts.cpp | 12 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 1 + .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 46 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 6 +- .../llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp | 37 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 17 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoA.td | 140 +++--- .../llvm/lib/Target/RISCV/RISCVInstrInfoD.td | 16 +- .../lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td | 33 +- .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 38 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZa.td | 98 +++- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 45 +- .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 2 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 7 + .../lib/Target/WebAssembly/WebAssemblyFastISel.cpp | 4 +- .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 16 + .../llvm/lib/Target/X86/X86FlagsCopyLowering.cpp | 1 + .../llvm/lib/Target/X86/X86ISelLowering.cpp | 53 ++- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 110 +++-- .../llvm/lib/Target/X86/X86InstrCompiler.td | 380 ++++++++------- .../llvm/lib/Target/X86/X86InstrMisc.td | 12 +- .../llvm/lib/Target/X86/X86PfmCounters.td | 18 + .../lib/TargetParser/ARMTargetParserCommon.cpp | 7 +- .../llvm/lib/TextAPI/InterfaceFile.cpp | 8 + .../IPO/MemProfContextDisambiguation.cpp | 521 ++++++++++++++++++--- .../Transforms/InstCombine/InstCombineAddSub.cpp | 24 + .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 114 +++-- .../Transforms/InstCombine/InstCombineCalls.cpp | 4 + .../Transforms/InstCombine/InstCombineSelect.cpp | 4 +- .../Instrumentation/AddressSanitizer.cpp | 2 +- .../Instrumentation/PGOInstrumentation.cpp | 12 +- .../llvm/lib/Transforms/Scalar/LoopFlatten.cpp | 79 ++-- .../Transforms/Scalar/RewriteStatepointsForGC.cpp | 23 +- .../Scalar/SeparateConstOffsetFromGEP.cpp | 58 +-- .../Scalar/StraightLineStrengthReduce.cpp | 55 +-- .../llvm/lib/Transforms/Utils/Local.cpp | 3 +- .../llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 13 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 6 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 69 ++- .../llvm/utils/TableGen/CodeGenDAGPatterns.cpp | 2 +- .../llvm/utils/TableGen/DAGISelMatcherEmitter.cpp | 81 +++- .../llvm/utils/TableGen/ExegesisEmitter.cpp | 52 +- .../utils/TableGen/GlobalISelCombinerEmitter.cpp | 2 +- .../openmp/runtime/src/z_Linux_util.cpp | 2 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 32 +- lib/libc++/Makefile | 40 +- lib/libc++/module.modulemap | 4 +- 247 files changed, 5252 insertions(+), 2361 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h index 10dcbdb262d8..5b1038582bc6 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h @@ -19,6 +19,7 @@ #include "clang/AST/SelectorLocationsKind.h" #include "clang/Basic/IdentifierTable.h" #include "clang/Basic/LLVM.h" +#include "clang/Basic/LangOptions.h" #include "clang/Basic/SourceLocation.h" #include "clang/Basic/Specifiers.h" #include "llvm/ADT/ArrayRef.h" @@ -488,6 +489,15 @@ public: // Return true if this is a FileContext Decl. bool isFileContextDecl() const; + /// Whether it resembles a flexible array member. This is a static member + /// because we want to be able to call it with a nullptr. That allows us to + /// perform non-Decl specific checks based on the object's type and strict + /// flex array level. + static bool isFlexibleArrayMemberLike( + ASTContext &Context, const Decl *D, QualType Ty, + LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel, + bool IgnoreTemplateOrMacroSubstitution); + ASTContext &getASTContext() const LLVM_READONLY; /// Helper to get the language options from the ASTContext. diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h index 984a4d8bab5e..648f5f946408 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h @@ -1425,6 +1425,9 @@ public: /// (C++11 [class]p6). bool isTriviallyCopyable() const; + /// Determine whether this class is considered trivially copyable per + bool isTriviallyCopyConstructible() const; + /// Determine whether this class is considered trivial. /// /// C++11 [class]p6: diff --git a/contrib/llvm-project/clang/include/clang/AST/Stmt.h b/contrib/llvm-project/clang/include/clang/AST/Stmt.h index da7b37ce0e12..e1fde24e6477 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Stmt.h +++ b/contrib/llvm-project/clang/include/clang/AST/Stmt.h @@ -1631,8 +1631,10 @@ public: SourceLocation RB); // Build an empty compound statement with a location. - explicit CompoundStmt(SourceLocation Loc) - : Stmt(CompoundStmtClass), LBraceLoc(Loc), RBraceLoc(Loc) { + explicit CompoundStmt(SourceLocation Loc) : CompoundStmt(Loc, Loc) {} + + CompoundStmt(SourceLocation Loc, SourceLocation EndLoc) + : Stmt(CompoundStmtClass), LBraceLoc(Loc), RBraceLoc(EndLoc) { CompoundStmtBits.NumStmts = 0; CompoundStmtBits.HasFPFeatures = 0; } diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index 9e9f896ebef7..d4e5310fb3ab 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -917,6 +917,9 @@ public: /// Return true if this is a trivially copyable type (C++0x [basic.types]p9) bool isTriviallyCopyableType(const ASTContext &Context) const; + /// Return true if this is a trivially copyable type + bool isTriviallyCopyConstructibleType(const ASTContext &Context) const; + /// Return true if this is a trivially relocatable type. bool isTriviallyRelocatableType(const ASTContext &Context) const; diff --git a/contrib/llvm-project/clang/include/clang/Basic/Attr.td b/contrib/llvm-project/clang/include/clang/Basic/Attr.td index d5eabaad4889..a03b0e44e15f 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/Attr.td +++ b/contrib/llvm-project/clang/include/clang/Basic/Attr.td @@ -4372,3 +4372,21 @@ def CodeAlign: StmtAttr { static constexpr int MaximumAlignment = 4096; }]; } + +def CountedBy : InheritableAttr { + let Spellings = [Clang<"counted_by">]; + let Subjects = SubjectList<[Field]>; + let Args = [IdentifierArgument<"CountedByField">]; + let Documentation = [CountedByDocs]; + let LangOpts = [COnly]; + // FIXME: This is ugly. Let using a DeclArgument would be nice, but a Decl + // isn't yet available due to the fact that we're still parsing the + // structure. Maybe that code could be changed sometime in the future. + code AdditionalMembers = [{ + private: + SourceRange CountedByFieldLoc; + public: + SourceRange getCountedByFieldLoc() const { return CountedByFieldLoc; } + void setCountedByFieldLoc(SourceRange Loc) { CountedByFieldLoc = Loc; } + }]; +} diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 5416a0cbdd07..2e8d7752c975 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -7749,3 +7749,81 @@ but do not pass them to the underlying coroutine or pass them by value. .. _`CRT`: https://clang.llvm.org/docs/AttributeReference.html#coro-return-type }]; } + +def CountedByDocs : Documentation { + let Category = DocCatField; + let Content = [{ +Clang supports the ``counted_by`` attribute on the flexible array member of a +structure in C. The argument for the attribute is the name of a field member +holding the count of elements in the flexible array. This information can be +used to improve the results of the array bound sanitizer and the +``__builtin_dynamic_object_size`` builtin. The ``count`` field member must be +within the same non-anonymous, enclosing struct as the flexible array member. + +This example specifies that the flexible array member ``array`` has the number +of elements allocated for it in ``count``: + +.. code-block:: c + + struct bar; + + struct foo { + size_t count; + char other; + struct bar *array[] __attribute__((counted_by(count))); + }; + +This establishes a relationship between ``array`` and ``count``. Specifically, +``array`` must have at least ``count`` number of elements available. It's the +user's responsibility to ensure that this relationship is maintained through +changes to the structure. + +In the following example, the allocated array erroneously has fewer elements +than what's specified by ``p->count``. This would result in an out-of-bounds +access not being detected. + +.. code-block:: c + + #define SIZE_INCR 42 + + struct foo *p; + + void foo_alloc(size_t count) { + p = malloc(MAX(sizeof(struct foo), + offsetof(struct foo, array[0]) + count * sizeof(struct bar *))); + p->count = count + SIZE_INCR; + } + +The next example updates ``p->count``, but breaks the relationship requirement +that ``p->array`` must have at least ``p->count`` number of elements available: + +.. code-block:: c + + #define SIZE_INCR 42 + + struct foo *p; + + void foo_alloc(size_t count) { + p = malloc(MAX(sizeof(struct foo), + offsetof(struct foo, array[0]) + count * sizeof(struct bar *))); + p->count = count; + } + + void use_foo(int index, int val) { + p->count += SIZE_INCR + 1; /* 'count' is now larger than the number of elements of 'array'. */ + p->array[index] = val; /* The sanitizer can't properly check this access. */ + } + +In this example, an update to ``p->count`` maintains the relationship +requirement: + +.. code-block:: c + + void use_foo(int index, int val) { + if (p->count == 0) + return; + --p->count; + p->array[index] = val; + } + }]; +} diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td index 568000106a84..85ecfdf9de62 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td @@ -167,7 +167,7 @@ def err_verify_no_such_marker : Error< def err_verify_missing_start : Error< "cannot find start ('{{') of expected %0">; def err_verify_missing_end : Error< - "cannot find end ('}}') of expected %0">; + "cannot find end ('%1') of expected %0">; def err_verify_invalid_content : Error< "invalid expected %0: %1">; def err_verify_missing_regex : Error< diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index e81d1a4fc288..e46779349475 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -2253,6 +2253,8 @@ def warn_cxx17_compat_aggregate_init_paren_list : Warning< def err_reference_bind_to_bitfield : Error< "%select{non-const|volatile}0 reference cannot bind to " "bit-field%select{| %1}2">; +def err_reference_bind_to_bitfield_in_cce : Error< + "reference cannot bind to bit-field in converted constant expression">; def err_reference_bind_to_vector_element : Error< "%select{non-const|volatile}0 reference cannot bind to vector element">; def err_reference_bind_to_matrix_element : Error< @@ -6439,6 +6441,19 @@ def warn_superclass_variable_sized_type_not_at_end : Warning< "field %0 can overwrite instance variable %1 with variable sized type %2" " in superclass %3">, InGroup; +def err_flexible_array_count_not_in_same_struct : Error< + "'counted_by' field %0 isn't within the same struct as the flexible array">; +def err_counted_by_attr_not_on_flexible_array_member : Error< + "'counted_by' only applies to C99 flexible array members">; +def err_counted_by_attr_refers_to_flexible_array : Error< + "'counted_by' cannot refer to the flexible array %0">; +def err_counted_by_must_be_in_structure : Error< + "field %0 in 'counted_by' not inside structure">; +def err_flexible_array_counted_by_attr_field_not_integer : Error< + "field %0 in 'counted_by' must be a non-boolean integer type">; +def note_flexible_array_counted_by_attr_field : Note< + "field %0 declared here">; + let CategoryName = "ARC Semantic Issue" in { // ARC-mode diagnostics. diff --git a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def index 21abc346cf17..0428b70c6020 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def @@ -457,6 +457,7 @@ ENUM_LANGOPT(SignReturnAddressKey, SignReturnAddressKeyKind, 1, SignReturnAddres "Key used for return address signing") LANGOPT(BranchTargetEnforcement, 1, 0, "Branch-target enforcement enabled") LANGOPT(BranchProtectionPAuthLR, 1, 0, "Use PC as a diversifier using PAuthLR NOP instructions.") +LANGOPT(GuardedControlStack, 1, 0, "Guarded control stack enabled") LANGOPT(SpeculativeLoadHardening, 1, 0, "Speculative load hardening enabled") diff --git a/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h b/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h index ac3c324c6c29..3eb23ebdacf0 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h +++ b/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h @@ -1373,6 +1373,7 @@ public: LangOptions::SignReturnAddressKeyKind::AKey; bool BranchTargetEnforcement = false; bool BranchProtectionPAuthLR = false; + bool GuardedControlStack = false; }; /// Determine if the Architecture in this TargetInfo supports branch diff --git a/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td b/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td index 7f80fb0386cc..6f35e25617ad 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td +++ b/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td @@ -454,11 +454,11 @@ let TargetGuard = "sve,bf16" in { let TargetGuard = "sve2p1" in { // Contiguous truncating store from quadword (single vector). - def SVST1UWQ : MInst<"svst1uwq[_{d}]", "vPcd", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1uwq">; - def SVST1UWQ_VNUM : MInst<"svst1uwq_vnum[_{d}]", "vPcld", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1uwq">; + def SVST1UWQ : MInst<"svst1wq[_{d}]", "vPcd", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1wq">; + def SVST1UWQ_VNUM : MInst<"svst1wq_vnum[_{d}]", "vPcld", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1wq">; - def SVST1UDQ : MInst<"svst1udq[_{d}]", "vPcd", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1udq">; - def SVST1UDQ_VNUM : MInst<"svst1udq_vnum[_{d}]", "vPcld", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1udq">; + def SVST1UDQ : MInst<"svst1dq[_{d}]", "vPcd", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1dq">; + def SVST1UDQ_VNUM : MInst<"svst1dq_vnum[_{d}]", "vPcld", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1dq">; // Store one vector (vector base + scalar offset) def SVST1Q_SCATTER_U64BASE_OFFSET : MInst<"svst1q_scatter[_{2}base]_offset[_{d}]", "vPgld", "cUcsUsiUilUlfhdb", [IsScatterStore, IsByteIndexed], MemEltTyDefault, "aarch64_sve_st1q_scatter_scalar_offset">; @@ -2040,12 +2040,12 @@ let TargetGuard = "sve2p1|sme2" in { } let TargetGuard = "sve2p1" in { -def SVDOT_X2_S : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "i", MergeNone, "aarch64_sve_sdot_x2", [], []>; -def SVDOT_X2_U : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "Ui", MergeNone, "aarch64_sve_udot_x2", [], []>; -def SVDOT_X2_F : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "f", MergeNone, "aarch64_sve_fdot_x2", [], []>; -def SVDOT_LANE_X2_S : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "i", MergeNone, "aarch64_sve_sdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; -def SVDOT_LANE_X2_U : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "Ui", MergeNone, "aarch64_sve_udot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; -def SVDOT_LANE_X2_F : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "f", MergeNone, "aarch64_sve_fdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_X2_S : SInst<"svdot[_{d}_{2}]", "ddhh", "i", MergeNone, "aarch64_sve_sdot_x2", [], []>; +def SVDOT_X2_U : SInst<"svdot[_{d}_{2}]", "ddhh", "Ui", MergeNone, "aarch64_sve_udot_x2", [], []>; +def SVDOT_X2_F : SInst<"svdot[_{d}_{2}]", "ddhh", "f", MergeNone, "aarch64_sve_fdot_x2", [], []>; +def SVDOT_LANE_X2_S : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "i", MergeNone, "aarch64_sve_sdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_LANE_X2_U : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "Ui", MergeNone, "aarch64_sve_udot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_LANE_X2_F : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "f", MergeNone, "aarch64_sve_fdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; } let TargetGuard = "sve2p1|sme2" in { @@ -2208,7 +2208,7 @@ let TargetGuard = "sve2p1" in { def SVTBLQ : SInst<"svtblq[_{d}]", "ddu", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_tblq">; def SVTBXQ : SInst<"svtbxq[_{d}]", "dddu", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_tbxq">; // EXTQ - def EXTQ : SInst<"svextq_lane[_{d}]", "dddk", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_extq_lane", [], [ImmCheck<2, ImmCheck0_15>]>; + def EXTQ : SInst<"svextq[_{d}]", "dddk", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_extq", [], [ImmCheck<2, ImmCheck0_15>]>; // PMOV // Move to Pred multiclass PMOV_TO_PRED flags=[], ImmCheckType immCh > { diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index 84648c6d5500..7f97d6b6faa3 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -4267,7 +4267,7 @@ def iquote : JoinedOrSeparate<["-"], "iquote">, Group, Visibility<[ClangOption, CC1Option]>, HelpText<"Add directory to QUOTE include search path">, MetaVarName<"">; def isysroot : JoinedOrSeparate<["-"], "isysroot">, Group, - Visibility<[ClangOption, CC1Option]>, + Visibility<[ClangOption, CC1Option, FlangOption]>, HelpText<"Set the system root directory (usually /)">, MetaVarName<"">, MarshallingInfoString, [{"/"}]>; def isystem : JoinedOrSeparate<["-"], "isystem">, Group, @@ -4585,11 +4585,13 @@ let Flags = [TargetSpecific] in { def menable_experimental_extensions : Flag<["-"], "menable-experimental-extensions">, Group, HelpText<"Enable use of experimental RISC-V extensions.">; def mrvv_vector_bits_EQ : Joined<["-"], "mrvv-vector-bits=">, Group, - HelpText<"Specify the size in bits of an RVV vector register. Defaults to " - "the vector length agnostic value of \"scalable\". Accepts power of " - "2 values between 64 and 65536. Also accepts \"zvl\" " - "to use the value implied by -march/-mcpu. Value will be reflected " - "in __riscv_v_fixed_vlen preprocessor define (RISC-V only)">; + Visibility<[ClangOption, FlangOption]>, + HelpText<"Specify the size in bits of an RVV vector register">, + DocBrief<"Defaults to the vector length agnostic value of \"scalable\". " + "Accepts power of 2 values between 64 and 65536. Also accepts " + "\"zvl\" to use the value implied by -march/-mcpu. On Clang, value " + "will be reflected in __riscv_v_fixed_vlen preprocessor define " + "(RISC-V only)">; def munaligned_access : Flag<["-"], "munaligned-access">, Group, HelpText<"Allow memory accesses to be unaligned (AArch32/AArch64/LoongArch/RISC-V only)">; @@ -5197,7 +5199,7 @@ def nohipwrapperinc : Flag<["-"], "nohipwrapperinc">, Group, HelpText<"Do not include the default HIP wrapper headers and include paths">; def : Flag<["-"], "nocudainc">, Alias; def nogpulib : Flag<["-"], "nogpulib">, MarshallingInfoFlag>, - Visibility<[ClangOption, CC1Option]>, + Visibility<[ClangOption, CC1Option, FlangOption, FC1Option]>, HelpText<"Do not link device library for CUDA/HIP device compilation">; def : Flag<["-"], "nocudalib">, Alias; def gpulibc : Flag<["-"], "gpulibc">, Visibility<[ClangOption, CC1Option, FlangOption, FC1Option]>, @@ -7010,6 +7012,8 @@ def mbranch_target_enforce : Flag<["-"], "mbranch-target-enforce">, MarshallingInfoFlag>; def mbranch_protection_pauth_lr : Flag<["-"], "mbranch-protection-pauth-lr">, MarshallingInfoFlag>; +def mguarded_control_stack : Flag<["-"], "mguarded-control-stack">, + MarshallingInfoFlag>; def fno_dllexport_inlines : Flag<["-"], "fno-dllexport-inlines">, MarshallingInfoNegativeFlag>; def cfguard_no_checks : Flag<["-"], "cfguard-no-checks">, diff --git a/contrib/llvm-project/clang/include/clang/Format/Format.h b/contrib/llvm-project/clang/include/clang/Format/Format.h index 8604dea689f9..59b645ecab71 100755 --- a/contrib/llvm-project/clang/include/clang/Format/Format.h +++ b/contrib/llvm-project/clang/include/clang/Format/Format.h @@ -225,6 +225,22 @@ struct FormatStyle { /// bbb = 2; /// \endcode bool AlignCompound; + /// Only for ``AlignConsecutiveDeclarations``. Whether function pointers are + /// aligned. + /// \code + /// true: + /// unsigned i; + /// int &r; + /// int *p; + /// int (*f)(); + /// + /// false: + /// unsigned i; + /// int &r; + /// int *p; + /// int (*f)(); + /// \endcode + bool AlignFunctionPointers; /// Only for ``AlignConsecutiveAssignments``. Whether short assignment /// operators are left-padded to the same length as long ones in order to /// put all assignment operators to the right of the left hand side. @@ -247,7 +263,9 @@ struct FormatStyle { bool operator==(const AlignConsecutiveStyle &R) const { return Enabled == R.Enabled && AcrossEmptyLines == R.AcrossEmptyLines && AcrossComments == R.AcrossComments && - AlignCompound == R.AlignCompound && PadOperators == R.PadOperators; + AlignCompound == R.AlignCompound && + AlignFunctionPointers == R.AlignFunctionPointers && + PadOperators == R.PadOperators; } bool operator!=(const AlignConsecutiveStyle &R) const { return !(*this == R); diff --git a/contrib/llvm-project/clang/include/clang/Parse/Parser.h b/contrib/llvm-project/clang/include/clang/Parse/Parser.h index 2dbe090bd093..186dbb770858 100644 --- a/contrib/llvm-project/clang/include/clang/Parse/Parser.h +++ b/contrib/llvm-project/clang/include/clang/Parse/Parser.h @@ -234,6 +234,26 @@ class Parser : public CodeCompletionHandler { /// Parsing OpenACC directive mode. bool OpenACCDirectiveParsing = false; + /// Currently parsing a situation where an OpenACC array section could be + /// legal, such as a 'var-list'. + bool AllowOpenACCArraySections = false; + + /// RAII object to set reset OpenACC parsing a context where Array Sections + /// are allowed. + class OpenACCArraySectionRAII { + Parser &P; + + public: + OpenACCArraySectionRAII(Parser &P) : P(P) { + assert(!P.AllowOpenACCArraySections); + P.AllowOpenACCArraySections = true; + } + ~OpenACCArraySectionRAII() { + assert(P.AllowOpenACCArraySections); + P.AllowOpenACCArraySections = false; + } + }; + /// When true, we are directly inside an Objective-C message /// send expression. /// @@ -3546,8 +3566,8 @@ private: ExprResult ParseOpenACCIDExpression(); /// Parses the variable list for the `cache` construct. void ParseOpenACCCacheVarList(); - /// Parses a single variable in a variable list for the 'cache' construct. - bool ParseOpenACCCacheVar(); + /// Parses a single variable in a variable list for OpenACC. + bool ParseOpenACCVar(); bool ParseOpenACCWaitArgument(); private: diff --git a/contrib/llvm-project/clang/include/clang/Sema/Sema.h b/contrib/llvm-project/clang/include/clang/Sema/Sema.h index edaee4c4b66d..cf2d4fbe6d3b 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Sema.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Sema.h @@ -4799,6 +4799,8 @@ public: bool CheckAlwaysInlineAttr(const Stmt *OrigSt, const Stmt *CurSt, const AttributeCommonInfo &A); + bool CheckCountedByAttr(Scope *Scope, const FieldDecl *FD); + /// Adjust the calling convention of a method to be the ABI default if it /// wasn't specified explicitly. This handles method types formed from /// function type typedefs and typename template arguments. @@ -5642,6 +5644,7 @@ public: CorrectionCandidateCallback &CCC, TemplateArgumentListInfo *ExplicitTemplateArgs = nullptr, ArrayRef Args = std::nullopt, + DeclContext *LookupCtx = nullptr, TypoExpr **Out = nullptr); DeclResult LookupIvarInObjCMethod(LookupResult &Lookup, Scope *S, diff --git a/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h b/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h index e0f8d152dbe5..09de164297e7 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h +++ b/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h @@ -282,7 +282,7 @@ class CorrectionCandidateCallback { public: static const unsigned InvalidDistance = TypoCorrection::InvalidDistance; - explicit CorrectionCandidateCallback(IdentifierInfo *Typo = nullptr, + explicit CorrectionCandidateCallback(const IdentifierInfo *Typo = nullptr, NestedNameSpecifier *TypoNNS = nullptr) : Typo(Typo), TypoNNS(TypoNNS) {} @@ -319,7 +319,7 @@ public: /// this method. virtual std::unique_ptr clone() = 0; - void setTypoName(IdentifierInfo *II) { Typo = II; } + void setTypoName(const IdentifierInfo *II) { Typo = II; } void setTypoNNS(NestedNameSpecifier *NNS) { TypoNNS = NNS; } // Flags for context-dependent keywords. WantFunctionLikeCasts is only @@ -345,13 +345,13 @@ protected: candidate.getCorrectionSpecifier() == TypoNNS; } - IdentifierInfo *Typo; + const IdentifierInfo *Typo; NestedNameSpecifier *TypoNNS; }; class DefaultFilterCCC final : public CorrectionCandidateCallback { public: - explicit DefaultFilterCCC(IdentifierInfo *Typo = nullptr, + explicit DefaultFilterCCC(const IdentifierInfo *Typo = nullptr, NestedNameSpecifier *TypoNNS = nullptr) : CorrectionCandidateCallback(Typo, TypoNNS) {} @@ -365,6 +365,10 @@ public: template class DeclFilterCCC final : public CorrectionCandidateCallback { public: + explicit DeclFilterCCC(const IdentifierInfo *Typo = nullptr, + NestedNameSpecifier *TypoNNS = nullptr) + : CorrectionCandidateCallback(Typo, TypoNNS) {} + bool ValidateCandidate(const TypoCorrection &candidate) override { return candidate.getCorrectionDeclAs(); } diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index b60dcfaabfd1..d9cefcaa84d7 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -1318,6 +1318,13 @@ void ASTContext::InitBuiltinTypes(const TargetInfo &Target, InitBuiltinType(OMPArrayShapingTy, BuiltinType::OMPArrayShaping); InitBuiltinType(OMPIteratorTy, BuiltinType::OMPIterator); } + // Placeholder type for OpenACC array sections. + if (LangOpts.OpenACC) { + // FIXME: Once we implement OpenACC array sections in Sema, this will either + // be combined with the OpenMP type, or given its own type. In the meantime, + // just use the OpenMP type so that parsing can work. + InitBuiltinType(OMPArraySectionTy, BuiltinType::OMPArraySection); + } if (LangOpts.MatrixTypes) InitBuiltinType(IncompleteMatrixIdxTy, BuiltinType::IncompleteMatrixIdx); diff --git a/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp b/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp index 5e5570bb42a1..b762d6a4cd38 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp @@ -5929,15 +5929,22 @@ ExpectedDecl ASTNodeImporter::VisitClassTemplateDecl(ClassTemplateDecl *D) { if (ToD) return ToD; - bool IsFriendTemplate = D->getFriendObjectKind() != Decl::FOK_None; - bool IsDependentContext = DC != LexicalDC ? LexicalDC->isDependentContext() - : DC->isDependentContext(); - bool DependentFriend = IsFriendTemplate && IsDependentContext; + // Should check if a declaration is friend in a dependent context. + // Such templates are not linked together in a declaration chain. + // The ASTImporter strategy is to map existing forward declarations to + // imported ones only if strictly necessary, otherwise import these as new + // forward declarations. In case of the "dependent friend" declarations, new + // declarations are created, but not linked in a declaration chain. + auto IsDependentFriend = [](ClassTemplateDecl *TD) { + return TD->getFriendObjectKind() != Decl::FOK_None && + TD->getLexicalDeclContext()->isDependentContext(); + }; + bool DependentFriend = IsDependentFriend(D); ClassTemplateDecl *FoundByLookup = nullptr; // We may already have a template of the same name; try to find and match it. - if (!DependentFriend && !DC->isFunctionOrMethod()) { + if (!DC->isFunctionOrMethod()) { SmallVector ConflictingDecls; auto FoundDecls = Importer.findDeclsInToCtx(DC, Name); for (auto *FoundDecl : FoundDecls) { @@ -5953,10 +5960,13 @@ ExpectedDecl ASTNodeImporter::VisitClassTemplateDecl(ClassTemplateDecl *D) { // FIXME: sufficient conditon for 'IgnoreTemplateParmDepth'? bool IgnoreTemplateParmDepth = - FoundTemplate->getFriendObjectKind() != Decl::FOK_None && - !D->specializations().empty(); + (FoundTemplate->getFriendObjectKind() != Decl::FOK_None) != + (D->getFriendObjectKind() != Decl::FOK_None); if (IsStructuralMatch(D, FoundTemplate, /*Complain=*/true, IgnoreTemplateParmDepth)) { + if (DependentFriend || IsDependentFriend(FoundTemplate)) + continue; + ClassTemplateDecl *TemplateWithDef = getTemplateDefinition(FoundTemplate); if (D->isThisDeclarationADefinition() && TemplateWithDef) @@ -9030,6 +9040,10 @@ class AttrImporter { public: AttrImporter(ASTImporter &I) : Importer(I), NImporter(I) {} + // Useful for accessing the imported attribute. + template T *castAttrAs() { return cast(ToAttr); } + template const T *castAttrAs() const { return cast(ToAttr); } + // Create an "importer" for an attribute parameter. // Result of the 'value()' of that object is to be passed to the function // 'importAttr', in the order that is expected by the attribute class. @@ -9243,6 +9257,15 @@ Expected ASTImporter::Import(const Attr *FromAttr) { From->args_size()); break; } + case attr::CountedBy: { + AI.cloneAttr(FromAttr); + const auto *CBA = cast(FromAttr); + Expected SR = Import(CBA->getCountedByFieldLoc()).get(); + if (!SR) + return SR.takeError(); + AI.castAttrAs()->setCountedByFieldLoc(SR.get()); + break; + } default: { // The default branch works for attributes that have no arguments to import. diff --git a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp index b1733c2d052a..8163f9bdaf8d 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp @@ -29,7 +29,6 @@ #include "clang/AST/Type.h" #include "clang/Basic/IdentifierTable.h" #include "clang/Basic/LLVM.h" -#include "clang/Basic/LangOptions.h" #include "clang/Basic/Module.h" #include "clang/Basic/ObjCRuntime.h" #include "clang/Basic/PartialDiagnostic.h" @@ -411,6 +410,79 @@ bool Decl::isFileContextDecl() const { return DC && DC->isFileContext(); } +bool Decl::isFlexibleArrayMemberLike( + ASTContext &Ctx, const Decl *D, QualType Ty, + LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel, + bool IgnoreTemplateOrMacroSubstitution) { + // For compatibility with existing code, we treat arrays of length 0 or + // 1 as flexible array members. + const auto *CAT = Ctx.getAsConstantArrayType(Ty); + if (CAT) { + using FAMKind = LangOptions::StrictFlexArraysLevelKind; + + llvm::APInt Size = CAT->getSize(); + if (StrictFlexArraysLevel == FAMKind::IncompleteOnly) + return false; + + // GCC extension, only allowed to represent a FAM. + if (Size.isZero()) + return true; + + if (StrictFlexArraysLevel == FAMKind::ZeroOrIncomplete && Size.uge(1)) + return false; + + if (StrictFlexArraysLevel == FAMKind::OneZeroOrIncomplete && Size.uge(2)) + return false; + } else if (!Ctx.getAsIncompleteArrayType(Ty)) { + return false; + } + + if (const auto *OID = dyn_cast_if_present(D)) + return OID->getNextIvar() == nullptr; + + const auto *FD = dyn_cast_if_present(D); + if (!FD) + return false; + + if (CAT) { + // GCC treats an array memeber of a union as an FAM if the size is one or + // zero. + llvm::APInt Size = CAT->getSize(); + if (FD->getParent()->isUnion() && (Size.isZero() || Size.isOne())) + return true; + } + + // Don't consider sizes resulting from macro expansions or template argument + // substitution to form C89 tail-padded arrays. + if (IgnoreTemplateOrMacroSubstitution) { + TypeSourceInfo *TInfo = FD->getTypeSourceInfo(); + while (TInfo) { + TypeLoc TL = TInfo->getTypeLoc(); + + // Look through typedefs. + if (TypedefTypeLoc TTL = TL.getAsAdjusted()) { + const TypedefNameDecl *TDL = TTL.getTypedefNameDecl(); + TInfo = TDL->getTypeSourceInfo(); + continue; + } + + if (auto CTL = TL.getAs()) { + if (const Expr *SizeExpr = + dyn_cast_if_present(CTL.getSizeExpr()); + !SizeExpr || SizeExpr->getExprLoc().isMacroID()) + return false; + } + + break; + } + } + + // Test that the field is the last in the structure. + RecordDecl::field_iterator FI( + DeclContext::decl_iterator(const_cast(FD))); + return ++FI == FD->getParent()->field_end(); +} + TranslationUnitDecl *Decl::getTranslationUnitDecl() { if (auto *TUD = dyn_cast(this)) return TUD; diff --git a/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp b/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp index c944862fcefe..98b0a6dc28ea 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp @@ -587,6 +587,19 @@ bool CXXRecordDecl::isTriviallyCopyable() const { return true; } +bool CXXRecordDecl::isTriviallyCopyConstructible() const { + + // A trivially copy constructible class is a class that: + // -- has no non-trivial copy constructors, + if (hasNonTrivialCopyConstructor()) + return false; + // -- has a trivial destructor. + if (!hasTrivialDestructor()) + return false; + + return true; +} + void CXXRecordDecl::markedVirtualFunctionPure() { // C++ [class.abstract]p2: // A class is abstract if it has at least one pure virtual function. diff --git a/contrib/llvm-project/clang/lib/AST/Expr.cpp b/contrib/llvm-project/clang/lib/AST/Expr.cpp index a90f92d07f86..b125fc676da8 100644 --- a/contrib/llvm-project/clang/lib/AST/Expr.cpp +++ b/contrib/llvm-project/clang/lib/AST/Expr.cpp @@ -205,85 +205,22 @@ bool Expr::isKnownToHaveBooleanValue(bool Semantic) const { *** 13055 LINES SKIPPED *** From nobody Sat Apr 20 10:32:21 2024 X-Original-To: dev-commits-src-branches@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 4VM7B12GJtz5HVrp; Sat, 20 Apr 2024 10:32:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B06FYrz4PbB; Sat, 20 Apr 2024 10:32:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609144; 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=VrSJ+LYU7f2St+BcBHcwsHaoLq+ST5moGngV7IlpDNc=; b=eufVMAikccQJqVonLqu7S41dmuGdGJ+DXbH2XujsxK4x7++QZ8dszyNRhNDJ6NLUuUdRvd bjcNEbND20bJv1EFr+dxj5miNpoK7aQ2LkXEGiKLIfHJjMidlGQN2APZBMZnV4uiVIj+V9 iUwdxwaqn1CybBA2XXqAyURiJAISHIqCgGWZNcgIOiV7IFeGWgk9RP57uyCbFv/JoImtP6 BSHG/0F6f5YsuLe6kqldCNQFKBPsmrqdhZLo9uL8Kc87gPdGaASnLyFr6cU9upm1cqC5vf aqZP7t1Q1LkdnAc4bQaFxA+UHfmUph0mk//b2OQYAZs0zjeo0d+NFNKNuy5SgA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609144; a=rsa-sha256; cv=none; b=uKzliDQ0rCQTSFk08RB13eSzkl/w16ilEK7mPfDmX5Ke/l8Hy7LOYwkbobGN3ULANjdKKN 7cl8qJjE4huxrmuojWP3J/4DWX9eww58LK63mV1CmcnzcjWmk8mRB5dPEiyVHH5rUMZrWc z+k/z/8sCkuCfRZogjD8KvvbsLSgaHZeXvoNYCb7jdmWyx2WUAT1kcsGrAWztWcmWopfLV JfltabpvemAs9QlC0c9C9eNw33D+ZDCYP6MCB4h6zEGXF/XQ2YaPuwiDxXyhaUOc98UuCx JUbfOTZeJbl4YFjEuNs/h4K05sbhGg85kQoFaFs1Pg5oV7L5lAT7Nrq8AGkScQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609144; 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=VrSJ+LYU7f2St+BcBHcwsHaoLq+ST5moGngV7IlpDNc=; b=wd89XQ64hKsiTm/JEcspzHg6mCdXRe+yKlV4Wd6Aux9HUmgamOQfhEVOKqjbpAu4A9CncT a5Mb2mE1EaO3CTREkmu+K0TqZsffRZ6QEzCxM2FBS5wcuEYx2ohDtnCpH8Hy3w8E4wRuNk D/3Oecw0v93mu2xfMMnpb8VyMV5m2VW1cmNfp4yktn2o0U5njQvpapku099IOpNcq+DH9g odnRrPmuEJFf+YMR+rTrfAIvwGv8z5OVA9nuA8TXd2haKGmCGcHrsgNaJVa5GUPJX2ga0F 4vm0OnXBjnuzrYuOsL/MemYh5Hp+QgyL4/zNH+CnmiH9ubicpMQ63cEZqesxJA== 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 4VM7B05XHwzYS1; Sat, 20 Apr 2024 10:32:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWOhv010979; Sat, 20 Apr 2024 10:32:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWLPe009727; Sat, 20 Apr 2024 10:32:21 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:21 GMT Message-Id: <202404201032.43KAWLPe009727@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: a58f00ea9151 - stable/14 - Merge llvm-project main llvmorg-18-init-18359-g93248729cfae List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: a58f00ea91514a4814b96b25bcb8dc79e946edce Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a58f00ea91514a4814b96b25bcb8dc79e946edce commit a58f00ea91514a4814b96b25bcb8dc79e946edce Author: Dimitry Andric AuthorDate: 2024-01-24 19:17:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:13 +0000 Merge llvm-project main llvmorg-18-init-18359-g93248729cfae This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-18359-g93248729cfae, the last commit before the upstream release/18.x branch was created. PR: 276104 MFC after: 1 month (cherry picked from commit 7a6dacaca14b62ca4b74406814becb87a3fefac0) --- contrib/llvm-project/FREEBSD-Xlist | 7 +- .../clang/include/clang/AST/APNumericStorage.h | 71 + .../llvm-project/clang/include/clang/AST/Decl.h | 25 +- .../clang/include/clang/AST/DeclBase.h | 9 +- .../llvm-project/clang/include/clang/AST/DeclCXX.h | 41 +- .../llvm-project/clang/include/clang/AST/Expr.h | 64 +- .../llvm-project/clang/include/clang/AST/ExprCXX.h | 19 +- .../llvm-project/clang/include/clang/AST/ODRHash.h | 3 + .../clang/include/clang/AST/PropertiesBase.td | 14 + .../clang/include/clang/AST/RecursiveASTVisitor.h | 2 + .../llvm-project/clang/include/clang/AST/Stmt.h | 8 +- .../include/clang/AST/TemplateArgumentVisitor.h | 2 + .../clang/include/clang/AST/TemplateBase.h | 86 +- .../llvm-project/clang/include/clang/AST/Type.h | 88 +- .../clang/include/clang/ASTMatchers/ASTMatchers.h | 205 +- .../clang/ASTMatchers/ASTMatchersInternal.h | 3 + .../Analysis/FlowSensitive/ControlFlowContext.h | 3 +- .../Analysis/FlowSensitive/DataflowAnalysis.h | 21 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 3 +- .../include/clang/Analysis/FlowSensitive/Formula.h | 4 + .../clang/Analysis/FlowSensitive/Transfer.h | 13 +- .../FlowSensitive/TypeErasedDataflowAnalysis.h | 9 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 98 +- .../clang/include/clang/Basic/AttrDocs.td | 84 +- .../include/clang/Basic/AttributeCommonInfo.h | 13 + .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 28 +- .../include/clang/Basic/BuiltinsLoongArchBase.def | 5 + .../include/clang/Basic/BuiltinsLoongArchLASX.def | 6 + .../include/clang/Basic/BuiltinsLoongArchLSX.def | 6 + .../clang/include/clang/Basic/BuiltinsPPC.def | 4 + .../clang/include/clang/Basic/CodeGenOptions.def | 15 +- .../clang/include/clang/Basic/CodeGenOptions.h | 3 + .../include/clang/Basic/DiagnosticCommonKinds.td | 8 +- .../include/clang/Basic/DiagnosticDriverKinds.td | 15 +- .../include/clang/Basic/DiagnosticParseKinds.td | 12 + .../include/clang/Basic/DiagnosticSemaKinds.td | 41 +- .../clang/Basic/DiagnosticSerializationKinds.td | 6 +- .../clang/include/clang/Basic/Features.def | 4 + .../clang/include/clang/Basic/LangOptions.def | 28 +- .../clang/include/clang/Basic/LangOptions.h | 44 +- .../clang/include/clang/Basic/ObjCRuntime.h | 15 +- .../clang/include/clang/Basic/OpenACCKinds.h | 294 +- .../clang/include/clang/Basic/TargetBuiltins.h | 4 +- .../clang/include/clang/Basic/TokenKinds.def | 5 +- .../clang/include/clang/Basic/TokenKinds.h | 4 +- .../clang/include/clang/Basic/arm_sme.td | 572 +- .../clang/include/clang/Basic/arm_sve.td | 222 +- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 72 +- .../clang/include/clang/Basic/riscv_vector.td | 44 +- .../clang/include/clang/Driver/Options.td | 69 +- .../clang/include/clang/Driver/Types.def | 6 +- .../clang/include/clang/ExtractAPI/API.h | 289 +- .../include/clang/ExtractAPI/AvailabilityInfo.h | 55 +- .../clang/ExtractAPI/DeclarationFragments.h | 5 +- .../include/clang/ExtractAPI/ExtractAPIVisitor.h | 195 +- .../ExtractAPI/Serialization/SerializerBase.h | 12 +- .../Serialization/SymbolGraphSerializer.h | 4 +- .../clang/include/clang/Format/Format.h | 11 + .../clang/include/clang/Frontend/ASTUnit.h | 2 +- .../clang/include/clang/Frontend/Utils.h | 4 +- .../clang/include/clang/Interpreter/Interpreter.h | 4 +- .../llvm-project/clang/include/clang/Lex/Lexer.h | 2 +- .../clang/include/clang/Lex/Preprocessor.h | 14 +- .../clang/include/clang/Parse/Parser.h | 32 + .../clang/include/clang/Sema/ScopeInfo.h | 6 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 64 +- .../clang/include/clang/Serialization/ASTReader.h | 4 + .../include/clang/Support/RISCVVIntrinsicUtils.h | 2 +- .../clang/lib/ARCMigrate/FileRemapper.cpp | 2 +- .../llvm-project/clang/lib/ARCMigrate/ObjCMT.cpp | 2 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 12 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 39 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 62 +- contrib/llvm-project/clang/lib/AST/Decl.cpp | 21 +- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 31 +- contrib/llvm-project/clang/lib/AST/DeclPrinter.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 9 +- contrib/llvm-project/clang/lib/AST/ExprCXX.cpp | 10 +- .../llvm-project/clang/lib/AST/ExprConstant.cpp | 45 +- .../clang/lib/AST/Interp/ByteCodeEmitter.cpp | 13 +- .../clang/lib/AST/Interp/ByteCodeEmitter.h | 10 +- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 96 +- .../clang/lib/AST/Interp/ByteCodeExprGen.h | 6 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.cpp | 68 +- .../llvm-project/clang/lib/AST/Interp/Context.cpp | 106 +- .../llvm-project/clang/lib/AST/Interp/Context.h | 3 + .../clang/lib/AST/Interp/EvalEmitter.cpp | 174 +- .../clang/lib/AST/Interp/EvalEmitter.h | 15 +- .../clang/lib/AST/Interp/EvaluationResult.cpp | 196 + .../clang/lib/AST/Interp/EvaluationResult.h | 111 + .../llvm-project/clang/lib/AST/Interp/IntegralAP.h | 12 +- .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 166 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 37 +- .../llvm-project/clang/lib/AST/Interp/Opcodes.td | 9 +- .../llvm-project/clang/lib/AST/Interp/Pointer.cpp | 154 +- .../llvm-project/clang/lib/AST/Interp/Pointer.h | 3 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 40 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 7 +- contrib/llvm-project/clang/lib/AST/Mangle.cpp | 2 +- .../llvm-project/clang/lib/AST/MicrosoftMangle.cpp | 78 +- .../llvm-project/clang/lib/AST/ODRDiagsEmitter.cpp | 4 +- contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 120 +- .../clang/lib/AST/RecordLayoutBuilder.cpp | 4 +- contrib/llvm-project/clang/lib/AST/StmtPrinter.cpp | 5 +- contrib/llvm-project/clang/lib/AST/StmtProfile.cpp | 6 + .../llvm-project/clang/lib/AST/TemplateBase.cpp | 113 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 12 +- contrib/llvm-project/clang/lib/AST/TypeLoc.cpp | 1 + contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 39 +- .../llvm-project/clang/lib/AST/VTableBuilder.cpp | 18 +- .../clang/lib/ASTMatchers/ASTMatchersInternal.cpp | 1 + .../clang/lib/ASTMatchers/Dynamic/Registry.cpp | 7 + .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 17 +- .../Analysis/FlowSensitive/ControlFlowContext.cpp | 2 +- .../FlowSensitive/DataflowAnalysisContext.cpp | 8 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 24 +- .../Analysis/FlowSensitive/SimplifyConstraints.cpp | 4 +- .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 2 + .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 92 +- .../clang/lib/Analysis/FlowSensitive/Value.cpp | 14 +- .../clang/lib/Analysis/RetainSummaryManager.cpp | 2 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 5 +- .../clang/lib/Basic/CodeGenOptions.cpp | 2 + .../llvm-project/clang/lib/Basic/FileManager.cpp | 2 +- contrib/llvm-project/clang/lib/Basic/Targets.cpp | 2 + .../clang/lib/Basic/Targets/AArch64.cpp | 27 +- .../llvm-project/clang/lib/Basic/Targets/AMDGPU.h | 17 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 4 + .../clang/lib/Basic/Targets/OSTargets.h | 6 +- .../llvm-project/clang/lib/Basic/Targets/PPC.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 93 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 12 + .../llvm-project/clang/lib/Basic/Targets/SPIR.h | 6 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 11 + contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 3 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 8 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 45 +- .../llvm-project/clang/lib/CodeGen/CGCUDANV.cpp | 2 +- contrib/llvm-project/clang/lib/CodeGen/CGCXX.cpp | 5 + contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 28 +- contrib/llvm-project/clang/lib/CodeGen/CGCleanup.h | 1 + .../llvm-project/clang/lib/CodeGen/CGDebugInfo.cpp | 12 +- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 14 + .../llvm-project/clang/lib/CodeGen/CGException.cpp | 4 + contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 12 +- .../llvm-project/clang/lib/CodeGen/CGExprCXX.cpp | 60 +- .../clang/lib/CodeGen/CGExprComplex.cpp | 10 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 18 +- contrib/llvm-project/clang/lib/CodeGen/CGObjC.cpp | 5 + .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 244 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 7 + contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 4 +- .../llvm-project/clang/lib/CodeGen/CGVTables.cpp | 2 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 122 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 4 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 437 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.h | 3 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 35 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 5 + .../clang/lib/CrossTU/CrossTranslationUnit.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 45 +- .../clang/lib/Driver/SanitizerArgs.cpp | 10 +- .../llvm-project/clang/lib/Driver/ToolChain.cpp | 8 +- .../clang/lib/Driver/ToolChains/AMDGPU.cpp | 33 +- .../clang/lib/Driver/ToolChains/AVR.cpp | 2 +- .../clang/lib/Driver/ToolChains/Arch/AArch64.cpp | 288 +- .../clang/lib/Driver/ToolChains/Arch/ARM.cpp | 5 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 4 + .../clang/lib/Driver/ToolChains/CSKYToolChain.cpp | 2 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 129 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 23 +- .../clang/lib/Driver/ToolChains/Cuda.cpp | 2 +- .../clang/lib/Driver/ToolChains/Darwin.cpp | 79 +- .../clang/lib/Driver/ToolChains/Darwin.h | 21 +- .../clang/lib/Driver/ToolChains/Fuchsia.cpp | 4 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 24 +- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 2 +- .../clang/lib/Driver/ToolChains/Hurd.cpp | 18 +- .../clang/lib/Driver/ToolChains/MSP430.cpp | 2 +- .../clang/lib/Driver/ToolChains/MSVC.cpp | 12 +- .../clang/lib/Driver/ToolChains/MSVC.h | 5 +- .../clang/lib/Driver/ToolChains/MinGW.cpp | 8 +- .../clang/lib/Driver/ToolChains/MinGW.h | 5 +- .../clang/lib/Driver/ToolChains/MipsLinux.cpp | 2 +- .../clang/lib/Driver/ToolChains/OpenBSD.cpp | 4 +- .../clang/lib/Driver/ToolChains/PS4CPU.cpp | 8 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Types.cpp | 7 +- contrib/llvm-project/clang/lib/ExtractAPI/API.cpp | 150 +- .../clang/lib/ExtractAPI/AvailabilityInfo.cpp | 63 +- .../clang/lib/ExtractAPI/DeclarationFragments.cpp | 89 +- .../Serialization/SymbolGraphSerializer.cpp | 74 +- .../clang/lib/Format/ContinuationIndenter.cpp | 34 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 7 +- .../llvm-project/clang/lib/Format/FormatToken.h | 76 + .../clang/lib/Format/FormatTokenLexer.cpp | 84 + .../clang/lib/Format/FormatTokenLexer.h | 7 + .../clang/lib/Format/TokenAnnotator.cpp | 17 +- .../clang/lib/Format/UnwrappedLineFormatter.cpp | 2 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 66 +- .../clang/lib/Format/WhitespaceManager.cpp | 15 +- .../clang/lib/Format/WhitespaceManager.h | 2 +- .../clang/lib/Frontend/CompilerInstance.cpp | 6 +- .../clang/lib/Frontend/CompilerInvocation.cpp | 53 +- .../clang/lib/Frontend/InitPreprocessor.cpp | 24 +- .../clang/lib/Frontend/LogDiagnosticPrinter.cpp | 2 +- .../clang/lib/Frontend/Rewrite/FrontendActions.cpp | 4 +- .../clang/lib/Frontend/TextDiagnosticBuffer.cpp | 8 +- contrib/llvm-project/clang/lib/Headers/arm_acle.h | 70 +- contrib/llvm-project/clang/lib/Headers/bmiintrin.h | 273 +- .../llvm-project/clang/lib/Headers/ia32intrin.h | 444 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 57 + .../llvm-project/clang/lib/Headers/larchintrin.h | 12 + .../llvm-project/clang/lib/Headers/lasxintrin.h | 24 + .../clang/lib/Headers/llvm_libc_wrappers/string.h | 4 +- contrib/llvm-project/clang/lib/Headers/lsxintrin.h | 24 + .../llvm-project/clang/lib/Index/USRGeneration.cpp | 10 + .../clang/lib/Interpreter/Interpreter.cpp | 34 +- .../llvm-project/clang/lib/Lex/HeaderSearch.cpp | 78 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 2 +- .../llvm-project/clang/lib/Lex/Preprocessor.cpp | 5 + .../llvm-project/clang/lib/Lex/UnicodeCharSets.h | 47 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 75 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 28 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 13 +- .../llvm-project/clang/lib/Parse/ParseExprCXX.cpp | 9 +- contrib/llvm-project/clang/lib/Parse/ParseObjc.cpp | 6 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 523 +- .../clang/lib/Parse/ParseTentative.cpp | 3 +- contrib/llvm-project/clang/lib/Parse/Parser.cpp | 5 + .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 17 +- contrib/llvm-project/clang/lib/Sema/Sema.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 133 +- .../llvm-project/clang/lib/Sema/SemaCoroutine.cpp | 5 + contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 174 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 120 +- .../llvm-project/clang/lib/Sema/SemaDeclCXX.cpp | 41 +- .../llvm-project/clang/lib/Sema/SemaDeclObjC.cpp | 4 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 43 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 49 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 70 +- contrib/llvm-project/clang/lib/Sema/SemaLambda.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaLookup.cpp | 1 + .../clang/lib/Sema/SemaObjCProperty.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 187 +- .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 5 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 6 + .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 265 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 64 +- .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 17 +- .../clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 23 +- .../clang/lib/Sema/SemaTemplateVariadic.cpp | 2 + contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 269 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 24 +- .../clang/lib/Serialization/ASTReader.cpp | 90 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 6 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 1 + .../clang/lib/Serialization/ASTWriter.cpp | 23 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 2 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 1 + .../Checkers/CheckSecuritySyntaxOnly.cpp | 2 + .../Checkers/LocalizationChecker.cpp | 6 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 91 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 183 + .../StaticAnalyzer/Checkers/VirtualCallChecker.cpp | 2 +- .../lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp | 14 +- .../clang/lib/Tooling/ASTDiff/ASTDiff.cpp | 4 +- .../clang/lib/Tooling/CompilationDatabase.cpp | 6 +- .../DependencyScanningWorker.cpp | 2 +- .../clang/lib/Tooling/Syntax/Tokens.cpp | 6 + contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 2 +- .../clang/tools/clang-format/ClangFormat.cpp | 24 +- contrib/llvm-project/clang/tools/driver/driver.cpp | 4 +- .../clang/utils/TableGen/ClangAttrEmitter.cpp | 63 +- ...ngCommentHTMLNamedCharacterReferenceEmitter.cpp | 2 +- .../utils/TableGen/ClangDiagnosticsEmitter.cpp | 2 +- .../clang/utils/TableGen/MveEmitter.cpp | 2 +- .../clang/utils/TableGen/RISCVVEmitter.cpp | 2 +- .../clang/utils/TableGen/SveEmitter.cpp | 56 +- .../llvm-project/clang/utils/TableGen/TableGen.cpp | 21 +- .../clang/utils/TableGen/TableGenBackends.h | 4 +- .../include/profile/instr_prof_interface.h | 92 + .../llvm-project/compiler-rt/lib/asan/asan_win.cpp | 7 +- .../lib/builtins/aarch64/sme-libc-routines.c | 87 + .../compiler-rt/lib/builtins/cpu_model/aarch64.c | 1 + .../lib/builtins/cpu_model/aarch64/fmv/apple.inc | 30 +- .../lib/builtins/cpu_model/aarch64/fmv/mrs.inc | 2 + .../lib/builtins/cpu_model/aarch64/hwcap.inc | 3 + .../compiler-rt/lib/builtins/cpu_model/x86.c | 5 +- .../compiler-rt/lib/builtins/fp_extend_impl.inc | 2 +- .../compiler-rt/lib/builtins/int_lib.h | 10 +- .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 8 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 2 +- .../compiler-rt/lib/interception/interception.h | 5 +- .../lib/interception/interception_win.cpp | 33 +- .../compiler-rt/lib/orc/coff_platform.cpp | 8 +- .../compiler-rt/lib/orc/wrapper_function_utils.h | 6 +- .../compiler-rt/lib/profile/InstrProfiling.h | 61 +- .../compiler-rt/lib/profile/InstrProfilingFile.c | 14 +- .../compiler-rt/lib/profile/InstrProfilingMerge.c | 5 + .../compiler-rt/lib/profile/InstrProfilingValue.c | 5 + .../compiler-rt/lib/profile/WindowsMMap.c | 3 +- .../compiler-rt/lib/profile/WindowsMMap.h | 6 + .../lib/sanitizer_common/sanitizer_asm.h | 23 + .../sanitizer_common_interceptors.inc | 8 +- .../lib/sanitizer_common/sanitizer_fuchsia.cpp | 87 +- .../lib/sanitizer_common/sanitizer_internal_defs.h | 9 +- .../sanitizer_symbolizer_report.cpp | 3 +- .../symbolizer/scripts/build_symbolizer.sh | 1 + .../compiler-rt/lib/tsan/rtl/tsan_dispatch_defs.h | 7 - .../compiler-rt/lib/tsan/rtl/tsan_platform.h | 2 +- .../lib/tsan/rtl/tsan_platform_linux.cpp | 140 +- .../compiler-rt/lib/tsan/rtl/tsan_platform_mac.cpp | 5 +- .../lib/tsan/rtl/tsan_platform_posix.cpp | 43 +- .../libcxx/include/__algorithm/clamp.h | 2 +- .../libcxx/include/__algorithm/comp_ref_type.h | 5 +- .../libcxx/include/__algorithm/nth_element.h | 8 +- .../libcxx/include/__algorithm/ranges_clamp.h | 5 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 22 +- .../include/__algorithm/three_way_comp_ref_type.h | 6 +- contrib/llvm-project/libcxx/include/__assert | 6 +- .../libcxx/include/__atomic/is_always_lock_free.h | 2 +- contrib/llvm-project/libcxx/include/__availability | 29 +- .../llvm-project/libcxx/include/__bit/bit_ceil.h | 2 +- .../llvm-project/libcxx/include/__chrono/ostream.h | 9 +- .../libcxx/include/__concepts/arithmetic.h | 4 + contrib/llvm-project/libcxx/include/__config | 71 +- .../libcxx/include/__coroutine/coroutine_handle.h | 16 +- .../__debug_utils/strict_weak_ordering_check.h | 14 +- .../libcxx/include/__exception/exception_ptr.h | 50 + .../libcxx/include/__expected/expected.h | 1142 +- contrib/llvm-project/libcxx/include/__hash_table | 2 +- .../libcxx/include/__iterator/iterator_traits.h | 2 +- .../libcxx/include/__memory/allocator.h | 14 +- .../libcxx/include/__memory/assume_aligned.h | 4 +- .../__memory_resource/polymorphic_allocator.h | 5 +- .../libcxx/include/__numeric/gcd_lcm.h | 2 +- .../include/__numeric/saturation_arithmetic.h | 110 + .../libcxx/include/__ranges/chunk_by_view.h | 3 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 2 +- .../libcxx/include/__ranges/repeat_view.h | 2 +- .../libcxx/include/__ranges/single_view.h | 2 +- .../libcxx/include/__ranges/take_while_view.h | 3 +- .../libcxx/include/__ranges/transform_view.h | 3 +- .../llvm-project/libcxx/include/__utility/cmp.h | 43 +- contrib/llvm-project/libcxx/include/any | 3 + contrib/llvm-project/libcxx/include/barrier | 23 +- contrib/llvm-project/libcxx/include/chrono | 4 + contrib/llvm-project/libcxx/include/concepts | 2 +- .../llvm-project/libcxx/include/condition_variable | 93 +- .../include/experimental/__simd/aligned_tag.h | 3 +- .../libcxx/include/experimental/__simd/scalar.h | 7 + .../libcxx/include/experimental/__simd/simd.h | 6 + .../libcxx/include/experimental/__simd/simd_mask.h | 6 + .../libcxx/include/experimental/__simd/vec_ext.h | 11 + contrib/llvm-project/libcxx/include/future | 11 +- contrib/llvm-project/libcxx/include/latch | 21 +- contrib/llvm-project/libcxx/include/libcxx.imp | 888 +- contrib/llvm-project/libcxx/include/locale | 12 +- contrib/llvm-project/libcxx/include/memory | 2 +- .../libcxx/include/module.modulemap.in | 1 + contrib/llvm-project/libcxx/include/new | 1 - contrib/llvm-project/libcxx/include/numeric | 13 + contrib/llvm-project/libcxx/include/ostream | 21 +- contrib/llvm-project/libcxx/include/print | 18 +- contrib/llvm-project/libcxx/include/regex | 11 +- contrib/llvm-project/libcxx/include/semaphore | 19 +- contrib/llvm-project/libcxx/include/shared_mutex | 11 +- contrib/llvm-project/libcxx/include/span | 16 + contrib/llvm-project/libcxx/include/sstream | 2 +- contrib/llvm-project/libcxx/include/stop_token | 11 +- contrib/llvm-project/libcxx/include/string | 5 +- contrib/llvm-project/libcxx/include/string_view | 7 +- contrib/llvm-project/libcxx/include/thread | 11 +- contrib/llvm-project/libcxx/include/typeinfo | 1 - contrib/llvm-project/libcxx/include/variant | 53 +- contrib/llvm-project/libcxx/include/vector | 14 +- contrib/llvm-project/libcxx/include/version | 4 +- .../llvm-project/libcxx/modules/modules.json.in | 26 + .../llvm-project/libcxx/modules/std.compat.cppm.in | 125 +- .../libcxx/modules/std.compat/cstdlib.inc | 4 +- .../libcxx/modules/std.compat/ctime.inc | 2 +- contrib/llvm-project/libcxx/modules/std.cppm.in | 1 + contrib/llvm-project/libcxx/modules/std/ctime.inc | 2 +- contrib/llvm-project/libcxx/modules/std/memory.inc | 2 + .../llvm-project/libcxx/modules/std/numeric.inc | 10 + .../libcxx/src/filesystem/operations.cpp | 26 +- .../libcxx/src/include/overridable_function.h | 119 + .../libcxx/src/include/to_chars_floating_point.h | 2 +- .../llvm-project/libcxx/src/memory_resource.cpp | 3 +- contrib/llvm-project/libcxx/src/mutex.cpp | 8 +- contrib/llvm-project/libcxx/src/new.cpp | 107 +- contrib/llvm-project/libcxx/src/ostream.cpp | 2 +- .../support/runtime/exception_pointer_cxxabi.ipp | 8 + .../support/runtime/exception_pointer_glibcxx.ipp | 8 + .../runtime/exception_pointer_unimplemented.ipp | 6 + .../vendor/llvm/default_assertion_handler.in | 31 + .../llvm-project/libunwind/src/UnwindCursor.hpp | 4 +- contrib/llvm-project/libunwind/src/libunwind.cpp | 6 +- contrib/llvm-project/lld/COFF/Driver.cpp | 12 +- contrib/llvm-project/lld/COFF/DriverUtils.cpp | 8 +- contrib/llvm-project/lld/COFF/InputFiles.cpp | 4 +- contrib/llvm-project/lld/COFF/Writer.cpp | 2 + contrib/llvm-project/lld/Common/Args.cpp | 15 +- .../llvm-project/lld/Common/DriverDispatcher.cpp | 1 - contrib/llvm-project/lld/ELF/Arch/ARM.cpp | 6 +- contrib/llvm-project/lld/ELF/Arch/Mips.cpp | 7 +- contrib/llvm-project/lld/ELF/Arch/PPC64.cpp | 2 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 10 +- contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 8 +- contrib/llvm-project/lld/ELF/Config.h | 2 + contrib/llvm-project/lld/ELF/Driver.cpp | 200 +- contrib/llvm-project/lld/ELF/DriverUtils.cpp | 2 +- contrib/llvm-project/lld/ELF/InputFiles.cpp | 10 +- contrib/llvm-project/lld/ELF/InputFiles.h | 11 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 4 +- contrib/llvm-project/lld/ELF/InputSection.h | 3 +- contrib/llvm-project/lld/ELF/LTO.cpp | 84 +- contrib/llvm-project/lld/ELF/LTO.h | 4 +- contrib/llvm-project/lld/ELF/LinkerScript.cpp | 8 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 17 +- contrib/llvm-project/lld/ELF/ScriptLexer.h | 4 +- contrib/llvm-project/lld/ELF/ScriptParser.cpp | 3 +- contrib/llvm-project/lld/ELF/Symbols.cpp | 6 +- contrib/llvm-project/lld/ELF/Symbols.h | 32 +- contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 4 +- contrib/llvm-project/lld/ELF/Target.cpp | 2 +- contrib/llvm-project/lld/ELF/Writer.cpp | 38 +- contrib/llvm-project/lld/MachO/Arch/ARM64.cpp | 51 +- contrib/llvm-project/lld/MachO/Arch/ARM64Common.h | 37 +- contrib/llvm-project/lld/MachO/Arch/ARM64_32.cpp | 11 +- contrib/llvm-project/lld/MachO/Arch/X86_64.cpp | 20 +- contrib/llvm-project/lld/MachO/Driver.cpp | 17 +- contrib/llvm-project/lld/MachO/DriverUtils.cpp | 2 +- .../llvm-project/lld/MachO/SyntheticSections.cpp | 42 +- contrib/llvm-project/lld/MachO/SyntheticSections.h | 2 +- contrib/llvm-project/lld/MachO/Target.h | 9 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 4 + contrib/llvm-project/lld/tools/lld/lld.cpp | 2 - contrib/llvm-project/lldb/include/lldb/API/LLDB.h | 1 + .../lldb/include/lldb/Breakpoint/Breakpoint.h | 2 +- .../include/lldb/Breakpoint/BreakpointIDList.h | 17 +- .../lldb/include/lldb/Breakpoint/Watchpoint.h | 2 - .../llvm-project/lldb/include/lldb/Core/Address.h | 10 +- .../lldb/include/lldb/Core/DebuggerEvents.h | 7 +- .../llvm-project/lldb/include/lldb/Core/Progress.h | 16 +- .../lldb/include/lldb/Core/ValueObject.h | 3 +- .../lldb/include/lldb/Host/Config.h.cmake | 2 + .../lldb/include/lldb/Symbol/CompileUnit.h | 16 +- .../lldb/include/lldb/Symbol/LineEntry.h | 10 +- .../llvm-project/lldb/include/lldb/Symbol/Symbol.h | 6 +- .../lldb/include/lldb/Symbol/SymbolContext.h | 16 +- .../lldb/include/lldb/Target/Platform.h | 26 + .../lldb/include/lldb/Utility/Broadcaster.h | 6 +- .../lldb/include/lldb/Utility/FileSpec.h | 24 +- .../lldb/include/lldb/Utility/FileSpecList.h | 33 +- .../lldb/include/lldb/Utility/Stream.h | 18 +- .../lldb/include/lldb/Utility/SupportFile.h | 55 + .../lldb/include/lldb/Utility/XcodeSDK.h | 2 + .../lldb/include/lldb/lldb-enumerations.h | 1 + .../llvm-project/lldb/include/lldb/lldb-forward.h | 2 + .../llvm-project/lldb/source/API/SBTypeFilter.cpp | 2 +- .../llvm-project/lldb/source/API/SBTypeFormat.cpp | 2 +- .../llvm-project/lldb/source/API/SBTypeSummary.cpp | 2 +- .../lldb/source/API/SBTypeSynthetic.cpp | 2 +- .../lldb/source/Breakpoint/Breakpoint.cpp | 53 +- .../lldb/source/Breakpoint/BreakpointIDList.cpp | 66 +- .../lldb/source/Breakpoint/BreakpointList.cpp | 7 +- .../lldb/source/Breakpoint/BreakpointLocation.cpp | 6 +- .../lldb/source/Breakpoint/BreakpointResolver.cpp | 3 +- .../lldb/source/Breakpoint/Watchpoint.cpp | 22 +- .../lldb/source/Breakpoint/WatchpointList.cpp | 23 +- .../source/Commands/CommandObjectBreakpoint.cpp | 54 +- .../lldb/source/Commands/CommandObjectFrame.cpp | 1 + .../lldb/source/Commands/CommandObjectSource.cpp | 4 +- .../lldb/source/Commands/CommandObjectTarget.cpp | 38 +- contrib/llvm-project/lldb/source/Core/Address.cpp | 26 +- .../llvm-project/lldb/source/Core/Disassembler.cpp | 5 +- .../llvm-project/lldb/source/Core/FormatEntity.cpp | 38 +- contrib/llvm-project/lldb/source/Core/Module.cpp | 16 +- .../llvm-project/lldb/source/Core/ModuleList.cpp | 28 +- contrib/llvm-project/lldb/source/Core/Progress.cpp | 30 +- .../llvm-project/lldb/source/Core/ValueObject.cpp | 343 +- .../lldb/source/Expression/DiagnosticManager.cpp | 15 +- .../Instruction/ARM/EmulateInstructionARM.cpp | 1 + .../Language/CPlusPlus/CPlusPlusLanguage.cpp | 84 +- .../source/Plugins/Language/CPlusPlus/LibCxx.cpp | 94 +- .../source/Plugins/Language/CPlusPlus/LibCxx.h | 12 + .../ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp | 6 +- .../Plugins/ObjectFile/ELF/ObjectFileELF.cpp | 5 +- .../Utility/RegisterContextPOSIX_mips64.cpp | 23 +- .../gdb-remote/GDBRemoteCommunicationClient.cpp | 3 +- .../Process/gdb-remote/ProcessGDBRemote.cpp | 79 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.cpp | 9 +- .../Plugins/SymbolFile/CTF/SymbolFileCTF.cpp | 1 + .../Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp | 6 + .../Plugins/SymbolFile/DWARF/DWARFDebugInfo.h | 5 + .../Plugins/SymbolFile/DWARF/DWARFFormValue.cpp | 24 +- .../Plugins/SymbolFile/DWARF/DWARFFormValue.h | 6 + .../source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp | 24 + .../source/Plugins/SymbolFile/DWARF/DWARFUnit.h | 5 + .../Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp | 5 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 16 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp | 11 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.cpp | 6 +- .../Debuginfod/SymbolLocatorDebuginfod.cpp | 83 +- .../SymbolLocatorDebuginfodProperties.td | 8 +- .../SymbolLocator/Default/SymbolLocatorDefault.cpp | 6 +- .../Plugins/TypeSystem/Clang/TypeSystemClang.cpp | 5 +- .../lldb/source/Symbol/CompileUnit.cpp | 11 +- .../llvm-project/lldb/source/Symbol/LineEntry.cpp | 23 +- .../llvm-project/lldb/source/Symbol/LineTable.cpp | 12 +- contrib/llvm-project/lldb/source/Symbol/Symbol.cpp | 17 +- .../lldb/source/Symbol/SymbolContext.cpp | 46 +- .../llvm-project/lldb/source/Target/Process.cpp | 10 +- contrib/llvm-project/lldb/source/Target/Target.cpp | 15 +- .../lldb/source/Target/TargetProperties.td | 2 +- contrib/llvm-project/lldb/source/Target/Thread.cpp | 15 +- .../llvm-project/lldb/source/Target/ThreadList.cpp | 10 +- .../lldb/source/Target/ThreadPlanStepOverRange.cpp | 12 +- .../lldb/source/Target/ThreadPlanStepRange.cpp | 4 +- .../lldb/source/Utility/Broadcaster.cpp | 5 +- .../llvm-project/lldb/source/Utility/FileSpec.cpp | 9 +- .../lldb/source/Utility/FileSpecList.cpp | 9 +- .../llvm-project/lldb/source/Utility/Stream.cpp | 17 +- .../llvm-project/lldb/source/Utility/XcodeSDK.cpp | 23 + contrib/llvm-project/lldb/tools/driver/Driver.cpp | 3 + .../lldb/tools/lldb-server/lldb-server.cpp | 4 +- .../llvm/include/llvm/ADT/APFixedPoint.h | 2 +- .../llvm/include/llvm/ADT/FunctionExtras.h | 7 +- .../llvm-project/llvm/include/llvm/ADT/Hashing.h | 4 +- .../llvm-project/llvm/include/llvm/ADT/SetVector.h | 2 +- .../llvm/include/llvm/ADT/SmallVector.h | 19 +- .../llvm/include/llvm/ADT/StringExtras.h | 2 +- .../llvm/include/llvm/Analysis/AliasAnalysis.h | 2 + .../llvm/include/llvm/Analysis/AliasSetTracker.h | 244 +- .../include/llvm/Analysis/BlockFrequencyInfoImpl.h | 5 +- .../include/llvm/Analysis/DOTGraphTraitsPass.h | 28 +- .../llvm/include/llvm/Analysis/RegionInfoImpl.h | 33 +- .../include/llvm/Analysis/TargetTransformInfo.h | 10 + .../llvm/Analysis/TargetTransformInfoImpl.h | 9 + .../llvm/include/llvm/Analysis/VecFuncs.def | 146 + .../llvm/include/llvm/Analysis/VectorUtils.h | 187 +- .../llvm/include/llvm/AsmParser/LLParser.h | 33 +- .../llvm/include/llvm/BinaryFormat/ELF.h | 2 + .../include/llvm/BinaryFormat/ELFRelocs/RISCV.def | 5 + .../llvm/include/llvm/BinaryFormat/MachO.def | 2 + .../llvm/include/llvm/BinaryFormat/Magic.h | 1 + .../llvm/include/llvm/BinaryFormat/Wasm.h | 396 +- .../llvm/include/llvm/BinaryFormat/WasmTraits.h | 5 +- .../llvm/include/llvm/Bitcode/BitcodeWriterPass.h | 10 +- .../llvm/include/llvm/CodeGen/AccelTable.h | 53 +- .../llvm/include/llvm/CodeGen/AsmPrinter.h | 4 - .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 210 +- .../llvm/include/llvm/CodeGen/CommandFlags.h | 3 + .../include/llvm/CodeGen/GlobalISel/CallLowering.h | 4 +- .../llvm/CodeGen/GlobalISel/GenericMachineInstrs.h | 19 +- .../include/llvm/CodeGen/GlobalISel/IRTranslator.h | 37 +- .../llvm/CodeGen/GlobalISel/LegalizerHelper.h | 16 - .../llvm/include/llvm/CodeGen/GlobalISel/Utils.h | 19 + .../llvm/include/llvm/CodeGen/GlobalMerge.h | 50 + .../llvm/include/llvm/CodeGen/MachineBasicBlock.h | 4 +- .../llvm/include/llvm/CodeGen/MachineOperand.h | 4 + .../llvm/include/llvm/CodeGen/MachineOutliner.h | 11 +- .../include/llvm/CodeGen/MachinePassRegistry.def | 3 +- .../llvm/include/llvm/CodeGen/MachinePipeliner.h | 18 +- .../llvm/include/llvm/CodeGen/MachineScheduler.h | 10 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 8 + .../llvm/include/llvm/CodeGen/StackMaps.h | 21 +- .../llvm/include/llvm/CodeGen/TargetLowering.h | 28 +- .../llvm/include/llvm/CodeGen/TargetPassConfig.h | 24 +- .../include/llvm/CodeGen/TargetSubtargetInfo.h | 4 + .../llvm/include/llvm/DWARFLinker/AddressesMap.h | 24 +- .../include/llvm/DWARFLinker/Classic/DWARFLinker.h | 45 +- .../llvm/DWARFLinker/Classic/DWARFStreamer.h | 18 +- .../include/llvm/DWARFLinker/DWARFLinkerBase.h | 47 + .../llvm/DWARFLinker}/IndexedValuesMap.h | 11 +- .../llvm/DWARFLinker/Parallel/DWARFLinker.h | 59 +- .../llvm/include/llvm/DebugInfo/DIContext.h | 1 + .../include/llvm/DebugInfo/DWARF/DWARFContext.h | 8 +- .../llvm/include/llvm/Debuginfod/Debuginfod.h | 14 + .../include/llvm/ExecutionEngine/JITLink/aarch32.h | 162 +- .../llvm/ExecutionEngine/Orc/MachOBuilder.h | 83 +- .../llvm/ExecutionEngine/Orc/MachOPlatform.h | 46 +- .../llvm/ExecutionEngine/RuntimeDyldChecker.h | 2 +- .../llvm/Frontend/Offloading/OffloadWrapper.h | 52 + .../include/llvm/Frontend/Offloading/Utility.h | 6 + .../llvm-project/llvm/include/llvm/IR/Attributes.h | 2 +- .../llvm/include/llvm/IR/CallingConv.h | 10 + .../llvm-project/llvm/include/llvm/IR/DebugInfo.h | 26 +- .../llvm/include/llvm/IR/DebugInfoMetadata.h | 4 + .../llvm/include/llvm/IR/DebugProgramInstruction.h | 109 +- .../llvm-project/llvm/include/llvm/IR/Function.h | 3 +- .../llvm/include/llvm/IR/GlobalObject.h | 1 + .../llvm/include/llvm/IR/GlobalValue.h | 3 +- .../llvm-project/llvm/include/llvm/IR/IRBuilder.h | 10 + .../llvm/include/llvm/IR/Instruction.h | 3 + .../llvm/include/llvm/IR/Intrinsics.td | 10 + .../llvm/include/llvm/IR/IntrinsicsAArch64.td | 36 +- .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 335 +- .../llvm/include/llvm/IR/IntrinsicsLoongArch.td | 13 + .../llvm/include/llvm/IR/IntrinsicsNVVM.td | 85 +- .../llvm/include/llvm/IR/IntrinsicsPowerPC.td | 5 + .../llvm/include/llvm/IR/IntrinsicsRISCV.td | 29 +- .../llvm-project/llvm/include/llvm/IR/Metadata.h | 87 +- .../llvm/include/llvm/IR/ModuleSummaryIndex.h | 2 +- .../llvm/include/llvm/IR/ProfileSummary.h | 8 +- .../llvm/include/llvm/IR/VFABIDemangler.h | 217 + .../llvm/include/llvm/IR/VPIntrinsics.def | 18 +- contrib/llvm-project/llvm/include/llvm/IR/Value.h | 15 +- .../llvm/include/llvm/MC/MCObjectWriter.h | 3 + .../llvm-project/llvm/include/llvm/MC/MCSymbol.h | 2 +- .../llvm/include/llvm/MC/MCSymbolWasm.h | 4 +- .../llvm/include/llvm/Object/COFFImportFile.h | 2 + .../llvm/include/llvm/Object/ELFObjectFile.h | 11 +- .../llvm-project/llvm/include/llvm/Object/MachO.h | 2 +- .../llvm/include/llvm/Object/OffloadBinary.h | 25 + .../llvm/include/llvm/Passes/PassBuilder.h | 132 +- .../llvm/ProfileData/Coverage/CoverageMapping.h | 18 +- .../llvm/include/llvm/ProfileData/SampleProf.h | 2 + .../llvm/include/llvm/Support/AMDGPUMetadata.h | 10 +- .../llvm/include/llvm/Support/FormatCommon.h | 4 +- .../llvm/include/llvm/Support/GenericDomTree.h | 7 +- .../llvm/include/llvm/Support/GenericLoopInfo.h | 18 +- .../include/llvm/Support/GenericLoopInfoImpl.h | 29 +- .../llvm-project/llvm/include/llvm/Support/JSON.h | 15 +- .../llvm/include/llvm/Support/MathExtras.h | 4 +- .../llvm/include/llvm/Support/RISCVAttributes.h | 2 +- .../llvm/include/llvm/Support/TargetOpcodes.def | 11 +- .../include/llvm/TableGen/StringToOffsetTable.h | 2 +- .../llvm/include/llvm/Target/CGPassBuilderOption.h | 2 +- .../llvm/include/llvm/Target/Target.td | 92 +- .../llvm/include/llvm/Target/TargetMachine.h | 3 + .../llvm/include/llvm/Target/TargetOptions.h | 17 +- .../llvm/include/llvm/Target/TargetPfmCounters.td | 7 + .../llvm/include/llvm/Target/TargetSchedule.td | 37 +- .../llvm/TargetParser/AArch64TargetParser.h | 135 +- .../include/llvm/TargetParser/ARMTargetParser.def | 5 + .../llvm/include/llvm/TargetParser/Triple.h | 25 +- .../include/llvm/TargetParser/X86TargetParser.def | 5 +- .../include/llvm/Transforms/IPO/EmbedBitcodePass.h | 16 +- .../llvm/Transforms/Instrumentation/CGProfile.h | 4 + .../llvm/Transforms/Scalar/ConstantHoisting.h | 1 + .../include/llvm/Transforms/Utils/ModuleUtils.h | 6 - .../llvm/Transforms/Utils/NameAnonGlobals.h | 2 + .../llvm/lib/Analysis/AliasAnalysis.cpp | 5 + .../llvm/lib/Analysis/AliasSetTracker.cpp | 338 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 25 +- .../llvm-project/llvm/lib/Analysis/InlineOrder.cpp | 2 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 23 +- .../llvm/lib/Analysis/ScalarEvolution.cpp | 4 + .../llvm/lib/Analysis/StackSafetyAnalysis.cpp | 2 +- .../llvm/lib/Analysis/TargetLibraryInfo.cpp | 9 +- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 5 + .../llvm/lib/Analysis/ValueTracking.cpp | 24 +- .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 93 +- .../llvm-project/llvm/lib/AsmParser/LLParser.cpp | 235 +- .../llvm-project/llvm/lib/BinaryFormat/Magic.cpp | 2 + .../llvm/lib/Bitcode/Reader/MetadataLoader.cpp | 37 +- .../llvm/lib/Bitcode/Writer/BitcodeWriterPass.cpp | 24 +- .../llvm/lib/Bitcode/Writer/ValueEnumerator.cpp | 4 +- .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 127 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 84 +- .../llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp | 12 +- .../lib/CodeGen/AssignmentTrackingAnalysis.cpp | 802 +- .../llvm/lib/CodeGen/BasicBlockSections.cpp | 10 +- .../CodeGen/BasicBlockSectionsProfileReader.cpp | 7 - .../llvm/lib/CodeGen/BranchFolding.cpp | 2 +- .../llvm/lib/CodeGen/CodeGenPrepare.cpp | 23 +- .../llvm-project/llvm/lib/CodeGen/CommandFlags.cpp | 8 + .../llvm/lib/CodeGen/ExpandVectorPredication.cpp | 2 + .../llvm/lib/CodeGen/GlobalISel/CallLowering.cpp | 42 +- .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 30 +- .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 214 +- .../lib/CodeGen/GlobalISel/InstructionSelect.cpp | 11 + .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 168 +- .../llvm/lib/CodeGen/GlobalISel/Utils.cpp | 147 + .../llvm-project/llvm/lib/CodeGen/GlobalMerge.cpp | 167 +- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.h | 4 +- .../llvm/lib/CodeGen/MachineCopyPropagation.cpp | 2 +- .../llvm/lib/CodeGen/MachineOperand.cpp | 13 + .../llvm/lib/CodeGen/MachineOutliner.cpp | 27 +- .../llvm/lib/CodeGen/MachinePipeliner.cpp | 482 +- .../llvm/lib/CodeGen/MachineScheduler.cpp | 37 +- .../llvm/lib/CodeGen/PatchableFunction.cpp | 52 +- .../llvm/lib/CodeGen/PreISelIntrinsicLowering.cpp | 5 +- contrib/llvm-project/llvm/lib/CodeGen/RDFGraph.cpp | 2 +- .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 31 +- .../llvm-project/llvm/lib/CodeGen/SafeStack.cpp | 22 +- .../llvm/lib/CodeGen/SelectOptimize.cpp | 408 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 10 + .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 5 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 3 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 9 +- .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 4 + .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 24 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 87 +- .../lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h | 4 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 30 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 8 +- .../llvm-project/llvm/lib/CodeGen/SlotIndexes.cpp | 2 +- .../llvm-project/llvm/lib/CodeGen/StackMaps.cpp | 42 +- .../llvm/lib/CodeGen/TargetLoweringBase.cpp | 4 +- .../llvm/lib/CodeGen/TargetPassConfig.cpp | 116 +- .../llvm/lib/CodeGen/TwoAddressInstructionPass.cpp | 13 +- .../llvm/lib/CodeGen/UnreachableBlockElim.cpp | 2 +- .../llvm/lib/DWARFLinker/Classic/DWARFLinker.cpp | 66 +- .../llvm/lib/DWARFLinker/Classic/DWARFStreamer.cpp | 90 +- .../llvm/lib/DWARFLinker/DWARFLinkerBase.cpp | 64 + .../lib/DWARFLinker/Parallel/DWARFEmitterImpl.cpp | 66 - .../lib/DWARFLinker/Parallel/DWARFEmitterImpl.h | 23 +- .../Parallel/DWARFLinkerCompileUnit.cpp | 20 +- .../DWARFLinker/Parallel/DWARFLinkerCompileUnit.h | 7 +- .../DWARFLinker/Parallel/DWARFLinkerGlobalData.h | 29 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.cpp | 98 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.h | 23 +- .../DWARFLinker/Parallel/DWARFLinkerTypeUnit.cpp | 12 +- .../lib/DWARFLinker/Parallel/DWARFLinkerTypeUnit.h | 2 +- .../lib/DWARFLinker/Parallel/DWARFLinkerUnit.h | 2 +- .../lib/DWARFLinker/Parallel/DependencyTracker.cpp | 4 +- .../lib/DWARFLinker/Parallel/OutputSections.cpp | 53 - .../llvm/lib/DWARFLinker/Parallel/OutputSections.h | 124 +- .../llvm/lib/DebugInfo/DWARF/DWARFCompileUnit.cpp | 10 +- .../llvm/lib/DebugInfo/DWARF/DWARFContext.cpp | 45 +- .../llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp | 2 +- .../llvm/lib/DebugInfo/DWARF/DWARFTypePrinter.cpp | 3 +- .../llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | 16 +- .../LogicalView/Readers/LVCodeViewReader.cpp | 4 +- .../llvm/lib/DebugInfo/Symbolize/MarkupFilter.cpp | 9 +- .../DebugInfo/Symbolize/SymbolizableObjectFile.cpp | 4 +- .../llvm/lib/DebugInfo/Symbolize/Symbolize.cpp | 8 +- .../llvm/lib/Debuginfod/Debuginfod.cpp | 36 +- .../llvm/lib/ExecutionEngine/ExecutionEngine.cpp | 4 +- .../ExecutionEngine/JITLink/ELFLinkGraphBuilder.h | 6 + .../lib/ExecutionEngine/JITLink/ELF_aarch32.cpp | 66 +- .../llvm/lib/ExecutionEngine/JITLink/aarch32.cpp | 286 +- .../llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | 6 + .../llvm/lib/ExecutionEngine/Orc/MachOPlatform.cpp | 60 +- .../Orc/TargetProcess/JITLoaderPerf.cpp | 2 +- .../RuntimeDyld/RuntimeDyldChecker.cpp | 27 +- .../RuntimeDyld/RuntimeDyldCheckerImpl.h | 3 +- .../llvm-project/llvm/lib/FileCheck/FileCheck.cpp | 61 +- .../llvm/lib/FileCheck/FileCheckImpl.h | 20 +- .../lib/Frontend/Offloading/OffloadWrapper.cpp | 620 + .../llvm/lib/Frontend/Offloading/Utility.cpp | 21 +- .../llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp | 7 +- contrib/llvm-project/llvm/lib/IR/AsmWriter.cpp | 28 +- contrib/llvm-project/llvm/lib/IR/AutoUpgrade.cpp | 305 +- contrib/llvm-project/llvm/lib/IR/BasicBlock.cpp | 19 +- contrib/llvm-project/llvm/lib/IR/ConstantFold.cpp | 49 +- contrib/llvm-project/llvm/lib/IR/DebugInfo.cpp | 258 +- .../llvm/lib/IR/DebugProgramInstruction.cpp | 190 +- contrib/llvm-project/llvm/lib/IR/Dominators.cpp | 5 +- contrib/llvm-project/llvm/lib/IR/Globals.cpp | 3 +- contrib/llvm-project/llvm/lib/IR/Instruction.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Instructions.cpp | 4 +- contrib/llvm-project/llvm/lib/IR/Metadata.cpp | 103 +- .../llvm-project/llvm/lib/IR/StructuralHash.cpp | 9 +- .../VFABIDemangling.cpp => IR/VFABIDemangler.cpp} | 133 +- contrib/llvm-project/llvm/lib/IR/Value.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 28 + .../llvm/lib/InterfaceStub/IFSHandler.cpp | 6 + .../llvm/lib/InterfaceStub/IFSStub.cpp | 3 +- contrib/llvm-project/llvm/lib/LTO/LTO.cpp | 2 +- .../llvm/lib/LTO/ThinLTOCodeGenerator.cpp | 6 +- .../llvm/lib/LineEditor/LineEditor.cpp | 2 +- .../llvm-project/llvm/lib/MC/ELFObjectWriter.cpp | 11 +- contrib/llvm-project/llvm/lib/MC/MCFragment.cpp | 2 +- .../llvm-project/llvm/lib/MC/MCObjectFileInfo.cpp | 4 + .../llvm/lib/MC/MCParser/DarwinAsmParser.cpp | 2 + contrib/llvm-project/llvm/lib/MC/MCStreamer.cpp | 9 + .../llvm-project/llvm/lib/MC/WasmObjectWriter.cpp | 2 +- .../llvm-project/llvm/lib/ObjCopy/CommonConfig.cpp | 6 +- contrib/llvm-project/llvm/lib/Object/Archive.cpp | 2 +- .../llvm-project/llvm/lib/Object/ArchiveWriter.cpp | 2 +- contrib/llvm-project/llvm/lib/Object/Binary.cpp | 1 + .../llvm/lib/Object/COFFImportFile.cpp | 80 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 4 + .../llvm-project/llvm/lib/Object/ObjectFile.cpp | 1 + .../llvm-project/llvm/lib/Object/OffloadBinary.cpp | 32 + .../llvm/lib/Object/RelocationResolver.cpp | 12 +- .../llvm/lib/Object/WasmObjectFile.cpp | 23 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 237 +- .../llvm/lib/Passes/PassBuilderPipelines.cpp | 20 +- .../llvm-project/llvm/lib/Passes/PassRegistry.def | 17 +- .../llvm/lib/Passes/StandardInstrumentations.cpp | 4 +- .../lib/ProfileData/Coverage/CoverageMapping.cpp | 52 +- contrib/llvm-project/llvm/lib/ProfileData/GCOV.cpp | 2 +- .../llvm/lib/ProfileData/InstrProf.cpp | 8 +- .../llvm/lib/Remarks/YAMLRemarkParser.cpp | 14 +- .../llvm/lib/Support/BalancedPartitioning.cpp | 16 +- contrib/llvm-project/llvm/lib/Support/Caching.cpp | 4 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 37 +- .../llvm/lib/Support/FileCollector.cpp | 2 +- .../llvm/lib/Support/FormatVariadic.cpp | 3 +- .../llvm-project/llvm/lib/Support/GraphWriter.cpp | 2 +- contrib/llvm-project/llvm/lib/Support/InitLLVM.cpp | 5 + .../llvm/lib/Support/LockFileManager.cpp | 8 +- contrib/llvm-project/llvm/lib/Support/Path.cpp | 4 +- contrib/llvm-project/llvm/lib/Support/Process.cpp | 2 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 22 +- .../llvm-project/llvm/lib/Support/SmallVector.cpp | 3 +- .../llvm-project/llvm/lib/Support/StringRef.cpp | 15 +- contrib/llvm-project/llvm/lib/Support/Unicode.cpp | 342 +- .../llvm/lib/Support/UnicodeCaseFold.cpp | 13 +- .../llvm/lib/Support/UnicodeNameToCodepoint.cpp | 3 +- .../Support/UnicodeNameToCodepointGenerated.cpp | 39628 ++++++++++--------- .../llvm-project/llvm/lib/Support/Unix/Program.inc | 2 +- .../llvm-project/llvm/lib/Support/VersionTuple.cpp | 6 +- .../llvm/lib/Support/VirtualFileSystem.cpp | 12 +- .../llvm-project/llvm/lib/Support/Windows/Path.inc | 41 +- .../llvm-project/llvm/lib/Target/AArch64/AArch64.h | 2 + .../llvm/lib/Target/AArch64/AArch64.td | 3 +- .../Target/AArch64/AArch64Arm64ECCallLowering.cpp | 769 + .../llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp | 77 + .../lib/Target/AArch64/AArch64CallingConvention.h | 16 + .../lib/Target/AArch64/AArch64CallingConvention.td | 128 + .../llvm/lib/Target/AArch64/AArch64Combine.td | 11 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 18 +- .../llvm/lib/Target/AArch64/AArch64FastISel.cpp | 3 + .../lib/Target/AArch64/AArch64FrameLowering.cpp | 26 + .../lib/Target/AArch64/AArch64GlobalsTagging.cpp | 26 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 62 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 524 +- .../llvm/lib/Target/AArch64/AArch64ISelLowering.h | 16 +- .../llvm/lib/Target/AArch64/AArch64InstrGISel.td | 30 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 68 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.td | 131 +- .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 11 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.cpp | 55 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.h | 3 + .../Target/AArch64/AArch64MachineFunctionInfo.h | 7 + .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 3 + .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 10 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 4 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.cpp | 19 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.h | 5 +- .../lib/Target/AArch64/AArch64SystemOperands.td | 2 + .../lib/Target/AArch64/AArch64TargetMachine.cpp | 8 +- .../lib/Target/AArch64/AArch64TargetObjectFile.cpp | 10 + .../lib/Target/AArch64/AArch64TargetObjectFile.h | 7 + .../Target/AArch64/AArch64TargetTransformInfo.cpp | 69 +- .../Target/AArch64/AArch64TargetTransformInfo.h | 2 + .../Target/AArch64/AsmParser/AArch64AsmParser.cpp | 24 +- .../Target/AArch64/GISel/AArch64CallLowering.cpp | 24 +- .../AArch64/GISel/AArch64InstructionSelector.cpp | 9 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 66 +- .../AArch64/GISel/AArch64PreLegalizerCombiner.cpp | 222 +- .../llvm/lib/Target/AArch64/SMEABIPass.cpp | 132 +- .../lib/Target/AArch64/Utils/AArch64BaseInfo.h | 39 +- .../Target/AArch64/Utils/AArch64SMEAttributes.cpp | 53 +- .../Target/AArch64/Utils/AArch64SMEAttributes.h | 78 +- .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.h | 3 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 54 +- .../llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp | 26 +- .../llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUCallLowering.cpp | 17 +- .../llvm/lib/Target/AMDGPU/AMDGPUGISel.td | 16 +- .../Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 21 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 35 + .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.h | 8 + .../Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp | 38 +- .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 28 +- .../lib/Target/AMDGPU/AMDGPUInstructionSelector.h | 6 +- .../llvm/lib/Target/AMDGPU/AMDGPUInstructions.td | 3 + .../lib/Target/AMDGPU/AMDGPULateCodeGenPrepare.cpp | 10 + .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 63 +- .../Target/AMDGPU/AMDGPULowerKernelArguments.cpp | 3 +- .../Target/AMDGPU/AMDGPULowerKernelAttributes.cpp | 5 +- .../Target/AMDGPU/AMDGPUMachineCFGStructurizer.cpp | 2 +- .../Target/AMDGPU/AMDGPUMarkLastScratchLoad.cpp | 142 + .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 6 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 42 +- .../AMDGPU/AMDGPURemoveIncompatibleFunctions.cpp | 3 +- .../Target/AMDGPU/AMDGPUResourceUsageAnalysis.cpp | 2 +- .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 10 + .../llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 3 + .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 144 +- .../llvm/lib/Target/AMDGPU/BUFInstructions.td | 96 +- .../llvm/lib/Target/AMDGPU/DSInstructions.td | 41 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 7 +- .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 189 +- .../llvm/lib/Target/AMDGPU/GCNDPPCombine.cpp | 28 +- .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 31 +- .../llvm/lib/Target/AMDGPU/GCNNSAReassign.cpp | 2 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 49 +- .../AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp | 14 +- .../AMDGPU/MCTargetDesc/AMDGPUELFObjectWriter.cpp | 19 +- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 17 +- .../AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.cpp | 43 +- .../AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h | 4 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp | 134 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.h | 59 +- .../llvm/lib/Target/AMDGPU/MIMGInstructions.td | 5 + .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 13 +- .../lib/Target/AMDGPU/SIAnnotateControlFlow.cpp | 7 +- .../llvm/lib/Target/AMDGPU/SIDefines.h | 10 +- .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 14 +- .../llvm/lib/Target/AMDGPU/SIFrameLowering.cpp | 7 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 262 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 3 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 1095 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 44 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 41 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 291 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 24 +- .../llvm/lib/Target/AMDGPU/SILowerSGPRSpills.cpp | 12 +- .../lib/Target/AMDGPU/SIMachineFunctionInfo.cpp | 54 +- .../llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | 25 +- .../llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp | 180 + .../llvm/lib/Target/AMDGPU/SIModeRegister.cpp | 2 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp | 9 +- .../llvm/lib/Target/AMDGPU/SMInstructions.td | 77 +- .../llvm/lib/Target/AMDGPU/SOPInstructions.td | 47 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 233 +- .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 154 +- .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 8 +- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 45 +- .../llvm/lib/Target/AMDGPU/VOP3Instructions.td | 4 +- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 83 +- .../llvm/lib/Target/AMDGPU/VOPCInstructions.td | 44 +- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 19 +- contrib/llvm-project/llvm/lib/Target/ARM/ARM.td | 18 + .../llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp | 19 +- .../llvm/lib/Target/ARM/ARMCallLowering.cpp | 6 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 11 +- .../llvm/lib/Target/ARM/ARMInstrMVE.td | 2 +- .../llvm/lib/Target/ARM/ARMSubtarget.h | 1 + .../llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp | 14 +- .../lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp | 20 +- .../lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp | 1 + .../lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h | 2 +- .../lib/Target/ARM/MVEGatherScatterLowering.cpp | 4 +- .../llvm/lib/Target/ARM/Thumb1InstrInfo.cpp | 4 +- .../llvm/lib/Target/ARM/Thumb2InstrInfo.cpp | 6 +- .../Hexagon/Disassembler/HexagonDisassembler.cpp | 2 + .../llvm/lib/Target/Hexagon/HexagonEarlyIfConv.cpp | 4 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 3 +- .../lib/Target/Hexagon/HexagonVectorCombine.cpp | 3 +- .../Hexagon/MCTargetDesc/HexagonMCInstrInfo.cpp | 6 +- .../llvm/lib/Target/LoongArch/LoongArch.td | 12 + .../Target/LoongArch/LoongArchFloat32InstrInfo.td | 8 + .../Target/LoongArch/LoongArchFloat64InstrInfo.td | 8 + .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 8 + .../lib/Target/LoongArch/LoongArchInstrInfo.td | 34 +- .../lib/Target/LoongArch/LoongArchLASXInstrInfo.td | 58 + .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 30 + .../llvm/lib/Target/LoongArch/LoongArchSubtarget.h | 4 + .../LoongArch/LoongArchTargetTransformInfo.cpp | 18 + .../LoongArch/LoongArchTargetTransformInfo.h | 2 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 196 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 20 + .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 2 + .../llvm/lib/Target/Mips/MipsAsmPrinter.cpp | 5 +- .../llvm/lib/Target/Mips/MipsCallLowering.cpp | 2 +- .../llvm/lib/Target/Mips/MipsRegisterBankInfo.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 24 + .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 50 +- *** 132333 LINES SKIPPED *** From nobody Sat Apr 20 10:32:25 2024 X-Original-To: dev-commits-src-branches@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 4VM7B21F1qz5HW0h; Sat, 20 Apr 2024 10:32:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B16mqyz4Pgx; Sat, 20 Apr 2024 10:32:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609146; 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=aYgAng5bkAzYVXyA5lpRqy+fJyUsM/Ee8jiyoriSddo=; b=XzfebjYt3EuUXYHq69DURHDG8z3BvUkUvQN86ZayFAv8kOlTlikkJQIQzJqphtVtluOgJv 0f6R0vYxnZLvMgHdMhD/o/MvZVEMI1F8bFVnptGeXl8eZdEvFStvfahZQY4eyqcamjRshM Fyf+K5lFLhD4G2/Q9UpAtatH8KVABShDUJL3hroQyAeFGco9NvZ6WF3lr+jqf9F9j/qpnZ Y5G2eIkTVkauKfgXAc9m3/zB59wOxSrvXeM0Qmv2gYxRdW/Hr3+SBr2YhIapceHQxzrzrq 6kSCiN2xdhG0WUIiJbTgcPUW/CQ757mqDjKD+HzJrLbw22b0YT7+q9oYodsofw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609145; a=rsa-sha256; cv=none; b=CJMQf8yfAWdxEVP3WjCRWDRvxwOgf7VmO7Ry+oVZ+H6XurZMvZHvxDUfP7SKOWERjmL3CZ /AkDAGtcYhHmuW4KeiQErdugeuAT0f9eVFPSph7hjyYEk5wb1FZRm+dKv2v5dh/YgVnZMk Cc141hMK2HOrBhkMcx7D8yruI4qQ1r2wuFL57jbL6pJ0wdTGB1zWwyuRRKyVaGt8WanrJF AsNJxwsYHNPFIaI8La2jypjq3Ag5u/Bt6XaJXWfO8bgEcCezCc+dQ1H211MHsenq3B1dHz K5w95CDoFVPQwoeS9TbRnfh5D2Z8DIu251LYKzGCBzgb/e+2RTgR0PSczsEOgw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609145; 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=aYgAng5bkAzYVXyA5lpRqy+fJyUsM/Ee8jiyoriSddo=; b=WC0iATx3rcgWxv6+dZyzDMzUpTVpq36UhrlxV5RUwPOMQQoGgBsGkKGomybGTwzv90MnBc 6AAbycD5qvaElGn7BUaiqPBI9Gagmfh5w0TrwVbEgbUBYqQbtiV27s60jtvCrWM+aBl4J3 ibzuBJb6WjHd1Dw6Y5PazGWwZYXe/fXLZCsdj/gu4DpHaO4EJ9osZipo5qeMnvDtNAX8TB vxIulc3K/QRNEqmcMwRGcI2NyhbdNtruMGnXCaUHjXMEyANaKdOsNM4LcLfZEEH0IcqRAb aDO9atnur2jMMCTf7MN2MadXQw8mcuU2BdN+d47aNsLPwkm8oc5sAbQT6DGvaA== 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 4VM7B16KBgzYk3; Sat, 20 Apr 2024 10:32:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWPJ7011017; Sat, 20 Apr 2024 10:32:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWP6m011014; Sat, 20 Apr 2024 10:32:25 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:25 GMT Message-Id: <202404201032.43KAWP6m011014@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: 3f37aa84be74 - stable/14 - Tentatively apply https://github.com/libcxxrt/libcxxrt/pull/27 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 3f37aa84be749be0963b388a02cdc58b4f1c7246 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=3f37aa84be749be0963b388a02cdc58b4f1c7246 commit 3f37aa84be749be0963b388a02cdc58b4f1c7246 Author: Dimitry Andric AuthorDate: 2024-01-26 15:03:20 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:14 +0000 Tentatively apply https://github.com/libcxxrt/libcxxrt/pull/27 This marks __cxa_allocate_exception, __cxa_free_exception and __cxa_init_primary_exception noexcept, to ensure compatibility with libc++'s declarations. PR: 276104 MFC after: 1 month (cherry picked from commit 3fb2e045791eb6f003205902cdc4f74702770ec6) --- contrib/libcxxrt/cxxabi.h | 6 +++--- contrib/libcxxrt/exception.cc | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/contrib/libcxxrt/cxxabi.h b/contrib/libcxxrt/cxxabi.h index e021f85c905a..ef4076a08a0a 100644 --- a/contrib/libcxxrt/cxxabi.h +++ b/contrib/libcxxrt/cxxabi.h @@ -204,12 +204,12 @@ __cxa_eh_globals *__cxa_get_globals_fast(void); std::type_info * __cxa_current_exception_type(); -void *__cxa_allocate_exception(size_t thrown_size); +void *__cxa_allocate_exception(size_t thrown_size) throw(); -void __cxa_free_exception(void* thrown_exception); +void __cxa_free_exception(void* thrown_exception) throw(); __cxa_exception *__cxa_init_primary_exception( - void *object, std::type_info* tinfo, void (*dest)(void *)); + void *object, std::type_info* tinfo, void (*dest)(void *)) throw(); /** * Throws an exception returned by __cxa_current_primary_exception(). This diff --git a/contrib/libcxxrt/exception.cc b/contrib/libcxxrt/exception.cc index b1659c902f56..35ff997dd445 100644 --- a/contrib/libcxxrt/exception.cc +++ b/contrib/libcxxrt/exception.cc @@ -121,7 +121,7 @@ static inline _Unwind_Reason_Code continueUnwinding(struct _Unwind_Exception *ex } -extern "C" void __cxa_free_exception(void *thrown_exception); +extern "C" void __cxa_free_exception(void *thrown_exception) throw(); extern "C" void __cxa_free_dependent_exception(void *thrown_exception); extern "C" void* __dynamic_cast(const void *sub, const __class_type_info *src, @@ -611,7 +611,7 @@ static void free_exception(char *e) * emergency buffer if malloc() fails, and may block if there are no such * buffers available. */ -extern "C" void *__cxa_allocate_exception(size_t thrown_size) +extern "C" void *__cxa_allocate_exception(size_t thrown_size) throw() { size_t size = thrown_size + sizeof(__cxa_exception); char *buffer = alloc_or_die(size); @@ -633,7 +633,7 @@ extern "C" void *__cxa_allocate_dependent_exception(void) * In this implementation, it is also called by __cxa_end_catch() and during * thread cleanup. */ -extern "C" void __cxa_free_exception(void *thrown_exception) +extern "C" void __cxa_free_exception(void *thrown_exception) throw() { __cxa_exception *ex = reinterpret_cast<__cxa_exception*>(thrown_exception) - 1; // Free the object that was thrown, calling its destructor @@ -794,7 +794,7 @@ static void throw_exception(__cxa_exception *ex) } extern "C" __cxa_exception *__cxa_init_primary_exception( - void *object, std::type_info* tinfo, void (*dest)(void *)) { + void *object, std::type_info* tinfo, void (*dest)(void *)) throw() { __cxa_exception *ex = reinterpret_cast<__cxa_exception*>(object) - 1; ex->referenceCount = 0; From nobody Sat Apr 20 10:32:26 2024 X-Original-To: dev-commits-src-branches@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 4VM7B31xWzz5HVtY; Sat, 20 Apr 2024 10:32:27 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B30V0sz4PSc; Sat, 20 Apr 2024 10:32:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609147; 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=fJaKu9Xu+A62eHQI1RHxLt6D9QWFf+2wo1v/zuMestk=; b=nzJzxXXCOkMKHgl1z/gG32h4o9Ln0xmwhXXL6WohGSrbsfyt15YgjbwVagqrmHTIsNq4sS RyNnrfwfdNaI05JhIUA7blZkNU+nllO0Or93tarJ0SngLftiwzZk6Tqw4bvSONo4bqq26O VsCCtNhOWDnGIgUdHIjzEDJjELFFh/kn0in38DpH9Fp8JCq6kB0YRsNlPcygKCfZI9+zyK 0qfbf1Yd4+Ov5JpbsDjDKH+6V7QR5AoarFLUaXra1phtT5xJfFPKv3wzQWxu9KQwDs7aZy 6ZbP0wAiiaZJgcvyhiQXWzDHDqCA69PPYOo97h1grj8tCKiKqMSWeGQVjoIjYg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609147; a=rsa-sha256; cv=none; b=foOZXQcJrP8HJ/H8ujeoS5UfsM+AlIDxDQsF849hPbI+z3xJNbGzIh2nx8I1jW33nAsPr2 yjMU1EtRFF4/1aTUps7jS9KMpyNxir0whH2u0s/Dtsg4d17v/lXxbQ8ZEd4B7IgV0kyO4B znN+9KB4hRjep82rxpNfhSBkmnn6YzP40D7EfbV+ZoiQz/evnrIWMSpTJx5IODh0VOgQg1 nDFKyjBJ+wUINCQvKVIh0BmRmzbdcDwmYo8QeAH38N1pmOD0Cof+Nj3maxwJb0ZM3xvxPo TcxwOdlosfTjKbB/wa4TBJ2/MOvgHNzR1Bx5+gTRWjKPU8a8DXORb3AjYqlpdA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609147; 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=fJaKu9Xu+A62eHQI1RHxLt6D9QWFf+2wo1v/zuMestk=; b=jPGSqHWQJGGdcaDTbH4W9/ofJumnT0y/V2HcgQMK0OMJFg4Ua11iADCEliUH+jLsmCReKk n5rlumdJmZD1OaCJoGrRSAr4hrqbl5t2vWyiQFquUdWkrMF/4F2ZkU77qYWNKpHAAp5wWk Lf1FMy3dYqZCqTHWAAgVcA+irjgUtp0TwbQTQJI7AcNk3P+041wDZiE52pdn0t9Pu6ZXr1 /ZlZcyqojxOp1MG1kOG8RcUk4jxgv6DUOmUmqPpTJQDKAWw2/V4sIyjPKXg4mDWm48LtVy FqyBXeZ+ajVQr+N8a6bDjVBBQRWJqH4hcejgW4N56036uzgdLU3VsVbBYZHSZg== 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 4VM7B306MMzYh9; Sat, 20 Apr 2024 10:32:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWQRh011057; Sat, 20 Apr 2024 10:32:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWQCw011054; Sat, 20 Apr 2024 10:32:26 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:26 GMT Message-Id: <202404201032.43KAWQCw011054@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: 3f2e8ce1cfdd - stable/14 - Merge llvm-project release/18.x llvmorg-18-init-18361-g22683463740e List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 3f2e8ce1cfdd2f41cd69da9166d3ecb0d299ad4d Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=3f2e8ce1cfdd2f41cd69da9166d3ecb0d299ad4d commit 3f2e8ce1cfdd2f41cd69da9166d3ecb0d299ad4d Author: Dimitry Andric AuthorDate: 2024-01-26 15:04:14 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:14 +0000 Merge llvm-project release/18.x llvmorg-18-init-18361-g22683463740e This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18-init-18361-g22683463740e. PR: 276104 MFC after: 1 month (cherry picked from commit 878ed4957e077721efaf90ab5b70dce86dc94f4b) --- contrib/llvm-project/libcxx/include/__config | 2 +- lib/clang/include/VCSVersion.inc | 6 +++--- lib/clang/include/clang/Basic/Version.inc | 6 +++--- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +++--- lib/clang/include/llvm/Config/config.h | 4 ++-- lib/clang/include/llvm/Config/llvm-config.h | 4 ++-- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 2eada10e96ce..8248cf3d2239 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -64,7 +64,7 @@ // _LIBCPP_VERSION represents the version of libc++, which matches the version of LLVM. // Given a LLVM release LLVM XX.YY.ZZ (e.g. LLVM 17.0.1 == 17.00.01), _LIBCPP_VERSION is // defined to XXYYZZ. -# define _LIBCPP_VERSION 180000 +# define _LIBCPP_VERSION 180100 # define _LIBCPP_CONCAT_IMPL(_X, _Y) _X##_Y # define _LIBCPP_CONCAT(_X, _Y) _LIBCPP_CONCAT_IMPL(_X, _Y) diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index c4390452d813..ca4f5d50df14 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLVM_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define CLANG_REVISION "llvmorg-18-init-18361-g22683463740e" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLDB_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/clang/Basic/Version.inc b/lib/clang/include/clang/Basic/Version.inc index adf6c5966121..26d6b3b2938f 100644 --- a/lib/clang/include/clang/Basic/Version.inc +++ b/lib/clang/include/clang/Basic/Version.inc @@ -1,8 +1,8 @@ -#define CLANG_VERSION 18.0.0git -#define CLANG_VERSION_STRING "18.0.0git" +#define CLANG_VERSION 18.1.0rc +#define CLANG_VERSION_STRING "18.1.0rc" #define CLANG_VERSION_MAJOR 18 #define CLANG_VERSION_MAJOR_STRING "18" -#define CLANG_VERSION_MINOR 0 +#define CLANG_VERSION_MINOR 1 #define CLANG_VERSION_PATCHLEVEL 0 #define CLANG_VENDOR "FreeBSD " diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index 1ffb3458abd0..ff41eaf5ebbe 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400006 -#define LLD_VERSION_STRING "18.0.0 (FreeBSD llvmorg-18-init-18359-g93248729cfae-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18-init-18361-g22683463740e-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/lldb/Version/Version.inc b/lib/clang/include/lldb/Version/Version.inc index c5e07a4eefbd..7a9546b4696f 100644 --- a/lib/clang/include/lldb/Version/Version.inc +++ b/lib/clang/include/lldb/Version/Version.inc @@ -1,6 +1,6 @@ -#define LLDB_VERSION 18.0.0git -#define LLDB_VERSION_STRING "18.0.0git" +#define LLDB_VERSION 18.1.0rc +#define LLDB_VERSION_STRING "18.1.0rc" #define LLDB_VERSION_MAJOR 18 -#define LLDB_VERSION_MINOR 0 +#define LLDB_VERSION_MINOR 1 #define LLDB_VERSION_PATCH 0 /* #undef LLDB_FULL_VERSION_STRING */ diff --git a/lib/clang/include/llvm/Config/config.h b/lib/clang/include/llvm/Config/config.h index fdc104e49231..718c44fff94d 100644 --- a/lib/clang/include/llvm/Config/config.h +++ b/lib/clang/include/llvm/Config/config.h @@ -344,10 +344,10 @@ #define PACKAGE_NAME "LLVM" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "LLVM 18.0.0git" +#define PACKAGE_STRING "LLVM 18.1.0rc" /* Define to the version of this package. */ -#define PACKAGE_VERSION "18.0.0git" +#define PACKAGE_VERSION "18.1.0rc" /* Define to the vendor of this package. */ /* #undef PACKAGE_VENDOR */ diff --git a/lib/clang/include/llvm/Config/llvm-config.h b/lib/clang/include/llvm/Config/llvm-config.h index f3555d0868e2..111e0a296ed5 100644 --- a/lib/clang/include/llvm/Config/llvm-config.h +++ b/lib/clang/include/llvm/Config/llvm-config.h @@ -177,13 +177,13 @@ #define LLVM_VERSION_MAJOR 18 /* Minor version of the LLVM API */ -#define LLVM_VERSION_MINOR 0 +#define LLVM_VERSION_MINOR 1 /* Patch version of the LLVM API */ #define LLVM_VERSION_PATCH 0 /* LLVM version string */ -#define LLVM_VERSION_STRING "18.0.0git" +#define LLVM_VERSION_STRING "18.1.0rc" /* Whether LLVM records statistics for use with GetStatistics(), * PrintStatistics() or PrintStatisticsJSON() diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index 7cc55b62be19..fa5c1df71357 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLVM_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" From nobody Sat Apr 20 10:32:28 2024 X-Original-To: dev-commits-src-branches@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 4VM7B44K99z5HVx7; Sat, 20 Apr 2024 10:32:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B41hKWz4Pmd; Sat, 20 Apr 2024 10:32:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609148; 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=LEz3TnHnaMO+z2GRKcaEHahK3CXQ1VbdU3JOHBaprDY=; b=sJjwcXaDOHCkuypQS6saqjwOP4uUIU9PofqDbT9n7WuxV9wYmMu/mr7R2m/2NCr2xCyC1r Aq6KMX/HtlHGzSjcbBKapEWU6rdC1MTOrjcc1D02XMaA0MCLTzUd5JFIkm3bO1CE62oaMe 06DSfeJ6hZwDDBp7aS0V/gc3wvJ6JDnEZELCkmAiqQmCuIuEgRavUDACyBeFlbXxrjtD16 7gRO41U0OhbK+wXVZ1EV/ECxoP/1YlWft+N3BpRaLbjWy3f6UOd9fPE+5fpM0Kv4bMgjwm CY4OcqrE0FES47hQyjBDsmyQxPhpDa5boQVIvrx2AEk4MoZNvCgvWIPtneDfuQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609148; a=rsa-sha256; cv=none; b=DM7TMLOphME7UtjXdbfBRKzGqsSRFP8/tZ1xv2Gzc4FAkUhrFSXeQrMI7wKE2R5cFwR8DW adbTS/z9k9LxBb4k+W/QeJLZhR2JAvRz/S01Lwcu0OHrcQOzAy2iR3KhAz9RyIQw2pg7v3 v8p7HL8w2schmEefNjdjsarMF7yDf9OF/vvRqowUi+V/J5D0fy1/aw44bDojiES4b/gZGY nzDqG+FPA9seEt7EO3Sa0QrRK9cNq3jZanXoaPp3qYR5jw2sG02OhSZSW+tB+rxtsWXdta DYtT1HPhbXTpCTWj/PLgsAVXUIYJ7/XixDagVnG5w8ZjziZIcwTQfUGFHA6uPQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609148; 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=LEz3TnHnaMO+z2GRKcaEHahK3CXQ1VbdU3JOHBaprDY=; b=NobchxZ02vJoUlEN2XjX3cFoF0cbyzBXRdR7EceQaqBAHLqKMrg0U+SkLOLIvOajsHUlxc uXbqQVPGYGLvFJqCTKoAUJ+JQLkagy2yukf1qZsSZJb3yKSzM78rwALYDm63WPtL/hLAkG S2oSDyZV++GfgveFMgD2caZXkCmcUEETcDhdm2+suqNhiHOD5+X74UcKlOp2ZP1OhslWZz X0exx0nzRwk6gyH3K7oC9SZ0a/93izgh5Eo329dx+vknSNyqBALRTrREgHGvhmC7Zgl7Qt +4aOYY6WkpY1uT4yMsoByvSFuomZqPFZVQ+WHcgS5z2dbf6TQM7Da1YtpUc1oQ== 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 4VM7B41HpSzYm9; Sat, 20 Apr 2024 10:32:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWSTs011108; Sat, 20 Apr 2024 10:32:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWSqR011105; Sat, 20 Apr 2024 10:32:28 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:28 GMT Message-Id: <202404201032.43KAWSqR011105@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: f8981b8ce216 - stable/14 - Merge commit 6e4930c67508 from llvm-project (by Alexander Kornienko): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: f8981b8ce216ab440cfb6497f5a672519e0b5880 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=f8981b8ce216ab440cfb6497f5a672519e0b5880 commit f8981b8ce216ab440cfb6497f5a672519e0b5880 Author: Dimitry Andric AuthorDate: 2024-01-28 20:34:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:15 +0000 Merge commit 6e4930c67508 from llvm-project (by Alexander Kornienko): Revert "[SemaCXX] Implement CWG2137 (list-initialization from objects of the same type) (#77768)" This reverts commit 924701311aa79180e86ad8ce43d253f27d25ec7d. Causes compilation errors on valid code, see https://github.com/llvm/llvm-project/pull/77768#issuecomment-1908062472. In particular, this fixes bogus "call to constructor of 'SomeType' is ambiguous" errors. PR: 276104 MFC after: 1 month (cherry picked from commit ddbac700c256bec42c441b75a5cb5f74e9be601f) --- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 40 ++++++---------------- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 38 ++++++-------------- 2 files changed, 20 insertions(+), 58 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp b/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp index 91e4cb7b68a2..457fa377355a 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp @@ -4200,7 +4200,7 @@ static OverloadingResult ResolveConstructorOverload( /// \param IsListInit Is this list-initialization? /// \param IsInitListCopy Is this non-list-initialization resulting from a /// list-initialization from {x} where x is the same -/// aggregate type as the entity? +/// type as the entity? static void TryConstructorInitialization(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, @@ -4230,14 +4230,6 @@ static void TryConstructorInitialization(Sema &S, Entity.getKind() != InitializedEntity::EK_LambdaToBlockConversionBlockElement); - bool CopyElisionPossible = false; - auto ElideConstructor = [&] { - // Convert qualifications if necessary. - Sequence.AddQualificationConversionStep(DestType, VK_PRValue); - if (ILE) - Sequence.RewrapReferenceInitList(DestType, ILE); - }; - // C++17 [dcl.init]p17: // - If the initializer expression is a prvalue and the cv-unqualified // version of the source type is the same class as the class of the @@ -4250,17 +4242,11 @@ static void TryConstructorInitialization(Sema &S, if (S.getLangOpts().CPlusPlus17 && !RequireActualConstructor && UnwrappedArgs.size() == 1 && UnwrappedArgs[0]->isPRValue() && S.Context.hasSameUnqualifiedType(UnwrappedArgs[0]->getType(), DestType)) { - if (ILE && !DestType->isAggregateType()) { - // CWG2311: T{ prvalue_of_type_T } is not eligible for copy elision - // Make this an elision if this won't call an initializer-list - // constructor. (Always on an aggregate type or check constructors first.) - assert(!IsInitListCopy && - "IsInitListCopy only possible with aggregate types"); - CopyElisionPossible = true; - } else { - ElideConstructor(); - return; - } + // Convert qualifications if necessary. + Sequence.AddQualificationConversionStep(DestType, VK_PRValue); + if (ILE) + Sequence.RewrapReferenceInitList(DestType, ILE); + return; } const RecordType *DestRecordType = DestType->getAs(); @@ -4305,12 +4291,6 @@ static void TryConstructorInitialization(Sema &S, S, Kind.getLocation(), Args, CandidateSet, DestType, Ctors, Best, CopyInitialization, AllowExplicit, /*OnlyListConstructors=*/true, IsListInit, RequireActualConstructor); - - if (CopyElisionPossible && Result == OR_No_Viable_Function) { - // No initializer list candidate - ElideConstructor(); - return; - } } // C++11 [over.match.list]p1: @@ -4592,9 +4572,9 @@ static void TryListInitialization(Sema &S, return; } - // C++11 [dcl.init.list]p3, per DR1467 and DR2137: - // - If T is an aggregate class and the initializer list has a single element - // of type cv U, where U is T or a class derived from T, the object is + // C++11 [dcl.init.list]p3, per DR1467: + // - If T is a class type and the initializer list has a single element of + // type cv U, where U is T or a class derived from T, the object is // initialized from that element (by copy-initialization for // copy-list-initialization, or by direct-initialization for // direct-list-initialization). @@ -4605,7 +4585,7 @@ static void TryListInitialization(Sema &S, // - Otherwise, if T is an aggregate, [...] (continue below). if (S.getLangOpts().CPlusPlus11 && InitList->getNumInits() == 1 && !IsDesignatedInit) { - if (DestType->isRecordType() && DestType->isAggregateType()) { + if (DestType->isRecordType()) { QualType InitType = InitList->getInit(0)->getType(); if (S.Context.hasSameUnqualifiedType(InitType, DestType) || S.IsDerivedFrom(InitList->getBeginLoc(), InitType, DestType)) { diff --git a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp index 030878899b81..c9eb67898356 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp @@ -1568,37 +1568,19 @@ TryUserDefinedConversion(Sema &S, Expr *From, QualType ToType, // called for those cases. if (CXXConstructorDecl *Constructor = dyn_cast(ICS.UserDefined.ConversionFunction)) { - QualType FromType; - SourceLocation FromLoc; - // C++11 [over.ics.list]p6, per DR2137: - // C++17 [over.ics.list]p6: - // If C is not an initializer-list constructor and the initializer list - // has a single element of type cv U, where U is X or a class derived - // from X, the implicit conversion sequence has Exact Match rank if U is - // X, or Conversion rank if U is derived from X. - if (const auto *InitList = dyn_cast(From); - InitList && InitList->getNumInits() == 1 && - !S.isInitListConstructor(Constructor)) { - const Expr *SingleInit = InitList->getInit(0); - FromType = SingleInit->getType(); - FromLoc = SingleInit->getBeginLoc(); - } else { - FromType = From->getType(); - FromLoc = From->getBeginLoc(); - } - QualType FromCanon = - S.Context.getCanonicalType(FromType.getUnqualifiedType()); + QualType FromCanon + = S.Context.getCanonicalType(From->getType().getUnqualifiedType()); QualType ToCanon = S.Context.getCanonicalType(ToType).getUnqualifiedType(); if (Constructor->isCopyConstructor() && (FromCanon == ToCanon || - S.IsDerivedFrom(FromLoc, FromCanon, ToCanon))) { + S.IsDerivedFrom(From->getBeginLoc(), FromCanon, ToCanon))) { // Turn this into a "standard" conversion sequence, so that it // gets ranked with standard conversion sequences. DeclAccessPair Found = ICS.UserDefined.FoundConversionFunction; ICS.setStandard(); ICS.Standard.setAsIdentityConversion(); - ICS.Standard.setFromType(FromType); + ICS.Standard.setFromType(From->getType()); ICS.Standard.setAllToTypes(ToType); ICS.Standard.CopyConstructor = Constructor; ICS.Standard.FoundCopyConstructor = Found; @@ -5324,18 +5306,18 @@ TryListConversion(Sema &S, InitListExpr *From, QualType ToType, IsDesignatedInit) return Result; - // Per DR1467 and DR2137: - // If the parameter type is an aggregate class X and the initializer list - // has a single element of type cv U, where U is X or a class derived from - // X, the implicit conversion sequence is the one required to convert the - // element to the parameter type. + // Per DR1467: + // If the parameter type is a class X and the initializer list has a single + // element of type cv U, where U is X or a class derived from X, the + // implicit conversion sequence is the one required to convert the element + // to the parameter type. // // Otherwise, if the parameter type is a character array [... ] // and the initializer list has a single element that is an // appropriately-typed string literal (8.5.2 [dcl.init.string]), the // implicit conversion sequence is the identity conversion. if (From->getNumInits() == 1 && !IsDesignatedInit) { - if (ToType->isRecordType() && ToType->isAggregateType()) { + if (ToType->isRecordType()) { QualType InitType = From->getInit(0)->getType(); if (S.Context.hasSameUnqualifiedType(InitType, ToType) || S.IsDerivedFrom(From->getBeginLoc(), InitType, ToType)) From nobody Sat Apr 20 10:32:29 2024 X-Original-To: dev-commits-src-branches@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 4VM7B54d8Hz5HVx8; Sat, 20 Apr 2024 10:32:29 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B52Jj0z4PfR; Sat, 20 Apr 2024 10:32:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609149; 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=4ptEKVF9/a8p4aJYO5JZlV3TSEPwbY6z5DbNtidbTMk=; b=uqFb/H4JAJEuVm5q6q+CA5YHivwUmSgDudWx8kHTuVEhZrri4WViJx562SxPWCzNZKS3Z2 HROSfezy733Eg066x/2YBio2rX4Z33DgY2z+/PQW/JK9Y3QcJlFGTCkuw25T16v6p3NNhP M0d5lfHFbSudJrYcd0ra7CbJ06raJOfNOrdcia98poXJng4+bTvMbPG/7H0B3FqGYO8MDq GHvu0gucAaLGhWTolLlS+Zzmk9s+QajMWmgBW7Lx1OBPhmkCqKw9AW2GtnR4cbGFDKzzuK 9/+wHrjAOWBsR1AW+8ZimpRI78Cule33lg0D2QPTHersfButfsDP97yGI3BgfA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609149; a=rsa-sha256; cv=none; b=S7hzFyEQ6zO/IB+CqhQ/edMZzPnQ6d8CszSy+HDM9Vv1ouoCOajRz0locJsow6nVcLaVzB jg1mmzCf+LDaJS3MxaKygESNTlEB0fwX8klVzd0UqB0ZqLM961i8fvzblV89id9d8XwAFf dYKbhX5nM334qJKnIrt+cvnLoW+QJilXcmuduz7JTt7gCKQy240/1QxeqgNrb/UqQE5y0g FDg/ZAMlx0gaTEW1MHKfdcsUC+s+bLQ9jKvtkt3fsmcHM41O/VVMorXkN2UpQ22NTsS+zW P9AIasbmtJviL/3N/aCFJoNBpzlWaVeccILGMf2/NWw8npKjlJGxZ32dodoMiw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609149; 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=4ptEKVF9/a8p4aJYO5JZlV3TSEPwbY6z5DbNtidbTMk=; b=J5yS/36JD5UhANLOeYrySb9ghVsquOlKR0ckRBayKGpIp4meEAO/LucsuImfqIJetj8m17 xjC+gDXifNNL2QUQztq4KnbQNjWhlJZrIpnaeB1hzOvZuA2vWrJT2ILh6PimO0i2yyDw1s y8cZzixWZSMf8EpVv3isqyXEveLQiBiPveoSOOIVI4sZRYDvZhkQ4cHQdaHrtOfrekO1yZ 2C4jafqIOHAp9lwXe/91hfXllLvzU7rhO3u6mAuXmk1kldjret/esVuWxDKTk3nMCcXJQK /KUt+61uiJ7CUNEQ0vwflEFR4E7BIICDT7nM24tlmHk66OmH9i6Fccpe+a7ktA== 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 4VM7B51wmgzYmB; Sat, 20 Apr 2024 10:32:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWTNM011160; Sat, 20 Apr 2024 10:32:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWTm4011156; Sat, 20 Apr 2024 10:32:29 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:29 GMT Message-Id: <202404201032.43KAWTm4011156@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: bf13152d9e61 - stable/14 - Merge commit 5f4ee5a2dfa9 from llvm-project (by Shanzhi): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: bf13152d9e61246e5a5f494e5cd02bd55cccea80 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=bf13152d9e61246e5a5f494e5cd02bd55cccea80 commit bf13152d9e61246e5a5f494e5cd02bd55cccea80 Author: Dimitry Andric AuthorDate: 2024-02-05 09:16:17 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:15 +0000 Merge commit 5f4ee5a2dfa9 from llvm-project (by Shanzhi): [Clang][AST] Fix a crash on attaching doc comments (#78716) This crash is basically caused by calling `ASTContext::getRawCommentForDeclNoCacheImp` with its input arguments `RepresentativeLocForDecl` and `CommentsInTheFile` refering to different files. A reduced reproducer is provided in this patch. After the source locations for instantiations of funtion template are corrected in the commit 256a0b298c68b89688b80350b034daf2f7785b67, the variable `CommitsInThisFile` in the function `ASTContext::attachCommentsToJustParsedDecls` would refer to the source file rather than the header file for implicit function template instantiation. Therefore, in the first loop in `ASTContext::attachCommentsToJustParsedDecls`, `D` should also be adjusted for relevant scenarios like the second loop. Fixes #67979 Fixes #68524 Fixes #70550 This should fix a segfault when compiling graphics/gdal. PR: 276104 MFC after: 1 month (cherry picked from commit dc36515b628331e03ac8c23a6749f7f3eb1ebec8) --- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index 5eb7aa366456..9a0ede201059 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -498,7 +498,11 @@ void ASTContext::attachCommentsToJustParsedDecls(ArrayRef Decls, return; FileID File; - for (Decl *D : Decls) { + for (const Decl *D : Decls) { + if (D->isInvalidDecl()) + continue; + + D = &adjustDeclToTemplate(*D); SourceLocation Loc = D->getLocation(); if (Loc.isValid()) { // See if there are any new comments that are not attached to a decl. From nobody Sat Apr 20 10:32:30 2024 X-Original-To: dev-commits-src-branches@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 4VM7B66VLzz5HWFy; Sat, 20 Apr 2024 10:32:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B642q3z4PYm; Sat, 20 Apr 2024 10:32:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609150; 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=Hbi7p0sAFVEKJP7rKLbZ7pzS7Gc+98fWp/JK9mqdKRw=; b=DLaUCikw0ryoqOmEQicEfV9RCovQvjX72WDwwcznhS7MbmM+DMKRi6/tZtZCWKGz2E/ZCy d3zmrxZ+QckV8hkM2vVvGOSng1C2TMwanLzwrdQUGSx39t0x9SoUna7abZ6Eh/EjgRcazi ICKogPquKTdlNsViQWxJzSB0ZUBSb7C0/gca1mHiVBJW1gX3t3CBT95ojlbE8pPREmhfdE 9FjXweXpUBuBLCwpTz4lCOMIaEFoxEfaXy/Rdw80lS4vaByxgUFH8NbmqxtdmdrdfprIjE KEFdIbHc1Ri/0D1IqEPzxZXI0EBfu218lWrLnR44IDZtUfPfLBXmYzKb62pq1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609150; a=rsa-sha256; cv=none; b=IyyZ+a+gUK5xoydF8rB+72FhQxs2XENu2pipzKc2NfUVsws/zCbHswH5TrpcAUb1hc4F04 QWcoVtop8hvJpbmPK0vLuSuslEKJhLjcq6PbonM185EmSGYOUGrtaNs2ShMOgpH5SYuMfP euUgNdmPtFuQtg+uuHFoJ7UzIK8arLyT5Sii7l3z1Eqw/Y7OqXhuS0e5oWFqv+uDWanj4q MTf4N7+8SDMU21GZ/RkrPvAYIcVmnZpGVBtBbL42rA6RKfXgCiHcsJgFIwWO4+oWad89FJ U7kT1da7Di23/veAZxtRvf7/toGf2zc+zUdewT75o894BIoqZz/K+QQMD/qjuA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609150; 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=Hbi7p0sAFVEKJP7rKLbZ7pzS7Gc+98fWp/JK9mqdKRw=; b=jsqEWoc5UAcXaP+UUnHkJLsI04FrkHGWUrd9ZKOQcGx9LBmXCkdcC4RIBopKUVQFx4plXk +OUoe19+2gTL0s22qJPYVHA/EEWgNlKH48vbsTcIvSROjxrrA+/rgyLOsjdCkbAKoqzT3T qX4/aCmjx/SHsc/Rq0kLMY806CmQr0/zd1k8xWlu6UQc9Npi0r52cTV1Sdm4nq+SclcWGY P/bz3aHReSFpD7SEW3f2+TlDnkJ8sq39ZQZjUn8UCBCmXjrHRZIYgk25n8URDr5kRQ86NY BtHy88V1QnggKhDRgawa63gznGwGgHA1sdGF/dZFXESLR+hrcB/TMZPXvv1Xow== 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 4VM7B631W5zYhC; Sat, 20 Apr 2024 10:32:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWU8U011213; Sat, 20 Apr 2024 10:32:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWUIk011210; Sat, 20 Apr 2024 10:32:30 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:30 GMT Message-Id: <202404201032.43KAWUIk011210@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: 905954429d1f - stable/14 - [libc++] Rename __bit_reference template parameter to avoid conflict List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 905954429d1f6ccebb287379b66e1b58051be889 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=905954429d1f6ccebb287379b66e1b58051be889 commit 905954429d1f6ccebb287379b66e1b58051be889 Author: Dimitry Andric AuthorDate: 2024-02-05 11:41:51 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:15 +0000 [libc++] Rename __bit_reference template parameter to avoid conflict As of 4d20cfcf4eb08217ed37c4d4c38dc395d7a66d26, `__bit_reference` contains a template `__fill_n` with a bool `_FillValue` parameter. Unfortunately there is a relatively widely used piece of scientific software called NetCDF, which exposes a (C) macro `_FillValue` in its public headers. When building the NetCDF C++ bindings, this quickly leads to compilation errors when the macro interferes with the template in `__bit_reference`. Rename the parameter to `_FillVal` to avoid the conflict. PR: 276104 MFC after: 1 month (cherry picked from commit 868ee3f2855615016ba87c14b9444c18a2e1ba30) --- contrib/llvm-project/libcxx/include/__bit_reference | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__bit_reference b/contrib/llvm-project/libcxx/include/__bit_reference index 9032b8f01809..3a5339b72ddc 100644 --- a/contrib/llvm-project/libcxx/include/__bit_reference +++ b/contrib/llvm-project/libcxx/include/__bit_reference @@ -173,7 +173,7 @@ private: // fill_n -template +template _LIBCPP_CONSTEXPR_SINCE_CXX20 _LIBCPP_HIDE_FROM_ABI void __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { using _It = __bit_iterator<_Cp, false>; @@ -185,7 +185,7 @@ __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); __storage_type __dn = std::min(__clz_f, __n); __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - if (_FillValue) + if (_FillVal) *__first.__seg_ |= __m; else *__first.__seg_ &= ~__m; @@ -194,13 +194,13 @@ __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { } // do middle whole words __storage_type __nw = __n / __bits_per_word; - std::fill_n(std::__to_address(__first.__seg_), __nw, _FillValue ? static_cast<__storage_type>(-1) : 0); + std::fill_n(std::__to_address(__first.__seg_), __nw, _FillVal ? static_cast<__storage_type>(-1) : 0); __n -= __nw * __bits_per_word; // do last partial word if (__n > 0) { __first.__seg_ += __nw; __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - if (_FillValue) + if (_FillVal) *__first.__seg_ |= __m; else *__first.__seg_ &= ~__m; @@ -1007,7 +1007,7 @@ private: friend class __bit_iterator<_Cp, true>; template friend struct __bit_array; - template + template _LIBCPP_CONSTEXPR_SINCE_CXX20 friend void __fill_n(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n); template From nobody Sat Apr 20 10:32:31 2024 X-Original-To: dev-commits-src-branches@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 4VM7B81xjrz5HWG5; Sat, 20 Apr 2024 10:32: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B76VvXz4Pq4; Sat, 20 Apr 2024 10:32:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609151; 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=XsenlHLJOFpnPUaIwWphBvOQa+YYD0ObkIvN1E6gm9U=; b=G93LpQ36zNJEGCs1YlZYwQvdFUyeaQMS4P1OOoYQj4tCbl5Y+mryK9cSdZQhPtalcoug2x tyvygMqRbkNzDOJFhCzdBBdjxe7fQuhGm5j+UygS+8HxZv6roYQVcxbHKugmldf9nEmyif G3kGU6f8VzGftUqY059IAMSz7D3NCceyn1H9IsqGn1WKeMRNR9I3PeA4fhdPGd3NMcithU cpikrq8eLCi+2Ji+fRXWmyliGGiGYCjCikZefoFAuI72WURtec7M3EAFmeOAWWff5CqFY1 16bEkB83upkYeXTWa7H7ZXo0BR/SCFdNSzPQBHUfZ3GmRKH8HFx1DGbwVhZHSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609151; a=rsa-sha256; cv=none; b=yGEjAigN8QVMR4lr127vnsQQJGBigUs1apVG7TtzJ4OoKrdeNDr+DkSraVCSge5C32c6uu ilmR1vfY9QiXHHis6JpU/II/kTQ5A0a/TILPN0CFiuKan/sSGMT007uTtzMt4iCyaPQbw/ ludh+MWUVRcxIrbwoict4kKN61FTNDw1lQ3ZdXnQ9rNetzMzYE2+wvb9QCmXTJlT+7Fc4d CjFwKk55uflnSzqE/PgwcJfoLbhOhn1Dy1Be8ZFmlMW8Cvu6wZIwqCmbdSnPdXifQiAgS7 cYc4vxh+aHWW80qVvAwfZ4ZYk5nWG6teIRKkj+IisEopGD4VDJm7MWObPf/J4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609151; 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=XsenlHLJOFpnPUaIwWphBvOQa+YYD0ObkIvN1E6gm9U=; b=ZC6RJeLvPhZvgqVucR4UxN+z+bLdGxSHGfk2UqmkOOfij7Qy43oEV5+TGk3bVRBOCzL31e OvkLcpa9+jPRJayc7CppDSZWVevCdbxQM8rQ0RcxcC+nfS3vG/6i1M+SB4/REQhn3bctNc xHx2v2U8AWMHpHfBKPDqbyEoAirZdJO5bU28zyl8ttXI4GyjWyoxCf4RK0ZnuXPEISK6nY XmsPrEppNBpfIH3jiiBa8IvokfGJ2Nt0ST8Trks6mIIeH0eMNNtmkn/NhsrXOpH71KmGwF UgrzoYhy7706G1QMz6Kh65oHSyo+hZyA7x0ykKWJO8MqyRav2SaX2IPLKzTgFw== 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 4VM7B766MMzYSJ; Sat, 20 Apr 2024 10:32:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWVHf011252; Sat, 20 Apr 2024 10:32:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWVNI011249; Sat, 20 Apr 2024 10:32:31 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:31 GMT Message-Id: <202404201032.43KAWVNI011249@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: b9d9368bac6c - stable/14 - Merge llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: b9d9368bac6cf937f457507e98e875e56b1dd077 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=b9d9368bac6cf937f457507e98e875e56b1dd077 commit b9d9368bac6cf937f457507e98e875e56b1dd077 Author: Dimitry Andric AuthorDate: 2024-02-07 14:58:02 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:15 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967. PR: 276104 MFC after: 1 month (cherry picked from commit b3edf4467982447620505a28fc82e38a414c07dc) --- .../llvm-project/clang/include/clang/AST/Type.h | 3 + .../clang/include/clang/Basic/AttrDocs.td | 5 +- .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 62 +++ .../clang/include/clang/Basic/CodeGenOptions.def | 3 + .../include/clang/Basic/DiagnosticCommonKinds.td | 2 +- .../clang/include/clang/Basic/DiagnosticDocs.td | 9 + .../include/clang/Basic/DiagnosticSemaKinds.td | 6 + .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Driver/Options.td | 13 + .../clang/include/clang/Format/Format.h | 43 +- .../clang/include/clang/Lex/Preprocessor.h | 11 +- .../llvm-project/clang/include/clang/Sema/Lookup.h | 3 +- .../clang/include/clang/Serialization/ASTReader.h | 6 + contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 20 +- .../llvm-project/clang/lib/AST/ExprConstant.cpp | 9 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 25 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 3 + contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 49 +- .../llvm-project/clang/lib/AST/TemplateBase.cpp | 3 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 3 + contrib/llvm-project/clang/lib/AST/Type.cpp | 15 +- contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 2 + .../clang/lib/Basic/Targets/AArch64.cpp | 23 + .../llvm-project/clang/lib/Basic/Targets/AArch64.h | 1 + .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 1 + .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 177 +++++++- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 17 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 6 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 21 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 6 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 15 + .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 52 +++ .../clang/lib/Driver/ToolChains/CommonArgs.h | 3 + contrib/llvm-project/clang/lib/Format/Format.cpp | 23 +- .../clang/lib/Format/TokenAnnotator.cpp | 11 +- .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 2 +- .../llvm-project/clang/lib/Lex/PPExpressions.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 55 ++- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 8 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 6 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 44 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 44 +- contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 21 +- .../clang/lib/Serialization/ASTReader.cpp | 3 + .../clang/lib/Serialization/ASTReaderDecl.cpp | 38 +- .../clang/lib/Serialization/ASTWriter.cpp | 8 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 13 +- .../clang/lib/StaticAnalyzer/Core/Environment.cpp | 8 +- .../compiler-rt/lib/builtins/i386/chkstk.S | 2 - .../compiler-rt/lib/builtins/x86_64/chkstk.S | 2 - .../lib/profile/InstrProfilingPlatformWindows.c | 2 +- .../sanitizer_symbolizer_report.cpp | 4 +- .../libcxx/include/__algorithm/copy_move_common.h | 5 + .../libcxx/include/__algorithm/equal.h | 5 + .../libcxx/include/__algorithm/equal_range.h | 5 + .../llvm-project/libcxx/include/__algorithm/fold.h | 5 + .../libcxx/include/__algorithm/in_found_result.h | 5 + .../libcxx/include/__algorithm/in_fun_result.h | 5 + .../libcxx/include/__algorithm/in_in_out_result.h | 5 + .../libcxx/include/__algorithm/in_in_result.h | 5 + .../libcxx/include/__algorithm/in_out_out_result.h | 5 + .../libcxx/include/__algorithm/includes.h | 5 + .../libcxx/include/__algorithm/next_permutation.h | 5 + .../libcxx/include/__algorithm/nth_element.h | 5 + .../libcxx/include/__algorithm/partial_sort.h | 5 + .../libcxx/include/__algorithm/partial_sort_copy.h | 5 + .../libcxx/include/__algorithm/partition.h | 5 + .../libcxx/include/__algorithm/prev_permutation.h | 5 + .../include/__algorithm/pstl_any_all_none_of.h | 5 + .../pstl_backends/cpu_backends/transform_reduce.h | 5 + .../libcxx/include/__algorithm/pstl_copy.h | 5 + .../libcxx/include/__algorithm/pstl_count.h | 5 + .../libcxx/include/__algorithm/pstl_equal.h | 5 + .../libcxx/include/__algorithm/pstl_fill.h | 5 + .../libcxx/include/__algorithm/pstl_find.h | 5 + .../libcxx/include/__algorithm/pstl_for_each.h | 5 + .../libcxx/include/__algorithm/pstl_generate.h | 5 + .../include/__algorithm/pstl_is_partitioned.h | 5 + .../libcxx/include/__algorithm/pstl_merge.h | 5 + .../libcxx/include/__algorithm/pstl_move.h | 5 + .../libcxx/include/__algorithm/pstl_replace.h | 5 + .../libcxx/include/__algorithm/pstl_rotate_copy.h | 5 + .../libcxx/include/__algorithm/pstl_sort.h | 5 + .../libcxx/include/__algorithm/pstl_stable_sort.h | 5 + .../libcxx/include/__algorithm/pstl_transform.h | 5 + .../libcxx/include/__algorithm/ranges_all_of.h | 5 + .../libcxx/include/__algorithm/ranges_any_of.h | 5 + .../include/__algorithm/ranges_binary_search.h | 5 + .../libcxx/include/__algorithm/ranges_clamp.h | 5 + .../libcxx/include/__algorithm/ranges_contains.h | 5 + .../libcxx/include/__algorithm/ranges_copy.h | 5 + .../include/__algorithm/ranges_copy_backward.h | 5 + .../libcxx/include/__algorithm/ranges_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_copy_n.h | 5 + .../libcxx/include/__algorithm/ranges_count.h | 5 + .../libcxx/include/__algorithm/ranges_count_if.h | 5 + .../libcxx/include/__algorithm/ranges_ends_with.h | 5 + .../libcxx/include/__algorithm/ranges_equal.h | 5 + .../include/__algorithm/ranges_equal_range.h | 5 + .../libcxx/include/__algorithm/ranges_fill.h | 5 + .../libcxx/include/__algorithm/ranges_fill_n.h | 5 + .../libcxx/include/__algorithm/ranges_find.h | 5 + .../libcxx/include/__algorithm/ranges_find_end.h | 5 + .../include/__algorithm/ranges_find_first_of.h | 5 + .../libcxx/include/__algorithm/ranges_find_if.h | 5 + .../include/__algorithm/ranges_find_if_not.h | 5 + .../libcxx/include/__algorithm/ranges_for_each.h | 5 + .../libcxx/include/__algorithm/ranges_for_each_n.h | 5 + .../libcxx/include/__algorithm/ranges_generate.h | 5 + .../libcxx/include/__algorithm/ranges_generate_n.h | 5 + .../libcxx/include/__algorithm/ranges_includes.h | 5 + .../include/__algorithm/ranges_inplace_merge.h | 5 + .../libcxx/include/__algorithm/ranges_is_heap.h | 5 + .../include/__algorithm/ranges_is_heap_until.h | 5 + .../include/__algorithm/ranges_is_partitioned.h | 5 + .../include/__algorithm/ranges_is_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_is_sorted.h | 5 + .../include/__algorithm/ranges_is_sorted_until.h | 5 + .../include/__algorithm/ranges_iterator_concept.h | 5 + .../__algorithm/ranges_lexicographical_compare.h | 5 + .../include/__algorithm/ranges_lower_bound.h | 5 + .../libcxx/include/__algorithm/ranges_make_heap.h | 5 + .../include/__algorithm/ranges_max_element.h | 5 + .../libcxx/include/__algorithm/ranges_merge.h | 5 + .../include/__algorithm/ranges_min_element.h | 5 + .../include/__algorithm/ranges_minmax_element.h | 5 + .../libcxx/include/__algorithm/ranges_mismatch.h | 5 + .../libcxx/include/__algorithm/ranges_move.h | 5 + .../include/__algorithm/ranges_move_backward.h | 5 + .../include/__algorithm/ranges_next_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_none_of.h | 5 + .../include/__algorithm/ranges_nth_element.h | 5 + .../include/__algorithm/ranges_partial_sort.h | 5 + .../include/__algorithm/ranges_partial_sort_copy.h | 5 + .../libcxx/include/__algorithm/ranges_partition.h | 5 + .../include/__algorithm/ranges_partition_copy.h | 5 + .../include/__algorithm/ranges_partition_point.h | 5 + .../libcxx/include/__algorithm/ranges_pop_heap.h | 5 + .../include/__algorithm/ranges_prev_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_push_heap.h | 5 + .../libcxx/include/__algorithm/ranges_remove.h | 5 + .../include/__algorithm/ranges_remove_copy.h | 5 + .../include/__algorithm/ranges_remove_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_remove_if.h | 5 + .../libcxx/include/__algorithm/ranges_replace.h | 5 + .../include/__algorithm/ranges_replace_copy.h | 5 + .../include/__algorithm/ranges_replace_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_replace_if.h | 5 + .../include/__algorithm/ranges_reverse_copy.h | 5 + .../libcxx/include/__algorithm/ranges_rotate.h | 5 + .../include/__algorithm/ranges_rotate_copy.h | 5 + .../libcxx/include/__algorithm/ranges_sample.h | 5 + .../libcxx/include/__algorithm/ranges_search_n.h | 5 + .../include/__algorithm/ranges_set_difference.h | 6 + .../include/__algorithm/ranges_set_intersection.h | 6 + .../__algorithm/ranges_set_symmetric_difference.h | 6 + .../libcxx/include/__algorithm/ranges_set_union.h | 5 + .../libcxx/include/__algorithm/ranges_shuffle.h | 5 + .../libcxx/include/__algorithm/ranges_sort.h | 5 + .../libcxx/include/__algorithm/ranges_sort_heap.h | 5 + .../include/__algorithm/ranges_stable_partition.h | 5 + .../include/__algorithm/ranges_stable_sort.h | 5 + .../include/__algorithm/ranges_starts_with.h | 5 + .../include/__algorithm/ranges_swap_ranges.h | 5 + .../libcxx/include/__algorithm/ranges_transform.h | 5 + .../libcxx/include/__algorithm/ranges_unique.h | 5 + .../include/__algorithm/ranges_unique_copy.h | 5 + .../libcxx/include/__algorithm/remove.h | 5 + .../libcxx/include/__algorithm/remove_if.h | 5 + .../libcxx/include/__algorithm/reverse.h | 5 + .../libcxx/include/__algorithm/rotate.h | 5 + .../libcxx/include/__algorithm/set_difference.h | 5 + .../libcxx/include/__algorithm/set_intersection.h | 5 + .../include/__algorithm/set_symmetric_difference.h | 5 + .../libcxx/include/__algorithm/set_union.h | 5 + .../libcxx/include/__algorithm/shift_left.h | 5 + .../libcxx/include/__algorithm/shift_right.h | 5 + .../llvm-project/libcxx/include/__algorithm/sort.h | 5 + .../libcxx/include/__algorithm/sort_heap.h | 5 + .../libcxx/include/__algorithm/stable_partition.h | 5 + .../libcxx/include/__algorithm/stable_sort.h | 5 + .../libcxx/include/__algorithm/swap_ranges.h | 5 + .../libcxx/include/__algorithm/unique.h | 5 + .../libcxx/include/__algorithm/unique_copy.h | 5 + .../libcxx/include/__algorithm/unwrap_iter.h | 2 +- .../libcxx/include/__algorithm/unwrap_range.h | 5 + contrib/llvm-project/libcxx/include/__config | 9 +- .../include/__filesystem/directory_iterator.h | 5 + .../libcxx/include/__filesystem/path.h | 5 + .../__filesystem/recursive_directory_iterator.h | 5 + .../libcxx/include/__format/format_arg.h | 5 + .../libcxx/include/__format/format_context.h | 5 + .../libcxx/include/__format/format_functions.h | 5 + .../libcxx/include/__format/formatter_output.h | 5 + .../libcxx/include/__format/write_escaped.h | 5 + .../libcxx/include/__functional/function.h | 5 + .../include/__iterator/cpp17_iterator_concepts.h | 5 + .../libcxx/include/__iterator/iterator_with_data.h | 5 + .../__memory/ranges_uninitialized_algorithms.h | 5 + .../libcxx/include/__memory/raw_storage_iterator.h | 5 + .../libcxx/include/__memory/shared_ptr.h | 5 + .../include/__memory/uninitialized_algorithms.h | 5 + .../libcxx/include/__mutex/once_flag.h | 5 + .../libcxx/include/__numeric/pstl_reduce.h | 5 + .../include/__numeric/pstl_transform_reduce.h | 5 + .../llvm-project/libcxx/include/__numeric/reduce.h | 5 + .../include/__numeric/saturation_arithmetic.h | 5 + .../libcxx/include/__numeric/transform_reduce.h | 5 + .../llvm-project/libcxx/include/__ranges/counted.h | 5 + .../libcxx/include/__ranges/drop_while_view.h | 5 + .../libcxx/include/__ranges/elements_view.h | 5 + .../libcxx/include/__ranges/filter_view.h | 5 + .../libcxx/include/__ranges/iota_view.h | 5 + .../libcxx/include/__ranges/join_view.h | 5 + .../libcxx/include/__ranges/lazy_split_view.h | 5 + .../libcxx/include/__ranges/repeat_view.h | 5 + .../libcxx/include/__ranges/reverse_view.h | 5 + .../libcxx/include/__ranges/single_view.h | 5 + .../libcxx/include/__ranges/split_view.h | 5 + .../libcxx/include/__ranges/take_while_view.h | 5 + .../libcxx/include/__ranges/transform_view.h | 5 + .../llvm-project/libcxx/include/__thread/jthread.h | 5 + .../llvm-project/libcxx/include/__thread/thread.h | 5 + contrib/llvm-project/libcxx/include/array | 5 + .../llvm-project/libcxx/include/condition_variable | 5 + .../libcxx/include/experimental/iterator | 5 + contrib/llvm-project/libcxx/include/future | 5 + contrib/llvm-project/libcxx/include/ios | 5 + contrib/llvm-project/libcxx/include/map | 5 + contrib/llvm-project/libcxx/include/ostream | 5 + contrib/llvm-project/libcxx/include/queue | 5 + contrib/llvm-project/libcxx/include/set | 5 + contrib/llvm-project/libcxx/include/stack | 5 + contrib/llvm-project/libcxx/include/string | 7 +- contrib/llvm-project/libcxx/include/strstream | 5 + contrib/llvm-project/libcxx/include/unordered_map | 5 + contrib/llvm-project/libcxx/include/unordered_set | 5 + contrib/llvm-project/libcxx/include/version | 14 +- contrib/llvm-project/libcxx/modules/std/atomic.inc | 2 + contrib/llvm-project/libcxx/modules/std/iosfwd.inc | 2 + contrib/llvm-project/libcxx/modules/std/string.inc | 4 + .../libcxx/modules/std/string_view.inc | 2 + contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 199 ++++++-- contrib/llvm-project/lld/ELF/InputFiles.cpp | 7 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 13 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 50 ++- contrib/llvm-project/lld/ELF/Writer.cpp | 12 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 62 +++ .../llvm/include/llvm/Analysis/AliasAnalysis.h | 7 + .../include/llvm/Analysis/BasicAliasAnalysis.h | 14 +- .../include/llvm/Analysis/BranchProbabilityInfo.h | 13 +- .../llvm/include/llvm/Analysis/Loads.h | 12 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 18 +- .../llvm/include/llvm/CodeGen/LivePhysRegs.h | 11 +- .../llvm/include/llvm/CodeGen/MachineBasicBlock.h | 6 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 119 +++-- .../llvm/include/llvm/Support/X86FoldTablesUtils.h | 11 +- .../include/llvm/Target/TargetInstrPredicate.td | 34 ++ .../llvm/TargetParser/AArch64TargetParser.h | 3 +- .../llvm/include/llvm/TargetParser/Triple.h | 6 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 6 +- contrib/llvm-project/llvm/lib/Analysis/Lint.cpp | 3 +- contrib/llvm-project/llvm/lib/Analysis/Loads.cpp | 9 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 53 ++- .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 22 +- .../llvm/lib/CodeGen/BranchFolding.cpp | 6 +- .../lib/ProfileData/Coverage/CoverageMapping.cpp | 240 ++++++++-- .../ProfileData/Coverage/CoverageMappingWriter.cpp | 10 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 3 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 6 + .../lib/Target/AArch64/AArch64FrameLowering.cpp | 6 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 28 +- .../llvm/lib/Target/AArch64/AArch64ISelLowering.h | 4 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 20 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.h | 3 - .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 229 ---------- .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 35 ++ .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 22 + .../Target/AArch64/AArch64TargetTransformInfo.cpp | 17 +- .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 1 + .../llvm/lib/Target/AMDGPU/AMDGPUGISel.td | 24 + .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 330 ++++++++++++++ .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 10 + .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 1 + .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 213 +++++++++ .../lib/Target/AMDGPU/AMDGPUInstructionSelector.h | 13 + .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 79 +++- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.h | 1 + .../llvm/lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp | 16 +- .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 16 + .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 16 + .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 142 +++++- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 34 ++ .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 19 +- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 47 ++ .../Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h | 4 + .../llvm/lib/Target/AMDGPU/SIDefines.h | 3 + .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 1 + .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 111 ++++- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 1 + .../llvm/lib/Target/AMDGPU/SIInstrFormats.td | 5 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 8 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 18 +- .../llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | 32 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 5 + .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 11 + .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 3 + .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 93 +++- .../llvm/lib/Target/AMDGPU/VOP3Instructions.td | 53 ++- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 500 ++++++++++++++++++++- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 32 +- .../llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp | 13 +- .../LoongArch/LoongArchTargetTransformInfo.cpp | 11 +- .../llvm/lib/Target/Mips/MipsAsmPrinter.cpp | 39 -- .../llvm/lib/Target/Mips/MipsAsmPrinter.h | 2 - .../Target/PowerPC/PPCExpandAtomicPseudoInsts.cpp | 14 +- .../llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 13 +- .../llvm-project/llvm/lib/Target/RISCV/RISCV.td | 6 + .../llvm/lib/Target/RISCV/RISCVFeatures.td | 26 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 2 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZicond.td | 2 - .../llvm/lib/Target/RISCV/RISCVMacroFusion.cpp | 210 --------- .../llvm/lib/Target/RISCV/RISCVMacroFusion.h | 28 -- .../llvm/lib/Target/RISCV/RISCVMacroFusion.td | 93 ++++ .../llvm/lib/Target/RISCV/RISCVSubtarget.cpp | 8 +- .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 8 +- .../llvm/lib/Target/RISCV/RISCVTargetMachine.cpp | 13 +- .../lib/Target/SystemZ/SystemZFrameLowering.cpp | 12 +- .../llvm/lib/Target/X86/X86AsmPrinter.cpp | 1 - .../llvm/lib/Target/X86/X86FrameLowering.cpp | 15 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 2 +- .../llvm/lib/Target/X86/X86InstrFoldTables.cpp | 11 +- .../llvm/lib/Target/X86/X86InstrInfo.cpp | 35 +- .../llvm/lib/TargetParser/TargetParser.cpp | 1 + .../InstCombine/InstCombineLoadStoreAlloca.cpp | 3 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 3 + .../Transforms/Scalar/ConstraintElimination.cpp | 7 +- .../llvm/lib/Transforms/Scalar/JumpThreading.cpp | 13 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 62 ++- .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 12 +- .../llvm/utils/TableGen/DAGISelMatcherEmitter.cpp | 3 +- .../llvm/utils/TableGen/PredicateExpander.cpp | 34 ++ .../llvm/utils/TableGen/PredicateExpander.h | 4 + .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 58 +-- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 3 +- usr.bin/clang/clang/clang-driver.cpp | 2 + usr.bin/clang/lld/lld-driver.cpp | 2 + usr.bin/clang/llvm-ar/llvm-ar-driver.cpp | 2 + usr.bin/clang/llvm-cxxfilt/llvm-cxxfilt-driver.cpp | 2 + usr.bin/clang/llvm-dwp/llvm-dwp-driver.cpp | 2 + usr.bin/clang/llvm-nm/llvm-nm-driver.cpp | 2 + usr.bin/clang/llvm-objcopy/llvm-objcopy-driver.cpp | 2 + usr.bin/clang/llvm-objdump/llvm-objdump-driver.cpp | 2 + .../clang/llvm-profdata/llvm-profdata-driver.cpp | 2 + usr.bin/clang/llvm-readobj/llvm-readobj-driver.cpp | 2 + usr.bin/clang/llvm-size/llvm-size-driver.cpp | 2 + .../llvm-symbolizer/llvm-symbolizer-driver.cpp | 2 + 361 files changed, 4552 insertions(+), 1284 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index ea425791fc97..6384cf9420b8 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -3495,6 +3495,9 @@ enum class VectorKind { /// is RISC-V RVV fixed-length data vector RVVFixedLengthData, + + /// is RISC-V RVV fixed-length mask vector + RVVFixedLengthMask, }; /// Represents a GCC generic vector type. This type is created using diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 7e633f8e2635..e02a1201e2ad 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -2424,7 +2424,10 @@ only be a power of 2 between 64 and 65536. For types where LMUL!=1, ``__riscv_v_fixed_vlen`` needs to be scaled by the LMUL of the type before passing to the attribute. -``vbool*_t`` types are not supported at this time. +For ``vbool*_t`` types, ``__riscv_v_fixed_vlen`` needs to be divided by the +number from the type name. For example, ``vbool8_t`` needs to use +``__riscv_v_fixed_vlen`` / 8. If the resulting value is not a multiple of 8, +the type is not supported for that value of ``__riscv_v_fixed_vlen``. }]; } diff --git a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def index d208342d9c51..74dfd1d214e8 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def +++ b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def @@ -436,5 +436,67 @@ TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_i32, "ii*1", "nc", "gfx12-insts,w TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_v4i16, "V4sV4s*1", "nc", "gfx12-insts,wavefrontsize64") TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_v4f16, "V4hV4h*1", "nc", "gfx12-insts,wavefrontsize64") +//===----------------------------------------------------------------------===// +// WMMA builtins. +// Postfix w32 indicates the builtin requires wavefront size of 32. +// Postfix w64 indicates the builtin requires wavefront size of 64. +// +// Some of these are very similar to their GFX11 counterparts, but they don't +// require replication of the A,B matrices, so they use fewer vector elements. +// Therefore, we add an "_gfx12" suffix to distinguish them from the existing +// builtins. +//===----------------------------------------------------------------------===// +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_f16_w32_gfx12, "V8fV8hV8hV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf16_w32_gfx12, "V8fV8sV8sV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f16_16x16x16_f16_w32_gfx12, "V8hV8hV8hV8h", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_bf16_16x16x16_bf16_w32_gfx12, "V8sV8sV8sV8s", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu8_w32_gfx12, "V8iIbV2iIbV2iV8iIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu4_w32_gfx12, "V8iIbiIbiV8iIb", "nc", "gfx12-insts,wavefrontsize32") +// These are gfx12-only, but for consistency with the other WMMA variants we're +// keeping the "_gfx12" suffix. +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_fp8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_bf8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_fp8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_bf8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x32_iu4_w32_gfx12, "V8iIbV2iIbV2iV8iIb", "nc", "gfx12-insts,wavefrontsize32") + +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_f16_w64_gfx12, "V4fV4hV4hV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf16_w64_gfx12, "V4fV4sV4sV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f16_16x16x16_f16_w64_gfx12, "V4hV4hV4hV4h", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_bf16_16x16x16_bf16_w64_gfx12, "V4sV4sV4sV4s", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu8_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu4_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") +// These are gfx12-only, but for consistency with the other WMMA variants we're +// keeping the "_gfx12" suffix. +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_fp8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_bf8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_fp8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_bf8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x32_iu4_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") + +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_f16_w32, "V8fV8hV16hV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf16_w32, "V8fV8sV16sV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f16_16x16x32_f16_w32, "V8hV8hV16hV8hs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_bf16_16x16x32_bf16_w32, "V8sV8sV16sV8ss", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu8_w32, "V8iIbV2iIbV4iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu4_w32, "V8iIbiIbV2iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x64_iu4_w32, "V8iIbV2iIbV4iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_fp8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_bf8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_fp8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_bf8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") + +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_f16_w64, "V4fV4hV8hV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf16_w64, "V4fV4sV8sV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f16_16x16x32_f16_w64, "V4hV4hV8hV4hs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_bf16_16x16x32_bf16_w64, "V4sV4sV8sV4ss", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu8_w64, "V4iIbiIbV2iV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu4_w64, "V4iIbiIbiV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x64_iu4_w64, "V4iIbiIbV2iV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_fp8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_bf8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_fp8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_bf8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") + #undef BUILTIN #undef TARGET_BUILTIN diff --git a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def index 2f2e45d5cf63..7c0bfe328496 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def @@ -369,6 +369,9 @@ ENUM_CODEGENOPT(VecLib, llvm::driver::VectorLibrary, 3, llvm::driver::VectorLibr /// The default TLS model to use. ENUM_CODEGENOPT(DefaultTLSModel, TLSModel, 2, GeneralDynamicTLSModel) +/// Whether to enable TLSDESC. AArch64 enables TLSDESC regardless of this value. +CODEGENOPT(EnableTLSDESC, 1, 0) + /// Bit size of immediate TLS offsets (0 == use the default). VALUE_CODEGENOPT(TLSSize, 8, 0) diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td index b1bada65cb6b..08bb1d81ba29 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td @@ -73,7 +73,7 @@ def warn_pragma_debug_unexpected_argument : Warning< def warn_fp_nan_inf_when_disabled : Warning< "use of %select{infinity|NaN}0%select{| via a macro}1 is undefined behavior " "due to the currently enabled floating-point options">, - InGroup>; + InGroup>; } // Parse && Sema diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td index e9862422b499..8c024b5cad74 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td @@ -87,3 +87,12 @@ program by treating all string literals as having type ``const char *`` instead of ``char *``. This can cause unexpected behaviors with type-sensitive constructs like ``_Generic``. }]; + +defvar NanInfDisabledDocs = [{ +This warning is enabled when source code using the macros ``INFINITY`` or ``NAN`` +is compiled with floating-point options preventing these two values. This can +lead to undefined behavior. Check the order of command line arguments that modify +this behavior, such as ``-ffast-math``, ``-fhonor-infinities``, and +``-fhonor-nans`` (etc), as well as ``#pragma`` directives if this diagnostic is +generated unexpectedly. +}]; diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index c5f1b67c4aa1..07ba4ecf7e12 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -3711,6 +3711,12 @@ def err_sme_za_call_no_za_state : Error< "call to a shared ZA function requires the caller to have ZA state">; def err_sme_zt0_call_no_zt0_state : Error< "call to a shared ZT0 function requires the caller to have ZT0 state">; +def err_sme_unimplemented_za_save_restore : Error< + "call to a function that shares state other than 'za' from a " + "function that has live 'za' state requires a spill/fill of ZA, which is not yet " + "implemented">; +def note_sme_use_preserves_za : Note< + "add '__arm_preserves(\"za\")' to the callee if it preserves ZA">; def err_sme_definition_using_sm_in_non_sme_target : Error< "function executed in streaming-SVE mode requires 'sme'">; def err_sme_definition_using_za_in_non_sme_target : Error< diff --git a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def index 8fc75e1cca03..4942dcaa086e 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def @@ -174,6 +174,7 @@ LANGOPT(MathErrno , 1, 1, "errno in math functions") BENIGN_LANGOPT(HeinousExtensions , 1, 0, "extensions that we really don't like and may be ripped out at any time") LANGOPT(Modules , 1, 0, "modules semantics") COMPATIBLE_LANGOPT(CPlusPlusModules, 1, 0, "C++ modules syntax") +LANGOPT(SkipODRCheckInGMF, 1, 0, "Skip ODR checks for decls in the global module fragment") LANGOPT(BuiltinHeadersInSystemModules, 1, 0, "builtin headers belong to system modules, and _Builtin_ modules are ignored for cstdlib headers") BENIGN_ENUM_LANGOPT(CompilingModule, CompilingModuleKind, 3, CMK_None, "compiling a module interface") diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index 7f4fa33748fa..e8d03fc26902 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -2985,6 +2985,14 @@ def fmodule_output : Flag<["-"], "fmodule-output">, Flags<[NoXarchOption]>, Visibility<[ClangOption, CC1Option]>, HelpText<"Save intermediate module file results when compiling a standard C++ module unit.">; +defm skip_odr_check_in_gmf : BoolOption<"f", "skip-odr-check-in-gmf", + LangOpts<"SkipODRCheckInGMF">, DefaultFalse, + PosFlag, + NegFlag>, + Group; + def fmodules_prune_interval : Joined<["-"], "fmodules-prune-interval=">, Group, Visibility<[ClangOption, CC1Option]>, MetaVarName<"">, HelpText<"Specify the interval (in seconds) between attempts to prune the module cache">, @@ -4419,6 +4427,8 @@ def mtls_size_EQ : Joined<["-"], "mtls-size=">, Group, HelpText<"Specify bit size of immediate TLS offsets (AArch64 ELF only): " "12 (for 4KB) | 24 (for 16MB, default) | 32 (for 4GB) | 48 (for 256TB, needs -mcmodel=large)">, MarshallingInfoInt>; +def mtls_dialect_EQ : Joined<["-"], "mtls-dialect=">, Group, + Flags<[TargetSpecific]>, HelpText<"Which thread-local storage dialect to use for dynamic accesses of TLS variables">; def mimplicit_it_EQ : Joined<["-"], "mimplicit-it=">, Group; def mdefault_build_attributes : Joined<["-"], "mdefault-build-attributes">, Group; def mno_default_build_attributes : Joined<["-"], "mno-default-build-attributes">, Group; @@ -7066,6 +7076,9 @@ def fexperimental_assignment_tracking_EQ : Joined<["-"], "fexperimental-assignme Values<"disabled,enabled,forced">, NormalizedValues<["Disabled","Enabled","Forced"]>, MarshallingInfoEnum, "Enabled">; +def enable_tlsdesc : Flag<["-"], "enable-tlsdesc">, + MarshallingInfoFlag>; + } // let Visibility = [CC1Option] //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/clang/include/clang/Format/Format.h b/contrib/llvm-project/clang/include/clang/Format/Format.h index bc9eecd42f9e..efcb4e1d87ea 100755 --- a/contrib/llvm-project/clang/include/clang/Format/Format.h +++ b/contrib/llvm-project/clang/include/clang/Format/Format.h @@ -4157,14 +4157,9 @@ struct FormatStyle { /// Different ways to put a space before opening parentheses. enum SpaceBeforeParensStyle : int8_t { - /// Never put a space before opening parentheses. - /// \code - /// void f() { - /// if(true) { - /// f(); - /// } - /// } - /// \endcode + /// This is **deprecated** and replaced by ``Custom`` below, with all + /// ``SpaceBeforeParensOptions`` but ``AfterPlacementOperator`` set to + /// ``false``. SBPO_Never, /// Put a space before opening parentheses only after control statement /// keywords (``for/if/while...``). @@ -4273,28 +4268,14 @@ struct FormatStyle { /// object.operator++ (10); object.operator++(10); /// \endcode bool AfterOverloadedOperator; - /// Styles for adding spacing between ``new/delete`` operators and opening - /// parentheses. - enum AfterPlacementOperatorStyle : int8_t { - /// Remove space after ``new/delete`` operators and before ``(``. - /// \code - /// new(buf) T; - /// delete(buf) T; - /// \endcode - APO_Never, - /// Always add space after ``new/delete`` operators and before ``(``. - /// \code - /// new (buf) T; - /// delete (buf) T; - /// \endcode - APO_Always, - /// Leave placement ``new/delete`` expressions as they are. - APO_Leave, - }; - /// Defines in which cases to put a space between ``new/delete`` operators - /// and opening parentheses. - /// \version 18 - AfterPlacementOperatorStyle AfterPlacementOperator; + /// If ``true``, put a space between operator ``new``/``delete`` and opening + /// parenthesis. + /// \code + /// true: false: + /// new (buf) T; vs. new(buf) T; + /// delete (buf) T; delete(buf) T; + /// \endcode + bool AfterPlacementOperator; /// If ``true``, put space between requires keyword in a requires clause and /// opening parentheses, if there is one. /// \code @@ -4327,7 +4308,7 @@ struct FormatStyle { : AfterControlStatements(false), AfterForeachMacros(false), AfterFunctionDeclarationName(false), AfterFunctionDefinitionName(false), AfterIfMacros(false), - AfterOverloadedOperator(false), AfterPlacementOperator(APO_Leave), + AfterOverloadedOperator(false), AfterPlacementOperator(true), AfterRequiresInClause(false), AfterRequiresInExpression(false), BeforeNonEmptyParentheses(false) {} diff --git a/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h b/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h index 2d9c53cdf5bd..b0a8ec0fec5e 100644 --- a/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h +++ b/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h @@ -2828,7 +2828,8 @@ public: return AnnotationInfos.find(II)->second; } - void emitMacroExpansionWarnings(const Token &Identifier) const { + void emitMacroExpansionWarnings(const Token &Identifier, + bool IsIfnDef = false) const { IdentifierInfo *Info = Identifier.getIdentifierInfo(); if (Info->isDeprecatedMacro()) emitMacroDeprecationWarning(Identifier); @@ -2837,12 +2838,12 @@ public: !SourceMgr.isInMainFile(Identifier.getLocation())) emitRestrictExpansionWarning(Identifier); - if (Info->getName() == "INFINITY") - if (getLangOpts().NoHonorInfs) + if (!IsIfnDef) { + if (Info->getName() == "INFINITY" && getLangOpts().NoHonorInfs) emitRestrictInfNaNWarning(Identifier, 0); - if (Info->getName() == "NAN") - if (getLangOpts().NoHonorNaNs) + if (Info->getName() == "NAN" && getLangOpts().NoHonorNaNs) emitRestrictInfNaNWarning(Identifier, 1); + } } static void processPathForFileMacro(SmallVectorImpl &Path, diff --git a/contrib/llvm-project/clang/include/clang/Sema/Lookup.h b/contrib/llvm-project/clang/include/clang/Sema/Lookup.h index 9c93bf1e6fb4..2f2f2607a937 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Lookup.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Lookup.h @@ -754,7 +754,8 @@ public: private: void diagnoseAccess() { - if (isClassLookup() && getSema().getLangOpts().AccessControl) + if (!isAmbiguous() && isClassLookup() && + getSema().getLangOpts().AccessControl) getSema().CheckLookupAccess(*this); } diff --git a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h index dd1451bbf2d2..cd28226c295b 100644 --- a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h +++ b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h @@ -2452,6 +2452,12 @@ private: uint32_t CurrentBitsIndex = ~0; }; +inline bool shouldSkipCheckingODR(const Decl *D) { + return D->getOwningModule() && + D->getASTContext().getLangOpts().SkipODRCheckInGMF && + D->getOwningModule()->isExplicitGlobalModule(); +} + } // namespace clang #endif // LLVM_CLANG_SERIALIZATION_ASTREADER_H diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index 9a0ede201059..cc5de9a6295e 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -1949,7 +1949,8 @@ TypeInfo ASTContext::getTypeInfoImpl(const Type *T) const { else if (VT->getVectorKind() == VectorKind::SveFixedLengthPredicate) // Adjust the alignment for fixed-length SVE predicates. Align = 16; - else if (VT->getVectorKind() == VectorKind::RVVFixedLengthData) + else if (VT->getVectorKind() == VectorKind::RVVFixedLengthData || + VT->getVectorKind() == VectorKind::RVVFixedLengthMask) // Adjust the alignment for fixed-length RVV vectors. Align = std::min(64, Width); break; @@ -9420,7 +9421,9 @@ bool ASTContext::areCompatibleVectorTypes(QualType FirstVec, Second->getVectorKind() != VectorKind::SveFixedLengthData && Second->getVectorKind() != VectorKind::SveFixedLengthPredicate && First->getVectorKind() != VectorKind::RVVFixedLengthData && - Second->getVectorKind() != VectorKind::RVVFixedLengthData) + Second->getVectorKind() != VectorKind::RVVFixedLengthData && + First->getVectorKind() != VectorKind::RVVFixedLengthMask && + Second->getVectorKind() != VectorKind::RVVFixedLengthMask) return true; return false; @@ -9526,8 +9529,11 @@ static uint64_t getRVVTypeSize(ASTContext &Context, const BuiltinType *Ty) { ASTContext::BuiltinVectorTypeInfo Info = Context.getBuiltinVectorTypeInfo(Ty); - uint64_t EltSize = Context.getTypeSize(Info.ElementType); - uint64_t MinElts = Info.EC.getKnownMinValue(); + unsigned EltSize = Context.getTypeSize(Info.ElementType); + if (Info.ElementType == Context.BoolTy) + EltSize = 1; + + unsigned MinElts = Info.EC.getKnownMinValue(); return VScale->first * MinElts * EltSize; } @@ -9541,6 +9547,12 @@ bool ASTContext::areCompatibleRVVTypes(QualType FirstType, auto IsValidCast = [this](QualType FirstType, QualType SecondType) { if (const auto *BT = FirstType->getAs()) { if (const auto *VT = SecondType->getAs()) { + if (VT->getVectorKind() == VectorKind::RVVFixedLengthMask) { + BuiltinVectorTypeInfo Info = getBuiltinVectorTypeInfo(BT); + return FirstType->isRVVVLSBuiltinType() && + Info.ElementType == BoolTy && + getTypeSize(SecondType) == getRVVTypeSize(*this, BT); + } if (VT->getVectorKind() == VectorKind::RVVFixedLengthData || VT->getVectorKind() == VectorKind::Generic) return FirstType->isRVVVLSBuiltinType() && diff --git a/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp b/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp index f1d07d022b25..edf9b5e2d52b 100644 --- a/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp +++ b/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp @@ -7951,7 +7951,8 @@ public: // Overloaded operator calls to member functions are represented as normal // calls with '*this' as the first argument. const CXXMethodDecl *MD = dyn_cast(FD); - if (MD && MD->isImplicitObjectMemberFunction()) { + if (MD && + (MD->isImplicitObjectMemberFunction() || (OCE && MD->isStatic()))) { // FIXME: When selecting an implicit conversion for an overloaded // operator delete, we sometimes try to evaluate calls to conversion // operators without a 'this' parameter! @@ -7960,7 +7961,11 @@ public: if (!EvaluateObjectArgument(Info, Args[0], ThisVal)) return false; - This = &ThisVal; + + // If we are calling a static operator, the 'this' argument needs to be + // ignored after being evaluated. + if (MD->isInstance()) + This = &ThisVal; // If this is syntactically a simple assignment using a trivial // assignment operator, start the lifetimes of union members as needed, diff --git a/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp b/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp index 40b1e086ddd0..688141b30441 100644 --- a/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp +++ b/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp @@ -3994,7 +3994,8 @@ void CXXNameMangler::mangleAArch64FixedSveVectorType( } void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { - assert(T->getVectorKind() == VectorKind::RVVFixedLengthData && + assert((T->getVectorKind() == VectorKind::RVVFixedLengthData || + T->getVectorKind() == VectorKind::RVVFixedLengthMask) && "expected fixed-length RVV vector!"); QualType EltType = T->getElementType(); @@ -4009,7 +4010,10 @@ void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { TypeNameOS << "int8"; break; case BuiltinType::UChar: - TypeNameOS << "uint8"; + if (T->getVectorKind() == VectorKind::RVVFixedLengthData) + TypeNameOS << "uint8"; + else + TypeNameOS << "bool"; break; case BuiltinType::Short: TypeNameOS << "int16"; @@ -4048,12 +4052,16 @@ void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { auto VScale = getASTContext().getTargetInfo().getVScaleRange( getASTContext().getLangOpts()); unsigned VLen = VScale->first * llvm::RISCV::RVVBitsPerBlock; - TypeNameOS << 'm'; - if (VecSizeInBits >= VLen) - TypeNameOS << (VecSizeInBits / VLen); - else - TypeNameOS << 'f' << (VLen / VecSizeInBits); + if (T->getVectorKind() == VectorKind::RVVFixedLengthData) { + TypeNameOS << 'm'; + if (VecSizeInBits >= VLen) + TypeNameOS << (VecSizeInBits / VLen); + else + TypeNameOS << 'f' << (VLen / VecSizeInBits); + } else { + TypeNameOS << (VLen / VecSizeInBits); + } TypeNameOS << "_t"; Out << "9__RVV_VLSI" << 'u' << TypeNameStr.size() << TypeNameStr << "Lj" @@ -4093,7 +4101,8 @@ void CXXNameMangler::mangleType(const VectorType *T) { T->getVectorKind() == VectorKind::SveFixedLengthPredicate) { mangleAArch64FixedSveVectorType(T); return; - } else if (T->getVectorKind() == VectorKind::RVVFixedLengthData) { + } else if (T->getVectorKind() == VectorKind::RVVFixedLengthData || + T->getVectorKind() == VectorKind::RVVFixedLengthMask) { mangleRISCVFixedRVVVectorType(T); return; } diff --git a/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp b/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp index 3daba13d0fce..3c11b75d7472 100644 --- a/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp +++ b/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp @@ -703,6 +703,9 @@ void JSONNodeDumper::VisitVectorType(const VectorType *VT) { case VectorKind::RVVFixedLengthData: JOS.attribute("vectorKind", "fixed-length rvv data vector"); break; + case VectorKind::RVVFixedLengthMask: + JOS.attribute("vectorKind", "fixed-length rvv mask vector"); + break; } } diff --git a/contrib/llvm-project/clang/lib/AST/ODRHash.cpp b/contrib/llvm-project/clang/lib/AST/ODRHash.cpp index 5b98646a1e8d..2dbc259138a8 100644 --- a/contrib/llvm-project/clang/lib/AST/ODRHash.cpp +++ b/contrib/llvm-project/clang/lib/AST/ODRHash.cpp @@ -745,55 +745,8 @@ void ODRHash::AddEnumDecl(const EnumDecl *Enum) { if (Enum->isScoped()) AddBoolean(Enum->isScopedUsingClassTag()); - if (Enum->getIntegerTypeSourceInfo()) { - // FIMXE: This allows two enums with different spellings to have the same - // hash. - // - // // mod1.cppm - // module; - // extern "C" { - // typedef unsigned __int64 size_t; - // } - // namespace std { - // using :: size_t; - // } - // - // extern "C++" { - // namespace std { - // enum class align_val_t : std::size_t {}; - // } - // } - // - // export module mod1; - // export using std::align_val_t; - // - // // mod2.cppm - // module; - // extern "C" { - // typedef unsigned __int64 size_t; - // } - // - // extern "C++" { - // namespace std { - // enum class align_val_t : size_t {}; - // } - // } - // - // export module mod2; - // import mod1; - // export using std::align_val_t; - // - // The above example should be disallowed since it violates - // [basic.def.odr]p14: - // - // Each such definition shall consist of the same sequence of tokens - // - // The definitions of `std::align_val_t` in two module units have different - // spellings but we failed to give an error here. - // - // See https://github.com/llvm/llvm-project/issues/76638 for details. + if (Enum->getIntegerTypeSourceInfo()) AddQualType(Enum->getIntegerType().getCanonicalType()); - } // Filter out sub-Decls which will not be processed in order to get an // accurate count of Decl's. diff --git a/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp b/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp index 2bdbeb08ef20..3310d7dc24c5 100644 --- a/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp @@ -450,7 +450,8 @@ bool TemplateArgument::structurallyEquals(const TemplateArgument &Other) const { getAsIntegral() == Other.getAsIntegral(); case StructuralValue: { - if (getStructuralValueType() != Other.getStructuralValueType()) + if (getStructuralValueType().getCanonicalType() != + Other.getStructuralValueType().getCanonicalType()) return false; llvm::FoldingSetNodeID A, B; diff --git a/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp b/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp index 48c6729a6738..ecf5de0be543 100644 --- a/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp +++ b/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp @@ -1623,6 +1623,9 @@ void TextNodeDumper::VisitVectorType(const VectorType *T) { case VectorKind::RVVFixedLengthData: OS << " fixed-length rvv data vector"; break; + case VectorKind::RVVFixedLengthMask: + OS << " fixed-length rvv mask vector"; + break; } OS << " " << T->getNumElements(); } diff --git a/contrib/llvm-project/clang/lib/AST/Type.cpp b/contrib/llvm-project/clang/lib/AST/Type.cpp index 3db5ae182f32..d4103025591e 100644 --- a/contrib/llvm-project/clang/lib/AST/Type.cpp +++ b/contrib/llvm-project/clang/lib/AST/Type.cpp @@ -2479,6 +2479,9 @@ bool Type::isRVVVLSBuiltinType() const { IsFP, IsBF) \ case BuiltinType::Id: \ return NF == 1; +#define RVV_PREDICATE_TYPE(Name, Id, SingletonId, NumEls) \ + case BuiltinType::Id: \ + return true; #include "clang/Basic/RISCVVTypes.def" default: return false; @@ -2491,7 +2494,17 @@ QualType Type::getRVVEltType(const ASTContext &Ctx) const { assert(isRVVVLSBuiltinType() && "unsupported type!"); const BuiltinType *BTy = castAs(); - return Ctx.getBuiltinVectorTypeInfo(BTy).ElementType; + *** 11829 LINES SKIPPED *** From nobody Sat Apr 20 10:32:32 2024 X-Original-To: dev-commits-src-branches@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 4VM7B96RXCz5HWG7; Sat, 20 Apr 2024 10:32:33 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7B91cvTz4Q1W; Sat, 20 Apr 2024 10:32:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609153; 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=1zUXIwG5EC3ciU+zmeNBi/4XoKqokLA8cCfjnOgVEyA=; b=UzQknvXhO9XfT6mSknscXzZ6JryAQkEgSo0pVp8PNvo5HEuC2RquetT+LvJNUYJDKIE1Lm WLwlMwZ2dSVYvXG5bDaQ7zBx4dq8NJcVNeBvZpMjHh2cCb7bzxh8wmzQ7z7BMG/uQ+/gEF 89IbvntCmKGbttV7lfUnnRVanQ7NJC0+Mbkv9UYeVbROEWomtG2xagRgYljmwD4k1UAsTD iBSbMfhoKyG8+pKOP8mYU6NJ4CtHlCr9jkAHKWHC992XVd/KyQ10tNFapFh+B52ZVql+W1 6KJ0LP4u0wi4YQmS/Ux7j+0QR6TkVGtthe35n7bVkCX8d5ysLEJ6t4gRQWe7tA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609153; a=rsa-sha256; cv=none; b=MZK4XDhXTlDcMuNqGN7TSbTlF8lmxQP6FQRER1PpT4W+xy1j03aVOoYF/6NGjxfB2few3i 3nErCMxb75WcjZktCP2Vj7uAIr0RTliCrZIZUxPCuHI0FiW6EknMppg+p5H32WqFJHoNCZ Vu5RQQmF9unxulQDpWnvPJH9YwSY5qSelhHHT5APdxgDkDqD0ZVrZv8KMCtg6ksKWcrm3o LJrmDNzLnN61ci71XUSXzixmuMn1aHwOkX/gaueQyBTTgyzdVTAICEwp39+9/vYcCpLbRc vzmEH4WvJyOJwXJ6PsOWLwIS+b5kmMGMuADdU8kSy22XD+mtoMVfFi+3/xMr5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609153; 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=1zUXIwG5EC3ciU+zmeNBi/4XoKqokLA8cCfjnOgVEyA=; b=IHDcWMIc1lWxSkZkK8YC4JmiLTm4MmgAbgWmN0LzCDBsCB+rwMRUDyMRpG18pSVmNssrG8 KYihczuWZEQOQAAMe6DuWDiN9ZHa1nh0S5Ik+jZa4y/OcONlrsBewVSK3jH1SnXxVn9u5B JQC4hWBKmgDfWCrEsqZ1xdtAQiVwKZAvXtWdvtjzMw2V65oaUrtxq/BiyyJmJWbxv2+N3d 0kRG8c/vP7MnH4tyl1H+OpPZuDDdOeymABknrPH06ksXpMi2S1SEdXnX1YtDuKzSTRjgD5 7yL+OB3Y0E+7ICAw7HpIxIFfSBNXeAmW4R0HNJI0+b/LABd8u9EfSwMPczRYuQ== 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 4VM7B90ydlzZ4s; Sat, 20 Apr 2024 10:32:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWXN8011291; Sat, 20 Apr 2024 10:32:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWWib011288; Sat, 20 Apr 2024 10:32:32 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:32 GMT Message-Id: <202404201032.43KAWWib011288@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: 4b8be30b443f - stable/14 - Merge llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 4b8be30b443fbe9beeb0d9264b78d9d0575ab164 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=4b8be30b443fbe9beeb0d9264b78d9d0575ab164 commit 4b8be30b443fbe9beeb0d9264b78d9d0575ab164 Author: Dimitry Andric AuthorDate: 2024-02-20 18:57:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:16 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442. PR: 276104 MFC after: 1 month (cherry picked from commit 74626c16ff489c0d64cf2843dfd522e7c544f3ce) --- .../clang/include/clang/Basic/arm_sme.td | 28 +- .../clang/include/clang/Driver/Options.td | 12 + .../clang/lib/Basic/Targets/AArch64.cpp | 9 +- .../clang/lib/Driver/ToolChains/Arch/Sparc.cpp | 81 +++ .../clang/lib/Format/UnwrappedLineParser.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 2 +- .../clang/tools/clang-format/ClangFormat.cpp | 49 +- .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 203 ++----- .../compiler-rt/lib/dfsan/done_abilist.txt | 6 + .../lib/dfsan/libc_ubuntu1404_abilist.txt | 5 + .../lib/profile/InstrProfilingPlatformAIX.c | 4 +- contrib/llvm-project/libcxx/include/print | 14 +- .../llvm-project/libcxx/modules/CMakeLists.txt.in | 88 +++ .../llvm-project/libcxx/modules/std/ostream.inc | 4 +- contrib/llvm-project/libcxx/src/print.cpp | 25 +- contrib/llvm-project/lld/COFF/Driver.cpp | 10 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 156 +++++- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 29 +- contrib/llvm-project/lld/ELF/Arch/SystemZ.cpp | 607 +++++++++++++++++++++ contrib/llvm-project/lld/ELF/Driver.cpp | 3 +- contrib/llvm-project/lld/ELF/InputFiles.cpp | 2 + contrib/llvm-project/lld/ELF/InputSection.cpp | 14 +- contrib/llvm-project/lld/ELF/InputSection.h | 24 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 27 +- contrib/llvm-project/lld/ELF/Relocations.h | 3 + contrib/llvm-project/lld/ELF/ScriptParser.cpp | 1 + contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 3 + contrib/llvm-project/lld/ELF/Target.cpp | 2 + contrib/llvm-project/lld/ELF/Target.h | 4 + contrib/llvm-project/lld/ELF/Writer.cpp | 4 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 53 +- .../llvm/include/llvm/BinaryFormat/ELF.h | 1 + .../llvm/lib/Analysis/ValueTracking.cpp | 7 +- .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 2 + .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 27 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 2 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 11 +- .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 4 + .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 5 +- .../lib/Target/Mips/AsmParser/MipsAsmParser.cpp | 7 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 98 ++-- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 3 +- .../llvm-project/llvm/lib/Target/Sparc/Sparc.td | 14 + .../llvm/lib/Target/Sparc/SparcISelLowering.cpp | 43 ++ .../llvm/lib/Target/Sparc/SparcRegisterInfo.cpp | 14 +- .../llvm/lib/Target/Sparc/SparcRegisterInfo.h | 1 + .../llvm/lib/Target/Sparc/SparcRegisterInfo.td | 4 + .../llvm/lib/Target/Sparc/SparcSubtarget.cpp | 1 + .../llvm/lib/Target/Sparc/SparcSubtarget.h | 10 + .../llvm/lib/Target/X86/X86ISelLowering.cpp | 10 +- .../llvm/lib/Transforms/IPO/LowerTypeTests.cpp | 28 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 14 +- contrib/llvm-project/openmp/runtime/src/kmp.h | 7 +- .../openmp/runtime/src/kmp_csupport.cpp | 5 +- .../openmp/runtime/src/kmp_gsupport.cpp | 2 +- .../llvm-project/openmp/runtime/src/kmp_lock.cpp | 6 +- contrib/llvm-project/openmp/runtime/src/kmp_lock.h | 17 +- .../openmp/runtime/src/kmp_settings.cpp | 5 + lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- usr.bin/clang/lld/Makefile | 1 + 62 files changed, 1481 insertions(+), 352 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td b/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td index 695e1bddf9ff..2da0e8d2aba9 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td +++ b/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td @@ -44,6 +44,7 @@ defm SVLD1_ZA32 : ZALoad<"za32", "i", "aarch64_sme_ld1w", [ImmCheck<0, ImmCheck0 defm SVLD1_ZA64 : ZALoad<"za64", "l", "aarch64_sme_ld1d", [ImmCheck<0, ImmCheck0_7>]>; defm SVLD1_ZA128 : ZALoad<"za128", "q", "aarch64_sme_ld1q", [ImmCheck<0, ImmCheck0_15>]>; +let TargetGuard = "sme" in { def SVLDR_VNUM_ZA : MInst<"svldr_vnum_za", "vmQl", "", [IsOverloadNone, IsStreamingCompatible, IsInOutZA], MemEltTyDefault, "aarch64_sme_ldr">; @@ -51,6 +52,7 @@ def SVLDR_VNUM_ZA : MInst<"svldr_vnum_za", "vmQl", "", def SVLDR_ZA : MInst<"svldr_za", "vmQ", "", [IsOverloadNone, IsStreamingCompatible, IsInOutZA], MemEltTyDefault, "aarch64_sme_ldr", []>; +} //////////////////////////////////////////////////////////////////////////////// // Stores @@ -81,6 +83,7 @@ defm SVST1_ZA32 : ZAStore<"za32", "i", "aarch64_sme_st1w", [ImmCheck<0, ImmCheck defm SVST1_ZA64 : ZAStore<"za64", "l", "aarch64_sme_st1d", [ImmCheck<0, ImmCheck0_7>]>; defm SVST1_ZA128 : ZAStore<"za128", "q", "aarch64_sme_st1q", [ImmCheck<0, ImmCheck0_15>]>; +let TargetGuard = "sme" in { def SVSTR_VNUM_ZA : MInst<"svstr_vnum_za", "vm%l", "", [IsOverloadNone, IsStreamingCompatible, IsInZA], MemEltTyDefault, "aarch64_sme_str">; @@ -88,6 +91,7 @@ def SVSTR_VNUM_ZA : MInst<"svstr_vnum_za", "vm%l", "", def SVSTR_ZA : MInst<"svstr_za", "vm%", "", [IsOverloadNone, IsStreamingCompatible, IsInZA], MemEltTyDefault, "aarch64_sme_str", []>; +} //////////////////////////////////////////////////////////////////////////////// // Read horizontal/vertical ZA slices @@ -277,22 +281,22 @@ multiclass ZAAddSub { def NAME # _ZA32_VG1x2_I32 : Inst<"sv" # n_suffix # "_za32[_{d}]_vg1x2", "vm2", "iUif", MergeNone, "aarch64_sme_" # n_suffix # "_za32_vg1x2", [IsStreaming, IsInOutZA], []>; def NAME # _ZA32_VG1X4_I32 : Inst<"sv" # n_suffix # "_za32[_{d}]_vg1x4", "vm4", "iUif", MergeNone, "aarch64_sme_" # n_suffix # "_za32_vg1x4", [IsStreaming, IsInOutZA], []>; + } - let TargetGuard = "sme-i16i64" in { - def NAME # _WRITE_SINGLE_ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x2", "vm2d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_SINGLE_ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x4", "vm4d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x4", [IsStreaming, IsInOutZA], []>; + let TargetGuard = "sme2,sme-i16i64" in { + def NAME # _WRITE_SINGLE_ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x2", "vm2d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_SINGLE_ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x4", "vm4d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x4", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_ZA64_VG1x2_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x2", "vm22", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_ZA64_VG1x4_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x4", "vm44", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x4", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_ZA64_VG1x2_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x2", "vm22", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_ZA64_VG1x4_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x4", "vm44", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x4", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; - } + def NAME # _ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; + } - let TargetGuard = "sme-f64f64" in { - def NAME # _ZA64_VG1X2_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X4_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; - } + let TargetGuard = "sme2,sme-f64f64" in { + def NAME # _ZA64_VG1X2_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _ZA64_VG1X4_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; } } diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index e8d03fc26902..175bedbfb4d0 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -5815,6 +5815,18 @@ def mvis3 : Flag<["-"], "mvis3">, Group; def mno_vis3 : Flag<["-"], "mno-vis3">, Group; def mhard_quad_float : Flag<["-"], "mhard-quad-float">, Group; def msoft_quad_float : Flag<["-"], "msoft-quad-float">, Group; +foreach i = 1 ... 7 in + def ffixed_g#i : Flag<["-"], "ffixed-g"#i>, Group, + HelpText<"Reserve the G"#i#" register (SPARC only)">; +foreach i = 0 ... 5 in + def ffixed_o#i : Flag<["-"], "ffixed-o"#i>, Group, + HelpText<"Reserve the O"#i#" register (SPARC only)">; +foreach i = 0 ... 7 in + def ffixed_l#i : Flag<["-"], "ffixed-l"#i>, Group, + HelpText<"Reserve the L"#i#" register (SPARC only)">; +foreach i = 0 ... 5 in + def ffixed_i#i : Flag<["-"], "ffixed-i"#i>, Group, + HelpText<"Reserve the I"#i#" register (SPARC only)">; } // let Flags = [TargetSpecific] // M68k features flags diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 336b7a5e3d72..3036f461c1de 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -1187,6 +1187,8 @@ TargetInfo::BuiltinVaListKind AArch64TargetInfo::getBuiltinVaListKind() const { } const char *const AArch64TargetInfo::GCCRegNames[] = { + // clang-format off + // 32-bit Integer registers "w0", "w1", "w2", "w3", "w4", "w5", "w6", "w7", "w8", "w9", "w10", "w11", "w12", "w13", "w14", "w15", "w16", "w17", "w18", "w19", "w20", "w21", "w22", @@ -1223,7 +1225,12 @@ const char *const AArch64TargetInfo::GCCRegNames[] = { // SVE predicate-as-counter registers "pn0", "pn1", "pn2", "pn3", "pn4", "pn5", "pn6", "pn7", "pn8", - "pn9", "pn10", "pn11", "pn12", "pn13", "pn14", "pn15" + "pn9", "pn10", "pn11", "pn12", "pn13", "pn14", "pn15", + + // SME registers + "za", "zt0", + + // clang-format on }; ArrayRef AArch64TargetInfo::getGCCRegNames() const { diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp index 22e583021515..ae1a4ba78826 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp @@ -178,4 +178,85 @@ void sparc::getSparcTargetFeatures(const Driver &D, const ArgList &Args, else Features.push_back("-hard-quad-float"); } + + if (Args.hasArg(options::OPT_ffixed_g1)) + Features.push_back("+reserve-g1"); + + if (Args.hasArg(options::OPT_ffixed_g2)) + Features.push_back("+reserve-g2"); + + if (Args.hasArg(options::OPT_ffixed_g3)) + Features.push_back("+reserve-g3"); + + if (Args.hasArg(options::OPT_ffixed_g4)) + Features.push_back("+reserve-g4"); + + if (Args.hasArg(options::OPT_ffixed_g5)) + Features.push_back("+reserve-g5"); + + if (Args.hasArg(options::OPT_ffixed_g6)) + Features.push_back("+reserve-g6"); + + if (Args.hasArg(options::OPT_ffixed_g7)) + Features.push_back("+reserve-g7"); + + if (Args.hasArg(options::OPT_ffixed_o0)) + Features.push_back("+reserve-o0"); + + if (Args.hasArg(options::OPT_ffixed_o1)) + Features.push_back("+reserve-o1"); + + if (Args.hasArg(options::OPT_ffixed_o2)) + Features.push_back("+reserve-o2"); + + if (Args.hasArg(options::OPT_ffixed_o3)) + Features.push_back("+reserve-o3"); + + if (Args.hasArg(options::OPT_ffixed_o4)) + Features.push_back("+reserve-o4"); + + if (Args.hasArg(options::OPT_ffixed_o5)) + Features.push_back("+reserve-o5"); + + if (Args.hasArg(options::OPT_ffixed_l0)) + Features.push_back("+reserve-l0"); + + if (Args.hasArg(options::OPT_ffixed_l1)) + Features.push_back("+reserve-l1"); + + if (Args.hasArg(options::OPT_ffixed_l2)) + Features.push_back("+reserve-l2"); + + if (Args.hasArg(options::OPT_ffixed_l3)) + Features.push_back("+reserve-l3"); + + if (Args.hasArg(options::OPT_ffixed_l4)) + Features.push_back("+reserve-l4"); + + if (Args.hasArg(options::OPT_ffixed_l5)) + Features.push_back("+reserve-l5"); + + if (Args.hasArg(options::OPT_ffixed_l6)) + Features.push_back("+reserve-l6"); + + if (Args.hasArg(options::OPT_ffixed_l7)) + Features.push_back("+reserve-l7"); + + if (Args.hasArg(options::OPT_ffixed_i0)) + Features.push_back("+reserve-i0"); + + if (Args.hasArg(options::OPT_ffixed_i1)) + Features.push_back("+reserve-i1"); + + if (Args.hasArg(options::OPT_ffixed_i2)) + Features.push_back("+reserve-i2"); + + if (Args.hasArg(options::OPT_ffixed_i3)) + Features.push_back("+reserve-i3"); + + if (Args.hasArg(options::OPT_ffixed_i4)) + Features.push_back("+reserve-i4"); + + if (Args.hasArg(options::OPT_ffixed_i5)) + Features.push_back("+reserve-i5"); } diff --git a/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp b/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp index b904e0e56d9e..573919798870 100644 --- a/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp +++ b/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp @@ -2515,7 +2515,7 @@ bool UnwrappedLineParser::parseParens(TokenType AmpAmpTokenType) { parseChildBlock(); break; case tok::r_paren: - if (!MightBeStmtExpr && + if (!MightBeStmtExpr && !Line->InMacroBody && Style.RemoveParentheses > FormatStyle::RPS_Leave) { const auto *Prev = LeftParen->Previous; const auto *Next = Tokens->peekNextToken(); diff --git a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp index 4efcb3590355..0d9c087ed0cd 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp @@ -14062,7 +14062,7 @@ inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS, Expr::EvalResult EVResult; if (RHS.get()->EvaluateAsInt(EVResult, Context)) { llvm::APSInt Result = EVResult.Val.getInt(); - if ((getLangOpts().Bool && !RHS.get()->getType()->isBooleanType() && + if ((getLangOpts().CPlusPlus && !RHS.get()->getType()->isBooleanType() && !RHS.get()->getExprLoc().isMacroID()) || (Result != 0 && Result != 1)) { Diag(Loc, diag::warn_logical_instead_of_bitwise) diff --git a/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp b/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp index 5ee6092bb9bb..e122cea50f72 100644 --- a/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp +++ b/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp @@ -399,7 +399,8 @@ class ClangFormatDiagConsumer : public DiagnosticConsumer { }; // Returns true on error. -static bool format(StringRef FileName, bool IsSTDIN) { +static bool format(StringRef FileName) { + const bool IsSTDIN = FileName == "-"; if (!OutputXML && Inplace && IsSTDIN) { errs() << "error: cannot use -i when reading from stdin.\n"; return false; @@ -545,24 +546,25 @@ static void PrintVersion(raw_ostream &OS) { } // Dump the configuration. -static int dumpConfig(bool IsSTDIN) { +static int dumpConfig() { std::unique_ptr Code; - - // `FileNames` must have at least "-" in it even if no file was specified. - assert(!FileNames.empty()); - - // Read in the code in case the filename alone isn't enough to detect the - // language. - ErrorOr> CodeOrErr = - MemoryBuffer::getFileOrSTDIN(FileNames[0]); - if (std::error_code EC = CodeOrErr.getError()) { - llvm::errs() << EC.message() << "\n"; - return 1; + // We can't read the code to detect the language if there's no file name. + if (!FileNames.empty()) { + // Read in the code in case the filename alone isn't enough to detect the + // language. + ErrorOr> CodeOrErr = + MemoryBuffer::getFileOrSTDIN(FileNames[0]); + if (std::error_code EC = CodeOrErr.getError()) { + llvm::errs() << EC.message() << "\n"; + return 1; + } + Code = std::move(CodeOrErr.get()); } - Code = std::move(CodeOrErr.get()); - llvm::Expected FormatStyle = - clang::format::getStyle(Style, IsSTDIN ? AssumeFileName : FileNames[0], + clang::format::getStyle(Style, + FileNames.empty() || FileNames[0] == "-" + ? AssumeFileName + : FileNames[0], FallbackStyle, Code ? Code->getBuffer() : ""); if (!FormatStyle) { llvm::errs() << llvm::toString(FormatStyle.takeError()) << "\n"; @@ -682,11 +684,8 @@ int main(int argc, const char **argv) { return 0; } - if (FileNames.empty()) - FileNames.push_back("-"); - if (DumpConfig) - return dumpConfig(FileNames[0] == "-"); + return dumpConfig(); if (!Files.empty()) { std::ifstream ExternalFileOfFiles{std::string(Files)}; @@ -699,7 +698,10 @@ int main(int argc, const char **argv) { errs() << "Clang-formating " << LineNo << " files\n"; } - if (FileNames.size() != 1 && + if (FileNames.empty()) + return clang::format::format("-"); + + if (FileNames.size() > 1 && (!Offsets.empty() || !Lengths.empty() || !LineRanges.empty())) { errs() << "error: -offset, -length and -lines can only be used for " "single file.\n"; @@ -709,14 +711,13 @@ int main(int argc, const char **argv) { unsigned FileNo = 1; bool Error = false; for (const auto &FileName : FileNames) { - const bool IsSTDIN = FileName == "-"; - if (!IsSTDIN && isIgnored(FileName)) + if (isIgnored(FileName)) continue; if (Verbose) { errs() << "Formatting [" << FileNo++ << "/" << FileNames.size() << "] " << FileName << "\n"; } - Error |= clang::format::format(FileName, IsSTDIN); + Error |= clang::format::format(FileName); } return Error ? 1 : 0; } diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp b/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp index 85b796bd6349..3af26e9f64c9 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp @@ -55,6 +55,10 @@ using namespace __dfsan; #define DECLARE_WEAK_INTERCEPTOR_HOOK(f, ...) \ SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE void f(__VA_ARGS__); +#define WRAPPER_ALIAS(fun, real) \ + SANITIZER_INTERFACE_ATTRIBUTE void __dfsw_##fun() ALIAS(__dfsw_##real); \ + SANITIZER_INTERFACE_ATTRIBUTE void __dfso_##fun() ALIAS(__dfso_##real); + // Async-safe, non-reentrant spin lock. class SignalSpinLocker { public: @@ -1197,16 +1201,20 @@ char *__dfso_strcpy(char *dest, const char *src, dfsan_label dst_label, *ret_origin = dst_origin; return ret; } +} -static long int dfsan_strtol(const char *nptr, char **endptr, int base, - char **tmp_endptr) { +template +static ALWAYS_INLINE auto dfsan_strtol_impl( + Fn real, const char *nptr, char **endptr, int base, + char **tmp_endptr) -> decltype(real(nullptr, nullptr, 0)) { assert(tmp_endptr); - long int ret = strtol(nptr, tmp_endptr, base); + auto ret = real(nptr, tmp_endptr, base); if (endptr) *endptr = *tmp_endptr; return ret; } +extern "C" { static void dfsan_strtolong_label(const char *nptr, const char *tmp_endptr, dfsan_label base_label, dfsan_label *ret_label) { @@ -1236,30 +1244,6 @@ static void dfsan_strtolong_origin(const char *nptr, const char *tmp_endptr, } } -SANITIZER_INTERFACE_ATTRIBUTE -long int __dfsw_strtol(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - long int ret = dfsan_strtol(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long int __dfso_strtol(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - long int ret = dfsan_strtol(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - static double dfsan_strtod(const char *nptr, char **endptr, char **tmp_endptr) { assert(tmp_endptr); double ret = strtod(nptr, tmp_endptr); @@ -1307,108 +1291,40 @@ double __dfso_strtod(const char *nptr, char **endptr, dfsan_label nptr_label, return ret; } -static long long int dfsan_strtoll(const char *nptr, char **endptr, int base, - char **tmp_endptr) { - assert(tmp_endptr); - long long int ret = strtoll(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long int __dfsw_strtoll(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - long long int ret = dfsan_strtoll(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long int __dfso_strtoll(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, - dfsan_origin endptr_origin, - dfsan_origin base_origin, - dfsan_origin *ret_origin) { - char *tmp_endptr; - long long int ret = dfsan_strtoll(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - -static unsigned long int dfsan_strtoul(const char *nptr, char **endptr, - int base, char **tmp_endptr) { - assert(tmp_endptr); - unsigned long int ret = strtoul(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -unsigned long int __dfsw_strtoul(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - unsigned long int ret = dfsan_strtoul(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -unsigned long int __dfso_strtoul( - const char *nptr, char **endptr, int base, dfsan_label nptr_label, - dfsan_label endptr_label, dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - unsigned long int ret = dfsan_strtoul(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - -static long long unsigned int dfsan_strtoull(const char *nptr, char **endptr, - int base, char **tmp_endptr) { - assert(tmp_endptr); - long long unsigned int ret = strtoull(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long unsigned int __dfsw_strtoull(const char *nptr, char **endptr, - int base, dfsan_label nptr_label, - dfsan_label endptr_label, - dfsan_label base_label, - dfsan_label *ret_label) { - char *tmp_endptr; - long long unsigned int ret = dfsan_strtoull(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long unsigned int __dfso_strtoull( - const char *nptr, char **endptr, int base, dfsan_label nptr_label, - dfsan_label endptr_label, dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - long long unsigned int ret = dfsan_strtoull(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} +WRAPPER_ALIAS(__isoc23_strtod, strtod) + +#define WRAPPER_STRTO(ret_type, fun) \ + SANITIZER_INTERFACE_ATTRIBUTE ret_type __dfsw_##fun( \ + const char *nptr, char **endptr, int base, dfsan_label nptr_label, \ + dfsan_label endptr_label, dfsan_label base_label, \ + dfsan_label *ret_label) { \ + char *tmp_endptr; \ + auto ret = dfsan_strtol_impl(fun, nptr, endptr, base, &tmp_endptr); \ + dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); \ + return ret; \ + } \ + SANITIZER_INTERFACE_ATTRIBUTE ret_type __dfso_##fun( \ + const char *nptr, char **endptr, int base, dfsan_label nptr_label, \ + dfsan_label endptr_label, dfsan_label base_label, \ + dfsan_label *ret_label, dfsan_origin nptr_origin, \ + dfsan_origin endptr_origin, dfsan_origin base_origin, \ + dfsan_origin *ret_origin) { \ + char *tmp_endptr; \ + auto ret = dfsan_strtol_impl(fun, nptr, endptr, base, &tmp_endptr); \ + dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); \ + dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, \ + base_origin, ret_origin); \ + return ret; \ + } + +WRAPPER_STRTO(long, strtol) +WRAPPER_STRTO(long long, strtoll) +WRAPPER_STRTO(unsigned long, strtoul) +WRAPPER_STRTO(unsigned long long, strtoull) +WRAPPER_ALIAS(__isoc23_strtol, strtol) +WRAPPER_ALIAS(__isoc23_strtoll, strtoll) +WRAPPER_ALIAS(__isoc23_strtoul, strtoul) +WRAPPER_ALIAS(__isoc23_strtoull, strtoull) SANITIZER_INTERFACE_ATTRIBUTE time_t __dfsw_time(time_t *t, dfsan_label t_label, dfsan_label *ret_label) { @@ -2231,7 +2147,7 @@ SANITIZER_INTERFACE_ATTRIBUTE int __dfso_write( *ret_label = 0; return write(fd, buf, count); } -} // namespace __dfsan +} // namespace __dfsan // Type used to extract a dfsan_label with va_arg() typedef int dfsan_label_va; @@ -2866,31 +2782,8 @@ int __dfso_sscanf(char *str, const char *format, dfsan_label str_label, return ret; } -SANITIZER_INTERFACE_ATTRIBUTE -int __dfsw___isoc99_sscanf(char *str, const char *format, dfsan_label str_label, - dfsan_label format_label, dfsan_label *va_labels, - dfsan_label *ret_label, ...) { - va_list ap; - va_start(ap, ret_label); - int ret = scan_buffer(str, ~0ul, format, va_labels, ret_label, nullptr, - nullptr, ap); - va_end(ap); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -int __dfso___isoc99_sscanf(char *str, const char *format, dfsan_label str_label, - dfsan_label format_label, dfsan_label *va_labels, - dfsan_label *ret_label, dfsan_origin str_origin, - dfsan_origin format_origin, dfsan_origin *va_origins, - dfsan_origin *ret_origin, ...) { - va_list ap; - va_start(ap, ret_origin); - int ret = scan_buffer(str, ~0ul, format, va_labels, ret_label, &str_origin, - ret_origin, ap); - va_end(ap); - return ret; -} +WRAPPER_ALIAS(__isoc99_sscanf, sscanf) +WRAPPER_ALIAS(__isoc23_sscanf, sscanf) static void BeforeFork() { StackDepotLockBeforeFork(); diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt b/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt index c582584d77e4..86a42ee1b4dc 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt @@ -270,6 +270,11 @@ fun:strtoul=custom fun:strtoull=custom fun:strcat=custom fun:strncat=custom +fun:__isoc23_strtod=custom +fun:__isoc23_strtol=custom +fun:__isoc23_strtoll=custom +fun:__isoc23_strtoul=custom +fun:__isoc23_strtoull=custom # Functions that produce an output that is computed from the input, but is not # necessarily data dependent. @@ -311,6 +316,7 @@ fun:snprintf=custom # scanf-like fun:sscanf=custom fun:__isoc99_sscanf=custom +fun:__isoc23_sscanf=custom # TODO: custom fun:asprintf=discard diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt b/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt index 433092e2b27b..9ffa56a23818 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt @@ -1,3 +1,8 @@ +fun:__isoc23_sscanf=uninstrumented +fun:__isoc23_strtol=uninstrumented +fun:__isoc23_strtoll=uninstrumented +fun:__isoc23_strtoul=uninstrumented +fun:__isoc23_strtoull=uninstrumented fun:_Exit=uninstrumented fun:_IO_adjust_column=uninstrumented fun:_IO_adjust_wcolumn=uninstrumented diff --git a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c index 9f46a98d78ac..002bec164d7e 100644 --- a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c +++ b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c @@ -195,6 +195,8 @@ static const int dummy_name[0] COMPILER_RT_SECTION( COMPILER_RT_SEG INSTR_PROF_NAME_SECT_NAME); static int dummy_vnds[0] COMPILER_RT_SECTION( COMPILER_RT_SEG INSTR_PROF_VNODES_SECT_NAME); +static int dummy_orderfile[0] COMPILER_RT_SECTION( + COMPILER_RT_SEG INSTR_PROF_ORDERFILE_SECT_NAME); // To avoid GC'ing of the dummy variables by the linker, reference them in an // array and reference the array in the runtime registration code @@ -206,7 +208,7 @@ static int dummy_vnds[0] COMPILER_RT_SECTION( COMPILER_RT_VISIBILITY void *__llvm_profile_keep[] = {(void *)&dummy_cnts, (void *)&dummy_bits, (void *)&dummy_data, (void *)&dummy_name, - (void *)&dummy_vnds}; + (void *)&dummy_vnds, (void *)&dummy_orderfile}; #ifdef __GNUC__ #pragma GCC diagnostic pop #endif diff --git a/contrib/llvm-project/libcxx/include/print b/contrib/llvm-project/libcxx/include/print index 7f2b5bac3dcf..543a540ee4f2 100644 --- a/contrib/llvm-project/libcxx/include/print +++ b/contrib/llvm-project/libcxx/include/print @@ -32,6 +32,7 @@ namespace std { */ #include <__assert> // all public C++ headers provide the assertion handler +#include <__availability> #include <__concepts/same_as.h> #include <__config> #include <__system_error/system_error.h> @@ -43,10 +44,6 @@ namespace std { #include #include -#if __has_include() -# include -#endif - #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) # pragma GCC system_header #endif @@ -68,7 +65,8 @@ _LIBCPP_EXPORTED_FROM_ABI bool __is_windows_terminal(FILE* __stream); // Note the function is only implemented on the Windows platform. _LIBCPP_EXPORTED_FROM_ABI void __write_to_windows_console(FILE* __stream, wstring_view __view); # endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS - +#elif __has_include() +_LIBCPP_EXPORTED_FROM_ABI bool __is_posix_terminal(FILE* __stream); #endif // _LIBCPP_WIN32API #if _LIBCPP_STD_VER >= 23 @@ -195,15 +193,17 @@ inline constexpr bool __use_unicode_execution_charset = _MSVC_EXECUTION_CHARACTE inline constexpr bool __use_unicode_execution_charset = true; # endif -_LIBCPP_HIDE_FROM_ABI inline bool __is_terminal(FILE* __stream) { +_LIBCPP_HIDE_FROM_ABI inline bool __is_terminal([[maybe_unused]] FILE* __stream) { // The macro _LIBCPP_TESTING_PRINT_IS_TERMINAL is used to change // the behavior in the test. This is not part of the public API. # ifdef _LIBCPP_TESTING_PRINT_IS_TERMINAL return _LIBCPP_TESTING_PRINT_IS_TERMINAL(__stream); +# elif _LIBCPP_AVAILABILITY_HAS_PRINT == 0 + return false; # elif defined(_LIBCPP_WIN32API) return std::__is_windows_terminal(__stream); # elif __has_include() - return isatty(fileno(__stream)); + return std::__is_posix_terminal(__stream); # else # error "Provide a way to determine whether a FILE* is a terminal" # endif diff --git a/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in b/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in new file mode 100644 index 000000000000..e332d70cc163 --- /dev/null +++ b/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in @@ -0,0 +1,88 @@ +cmake_minimum_required(VERSION 3.26) + +project(libc++-modules LANGUAGES CXX) + +# Enable CMake's module support +if(CMAKE_VERSION VERSION_LESS "3.28.0") + if(CMAKE_VERSION VERSION_LESS "3.27.0") + set(CMAKE_EXPERIMENTAL_CXX_MODULE_CMAKE_API "2182bf5c-ef0d-489a-91da-49dbc3090d2a") + else() + set(CMAKE_EXPERIMENTAL_CXX_MODULE_CMAKE_API "aa1f7df0-828a-4fcd-9afc-2dc80491aca7") + endif() + set(CMAKE_EXPERIMENTAL_CXX_MODULE_DYNDEP 1) +else() + cmake_policy(VERSION 3.28) +endif() + +# Default to C++ extensions being off. Libc++'s modules support have trouble +# with extensions right now. +set(CMAKE_CXX_EXTENSIONS OFF) + +# Propagates the CMake options to the modules. +# +# This uses the std module hard-coded since the std.compat module does not +# depend on these flags. +macro(compile_define_if_not condition def) + if (NOT ${condition}) + target_compile_definitions(std PRIVATE ${def}) + endif() +endmacro() +macro(compile_define_if condition def) + if (${condition}) + target_compile_definitions(std PRIVATE ${def}) + endif() +endmacro() + +### STD + +add_library(std) +target_sources(std + PUBLIC FILE_SET cxx_modules TYPE CXX_MODULES FILES + std.cppm +) + +target_include_directories(std SYSTEM PRIVATE @LIBCXX_CONFIGURED_INCLUDE_DIRS@) + +if (NOT @LIBCXX_ENABLE_EXCEPTIONS@) + target_compile_options(std PUBLIC -fno-exceptions) +endif() + +target_compile_options(std + PUBLIC + -nostdinc++ + -Wno-reserved-module-identifier + -Wno-reserved-user-defined-literal + @LIBCXX_COMPILE_FLAGS@ +) +set_target_properties(std + PROPERTIES + OUTPUT_NAME "c++std" +) + +### STD.COMPAT + +add_library(std.compat) +target_sources(std.compat + PUBLIC FILE_SET cxx_modules TYPE CXX_MODULES FILES + std.compat.cppm +) + +target_include_directories(std.compat SYSTEM PRIVATE @LIBCXX_CONFIGURED_INCLUDE_DIRS@) + +if (NOT @LIBCXX_ENABLE_EXCEPTIONS@) + target_compile_options(std.compat PUBLIC -fno-exceptions) +endif() + +target_compile_options(std.compat + PUBLIC + -nostdinc++ + -Wno-reserved-module-identifier + -Wno-reserved-user-defined-literal + -fmodule-file=std=${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/std.dir/std.pcm + @LIBCXX_COMPILE_FLAGS@ +) +set_target_properties(std.compat + PROPERTIES + OUTPUT_NAME "c++std.compat" +) +add_dependencies(std.compat std) diff --git a/contrib/llvm-project/libcxx/modules/std/ostream.inc b/contrib/llvm-project/libcxx/modules/std/ostream.inc index 8fcbfb4bdc18..0e0e2d54fe6b 100644 --- a/contrib/llvm-project/libcxx/modules/std/ostream.inc +++ b/contrib/llvm-project/libcxx/modules/std/ostream.inc @@ -33,8 +33,10 @@ export namespace std { using std::println; using std::vprint_nonunicode; +# ifndef _LIBCPP_HAS_NO_UNICODE using std::vprint_unicode; -# endif // _LIBCPP_STD_VER >= 23 +# endif // _LIBCPP_HAS_NO_UNICODE +# endif // _LIBCPP_STD_VER >= 23 #endif // _LIBCPP_HAS_NO_LOCALIZATION } // namespace std diff --git a/contrib/llvm-project/libcxx/src/print.cpp b/contrib/llvm-project/libcxx/src/print.cpp index 3692187a5954..8fa59fdd097b 100644 --- a/contrib/llvm-project/libcxx/src/print.cpp +++ b/contrib/llvm-project/libcxx/src/print.cpp @@ -8,22 +8,26 @@ #include <__config> -#if defined(_LIBCPP_WIN32API) +#include +#include + +#include <__system_error/system_error.h> -# include -# include +#include "filesystem/error.h" +#if defined(_LIBCPP_WIN32API) # define WIN32_LEAN_AND_MEAN # define NOMINMAX # include # include - -# include <__system_error/system_error.h> - -# include "filesystem/error.h" +#elif __has_include() +# include +#endif _LIBCPP_BEGIN_NAMESPACE_STD +#if defined(_LIBCPP_WIN32API) + _LIBCPP_EXPORTED_FROM_ABI bool __is_windows_terminal(FILE* __stream) { // Note the Standard does this in one call, but it's unclear whether // an invalid handle is allowed when calling GetConsoleMode. @@ -52,6 +56,9 @@ __write_to_windows_console([[maybe_unused]] FILE* __stream, [[maybe_unused]] wst } # endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS -_LIBCPP_END_NAMESPACE_STD +#elif __has_include() // !_LIBCPP_WIN32API -#endif // !_LIBCPP_WIN32API +_LIBCPP_EXPORTED_FROM_ABI bool __is_posix_terminal(FILE* __stream) { return isatty(fileno(__stream)); } +#endif + +_LIBCPP_END_NAMESPACE_STD diff --git a/contrib/llvm-project/lld/COFF/Driver.cpp b/contrib/llvm-project/lld/COFF/Driver.cpp index e0afb6b18805..22ee2f133be9 100644 --- a/contrib/llvm-project/lld/COFF/Driver.cpp +++ b/contrib/llvm-project/lld/COFF/Driver.cpp @@ -1825,7 +1825,15 @@ void LinkerDriver::linkerMain(ArrayRef argsArr) { } } else { config->repro = false; - config->timestamp = time(nullptr); + if (std::optional epoch = + Process::GetEnv("SOURCE_DATE_EPOCH")) { + StringRef value(*epoch); + if (value.getAsInteger(0, config->timestamp)) + fatal(Twine("invalid SOURCE_DATE_EPOCH timestamp: ") + value + + ". Expected 32-bit integer"); + } else { + config->timestamp = time(nullptr); + } } // Handle /alternatename diff --git a/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp b/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp index ab2ec5b447d0..05fd38fb753f 100644 --- a/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp +++ b/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp @@ -36,6 +36,8 @@ public: bool usesOnlyLowPageBits(RelType type) const override; void relocate(uint8_t *loc, const Relocation &rel, uint64_t val) const override; + bool relaxOnce(int pass) const override; + void finalizeRelax(int passes) const override; }; } // end anonymous namespace @@ -465,8 +467,9 @@ RelExpr LoongArch::getRelExpr(const RelType type, const Symbol &s, case R_LARCH_TLS_GD_HI20: return R_TLSGD_GOT; case R_LARCH_RELAX: - // LoongArch linker relaxation is not implemented yet. - return R_NONE; *** 2151 LINES SKIPPED *** From nobody Sat Apr 20 10:32:35 2024 X-Original-To: dev-commits-src-branches@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 4VM7BC5zKKz5HVs2; Sat, 20 Apr 2024 10:32:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BC40MWz4Q1r; Sat, 20 Apr 2024 10:32:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609155; 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=MyQU8T0u9g4QpigrII5dGSGmCZghng8UzyyYuM2bmic=; b=o/E2tqlozkbtvAEg8M3i/ENk5/US8jdhbrsCyTWsB8gHBCSa/sETMkcYjnX7y3Ev+CAn5L OV1UUqsPjdHLiMZkNTGGSBRoO/cxfRwxKOIKzRsVJDy39ccbS8sHoCWMI/Dv9OLgOg64DK 4mvIFqO0VP5KDYZ8GIuRp6dh8hbTtldRQ+yk7okWYfLwpMtctRV+P7E/jyziTs/vTTbPgl 0YxfZEc5uf6oIt0HWicsrTgsgsLtMhU679z09GYmF6wVldcT8QecWveKzk0GAQud/Z4+NZ p+0KRCMcnKYv9IZe9xmXfLLvbwby2Ufpx8KJ7TMfD5groKh1YyB9HGrKRBg+rg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609155; a=rsa-sha256; cv=none; b=IEcrsLb/kWpTe8oCM1SPhwEfSVBHl3+/BsENGFUzcHycdLai4fjlBxqcd787ySMSBEnaj4 1162B10I2pNZmY23UROy22htxiGmmDi5v1FMAi/ibaYtdmQWZfy3mVGqLW1qXydOFVnyOv gpvgDfwVqfBEvpDRm3MTBWAu2ekhMH3pQyx2SJ9+qEj93OelY6FtzrBaDk6PVmfAYjhFT6 +/oBdh+q4bHK37pRyWEtV+1VuGXHvaq0UQlAxpguOJyqeUPwbHiFIKV5u4wqw5jG9+ZnkO 92HGdg46HWY7HqFaaZPQ03AuEI9s/fIZxmLlAlJzWDeTnzHccylqmOg405lX6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609155; 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=MyQU8T0u9g4QpigrII5dGSGmCZghng8UzyyYuM2bmic=; b=krjixsKpYVQ9yzWj4aBdeW6INVIhoPphKSmFm5BDDRh3XJIvSu6FawSPZN9LY7EhGNRxHf E/YY96L7jeeHLCGP5B48iTW2fwLDcAJwuu4sOOeU6gwbz96N8TYxbxRBGL9W4cUn+aC68v 5FLssowHEvPqntXwMIZE95BeQrqO7/o/NAiHOZWd5/dnAUrsKAhga4j4JpEdBgpmzTPOS9 4B+rtgsRbeZrHudki01tsXKrZckBOwnpkHvGuTtFymoJ4AHjH8ygAEXJO4SRaJXwwyRNc9 0xd0baAeItwHclQoKZQFravaXR6isDV8SkS48J03jBVOkcQIm2Esu1bEdGfXHQ== 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 4VM7BC3bSgzYkH; Sat, 20 Apr 2024 10:32:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWZEZ011375; Sat, 20 Apr 2024 10:32:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWZMF011372; Sat, 20 Apr 2024 10:32:35 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:35 GMT Message-Id: <202404201032.43KAWZMF011372@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: 471f3ba46090 - stable/14 - Merge llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 471f3ba460906d3bca33d0bff87d0e73a9f93e9c Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=471f3ba460906d3bca33d0bff87d0e73a9f93e9c commit 471f3ba460906d3bca33d0bff87d0e73a9f93e9c Author: Dimitry Andric AuthorDate: 2024-03-10 12:37:50 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:17 +0000 Merge llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e. PR: 276104 MFC after: 1 month (cherry picked from commit 4c2d3b022a1d543dbbff75a0c53e8d3d7242216d) --- .../llvm-project/clang/include/clang/Sema/Sema.h | 4 +- .../clang/lib/Basic/Targets/AArch64.cpp | 1 - .../llvm-project/clang/lib/Basic/Targets/Mips.h | 4 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 11 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 4 +- contrib/llvm-project/libcxx/include/csetjmp | 8 +- .../llvm/include/llvm/ADT/iterator_range.h | 4 +- .../llvm/include/llvm/IR/Attributes.td | 28 +- .../llvm/TargetParser/AArch64TargetParser.h | 8 +- contrib/llvm-project/llvm/lib/Analysis/Loads.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Attributes.cpp | 5 + .../llvm/lib/Target/AArch64/AArch64.td | 27 + .../llvm/lib/Target/AArch64/AArch64SchedA53.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedA57.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedA64FX.td | 3 +- .../lib/Target/AArch64/AArch64SchedAmpere1B.td | 1149 ++++++++++++++++++++ .../llvm/lib/Target/AArch64/AArch64SchedCyclone.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM3.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM4.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM5.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedFalkor.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedKryo.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseN1.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseN2.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV1.td | 3 +- .../lib/Target/AArch64/AArch64SchedNeoverseV2.td | 3 +- .../llvm/lib/Target/AArch64/AArch64SchedTSV110.td | 2 +- .../lib/Target/AArch64/AArch64SchedThunderX.td | 2 +- .../lib/Target/AArch64/AArch64SchedThunderX2T99.td | 2 +- .../Target/AArch64/AArch64SchedThunderX3T110.td | 2 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.cpp | 1 + .../llvm/lib/Target/AArch64/AArch64Subtarget.h | 1 + .../lib/Target/Mips/AsmParser/MipsAsmParser.cpp | 78 +- .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 10 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 5 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 1 + .../llvm/lib/Transforms/Utils/FlattenCFG.cpp | 14 +- .../llvm/lib/Transforms/Utils/Local.cpp | 8 +- .../llvm/tools/llvm-cov/SourceCoverageView.cpp | 2 +- .../llvm/tools/llvm-cov/SourceCoverageViewHTML.cpp | 9 +- .../llvm/tools/llvm-cov/SourceCoverageViewText.cpp | 3 +- .../llvm/tools/llvm-readobj/ObjDumper.cpp | 26 +- .../llvm/tools/llvm-readobj/ObjDumper.h | 4 +- .../llvm-project/llvm/tools/llvm-readobj/Opts.td | 2 + .../llvm/tools/llvm-readobj/llvm-readobj.cpp | 6 +- .../llvm/utils/TableGen/Attributes.cpp | 6 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/liblldb/LLDBWrapLua.cpp | 162 +-- 54 files changed, 1501 insertions(+), 163 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/Sema/Sema.h b/contrib/llvm-project/clang/include/clang/Sema/Sema.h index 1f1cbd11ff73..6adb8fb7966b 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Sema.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Sema.h @@ -1090,7 +1090,9 @@ public: if (FD) { FD->setWillHaveBody(true); S.ExprEvalContexts.back().InImmediateFunctionContext = - FD->isImmediateFunction(); + FD->isImmediateFunction() || + S.ExprEvalContexts[S.ExprEvalContexts.size() - 2] + .isConstantEvaluated(); S.ExprEvalContexts.back().InImmediateEscalatingFunctionContext = S.getLangOpts().CPlusPlus20 && FD->isImmediateEscalating(); } else diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 3036f461c1de..f5a5d689fa09 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -258,7 +258,6 @@ void AArch64TargetInfo::getTargetDefinesARMV83A(const LangOptions &Opts, MacroBuilder &Builder) const { Builder.defineMacro("__ARM_FEATURE_COMPLEX", "1"); Builder.defineMacro("__ARM_FEATURE_JCVT", "1"); - Builder.defineMacro("__ARM_FEATURE_PAUTH", "1"); // Also include the Armv8.2 defines getTargetDefinesARMV82A(Opts, Builder); } diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h b/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h index f46b95abfd75..23d4e1b598fa 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h +++ b/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h @@ -237,12 +237,14 @@ public: case 'r': // CPU registers. case 'd': // Equivalent to "r" unless generating MIPS16 code. case 'y': // Equivalent to "r", backward compatibility only. - case 'f': // floating-point registers. case 'c': // $25 for indirect jumps case 'l': // lo register case 'x': // hilo register pair Info.setAllowsRegister(); return true; + case 'f': // floating-point registers. + Info.setAllowsRegister(); + return FloatABI != SoftFloat; case 'I': // Signed 16-bit constant case 'J': // Integer 0 case 'K': // Unsigned 16-bit constant diff --git a/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp b/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp index 5d7c38477457..fb4e86e8bd80 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp @@ -240,9 +240,12 @@ struct MapRegionCounters : public RecursiveASTVisitor { if (MCDCMaxCond == 0) return true; - /// At the top of the logical operator nest, reset the number of conditions. - if (LogOpStack.empty()) + /// At the top of the logical operator nest, reset the number of conditions, + /// also forget previously seen split nesting cases. + if (LogOpStack.empty()) { NumCond = 0; + SplitNestedLogicalOp = false; + } if (const Expr *E = dyn_cast(S)) { const BinaryOperator *BinOp = dyn_cast(E->IgnoreParens()); @@ -293,7 +296,7 @@ struct MapRegionCounters : public RecursiveASTVisitor { "contains an operation with a nested boolean expression. " "Expression will not be covered"); Diag.Report(S->getBeginLoc(), DiagID); - return false; + return true; } /// Was the maximum number of conditions encountered? @@ -304,7 +307,7 @@ struct MapRegionCounters : public RecursiveASTVisitor { "number of conditions (%0) exceeds max (%1). " "Expression will not be covered"); Diag.Report(S->getBeginLoc(), DiagID) << NumCond << MCDCMaxCond; - return false; + return true; } // Otherwise, allocate the number of bytes required for the bitmap diff --git a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp index 0d9c087ed0cd..4cce0abc2315 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp @@ -18294,7 +18294,6 @@ void Sema::CheckUnusedVolatileAssignment(Expr *E) { } void Sema::MarkExpressionAsImmediateEscalating(Expr *E) { - assert(!FunctionScopes.empty() && "Expected a function scope"); assert(getLangOpts().CPlusPlus20 && ExprEvalContexts.back().InImmediateEscalatingFunctionContext && "Cannot mark an immediate escalating expression outside of an " @@ -18311,7 +18310,8 @@ void Sema::MarkExpressionAsImmediateEscalating(Expr *E) { } else { assert(false && "expected an immediately escalating expression"); } - getCurFunction()->FoundImmediateEscalatingExpression = true; + if (FunctionScopeInfo *FI = getCurFunction()) + FI->FoundImmediateEscalatingExpression = true; } ExprResult Sema::CheckForImmediateInvocation(ExprResult E, FunctionDecl *Decl) { diff --git a/contrib/llvm-project/libcxx/include/csetjmp b/contrib/llvm-project/libcxx/include/csetjmp index d219c8e6cb22..9012cad22ebe 100644 --- a/contrib/llvm-project/libcxx/include/csetjmp +++ b/contrib/llvm-project/libcxx/include/csetjmp @@ -33,7 +33,13 @@ void longjmp(jmp_buf env, int val); #include <__assert> // all public C++ headers provide the assertion handler #include <__config> -#include +// is not provided by libc++ +#if __has_include() +# include +# ifdef _LIBCPP_SETJMP_H +# error "If libc++ starts defining , the __has_include check should move to libc++'s " +# endif +#endif #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) # pragma GCC system_header diff --git a/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h b/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h index 2dc227935984..7d288ea4506b 100644 --- a/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h +++ b/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h @@ -43,8 +43,8 @@ class iterator_range { IteratorT begin_iterator, end_iterator; public: -#if __GNUC__ == 7 - // Be careful no to break gcc-7 on the mlir target. +#if __GNUC__ == 7 || (__GNUC__ == 8 && __GNUC_MINOR__ < 4) + // Be careful no to break gcc-7 and gcc-8 < 8.4 on the mlir target. // See https://github.com/llvm/llvm-project/issues/63843 template #else diff --git a/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td b/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td index 864f87f33838..d22eb76d2292 100644 --- a/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td +++ b/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td @@ -339,14 +339,26 @@ def UseSampleProfile : StrBoolAttr<"use-sample-profile">; def DenormalFPMath : ComplexStrAttr<"denormal-fp-math", [FnAttr]>; def DenormalFPMathF32 : ComplexStrAttr<"denormal-fp-math-f32", [FnAttr]>; +// Attribute compatiblity rules are generated to check the attribute of the +// caller and callee and decide whether inlining should be allowed. CompatRule +// and child classes are used for the rule generation. CompatRule takes only a +// compare function which could be templated with the attribute type. +// CompatRuleStrAttr takes the compare function and the string attribute for +// checking compatibility for inline substitution. class CompatRule { - // The name of the function called to check the attribute of the caller and - // callee and decide whether inlining should be allowed. The function's - // signature must match "bool(const Function&, const Function &)", where the - // first parameter is the reference to the caller and the second parameter is - // the reference to the callee. It must return false if the attributes of the - // caller and callee are incompatible, and true otherwise. + // The function's signature must match "bool(const Function&, const + // Function&)", where the first parameter is the reference to the caller and + // the second parameter is the reference to the callee. It must return false + // if the attributes of the caller and callee are incompatible, and true + // otherwise. string CompatFunc = F; + string AttrName = ""; +} + +class CompatRuleStrAttr : CompatRule { + // The checker function is extended with an third argument as the function + // attribute string "bool(const Function&, const Function&, const StringRef&)". + string AttrName = Attr; } def : CompatRule<"isEqual">; @@ -359,7 +371,9 @@ def : CompatRule<"isEqual">; def : CompatRule<"isEqual">; def : CompatRule<"isEqual">; def : CompatRule<"checkDenormMode">; - +def : CompatRuleStrAttr<"isEqual", "sign-return-address">; +def : CompatRuleStrAttr<"isEqual", "sign-return-address-key">; +def : CompatRuleStrAttr<"isEqual", "branch-protection-pauth-lr">; class MergeRule { // The name of the function called to merge the attributes of the caller and diff --git a/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h b/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h index 6d82748d8004..c10f92e28717 100644 --- a/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h +++ b/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h @@ -478,7 +478,7 @@ inline constexpr ArchInfo ARMV8_1A = { VersionTuple{8, 1}, AProfile, "armv8.1-a inline constexpr ArchInfo ARMV8_2A = { VersionTuple{8, 2}, AProfile, "armv8.2-a", "+v8.2a", (ARMV8_1A.DefaultExts | AArch64::ExtensionBitset({AArch64::AEK_RAS}))}; inline constexpr ArchInfo ARMV8_3A = { VersionTuple{8, 3}, AProfile, "armv8.3-a", "+v8.3a", (ARMV8_2A.DefaultExts | - AArch64::ExtensionBitset({AArch64::AEK_RCPC, AArch64::AEK_JSCVT, AArch64::AEK_FCMA}))}; + AArch64::ExtensionBitset({AArch64::AEK_FCMA, AArch64::AEK_JSCVT, AArch64::AEK_PAUTH, AArch64::AEK_RCPC}))}; inline constexpr ArchInfo ARMV8_4A = { VersionTuple{8, 4}, AProfile, "armv8.4-a", "+v8.4a", (ARMV8_3A.DefaultExts | AArch64::ExtensionBitset({AArch64::AEK_DOTPROD}))}; inline constexpr ArchInfo ARMV8_5A = { VersionTuple{8, 5}, AProfile, "armv8.5-a", "+v8.5a", (ARMV8_4A.DefaultExts)}; @@ -805,6 +805,12 @@ inline constexpr CpuInfo CpuInfos[] = { {AArch64::AEK_FP16, AArch64::AEK_RAND, AArch64::AEK_SM4, AArch64::AEK_SHA3, AArch64::AEK_SHA2, AArch64::AEK_AES, AArch64::AEK_MTE, AArch64::AEK_SB, AArch64::AEK_SSBS}))}, + {"ampere1b", ARMV8_7A, + (AArch64::ExtensionBitset({AArch64::AEK_FP16, AArch64::AEK_RAND, + AArch64::AEK_SM4, AArch64::AEK_SHA3, + AArch64::AEK_SHA2, AArch64::AEK_AES, + AArch64::AEK_MTE, AArch64::AEK_SB, + AArch64::AEK_SSBS, AArch64::AEK_CSSC}))}, }; // An alias for a CPU. diff --git a/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp b/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp index 6bf0d2f56eb4..5916d2ab48ec 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp @@ -364,7 +364,7 @@ bool llvm::isSafeToLoadUnconditionally(Value *V, Align Alignment, APInt &Size, if (Size.getBitWidth() > 64) return false; - const uint64_t LoadSize = Size.getZExtValue(); + const TypeSize LoadSize = TypeSize::getFixed(Size.getZExtValue()); // Otherwise, be a little bit aggressive by scanning the local block where we // want to check to see if the pointer is already being loaded or stored @@ -414,11 +414,11 @@ bool llvm::isSafeToLoadUnconditionally(Value *V, Align Alignment, APInt &Size, // Handle trivial cases. if (AccessedPtr == V && - LoadSize <= DL.getTypeStoreSize(AccessedTy)) + TypeSize::isKnownLE(LoadSize, DL.getTypeStoreSize(AccessedTy))) return true; if (AreEquivalentAddressValues(AccessedPtr->stripPointerCasts(), V) && - LoadSize <= DL.getTypeStoreSize(AccessedTy)) + TypeSize::isKnownLE(LoadSize, DL.getTypeStoreSize(AccessedTy))) return true; } return false; diff --git a/contrib/llvm-project/llvm/lib/IR/Attributes.cpp b/contrib/llvm-project/llvm/lib/IR/Attributes.cpp index fd5160209506..19076771ff2e 100644 --- a/contrib/llvm-project/llvm/lib/IR/Attributes.cpp +++ b/contrib/llvm-project/llvm/lib/IR/Attributes.cpp @@ -2045,6 +2045,11 @@ static bool isEqual(const Function &Caller, const Function &Callee) { Callee.getFnAttribute(AttrClass::getKind()); } +static bool isEqual(const Function &Caller, const Function &Callee, + const StringRef &AttrName) { + return Caller.getFnAttribute(AttrName) == Callee.getFnAttribute(AttrName); +} + /// Compute the logical AND of the attributes of the caller and the /// callee. /// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td index 36700f73df4b..feabd137c0cf 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td @@ -837,6 +837,7 @@ include "AArch64SchedA64FX.td" include "AArch64SchedThunderX3T110.td" include "AArch64SchedTSV110.td" include "AArch64SchedAmpere1.td" +include "AArch64SchedAmpere1B.td" include "AArch64SchedNeoverseN1.td" include "AArch64SchedNeoverseN2.td" include "AArch64SchedNeoverseV1.td" @@ -1376,6 +1377,24 @@ def TuneAmpere1A : SubtargetFeature<"ampere1a", "ARMProcFamily", "Ampere1A", FeatureLdpAlignedOnly, FeatureStpAlignedOnly]>; +def TuneAmpere1B : SubtargetFeature<"ampere1b", "ARMProcFamily", "Ampere1B", + "Ampere Computing Ampere-1B processors", [ + FeaturePostRAScheduler, + FeatureFuseAES, + FeatureFuseAdrpAdd, + FeatureAddrLSLFast, + FeatureALULSLFast, + FeatureAggressiveFMA, + FeatureArithmeticBccFusion, + FeatureCmpBccFusion, + FeatureFuseAddress, + FeatureFuseLiterals, + FeatureStorePairSuppress, + FeatureEnableSelectOptimize, + FeaturePredictableSelectIsExpensive, + FeatureLdpAlignedOnly, + FeatureStpAlignedOnly]>; + def ProcessorFeatures { list A53 = [HasV8_0aOps, FeatureCRC, FeatureCrypto, FeatureFPARMv8, FeatureNEON, FeaturePerfMon]; @@ -1529,6 +1548,11 @@ def ProcessorFeatures { FeatureMTE, FeatureSSBS, FeatureRandGen, FeatureSB, FeatureSM4, FeatureSHA2, FeatureSHA3, FeatureAES]; + list Ampere1B = [HasV8_7aOps, FeatureNEON, FeaturePerfMon, + FeatureMTE, FeatureSSBS, FeatureRandGen, + FeatureSB, FeatureSM4, FeatureSHA2, + FeatureSHA3, FeatureAES, FeatureCSSC, + FeatureWFxT, FeatureFullFP16]; // ETE and TRBE are future architecture extensions. We temporarily enable them // by default for users targeting generic AArch64. The extensions do not @@ -1696,6 +1720,9 @@ def : ProcessorModel<"ampere1", Ampere1Model, ProcessorFeatures.Ampere1, def : ProcessorModel<"ampere1a", Ampere1Model, ProcessorFeatures.Ampere1A, [TuneAmpere1A]>; +def : ProcessorModel<"ampere1b", Ampere1BModel, ProcessorFeatures.Ampere1B, + [TuneAmpere1B]>; + //===----------------------------------------------------------------------===// // Assembly parser //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td index 3e4168f5f445..c714bad92b7f 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td @@ -29,7 +29,7 @@ def CortexA53Model : SchedMachineModel { list UnsupportedFeatures = !listconcat(SVEUnsupported.F, PAUnsupported.F, SMEUnsupported.F, - [HasMTE]); + [HasMTE, HasCSSC]); } diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td index 277ec772cf0f..ebbc3b72b506 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td @@ -34,7 +34,7 @@ def CortexA57Model : SchedMachineModel { list UnsupportedFeatures = !listconcat(SVEUnsupported.F, PAUnsupported.F, SMEUnsupported.F, - [HasMTE]); + [HasMTE, HasCSSC]); } //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td index 7edce4b61605..d6fe84a2c9c9 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td @@ -22,7 +22,8 @@ def A64FXModel : SchedMachineModel { list UnsupportedFeatures = !listconcat(SMEUnsupported.F, SVEUnsupported.F, [HasMTE, HasMatMulInt8, HasBF16, - HasPAuth, HasPAuthLR, HasCPA]); + HasPAuth, HasPAuthLR, HasCPA, + HasCSSC]); let FullInstRWOverlapCheck = 0; } diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td new file mode 100644 index 000000000000..9c4f000cf351 --- /dev/null +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td @@ -0,0 +1,1149 @@ +//=- AArch64SchedAmpere1B.td - Ampere-1B scheduling def -----*- tablegen -*-=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// +// +// This file defines the machine model for the Ampere Computing Ampere-1B to +// support instruction scheduling and other instruction cost heuristics. +// +//===----------------------------------------------------------------------===// + +// The Ampere-1B core is an out-of-order micro-architecture. The front +// end has branch prediction, with a 10-cycle recovery time from a +// mispredicted branch. Instructions coming out of the front end are +// decoded into internal micro-ops (uops). + +def Ampere1BModel : SchedMachineModel { + let IssueWidth = 12; // Maximum micro-ops dispatch rate. + let MicroOpBufferSize = 192; // micro-op re-order buffer size + let LoadLatency = 3; // Optimistic load latency + let MispredictPenalty = 10; // Branch mispredict penalty + let LoopMicroOpBufferSize = 32; // Instruction queue size + let CompleteModel = 1; + + list UnsupportedFeatures = !listconcat(SVEUnsupported.F, + SMEUnsupported.F, + PAUnsupported.F); +} + +let SchedModel = Ampere1BModel in { + +//===----------------------------------------------------------------------===// +// Define each kind of processor resource and number available on Ampere-1B. + +def Ampere1BUnitA : ProcResource<2>; // integer single-cycle, branch, and flags r/w +def Ampere1BUnitB : ProcResource<2>; // integer single-cycle, and complex shifts +def Ampere1BUnitBS : ProcResource<1>; // integer multi-cycle +def Ampere1BUnitL : ProcResource<2>; // load +def Ampere1BUnitS : ProcResource<2>; // store address calculation +def Ampere1BUnitX : ProcResource<1>; // FP and vector operations, and flag write +def Ampere1BUnitY : ProcResource<1>; // FP and vector operations, and crypto +def Ampere1BUnitZ : ProcResource<1>; // FP store data and FP-to-integer moves + +def Ampere1BUnitAB : ProcResGroup<[Ampere1BUnitA, Ampere1BUnitB]>; +def Ampere1BUnitXY : ProcResGroup<[Ampere1BUnitX, Ampere1BUnitY]>; + +//===----------------------------------------------------------------------===// +// Define customized scheduler read/write types specific to the Ampere-1. + +def Ampere1BWrite_1cyc_1A : SchedWriteRes<[Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_2A : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1B : SchedWriteRes<[Ampere1BUnitB]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1BS_1B : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitB]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1AB : SchedWriteRes<[Ampere1BUnitAB]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1AB_1A : SchedWriteRes<[Ampere1BUnitAB, Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1S : SchedWriteRes<[Ampere1BUnitS]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_2S : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1Y : SchedWriteRes<[Ampere1BUnitY]> { + let Latency = 2; + let NumMicroOps = 1; +} + +def Ampere1BWrite_2cyc_2AB : SchedWriteRes<[Ampere1BUnitAB, Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1AB : SchedWriteRes<[Ampere1BUnitB, Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1S : SchedWriteRes<[Ampere1BUnitB, Ampere1BUnitS]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1S_1AB : SchedWriteRes<[Ampere1BUnitB, + Ampere1BUnitS, + Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 3; +} + +def Ampere1BWrite_2cyc_1S_2Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ, + Ampere1BUnitZ]> { + let Latency = 2; + let NumMicroOps = 3; +} + +def Ampere1BWrite_2cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 2; + let NumMicroOps = 1; +} + +def Ampere1BWrite_2cyc_1S_1Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitZ]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_3cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1Z : SchedWriteRes<[Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1S_1Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 2; +} + +def Ampere1BWrite_3cyc_1S_2Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 3; +} + +def Ampere1BWrite_3cyc_2S_2Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 4; +} + +def Ampere1BWrite_4cyc_1BS_1AB : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitAB]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_2L : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1L_1B : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitB]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_5cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 5; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_1XY_1S_1Z : SchedWriteRes<[Ampere1BUnitXY, + Ampere1BUnitS, + Ampere1BUnitZ]> { + let Latency = 4; + let NumMicroOps = 3; +} + +def Ampere1BWrite_4cyc_3S_3Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 4; + let NumMicroOps = 6; +} + +def Ampere1BWrite_5cyc_4S_4Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 5; + let NumMicroOps = 8; +} + +def Ampere1BWrite_5cyc_1L_1BS : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitBS]> { + let Latency = 5; + let NumMicroOps = 2; +} + +def Ampere1BWrite_5cyc_3L : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL]> { + let Latency = 5; + let NumMicroOps = 3; +} + +def Ampere1BWrite_5cyc_4L : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL]> { + let Latency = 5; + let NumMicroOps = 4; +} + +def Ampere1BWrite_5cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 5; + let NumMicroOps = 1; +} + +def Ampere1BWrite_5cyc_2XY_2S_2Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 5; + let NumMicroOps = 6; +} + +def Ampere1BWrite_6cyc_1BS_1A : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitA]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_1BS_2A : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitA, + Ampere1BUnitA]> { + let Latency = 6; + let NumMicroOps = 3; +} + +def Ampere1BWrite_6cyc_1L_1XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_2L_2XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 4; +} + +def Ampere1BWrite_6cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_3XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 3; +} + +def Ampere1BWrite_6cyc_2XY_2S_2Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 6; + let NumMicroOps = 6; +} + +def Ampere1BWrite_6cyc_3XY_3S_3Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 6; + let NumMicroOps = 9; +} + +def Ampere1BWrite_7cyc_1BS_1XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_1XY_1Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_1X_1Z : SchedWriteRes<[Ampere1BUnitX, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 6; +} + +def Ampere1BWrite_7cyc_4L_4XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 8; +} + +def Ampere1BWrite_7cyc_4XY_4S_4Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 12; +} + +def Ampere1BWrite_8cyc_1BS_1L : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitL]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_1BS_1XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_2L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 5; +} + +def Ampere1BWrite_8cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 6; +} + +def Ampere1BWrite_8cyc_4L_4XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 8; +} + +def Ampere1BWrite_8cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_4XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 4; +} + +def Ampere1BWrite_9cyc_6XY_4S_4Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 9; + let NumMicroOps = 14; +} + +def Ampere1BWrite_9cyc_1A_1BS_1X : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitBS, Ampere1BUnitX]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_9cyc_1A_1BS_1XY : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_9cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 6; +} + +def Ampere1BWrite_9cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 9; + let NumMicroOps = 1; +} + +def Ampere1BWrite_9cyc_3XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_10cyc_4L_8XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 10; + let NumMicroOps = 12; +} + +def Ampere1BWrite_11cyc_1BS_2XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 11; + let NumMicroOps = 3; +} + +def Ampere1BWrite_11cyc_4L_8XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 11; + let NumMicroOps = 12; +} + +def Ampere1BWrite_12cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 12; + let NumMicroOps = 1; +} + +def Ampere1BWrite_13cyc_1BS_1X : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitX]> { + let Latency = 13; + let NumMicroOps = 2; +} + +def Ampere1BWrite_17cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 17; + let NumMicroOps = 1; +} + +def Ampere1BWrite_19cyc_2BS_1X : SchedWriteRes<[Ampere1BUnitBS, + Ampere1BUnitBS, + Ampere1BUnitX]> { + let Latency = 13; + let NumMicroOps = 3; +} + +def Ampere1BWrite_19cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 19; + let NumMicroOps = 1; +} + +def Ampere1BWrite_21cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 21; + let NumMicroOps = 1; +} + +def Ampere1BWrite_33cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 33; + let NumMicroOps = 1; +} + +def Ampere1BWrite_39cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 39; + let NumMicroOps = 1; +} + +def Ampere1BWrite_63cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 63; + let NumMicroOps = 1; +} + +// For basic arithmetic, we have more flexibility for short shifts (LSL shift <= 4), +// which are a single uop, and for extended registers, which have full flexibility +// across Unit A or B for both uops. +def Ampere1BWrite_Arith : SchedWriteVariant<[ + SchedVar, + SchedVar, + SchedVar]>; + +def Ampere1BWrite_ArithFlagsetting : SchedWriteVariant<[ + SchedVar, + SchedVar, + SchedVar]>; + +//===----------------------------------------------------------------------===// +// Map the target-defined scheduler read/write resources and latencies for Ampere-1. +// This provides a coarse model, which is then specialised below. + +def : WriteRes; // MOVN, MOVZ +def : WriteRes; // ALU +def : WriteRes { + let Latency = 2; + let NumMicroOps = 2; +} // ALU of Shifted-Reg +def : WriteRes { *** 1567 LINES SKIPPED *** From nobody Sat Apr 20 10:32:34 2024 X-Original-To: dev-commits-src-branches@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 4VM7BC0rwLz5HVtj; Sat, 20 Apr 2024 10:32:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BB2bNVz4Pl6; Sat, 20 Apr 2024 10:32:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609154; 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=WM57fQ24kKHkrrjvWR98AsG31cTyqzHl9zc+Dj3UIFg=; b=yDlIlqBFlobSUTMEz5BV6f9ryoUp6Ic6FY1qnwug8Fj5J23HXSV9L0+uSP/dyD4sYykp6o 8ArbS79ZHRGQzYkXccNZDiGgXkkLrfe5UJwTYnlvMm5OJqgtqDz2zTdlQOGWNWoTDwk775 6fAk8tfiBuIjsoN5zXQJPxeT5vxiVboS8HJh13LO66z4ZcbRXCUNUZAWUCBjIxDQNyXF2/ GfqTLKsTzGcLbGj6Gj4g+uOHG+4YMwKnhh/mVQgVcXtZBkdLAFHhwE8ziT+EmSD9qTACfm fBNA54mDIVLIZ4iaCwlerxHKhw43znGxsUQfJiV4hzFQqLgED+Jw4MJYAcLBVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609154; a=rsa-sha256; cv=none; b=MSWSug14fzEi+rTWAVszkbaFCBqErRIz76k6Oo/4Z52yuYdkLXrTWt48Z8Me2RDQvlmlNz 0cfUHkVFjWUehjlseQQD/mSvvBwZRoFv300F8RglvPQEkvWcPJy7bGrnfhu32dQPrQSZxj Hc5rEZDZJNa4OuZtkAY449hYvUBStgAgq4xVsdS66RdG4fZeXnbpdgJVpvz5I6kKOV/LG7 14hafnjRRMlQ2MAWbgw0psKDvN4TOCr+NiG0EQPByhcCUu/bfUl9fI18eq72nFbUVTSCA7 OsVdFfrpPa4qhEn+vP2M9v125b3mlf3BWO/LlOBDOFJnChjpknXRoKJGjUHeGw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609154; 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=WM57fQ24kKHkrrjvWR98AsG31cTyqzHl9zc+Dj3UIFg=; b=CavdfWFWZwDpf2IM5nXW5dfW9eondtmT7XnSGjyWyaglYJdvP1Lsi4qP/rhBCey1P5vAlh hvx0GyP9hdHCI68pkQL/bLc4zhKxjOBMHVVr2g2JQWewsLfF9VHMUZj1GRKYYSX5O/svBl 1Gv7OFZAzfG8zNfrdKKdvQA3mlhywqaIlAZImQqvO5hSKeA6M2qSnk1QxcR/kNVzLO5gKh WZINwMntDFV339LyBr9WELZJEILYSfQwfi/W29dxZhNvQeFd8Q90SWdgKhG1XvsfE6vazy D+3LtbDw+ccBPMguyy7+lDdrSp4cefHSpwduym8XkxyjzgjGbFwEjrTxGflUNA== 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 4VM7BB1wvCzZ2p; Sat, 20 Apr 2024 10:32:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWYmm011330; Sat, 20 Apr 2024 10:32:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWYqN011327; Sat, 20 Apr 2024 10:32:34 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:34 GMT Message-Id: <202404201032.43KAWYqN011327@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: 8e3e0a4774e1 - stable/14 - Merge llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 8e3e0a4774e1407ee08eb12b2690fc9b3977a32e Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=8e3e0a4774e1407ee08eb12b2690fc9b3977a32e commit 8e3e0a4774e1407ee08eb12b2690fc9b3977a32e Author: Dimitry Andric AuthorDate: 2024-02-21 10:24:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:16 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463. PR: 276104 MFC after: 1 month (cherry picked from commit 56727255ad47072ec2cc81b4ae728a099697b0e4) --- .../clang/lib/Serialization/ASTReaderDecl.cpp | 10 +- .../clang/lib/Serialization/ASTWriter.cpp | 6 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 15 +- .../compiler-rt/lib/profile/InstrProfilingFile.c | 3 + .../llvm/include/llvm/Analysis/ScalarEvolution.h | 7 + .../llvm/lib/Analysis/ScalarEvolution.cpp | 62 ++++ .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 37 +- .../InstCombine/InstructionCombining.cpp | 6 +- .../Transforms/Utils/ScalarEvolutionExpander.cpp | 57 +-- .../llvm/lib/Transforms/Utils/SimplifyIndVar.cpp | 18 +- .../llvm/tools/llvm-objcopy/ObjcopyOptions.cpp | 2 + .../llvm/tools/llvm-objdump/ELFDump.cpp | 3 + .../llvm/tools/llvm-readobj/ELFDumper.cpp | 1 + .../llvm-project/openmp/runtime/src/z_AIX_asm.S | 410 +++++++++++++++++++++ lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 17 files changed, 558 insertions(+), 89 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp index 1fadd8039462..321c11e55c14 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp @@ -800,11 +800,12 @@ void ASTDeclReader::VisitEnumDecl(EnumDecl *ED) { BitsUnpacker EnumDeclBits(Record.readInt()); ED->setNumPositiveBits(EnumDeclBits.getNextBits(/*Width=*/8)); ED->setNumNegativeBits(EnumDeclBits.getNextBits(/*Width=*/8)); + bool ShouldSkipCheckingODR = EnumDeclBits.getNextBit(); ED->setScoped(EnumDeclBits.getNextBit()); ED->setScopedUsingClassTag(EnumDeclBits.getNextBit()); ED->setFixed(EnumDeclBits.getNextBit()); - if (!shouldSkipCheckingODR(ED)) { + if (!ShouldSkipCheckingODR) { ED->setHasODRHash(true); ED->ODRHash = Record.readInt(); } @@ -1073,6 +1074,7 @@ void ASTDeclReader::VisitFunctionDecl(FunctionDecl *FD) { FD->setCachedLinkage((Linkage)FunctionDeclBits.getNextBits(/*Width=*/3)); FD->setStorageClass((StorageClass)FunctionDeclBits.getNextBits(/*Width=*/3)); + bool ShouldSkipCheckingODR = FunctionDeclBits.getNextBit(); FD->setInlineSpecified(FunctionDeclBits.getNextBit()); FD->setImplicitlyInline(FunctionDeclBits.getNextBit()); FD->setHasSkippedBody(FunctionDeclBits.getNextBit()); @@ -1102,7 +1104,7 @@ void ASTDeclReader::VisitFunctionDecl(FunctionDecl *FD) { if (FD->isExplicitlyDefaulted()) FD->setDefaultLoc(readSourceLocation()); - if (!shouldSkipCheckingODR(FD)) { + if (!ShouldSkipCheckingODR) { FD->ODRHash = Record.readInt(); FD->setHasODRHash(true); } @@ -1973,6 +1975,8 @@ void ASTDeclReader::ReadCXXDefinitionData( BitsUnpacker CXXRecordDeclBits = Record.readInt(); + bool ShouldSkipCheckingODR = CXXRecordDeclBits.getNextBit(); + #define FIELD(Name, Width, Merge) \ if (!CXXRecordDeclBits.canGetNextNBits(Width)) \ CXXRecordDeclBits.updateValue(Record.readInt()); \ @@ -1982,7 +1986,7 @@ void ASTDeclReader::ReadCXXDefinitionData( #undef FIELD // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) { + if (!ShouldSkipCheckingODR) { // Note: the caller has deserialized the IsLambda bit already. Data.ODRHash = Record.readInt(); Data.HasODRHash = true; diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp index 3b79a9238d1a..73018c1170d8 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp @@ -6010,6 +6010,9 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { BitsPacker DefinitionBits; + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + DefinitionBits.addBit(ShouldSkipCheckingODR); + #define FIELD(Name, Width, Merge) \ if (!DefinitionBits.canWriteNextNBits(Width)) { \ Record->push_back(DefinitionBits); \ @@ -6023,11 +6026,10 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { Record->push_back(DefinitionBits); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) { + if (!ShouldSkipCheckingODR) // getODRHash will compute the ODRHash if it has not been previously // computed. Record->push_back(D->getODRHash()); - } bool ModulesDebugInfo = Writer->Context->getLangOpts().ModulesDebugInfo && !D->isDependentType(); diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp index f224075643e9..e73800100e3c 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp @@ -488,13 +488,15 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { BitsPacker EnumDeclBits; EnumDeclBits.addBits(D->getNumPositiveBits(), /*BitWidth=*/8); EnumDeclBits.addBits(D->getNumNegativeBits(), /*BitWidth=*/8); + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + EnumDeclBits.addBit(ShouldSkipCheckingODR); EnumDeclBits.addBit(D->isScoped()); EnumDeclBits.addBit(D->isScopedUsingClassTag()); EnumDeclBits.addBit(D->isFixed()); Record.push_back(EnumDeclBits); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) + if (!ShouldSkipCheckingODR) Record.push_back(D->getODRHash()); if (MemberSpecializationInfo *MemberInfo = D->getMemberSpecializationInfo()) { @@ -678,6 +680,8 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { // FIXME: stable encoding FunctionDeclBits.addBits(llvm::to_underlying(D->getLinkageInternal()), 3); FunctionDeclBits.addBits((uint32_t)D->getStorageClass(), /*BitWidth=*/3); + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + FunctionDeclBits.addBit(ShouldSkipCheckingODR); FunctionDeclBits.addBit(D->isInlineSpecified()); FunctionDeclBits.addBit(D->isInlined()); FunctionDeclBits.addBit(D->hasSkippedBody()); @@ -704,7 +708,7 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { Record.AddSourceLocation(D->getDefaultLoc()); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) + if (!ShouldSkipCheckingODR) Record.push_back(D->getODRHash()); if (D->isDefaulted()) { @@ -2137,12 +2141,13 @@ getFunctionDeclAbbrev(serialization::DeclCode Code) { Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 11)); // IDNS Abv->Add(BitCodeAbbrevOp( BitCodeAbbrevOp::Fixed, - 27)); // Packed Function Bits: StorageClass, Inline, InlineSpecified, + 28)); // Packed Function Bits: StorageClass, Inline, InlineSpecified, // VirtualAsWritten, Pure, HasInheritedProto, HasWrittenProto, // Deleted, Trivial, TrivialForCall, Defaulted, ExplicitlyDefaulted, // IsIneligibleOrNotSelected, ImplicitReturnZero, Constexpr, // UsesSEHTry, SkippedBody, MultiVersion, LateParsed, - // FriendConstraintRefersToEnclosingTemplate, Linkage + // FriendConstraintRefersToEnclosingTemplate, Linkage, + // ShouldSkipCheckingODR Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // LocEnd Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 32)); // ODRHash // This Array slurps the rest of the record. Fortunately we want to encode @@ -2269,7 +2274,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // AddTypeRef Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // IntegerType Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // getPromotionType - Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 19)); // Enum Decl Bits + Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 20)); // Enum Decl Bits Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 32));// ODRHash Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // InstantiatedMembEnum // DC diff --git a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c index 867ae73f0d3b..f3b457d786e6 100644 --- a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c +++ b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c @@ -677,6 +677,7 @@ static void initializeProfileForContinuousMode(void) { PROF_ERR("Continuous counter sync mode is enabled, but raw profile is not" "page-aligned. CurrentFileOffset = %" PRIu64 ", pagesz = %u.\n", (uint64_t)CurrentFileOffset, PageSize); + fclose(File); return; } if (writeProfileWithFileObject(Filename, File) != 0) { @@ -692,6 +693,8 @@ static void initializeProfileForContinuousMode(void) { if (doMerging()) { lprofUnlockFileHandle(File); + } + if (File != NULL) { fclose(File); } } diff --git a/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h b/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h index af3ad822e0b0..0880f9c65aa4 100644 --- a/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h +++ b/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h @@ -1314,6 +1314,13 @@ public: void getPoisonGeneratingValues(SmallPtrSetImpl &Result, const SCEV *S); + /// Check whether it is poison-safe to represent the expression S using the + /// instruction I. If such a replacement is performed, the poison flags of + /// instructions in DropPoisonGeneratingInsts must be dropped. + bool canReuseInstruction( + const SCEV *S, Instruction *I, + SmallVectorImpl &DropPoisonGeneratingInsts); + class FoldID { const SCEV *Op = nullptr; const Type *Ty = nullptr; diff --git a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp index 2acb45837c48..4b2db80bc1ec 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp @@ -4184,6 +4184,68 @@ void ScalarEvolution::getPoisonGeneratingValues( Result.insert(SU->getValue()); } +bool ScalarEvolution::canReuseInstruction( + const SCEV *S, Instruction *I, + SmallVectorImpl &DropPoisonGeneratingInsts) { + // If the instruction cannot be poison, it's always safe to reuse. + if (programUndefinedIfPoison(I)) + return true; + + // Otherwise, it is possible that I is more poisonous that S. Collect the + // poison-contributors of S, and then check whether I has any additional + // poison-contributors. Poison that is contributed through poison-generating + // flags is handled by dropping those flags instead. + SmallPtrSet PoisonVals; + getPoisonGeneratingValues(PoisonVals, S); + + SmallVector Worklist; + SmallPtrSet Visited; + Worklist.push_back(I); + while (!Worklist.empty()) { + Value *V = Worklist.pop_back_val(); + if (!Visited.insert(V).second) + continue; + + // Avoid walking large instruction graphs. + if (Visited.size() > 16) + return false; + + // Either the value can't be poison, or the S would also be poison if it + // is. + if (PoisonVals.contains(V) || isGuaranteedNotToBePoison(V)) + continue; + + auto *I = dyn_cast(V); + if (!I) + return false; + + // Disjoint or instructions are interpreted as adds by SCEV. However, we + // can't replace an arbitrary add with disjoint or, even if we drop the + // flag. We would need to convert the or into an add. + if (auto *PDI = dyn_cast(I)) + if (PDI->isDisjoint()) + return false; + + // FIXME: Ignore vscale, even though it technically could be poison. Do this + // because SCEV currently assumes it can't be poison. Remove this special + // case once we proper model when vscale can be poison. + if (auto *II = dyn_cast(I); + II && II->getIntrinsicID() == Intrinsic::vscale) + continue; + + if (canCreatePoison(cast(I), /*ConsiderFlagsAndMetadata*/ false)) + return false; + + // If the instruction can't create poison, we can recurse to its operands. + if (I->hasPoisonGeneratingFlagsOrMetadata()) + DropPoisonGeneratingInsts.push_back(I); + + for (Value *Op : I->operands()) + Worklist.push_back(Op); + } + return true; +} + const SCEV * ScalarEvolution::getSequentialMinMaxExpr(SCEVTypes Kind, SmallVectorImpl &Ops) { diff --git a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp index 26ed74108ec3..18a4223d481e 100644 --- a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp @@ -1635,7 +1635,8 @@ class BitPermutationSelector { default: break; case ISD::ROTL: if (isa(V.getOperand(1))) { - unsigned RotAmt = V.getConstantOperandVal(1); + assert(isPowerOf2_32(NumBits) && "rotl bits should be power of 2!"); + unsigned RotAmt = V.getConstantOperandVal(1) & (NumBits - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; @@ -1648,15 +1649,20 @@ class BitPermutationSelector { case ISD::SHL: case PPCISD::SHL: if (isa(V.getOperand(1))) { - unsigned ShiftAmt = V.getConstantOperandVal(1); + // sld takes 7 bits, slw takes 6. + unsigned ShiftAmt = V.getConstantOperandVal(1) & ((NumBits << 1) - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; - for (unsigned i = ShiftAmt; i < NumBits; ++i) - Bits[i] = LHSBits[i - ShiftAmt]; - - for (unsigned i = 0; i < ShiftAmt; ++i) - Bits[i] = ValueBit(ValueBit::ConstZero); + if (ShiftAmt >= NumBits) { + for (unsigned i = 0; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } else { + for (unsigned i = ShiftAmt; i < NumBits; ++i) + Bits[i] = LHSBits[i - ShiftAmt]; + for (unsigned i = 0; i < ShiftAmt; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } return std::make_pair(Interesting = true, &Bits); } @@ -1664,15 +1670,20 @@ class BitPermutationSelector { case ISD::SRL: case PPCISD::SRL: if (isa(V.getOperand(1))) { - unsigned ShiftAmt = V.getConstantOperandVal(1); + // srd takes lowest 7 bits, srw takes 6. + unsigned ShiftAmt = V.getConstantOperandVal(1) & ((NumBits << 1) - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; - for (unsigned i = 0; i < NumBits - ShiftAmt; ++i) - Bits[i] = LHSBits[i + ShiftAmt]; - - for (unsigned i = NumBits - ShiftAmt; i < NumBits; ++i) - Bits[i] = ValueBit(ValueBit::ConstZero); + if (ShiftAmt >= NumBits) { + for (unsigned i = 0; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } else { + for (unsigned i = 0; i < NumBits - ShiftAmt; ++i) + Bits[i] = LHSBits[i + ShiftAmt]; + for (unsigned i = NumBits - ShiftAmt; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } return std::make_pair(Interesting = true, &Bits); } diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp index 249f4a7710e0..5d207dcfd18d 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -2594,10 +2594,10 @@ Instruction *InstCombinerImpl::visitGetElementPtrInst(GetElementPtrInst &GEP) { Value *V; if ((has_single_bit(TyAllocSize) && match(GEP.getOperand(1), - m_Exact(m_AShr(m_Value(V), - m_SpecificInt(countr_zero(TyAllocSize)))))) || + m_Exact(m_Shr(m_Value(V), + m_SpecificInt(countr_zero(TyAllocSize)))))) || match(GEP.getOperand(1), - m_Exact(m_SDiv(m_Value(V), m_SpecificInt(TyAllocSize))))) { + m_Exact(m_IDiv(m_Value(V), m_SpecificInt(TyAllocSize))))) { GetElementPtrInst *NewGEP = GetElementPtrInst::Create( Builder.getInt8Ty(), GEP.getPointerOperand(), V); NewGEP->setIsInBounds(GEP.isInBounds()); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp index a1d7f0f9ba0f..a3951fdf8a15 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp @@ -1366,61 +1366,6 @@ Value *SCEVExpander::expandCodeFor(const SCEV *SH, Type *Ty) { return V; } -static bool -canReuseInstruction(ScalarEvolution &SE, const SCEV *S, Instruction *I, - SmallVectorImpl &DropPoisonGeneratingInsts) { - // If the instruction cannot be poison, it's always safe to reuse. - if (programUndefinedIfPoison(I)) - return true; - - // Otherwise, it is possible that I is more poisonous that S. Collect the - // poison-contributors of S, and then check whether I has any additional - // poison-contributors. Poison that is contributed through poison-generating - // flags is handled by dropping those flags instead. - SmallPtrSet PoisonVals; - SE.getPoisonGeneratingValues(PoisonVals, S); - - SmallVector Worklist; - SmallPtrSet Visited; - Worklist.push_back(I); - while (!Worklist.empty()) { - Value *V = Worklist.pop_back_val(); - if (!Visited.insert(V).second) - continue; - - // Avoid walking large instruction graphs. - if (Visited.size() > 16) - return false; - - // Either the value can't be poison, or the S would also be poison if it - // is. - if (PoisonVals.contains(V) || isGuaranteedNotToBePoison(V)) - continue; - - auto *I = dyn_cast(V); - if (!I) - return false; - - // FIXME: Ignore vscale, even though it technically could be poison. Do this - // because SCEV currently assumes it can't be poison. Remove this special - // case once we proper model when vscale can be poison. - if (auto *II = dyn_cast(I); - II && II->getIntrinsicID() == Intrinsic::vscale) - continue; - - if (canCreatePoison(cast(I), /*ConsiderFlagsAndMetadata*/ false)) - return false; - - // If the instruction can't create poison, we can recurse to its operands. - if (I->hasPoisonGeneratingFlagsOrMetadata()) - DropPoisonGeneratingInsts.push_back(I); - - for (Value *Op : I->operands()) - Worklist.push_back(Op); - } - return true; -} - Value *SCEVExpander::FindValueInExprValueMap( const SCEV *S, const Instruction *InsertPt, SmallVectorImpl &DropPoisonGeneratingInsts) { @@ -1448,7 +1393,7 @@ Value *SCEVExpander::FindValueInExprValueMap( continue; // Make sure reusing the instruction is poison-safe. - if (canReuseInstruction(SE, S, EntInst, DropPoisonGeneratingInsts)) + if (SE.canReuseInstruction(S, EntInst, DropPoisonGeneratingInsts)) return V; DropPoisonGeneratingInsts.clear(); } diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp index 0ed3324a27b6..1b142f14d811 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp @@ -16,6 +16,7 @@ #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/Statistic.h" #include "llvm/Analysis/LoopInfo.h" +#include "llvm/Analysis/ValueTracking.h" #include "llvm/IR/Dominators.h" #include "llvm/IR/IRBuilder.h" #include "llvm/IR/Instructions.h" @@ -713,8 +714,11 @@ bool SimplifyIndvar::replaceFloatIVWithIntegerIV(Instruction *UseInst) { bool SimplifyIndvar::eliminateIdentitySCEV(Instruction *UseInst, Instruction *IVOperand) { if (!SE->isSCEVable(UseInst->getType()) || - (UseInst->getType() != IVOperand->getType()) || - (SE->getSCEV(UseInst) != SE->getSCEV(IVOperand))) + UseInst->getType() != IVOperand->getType()) + return false; + + const SCEV *UseSCEV = SE->getSCEV(UseInst); + if (UseSCEV != SE->getSCEV(IVOperand)) return false; // getSCEV(X) == getSCEV(Y) does not guarantee that X and Y are related in the @@ -742,6 +746,16 @@ bool SimplifyIndvar::eliminateIdentitySCEV(Instruction *UseInst, if (!LI->replacementPreservesLCSSAForm(UseInst, IVOperand)) return false; + // Make sure the operand is not more poisonous than the instruction. + if (!impliesPoison(IVOperand, UseInst)) { + SmallVector DropPoisonGeneratingInsts; + if (!SE->canReuseInstruction(UseSCEV, IVOperand, DropPoisonGeneratingInsts)) + return false; + + for (Instruction *I : DropPoisonGeneratingInsts) + I->dropPoisonGeneratingFlagsAndMetadata(); + } + LLVM_DEBUG(dbgs() << "INDVARS: Eliminated identity: " << *UseInst << '\n'); SE->forgetValue(UseInst); diff --git a/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp b/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp index f15307181fad..f63e5c61e802 100644 --- a/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp @@ -299,6 +299,8 @@ static const StringMap TargetMap{ // LoongArch {"elf32-loongarch", {ELF::EM_LOONGARCH, false, true}}, {"elf64-loongarch", {ELF::EM_LOONGARCH, true, true}}, + // SystemZ + {"elf64-s390", {ELF::EM_S390, true, false}}, }; static Expected diff --git a/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp b/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp index 34861ee92128..fda99bd6d33e 100644 --- a/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp @@ -291,6 +291,9 @@ template void ELFDumper::printProgramHeaders() { case ELF::PT_OPENBSD_RANDOMIZE: outs() << "OPENBSD_RANDOMIZE "; break; + case ELF::PT_OPENBSD_SYSCALLS: + outs() << "OPENBSD_SYSCALLS "; + break; case ELF::PT_OPENBSD_WXNEEDED: outs() << "OPENBSD_WXNEEDED "; break; diff --git a/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp b/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp index f369a63add11..387124ad53e4 100644 --- a/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp @@ -1478,6 +1478,7 @@ static StringRef segmentTypeToString(unsigned Arch, unsigned Type) { LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_RANDOMIZE); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_WXNEEDED); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_NOBTCFI); + LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_SYSCALLS); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_BOOTDATA); default: return ""; diff --git a/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S b/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S new file mode 100644 index 000000000000..d711fcb7a785 --- /dev/null +++ b/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S @@ -0,0 +1,410 @@ +// z_AIX_asm.S: - microtasking routines specifically +// written for Power platforms running AIX OS + +// +////===----------------------------------------------------------------------===// +//// +//// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +//// See https://llvm.org/LICENSE.txt for license information. +//// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +//// +////===----------------------------------------------------------------------===// +// + +// ----------------------------------------------------------------------- +// macros +// ----------------------------------------------------------------------- + +#include "kmp_config.h" + +#if KMP_OS_AIX +//------------------------------------------------------------------------ +// int +// __kmp_invoke_microtask( void (*pkfn) (int *gtid, int *tid, ...), +// int gtid, int tid, +// int argc, void *p_argv[] +// #if OMPT_SUPPORT +// , +// void **exit_frame_ptr +// #endif +// ) { +// #if OMPT_SUPPORT +// *exit_frame_ptr = OMPT_GET_FRAME_ADDRESS(0); +// #endif +// +// (*pkfn)( & gtid, & tid, p_argv[0], ... ); +// +// // FIXME: This is done at call-site and can be removed here. +// #if OMPT_SUPPORT +// *exit_frame_ptr = 0; +// #endif +// +// return 1; +// } +// +// parameters: +// r3: pkfn +// r4: gtid +// r5: tid +// r6: argc +// r7: p_argv +// r8: &exit_frame +// +// return: r3 (always 1/TRUE) +// + +#if KMP_ARCH_PPC64_XCOFF + + .globl __kmp_invoke_microtask[DS] + .globl .__kmp_invoke_microtask + .align 4 + .csect __kmp_invoke_microtask[DS],3 + .vbyte 8, .__kmp_invoke_microtask + .vbyte 8, TOC[TC0] + .vbyte 8, 0 + .csect .text[PR],2 + .machine "pwr7" +.__kmp_invoke_microtask: + + +// -- Begin __kmp_invoke_microtask +// mark_begin; + +// We need to allocate a stack frame large enough to hold all of the parameters +// on the stack for the microtask plus what this function needs. That's 48 +// bytes under the XCOFF64 ABI, plus max(64, 8*(2 + argc)) for +// the parameters to the microtask (gtid, tid, argc elements of p_argv), +// plus 8 bytes to store the values of r4 and r5, and 8 bytes to store r31. +// With OMP-T support, we need an additional 8 bytes to save r30 to hold +// a copy of r8. +// Stack offsets relative to stack pointer: +// r31: -8, r30: -16, gtid: -20, tid: -24 + + mflr 0 + std 31, -8(1) # Save r31 to the stack + std 0, 16(1) # Save LR to the linkage area + +// This is unusual because normally we'd set r31 equal to r1 after the stack +// frame is established. In this case, however, we need to dynamically compute +// the stack frame size, and so we keep a direct copy of r1 to access our +// register save areas and restore the r1 value before returning. + mr 31, 1 + +// Compute the size of the "argc" portion of the parameter save area. +// The parameter save area is always at least 64 bytes long (i.e. 8 regs) +// The microtask has (2 + argc) parameters, so if argc <= 6, we need to +// to allocate 8*6 bytes, not 8*argc. + li 0, 6 + cmpwi 0, 6, 6 + iselgt 0, 6, 0 # r0 = (argc > 6)? argc : 6 + sldi 0, 0, 3 # r0 = 8 * max(argc, 6) + +// Compute the size necessary for the local stack frame. +// 88 = 48 + 4 (for r4) + 4 (for r5) + 8 (for r31) + 8 (for OMP-T r30) + +// 8 (parameter gtid) + 8 (parameter tid) + li 12, 88 + add 12, 0, 12 + neg 12, 12 + +// We need to make sure that the stack frame stays aligned (to 16 bytes). + li 0, -16 + and 12, 0, 12 + +// Establish the local stack frame. + stdux 1, 1, 12 + +#if OMPT_SUPPORT + std 30, -16(31) # Save r30 to the stack + std 1, 0(8) + mr 30, 8 +#endif + +// Store gtid and tid to the stack because they're passed by reference to the microtask. + stw 4, -20(31) # Save gtid to the stack + stw 5, -24(31) # Save tid to the stack + + mr 12, 6 # r12 = argc + mr 4, 7 # r4 = p_argv + + cmpwi 0, 12, 1 + blt 0, .Lcall # if (argc < 1) goto .Lcall + + ld 5, 0(4) # r5 = p_argv[0] + + cmpwi 0, 12, 2 + blt 0, .Lcall # if (argc < 2) goto .Lcall + + ld 6, 8(4) # r6 = p_argv[1] + + cmpwi 0, 12, 3 + blt 0, .Lcall # if (argc < 3) goto .Lcall + + ld 7, 16(4) # r7 = p_argv[2] + + cmpwi 0, 12, 4 + blt 0, .Lcall # if (argc < 4) goto .Lcall + + ld 8, 24(4) # r8 = p_argv[3] + + cmpwi 0, 12, 5 + blt 0, .Lcall # if (argc < 5) goto .Lcall + + ld 9, 32(4) # r9 = p_argv[4] + + cmpwi 0, 12, 6 + blt 0, .Lcall # if (argc < 6) goto .Lcall + + ld 10, 40(4) # r10 = p_argv[5] + + cmpwi 0, 12, 7 + blt 0, .Lcall # if (argc < 7) goto .Lcall + +// There are more than 6 microtask parameters, so we need to store the +// remainder to the stack. + addi 12, 12, -6 # argc -= 6 + mtctr 12 + +// These are set to 8 bytes before the first desired store address (we're using +// pre-increment loads and stores in the loop below). The parameter save area +// for the microtask begins 48 + 8*8 == 112 bytes above r1 for XCOFF64. + addi 4, 4, 40 # p_argv = p_argv + 5 + # (i.e. skip the 5 elements we already processed) + addi 12, 1, 104 # r12 = stack offset (112 - 8) + +.Lnext: + ldu 0, 8(4) + stdu 0, 8(12) + bdnz .Lnext + +.Lcall: + std 2, 40(1) # Save the TOC pointer to the linkage area +// Load the actual function address from the function descriptor. + ld 12, 0(3) # Function address + ld 2, 8(3) # TOC pointer + ld 11, 16(3) # Environment pointer + + addi 3, 31, -20 # r3 = >id + addi 4, 31, -24 # r4 = &tid + + mtctr 12 # CTR = function address + bctrl # Branch to CTR + ld 2, 40(1) # Restore TOC pointer from linkage area + +#if OMPT_SUPPORT + li 3, 0 + std 3, 0(30) +#endif + + li 3, 1 + +#if OMPT_SUPPORT + ld 30, -16(31) # Restore r30 from the saved value on the stack +#endif + + mr 1, 31 + ld 31, -8(1) # Restore r31 from the saved value on the stack + ld 0, 16(1) + mtlr 0 # Restore LR from the linkage area + blr # Branch to LR + +#else // KMP_ARCH_PPC_XCOFF + + .globl __kmp_invoke_microtask[DS] + .globl .__kmp_invoke_microtask + .align 4 + .csect __kmp_invoke_microtask[DS],2 + .vbyte 4, .__kmp_invoke_microtask + .vbyte 4, TOC[TC0] + .vbyte 4, 0 + .csect .text[PR],2 + .machine "pwr7" +.__kmp_invoke_microtask: + + +// -- Begin __kmp_invoke_microtask +// mark_begin; + +// We need to allocate a stack frame large enough to hold all of the parameters +// on the stack for the microtask plus what this function needs. That's 24 +// bytes under the XCOFF ABI, plus max(32, 8*(2 + argc)) for +// the parameters to the microtask (gtid, tid, argc elements of p_argv), +// plus 8 bytes to store the values of r4 and r5, and 4 bytes to store r31. +// With OMP-T support, we need an additional 4 bytes to save r30 to hold +// a copy of r8. +// Stack offsets relative to stack pointer: +// r31: -4, r30: -8, gtid: -12, tid: -16 + + mflr 0 + stw 31, -4(1) # Save r31 to the stack + stw 0, 8(1) # Save LR to the linkage area + +// This is unusual because normally we'd set r31 equal to r1 after the stack +// frame is established. In this case, however, we need to dynamically compute +// the stack frame size, and so we keep a direct copy of r1 to access our +// register save areas and restore the r1 value before returning. + mr 31, 1 + +// Compute the size of the "argc" portion of the parameter save area. +// The parameter save area is always at least 32 bytes long (i.e. 8 regs) +// The microtask has (2 + argc) parameters, so if argc <= 6, we need to +// to allocate 4*6 bytes, not 4*argc. + li 0, 6 + cmpwi 0, 6, 6 + iselgt 0, 6, 0 # r0 = (argc > 6)? argc : 6 + slwi 0, 0, 2 # r0 = 4 * max(argc, 6) + +// Compute the size necessary for the local stack frame. +// 56 = 32 + 4 (for r4) + 4 (for r5) + 4 (for r31) + 4 (for OMP-T r30) + +// 4 (parameter gtid) + 4 (parameter tid) + li 12, 56 + add 12, 0, 12 + neg 12, 12 + +// We need to make sure that the stack frame stays aligned (to 16 bytes). + li 0, -16 + and 12, 0, 12 + +// Establish the local stack frame. + stwux 1, 1, 12 + +#if OMPT_SUPPORT + stw 30, -8(31) # Save r30 to the stack + stw 1, 0(8) + mr 30, 8 +#endif + +// Store gtid and tid to the stack because they're passed by reference to the microtask. + stw 4, -12(31) # Save gtid to the stack + stw 5, -16(31) # Save tid to the stack + + mr 12, 6 # r12 = argc + mr 4, 7 # r4 = p_argv + + cmpwi 0, 12, 1 + blt 0, .Lcall # if (argc < 1) goto .Lcall + + lwz 5, 0(4) # r5 = p_argv[0] + + cmpwi 0, 12, 2 + blt 0, .Lcall # if (argc < 2) goto .Lcall + + lwz 6, 4(4) # r6 = p_argv[1] + + cmpwi 0, 12, 3 + blt 0, .Lcall # if (argc < 3) goto .Lcall + + lwz 7, 8(4) # r7 = p_argv[2] + + cmpwi 0, 12, 4 + blt 0, .Lcall # if (argc < 4) goto .Lcall + + lwz 8, 12(4) # r8 = p_argv[3] + + cmpwi 0, 12, 5 + blt 0, .Lcall # if (argc < 5) goto .Lcall + + lwz 9, 16(4) # r9 = p_argv[4] + + cmpwi 0, 12, 6 + blt 0, .Lcall # if (argc < 6) goto .Lcall + + lwz 10, 20(4) # r10 = p_argv[5] + + cmpwi 0, 12, 7 + blt 0, .Lcall # if (argc < 7) goto .Lcall + +// There are more than 6 microtask parameters, so we need to store the +// remainder to the stack. + addi 12, 12, -6 # argc -= 6 + mtctr 12 + +// These are set to 4 bytes before the first desired store address (we're using +// pre-increment loads and stores in the loop below). The parameter save area +// for the microtask begins 24 + 4*8 == 56 bytes above r1 for XCOFF. + addi 4, 4, 20 # p_argv = p_argv + 5 + # (i.e. skip the 5 elements we already processed) + addi 12, 1, 52 # r12 = stack offset (56 - 4) + +.Lnext: + lwzu 0, 4(4) + stwu 0, 4(12) + bdnz .Lnext + +.Lcall: + stw 2, 20(1) # Save the TOC pointer to the linkage area +// Load the actual function address from the function descriptor. + lwz 12, 0(3) # Function address + lwz 2, 4(3) # TOC pointer + lwz 11, 8(3) # Environment pointer + + addi 3, 31, -12 # r3 = >id + addi 4, 31, -16 # r4 = &tid + + mtctr 12 # CTR = function address + bctrl # Branch to CTR + lwz 2, 20(1) # Restore TOC pointer from linkage area + +#if OMPT_SUPPORT + li 3, 0 + stw 3, 0(30) +#endif + + li 3, 1 + +#if OMPT_SUPPORT + lwz 30, -8(31) # Restore r30 from the saved value on the stack +#endif + + mr 1, 31 + lwz 31, -4(1) # Restore r31 from the saved value on the stack + lwz 0, 8(1) + mtlr 0 # Restore LR from the linkage area + blr # Branch to LR + +#endif // KMP_ARCH_PPC64_XCOFF + +.Lfunc_end0: + .vbyte 4, 0x00000000 # Traceback table begin + .byte 0x00 # Version = 0 + .byte 0x09 # Language = CPlusPlus + .byte 0x20 # -IsGlobaLinkage, -IsOutOfLineEpilogOrPrologue + # +HasTraceBackTableOffset, -IsInternalProcedure + # -HasControlledStorage, -IsTOCless + # -IsFloatingPointPresent + # -IsFloatingPointOperationLogOrAbortEnabled + .byte 0x61 # -IsInterruptHandler, +IsFunctionNamePresent, +IsAllocaUsed + # OnConditionDirective = 0, -IsCRSaved, +IsLRSaved + .byte 0x80 # +IsBackChainStored, -IsFixup, NumOfFPRsSaved = 0 +#if OMPT_SUPPORT + .byte 0x02 # -HasExtensionTable, -HasVectorInfo, NumOfGPRsSaved = 2 + .byte 0x06 # NumberOfFixedParms = 6 +#else + .byte 0x01 # -HasExtensionTable, -HasVectorInfo, NumOfGPRsSaved = 1 + .byte 0x05 # NumberOfFixedParms = 5 +#endif + .byte 0x01 # NumberOfFPParms = 0, +HasParmsOnStack + .vbyte 4, 0x00000000 # Parameter type = i, i, i, i, i + .vbyte 4, .Lfunc_end0-.__kmp_invoke_microtask # Function size + .vbyte 2, 0x0016 # Function name len = 22 + .byte "__kmp_invoke_microtask" # Function Name + .byte 0x1f # AllocaRegister = 31 + # -- End function + +// -- End __kmp_invoke_microtask + +// Support for unnamed common blocks. + + .comm .gomp_critical_user_, 32, 3 +#if KMP_ARCH_PPC64_XCOFF + .csect __kmp_unnamed_critical_addr[RW],3 +#else + .csect __kmp_unnamed_critical_addr[RW],2 +#endif + .globl __kmp_unnamed_critical_addr[RW] + .ptr .gomp_critical_user_ + +// -- End unnamed common block + + .toc + +#endif // KMP_OS_AIX diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index fd0a56bce1b7..1dd3c861dbb2 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define LLVM_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define CLANG_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define LLDB_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index 153e86106f12..002ec1eecc00 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400006 -#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18.1.0-rc2-53-gc7b0a6ecd442-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18.1.0-rc3-0-g6c90f8dd5463-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index d06ac507357e..6950d566ff2f 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" *** 2 LINES SKIPPED *** From nobody Sat Apr 20 10:32:36 2024 X-Original-To: dev-commits-src-branches@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 4VM7BF1SP6z5HWKG; Sat, 20 Apr 2024 10:32:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BD5CYmz4PtJ; Sat, 20 Apr 2024 10:32:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609156; 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=MtcqtU1GZ0VcC/79Dwfly28k2eHpaSq/IIRVcCCf3yU=; b=xfXa/j2QGIqqLZ6o5Pv6u5WTb3cW3aFseoYlYSDl0zuFZoJFIC9rQFtZmz9Q6tl/pJhKPG pISMZPVDrJqWa59q/j0EOoPnKlj18r+CrJjYvVm4q5h+e3WdU5OaXkr5PmSmAOHnmiYJmb TYPXmTRROH0cvz/vz3tkDpYT6NSH6d8OAnAW9ROCQTNq7XiDUVDIUaX+KKbrRtih03XFrw o2nX4FCjOrZLEqwhAZ1NCrCE5NovoAxtg/lHjU6Ow39BddY6x+rlfla79KwD9gmVwGg841 GAW3M3CS0LVxTQzu/Lhjb1xiqfuRIjMq9SizNKHJ1JDiN6IlN6sYV9K15dKJwQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609156; a=rsa-sha256; cv=none; b=kyllmlfQwJItkl4e7qWFr1tFDHpwrVeIEfh9zOdO2uLrRl/LFXaAfcTv0E+iIi/op1LIcr ZuWP9e7kl6+Ns7XUc/hmHzLg1LODbE9ES0CQrlpqX7IKKeQbSfPz/szsWlGiojiwLi396V eDPkTmXAUgOOSVnBeshyMGBFFNfK2NWz1N/Wk5R8QzJBZ1uFQqvjrnWES9eQP5k5vBfKaD wDT5zLY639+J0zpssfhT7C3Kgk86m7u1pKcsbp7SU88C4e9BehGzXX1FXRGKJwR0ybHqmr 9w3PotTG3iztpm9YUVMAfgzwXSe0guUmnlPJeE0Xxfis3h6j1owKmi/Q9e+Wzg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609156; 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=MtcqtU1GZ0VcC/79Dwfly28k2eHpaSq/IIRVcCCf3yU=; b=oAfsubT6eP9geA1cWvkdQbSzIRCCS0icT6WuylKgX0rlnNKxHNNTVFlFibvaSQIl1j7SaE Q/L5ll1RJxffvteN1JGO6Lr7lRv/8TkZ9YLgk3KYMG5CnG5NApa9VPROHeN1s7CRREH3I/ Uu9iA0/vI3l7cTxcrrBl+HrQKPOKRSrejUdFwJLFe72x0kggVjw3XFD20iCq4uqkT4jI2e 8zie8BWiGP/V4Q4k9GweoJ9GNP9w6TkkqCT90X8uIrKYqgRrGyrqAidQiDZdW/QLgMOuyx EGxzSXdRjTG0eCPrnDHzGxxpneqFSWbueNhOk+VBNmZme1GhE3PIU5LiWUvbzQ== 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 4VM7BD4fBqzZ2r; Sat, 20 Apr 2024 10:32:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWafd011431; Sat, 20 Apr 2024 10:32:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWaFM011428; Sat, 20 Apr 2024 10:32:36 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:36 GMT Message-Id: <202404201032.43KAWaFM011428@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: ab1bf989a944 - stable/14 - Revert commit 6255157d24e2 from llvm-project (by Dimitry Andric): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: ab1bf989a94495472d91845e83b725d7c20aef5e Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ab1bf989a94495472d91845e83b725d7c20aef5e commit ab1bf989a94495472d91845e83b725d7c20aef5e Author: Dimitry Andric AuthorDate: 2024-03-19 13:07:27 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:17 +0000 Revert commit 6255157d24e2 from llvm-project (by Dimitry Andric): [libc++] Re-enable std::pair trivial copy constructor for FreeBSD >= 14 After many years of using the really old std::pair ABI which did not yet have a trivial copy constructor, FreeBSD 14 and later will finally get rid of it. Only use the old ABI for FreeBSD 13 and earlier. Note: on the FreeBSD side, we will bump our libc++.so version for this, and keep an old compatibility library in a separate package. Differential Revision: https://reviews.llvm.org/D126462 This ABI change can cause crashes when binaries compiled against older libc++ versions are run against binaries compiled against this libc++ version. For example, lang/ldc uses a precompiled bootstrap ldc2 binary that was compiled against the old libc++, but also links against libLLVM-15.so. If libLLVM-15.so is compiled against the new libc++ version, the ABI mismatch results in segfaults or even stack overflows. Note: we can only re-enable the std::pair trivial copy constructors again when the official libc++ ABI version is bumped to 2. PR: 276104 MFC after: 1 month (cherry picked from commit ce4f1f49e036fd806b534decfe38020dae32a384) --- contrib/llvm-project/libcxx/include/__config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index fa5535facb14..a5981984d37e 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -190,7 +190,7 @@ # endif // Feature macros for disabling pre ABI v1 features. All of these options // are deprecated. -# if defined(__FreeBSD__) && __FreeBSD__ < 14 +# if defined(__FreeBSD__) # define _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR # endif // For XCOFF linkers, we have problems if we see a weak hidden version of a symbol From nobody Sat Apr 20 10:32:37 2024 X-Original-To: dev-commits-src-branches@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 4VM7BG1d3Yz5HW17; Sat, 20 Apr 2024 10:32:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BF72V4z4Q42; Sat, 20 Apr 2024 10:32:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609158; 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=PtyVA7GdOcmy0X+wXZoyOaFZsH4bhEmjAPYnDHMip4g=; b=F5tWrjWK7avOIVPFopKGaoYFDMDjHv7js2Y4mSFjRfOEHVxoZGcVOmO8fZZzBzifSvCwsn E3hUND0inLOucINsM/2UQZYTuNcJM5ID155eReepIh03qqA7dL5+JMlNZOjwYgVWQlNoSS 7k+LmUjKGZe23YUmWGGynUH9pGgyUwcjH0Yxxfx2GeJsuwLrhpr0v2XtCb6ILGcAoGW8ZN BVIIet8zjnYOi46ysIJKE9A0IvDb6dKAhwh8yXI3Ef156XTHJ+2m2Bc2DMGP9I3OmQaJqb lfNyN3N75X38hwQIMgyMd7cVKlYNVUOT0JkH1od1UXTvoqUAOqV2aqs2QP1raQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609158; a=rsa-sha256; cv=none; b=UxWqkd7Ygz70453kw4OEUYmm7e76n6+UScDbId/Jx4E3eAY96yF3WFIvyZkEiesu4lg20v 2NF3AbX9mlU7yRJKCDCaBUCGuYBepdm4TUPSU2wON9X9U+UTMzme67BG9FwipI1MAEeSCM FT5K8CWewmWfXJarTLzuLagBkO3kPkO7mtptPSMIo1UbL5tGUS5neHjzZygO5uOJkgWeuC E8u5w+hRKCVnQNUF2X24L7FBDRDi4J1SVctVrjKg0l4fvFF77VYsEsnuNFp+2xdVaBp/3p 6sEQ8dFzML1FuCZ5qNGmEqXgDoGBywODr9SfEVXK992qxnKXMn4K02pA/ZXFvQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609158; 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=PtyVA7GdOcmy0X+wXZoyOaFZsH4bhEmjAPYnDHMip4g=; b=TBYdU3BkTsd4wh/Y5xayHm7mvJn6Yn0wKSM+5PlSvsRHWN8F3qeNkjA0kNTDilMW6Cn84t cqkLUeWnH3thDZ53HGMzRQc6zVHQ939wMZziQpl7WpUY0mVNHqmMXPwHOJkyS+4E/Xakrn Xi5mgztmwY5T2kK3dxyyoD9DbBDt20TwOzuvjrRZXuXYOLkvcJhAJsy1VurFegumoOllTx 0k3g832jflxlujZdP8yj8UYwjaRUDWUeNemrqahV0tFnUG6hQLT8Yo5FHY+gZ1AeCechfX d9ejJyXyBcdXzasPYTuOGxBm0JdBd4eOTo/Ti6F4QgEP/FHhV6CAU4cCVN5KMw== 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 4VM7BF5cpvzZ9m; Sat, 20 Apr 2024 10:32:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWbMc011489; Sat, 20 Apr 2024 10:32:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWbCs011486; Sat, 20 Apr 2024 10:32:37 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:37 GMT Message-Id: <202404201032.43KAWbCs011486@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: 16bdd01787d1 - stable/14 - Merge commit f5f3d5d6534f from llvm-project (by Qizhi Hu): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 16bdd01787d1fad424b774b6d36ce17817143ff4 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=16bdd01787d1fad424b774b6d36ce17817143ff4 commit 16bdd01787d1fad424b774b6d36ce17817143ff4 Author: Dimitry Andric AuthorDate: 2024-03-21 20:50:26 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:17 +0000 Merge commit f5f3d5d6534f from llvm-project (by Qizhi Hu): [Clang][Sema] Fix a crash in lambda instantiation (#85565) Fix https://github.com/llvm/llvm-project/issues/85343 When build lambda expression in lambda instantiation, `ThisType` is required in `Sema::CheckCXXThisCapture` to build `this` capture. Set `this` type by import `Sema::CXXThisScopeRAII` and it will be used later in lambda expression transformation. Co-authored-by: huqizhi <836744285@qq.com> This fixes 'Assertion failed: (!isNull() && "Cannot retrieve a NULL type pointer"), function getCommonPtr" when building the x11-wm/wayfire port. PR: 276104 MFC after: 1 month (cherry picked from commit 49a6e426df84eff1ae54905a02f66910a6a177d3) --- contrib/llvm-project/clang/lib/Sema/TreeTransform.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/contrib/llvm-project/clang/lib/Sema/TreeTransform.h b/contrib/llvm-project/clang/lib/Sema/TreeTransform.h index e55e752b9cc3..2f012cade6b9 100644 --- a/contrib/llvm-project/clang/lib/Sema/TreeTransform.h +++ b/contrib/llvm-project/clang/lib/Sema/TreeTransform.h @@ -13516,6 +13516,16 @@ TreeTransform::TransformLambdaExpr(LambdaExpr *E) { // Capturing 'this' is trivial. if (C->capturesThis()) { + // If this is a lambda that is part of a default member initialiser + // and which we're instantiating outside the class that 'this' is + // supposed to refer to, adjust the type of 'this' accordingly. + // + // Otherwise, leave the type of 'this' as-is. + Sema::CXXThisScopeRAII ThisScope( + getSema(), + dyn_cast_if_present( + getSema().getFunctionLevelDeclContext()), + Qualifiers()); getSema().CheckCXXThisCapture(C->getLocation(), C->isExplicit(), /*BuildAndDiagnose*/ true, nullptr, C->getCaptureKind() == LCK_StarThis); From nobody Sat Apr 20 10:32:38 2024 X-Original-To: dev-commits-src-branches@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 4VM7BH4Kj1z5HVxM; Sat, 20 Apr 2024 10:32:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BH1j8kz4Q2X; Sat, 20 Apr 2024 10:32:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609159; 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=jHuKyQM0zMEmq+cx8q4TlsLuKJZn8780VeKWdKX99N4=; b=uIXWDZnXpavjMlnV9hnJzcpUgCkOGRzRRz7MPjw6JssXz8FYyJG/9XQbcFVPYhi+aj7AfR KKyBaPQUl29wNXSkTjtkvv+x/FiM4wfGG0ZbZZe7cp8ObfaSRApt67FGGw+0+5Aycckcef K9fwrZuqDM235ssTUlt9KIQwEqy/520J5/iZ3XQDXK4+BgkqM85q4s/API+3purpcgtws1 wDTL+8MFLLGUNOqMeL7GY+l/R7RrFKj2A6tQyUDVwtONsgAyOBJcz8nOc+WMHo+TXHd7nJ 19ao2c8G9B/hW56w+8AjhrHWgASaLpDP8uj1FGHX8SAmm/5c5YL66M0zEhO5fQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609159; a=rsa-sha256; cv=none; b=gmBb+OKwYTI8FcM4Ez58QQCPLhqPBwGNFQMMS61WPt3ygNN4ncxO0333kjlFyUF8X0jueA rN9dRvjoIZR3PI9nDrvCm83rebBrlSNguzxc3qy+YzteDDoOuBIsyCiuSPeBe1Hq2RjROs MhyVH1XysrbgCYDOUq7MtSyzQU4VUxaJ67MTR09Z+mYWGSdD83J0B0jA31qRxH9r50LeP9 9G06DA3i/FabyjZUnHsGi2aqFqj7dVen5nxfeafcNd8PEpz1fuWbvjliyW7wjAD8NiiUr4 zMQXLCP1+W5ClrR3dJfL+fuJqFVfRikyqg9Ji9lrweg+yNxqfYdEEKlV3zdzfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609159; 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=jHuKyQM0zMEmq+cx8q4TlsLuKJZn8780VeKWdKX99N4=; b=pXGguSnpq6yODBErDYp7F3AEkKrXF5kuoX4gN6rQvLievsm6Ajf4/dt3HwEc9Jv7rAeQHZ OeQDq4PRpzLwXiieUJ3xvPoH79DO+tZ8YvS+xwZFnFvzvlous6uRiTXMDus7NNPvKqzYZL PTddT77KvKkCbEb/UKNM/gJUUbMHFDeWLV92iBH6QQoMjOtiAfxLuuQ3qiLDyomBBq5R47 3l21VoHy1g83uELe9ql/2PEYrzWZbZKFEGjxXrXzRk31VfOavZICxHQBUAAjg5SEGaaWPh 1T8QfSRww3p/iEJHrAiRWsnmW4cix4wXLDrEHEu0uu/qhfjTOF/CH3328boaNA== 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 4VM7BH1GCLzZ4t; Sat, 20 Apr 2024 10:32:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWdZk011528; Sat, 20 Apr 2024 10:32:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWcX1011525; Sat, 20 Apr 2024 10:32:38 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:38 GMT Message-Id: <202404201032.43KAWcX1011525@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: c9eafe979616 - stable/14 - Merge llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: c9eafe97961631c6d1135b294eb04993144d7d6b Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=c9eafe97961631c6d1135b294eb04993144d7d6b commit c9eafe97961631c6d1135b294eb04993144d7d6b Author: Dimitry Andric AuthorDate: 2024-04-05 22:02:56 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:14:17 +0000 Merge llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879. PR: 276104 MFC after: 1 month (cherry picked from commit 439352ac8257c8419cb4a662abb7f260f31f9932) --- .../clang/include/clang/AST/DeclBase.h | 10 ++ .../clang/include/clang/Sema/ScopeInfo.h | 4 +- .../clang/include/clang/Serialization/ASTReader.h | 7 -- contrib/llvm-project/clang/lib/AST/Decl.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 5 + contrib/llvm-project/clang/lib/Basic/Module.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 32 ++--- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 43 ++++--- .../clang/lib/Driver/ToolChains/WebAssembly.cpp | 27 ++++- .../clang/lib/Driver/ToolChains/WebAssembly.h | 2 +- .../llvm-project/clang/lib/Headers/__stddef_null.h | 2 +- .../clang/lib/Headers/__stddef_nullptr_t.h | 7 +- .../clang/lib/Headers/__stddef_offsetof.h | 7 +- .../clang/lib/Headers/__stddef_ptrdiff_t.h | 7 +- .../clang/lib/Headers/__stddef_rsize_t.h | 7 +- .../clang/lib/Headers/__stddef_size_t.h | 7 +- .../clang/lib/Headers/__stddef_unreachable.h | 7 +- .../clang/lib/Headers/__stddef_wchar_t.h | 7 +- .../llvm-project/clang/lib/Headers/larchintrin.h | 2 +- .../clang/lib/Headers/module.modulemap | 20 ++-- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 9 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 73 +++++++----- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 22 +++- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 22 +++- .../clang/lib/Serialization/ASTReader.cpp | 2 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 8 +- .../clang/lib/Serialization/ASTWriter.cpp | 2 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 8 +- .../clang/lib/StaticAnalyzer/Core/CallEvent.cpp | 2 +- .../llvm-project/compiler-rt/lib/builtins/divtc3.c | 2 +- .../llvm-project/compiler-rt/lib/builtins/fp_lib.h | 41 ++++--- .../compiler-rt/lib/builtins/int_types.h | 8 +- .../llvm-project/compiler-rt/lib/builtins/multc3.c | 2 +- contrib/llvm-project/compiler-rt/lib/msan/msan.cpp | 2 +- contrib/llvm-project/compiler-rt/lib/msan/msan.h | 35 ++++-- .../compiler-rt/lib/msan/msan_allocator.cpp | 3 + .../compiler-rt/lib/msan/msan_linux.cpp | 67 ++++++++--- .../lib/tsan/rtl/tsan_interceptors_posix.cpp | 43 +++---- contrib/llvm-project/libcxx/include/__availability | 7 +- .../llvm-project/libcxx/modules/modules.json.in | 2 +- contrib/llvm-project/lld/COFF/DLL.cpp | 2 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 22 ++++ contrib/llvm-project/lld/ELF/Arch/PPC64.cpp | 3 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 2 + contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 7 +- contrib/llvm-project/lld/ELF/Writer.cpp | 3 + contrib/llvm-project/lld/docs/ReleaseNotes.rst | 5 + .../llvm/include/llvm/Analysis/VectorUtils.h | 5 + .../llvm/include/llvm/BinaryFormat/COFF.h | 5 +- .../llvm-project/llvm/include/llvm/Object/COFF.h | 41 +++++++ .../llvm/include/llvm/Object/COFFImportFile.h | 35 +++++- .../llvm/include/llvm/Support/FormattedStream.h | 51 ++++++-- .../llvm/include/llvm/Target/TargetSchedule.td | 2 +- .../llvm/lib/Analysis/ValueTracking.cpp | 2 + .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 25 ++++ .../llvm/lib/MC/MCParser/AsmParser.cpp | 4 +- .../llvm-project/llvm/lib/Object/ArchiveWriter.cpp | 11 ++ .../llvm/lib/Object/COFFImportFile.cpp | 114 +++++++++++++----- .../llvm/lib/Support/FormattedStream.cpp | 3 + .../Target/AArch64/AArch64Arm64ECCallLowering.cpp | 57 ++++++--- .../lib/Target/AArch64/AArch64CallingConvention.td | 3 + .../lib/Target/AArch64/AArch64ISelLowering.cpp | 10 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.cpp | 2 + .../lib/Target/AArch64/Utils/AArch64BaseInfo.h | 28 ----- .../llvm/lib/Target/ARM/ARMFrameLowering.cpp | 11 +- .../llvm/lib/Target/ARM/ARMFrameLowering.h | 4 + .../llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp | 23 ++-- .../llvm/lib/Target/AVR/AVRInstrInfo.td | 2 +- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 9 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 2 + .../lib/Target/LoongArch/LoongArchTargetMachine.h | 5 + .../Mips/MCTargetDesc/MipsTargetStreamer.cpp | 12 +- .../llvm/lib/Target/Mips/MipsExpandPseudo.cpp | 60 ++++++++-- .../llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 6 - .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 1 + .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 20 ++-- .../lib/Target/RISCV/RISCVTargetTransformInfo.cpp | 3 + .../lib/Target/SystemZ/SystemZISelLowering.cpp | 34 ++++++ .../llvm/lib/Target/X86/X86ISelLowering.cpp | 11 +- .../llvm/lib/Target/X86/X86InstrVecCompiler.td | 3 + .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 4 + .../llvm/lib/Transforms/IPO/ArgumentPromotion.cpp | 6 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 13 ++- .../Transforms/InstCombine/InstCombineCasts.cpp | 4 +- .../Transforms/InstCombine/InstCombineCompares.cpp | 7 ++ .../Transforms/InstCombine/InstCombineSelect.cpp | 9 +- .../InstCombine/InstructionCombining.cpp | 1 + .../Transforms/Instrumentation/ThreadSanitizer.cpp | 9 +- .../lib/Transforms/Scalar/DeadStoreElimination.cpp | 31 ++++- .../llvm/lib/Transforms/Scalar/SROA.cpp | 80 ++++++++----- .../llvm-project/llvm/tools/llvm-mc/llvm-mc.cpp | 5 - .../llvm/tools/llvm-objdump/llvm-objdump.cpp | 7 -- .../llvm/tools/llvm-readobj/COFFImportDumper.cpp | 6 + .../TableGen/MacroFusionPredicatorEmitter.cpp | 12 +- contrib/llvm-project/openmp/runtime/src/kmp.h | 8 +- .../openmp/runtime/src/kmp_affinity.cpp | 129 +++++++++++++++++++-- .../llvm-project/openmp/runtime/src/kmp_affinity.h | 73 +++++++++++- contrib/llvm-project/openmp/runtime/src/kmp_lock.h | 3 +- contrib/llvm-project/openmp/runtime/src/kmp_os.h | 3 +- .../openmp/runtime/src/z_Linux_util.cpp | 37 +++++- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 107 files changed, 1266 insertions(+), 431 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h index 9a4736019d1b..eb7a1a320600 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h @@ -673,6 +673,16 @@ public: /// fragment. See [module.global.frag]p3,4 for details. bool isDiscardedInGlobalModuleFragment() const { return false; } + /// Check if we should skip checking ODRHash for declaration \param D. + /// + /// The existing ODRHash mechanism seems to be not stable enough and + /// the false positive ODR violation reports are annoying and we rarely see + /// true ODR violation reports. Also we learned that MSVC disabled ODR checks + /// for declarations in GMF. So we try to disable ODR checks in the GMF to + /// get better user experiences before we make the ODR violation checks stable + /// enough. + bool shouldSkipCheckingODR() const; + /// Return true if this declaration has an attribute which acts as /// definition of the entity, such as 'alias' or 'ifunc'. bool hasDefiningAttr() const; diff --git a/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h b/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h index 6eaa74382685..06e47eed4e93 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h +++ b/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h @@ -925,8 +925,8 @@ public: /// that were defined in parent contexts. Used to avoid warnings when the /// shadowed variables are uncaptured by this lambda. struct ShadowedOuterDecl { - const VarDecl *VD; - const VarDecl *ShadowedDecl; + const NamedDecl *VD; + const NamedDecl *ShadowedDecl; }; llvm::SmallVector ShadowingDecls; diff --git a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h index cd28226c295b..62c25f5b7a0d 100644 --- a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h +++ b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h @@ -2451,13 +2451,6 @@ private: uint32_t Value; uint32_t CurrentBitsIndex = ~0; }; - -inline bool shouldSkipCheckingODR(const Decl *D) { - return D->getOwningModule() && - D->getASTContext().getLangOpts().SkipODRCheckInGMF && - D->getOwningModule()->isExplicitGlobalModule(); -} - } // namespace clang #endif // LLVM_CLANG_SERIALIZATION_ASTREADER_H diff --git a/contrib/llvm-project/clang/lib/AST/Decl.cpp b/contrib/llvm-project/clang/lib/AST/Decl.cpp index 26fdfa040796..1ee33fd7576d 100644 --- a/contrib/llvm-project/clang/lib/AST/Decl.cpp +++ b/contrib/llvm-project/clang/lib/AST/Decl.cpp @@ -4476,7 +4476,7 @@ unsigned FunctionDecl::getODRHash() { } class ODRHash Hash; - Hash.AddFunctionDecl(this); + Hash.AddFunctionDecl(this, /*SkipBody=*/shouldSkipCheckingODR()); setHasODRHash(true); ODRHash = Hash.CalculateHash(); return ODRHash; diff --git a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp index 8163f9bdaf8d..6b3c13ff206d 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp @@ -1102,6 +1102,11 @@ bool Decl::isInAnotherModuleUnit() const { return M != getASTContext().getCurrentNamedModule(); } +bool Decl::shouldSkipCheckingODR() const { + return getASTContext().getLangOpts().SkipODRCheckInGMF && getOwningModule() && + getOwningModule()->isExplicitGlobalModule(); +} + static Decl::Kind getKind(const Decl *D) { return D->getKind(); } static Decl::Kind getKind(const DeclContext *DC) { return DC->getDeclKind(); } diff --git a/contrib/llvm-project/clang/lib/Basic/Module.cpp b/contrib/llvm-project/clang/lib/Basic/Module.cpp index 925217431d4d..0dac8748a98a 100644 --- a/contrib/llvm-project/clang/lib/Basic/Module.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Module.cpp @@ -301,10 +301,9 @@ bool Module::directlyUses(const Module *Requested) { if (Requested->isSubModuleOf(Use)) return true; - // Anyone is allowed to use our builtin stdarg.h and stddef.h and their - // accompanying modules. - if (Requested->getTopLevelModuleName() == "_Builtin_stdarg" || - Requested->getTopLevelModuleName() == "_Builtin_stddef") + // Anyone is allowed to use our builtin stddef.h and its accompanying modules. + if (Requested->fullModuleNameIs({"_Builtin_stddef", "max_align_t"}) || + Requested->fullModuleNameIs({"_Builtin_stddef_wint_t"})) return true; if (NoUndeclaredIncludes) diff --git a/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp b/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp index 7877e20d77f7..4f22d35f9d3a 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp @@ -186,6 +186,14 @@ class EmitAssemblyHelper { TargetTriple.getVendor() != llvm::Triple::Apple; } + /// Check whether we should emit a flag for UnifiedLTO. + /// The UnifiedLTO module flag should be set when UnifiedLTO is enabled for + /// ThinLTO or Full LTO with module summaries. + bool shouldEmitUnifiedLTOModueFlag() const { + return CodeGenOpts.UnifiedLTO && + (CodeGenOpts.PrepareForThinLTO || shouldEmitRegularLTOSummary()); + } + public: EmitAssemblyHelper(DiagnosticsEngine &_Diags, const HeaderSearchOptions &HeaderSearchOpts, @@ -1029,7 +1037,8 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!actionRequiresCodeGen(Action) && CodeGenOpts.VerifyModule) MPM.addPass(VerifierPass()); - if (Action == Backend_EmitBC || Action == Backend_EmitLL) { + if (Action == Backend_EmitBC || Action == Backend_EmitLL || + CodeGenOpts.FatLTO) { if (CodeGenOpts.PrepareForThinLTO && !CodeGenOpts.DisableLLVMPasses) { if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", @@ -1040,11 +1049,9 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!ThinLinkOS) return; } - if (CodeGenOpts.UnifiedLTO) - TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); MPM.addPass(ThinLTOBitcodeWriterPass( *OS, ThinLinkOS ? &ThinLinkOS->os() : nullptr)); - } else { + } else if (Action == Backend_EmitLL) { MPM.addPass(PrintModulePass(*OS, "", CodeGenOpts.EmitLLVMUseLists, /*EmitLTOSummary=*/true)); } @@ -1058,24 +1065,17 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", uint32_t(1)); - if (CodeGenOpts.UnifiedLTO) - TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); } - if (Action == Backend_EmitBC) + if (Action == Backend_EmitBC) { MPM.addPass(BitcodeWriterPass(*OS, CodeGenOpts.EmitLLVMUseLists, EmitLTOSummary)); - else + } else if (Action == Backend_EmitLL) { MPM.addPass(PrintModulePass(*OS, "", CodeGenOpts.EmitLLVMUseLists, EmitLTOSummary)); + } } - } - if (CodeGenOpts.FatLTO) { - // Set the EnableSplitLTOUnit and UnifiedLTO module flags, since FatLTO - // uses a different action than Backend_EmitBC or Backend_EmitLL. - if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) - TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", - uint32_t(CodeGenOpts.EnableSplitLTOUnit)); - if (CodeGenOpts.UnifiedLTO && !TheModule->getModuleFlag("UnifiedLTO")) + + if (shouldEmitUnifiedLTOModueFlag()) TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); } diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp index bbe14ef4c172..aa9997b87ecf 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp @@ -1241,27 +1241,38 @@ static void emitStoresForConstant(CodeGenModule &CGM, const VarDecl &D, return; } - // If the initializer is small, use a handful of stores. + // If the initializer is small or trivialAutoVarInit is set, use a handful of + // stores. + bool IsTrivialAutoVarInitPattern = + CGM.getContext().getLangOpts().getTrivialAutoVarInit() == + LangOptions::TrivialAutoVarInitKind::Pattern; if (shouldSplitConstantStore(CGM, ConstantSize)) { if (auto *STy = dyn_cast(Ty)) { - const llvm::StructLayout *Layout = - CGM.getDataLayout().getStructLayout(STy); - for (unsigned i = 0; i != constant->getNumOperands(); i++) { - CharUnits CurOff = CharUnits::fromQuantity(Layout->getElementOffset(i)); - Address EltPtr = Builder.CreateConstInBoundsByteGEP( - Loc.withElementType(CGM.Int8Ty), CurOff); - emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, - constant->getAggregateElement(i), IsAutoInit); + if (STy == Loc.getElementType() || + (STy != Loc.getElementType() && IsTrivialAutoVarInitPattern)) { + const llvm::StructLayout *Layout = + CGM.getDataLayout().getStructLayout(STy); + for (unsigned i = 0; i != constant->getNumOperands(); i++) { + CharUnits CurOff = + CharUnits::fromQuantity(Layout->getElementOffset(i)); + Address EltPtr = Builder.CreateConstInBoundsByteGEP( + Loc.withElementType(CGM.Int8Ty), CurOff); + emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, + constant->getAggregateElement(i), IsAutoInit); + } + return; } - return; } else if (auto *ATy = dyn_cast(Ty)) { - for (unsigned i = 0; i != ATy->getNumElements(); i++) { - Address EltPtr = Builder.CreateConstGEP( - Loc.withElementType(ATy->getElementType()), i); - emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, - constant->getAggregateElement(i), IsAutoInit); + if (ATy == Loc.getElementType() || + (ATy != Loc.getElementType() && IsTrivialAutoVarInitPattern)) { + for (unsigned i = 0; i != ATy->getNumElements(); i++) { + Address EltPtr = Builder.CreateConstGEP( + Loc.withElementType(ATy->getElementType()), i); + emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, + constant->getAggregateElement(i), IsAutoInit); + } + return; } - return; } } diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp index 57f4600727ec..0b16b660364f 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp @@ -44,8 +44,15 @@ std::string wasm::Linker::getLinkerPath(const ArgList &Args) const { llvm::sys::fs::can_execute(UseLinker)) return std::string(UseLinker); - // Accept 'lld', and 'ld' as aliases for the default linker - if (UseLinker != "lld" && UseLinker != "ld") + // Interpret 'lld' as explicitly requesting `wasm-ld`, so look for that + // linker. Note that for `wasm32-wasip2` this overrides the default linker + // of `wasm-component-ld`. + if (UseLinker == "lld") { + return ToolChain.GetProgramPath("wasm-ld"); + } + + // Allow 'ld' as an alias for the default linker + if (UseLinker != "ld") ToolChain.getDriver().Diag(diag::err_drv_invalid_linker_name) << A->getAsString(Args); } @@ -73,6 +80,16 @@ void wasm::Linker::ConstructJob(Compilation &C, const JobAction &JA, if (Args.hasArg(options::OPT_s)) CmdArgs.push_back("--strip-all"); + // On `wasip2` the default linker is `wasm-component-ld` which wraps the + // execution of `wasm-ld`. Find `wasm-ld` and pass it as an argument of where + // to find it to avoid it needing to hunt and rediscover or search `PATH` for + // where it is. + if (llvm::sys::path::stem(Linker).ends_with_insensitive( + "wasm-component-ld")) { + CmdArgs.push_back("--wasm-ld-path"); + CmdArgs.push_back(Args.MakeArgString(ToolChain.GetProgramPath("wasm-ld"))); + } + Args.addAllArgs(CmdArgs, {options::OPT_L, options::OPT_u}); ToolChain.AddFilePathLibArgs(Args, CmdArgs); @@ -221,6 +238,12 @@ WebAssembly::WebAssembly(const Driver &D, const llvm::Triple &Triple, } } +const char *WebAssembly::getDefaultLinker() const { + if (getOS() == "wasip2") + return "wasm-component-ld"; + return "wasm-ld"; +} + bool WebAssembly::IsMathErrnoDefault() const { return false; } bool WebAssembly::IsObjCNonFragileABIDefault() const { return true; } diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h index ae60f464c108..76e0ca39bd74 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h @@ -67,7 +67,7 @@ private: llvm::opt::ArgStringList &CmdArgs) const override; SanitizerMask getSupportedSanitizers() const override; - const char *getDefaultLinker() const override { return "wasm-ld"; } + const char *getDefaultLinker() const override; CXXStdlibType GetDefaultCXXStdlibType() const override { return ToolChain::CST_Libcxx; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_null.h b/contrib/llvm-project/clang/lib/Headers/__stddef_null.h index 7336fdab3897..c10bd2d7d988 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_null.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_null.h @@ -7,7 +7,7 @@ *===-----------------------------------------------------------------------=== */ -#if !defined(NULL) || !__has_feature(modules) +#if !defined(NULL) || !__building_module(_Builtin_stddef) /* linux/stddef.h will define NULL to 0. glibc (and other) headers then define * __need_NULL and rely on stddef.h to redefine NULL to the correct value again. diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h index 183d394d56c1..7f3fbe6fe0d3 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _NULLPTR_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_NULLPTR_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _NULLPTR_T #ifdef __cplusplus diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h b/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h index 3b347b3b92f6..84172c6cd273 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h @@ -7,6 +7,11 @@ *===-----------------------------------------------------------------------=== */ -#ifndef offsetof +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(offsetof) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define offsetof(t, d) __builtin_offsetof(t, d) #endif diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h index 3ea6d7d2852e..fd3c893c66c9 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _PTRDIFF_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_PTRDIFF_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _PTRDIFF_T typedef __PTRDIFF_TYPE__ ptrdiff_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h index b6428d0c12b6..dd433d40d973 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _RSIZE_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_RSIZE_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _RSIZE_T typedef __SIZE_TYPE__ rsize_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h index e4a389510bcd..3dd7b1f37929 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _SIZE_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_SIZE_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _SIZE_T typedef __SIZE_TYPE__ size_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h b/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h index 3e7fe0197966..518580c92d3f 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h @@ -7,6 +7,11 @@ *===-----------------------------------------------------------------------=== */ -#ifndef unreachable +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(unreachable) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define unreachable() __builtin_unreachable() #endif diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h index 16a6186512c0..bd69f6322541 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h @@ -9,7 +9,12 @@ #if !defined(__cplusplus) || (defined(_MSC_VER) && !_NATIVE_WCHAR_T_DEFINED) -#ifndef _WCHAR_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_WCHAR_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _WCHAR_T #ifdef _MSC_EXTENSIONS diff --git a/contrib/llvm-project/clang/lib/Headers/larchintrin.h b/contrib/llvm-project/clang/lib/Headers/larchintrin.h index a613e5ca0e5e..f4218295919a 100644 --- a/contrib/llvm-project/clang/lib/Headers/larchintrin.h +++ b/contrib/llvm-project/clang/lib/Headers/larchintrin.h @@ -156,7 +156,7 @@ extern __inline unsigned char return (unsigned char)__builtin_loongarch_iocsrrd_b((unsigned int)_1); } -extern __inline unsigned char +extern __inline unsigned short __attribute__((__gnu_inline__, __always_inline__, __artificial__)) __iocsrrd_h(unsigned int _1) { return (unsigned short)__builtin_loongarch_iocsrrd_h((unsigned int)_1); diff --git a/contrib/llvm-project/clang/lib/Headers/module.modulemap b/contrib/llvm-project/clang/lib/Headers/module.modulemap index a786689d3917..56a13f69bc05 100644 --- a/contrib/llvm-project/clang/lib/Headers/module.modulemap +++ b/contrib/llvm-project/clang/lib/Headers/module.modulemap @@ -155,9 +155,9 @@ module _Builtin_intrinsics [system] [extern_c] { // Start -fbuiltin-headers-in-system-modules affected modules -// The following modules all ignore their top level headers -// when -fbuiltin-headers-in-system-modules is passed, and -// most of those headers join system modules when present. +// The following modules all ignore their headers when +// -fbuiltin-headers-in-system-modules is passed, and many of +// those headers join system modules when present. // e.g. if -fbuiltin-headers-in-system-modules is passed, then // float.h will not be in the _Builtin_float module (that module @@ -190,11 +190,6 @@ module _Builtin_stdalign [system] { export * } -// When -fbuiltin-headers-in-system-modules is passed, only -// the top level headers are removed, the implementation headers -// will always be in their submodules. That means when stdarg.h -// is included, it will still import this module and make the -// appropriate submodules visible. module _Builtin_stdarg [system] { textual header "stdarg.h" @@ -237,6 +232,8 @@ module _Builtin_stdbool [system] { module _Builtin_stddef [system] { textual header "stddef.h" + // __stddef_max_align_t.h is always in this module, even if + // -fbuiltin-headers-in-system-modules is passed. explicit module max_align_t { header "__stddef_max_align_t.h" export * @@ -283,9 +280,10 @@ module _Builtin_stddef [system] { } } -/* wint_t is provided by and not . It's here - * for compatibility, but must be explicitly requested. Therefore - * __stddef_wint_t.h is not part of _Builtin_stddef. */ +// wint_t is provided by and not . It's here +// for compatibility, but must be explicitly requested. Therefore +// __stddef_wint_t.h is not part of _Builtin_stddef. It is always in +// this module even if -fbuiltin-headers-in-system-modules is passed. module _Builtin_stddef_wint_t [system] { header "__stddef_wint_t.h" export * diff --git a/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp b/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp index afb2948f05ae..10c475f617d4 100644 --- a/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp +++ b/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp @@ -2498,9 +2498,12 @@ void ModuleMapParser::parseHeaderDecl(MMToken::TokenKind LeadingToken, } bool NeedsFramework = false; - // Don't add the top level headers to the builtin modules if the builtin headers - // belong to the system modules. - if (!Map.LangOpts.BuiltinHeadersInSystemModules || ActiveModule->isSubModule() || !isBuiltInModuleName(ActiveModule->Name)) + // Don't add headers to the builtin modules if the builtin headers belong to + // the system modules, with the exception of __stddef_max_align_t.h which + // always had its own module. + if (!Map.LangOpts.BuiltinHeadersInSystemModules || + !isBuiltInModuleName(ActiveModule->getTopLevelModuleName()) || + ActiveModule->fullModuleNameIs({"_Builtin_stddef", "max_align_t"})) Map.addUnresolvedHeader(ActiveModule, std::move(Header), NeedsFramework); if (NeedsFramework) diff --git a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp index a300badc6d02..f5bb3e0b42e2 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp @@ -8396,28 +8396,40 @@ void Sema::CheckShadow(NamedDecl *D, NamedDecl *ShadowedDecl, unsigned WarningDiag = diag::warn_decl_shadow; SourceLocation CaptureLoc; - if (isa(D) && isa(ShadowedDecl) && NewDC && - isa(NewDC)) { + if (isa(D) && NewDC && isa(NewDC)) { if (const auto *RD = dyn_cast(NewDC->getParent())) { if (RD->isLambda() && OldDC->Encloses(NewDC->getLexicalParent())) { - if (RD->getLambdaCaptureDefault() == LCD_None) { - // Try to avoid warnings for lambdas with an explicit capture list. + if (const auto *VD = dyn_cast(ShadowedDecl)) { const auto *LSI = cast(getCurFunction()); - // Warn only when the lambda captures the shadowed decl explicitly. - CaptureLoc = getCaptureLocation(LSI, cast(ShadowedDecl)); - if (CaptureLoc.isInvalid()) - WarningDiag = diag::warn_decl_shadow_uncaptured_local; - } else { - // Remember that this was shadowed so we can avoid the warning if the - // shadowed decl isn't captured and the warning settings allow it. + if (RD->getLambdaCaptureDefault() == LCD_None) { + // Try to avoid warnings for lambdas with an explicit capture + // list. Warn only when the lambda captures the shadowed decl + // explicitly. + CaptureLoc = getCaptureLocation(LSI, VD); + if (CaptureLoc.isInvalid()) + WarningDiag = diag::warn_decl_shadow_uncaptured_local; + } else { + // Remember that this was shadowed so we can avoid the warning if + // the shadowed decl isn't captured and the warning settings allow + // it. + cast(getCurFunction()) + ->ShadowingDecls.push_back({D, VD}); + return; + } + } + if (isa(ShadowedDecl)) { + // If lambda can capture this, then emit default shadowing warning, + // Otherwise it is not really a shadowing case since field is not + // available in lambda's body. + // At this point we don't know that lambda can capture this, so + // remember that this was shadowed and delay until we know. cast(getCurFunction()) - ->ShadowingDecls.push_back( - {cast(D), cast(ShadowedDecl)}); + ->ShadowingDecls.push_back({D, ShadowedDecl}); return; } } - - if (cast(ShadowedDecl)->hasLocalStorage()) { + if (const auto *VD = dyn_cast(ShadowedDecl); + VD && VD->hasLocalStorage()) { // A variable can't shadow a local variable in an enclosing scope, if // they are separated by a non-capturing declaration context. for (DeclContext *ParentDC = NewDC; @@ -8468,19 +8480,28 @@ void Sema::CheckShadow(NamedDecl *D, NamedDecl *ShadowedDecl, /// when these variables are captured by the lambda. void Sema::DiagnoseShadowingLambdaDecls(const LambdaScopeInfo *LSI) { for (const auto &Shadow : LSI->ShadowingDecls) { - const VarDecl *ShadowedDecl = Shadow.ShadowedDecl; + const NamedDecl *ShadowedDecl = Shadow.ShadowedDecl; // Try to avoid the warning when the shadowed decl isn't captured. - SourceLocation CaptureLoc = getCaptureLocation(LSI, ShadowedDecl); const DeclContext *OldDC = ShadowedDecl->getDeclContext(); - Diag(Shadow.VD->getLocation(), CaptureLoc.isInvalid() - ? diag::warn_decl_shadow_uncaptured_local - : diag::warn_decl_shadow) - << Shadow.VD->getDeclName() - << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; - if (!CaptureLoc.isInvalid()) - Diag(CaptureLoc, diag::note_var_explicitly_captured_here) - << Shadow.VD->getDeclName() << /*explicitly*/ 0; - Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + if (const auto *VD = dyn_cast(ShadowedDecl)) { + SourceLocation CaptureLoc = getCaptureLocation(LSI, VD); + Diag(Shadow.VD->getLocation(), + CaptureLoc.isInvalid() ? diag::warn_decl_shadow_uncaptured_local + : diag::warn_decl_shadow) + << Shadow.VD->getDeclName() + << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; + if (CaptureLoc.isValid()) + Diag(CaptureLoc, diag::note_var_explicitly_captured_here) + << Shadow.VD->getDeclName() << /*explicitly*/ 0; + Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + } else if (isa(ShadowedDecl)) { + Diag(Shadow.VD->getLocation(), + LSI->isCXXThisCaptured() ? diag::warn_decl_shadow + : diag::warn_decl_shadow_uncaptured_local) + << Shadow.VD->getDeclName() + << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; + Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + } } } diff --git a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp index 940bcccb9e26..b708272ebe7d 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp @@ -14470,6 +14470,23 @@ ExprResult Sema::CreateOverloadedBinOp(SourceLocation OpLoc, CurFPFeatureOverrides()); } + // If this is the .* operator, which is not overloadable, just + // create a built-in binary operator. + if (Opc == BO_PtrMemD) { + auto CheckPlaceholder = [&](Expr *&Arg) { + ExprResult Res = CheckPlaceholderExpr(Arg); + if (Res.isUsable()) + Arg = Res.get(); + return !Res.isUsable(); + }; + + // CreateBuiltinBinOp() doesn't like it if we tell it to create a '.*' + // expression that contains placeholders (in either the LHS or RHS). + if (CheckPlaceholder(Args[0]) || CheckPlaceholder(Args[1])) + return ExprError(); + return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); + } + // Always do placeholder-like conversions on the RHS. if (checkPlaceholderForOverload(*this, Args[1])) return ExprError(); @@ -14489,11 +14506,6 @@ ExprResult Sema::CreateOverloadedBinOp(SourceLocation OpLoc, if (Opc == BO_Assign && !Args[0]->getType()->isOverloadableType()) return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); - // If this is the .* operator, which is not overloadable, just - // create a built-in binary operator. - if (Opc == BO_PtrMemD) - return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); - // Build the overload set. OverloadCandidateSet CandidateSet(OpLoc, OverloadCandidateSet::CSK_Operator, OverloadCandidateSet::OperatorRewriteInfo( diff --git a/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp b/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp index a381d876a54c..b619f5d729e8 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp @@ -1830,7 +1830,27 @@ static TemplateParameterList *GetTemplateParameterList(TemplateDecl *TD) { // Make sure we get the template parameter list from the most // recent declaration, since that is the only one that is guaranteed to // have all the default template argument information. - return cast(TD->getMostRecentDecl())->getTemplateParameters(); + Decl *D = TD->getMostRecentDecl(); + // C++11 [temp.param]p12: + // A default template argument shall not be specified in a friend class + // template declaration. + // + // Skip past friend *declarations* because they are not supposed to contain + // default template arguments. Moreover, these declarations may introduce + // template parameters living in different template depths than the + // corresponding template parameters in TD, causing unmatched constraint + // substitution. + // + // FIXME: Diagnose such cases within a class template: + // template + // struct S { + // template friend struct C; + // }; + // template struct S; + while (D->getFriendObjectKind() != Decl::FriendObjectKind::FOK_None && + D->getPreviousDecl()) + D = D->getPreviousDecl(); + return cast(D)->getTemplateParameters(); } DeclResult Sema::CheckClassTemplate( diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp index 028610deb300..490b8cb10a48 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp @@ -9745,7 +9745,7 @@ void ASTReader::finishPendingActions() { !NonConstDefn->isLateTemplateParsed() && // We only perform ODR checks for decls not in the explicit // global module fragment. - !shouldSkipCheckingODR(FD) && + !FD->shouldSkipCheckingODR() && FD->getODRHash() != NonConstDefn->getODRHash()) { if (!isa(FD)) { PendingFunctionOdrMergeFailures[FD].push_back(NonConstDefn); diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp index 321c11e55c14..110f55f8c0f4 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp @@ -832,7 +832,7 @@ void ASTDeclReader::VisitEnumDecl(EnumDecl *ED) { Reader.mergeDefinitionVisibility(OldDef, ED); // We don't want to check the ODR hash value for declarations from global // module fragment. - if (!shouldSkipCheckingODR(ED) && + if (!ED->shouldSkipCheckingODR() && OldDef->getODRHash() != ED->getODRHash()) Reader.PendingEnumOdrMergeFailures[OldDef].push_back(ED); } else { @@ -874,7 +874,7 @@ void ASTDeclReader::VisitRecordDecl(RecordDecl *RD) { VisitRecordDeclImpl(RD); // We should only reach here if we're in C/Objective-C. There is no // global module fragment. - assert(!shouldSkipCheckingODR(RD)); + assert(!RD->shouldSkipCheckingODR()); RD->setODRHash(Record.readInt()); // Maintain the invariant of a redeclaration chain containing only @@ -2152,7 +2152,7 @@ void ASTDeclReader::MergeDefinitionData( } // We don't want to check ODR for decls in the global module fragment. - if (shouldSkipCheckingODR(MergeDD.Definition)) + if (MergeDD.Definition->shouldSkipCheckingODR()) return; if (D->getODRHash() != MergeDD.ODRHash) { @@ -3526,7 +3526,7 @@ ASTDeclReader::FindExistingResult ASTDeclReader::findExisting(NamedDecl *D) { // same template specialization into the same CXXRecordDecl. auto MergedDCIt = Reader.MergedDeclContexts.find(D->getLexicalDeclContext()); if (MergedDCIt != Reader.MergedDeclContexts.end() && - !shouldSkipCheckingODR(D) && MergedDCIt->second == D->getDeclContext()) + !D->shouldSkipCheckingODR() && MergedDCIt->second == D->getDeclContext()) Reader.PendingOdrMergeChecks.push_back(D); return FindExistingResult(Reader, D, /*Existing=*/nullptr, diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp index 73018c1170d8..378a1f86bd53 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp @@ -6010,7 +6010,7 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { BitsPacker DefinitionBits; - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); DefinitionBits.addBit(ShouldSkipCheckingODR); #define FIELD(Name, Width, Merge) \ diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp index e73800100e3c..42583c09f009 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp @@ -488,7 +488,7 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { BitsPacker EnumDeclBits; EnumDeclBits.addBits(D->getNumPositiveBits(), /*BitWidth=*/8); EnumDeclBits.addBits(D->getNumNegativeBits(), /*BitWidth=*/8); - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); EnumDeclBits.addBit(ShouldSkipCheckingODR); EnumDeclBits.addBit(D->isScoped()); EnumDeclBits.addBit(D->isScopedUsingClassTag()); @@ -514,7 +514,7 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { !D->isTopLevelDeclInObjCContainer() && !CXXRecordDecl::classofKind(D->getKind()) && !D->getIntegerTypeSourceInfo() && !D->getMemberSpecializationInfo() && - !needsAnonymousDeclarationNumber(D) && !shouldSkipCheckingODR(D) && + !needsAnonymousDeclarationNumber(D) && !D->shouldSkipCheckingODR() && D->getDeclName().getNameKind() == DeclarationName::Identifier) AbbrevToUse = Writer.getDeclEnumAbbrev(); @@ -680,7 +680,7 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { // FIXME: stable encoding FunctionDeclBits.addBits(llvm::to_underlying(D->getLinkageInternal()), 3); FunctionDeclBits.addBits((uint32_t)D->getStorageClass(), /*BitWidth=*/3); - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); FunctionDeclBits.addBit(ShouldSkipCheckingODR); FunctionDeclBits.addBit(D->isInlineSpecified()); FunctionDeclBits.addBit(D->isInlined()); @@ -1514,7 +1514,7 @@ void ASTDeclWriter::VisitCXXMethodDecl(CXXMethodDecl *D) { D->getFirstDecl() == D->getMostRecentDecl() && !D->isInvalidDecl() && !D->hasAttrs() && !D->isTopLevelDeclInObjCContainer() && D->getDeclName().getNameKind() == DeclarationName::Identifier && - !shouldSkipCheckingODR(D) && !D->hasExtInfo() && + !D->shouldSkipCheckingODR() && !D->hasExtInfo() && !D->isExplicitlyDefaulted()) { if (D->getTemplatedKind() == FunctionDecl::TK_NonTemplate || D->getTemplatedKind() == FunctionDecl::TK_FunctionTemplate || diff --git a/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp b/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp index 0ac1d91b79be..bc14aea27f67 100644 --- a/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp +++ b/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp @@ -1409,7 +1409,7 @@ CallEventManager::getSimpleCall(const CallExpr *CE, ProgramStateRef State, if (const auto *OpCE = dyn_cast(CE)) { const FunctionDecl *DirectCallee = OpCE->getDirectCallee(); if (const auto *MD = dyn_cast(DirectCallee)) - if (MD->isInstance()) + if (MD->isImplicitObjectMemberFunction()) return create(OpCE, State, LCtx, ElemRef); } else if (CE->getCallee()->getType()->isBlockPointerType()) { diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c b/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c index e970cef574b2..099de5802daf 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c +++ b/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c @@ -13,7 +13,7 @@ #define QUAD_PRECISION #include "fp_lib.h" -#if defined(CRT_HAS_TF_MODE) +#if defined(CRT_HAS_F128) // Returns: the quotient of (a + ib) / (c + id) diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h b/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h index af406e760497..c4f0a5b9587f 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h +++ b/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h @@ -22,6 +22,7 @@ #include "int_lib.h" #include "int_math.h" +#include "int_types.h" #include #include #include @@ -93,13 +94,14 @@ static __inline void wideMultiply(rep_t a, rep_t b, rep_t *hi, rep_t *lo) { COMPILER_RT_ABI fp_t __adddf3(fp_t a, fp_t b); #elif defined QUAD_PRECISION -#if defined(CRT_HAS_TF_MODE) +#if defined(CRT_HAS_F128) && defined(CRT_HAS_128BIT) typedef uint64_t half_rep_t; typedef __uint128_t rep_t; typedef __int128_t srep_t; typedef tf_float fp_t; #define HALF_REP_C UINT64_C #define REP_C (__uint128_t) +#if defined(CRT_HAS_IEEE_TF) // Note: Since there is no explicit way to tell compiler the constant is a // 128-bit integer, we let the constant be casted to 128-bit integer #define significandBits 112 @@ -188,7 +190,10 @@ static __inline void wideMultiply(rep_t a, rep_t b, rep_t *hi, rep_t *lo) { #undef Word_HiMask #undef Word_LoMask #undef Word_FullMask -#endif // defined(CRT_HAS_TF_MODE) *** 3106 LINES SKIPPED *** From nobody Sat Apr 20 10:32:40 2024 X-Original-To: dev-commits-src-branches@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 4VM7BJ5vF6z5HVtr; Sat, 20 Apr 2024 10:32:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BJ3ZwLz4Prd; Sat, 20 Apr 2024 10:32:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609160; 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=T20lPtZR3SY4sbalWpyzX8eEz7s5H/g6Fv1GgIk+8Kk=; b=iRhiv0ve54OHV0NgzQhbDAhIGcF20YbCUbyCfGylV8PvJGDJiPPvYyf0JFqqMwefa0VOAw nyvQZoZTE2St9znlmwh1BlMqUqhwqBbzgHG6UaDV+lz0IO+5xMwsEO6rixLvZ40PjxQHyp NgH8Oti7FMuuBgao2s2ueuojINsEbnAzRe5Wbi2xnnrhmJu+0Ppx9W0LEAK0NgJmuADMLw +zWRCVau3Qf1XBQLRZ4rCwd75lD73sAYpeg9JQbf4kW8Z1MOtW3kSEmcLsWCXlfoOMTB/u 3o6M9Fek5gEPq63Ad6fb4ryNDxt2VTWJ3rcqswIv1xw025TED0OQjinXR7HISQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609160; a=rsa-sha256; cv=none; b=MhK9dwUvX0KAIWMYhoy5YGZbIN5rkZZFq5laYd4JFdR5LIG8otnm6/sQGnBKtYqQBmBVEb E++9ZubfQmgagf7CW79NT+BDfTPRdPELSS/awYeX8DdxP1ek5fpP32QD1lHZGcUywnfMqi ePqD/jj7Sna6OrQ3eFpV8x4aqwrkv1DbFB8wajBWzPewzbvMLladMx7sdOv5ZDGM3W89kH MiJSaGjDyy3IoXanR6pKqWWi55FBXpH85MRa91Jb5Ar8mz6qvtIyo30KvlR+TQgqSQQ3Qj 0090Mle/UPKeg4wOIr5hfG9E3qQU+YRokLlENk4CH3Ru/OKi5Zbd8k+EH6Ltjg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609160; 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=T20lPtZR3SY4sbalWpyzX8eEz7s5H/g6Fv1GgIk+8Kk=; b=loEU5taIda7G9C8C0wRWpWZ5IAkbaCh68az43cdVt87lSjqGTki3P3fzZ1Dj88b3pplFfo LYooDMIVCf7hNAWZpvH90bPXNgFnaWgU0P2QKqLslaG0SYFX6tU0KtOvAkX9XHl0SEBrmr c+FKTtHYC27mvE49zFosbeDhhVOax/Oc+kpyEb434MTPF526C+P6PL/hMoX5Ihh7QMlkev 6Gr2WerFBpCk/paeveO/zuSF0g+87hCFK4y6aR1KmEOT2IvBTKq7TvVnaNN5aMfysrs57W GaQvNqprwgVuw90v6GFkbxvkfunAlwZhpgrFFaYQLV4Yje1DBp+ALjyfhsVQnA== 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 4VM7BJ2HQWzYhM; Sat, 20 Apr 2024 10:32:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWevZ011576; Sat, 20 Apr 2024 10:32:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWejo011573; Sat, 20 Apr 2024 10:32:40 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:40 GMT Message-Id: <202404201032.43KAWejo011573@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: c7c33b213a8a - stable/14 - Fix arm64 build after llvm 18.1.3 upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: c7c33b213a8a7f3203015809def9ae25fa77d8d1 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=c7c33b213a8a7f3203015809def9ae25fa77d8d1 commit c7c33b213a8a7f3203015809def9ae25fa77d8d1 Author: Dimitry Andric AuthorDate: 2024-04-07 00:07:38 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:24 +0000 Fix arm64 build after llvm 18.1.3 upgrade Apparently clang 18 has become more strict about using floating point registers in inline assembly when -mgeneral-regs-only is used. This causes sys/arm64/arm64/vfp.c to fail to compile, with "error: instruction requires: fp-armv8", and "error: expected readable system register". To fix it, similar to other files compiled for arm64, disable -mgeneral-regs-only for this particular file. PR: 276104 MFC after: 1 month (cherry picked from commit f4d93b67611f6f8b19db7bac6b0973b2ef0cfcb6) --- sys/conf/files.arm64 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64 index 218571d0e23a..b142999ec659 100644 --- a/sys/conf/files.arm64 +++ b/sys/conf/files.arm64 @@ -82,7 +82,8 @@ arm64/arm64/uma_machdep.c standard arm64/arm64/undefined.c standard arm64/arm64/unwind.c optional ddb | kdtrace_hooks | stack \ compile-with "${NORMAL_C:N-fsanitize*}" -arm64/arm64/vfp.c standard +arm64/arm64/vfp.c standard \ + compile-with "${NORMAL_C:N-mgeneral-regs-only}" arm64/arm64/vm_machdep.c standard arm64/coresight/coresight.c standard From nobody Sat Apr 20 10:32:41 2024 X-Original-To: dev-commits-src-branches@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 4VM7BL1p4yz5HVtw; Sat, 20 Apr 2024 10:32:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BK4gCFz4Prs; Sat, 20 Apr 2024 10:32:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609161; 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=jqnleGtJ3FfJfCIxe7rC0OsT6spNPa1TnD93IkQ3Jr0=; b=OIfJJdQ+HQopv5GyuuoY9dqQVmxUcPPVBR3VT+Bowso+M3RzD4LKzhqrlBPTDvm9L5Uz37 dMWdCoV6T3Xdrk58SorSt+jihWNcEfAktb/MLVvgURqPaDC5Q0Sq9b43VjuFkPFibCEOfJ XGqk2B/R7GenTJJaHe8mCzLf8T8H1vqR/p7kl5zh1yOWwsyaqAGbSnFZxT8tGocqab0WPB 5VnzvK8fjDZqr3UprTzuj13zOp08xvDG9h04QWSnow8Za5UXkODZIn9UCqwvXSVBIy29Wf /VvizykUTkLovTFAoPWQJZmejQ4ufbXXs+Rc3b6BfKLZUq4gP8HNImSRGxUbVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609161; a=rsa-sha256; cv=none; b=EJzMofus2ZeufePp+oejfXFhejs1Tnkq/i60hNAYqK76h1V6ljPXqz9KcssYYyo5mCSTsU xvIqfKsHTVmZpBGbmDJvyEA0RiV3bVmNLJ3AyKuTCmYVehkjiPiP73HW9VOJqPzgSDFMKD 9gWcJWLPN4xeZH4qR7DYkkEPju8nGQowzpLz8Efgwd6oHs1AINL63MekbO8Ukz/ZJszNjD xeSzi8x5JRPugBVJgHgGyiW57FuHLoiV01IBb8vS7HN538MwY8JncEQmG0xa3mb/o+2pTH /xWepiaNdvecU7ijy3l9/0PERF0Mf6fUPvv4g2V/YdTMtkGpVOQXMIXHnIBpIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609161; 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=jqnleGtJ3FfJfCIxe7rC0OsT6spNPa1TnD93IkQ3Jr0=; b=FijVTfXPGtNvfMm9HQIBR37HsKGoecTKjof/a8aJr0OVbxvw0gai9FOc29/VQF2R37vbFP hPn3KcFstsBJo4ZddXjYWhgQpoMZ6LeAdwamSOkjkx0+8w8ZPyhuf+cV0JSNuVzocTfwuZ aSzhjFGXpmtTkhbsoz2f5mrKBGsMLUZiSnol3LZobJaImirlw/Ea6vSj1D99WSSge0USJd hu0oFjBFAeXM9k9Y32zA43uwObS2HKwKOudhrAeAqAKm0Ua/DKwq4jTYimjjK4X+pBGdUA /znTcvAfj0W/3aAHpFqNKkcBBMR53Qxiwm2Cp63/IL9IfpTDUBrCstQ7gmYNyA== 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 4VM7BK3DdXzYqD; Sat, 20 Apr 2024 10:32:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWfcT011636; Sat, 20 Apr 2024 10:32:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWfst011633; Sat, 20 Apr 2024 10:32:41 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:41 GMT Message-Id: <202404201032.43KAWfst011633@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: f0e05595a1b4 - stable/14 - Fix arm64 build after llvm 18.1.3 upgrade (take 2) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: f0e05595a1b47554cdbfcb84f33d03b921d375de Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=f0e05595a1b47554cdbfcb84f33d03b921d375de commit f0e05595a1b47554cdbfcb84f33d03b921d375de Author: Dimitry Andric AuthorDate: 2024-04-07 09:23:06 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 Fix arm64 build after llvm 18.1.3 upgrade (take 2) Instead of compiling the whole sys/arm64/arm64/vfp.c file without -mgeneral-regs-only, which might have unwanted side effects, add ".arch_extension fp" / ".arch_extension nofp" pairs to the inline assembly. PR: 276104 Suggested by: andrew MFC after: 1 month (cherry picked from commit 61e482f2fcd53bbc7fd3d4cc8b7df79d5d57d75c) --- sys/arm64/arm64/vfp.c | 4 ++++ sys/conf/files.arm64 | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/vfp.c b/sys/arm64/arm64/vfp.c index ced1a446f0a8..be98af945b0a 100644 --- a/sys/arm64/arm64/vfp.c +++ b/sys/arm64/arm64/vfp.c @@ -110,6 +110,7 @@ vfp_store(struct vfpstate *state) vfp_state = state->vfp_regs; __asm __volatile( + ".arch_extension fp\n" "mrs %0, fpcr \n" "mrs %1, fpsr \n" "stp q0, q1, [%2, #16 * 0]\n" @@ -128,6 +129,7 @@ vfp_store(struct vfpstate *state) "stp q26, q27, [%2, #16 * 26]\n" "stp q28, q29, [%2, #16 * 28]\n" "stp q30, q31, [%2, #16 * 30]\n" + ".arch_extension nofp\n" : "=&r"(fpcr), "=&r"(fpsr) : "r"(vfp_state)); state->vfp_fpcr = fpcr; @@ -145,6 +147,7 @@ vfp_restore(struct vfpstate *state) fpsr = state->vfp_fpsr; __asm __volatile( + ".arch_extension fp\n" "ldp q0, q1, [%2, #16 * 0]\n" "ldp q2, q3, [%2, #16 * 2]\n" "ldp q4, q5, [%2, #16 * 4]\n" @@ -163,6 +166,7 @@ vfp_restore(struct vfpstate *state) "ldp q30, q31, [%2, #16 * 30]\n" "msr fpcr, %0 \n" "msr fpsr, %1 \n" + ".arch_extension nofp\n" : : "r"(fpcr), "r"(fpsr), "r"(vfp_state)); } diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64 index b142999ec659..218571d0e23a 100644 --- a/sys/conf/files.arm64 +++ b/sys/conf/files.arm64 @@ -82,8 +82,7 @@ arm64/arm64/uma_machdep.c standard arm64/arm64/undefined.c standard arm64/arm64/unwind.c optional ddb | kdtrace_hooks | stack \ compile-with "${NORMAL_C:N-fsanitize*}" -arm64/arm64/vfp.c standard \ - compile-with "${NORMAL_C:N-mgeneral-regs-only}" +arm64/arm64/vfp.c standard arm64/arm64/vm_machdep.c standard arm64/coresight/coresight.c standard From nobody Sat Apr 20 10:32:42 2024 X-Original-To: dev-commits-src-branches@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 4VM7BM06Ryz5HVxS; Sat, 20 Apr 2024 10:32:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BL4lmjz4Q4R; Sat, 20 Apr 2024 10:32:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609162; 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=rIbDGK1+iuzvyO7VpVNixn4vdMBtmgtYygcaXfdmun4=; b=ubl8Q5q4yO/heVrm4zaI/yYcoGNvBpcZao5xXnsG+1+SuBOwTpvFhPpycsfgGYLhDW5wgC mrW1KhLQnhRO8U6GTEFXSU3HosP6/WGXtbYn+rtuxBR5raeobVqEJtTclrn0/YyHrM1aZq HQSLTwZOuqRrQ2naGTgV8DrEWgJqdEZ8Zfz+y52fKMWb+hi3fzCI3ht0Xeo96wPGjDyotW U5sGV8CL11izd+g5jSJE1ED67zw2fN/LwaFW2O5PLze6giPfjH9jWo4BTg2ZkjAa8VtRBY xsi5GY79mIic7Yofz+u+U6kPYYufgZ70iSbVjnfW7UKFq7XcW/IG3SW7SDp9hA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609162; a=rsa-sha256; cv=none; b=CKu8UxiBtWnZblNfEdvNUVnNA2C1sMW06yGdbrLO6qQrpKT3ZApHn4kc53GNktO9XLXnCV J78P000IXDfkhgxQfIDsnHn+jmIeZU/iWEzp8sZsR8X8CJzG7clyi/mQXh+h1s1uAcFnh+ Nm2QicKGONYLlqWZF0NJ96HukFvj0abnZbKIZnsQJO3eEA302vCEGKtPTrJd3IEcSYnkMk hBkXIlWkM4UJ9nP5h7BmORrM7uTSa7W7xAaQiM0zQ5t/5p8N/4tNcFCGH20gjunldlj6vY u02wFs8l16IkbCBxjoRKz+8o+ebFbrgYOPoKi27fUaQqkBZRzbFy2suM6NdYrQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609162; 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=rIbDGK1+iuzvyO7VpVNixn4vdMBtmgtYygcaXfdmun4=; b=UwJFqmH4qPK8V7trd/TyMs1bP1QqDE/VHYqPMv1NlGkw3SMJzX4DQztVyktzdR64ilDhIN E7czlvosfU5tkVXSD4DiKC5/Uwow38hEP1KDYHImdkTHYcjNUAq6v0p2pzTSyz4sWPhtgy dg5ycTjZwxRqhwgbWFiJ+RN3CaAeFELdS/zhWaZrHeH5FHKNm2vJhfDh1az87QC541w3zR 7H8oiZS5IF9Y0qkaupELrapKu1PKd1hthdV1e1wMGZBxHCS9ST74IJfPRhVvBN/ZJvPkYj 8SEBKGylQro/OGHRTzoMnQFsKH0nkBo835RAQ3HznSg9kEt/Ndd6fDlMthWJ5A== 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 4VM7BL4FrMzZ2t; Sat, 20 Apr 2024 10:32:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWgHl011681; Sat, 20 Apr 2024 10:32:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWgnY011678; Sat, 20 Apr 2024 10:32:42 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:42 GMT Message-Id: <202404201032.43KAWgnY011678@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: 924cf780a23a - stable/14 - Fix GENERIC-KASAN kernel build for amd64 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 924cf780a23a6c01638ee9865dcd63eb21c72b4a Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=924cf780a23a6c01638ee9865dcd63eb21c72b4a commit 924cf780a23a6c01638ee9865dcd63eb21c72b4a Author: Dimitry Andric AuthorDate: 2024-04-07 17:56:03 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 Fix GENERIC-KASAN kernel build for amd64 Work around https://github.com/llvm/llvm-project/issues/87923, which leads to an assertion failure compiling several kernel source files with asan enabled. PR: 276104 MFC after: 1 month (cherry picked from commit b811dac2115a6ada606c03d7d823a95d11c5f3c9) --- sys/conf/kern.pre.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index 6bf647f5c3ea..567c68e5887e 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -111,6 +111,11 @@ SAN_CFLAGS+= -DSAN_NEEDS_INTERCEPTORS -DSAN_INTERCEPTOR_PREFIX=kasan \ # upstreamed similar to: https://reviews.llvm.org/D98285 # SAN_CFLAGS+= -mllvm -asan-mapping-offset=0xdfff208000000000 +.elif ${MACHINE_CPUARCH} == "amd64" && \ + ${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 180000 +# Work around https://github.com/llvm/llvm-project/issues/87923, which leads to +# an assertion failure compiling dtrace.c with asan enabled. +SAN_CFLAGS+= -mllvm -asan-use-stack-safety=0 .endif .endif From nobody Sat Apr 20 10:32:43 2024 X-Original-To: dev-commits-src-branches@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 4VM7BN1wpVz5HWMM; Sat, 20 Apr 2024 10:32: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BM66mkz4Q32; Sat, 20 Apr 2024 10:32:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609163; 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=ywqohs+4WmCqttFLIs94Dd9fJA2hiQBhZnJAysc1WJM=; b=uyEFGGGApIsx97MhlubcpVUbRupbNVDNisC+tlmRKHmbe4bfnIUKSDzK6ipbmVRDylZr0P 8ZkNkND58+U5Pvk6s9TRWOY5AXxJmGp97Xmhymp3tGL1JvYqQx8+sFZEvmz8SwgH4kUjin u7riLBwJo8iiASYmgsvPllaNx2oPCS1H4gAvr1BAhi+/Wr9SYVQn7SiWbxqY1NiOOmvbR1 a5ImjuXVHm4tPEhPUz5ozIjrRshfSio9BIvXZfFl1nLA6KBs5ahewT/X8bPnQ5+9XRD3mP RLkI0AqFlUPg58NqodMLNDmbblpCq6XEDi7sYqmDzX5WVKKQOurQ0ukKergDmg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609163; a=rsa-sha256; cv=none; b=KR5EHKwnSHmsxl98ejFgSwhIKs87eP2yJO/l3xozsoQjTcZD7lgUN3wVqUw2YERYVCC8aO XpOWLYbpQgY481wCs/ZjDaNKbRD20kPbRuSOBHMqEID8mReRugSptbnA06+lH8OQl+0NEl RGqRNziwx4yU2Sfh/4U7UKHYihs/hIYIP/0PTGIaHsC+sbk57/4TdT4QFsQz/w+kHX9BFW ASyqfT8zHFNF7oqRqa4ihWh1zmZVsUcxoTwsRoatsyhzuArr8ge49R65A6VKWr3978iCPQ RfNWkTwvksYI+R4g8dxjmhqippC64cI2oH7HQSWfBZjJs98h+apkcgGqQwKrnQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609163; 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=ywqohs+4WmCqttFLIs94Dd9fJA2hiQBhZnJAysc1WJM=; b=nnGOh3/IeL8X1cIk5OJJtoPM8mrpumcZbzn/jUEaY076hais+Jb/dv+1S25+2mvz7yeFPo 51GDSktEctQ/S0O3cazySL99hPRnA26gcaY1Ts8UiJdanNH8WzMlbkas9u78Bz0QDR1Uq+ RUBBhhZkpgqag4h9BOUgZb8ZME+J8yvRY1J7cObJCMIm7WD6nB9NbDj3jU30gkGfDSD2Tl xHpPnVAnr5IQxZ8qNWfIC7EfNlX0zDAubkeHuoTBiFIVO61pmMFFRegttlvlojBW6i4ULs gc6qCcwYPsgqoNaxlcwUOkPtbd7tY8vSe7QqdXehgyRgP/gbsz+uJv0foXZ86A== 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 4VM7BM5KMJzZ9n; Sat, 20 Apr 2024 10:32:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWhqJ011723; Sat, 20 Apr 2024 10:32:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWhcx011720; Sat, 20 Apr 2024 10:32:43 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:43 GMT Message-Id: <202404201032.43KAWhcx011720@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: 329e66dd048e - stable/14 - libcompiler_rt Makefile.inc: remove debugging messages List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 329e66dd048ea64e06aff7dd3d5c5bf679e4af25 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=329e66dd048ea64e06aff7dd3d5c5bf679e4af25 commit 329e66dd048ea64e06aff7dd3d5c5bf679e4af25 Author: Dimitry Andric AuthorDate: 2024-04-07 18:16:50 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 libcompiler_rt Makefile.inc: remove debugging messages PR: 276104 MFC after: 1 month (cherry picked from commit d00b9344bb10a9a35b02df33475bec951dfccd78) --- lib/libcompiler_rt/Makefile.inc | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index 76b66b19d910..d9fe3d8bc8f2 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -1,6 +1,5 @@ CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/:C/powerpc/ppc/} -.info DIMDBG: CRTARCH=${CRTARCH} CRTSRC= ${SRCTOP}/contrib/llvm-project/compiler-rt/lib/builtins @@ -131,7 +130,6 @@ SRCF+= floatundisf # 80-bit long double functions, only used on x86. # .if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" -.info DIMDBG: Enabling 80-bit long double SRCF+= divxc3 SRCF+= extendxftf2 SRCF+= fixxfdi @@ -153,8 +151,6 @@ SRCS+= floatundixf.c SRCF+= floatdixf SRCF+= floatundixf .endif -.else -.info DIMDBG: NOT enabling 80-bit long double .endif # __cpu_model support, only used on aarch64 and x86 @@ -178,7 +174,6 @@ SRCF+= fp_mode # .if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ ${MACHINE_CPUARCH} == "riscv" -.info DIMDBG: Enabling 128-bit quad precision SRCF+= addtf3 SRCF+= comparetf2 SRCF+= divtc3 @@ -205,8 +200,6 @@ SRCF+= subtf3 SRCF+= trunctfdf2 SRCF+= trunctfhf2 SRCF+= trunctfsf2 -.else -.info DIMDBG: NOT enabling 128-bit quad precision .endif # These are already shipped by libc.a on some architectures. From nobody Sat Apr 20 10:32:44 2024 X-Original-To: dev-commits-src-branches@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 4VM7BP1gKmz5HWPq; Sat, 20 Apr 2024 10:32:45 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BN6kv0z4QD1; Sat, 20 Apr 2024 10:32:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609165; 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=VqeC3CHPqZbnWAuXPNzhQXO1+HipDfdriWOKT3AylvQ=; b=UIdx/n08R8xdfvtr64Z+Q3wpTdLXjYgol5lAwLTaMULC1WH4MjKFCeV52625zxzJUY3uiS xVcOZTr2jdj1SJyttJ8jsgBJiuCROP21PxXnZwEUZPc+PGwylTioAymN9kd0F5O2SM4Zp/ zFS3VCxmagq/Vepfm/odhWoWEmGEIUsMmOr/33eRWnblQlYjn4VjG3T/K5MSim5sThXX4e GZvQAo+/hW20bGs+994GxlURF498qHwv9pjmtjSPQtBPW3QQdimd2y21yIxsDIPM5pLw8N EpQrmA81wqfIqyjiQ4qQzZFJgcBsEG+GjOp8ODC6i+FvlawvhBNknjhA4dlU1A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609164; a=rsa-sha256; cv=none; b=wCKtWyZ0hlNGj4x4cW/N0tvPmWtmrcFByo8G5DUbAZkD+Km1/sYkKJYrXKG+5KtFtTCFAl g9dQsPGY75fLq/r6K68s460gR5OMdNLA0C9t5ltqoiF+TgCAhSgEYpuCXafn9dvk+c7gka 4i8DCbbVwtlg/0Z3gzXapXDy2iUrNiyo+AWCPmBsM3tsEeZPczjB7LzlgOOhWWJF1ztfuR su8jxg+oRcFBOfDyfGuMsZXiD6S3M87DCfgiQIlJESq1TGheoWqkpe1py3XHAW4D90QBur wmaqJm0DMZl7AAm5VF5pad1MG5fmsKG7Qy4J4e7UnxGRwfS1jJUUf9gGz1DeWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609164; 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=VqeC3CHPqZbnWAuXPNzhQXO1+HipDfdriWOKT3AylvQ=; b=LxtFprlUuyrL5NFKvddRIZ9JyMLwoFyTeVhYiHCR/KTvU1dU9Je4AHMww3vaH7I1EN7+9W oJQuBa0wVLpG4pMv4YoxUlQ/o3bmXOb+uCpgtMaLkcSnYrUa+B3EeSPA4EuaLjVACvIJhO AoFI4YvIJNtcpU+/r8V7MzEqZLYXuF2z8hEx+fRW5vXDmfrvDWJOYyIUnKWbzepa0n2i8f eBMlfQtZTi6RgLT7lphT3eBIlhW3DbUNHE88uPptKd8Qaz8n5uS4k/SdXI4artWF4R8qNs sc73Q7DGp9DvqNQjnGx/IV72qmuF3/KkJ1TOy5T2IW4RDRG5QEgLgkbBa9epfg== 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 4VM7BN6LTtzYqF; Sat, 20 Apr 2024 10:32:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWiXY011783; Sat, 20 Apr 2024 10:32:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWi0S011780; Sat, 20 Apr 2024 10:32:44 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:44 GMT Message-Id: <202404201032.43KAWi0S011780@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: 24c907849352 - stable/14 - libcompiler_rt Makefile.inc: don't build bfloat16 support for gcc < 13 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 24c907849352847965a34db43bb5eeec5358145c Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=24c907849352847965a34db43bb5eeec5358145c commit 24c907849352847965a34db43bb5eeec5358145c Author: Dimitry Andric AuthorDate: 2024-04-07 18:21:01 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 libcompiler_rt Makefile.inc: don't build bfloat16 support for gcc < 13 Older versions of gcc produce "error: unknown type name '__bf16'". PR: 276104 MFC after: 1 month (cherry picked from commit 2e226748a961329471f5b51483318b94c8735f34) --- lib/libcompiler_rt/Makefile.inc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index d9fe3d8bc8f2..2c756f4ad21f 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -228,9 +228,10 @@ SRCF+= comparesf2 # # bfloat16 support, only used on some architectures. # -.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ - ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ - !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv" +.if (${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ + ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ + !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv") && \ + !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 130000) SRCF+= truncdfbf2 SRCF+= truncsfbf2 .endif From nobody Sat Apr 20 10:32:45 2024 X-Original-To: dev-commits-src-branches@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 4VM7BQ3mpYz5HW1P; Sat, 20 Apr 2024 10:32:46 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BQ1J7hz4Q9k; Sat, 20 Apr 2024 10:32:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609166; 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=1+XmnVo4qms5G53gkhg1UHGadfxHdiAuiep67oK0jik=; b=r4+Tjzn72YRNQbusWnLKC/4AmD++4bcGqEa3oEjdyww6TFFRt7qb+jWEyeipaCfGgMZXpV NdFqsFUAfDljexvX3jJC9tyPyA5DyUENwBfdp+/XFp+uSjzayApqVv+aZbw5WJItknAim2 QrVLPvk4j/z8SEyV1Pf+r+3xd5bvTbkS2ze2hCpkBaMz5VXlGbgAASEgzapMbaSKjFw46h P4TBhEkmc4Au1VTNWDaSQBNCoVrMNwn7sK2hJ6af/NrDNnZ63Wn7QOJTfpIPBERoDTG98v q9gqpGeSxQ++V0sCWmbicfQmmmnm8vYQUKEFoRhr9KySdKFaZLcwF1ANpMh19g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609166; a=rsa-sha256; cv=none; b=YpjLJrk172+ddbsO1FMo9Jmtt/HKvWIiawZSvksn1EYph/5YqmamqC/RfMI+3mZ/Mfr3vM HoEga0H0M3kemzkLDnH9KtCbUCktuhm76yCe/6fUHPZF2A2os/BbcIJbIWbwLqdxRjZDL5 IRsgrgdb/SIqHpnowO1ARHD3uCISvzpyCezMMHvIi5cxMulXbf2BItgXiI9FfUo9TAboti gxu48rw4gw2R/Jg1DqHW00TxhVrX6cHtZrvLPjHiCQsz8A/Yk/ZKr8kWRI14k3oHix8V3p 0HSdax4C94e4j9H7UVZSGxmIBpWv+etXwsFYBiei0ZbA7XhSu5kDmymtLufSZg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609166; 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=1+XmnVo4qms5G53gkhg1UHGadfxHdiAuiep67oK0jik=; b=G6kgszjAgIZWM560MLV/1Ksn+IZu66586LdigVC19UrbROdrh0EjS+ERUdKDhlmWOSsv7r P3KbLCuIewc8g973fb6vI5tjadungtLL5Sd2mvSuhRx+XndgjvlKhHdG966bnvurvbOJrN fsbZS99JfAxM652qUpSrs1PR6y78I6XTUaS881G48ZBNoATuLfdlq6Iayt/twB+G2ZKX/D GcMWQ+nvdRTc+bUBIjRLglK/2nJwC5nxOKeJOjhDAhokDekW/d1ZmMM3ym8CMlWr86/Z3Q hqtwTtkzA3HJuxYDnteN01OiM1I61LNVaoiP0LfOt0kucm1Phrk5e13yfm0wHQ== 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 4VM7BQ01VdzYqG; Sat, 20 Apr 2024 10:32:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWjNc011831; Sat, 20 Apr 2024 10:32:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWj8H011828; Sat, 20 Apr 2024 10:32:45 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:45 GMT Message-Id: <202404201032.43KAWj8H011828@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: 89ef2b34ab73 - stable/14 - libcompiler_rt Makefile.inc: include bsd.compiler.mk to fix build List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 89ef2b34ab7333699641b7f8763633a51ee166a0 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=89ef2b34ab7333699641b7f8763633a51ee166a0 commit 89ef2b34ab7333699641b7f8763633a51ee166a0 Author: Dimitry Andric AuthorDate: 2024-04-07 19:45:51 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 libcompiler_rt Makefile.inc: include bsd.compiler.mk to fix build Apparently libgcc_s has always included libcompiler_rt's Makefile.inc without first including bsd.compiler.mk, even though Makefile.inc used COMPILER_TYPE already. It looks like we were just lucky that the expression was not malformed. PR: 276104 Reported by: Herbert J. Skuhra MFC after: 1 month (cherry picked from commit 4c983a2886877a855ac3a2836b15d80356fbb8d4) --- lib/libcompiler_rt/Makefile.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index 2c756f4ad21f..47d87b71ea77 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -1,3 +1,4 @@ +.include CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/:C/powerpc/ppc/} From nobody Sat Apr 20 10:32:47 2024 X-Original-To: dev-commits-src-branches@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 4VM7BR5jY1z5HVvF; Sat, 20 Apr 2024 10:32:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BR3lBmz4Q3Y; Sat, 20 Apr 2024 10:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609167; 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=ctTQlDj9zJMGKyO0gPyju/QDqRlMJAboqdVmpzvk5uM=; b=vIYZkNfHYdbByo8gATQ9PC48nwywxMpSJfcR9Us+kxAflGweNqKwXfqeIGG+5E+QZ9MyRX aO+DIpvT3uX6dv833LuzQ08ZfbAow8i5VLo5Mr/kDhuD6vaABCvxmmNwLc6DHWDzDQFe29 5wkc6CsaLttoMtwVc4H/+LuxDQEUlfM7fmjdbE7ENX3JMNy5Xn7nyZWPxilKLNu6yb7I7P 85POneCivVZ75RfI653S8QwRw3VQ41PW083jVxnUaT+uJ+YvDVOg+jhrO0h7yJqjF9qJSG Qne9moa7DzlBDUZI00glRAv3QPuJp1FKHSu+YmakU9mnOhwyx2fnh7TZqUdjTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609167; a=rsa-sha256; cv=none; b=YUvwqJvr8xXQC0YBqQvkCmj5jvHUppLlkFKz3wYlORWI4PAhoKtNtjBTbypluTvH4RXST6 lhX/4gkdQgLKGPgkDQBTgTbjdxAFGF1vlU4Jh3EteuFALJCguO157RPj5rTqIurACKq3sV +F+AU1JcLrKLLbBhyEwq29656C7RsbQGlJFpMA9xbdTvYQpM1ZDwaA3jrq1KPAoAl36rL0 SHxxJ+hBgqn5aM+zr4+94Lk7V+xcGa9E7ja54jMqwILTuKmx1RXZsVB6yFhQWCrf/xXZiZ r592WzOplJrodppoYWWS6CfJhdimxYzdcB6kPgGKbrGI1/0FCqcUyB0zwbllSw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609167; 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=ctTQlDj9zJMGKyO0gPyju/QDqRlMJAboqdVmpzvk5uM=; b=TXeTrHrbgF+3JYLHfqQwVxQuQL6A1eJ2f8x3gKPGLSRFoTt1RiiK5ZWdgUU231bwOS4Yfi GxsSl+VMlUOsdHjZy9BSy+vxLImTord/eqc3gRFefeOphiZ8HG1swz9iaOotZoQLHxnStZ D9f3ulooH7O61Dy8ukujt7zis2hhK0RdnYeG0ADiYVJPYJWpyrqcyJzE/NRF2u84cg3Fhv NxrWt9BF+JHLKbHGxrQo0KtYvpTB/0vEzX97bKcrb2LjNQACuetshm5i6hATt/QdaD3GJN 1Qz+TQ/P0cnKkK+T19YO3Tdk5ZsFtup7NkLuGb1dabj0ifNG6CeW4u1NqE3C9Q== 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 4VM7BR17D4zZ4v; Sat, 20 Apr 2024 10:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWlLw011894; Sat, 20 Apr 2024 10:32:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWlbC011891; Sat, 20 Apr 2024 10:32:47 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:47 GMT Message-Id: <202404201032.43KAWlbC011891@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: ca40ad0cb442 - stable/14 - libllvm: add missed tlbgen headers and sources for BPF target List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: ca40ad0cb4420c8a8a6c045f6f004ca55c96ca31 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ca40ad0cb4420c8a8a6c045f6f004ca55c96ca31 commit ca40ad0cb4420c8a8a6c045f6f004ca55c96ca31 Author: Dimitry Andric AuthorDate: 2024-04-10 22:10:07 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 libllvm: add missed tlbgen headers and sources for BPF target Noticed by: vishwin PR: 276104 MFC after: 1 month (cherry picked from commit 442d351bd242d14b1c0bb67cd048ac022f2e82ad) --- lib/clang/libllvm/Makefile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/clang/libllvm/Makefile b/lib/clang/libllvm/Makefile index 5dc864fabbcd..528551aab852 100644 --- a/lib/clang/libllvm/Makefile +++ b/lib/clang/libllvm/Makefile @@ -1393,12 +1393,17 @@ SRCS_MIN+= Target/BPF/BPFMIChecking.cpp SRCS_MIN+= Target/BPF/BPFMIPeephole.cpp SRCS_MIN+= Target/BPF/BPFMISimplifyPatchable.cpp SRCS_MIN+= Target/BPF/BPFPreserveDIType.cpp +SRCS_MIN+= Target/BPF/BPFPreserveStaticOffset.cpp SRCS_MIN+= Target/BPF/BPFRegisterInfo.cpp SRCS_MIN+= Target/BPF/BPFSelectionDAGInfo.cpp SRCS_MIN+= Target/BPF/BPFSubtarget.cpp SRCS_MIN+= Target/BPF/BPFTargetMachine.cpp SRCS_MIN+= Target/BPF/BTFDebug.cpp SRCS_MIN+= Target/BPF/Disassembler/BPFDisassembler.cpp +SRCS_MIN+= Target/BPF/GISel/BPFCallLowering.cpp +SRCS_MIN+= Target/BPF/GISel/BPFInstructionSelector.cpp +SRCS_MIN+= Target/BPF/GISel/BPFLegalizerInfo.cpp +SRCS_MIN+= Target/BPF/GISel/BPFRegisterBankInfo.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFAsmBackend.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFELFObjectWriter.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFInstPrinter.cpp @@ -2199,8 +2204,10 @@ TGHDRS+= BPFGenAsmWriter.inc TGHDRS+= BPFGenCallingConv.inc TGHDRS+= BPFGenDAGISel.inc TGHDRS+= BPFGenDisassemblerTables.inc +TGHDRS+= BPFGenGlobalISel.inc TGHDRS+= BPFGenInstrInfo.inc TGHDRS+= BPFGenMCCodeEmitter.inc +TGHDRS+= BPFGenRegisterBank.inc TGHDRS+= BPFGenRegisterInfo.inc TGHDRS+= BPFGenSubtargetInfo.inc .endif # MK_LLVM_TARGET_BPF From nobody Sat Apr 20 10:32:48 2024 X-Original-To: dev-commits-src-branches@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 4VM7BS4yMrz5HW1Q; Sat, 20 Apr 2024 10:32:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BS32yHz4QJg; Sat, 20 Apr 2024 10:32:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609168; 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=2zUg5GSXMlAAfuY/fjuNiuqg+o4sXnNrHLUY09KXtpo=; b=mnhpW06oi8burzueIBdozXxueuTu+UJlu7z/KtMbuvrzM+8I+Ncfg1CeWeqW5q6WSKjj1I MW6PYcX2mQT0tMB3wSryiPaidcMeJ0Ji/RJDjz2rnTF+6NSK8EoymgMTXX0b8fsayNPOY5 oI5bqnQNW0OSAAhX7xkkVX/MsVOI5GSGfPMBsgKuYoo8n5VLmMlakaL3mcWLmD88/Tagjt ADJINDzvSjemO/fm3h+5Qm9qqJ8YBN4Z/JrjvTw+dTSK6c4zUd4UNqTct8xbcikwOJCNMi KYbxmUnaaXrv00cpjbZNgLCo0JKuD6dox1sRNozWlOPy53pRlsRHACnNlgwymA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609168; a=rsa-sha256; cv=none; b=YR78bHsMfUPoCwTCTiMopC5TuQJ8H4VsRy4Fj6h/+tW3nPPVLtM9DlzUFipRZxJPnBQieB Os/g+u+JkVVG3RgU94Nmp1IV9ifxvZj1IOyaCcDsvWcVsD1dwlfXvZWRt7h3ISVoBkNatv hYUIQMtOBCbS8QxW6Q4zm6cMwtekhObnylYqCIEy1HOkA6Blrt/GJANIWeBif9kmN8wZZx UmDvRdizi2YZZfyLrKFCrvHZxnWZR+zQ7qcnlF+IuY5DQKK6FSv8RkFBXri8ZA5Cen2MvB dZEbiEo+tQDtkvWPVXbRu4j6wEYkJefSMuFL6oABXF+oBGGqJtQQ3h1395wJsw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609168; 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=2zUg5GSXMlAAfuY/fjuNiuqg+o4sXnNrHLUY09KXtpo=; b=KtZ5pmiKyrVCxHj6MnJGkmG1FAcQBci+v4oFF9pFi5o4FHMGmRE9Bz8DVgVB6UKPrynMps Fl8HxB2QrHl8dqQkCtQkLNTBPD+Qeih3AWNqJ73gKR0MYNI2MDvPkHtamucpW198BTqn+4 ngl5KETX1cN5Wk93h2kvteH4ltZoGPgNy4saXm7dVwMoj/blEOyaogXaeuHhkznPfj4s78 pv28xyNgoOvDCB60Zh3mXcAyieJ6Z2WAFm/SsbgJKPPQuEX/UqV0+NKw2bFdkm7KLjM59g 4Webxr3wUOyTIfs7u6cVDg621H+yIKYMmZfuc5q1t6z1xVPUYh199m4MD+iH7g== 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 4VM7BS2gTBzYmk; Sat, 20 Apr 2024 10:32:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWmS5011945; Sat, 20 Apr 2024 10:32:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWmk1011942; Sat, 20 Apr 2024 10:32:48 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:48 GMT Message-Id: <202404201032.43KAWmk1011942@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: a3549d8d4dbf - stable/14 - Merge commit 55c466da2f2f from llvm-project (by Benjamin Kramer): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: a3549d8d4dbf7f6e30bcbdc18cf6dda2bd09d39b Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a3549d8d4dbf7f6e30bcbdc18cf6dda2bd09d39b commit a3549d8d4dbf7f6e30bcbdc18cf6dda2bd09d39b Author: Dimitry Andric AuthorDate: 2024-04-11 21:12:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:25 +0000 Merge commit 55c466da2f2f from llvm-project (by Benjamin Kramer): [X86][AVX512BF16] Add a few missing insert/extract patterns These are really the same as the f16 (and i16) instructions, but we need them for any type that can occur. Merge commit 2e4e04c59043 from llvm-project (by Phoebe Wang): [X86][BF16] Do not lower to VCVTNEPS2BF16 without AVX512VL (#86395) Fixes: #86305 These should fix "fatal error: error in backend: Cannot select: t71: v32bf16 = insert_subvector t67, t64, Constant:i32<16>" when building the misc/ncnn port. PR: 278305 Reported by: yuri MFC after: 1 month (cherry picked from commit 78d3648e73d11c5a4dbcc0392907f0723bf1df1c) --- contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp | 7 +++++-- contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td | 12 ++++++++++++ 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp index 9e64726fb6ff..96bbd981ff24 100644 --- a/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp @@ -21420,7 +21420,9 @@ SDValue X86TargetLowering::LowerFP_ROUND(SDValue Op, SelectionDAG &DAG) const { } if (VT.getScalarType() == MVT::bf16) { - if (SVT.getScalarType() == MVT::f32 && isTypeLegal(VT)) + if (SVT.getScalarType() == MVT::f32 && + ((Subtarget.hasBF16() && Subtarget.hasVLX()) || + Subtarget.hasAVXNECONVERT())) return Op; return SDValue(); } @@ -21527,7 +21529,8 @@ SDValue X86TargetLowering::LowerFP_TO_BF16(SDValue Op, SDLoc DL(Op); MVT SVT = Op.getOperand(0).getSimpleValueType(); - if (SVT == MVT::f32 && (Subtarget.hasBF16() || Subtarget.hasAVXNECONVERT())) { + if (SVT == MVT::f32 && ((Subtarget.hasBF16() && Subtarget.hasVLX()) || + Subtarget.hasAVXNECONVERT())) { SDValue Res; Res = DAG.getNode(ISD::SCALAR_TO_VECTOR, DL, MVT::v4f32, Op.getOperand(0)); Res = DAG.getNode(X86ISD::CVTNEPS2BF16, DL, MVT::v8bf16, Res); diff --git a/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td b/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td index bb5e22c71427..fdca58141f0f 100644 --- a/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td +++ b/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td @@ -494,6 +494,8 @@ defm : vinsert_for_size_lowering<"VINSERTI32x4Z256", v16i8x_info, v32i8x_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; defm : vinsert_for_size_lowering<"VINSERTF32x4Z256", v8f16x_info, v16f16x_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; +defm : vinsert_for_size_lowering<"VINSERTF32x4Z256", v8bf16x_info, v16bf16x_info, + vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; // Codegen pattern with the alternative types insert VEC128 into VEC512 defm : vinsert_for_size_lowering<"VINSERTI32x4Z", v8i16x_info, v32i16_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; @@ -501,6 +503,8 @@ defm : vinsert_for_size_lowering<"VINSERTI32x4Z", v16i8x_info, v64i8_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; defm : vinsert_for_size_lowering<"VINSERTF32x4Z", v8f16x_info, v32f16_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; +defm : vinsert_for_size_lowering<"VINSERTF32x4Z", v8bf16x_info, v32bf16_info, + vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; // Codegen pattern with the alternative types insert VEC256 into VEC512 defm : vinsert_for_size_lowering<"VINSERTI64x4Z", v16i16x_info, v32i16_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; @@ -508,6 +512,8 @@ defm : vinsert_for_size_lowering<"VINSERTI64x4Z", v32i8x_info, v64i8_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; defm : vinsert_for_size_lowering<"VINSERTF64x4Z", v16f16x_info, v32f16_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; +defm : vinsert_for_size_lowering<"VINSERTF64x4Z", v16bf16x_info, v32bf16_info, + vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; multiclass vinsert_for_mask_cast; defm : vextract_for_size_lowering<"VEXTRACTF32x4Z256", v16f16x_info, v8f16x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasVLX]>; +defm : vextract_for_size_lowering<"VEXTRACTF32x4Z256", v16bf16x_info, v8bf16x_info, + vextract128_extract, EXTRACT_get_vextract128_imm, [HasVLX]>; // Codegen pattern with the alternative types extract VEC128 from VEC512 defm : vextract_for_size_lowering<"VEXTRACTI32x4Z", v32i16_info, v8i16x_info, @@ -803,6 +811,8 @@ defm : vextract_for_size_lowering<"VEXTRACTI32x4Z", v64i8_info, v16i8x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; defm : vextract_for_size_lowering<"VEXTRACTF32x4Z", v32f16_info, v8f16x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; +defm : vextract_for_size_lowering<"VEXTRACTF32x4Z", v32bf16_info, v8bf16x_info, + vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; // Codegen pattern with the alternative types extract VEC256 from VEC512 defm : vextract_for_size_lowering<"VEXTRACTI64x4Z", v32i16_info, v16i16x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; @@ -810,6 +820,8 @@ defm : vextract_for_size_lowering<"VEXTRACTI64x4Z", v64i8_info, v32i8x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; defm : vextract_for_size_lowering<"VEXTRACTF64x4Z", v32f16_info, v16f16x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; +defm : vextract_for_size_lowering<"VEXTRACTF64x4Z", v32bf16_info, v16bf16x_info, + vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; // A 128-bit extract from bits [255:128] of a 512-bit vector should use a From nobody Sat Apr 20 10:32:49 2024 X-Original-To: dev-commits-src-branches@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 4VM7BV2HHrz5HW1Z; Sat, 20 Apr 2024 10:32:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BT5dnGz4Q7h; Sat, 20 Apr 2024 10:32:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609169; 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=7QfsgEW3L9KuBGO09VtlNhxqH4qG8VfWRBU9UYLUcJ4=; b=c1ETrYI0GbzYXWFAMnMbdL/o4Hu2ORx15uVEs3vDtgwLuylA/wtCx+NAo9D49f74MmGkwx /Cnf6bzvvjAMJBTnH1E3nNcEs/x3aeUJoKPntgRAweW/6PWI0EA8+ePd5hTelMjzzVVcsG r/ARsqHzKBp+Z3ERriiEcZ47suYgrXvXEBOHaWdaFigghIqRz9FH0Uyi+twl3K56MmPziW 4xrN4TK7WgX6aBKZG0ROZPpRbuSu3XgsZUL7YFWFeHKA3qa19pLBD38B0J7xDXYj3aUR83 ek1uk+ol6Gqyl/S0wJK6dHAbqWm+pvKQ0knVdNSDAzT+wnJdpjNQIfl9jMNeeQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609169; a=rsa-sha256; cv=none; b=SdaSeBDKD7tG3BFhzy4F4F47qOnzpZPp/LCZl+auxJE27BBkqpXbF5RD3egmiTIMhGaP/J E1jcMwnKoR8TaHx9ewh2akG0C3MP1EEkuwntijk272heNdV44pdtMUBpWvnybgjFoqSF2I jgOWiKJLajTjIlfdJQF37NmGo2ZXRfWhe0aDuFvkUdeSLSsNUGls5PFSXu+Z9r+jUZXm1x QEoSZExt1TnznoNlS0dR0KfR7dORDcLZPYLqFsdBCeTCYe5yKu9zZtzIvQ7s9/IqWOykgA +f928Kgad03CVWCDnUw8jssoafZjlJHaxGtWOVgXETYJNFM+UkaQNFgYg7295g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609169; 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=7QfsgEW3L9KuBGO09VtlNhxqH4qG8VfWRBU9UYLUcJ4=; b=BZcZyIUoqavRuQQXF3Sv4gYJj25x2p6aUyVSC067U61RzI4c7rjSKNgcKTOJcpx/TKZ3mL zxnWARKPaS/LDtjHW9MkJfhlUuglNTJlBOMuBaMhClIFiN3V2kby/GmKPnm7bkSDWalX3c i+ZjpAxhiODRm/gZgXvQGHerRAq5+C1oVUUW5+ZUnqAMsb9oy8Bun8Fr7rDbYDyPedHKmX pNgKTx0D0FxputFM1KJYIRpDmS6u8A3k+0N+ICta0TmbpcOC81i2qQp7klkd1i2r2Xd7x4 HeRFgubQ9pBsxEuqf6QtH8w0N+kMaUb9uRQRjfxgtzYcDJ49e08YCNtn7F5OOw== 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 4VM7BT3j0pzZC2; Sat, 20 Apr 2024 10:32:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWnu1011996; Sat, 20 Apr 2024 10:32:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWnjR011993; Sat, 20 Apr 2024 10:32:49 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:49 GMT Message-Id: <202404201032.43KAWnjR011993@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: fcfb38a25f07 - stable/14 - Revert commit 925a11a5f221 from llvm-project (by Nikolas Klauser): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: fcfb38a25f074c3677e9c672a6c4550b3430bd04 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=fcfb38a25f074c3677e9c672a6c4550b3430bd04 commit fcfb38a25f074c3677e9c672a6c4550b3430bd04 Author: Dimitry Andric AuthorDate: 2024-04-13 08:44:26 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:26 +0000 Revert commit 925a11a5f221 from llvm-project (by Nikolas Klauser): [libc++] Simplify is_convertible GCC 13 has added __is_convertible(), so we don't need to keep the fallback implementation around. Reviewed By: #libc, Mordante Spies: Mordante, libcxx-commits Differential Revision: https://reviews.llvm.org/D157939 This should allow buildworld with gcc 12 to work again. PR: 276104 MFC after: 1 month (cherry picked from commit 2365f012951e5f0333cf31c690f668299c86b30e) --- .../libcxx/include/__type_traits/is_convertible.h | 79 +++++++++++++++++++++- 1 file changed, 78 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h b/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h index bc91d8b23430..b378a20cedeb 100644 --- a/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h +++ b/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h @@ -24,12 +24,89 @@ _LIBCPP_BEGIN_NAMESPACE_STD +#if __has_builtin(__is_convertible) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + template struct _LIBCPP_TEMPLATE_VIS is_convertible : public integral_constant {}; +#elif __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + +template +struct _LIBCPP_TEMPLATE_VIS is_convertible : public integral_constant {}; + +// TODO: Remove this fallback when GCC < 13 support is no longer required. +// GCC 13 has the __is_convertible built-in. +#else // __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + +namespace __is_convertible_imp { +template +void __test_convert(_Tp); + +template +struct __is_convertible_test : public false_type {}; + +template +struct __is_convertible_test<_From, _To, decltype(__is_convertible_imp::__test_convert<_To>(std::declval<_From>()))> + : public true_type {}; + +// clang-format off +template ::value, + bool _IsFunction = is_function<_Tp>::value, + bool _IsVoid = is_void<_Tp>::value> + struct __is_array_function_or_void { enum { value = 0 }; }; +template struct __is_array_function_or_void<_Tp, true, false, false> { enum { value = 1 }; }; +template struct __is_array_function_or_void<_Tp, false, true, false> { enum { value = 2 }; }; +template struct __is_array_function_or_void<_Tp, false, false, true> { enum { value = 3 }; }; +// clang-format on +} // namespace __is_convertible_imp + +template >::value> +struct __is_convertible_check { + static const size_t __v = 0; +}; + +template +struct __is_convertible_check<_Tp, 0> { + static const size_t __v = sizeof(_Tp); +}; + +template ::value, + unsigned _T2_is_array_function_or_void = __is_convertible_imp::__is_array_function_or_void<_T2>::value> +struct __is_convertible + : public integral_constant::value >{}; + +// clang-format off +template struct __is_convertible<_T1, _T2, 0, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 1> : public false_type{}; + +template struct __is_convertible<_T1, _T2, 0, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 2> : public false_type{}; + +template struct __is_convertible<_T1, _T2, 0, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 3> : public true_type{}; +// clang-format on + +template +struct _LIBCPP_TEMPLATE_VIS is_convertible : public __is_convertible<_T1, _T2> { + static const size_t __complete_check1 = __is_convertible_check<_T1>::__v; + static const size_t __complete_check2 = __is_convertible_check<_T2>::__v; +}; + +#endif // __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + #if _LIBCPP_STD_VER >= 17 template -inline constexpr bool is_convertible_v = __is_convertible(_From, _To); +inline constexpr bool is_convertible_v = is_convertible<_From, _To>::value; #endif _LIBCPP_END_NAMESPACE_STD From nobody Sat Apr 20 10:32:50 2024 X-Original-To: dev-commits-src-branches@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 4VM7BW0tXGz5HW5f; Sat, 20 Apr 2024 10:32:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BV69vcz4QK3; Sat, 20 Apr 2024 10:32:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609170; 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=Bx64wnSkWwcfFC7v+TO6ghl19jqWg7B2DC8ygvxEb/M=; b=AURd4PGjNHuFTelp+e4Er/u10/1TLbVZyZasNCl/xTGKmBTFROHAz/sfLu9O/S7IjEBN22 OhH2Q3WHUCvHGFOv8QBz62w5WoKzeKZx0rF4T6AbxlJ8xze0sn6xIqMY+BYpHzrsiK6iID YETqMPUi1fM9kkdvuoFLmdeH7gtpaWviQ5SXth3o3SD3Ddob1ldZXuRkg2SC/wfUD32p/r SpU4CpyN1qGkhYNsDHLda2+cUCictFqf730559thiyzs9DFeS9+nQn4rsliVH3xQ6azuT8 CYMpdIOzs8agh+Sxqd/SKSemNnZfjTjqqeqtQc5NpWIag1dGcGSTQtbLszX+lg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609170; a=rsa-sha256; cv=none; b=sqqYzg80NmaaI2QWHcNC4ukCNIpVGw6EhePP9TSVCMthpeNnTeVwGHVovDvq4LyG0jDidM VQwlFQPobKRPp279VPsIGbxfPky1xPOCLPaWa0LURW3/VFJM7Oo9aW5FKAYFJR7cHKsKo1 8cjVQT8EHxJwFXIpTgrj/oeL/Ui7e1suFBhKIErqYD9OOdslZQVvQXe8CADHJdriVrnbdb Yr5ZDC0Nrg+mt5OtOfU1GT9QsS6M6+P6rElR5Orad9yPfxWPJlTzUxy9M1zdNzO2k7xjlj QsG18XUbwWhs8JedWfIQ+Sn0nx9B2thkBZcsShCycU0RViqutS/UMWDTyaUNhA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609170; 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=Bx64wnSkWwcfFC7v+TO6ghl19jqWg7B2DC8ygvxEb/M=; b=X5JRKna7Onoe3qo9rVt1gFMfkIcMFnUwgAFQe4YyKxW4BZySXOPMPaM9ksqeBhG+0njImd VgOL9ljmNhNfcW0PfjB8SaCgSvck9AbpL2FsJm06uX/Sv8xaux0nDngO9TVj/BZT5FG2wa leqTcsnPtZOGNJpfq3IsDRoW9bMTXqni6k5mAhGXR28p0EOHdFqqXXs2Sv4cFkY1bqrz5T UZ3ZKlb4LDNmBujizo8cvHPPde1jReZOJOxe0fLok6nia2PLdh4bh4YhDdmGnAccU0ayWa m4C4pkWUOOWQI6hRjBg49WgxA9TmJeF6uHA5ho39xkYRRM3A+Hp9edb+BMp6fg== 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 4VM7BV4S8CzYkJ; Sat, 20 Apr 2024 10:32:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWo2f012058; Sat, 20 Apr 2024 10:32:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWoFL012055; Sat, 20 Apr 2024 10:32:50 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:50 GMT Message-Id: <202404201032.43KAWoFL012055@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: 18590ac4f035 - stable/14 - sanitizers: mark __elf_aux_vector as weak, to allow linking without libsys List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 18590ac4f0355175003baefa711fcb47f041f24e Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=18590ac4f0355175003baefa711fcb47f041f24e commit 18590ac4f0355175003baefa711fcb47f041f24e Author: Dimitry Andric AuthorDate: 2024-04-14 17:38:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:26 +0000 sanitizers: mark __elf_aux_vector as weak, to allow linking without libsys After libsys was introduced, linking sanitized programs started failing with: # c++ -fsanitize=address main.cc ld: error: undefined symbol: __elf_aux_vector >>> referenced by sanitizer_linux_libcdep.cpp:950 (/usr/src/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp:950) >>> sanitizer_linux_libcdep.o:(__sanitizer::ReExec()) in archive /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a c++: error: linker command failed with exit code 1 (use -v to see invocation) Mark __elf_aux_vector as weak in the internal sanitizer declaration, so the linker will accept it at link time. The dynamic linker will then take care of the symbol at run time. Suggestion by: brooks PR: 276104, 277393 MFC after: 1 month (cherry picked from commit 8b181c2fbaa8c6b32e5510ef6e3a6d364ff4710e) --- .../compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp b/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp index cccbb4d256df..962fff53e447 100644 --- a/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp +++ b/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp @@ -53,7 +53,7 @@ // that, it was never implemented. So just define it to zero. # undef MAP_NORESERVE # define MAP_NORESERVE 0 -extern const Elf_Auxinfo *__elf_aux_vector; +extern const Elf_Auxinfo *__elf_aux_vector __attribute__ ((weak)); # endif # if SANITIZER_NETBSD From nobody Sat Apr 20 10:32:51 2024 X-Original-To: dev-commits-src-branches@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 4VM7BX370vz5HW5k; Sat, 20 Apr 2024 10:32:52 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BX08fKz4QH1; Sat, 20 Apr 2024 10:32:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609172; 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=OSTCjpgz9FWFRGGcLTRZuKawuI48tSkGIt69b4G5/zU=; b=uig4VvsNfyOiauYTGSaYGsOwcZzLJA2PhkP5nmzA2ikyhkPvTr/N2b4kqZFuqg7QTvcjvq NWLGQbj6ilh+SzQb0M+/WLd2yGs24GsBZS2rADuH0UXyBtcVp9gBXUsSqamU+yXzX9Obtb mjNx7LI8a2LlKkiJwLJDrfLyIbYx+6DavUOAnLpt2JxBkY5d5YS85VjmvYi1rkzgvGThXt qWeETog1ETtAE2NoBFIwMPR1LbvkjoatpVlHdefA6hMCrecyPNgr/BqOxWRdMvQutbFQxL n/lPrsOmPoZBfZVA/ZDyEcDW7R0aDcZRTD9Cmn5NtGA5P9qIThKEMsZTiO7vhA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609172; a=rsa-sha256; cv=none; b=olX/0AqU6lC2vMhnl2gwmYbMHuhPKsMLDmacE+y6jLJ5p8yWGExnM+fC2kZMtMZJyuMgI3 3yNoY6g1UVdt29O37Y+jgoGfdXsRyiIOY5OFCUjMGyhreTYpCOLkkuyU/Gy6Yls6sRN/pY hkGdVrnIpbPDc1Bn0umE9arT4JL34OBI7lnEeFPnlYVlmr6FvSsk5rhrvHr0S6kSgvrET6 /+jq2y6xDfRQapEuplCGOZwuZFA/VDl/9siEvx0Qt9cQ/baKq2YhM3OtHZfG+FuAh7Laqb TbsRZzCp3qcGSMd02Ua1KzhA7kyPSZBEEyxuKUx3bkpa4Rc1WrA1yG9MccYMbQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609172; 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=OSTCjpgz9FWFRGGcLTRZuKawuI48tSkGIt69b4G5/zU=; b=s55Y9GsydvVe6nlfjRBVJHN/flxfDd0FxU4ulpRsp3FjAz+jsrKAkp6c1enUWUh8KIjKrn 59tMVgKF/zyb4FgzoKcbgcm3jo2414dreT1ia8TqOmThGVCdjCWXsKQJvTKEknDG3bTaMq GeP+dDgfcXWi28MXAsxINJy1ey7o7h5BQTX7d4c8BiugnKaaSEh/y+qr/U0vnxrPHHSC3H CnIn78sGfSUVhKAjF0VxApwUbuX8lDhlyuzz0dMRbvbWod7YP8M2blbdMtEZ4/D046hJTX AMdLpKrjNI5EL6y/8E7mNAAyUfigzEYRkmfv8/SoYDxSd1OJNM7WgEQm/cbzAQ== 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 4VM7BW5XNczZ9p; Sat, 20 Apr 2024 10:32:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWpqk012107; Sat, 20 Apr 2024 10:32:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWpSM012103; Sat, 20 Apr 2024 10:32:51 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:51 GMT Message-Id: <202404201032.43KAWpSM012103@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: 40d5cf3f394d - stable/14 - Merge commit 37b7207651b4 from llvm-project (by zhongyunde@huawei.com): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 40d5cf3f394d72b9c6a9ce69cebd95d168b1fa72 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=40d5cf3f394d72b9c6a9ce69cebd95d168b1fa72 commit 40d5cf3f394d72b9c6a9ce69cebd95d168b1fa72 Author: Dimitry Andric AuthorDate: 2024-04-15 16:24:39 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:26 +0000 Merge commit 37b7207651b4 from llvm-project (by zhongyunde@huawei.com): [SimplifyCFG] Fix crash when there is unreachable large index (#88616) The large case index out of scope is dead code, but it is still be created for TableContents in SwitchLookupTable::SwitchLookupTable, so make sure the table size after growing should not get smaller. Fix https://github.com/llvm/llvm-project/issues/88607 This should fix "Assertion failed: (idx < size()), function operator[]" when building the science/dynare port. PR: 276104, 278320 Reported by: yuri MFC after: 1 month (cherry picked from commit 514c98ba14a0f590891844d1a6bec0ac4de54489) --- contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp index 13eae549b2ce..f95dae1842fe 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp @@ -6710,9 +6710,11 @@ static bool SwitchToLookupTable(SwitchInst *SI, IRBuilder<> &Builder, return SwitchLookupTable::WouldFitInRegister( DL, UpperBound, KV.second /* ResultType */); })) { + // There may be some case index larger than the UpperBound (unreachable + // case), so make sure the table size does not get smaller. + TableSize = std::max(UpperBound, TableSize); // The default branch is unreachable after we enlarge the lookup table. // Adjust DefaultIsReachable to reuse code path. - TableSize = UpperBound; DefaultIsReachable = false; } } From nobody Sat Apr 20 10:32:52 2024 X-Original-To: dev-commits-src-branches@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 4VM7BY39Wgz5HW5m; Sat, 20 Apr 2024 10:32:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BY0V03z4Q8B; Sat, 20 Apr 2024 10:32:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609173; 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=U4y/rX5mmLkLSc0SwrhBN0WcOV0vgIicAuRFKEG0haY=; b=d/FGLFYeQv+m1rr+531TU8MEIQJkzd+18USR1zcipfqSV5Yip1E0aGxgSb5+7GkG0T/45/ MV664q8OCJeeXLUu2fdUYUzJ7vwE6e2RbPISvLX0qApHfb6pmFeiT9OJZz0Wap5AHPuiUh 0xvyms7KbfmHaujcXVetD6xFPvd479Pky8HDbFZzxYSKEOhoO8avtlOU3jzHpQzQYRO/ht IqsRvq+R0AEcmWrEWR8urQU9vHFE84CO1zI7QgIAREinNg5puTgavlZJ79+Gfxe8JsRhnE xe1fRMsvOUoYt5wrqrQdzM3yI3ROjTHvXyx6Letd9mYR+/g3SzewC+4+UQ9nbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609173; a=rsa-sha256; cv=none; b=WbPZYw3Ij+18NP5LwMKl954GYsOZUdWFgSDhahku29dGg3t508opKoGtzIjOHai2G/lKg+ 8pfTJkmuyYeycjiv2V/Cdsc3zjFlw15vINa95HJZE2WXaOO170C8muemaX0fkeS38n5ie5 Vn/UCKLI158GZcL1KBsD+oaNY1rglU/u6tZH5k9Djxz5WRHhh79DPaxIHYqpT3wTKJC291 qdLIqJTApICsss1wW68rIuhHkUmaqV1Guo3xFZ8RdgOJFoZt75YXk0KigB+E8yzViNYOUE ZRxPfrfmSY3ZcYB6wXn63rtWOGbXlwm6g+gkD+Tg9xBRRyofIZ7vnZECaciHOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609173; 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=U4y/rX5mmLkLSc0SwrhBN0WcOV0vgIicAuRFKEG0haY=; b=N5shgQC1r6K1/k9K8Fl/6twtZeQ26zoXhPlIGygoGUN9T0lrDhlQOSNDIgvRZVIAHy/a2l 4rE+lNuO2J4OgYFSMJbtnW2EY/CRC1cfeKLMXF522YDL4NSF1+du91ucMEVR+Rkm2CiR1v GRZRlMJn2xFhMzSEA1v4SaHfGtMIj00++UrdTbGIVPOk4VieRXQj+PcO+kJ1kYv9dfDm1X AVRswBUdiKUC6bH1HGv/PXykGnoBvTDNeQJQIrcGzYlI0XWqTuA09d0y12rseCAmEsi5dz YuInO+T/uST+A6JJcmTXPUcGGmkuDchVFuu3b2N4k3kj67RUx6xpuTyNAthVbw== 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 4VM7BX6VbZzYhN; Sat, 20 Apr 2024 10:32:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWq7h012154; Sat, 20 Apr 2024 10:32:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWq2S012151; Sat, 20 Apr 2024 10:32:52 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:52 GMT Message-Id: <202404201032.43KAWq2S012151@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: 47020df00dd8 - stable/14 - libcompiler_rt Makefile.inc: update _Float16/__bf16 checks List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 47020df00dd821a8102cfd7358408de0ed9b6f39 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=47020df00dd821a8102cfd7358408de0ed9b6f39 commit 47020df00dd821a8102cfd7358408de0ed9b6f39 Author: Dimitry Andric AuthorDate: 2024-04-17 20:20:47 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:03:26 +0000 libcompiler_rt Makefile.inc: update _Float16/__bf16 checks Clang supports __bf16 for riscv from version 18.0 onwards, so update the checks for it. While here, rewrite the checks so they are hopefully more readable, and also handle gcc a little better. In addition, define COMPILER_RT_HAS_FLOAT16 and COMPILER_RT_HAS_BFLOAT16 when these features should be available, since there are some parts in compiler-rt that check for these defines. PR: 276104 MFC after: 1 month (cherry picked from commit f276adc148433d009d198c2ebccdd3303377e237) --- lib/libcompiler_rt/Makefile.inc | 33 ++++++++++++++++++++++++++++----- 1 file changed, 28 insertions(+), 5 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index 47d87b71ea77..9aea0f2b051a 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -226,13 +226,36 @@ SRCF+= comparedf2 SRCF+= comparesf2 .endif +# Helper to reduce complexity of _Float16 and __bf16 statements below. +.if ${MACHINE_CPUARCH} == "aarch64" || \ + ${MACHINE_CPUARCH} == "amd64" || \ + ${MACHINE_CPUARCH} == "arm" || \ + (${MACHINE_CPUARCH} == "i386" && !empty(MACHINE_CPU:Msse2)) +CRT_COMMON_F16_ARCH=t +.endif + +# +# _Float16 support, only on some architectures, and with certain compiler +# versions. +# +.if ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 150000) && \ + (defined(CRT_COMMON_F16_ARCH) || ${MACHINE_CPUARCH} == "riscv")) || \ + ((${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} >= 120000) && \ + (defined(CRT_COMMON_F16_ARCH))) +CFLAGS+= -DCOMPILER_RT_HAS_FLOAT16 +.endif + # -# bfloat16 support, only used on some architectures. +# __bf16 support, only on some architectures, and with certain compiler +# versions. # -.if (${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ - ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ - !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv") && \ - !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 130000) +.if ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 150000) && \ + (defined(CRT_COMMON_F16_ARCH))) || \ + ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 180000) && \ + ${MACHINE_CPUARCH} == "riscv") || \ + ((${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} >= 130000) && \ + (defined(CRT_COMMON_F16_ARCH))) +CFLAGS+= -DCOMPILER_RT_HAS_BFLOAT16 SRCF+= truncdfbf2 SRCF+= truncsfbf2 .endif From nobody Sat Apr 20 10:32:55 2024 X-Original-To: dev-commits-src-branches@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 4VM7Bb3gqhz5HWQ6; Sat, 20 Apr 2024 10:32:55 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Bb1vpvz4Q6Q; Sat, 20 Apr 2024 10:32:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609175; 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=U40F4t+F5iYhqLNyKQ9gClVjKYZcIgiOiPmaxnoRD/E=; b=yYjAwX+VkiV9ywyjJL6udaw4EzkL0pZLbm7dA9dl4GxfstFtCV4uv39xo/n5VK26Y6W5mB A4fDye2VXnI5KEGY8hArmxBGLhfq+XvSAcbRu/d4y10vqTARtKynvU3IaYxycBlbA5XiQS SlwBwhuHZXsFPIturEdJtmL/R0el2ciXQ87HtB4AbKTLQJ7GXa5F+jSp0mYHDgkoqDvdGy mlmZY9bDgQ7aCHdcLObvfL+gA65DMI0R9QWFIgn5rXLlI03yqvfCmaP94hfR6ZNp+ixCsm tVZgS4frG/WK+7z0tXGbXZfG4lb0drUqpTqZSDkB+OuELR4GmzKQy9lhzYxHIg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609175; a=rsa-sha256; cv=none; b=rTNOan+dazAdv49iRQWl7f6lX/OxGRt/xplv7ZqV7eq+ObpiUdJdG2OEFngLAwKaqlDpmP E0sL78wEEqJFVHVowx97L4ltBW3JTUfc+mPgfmq0Jn9rsS8T32t89JYFicT8XPITcRPJE8 cL+6CMCsz6DLxelCFUE/dFmmnQ5alZZ0gkFcWBptfnnU6kNoGS07R9lqq5zYYf2cMuHc54 jzdBjj0LXVJ7JqGtDgpV2M1dtUy9IfUyAQv5T66qCumz23/uhs8W+1Xb/NpU59aaksHfIa ci8GMNuyfIQVIxvlytM0/4t3JZqk7R4aUgRoE4r9czaCNybpY/SG0a32udSJ2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609175; 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=U40F4t+F5iYhqLNyKQ9gClVjKYZcIgiOiPmaxnoRD/E=; b=VeoojpZe3jgv19ua/DFTnvbN6ImG4rwGzhmVeXCPq2fn5nFB7wOtrHpxdd1IZdCc9Eu73s kl8HBYB0CBg+hGf38waASGzPnP5r5hq24TLsDi6pUQO9fdUfr2yiCIutHqAc5xsEAehT8u vkrbM6xZfKb3mxMU+++0EwKS5tpYnp2pVrRoHD1r4nWz3vfkVBY1O07XwnJ/ZQ4LE0/rWr ritjbuZqFm+HSbEsCbQWvei4I5PUnVRqh/uEitlcII35DlnvbnSc2fFzL0JMfLdKJ6vX/j o5PElCT9Du6SxDWX4LD6UTbzr/XEbWmHY7RrVt01G9lEkC6sJcwG2T6eblxugA== 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 4VM7Bb1BSRzZC3; Sat, 20 Apr 2024 10:32:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWtIq012244; Sat, 20 Apr 2024 10:32:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWtRQ012241; Sat, 20 Apr 2024 10:32:55 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:55 GMT Message-Id: <202404201032.43KAWtRQ012241@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: 7c41358a2b0a - stable/14 - Bump __FreeBSD_version for llvm 18.1.3 merge List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 7c41358a2b0a2e70a2b61ec347354f3452e4d2f3 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7c41358a2b0a2e70a2b61ec347354f3452e4d2f3 commit 7c41358a2b0a2e70a2b61ec347354f3452e4d2f3 Author: Dimitry Andric AuthorDate: 2024-04-06 20:15:21 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:04:35 +0000 Bump __FreeBSD_version for llvm 18.1.3 merge PR: 276104 MFC after: 1 month (cherry picked from commit 0192eda105b367d4670205547e8e830e3716bea3) --- sys/sys/param.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/param.h b/sys/sys/param.h index b1ee17301504..46f0cf211cff 100644 --- a/sys/sys/param.h +++ b/sys/sys/param.h @@ -75,7 +75,7 @@ * cannot include sys/param.h and should only be updated here. */ #undef __FreeBSD_version -#define __FreeBSD_version 1400510 +#define __FreeBSD_version 1400511 /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From nobody Sat Apr 20 10:32:53 2024 X-Original-To: dev-commits-src-branches@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 4VM7BZ6Xk5z5HWMk; Sat, 20 Apr 2024 10:32:54 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7BZ103Rz4Q6G; Sat, 20 Apr 2024 10:32:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609174; 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=H98qYtYorjA5PrAkQbjxe9ix+BjhaD7zWtBfEnMFIa8=; b=X3Mb/Q8b8hDfAim8Y9jRO+2xlDkfC9ricBesD7h0wTFgOBWiYzBAsJ1QlDmiyClr5SpuPp +p1UmkG2XADQngYfx/s6ar8KZk2oLlEqb5n2H9yT/FRTZ9CYZRzbcnlyRJThaopP9nqRyK t7dd605AbFjUrSpPVEN/6QkVkJgLeEkAuO1mdXj7XrSk5sumfxhI3OeWV+PD9+1N3nucaO gzWzsGWs5fJZqqaBHWMMG9zKbcU/NY2tJoOP492MgEAZN49A0uDNQCqtD8yTGDOCYG0j3C aaK8MIBFjyXco5ZNDjNUzbnbUNEZnI3wBo85HNIWNKPr7r417xHgUPb4QkKxFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609174; a=rsa-sha256; cv=none; b=HORk3yIKjej1FNAaW4guT9yYKvbzWI+LmH8edkKoW/4vm9259esT3esCIIyX4Ed8KjmFKQ /huyj/vvBw4aEQL+hRCA2fKJqb5uhTdmjXV7D+2yuUFt7o+VbWLu039XY685kZpJw5gqNm VzSVgRavxB2NoYEjySqliOc5EEb1XCPb+cXZACi1m4T8DbJXDEhH4J/n4ZlqvpGJeExNt8 y3ao7akHpWlWHTDXGW/FkoqInjRm4ifqqj0TBN++QGAx+MKZAmZN01sa3C8MNK2LKVJHrK 1Z2OxJBAWP+8rrC/26qs7MCaHBduTq1gTsvT8kKINFXwc+JnM7Sz1YGo8rWsBw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609174; 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=H98qYtYorjA5PrAkQbjxe9ix+BjhaD7zWtBfEnMFIa8=; b=jqigvGsXg6LGaKzSSUNr6XnQf5uShoUkKWmKu6Jj7gS+bl3mZL2l3SdVUryTH4CSACkXCm Clk3mTf4pydHNDe3j9y32zYDl5LxVtlfWt48HdxKTVzsEHvfFSyjZ1LIhBC2KjNSJp6jDY mXMXIb46I4E8zDzsfhthw3njFltaxAmtPp4n7gxp5BSguA3DnmZQpwtgSfexIdTpBMR+5N cI2FxBXSdWaqMfw+crro1V6N81/iSvLbp4vOO/CFWSR1tPw08MEqJsBVajQnJ1Dn3Alr+T a6mLK+By356hgTC6I2nMGBbZZBdWuq2RSb8NVnVqgaSErIHqnwJuT+Cy5G2zDQ== 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 4VM7BZ0YyNzYqH; Sat, 20 Apr 2024 10:32:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAWru0012199; Sat, 20 Apr 2024 10:32:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAWrFH012196; Sat, 20 Apr 2024 10:32:53 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:32:53 GMT Message-Id: <202404201032.43KAWrFH012196@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: a4f6bfe30406 - stable/14 - libgcc_{eh,s}: restore __*_frame_info symbols post llvm18 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: a4f6bfe30406d2ec0050807c73a836d027ed4be5 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a4f6bfe30406d2ec0050807c73a836d027ed4be5 commit a4f6bfe30406d2ec0050807c73a836d027ed4be5 Author: Brooks Davis AuthorDate: 2024-04-19 21:45:05 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:04:35 +0000 libgcc_{eh,s}: restore __*_frame_info symbols post llvm18 The upstream llvm commit 5eb44df1b64d made the addition of these GCC compatability symbols dependent on build configuration rather than hardcoded for amd64, i386, and powerpc. Reenable them. Reviewed by: dim Differential Revision: https://reviews.freebsd.org/D44877 (cherry picked from commit 0b9e3585805e83718c3ebdab923aca51597193cd) --- lib/libgcc_eh/Makefile.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/libgcc_eh/Makefile.inc b/lib/libgcc_eh/Makefile.inc index 9e194cc875f1..75e7d743a720 100644 --- a/lib/libgcc_eh/Makefile.inc +++ b/lib/libgcc_eh/Makefile.inc @@ -17,6 +17,9 @@ SRCS_EXC+= UnwindRegistersSave.S SRCS_EXC+= libunwind.cpp SRCS+= ${SRCS_EXC} +.if ${MACHINE} == "amd64" || ${MACHINE} == "i386" || ${MACHINE} == "powerpc" +CFLAGS.UnwindLevel1-gcc-ext.c+= -D_LIBUNWIND_SUPPORT_FRAME_APIS +.endif .for file in ${SRCS_EXC:M*.c} CFLAGS.${file}+= -fno-exceptions -funwind-tables .if ${MK_ASAN} != "no" From nobody Sat Apr 20 10:34:00 2024 X-Original-To: dev-commits-src-branches@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 4VM7D42q6zz5HWSx; Sat, 20 Apr 2024 10:34:12 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7D40C39z4S4L; Sat, 20 Apr 2024 10:34:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609252; 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=yXco8I67zmvibhjLT1+JW0DkAcV/2S/z4Fu2oHFU8Tw=; b=DvhaLnA+xd1dczhTN4EcEuO8yx+bpESv1AGMJ7dsQ+zGTX64/SgH9hDb58bI4P2SNNQ2C+ GJxWturuOBf17JCTlADaRlAcAeE3AMhpDzfPyw0O1V0+l3wpUNCdP9TjTQ89EF4H1n6JQ2 cv3MkM4GGe0j9H+SHtMOEYtlyUMGJIB2AGhFFdfGsxi4jr21HHm8tGJ3O1bR52XifY3s4y RPI4OxLILFMbO55S6+tqla4Y2JWxFSOWlwPHVzplghGkNQwza96/dezruh5L6smR9f81G0 63DvCn4MAZ5LUlt/mtBVkYKH/pWyrPrN4bUPzY27HRexUh6zqHiSKtsktJCkfA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609252; a=rsa-sha256; cv=none; b=kAemxS+OQfcTNPbIRzz2S14kK8GsVSORue7pOWvjNf3bbT+3oc4yd+O/wj04gUJiz6cUzL Lerfr9/RtWt33A0U5ARfJUO/I9KTHy7EGXLtNUwdy0IAnZn9jOiTvs6tYtLwBBgK7IvN6V bZ3sh1gEH7NWUjt0kZmDJDNBJrjRCVc/yKyRTCE33LG1GRBJInOQWljRwvhUE0VM87ojjV ucyb2xUsT/LpHbc7RfieMbecoHCqkQEWivfO3nIn1M+OPWjwbcBt3seT//oJtLCCJjs/L8 6iYvXTeU6KDABEyFBAjwsTzHPIGz4LhjWnbzkJx1TLB6okd5mmaZ1HDpjw96Zw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609252; 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=yXco8I67zmvibhjLT1+JW0DkAcV/2S/z4Fu2oHFU8Tw=; b=fo6LoXVUcW0q7Rc5Zha7aJfr2GhEULY5wsNE2kg9P3lo057hU7kaigOnP3cOFWsfer7F+d 0sZ0IG+3iDoO6buEjw/uVXUuWCBnSBFglTPdW90ZDW13dCiZh+dyuqigkIO1OplDGXiUVh 4d0nKYfHWWSyKv8VjVcXlxwsVqObmeNUKnQbE9PU5N2V0hu+KYjuK3rMLUBKJjxSnaTzOs bTjYpJdOEfOacCG7mNV8Gprfux7CTr1Gcc9Yob1skWMDLqrTmORLBNWBVVdv7dpw6ik/NI FXY6himtDKMJUiqv5E8qSAkuje/wtC2ViO4/SqPBerk3ZWGmZFMkcGf10HM/ZQ== 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 4VM7D36LdxzYkb; Sat, 20 Apr 2024 10:34:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYBAv013193; Sat, 20 Apr 2024 10:34:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAY0wh013169; Sat, 20 Apr 2024 10:34:00 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:00 GMT Message-Id: <202404201034.43KAY0wh013169@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: bdbe302c3396 - stable/13 - Merge llvm-project main llvmorg-18-init-15088-gd14ee76181fb List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: bdbe302c3396ceb4dd89d1214485439598f05368 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=bdbe302c3396ceb4dd89d1214485439598f05368 commit bdbe302c3396ceb4dd89d1214485439598f05368 Author: Dimitry Andric AuthorDate: 2023-12-18 20:30:12 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:23:40 +0000 Merge llvm-project main llvmorg-18-init-15088-gd14ee76181fb This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-15088-gd14ee76181fb. PR: 276104 MFC after: 1 month (cherry picked from commit 5f757f3ff9144b609b3c433dfd370cc6bdc191ad) --- ObsoleteFiles.inc | 441 + contrib/llvm-project/FREEBSD-Xlist | 32 +- .../clang/include/clang-c/BuildSystem.h | 6 +- contrib/llvm-project/clang/include/clang-c/Index.h | 7 +- .../clang/include/clang/APINotes/APINotesManager.h | 175 + .../clang/include/clang/APINotes/APINotesOptions.h | 34 + .../clang/include/clang/APINotes/APINotesReader.h | 200 + .../clang/include/clang/APINotes/APINotesWriter.h | 110 + .../include/clang/APINotes/APINotesYAMLCompiler.h | 11 + .../clang/include/clang/APINotes/Types.h | 59 +- .../clang/include/clang/ARCMigrate/ARCMT.h | 2 +- .../clang/include/clang/ARCMigrate/FileRemapper.h | 16 +- .../llvm-project/clang/include/clang/AST/APValue.h | 8 + .../clang/include/clang/AST/ASTConcept.h | 116 +- .../clang/include/clang/AST/ASTContext.h | 69 +- .../llvm-project/clang/include/clang/AST/ASTFwd.h | 1 + .../clang/include/clang/AST/ASTLambda.h | 15 + .../clang/include/clang/AST/ASTNodeTraverser.h | 20 +- .../include/clang/AST/ASTStructuralEquivalence.h | 12 +- .../clang/include/clang/AST/ASTTypeTraits.h | 6 + .../llvm-project/clang/include/clang/AST/Attr.h | 11 +- .../clang/include/clang/AST/CXXInheritance.h | 2 +- .../llvm-project/clang/include/clang/AST/Comment.h | 286 +- .../clang/include/clang/AST/CommentSema.h | 3 +- .../clang/include/clang/AST/CommentVisitor.h | 5 +- .../llvm-project/clang/include/clang/AST/Decl.h | 218 +- .../clang/include/clang/AST/DeclBase.h | 188 +- .../llvm-project/clang/include/clang/AST/DeclCXX.h | 76 +- .../clang/include/clang/AST/DeclFriend.h | 1 + .../clang/include/clang/AST/DeclObjC.h | 49 +- .../clang/include/clang/AST/DeclOpenMP.h | 22 +- .../clang/include/clang/AST/DeclTemplate.h | 166 +- .../clang/include/clang/AST/DeclarationName.h | 3 +- .../clang/include/clang/AST/DependentDiagnostic.h | 2 + .../llvm-project/clang/include/clang/AST/Expr.h | 261 +- .../llvm-project/clang/include/clang/AST/ExprCXX.h | 111 +- .../clang/include/clang/AST/ExprConcepts.h | 91 +- .../clang/include/clang/AST/ExprObjC.h | 41 +- .../clang/include/clang/AST/JSONNodeDumper.h | 9 + .../llvm-project/clang/include/clang/AST/Mangle.h | 4 +- .../clang/include/clang/AST/OpenMPClause.h | 181 +- .../clang/include/clang/AST/OperationKinds.def | 1 + .../clang/include/clang/AST/PrettyPrinter.h | 40 +- .../clang/include/clang/AST/PropertiesBase.td | 4 +- .../clang/include/clang/AST/RawCommentList.h | 1 + .../clang/include/clang/AST/RecursiveASTVisitor.h | 90 +- .../llvm-project/clang/include/clang/AST/Stmt.h | 195 +- .../clang/include/clang/AST/StmtOpenMP.h | 77 +- .../clang/include/clang/AST/TemplateBase.h | 11 + .../clang/include/clang/AST/TemplateName.h | 2 +- .../clang/include/clang/AST/TextNodeDumper.h | 7 + .../llvm-project/clang/include/clang/AST/Type.h | 409 +- .../llvm-project/clang/include/clang/AST/TypeLoc.h | 111 +- .../clang/include/clang/AST/TypeProperties.td | 4 + .../clang/include/clang/AST/VTableBuilder.h | 2 +- .../clang/include/clang/ASTMatchers/ASTMatchers.h | 37 +- .../include/clang/Analysis/Analyses/Dominators.h | 2 +- .../clang/Analysis/Analyses/IntervalPartition.h | 109 +- .../include/clang/Analysis/Analyses/ThreadSafety.h | 8 +- .../clang/Analysis/Analyses/ThreadSafetyCommon.h | 2 +- .../clang/Analysis/Analyses/UnsafeBufferUsage.h | 65 +- .../Analysis/Analyses/UnsafeBufferUsageGadgets.def | 1 + .../clang/include/clang/Analysis/CFG.h | 39 +- .../clang/include/clang/Analysis/CFGStmtMap.h | 2 + .../include/clang/Analysis/FlowSensitive/Arena.h | 23 +- .../Analysis/FlowSensitive/ControlFlowContext.h | 14 +- .../Analysis/FlowSensitive/DataflowAnalysis.h | 84 +- .../FlowSensitive/DataflowAnalysisContext.h | 122 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 201 +- .../Analysis/FlowSensitive/DataflowWorklist.h | 26 +- .../include/clang/Analysis/FlowSensitive/Formula.h | 17 +- .../include/clang/Analysis/FlowSensitive/Logger.h | 4 +- .../clang/Analysis/FlowSensitive/MatchSwitch.h | 4 + .../Models/UncheckedOptionalAccessModel.h | 24 +- .../clang/Analysis/FlowSensitive/NoopAnalysis.h | 12 +- .../clang/Analysis/FlowSensitive/RecordOps.h | 38 +- .../Analysis/FlowSensitive/SimplifyConstraints.h | 49 + .../clang/Analysis/FlowSensitive/StorageLocation.h | 52 +- .../FlowSensitive/TypeErasedDataflowAnalysis.h | 19 - .../include/clang/Analysis/FlowSensitive/Value.h | 64 +- .../include/clang/Basic/AArch64SVEACLETypes.def | 2 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 298 +- .../clang/include/clang/Basic/AttrDocs.td | 769 +- .../include/clang/Basic/AttrSubjectMatchRules.h | 4 +- .../include/clang/Basic/AttributeCommonInfo.h | 30 +- .../clang/include/clang/Basic/Attributes.h | 4 +- .../clang/include/clang/Basic/Builtins.def | 52 +- .../clang/include/clang/Basic/BuiltinsAArch64.def | 17 +- .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 40 +- .../include/clang/Basic/BuiltinsLoongArch.def | 45 +- .../include/clang/Basic/BuiltinsLoongArchBase.def | 53 + .../include/clang/Basic/BuiltinsLoongArchLASX.def | 982 + .../include/clang/Basic/BuiltinsLoongArchLSX.def | 953 + .../clang/include/clang/Basic/BuiltinsNVPTX.def | 25 +- .../clang/include/clang/Basic/BuiltinsPPC.def | 3 + .../clang/include/clang/Basic/BuiltinsRISCV.def | 4 +- .../clang/include/clang/Basic/BuiltinsSystemZ.def | 46 +- .../clang/include/clang/Basic/BuiltinsX86.def | 852 +- .../clang/include/clang/Basic/BuiltinsX86_64.def | 3 + .../clang/include/clang/Basic/CodeGenOptions.def | 94 +- .../clang/include/clang/Basic/CodeGenOptions.h | 27 +- .../llvm-project/clang/include/clang/Basic/Cuda.h | 11 +- .../clang/include/clang/Basic/DebugOptions.def | 146 + .../clang/include/clang/Basic/DeclNodes.td | 1 - .../clang/include/clang/Basic/Diagnostic.h | 12 +- .../include/clang/Basic/DiagnosticASTKinds.td | 25 +- .../include/clang/Basic/DiagnosticCommonKinds.td | 57 +- .../include/clang/Basic/DiagnosticDriverKinds.td | 53 +- .../include/clang/Basic/DiagnosticFrontendKinds.td | 8 + .../clang/include/clang/Basic/DiagnosticGroups.td | 91 +- .../clang/include/clang/Basic/DiagnosticIDs.h | 8 +- .../include/clang/Basic/DiagnosticLexKinds.td | 50 +- .../clang/include/clang/Basic/DiagnosticOptions.h | 5 + .../include/clang/Basic/DiagnosticParseKinds.td | 78 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 342 +- .../clang/Basic/DiagnosticSerializationKinds.td | 7 +- .../clang/include/clang/Basic/DirectoryEntry.h | 74 - .../clang/include/clang/Basic/FPOptions.def | 4 +- .../clang/include/clang/Basic/Features.def | 7 +- .../clang/include/clang/Basic/FileEntry.h | 94 +- .../clang/include/clang/Basic/FileManager.h | 17 +- .../clang/include/clang/Basic/IdentifierTable.h | 306 +- .../clang/include/clang/Basic/JsonSupport.h | 2 +- .../clang/include/clang/Basic/LangOptions.def | 26 +- .../clang/include/clang/Basic/LangOptions.h | 32 +- .../clang/include/clang/Basic/LangStandard.h | 7 +- .../clang/include/clang/Basic/LangStandards.def | 18 +- .../clang/include/clang/Basic/Linkage.h | 54 +- .../clang/include/clang/Basic/Module.h | 61 +- .../clang/include/clang/Basic/ObjCRuntime.h | 4 +- .../clang/include/clang/Basic/OpenACCKinds.h | 74 + .../clang/include/clang/Basic/OpenMPKinds.def | 10 + .../clang/include/clang/Basic/OpenMPKinds.h | 12 + .../clang/include/clang/Basic/ParsedAttrInfo.h | 16 + .../clang/include/clang/Basic/PragmaKinds.h | 8 + .../clang/include/clang/Basic/RISCVVTypes.def | 91 +- .../clang/include/clang/Basic/Sanitizers.h | 6 +- .../clang/include/clang/Basic/SourceLocation.h | 5 +- .../clang/include/clang/Basic/SourceManager.h | 88 +- .../clang/include/clang/Basic/SourceMgrAdapter.h | 85 + .../clang/include/clang/Basic/Specifiers.h | 20 +- .../clang/include/clang/Basic/StmtNodes.td | 1 + .../clang/include/clang/Basic/SyncScope.h | 69 +- .../clang/include/clang/Basic/TargetBuiltins.h | 2 +- .../clang/include/clang/Basic/TargetInfo.h | 27 +- .../clang/include/clang/Basic/TargetOSMacros.def | 55 + .../clang/include/clang/Basic/TargetOptions.h | 16 +- .../clang/include/clang/Basic/TokenKinds.def | 55 +- .../clang/include/clang/Basic/Visibility.h | 28 +- .../clang/include/clang/Basic/arm_neon.td | 5 + .../clang/include/clang/Basic/arm_sme.td | 174 +- .../clang/include/clang/Basic/arm_sve.td | 442 +- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 13 +- .../include/clang/Basic/riscv_sifive_vector.td | 154 +- .../clang/include/clang/Basic/riscv_vector.td | 908 +- .../include/clang/Basic/riscv_vector_common.td | 467 + .../clang/include/clang/CodeGen/BackendUtil.h | 4 +- .../clang/include/clang/CodeGen/CGFunctionInfo.h | 5 + .../include/clang/CodeGen/ConstantInitBuilder.h | 7 +- .../clang/include/clang/Driver/ClangOptionDocs.td | 6 +- .../clang/include/clang/Driver/Distro.h | 3 +- .../clang/include/clang/Driver/Driver.h | 5 +- .../clang/include/clang/Driver/Multilib.h | 18 +- .../clang/include/clang/Driver/OffloadBundler.h | 39 +- .../clang/include/clang/Driver/Options.h | 40 +- .../clang/include/clang/Driver/Options.td | 3551 +- .../clang/include/clang/Driver/SanitizerArgs.h | 1 + .../clang/include/clang/Driver/ToolChain.h | 17 +- .../clang/include/clang/Driver/Types.def | 4 +- .../clang/include/clang/Driver/Types.h | 2 +- .../clang/include/clang/ExtractAPI/API.h | 811 +- .../clang/ExtractAPI/DeclarationFragments.h | 149 +- .../include/clang/ExtractAPI/ExtractAPIVisitor.h | 754 +- .../ExtractAPI/Serialization/SerializerBase.h | 190 + .../Serialization/SymbolGraphSerializer.h | 58 + .../clang/include/clang/Format/Format.h | 254 +- .../clang/include/clang/Frontend/ASTUnit.h | 31 +- .../include/clang/Frontend/CompilerInstance.h | 103 +- .../include/clang/Frontend/CompilerInvocation.h | 325 +- .../clang/Frontend/DependencyOutputOptions.h | 6 + .../clang/include/clang/Frontend/FrontendActions.h | 3 + .../clang/include/clang/Frontend/FrontendOptions.h | 50 +- .../clang/include/clang/Frontend/MigratorOptions.h | 4 + .../clang/Frontend/PreprocessorOutputOptions.h | 16 + .../include/clang/Frontend/TextDiagnosticPrinter.h | 1 + .../clang/Frontend/VerifyDiagnosticConsumer.h | 163 +- .../SerializablePathCollection.h | 2 +- .../include/clang/Interpreter/CodeCompletion.h | 30 + .../clang/include/clang/Lex/DirectoryLookup.h | 4 + .../clang/include/clang/Lex/HeaderMap.h | 3 +- .../clang/include/clang/Lex/HeaderSearch.h | 62 +- .../clang/include/clang/Lex/HeaderSearchOptions.h | 54 +- .../llvm-project/clang/include/clang/Lex/Lexer.h | 38 +- .../clang/include/clang/Lex/LiteralSupport.h | 11 +- .../clang/include/clang/Lex/MacroInfo.h | 3 + .../clang/include/clang/Lex/ModuleMap.h | 58 +- .../clang/include/clang/Lex/PPCallbacks.h | 10 +- .../clang/include/clang/Lex/PreprocessingRecord.h | 3 + .../clang/include/clang/Lex/Preprocessor.h | 84 +- .../clang/include/clang/Lex/PreprocessorLexer.h | 2 +- .../clang/include/clang/Lex/PreprocessorOptions.h | 3 + .../clang/include/clang/Lex/VariadicMacroSupport.h | 5 + .../clang/include/clang/Parse/LoopHint.h | 6 +- .../clang/include/clang/Parse/Parser.h | 84 +- .../include/clang/Parse/RAIIObjectsForParser.h | 19 + .../include/clang/Sema/CodeCompleteConsumer.h | 7 +- .../clang/include/clang/Sema/DeclSpec.h | 13 +- .../include/clang/Sema/HLSLExternalSemaSource.h | 4 +- .../clang/include/clang/Sema/IdentifierResolver.h | 3 + .../llvm-project/clang/include/clang/Sema/Lookup.h | 67 +- .../clang/include/clang/Sema/Overload.h | 8 +- .../clang/include/clang/Sema/Ownership.h | 276 +- .../clang/include/clang/Sema/ParsedAttr.h | 15 + .../clang/include/clang/Sema/ScopeInfo.h | 14 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 562 +- .../clang/include/clang/Sema/Template.h | 6 +- .../clang/include/clang/Sema/TypoCorrection.h | 12 +- .../include/clang/Serialization/ASTBitCodes.h | 19 +- .../clang/include/clang/Serialization/ASTReader.h | 95 +- .../include/clang/Serialization/ASTRecordReader.h | 9 +- .../include/clang/Serialization/ASTRecordWriter.h | 3 + .../clang/include/clang/Serialization/ASTWriter.h | 82 +- .../clang/Serialization/GlobalModuleIndex.h | 8 +- .../clang/include/clang/Serialization/ModuleFile.h | 20 +- .../clang/Serialization/ModuleFileExtension.h | 3 +- .../clang/StaticAnalyzer/Checkers/Checkers.td | 139 +- .../clang/StaticAnalyzer/Checkers/SValExplainer.h | 10 +- .../clang/StaticAnalyzer/Core/AnalyzerOptions.h | 4 +- .../StaticAnalyzer/Core/BugReporter/BugReporter.h | 5 +- .../Core/BugReporter/BugSuppression.h | 53 + .../StaticAnalyzer/Core/BugReporter/BugType.h | 33 +- .../include/clang/StaticAnalyzer/Core/Checker.h | 4 +- .../StaticAnalyzer/Core/PathSensitive/CallEvent.h | 99 +- .../Core/PathSensitive/ConstraintManager.h | 16 + .../Core/PathSensitive/DynamicExtent.h | 5 + .../Core/PathSensitive/DynamicType.h | 1 - .../Core/PathSensitive/SValBuilder.h | 17 + .../Core/PathSensitive/SValVisitor.h | 55 +- .../StaticAnalyzer/Core/PathSensitive/SVals.def | 38 +- .../StaticAnalyzer/Core/PathSensitive/SVals.h | 226 +- .../include/clang/Support/RISCVVIntrinsicUtils.h | 53 +- .../DependencyScanningFilesystem.h | 2 +- .../DependencyScanning/DependencyScanningService.h | 26 +- .../DependencyScanning/DependencyScanningTool.h | 37 +- .../DependencyScanning/DependencyScanningWorker.h | 4 +- .../DependencyScanning/ModuleDepCollector.h | 59 +- .../clang/Tooling/Inclusions/HeaderAnalysis.h | 4 +- .../clang/include/clang/Tooling/Tooling.h | 3 + .../include/clang/Tooling/Transformer/SourceCode.h | 6 + .../llvm-project/clang/include/module.modulemap | 4 + .../clang/lib/APINotes/APINotesFormat.h | 92 +- .../clang/lib/APINotes/APINotesManager.cpp | 458 + .../clang/lib/APINotes/APINotesReader.cpp | 2049 + .../clang/lib/APINotes/APINotesWriter.cpp | 1384 + .../clang/lib/APINotes/APINotesYAMLCompiler.cpp | 521 +- .../llvm-project/clang/lib/ARCMigrate/ARCMT.cpp | 27 +- .../clang/lib/ARCMigrate/FileRemapper.cpp | 107 +- .../llvm-project/clang/lib/ARCMigrate/ObjCMT.cpp | 22 +- .../clang/lib/ARCMigrate/PlistReporter.cpp | 2 +- .../clang/lib/ARCMigrate/TransAutoreleasePool.cpp | 4 +- .../clang/lib/ARCMigrate/TransUnbridgedCasts.cpp | 2 +- .../clang/lib/ARCMigrate/TransformActions.cpp | 2 +- .../clang/lib/ARCMigrate/Transforms.cpp | 2 +- contrib/llvm-project/clang/lib/AST/APValue.cpp | 18 +- contrib/llvm-project/clang/lib/AST/ASTConcept.cpp | 29 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 706 +- .../llvm-project/clang/lib/AST/ASTDiagnostic.cpp | 1 + contrib/llvm-project/clang/lib/AST/ASTDumper.cpp | 15 + contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 468 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 49 +- .../llvm-project/clang/lib/AST/ASTTypeTraits.cpp | 8 + contrib/llvm-project/clang/lib/AST/Comment.cpp | 30 +- contrib/llvm-project/clang/lib/AST/CommentSema.cpp | 52 +- .../clang/lib/AST/ComputeDependence.cpp | 9 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 252 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 89 +- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 100 +- contrib/llvm-project/clang/lib/AST/DeclObjC.cpp | 14 +- contrib/llvm-project/clang/lib/AST/DeclOpenMP.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclPrinter.cpp | 196 +- .../llvm-project/clang/lib/AST/DeclTemplate.cpp | 38 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 355 +- contrib/llvm-project/clang/lib/AST/ExprCXX.cpp | 65 +- .../clang/lib/AST/ExprClassification.cpp | 18 +- .../llvm-project/clang/lib/AST/ExprConcepts.cpp | 83 +- .../llvm-project/clang/lib/AST/ExprConstShared.h | 59 + .../llvm-project/clang/lib/AST/ExprConstant.cpp | 747 +- .../llvm-project/clang/lib/AST/FormatString.cpp | 32 +- .../llvm-project/clang/lib/AST/Interp/Boolean.h | 12 +- .../clang/lib/AST/Interp/ByteCodeEmitter.cpp | 104 +- .../clang/lib/AST/Interp/ByteCodeEmitter.h | 13 +- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 2144 +- .../clang/lib/AST/Interp/ByteCodeExprGen.h | 102 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.cpp | 110 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.h | 9 +- .../llvm-project/clang/lib/AST/Interp/Context.cpp | 69 +- .../llvm-project/clang/lib/AST/Interp/Context.h | 15 +- .../clang/lib/AST/Interp/Descriptor.cpp | 128 +- .../llvm-project/clang/lib/AST/Interp/Descriptor.h | 56 +- .../llvm-project/clang/lib/AST/Interp/Disasm.cpp | 6 + .../clang/lib/AST/Interp/EvalEmitter.cpp | 49 +- .../clang/lib/AST/Interp/EvalEmitter.h | 17 +- .../llvm-project/clang/lib/AST/Interp/Floating.h | 62 +- contrib/llvm-project/clang/lib/AST/Interp/Frame.h | 2 +- .../llvm-project/clang/lib/AST/Interp/Function.cpp | 10 +- .../llvm-project/clang/lib/AST/Interp/Function.h | 39 +- .../llvm-project/clang/lib/AST/Interp/Integral.h | 22 +- .../llvm-project/clang/lib/AST/Interp/IntegralAP.h | 291 + .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 144 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 429 +- .../clang/lib/AST/Interp/InterpBlock.h | 37 +- .../clang/lib/AST/Interp/InterpBuiltin.cpp | 861 +- .../clang/lib/AST/Interp/InterpFrame.cpp | 27 +- .../clang/lib/AST/Interp/InterpFrame.h | 5 +- .../clang/lib/AST/Interp/InterpStack.cpp | 20 +- .../clang/lib/AST/Interp/InterpStack.h | 5 + .../clang/lib/AST/Interp/InterpState.cpp | 14 +- .../clang/lib/AST/Interp/InterpState.h | 3 + .../llvm-project/clang/lib/AST/Interp/Opcodes.td | 96 +- .../llvm-project/clang/lib/AST/Interp/Pointer.cpp | 83 +- .../llvm-project/clang/lib/AST/Interp/Pointer.h | 140 +- .../llvm-project/clang/lib/AST/Interp/PrimType.cpp | 1 + .../llvm-project/clang/lib/AST/Interp/PrimType.h | 47 +- .../llvm-project/clang/lib/AST/Interp/Program.cpp | 31 +- .../llvm-project/clang/lib/AST/Interp/Program.h | 8 +- contrib/llvm-project/clang/lib/AST/Interp/Record.h | 6 +- .../llvm-project/clang/lib/AST/Interp/Source.cpp | 14 + contrib/llvm-project/clang/lib/AST/Interp/Source.h | 11 +- .../llvm-project/clang/lib/AST/Interp/State.cpp | 10 +- contrib/llvm-project/clang/lib/AST/Interp/State.h | 4 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 782 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 122 +- contrib/llvm-project/clang/lib/AST/Mangle.cpp | 12 +- .../llvm-project/clang/lib/AST/MicrosoftCXXABI.cpp | 10 +- .../llvm-project/clang/lib/AST/MicrosoftMangle.cpp | 149 +- .../llvm-project/clang/lib/AST/ODRDiagsEmitter.cpp | 6 +- contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 75 +- .../llvm-project/clang/lib/AST/OpenMPClause.cpp | 57 +- .../clang/lib/AST/PrintfFormatString.cpp | 2 +- .../llvm-project/clang/lib/AST/QualTypeNames.cpp | 4 +- .../llvm-project/clang/lib/AST/RawCommentList.cpp | 4 +- .../clang/lib/AST/RecordLayoutBuilder.cpp | 91 +- .../clang/lib/AST/ScanfFormatString.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Stmt.cpp | 7 +- contrib/llvm-project/clang/lib/AST/StmtOpenMP.cpp | 34 +- contrib/llvm-project/clang/lib/AST/StmtPrinter.cpp | 24 +- contrib/llvm-project/clang/lib/AST/StmtProfile.cpp | 27 +- .../llvm-project/clang/lib/AST/TemplateBase.cpp | 15 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 245 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 268 +- contrib/llvm-project/clang/lib/AST/TypeLoc.cpp | 45 +- contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 86 +- .../llvm-project/clang/lib/AST/VTableBuilder.cpp | 37 +- .../clang/lib/ASTMatchers/ASTMatchFinder.cpp | 28 +- .../clang/lib/ASTMatchers/ASTMatchersInternal.cpp | 18 +- .../clang/lib/ASTMatchers/Dynamic/Parser.cpp | 6 +- .../clang/lib/ASTMatchers/Dynamic/Registry.cpp | 3 + .../clang/lib/ASTMatchers/GtestMatchers.cpp | 1 - .../llvm-project/clang/lib/Analysis/BodyFarm.cpp | 6 +- contrib/llvm-project/clang/lib/Analysis/CFG.cpp | 78 +- .../llvm-project/clang/lib/Analysis/CallGraph.cpp | 2 +- .../clang/lib/Analysis/CalledOnceCheck.cpp | 2 +- .../clang/lib/Analysis/CocoaConventions.cpp | 11 +- .../llvm-project/clang/lib/Analysis/Consumed.cpp | 4 +- .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 28 +- .../clang/lib/Analysis/FlowSensitive/Arena.cpp | 195 +- .../Analysis/FlowSensitive/ControlFlowContext.cpp | 20 +- .../FlowSensitive/DataflowAnalysisContext.cpp | 180 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 668 +- .../lib/Analysis/FlowSensitive/DebugSupport.cpp | 6 +- .../clang/lib/Analysis/FlowSensitive/Formula.cpp | 18 +- .../lib/Analysis/FlowSensitive/HTMLLogger.cpp | 131 +- .../lib/Analysis/FlowSensitive/HTMLLogger.css | 27 +- .../lib/Analysis/FlowSensitive/HTMLLogger.html | 23 +- .../clang/lib/Analysis/FlowSensitive/Logger.cpp | 19 +- .../FlowSensitive/Models/ChromiumCheckModel.cpp | 4 +- .../Models/UncheckedOptionalAccessModel.cpp | 481 +- .../clang/lib/Analysis/FlowSensitive/RecordOps.cpp | 72 +- .../Analysis/FlowSensitive/SimplifyConstraints.cpp | 180 + .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 303 +- .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 129 +- .../clang/lib/Analysis/FlowSensitive/Value.cpp | 28 +- .../FlowSensitive/WatchedLiteralsSolver.cpp | 216 +- .../clang/lib/Analysis/IntervalPartition.cpp | 215 +- .../clang/lib/Analysis/PathDiagnostic.cpp | 8 +- .../clang/lib/Analysis/RetainSummaryManager.cpp | 69 +- .../clang/lib/Analysis/ThreadSafety.cpp | 259 +- .../clang/lib/Analysis/ThreadSafetyCommon.cpp | 23 +- .../clang/lib/Analysis/UninitializedValues.cpp | 2 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 1038 +- .../llvm-project/clang/lib/Basic/Attributes.cpp | 28 +- .../clang/lib/Basic/CodeGenOptions.cpp | 35 + contrib/llvm-project/clang/lib/Basic/Cuda.cpp | 7 + .../llvm-project/clang/lib/Basic/Diagnostic.cpp | 11 +- .../llvm-project/clang/lib/Basic/DiagnosticIDs.cpp | 2 +- .../llvm-project/clang/lib/Basic/FileManager.cpp | 87 +- .../clang/lib/Basic/IdentifierTable.cpp | 82 +- .../llvm-project/clang/lib/Basic/LangOptions.cpp | 6 +- .../llvm-project/clang/lib/Basic/LangStandards.cpp | 33 + contrib/llvm-project/clang/lib/Basic/Module.cpp | 51 +- .../llvm-project/clang/lib/Basic/OpenMPKinds.cpp | 25 + .../llvm-project/clang/lib/Basic/ProfileList.cpp | 4 +- .../clang/lib/Basic/SanitizerSpecialCaseList.cpp | 3 +- contrib/llvm-project/clang/lib/Basic/Sarif.cpp | 17 +- .../clang/lib/Basic/SourceLocation.cpp | 5 + .../llvm-project/clang/lib/Basic/SourceManager.cpp | 317 +- .../clang/lib/Basic/SourceMgrAdapter.cpp | 136 + .../llvm-project/clang/lib/Basic/TargetInfo.cpp | 10 +- contrib/llvm-project/clang/lib/Basic/Targets.cpp | 48 +- .../clang/lib/Basic/Targets/AArch64.cpp | 72 +- .../llvm-project/clang/lib/Basic/Targets/AArch64.h | 3 + .../clang/lib/Basic/Targets/AMDGPU.cpp | 91 +- .../llvm-project/clang/lib/Basic/Targets/AMDGPU.h | 19 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 4 +- .../llvm-project/clang/lib/Basic/Targets/BPF.cpp | 33 +- contrib/llvm-project/clang/lib/Basic/Targets/BPF.h | 2 +- .../clang/lib/Basic/Targets/LoongArch.cpp | 12 +- .../clang/lib/Basic/Targets/LoongArch.h | 5 + .../llvm-project/clang/lib/Basic/Targets/M68k.cpp | 34 +- .../llvm-project/clang/lib/Basic/Targets/M68k.h | 1 + .../llvm-project/clang/lib/Basic/Targets/Mips.cpp | 6 +- .../llvm-project/clang/lib/Basic/Targets/Mips.h | 13 + .../llvm-project/clang/lib/Basic/Targets/NVPTX.cpp | 7 +- .../llvm-project/clang/lib/Basic/Targets/NVPTX.h | 2 + .../clang/lib/Basic/Targets/OSTargets.cpp | 3 + .../clang/lib/Basic/Targets/OSTargets.h | 57 +- .../llvm-project/clang/lib/Basic/Targets/PPC.cpp | 31 +- contrib/llvm-project/clang/lib/Basic/Targets/PPC.h | 3 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 164 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 10 + .../llvm-project/clang/lib/Basic/Targets/SPIR.cpp | 11 +- .../llvm-project/clang/lib/Basic/Targets/SPIR.h | 54 +- .../llvm-project/clang/lib/Basic/Targets/Sparc.cpp | 76 +- .../llvm-project/clang/lib/Basic/Targets/SystemZ.h | 2 +- .../clang/lib/Basic/Targets/WebAssembly.cpp | 12 + .../clang/lib/Basic/Targets/WebAssembly.h | 1 + .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 140 +- contrib/llvm-project/clang/lib/Basic/Targets/X86.h | 53 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 8 +- .../clang/lib/CodeGen/BackendConsumer.h | 166 + .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 227 +- .../llvm-project/clang/lib/CodeGen/CGAtomic.cpp | 308 +- .../llvm-project/clang/lib/CodeGen/CGBlocks.cpp | 100 +- contrib/llvm-project/clang/lib/CodeGen/CGBuilder.h | 17 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 1850 +- .../llvm-project/clang/lib/CodeGen/CGCUDANV.cpp | 173 +- .../llvm-project/clang/lib/CodeGen/CGCUDARuntime.h | 14 +- .../llvm-project/clang/lib/CodeGen/CGCXXABI.cpp | 8 +- contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 168 +- contrib/llvm-project/clang/lib/CodeGen/CGCall.h | 36 +- contrib/llvm-project/clang/lib/CodeGen/CGClass.cpp | 55 +- .../llvm-project/clang/lib/CodeGen/CGCleanup.cpp | 14 +- .../llvm-project/clang/lib/CodeGen/CGCoroutine.cpp | 95 +- .../llvm-project/clang/lib/CodeGen/CGDebugInfo.cpp | 154 +- .../llvm-project/clang/lib/CodeGen/CGDebugInfo.h | 14 +- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 62 +- .../llvm-project/clang/lib/CodeGen/CGDeclCXX.cpp | 53 +- .../llvm-project/clang/lib/CodeGen/CGException.cpp | 75 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 385 +- .../llvm-project/clang/lib/CodeGen/CGExprCXX.cpp | 43 +- .../clang/lib/CodeGen/CGExprComplex.cpp | 170 +- .../clang/lib/CodeGen/CGExprConstant.cpp | 73 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 80 +- .../clang/lib/CodeGen/CGGPUBuiltin.cpp | 15 +- .../clang/lib/CodeGen/CGHLSLRuntime.cpp | 66 +- .../llvm-project/clang/lib/CodeGen/CGHLSLRuntime.h | 2 +- .../llvm-project/clang/lib/CodeGen/CGLoopInfo.cpp | 24 +- .../llvm-project/clang/lib/CodeGen/CGLoopInfo.h | 6 + .../clang/lib/CodeGen/CGNonTrivialStruct.cpp | 4 +- contrib/llvm-project/clang/lib/CodeGen/CGObjC.cpp | 37 +- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 186 +- .../llvm-project/clang/lib/CodeGen/CGObjCMac.cpp | 149 +- .../clang/lib/CodeGen/CGObjCRuntime.cpp | 4 +- .../clang/lib/CodeGen/CGOpenCLRuntime.cpp | 50 +- .../clang/lib/CodeGen/CGOpenCLRuntime.h | 3 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 1169 +- .../clang/lib/CodeGen/CGOpenMPRuntime.h | 77 +- .../clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp | 517 +- .../clang/lib/CodeGen/CGOpenMPRuntimeGPU.h | 40 +- .../clang/lib/CodeGen/CGRecordLayoutBuilder.cpp | 13 +- contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 46 +- .../clang/lib/CodeGen/CGStmtOpenMP.cpp | 44 +- contrib/llvm-project/clang/lib/CodeGen/CGVTT.cpp | 5 + .../llvm-project/clang/lib/CodeGen/CGVTables.cpp | 82 +- .../clang/lib/CodeGen/CodeGenAction.cpp | 671 +- .../clang/lib/CodeGen/CodeGenFunction.cpp | 89 +- .../clang/lib/CodeGen/CodeGenFunction.h | 52 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 460 +- .../llvm-project/clang/lib/CodeGen/CodeGenModule.h | 100 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 21 +- .../llvm-project/clang/lib/CodeGen/CodeGenTBAA.cpp | 33 +- .../clang/lib/CodeGen/CodeGenTypeCache.h | 7 +- .../clang/lib/CodeGen/CodeGenTypes.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/CodeGenTypes.h | 4 + .../clang/lib/CodeGen/CoverageMappingGen.cpp | 32 +- .../clang/lib/CodeGen/CoverageMappingGen.h | 4 +- .../llvm-project/clang/lib/CodeGen/EHScopeStack.h | 4 +- .../clang/lib/CodeGen/ItaniumCXXABI.cpp | 120 +- .../clang/lib/CodeGen/LinkInModulesPass.cpp | 29 + .../clang/lib/CodeGen/LinkInModulesPass.h | 42 + .../clang/lib/CodeGen/MicrosoftCXXABI.cpp | 100 +- .../CodeGen/ObjectFilePCHContainerOperations.cpp | 3 + .../clang/lib/CodeGen/SwiftCallingConv.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.cpp | 2 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.h | 3 + .../clang/lib/CodeGen/Targets/AArch64.cpp | 19 +- .../clang/lib/CodeGen/Targets/AMDGPU.cpp | 159 +- .../clang/lib/CodeGen/Targets/LoongArch.cpp | 24 +- .../clang/lib/CodeGen/Targets/NVPTX.cpp | 71 +- .../llvm-project/clang/lib/CodeGen/Targets/PPC.cpp | 23 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 4 +- .../clang/lib/CodeGen/Targets/SPIR.cpp | 6 +- .../clang/lib/CodeGen/Targets/Sparc.cpp | 2 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 58 +- .../clang/lib/CodeGen/Targets/XCore.cpp | 2 +- .../clang/lib/CrossTU/CrossTranslationUnit.cpp | 10 +- .../linux/DirectoryWatcher-linux.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Distro.cpp | 15 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 316 +- .../clang/lib/Driver/DriverOptions.cpp | 5 +- contrib/llvm-project/clang/lib/Driver/Job.cpp | 8 +- contrib/llvm-project/clang/lib/Driver/Multilib.cpp | 116 +- .../clang/lib/Driver/OffloadBundler.cpp | 591 +- .../clang/lib/Driver/SanitizerArgs.cpp | 2 + .../llvm-project/clang/lib/Driver/ToolChain.cpp | 112 +- .../clang/lib/Driver/ToolChains/AIX.cpp | 31 +- .../llvm-project/clang/lib/Driver/ToolChains/AIX.h | 6 +- .../clang/lib/Driver/ToolChains/AMDGPU.cpp | 82 +- .../clang/lib/Driver/ToolChains/AMDGPU.h | 2 +- .../clang/lib/Driver/ToolChains/AVR.cpp | 61 +- .../llvm-project/clang/lib/Driver/ToolChains/AVR.h | 2 +- .../clang/lib/Driver/ToolChains/Ananas.cpp | 148 - .../clang/lib/Driver/ToolChains/Ananas.h | 65 - .../clang/lib/Driver/ToolChains/Arch/AArch64.cpp | 17 +- .../clang/lib/Driver/ToolChains/Arch/ARM.cpp | 35 +- .../clang/lib/Driver/ToolChains/Arch/LoongArch.cpp | 32 + .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 11 +- .../clang/lib/Driver/ToolChains/Arch/Sparc.cpp | 4 - .../clang/lib/Driver/ToolChains/Arch/VE.cpp | 7 +- .../clang/lib/Driver/ToolChains/Arch/X86.cpp | 42 +- .../clang/lib/Driver/ToolChains/BareMetal.cpp | 31 +- .../clang/lib/Driver/ToolChains/BareMetal.h | 3 +- .../clang/lib/Driver/ToolChains/CSKYToolChain.cpp | 5 +- .../clang/lib/Driver/ToolChains/CSKYToolChain.h | 2 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 845 +- .../clang/lib/Driver/ToolChains/Clang.h | 4 +- .../clang/lib/Driver/ToolChains/CloudABI.cpp | 151 - .../clang/lib/Driver/ToolChains/CloudABI.h | 70 - .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 400 +- .../clang/lib/Driver/ToolChains/CommonArgs.h | 34 +- .../clang/lib/Driver/ToolChains/Contiki.cpp | 27 - .../clang/lib/Driver/ToolChains/Contiki.h | 39 - .../clang/lib/Driver/ToolChains/CrossWindows.h | 4 +- .../clang/lib/Driver/ToolChains/Cuda.cpp | 21 +- .../clang/lib/Driver/ToolChains/Cuda.h | 6 +- .../clang/lib/Driver/ToolChains/Darwin.cpp | 133 +- .../clang/lib/Driver/ToolChains/DragonFly.cpp | 152 +- .../clang/lib/Driver/ToolChains/DragonFly.h | 14 +- .../clang/lib/Driver/ToolChains/Flang.cpp | 263 +- .../clang/lib/Driver/ToolChains/Flang.h | 14 + .../clang/lib/Driver/ToolChains/FreeBSD.cpp | 104 +- .../clang/lib/Driver/ToolChains/FreeBSD.h | 12 +- .../clang/lib/Driver/ToolChains/Fuchsia.cpp | 23 +- .../clang/lib/Driver/ToolChains/Fuchsia.h | 2 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 269 +- .../llvm-project/clang/lib/Driver/ToolChains/Gnu.h | 3 +- .../clang/lib/Driver/ToolChains/HIPAMD.cpp | 16 +- .../clang/lib/Driver/ToolChains/HIPAMD.h | 2 +- .../clang/lib/Driver/ToolChains/HIPSPV.cpp | 4 - .../clang/lib/Driver/ToolChains/HIPSPV.h | 2 +- .../clang/lib/Driver/ToolChains/HIPUtility.cpp | 8 + .../clang/lib/Driver/ToolChains/HLSL.cpp | 8 - .../clang/lib/Driver/ToolChains/Haiku.cpp | 257 +- .../clang/lib/Driver/ToolChains/Haiku.h | 40 +- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 24 +- .../clang/lib/Driver/ToolChains/Hexagon.h | 4 +- .../clang/lib/Driver/ToolChains/Hurd.cpp | 4 +- .../clang/lib/Driver/ToolChains/Linux.cpp | 2 +- .../clang/lib/Driver/ToolChains/MSP430.cpp | 4 +- .../clang/lib/Driver/ToolChains/MSP430.h | 2 +- .../clang/lib/Driver/ToolChains/MSVC.cpp | 10 +- .../clang/lib/Driver/ToolChains/MSVC.h | 2 +- .../clang/lib/Driver/ToolChains/MinGW.cpp | 19 +- .../clang/lib/Driver/ToolChains/MinGW.h | 4 +- .../clang/lib/Driver/ToolChains/Minix.cpp | 116 - .../clang/lib/Driver/ToolChains/Minix.h | 64 - .../clang/lib/Driver/ToolChains/Myriad.cpp | 293 - .../clang/lib/Driver/ToolChains/Myriad.h | 103 - .../clang/lib/Driver/ToolChains/NaCl.cpp | 9 +- .../clang/lib/Driver/ToolChains/NaCl.h | 2 +- .../clang/lib/Driver/ToolChains/NetBSD.cpp | 150 +- .../clang/lib/Driver/ToolChains/NetBSD.h | 6 +- .../clang/lib/Driver/ToolChains/OpenBSD.cpp | 77 +- .../clang/lib/Driver/ToolChains/OpenBSD.h | 6 +- .../clang/lib/Driver/ToolChains/PPCLinux.cpp | 4 +- .../clang/lib/Driver/ToolChains/PS4CPU.cpp | 15 +- .../clang/lib/Driver/ToolChains/PS4CPU.h | 4 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.cpp | 9 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.h | 2 +- .../clang/lib/Driver/ToolChains/ROCm.h | 13 + .../clang/lib/Driver/ToolChains/SPIRV.h | 2 +- .../clang/lib/Driver/ToolChains/Solaris.cpp | 212 +- .../clang/lib/Driver/ToolChains/Solaris.h | 18 +- .../clang/lib/Driver/ToolChains/VEToolchain.cpp | 14 +- .../clang/lib/Driver/ToolChains/WebAssembly.cpp | 37 +- .../clang/lib/Driver/ToolChains/WebAssembly.h | 2 +- .../clang/lib/Driver/ToolChains/XCore.cpp | 3 +- .../clang/lib/Driver/ToolChains/XCore.h | 4 +- .../clang/lib/Driver/ToolChains/ZOS.cpp | 16 +- .../llvm-project/clang/lib/Driver/ToolChains/ZOS.h | 6 +- contrib/llvm-project/clang/lib/Driver/Types.cpp | 4 +- contrib/llvm-project/clang/lib/Edit/Commit.cpp | 2 +- .../clang/lib/Edit/RewriteObjCFoundationAPI.cpp | 8 +- contrib/llvm-project/clang/lib/ExtractAPI/API.cpp | 275 +- .../clang/lib/ExtractAPI/DeclarationFragments.cpp | 772 +- .../clang/lib/ExtractAPI/ExtractAPIConsumer.cpp | 27 +- .../Serialization/SymbolGraphSerializer.cpp | 470 +- .../clang/lib/Format/BreakableToken.cpp | 158 +- .../llvm-project/clang/lib/Format/BreakableToken.h | 44 + .../clang/lib/Format/ContinuationIndenter.cpp | 291 +- .../clang/lib/Format/ContinuationIndenter.h | 3 + .../clang/lib/Format/DefinitionBlockSeparator.cpp | 8 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 206 +- .../llvm-project/clang/lib/Format/FormatToken.cpp | 3 +- .../llvm-project/clang/lib/Format/FormatToken.h | 75 +- .../clang/lib/Format/FormatTokenLexer.cpp | 41 +- .../clang/lib/Format/FormatTokenSource.h | 2 +- .../clang/lib/Format/MacroCallReconstructor.cpp | 49 +- .../clang/lib/Format/MacroExpander.cpp | 4 +- .../clang/lib/Format/NamespaceEndCommentsFixer.cpp | 14 +- .../lib/Format/ObjCPropertyAttributeOrderFixer.cpp | 220 + .../lib/Format/ObjCPropertyAttributeOrderFixer.h | 51 + .../clang/lib/Format/QualifierAlignmentFixer.cpp | 30 +- .../clang/lib/Format/QualifierAlignmentFixer.h | 9 +- .../clang/lib/Format/SortJavaScriptImports.cpp | 18 +- .../clang/lib/Format/TokenAnnotator.cpp | 693 +- .../llvm-project/clang/lib/Format/TokenAnnotator.h | 17 + .../clang/lib/Format/UnwrappedLineFormatter.cpp | 88 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 335 +- .../clang/lib/Format/UnwrappedLineParser.h | 36 +- .../clang/lib/Format/WhitespaceManager.cpp | 334 +- .../clang/lib/Format/WhitespaceManager.h | 2 +- .../llvm-project/clang/lib/Frontend/ASTMerge.cpp | 2 +- .../llvm-project/clang/lib/Frontend/ASTUnit.cpp | 54 +- .../clang/lib/Frontend/CompilerInstance.cpp | 57 +- .../clang/lib/Frontend/CompilerInvocation.cpp | 1089 +- .../clang/lib/Frontend/DependencyFile.cpp | 2 +- .../clang/lib/Frontend/DependencyGraph.cpp | 2 +- .../clang/lib/Frontend/FrontendAction.cpp | 42 +- .../clang/lib/Frontend/FrontendActions.cpp | 33 +- .../clang/lib/Frontend/HeaderIncludeGen.cpp | 2 +- .../clang/lib/Frontend/InitPreprocessor.cpp | 47 +- .../clang/lib/Frontend/LogDiagnosticPrinter.cpp | 4 +- .../clang/lib/Frontend/PrecompiledPreamble.cpp | 18 +- .../clang/lib/Frontend/PrintPreprocessedOutput.cpp | 232 +- .../clang/lib/Frontend/Rewrite/FixItRewriter.cpp | 3 +- .../clang/lib/Frontend/Rewrite/HTMLPrint.cpp | 2 +- .../lib/Frontend/Rewrite/InclusionRewriter.cpp | 47 +- .../lib/Frontend/Rewrite/RewriteModernObjC.cpp | 45 +- .../clang/lib/Frontend/Rewrite/RewriteObjC.cpp | 36 +- .../clang/lib/Frontend/SARIFDiagnostic.cpp | 7 +- .../clang/lib/Frontend/TextDiagnostic.cpp | 9 +- .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 47 +- .../lib/FrontendTool/ExecuteCompilerInvocation.cpp | 6 +- .../lib/Headers/__clang_cuda_device_functions.h | 4 +- .../lib/Headers/__clang_cuda_libdevice_declares.h | 4 +- .../clang/lib/Headers/__clang_cuda_math.h | 4 +- .../lib/Headers/__clang_cuda_runtime_wrapper.h | 4 +- .../clang/lib/Headers/__clang_hip_math.h | 363 +- .../lib/Headers/__clang_hip_runtime_wrapper.h | 60 +- .../clang/lib/Headers/__stdarg___gnuc_va_list.h | 13 + .../clang/lib/Headers/__stdarg___va_copy.h | 12 + .../clang/lib/Headers/__stdarg_va_arg.h | 22 + .../clang/lib/Headers/__stdarg_va_copy.h | 12 + .../clang/lib/Headers/__stdarg_va_list.h | 13 + .../clang/lib/Headers/__stddef_max_align_t.h | 2 +- .../llvm-project/clang/lib/Headers/__stddef_null.h | 29 + .../clang/lib/Headers/__stddef_nullptr_t.h | 24 + .../clang/lib/Headers/__stddef_offsetof.h | 12 + .../clang/lib/Headers/__stddef_ptrdiff_t.h | 15 + .../clang/lib/Headers/__stddef_rsize_t.h | 15 + .../clang/lib/Headers/__stddef_size_t.h | 15 + .../clang/lib/Headers/__stddef_unreachable.h | 12 + .../clang/lib/Headers/__stddef_wchar_t.h | 23 + .../clang/lib/Headers/__stddef_wint_t.h | 15 + contrib/llvm-project/clang/lib/Headers/altivec.h | 43 +- contrib/llvm-project/clang/lib/Headers/ammintrin.h | 8 +- contrib/llvm-project/clang/lib/Headers/arm_acle.h | 15 + .../llvm-project/clang/lib/Headers/avx2intrin.h | 27 +- .../clang/lib/Headers/avx512bf16intrin.h | 5 +- .../clang/lib/Headers/avx512bitalgintrin.h | 5 +- .../clang/lib/Headers/avx512bwintrin.h | 66 +- .../clang/lib/Headers/avx512cdintrin.h | 4 +- .../clang/lib/Headers/avx512dqintrin.h | 6 +- .../llvm-project/clang/lib/Headers/avx512fintrin.h | 10 +- .../clang/lib/Headers/avx512fp16intrin.h | 10 +- .../clang/lib/Headers/avx512ifmaintrin.h | 4 +- .../clang/lib/Headers/avx512ifmavlintrin.h | 10 +- .../clang/lib/Headers/avx512pfintrin.h | 5 - .../clang/lib/Headers/avx512vbmi2intrin.h | 2 +- .../clang/lib/Headers/avx512vbmiintrin.h | 5 +- .../clang/lib/Headers/avx512vbmivlintrin.h | 11 +- .../clang/lib/Headers/avx512vlbf16intrin.h | 14 +- .../clang/lib/Headers/avx512vlbitalgintrin.h | 10 +- .../clang/lib/Headers/avx512vlbwintrin.h | 10 +- .../clang/lib/Headers/avx512vlcdintrin.h | 11 +- .../clang/lib/Headers/avx512vldqintrin.h | 10 +- .../clang/lib/Headers/avx512vlfp16intrin.h | 4 +- .../clang/lib/Headers/avx512vlintrin.h | 10 +- .../clang/lib/Headers/avx512vlvbmi2intrin.h | 10 +- .../clang/lib/Headers/avx512vlvnniintrin.h | 10 +- .../clang/lib/Headers/avx512vlvp2intersectintrin.h | 10 +- .../clang/lib/Headers/avx512vnniintrin.h | 5 +- .../clang/lib/Headers/avx512vp2intersectintrin.h | 5 +- .../clang/lib/Headers/avx512vpopcntdqintrin.h | 4 +- .../clang/lib/Headers/avx512vpopcntdqvlintrin.h | 8 +- contrib/llvm-project/clang/lib/Headers/avxintrin.h | 14 +- contrib/llvm-project/clang/lib/Headers/bmiintrin.h | 22 +- contrib/llvm-project/clang/lib/Headers/emmintrin.h | 20 +- .../llvm-project/clang/lib/Headers/gfniintrin.h | 29 +- .../clang/lib/Headers/hlsl/hlsl_intrinsics.h | 722 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 4 +- contrib/llvm-project/clang/lib/Headers/intrin.h | 16 + .../llvm-project/clang/lib/Headers/lasxintrin.h | 3860 ++ contrib/llvm-project/clang/lib/Headers/limits.h | 6 +- .../clang/lib/Headers/llvm_libc_wrappers/assert.h | 34 + .../clang/lib/Headers/llvm_libc_wrappers/ctype.h | 17 + .../clang/lib/Headers/llvm_libc_wrappers/stdio.h | 18 + .../clang/lib/Headers/llvm_libc_wrappers/stdlib.h | 5 +- .../clang/lib/Headers/llvm_libc_wrappers/string.h | 65 +- .../clang/lib/Headers/llvm_libc_wrappers/time.h | 34 + contrib/llvm-project/clang/lib/Headers/lsxintrin.h | 3726 ++ contrib/llvm-project/clang/lib/Headers/mmintrin.h | 12 +- .../clang/lib/Headers/module.modulemap | 159 +- .../llvm-project/clang/lib/Headers/opencl-c-base.h | 5 + .../clang/lib/Headers/openmp_wrappers/cmath | 2 +- contrib/llvm-project/clang/lib/Headers/pmmintrin.h | 5 +- .../clang/lib/Headers/ppc_wrappers/smmintrin.h | 50 +- .../clang/lib/Headers/riscv_bitmanip.h | 179 + .../llvm-project/clang/lib/Headers/riscv_crypto.h | 170 + .../llvm-project/clang/lib/Headers/riscv_ntlh.h | 8 +- contrib/llvm-project/clang/lib/Headers/smmintrin.h | 6 +- contrib/llvm-project/clang/lib/Headers/stdalign.h | 4 +- contrib/llvm-project/clang/lib/Headers/stdarg.h | 90 +- contrib/llvm-project/clang/lib/Headers/stdatomic.h | 8 +- contrib/llvm-project/clang/lib/Headers/stdckdint.h | 42 + contrib/llvm-project/clang/lib/Headers/stddef.h | 166 +- contrib/llvm-project/clang/lib/Headers/stdint.h | 67 +- .../llvm-project/clang/lib/Headers/stdnoreturn.h | 4 +- contrib/llvm-project/clang/lib/Headers/tmmintrin.h | 9 +- .../llvm-project/clang/lib/Headers/usermsrintrin.h | 30 + .../llvm-project/clang/lib/Headers/vaesintrin.h | 6 +- contrib/llvm-project/clang/lib/Headers/vecintrin.h | 416 +- .../llvm-project/clang/lib/Headers/x86gprintrin.h | 5 + contrib/llvm-project/clang/lib/Headers/xmmintrin.h | 14 +- .../llvm-project/clang/lib/Index/CommentToXML.cpp | 54 +- contrib/llvm-project/clang/lib/Index/IndexBody.cpp | 29 +- .../llvm-project/clang/lib/Index/IndexSymbol.cpp | 33 +- .../clang/lib/Index/IndexingContext.cpp | 5 +- .../llvm-project/clang/lib/Index/IndexingContext.h | 2 +- .../llvm-project/clang/lib/Index/USRGeneration.cpp | 63 +- .../SerializablePathCollection.cpp | 10 +- .../clang/lib/Interpreter/CodeCompletion.cpp | 211 + .../clang/lib/Interpreter/DeviceOffload.cpp | 2 +- .../clang/lib/Interpreter/IncrementalExecutor.cpp | 10 +- .../clang/lib/Interpreter/IncrementalParser.cpp | 9 +- .../clang/lib/Interpreter/IncrementalParser.h | 4 +- .../clang/lib/Interpreter/Interpreter.cpp | 7 +- .../llvm-project/clang/lib/Interpreter/Value.cpp | 17 +- .../clang/lib/Lex/DependencyDirectivesScanner.cpp | 5 +- contrib/llvm-project/clang/lib/Lex/HeaderMap.cpp | 15 +- .../llvm-project/clang/lib/Lex/HeaderSearch.cpp | 170 +- .../clang/lib/Lex/InitHeaderSearch.cpp | 116 +- contrib/llvm-project/clang/lib/Lex/Lexer.cpp | 212 +- .../llvm-project/clang/lib/Lex/LiteralSupport.cpp | 33 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 162 +- contrib/llvm-project/clang/lib/Lex/PPCaching.cpp | 6 +- .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 134 +- .../llvm-project/clang/lib/Lex/PPExpressions.cpp | 10 +- .../llvm-project/clang/lib/Lex/PPLexerChange.cpp | 24 +- .../clang/lib/Lex/PPMacroExpansion.cpp | 24 +- contrib/llvm-project/clang/lib/Lex/Pragma.cpp | 8 +- .../llvm-project/clang/lib/Lex/Preprocessor.cpp | 129 +- .../clang/lib/Lex/PreprocessorLexer.cpp | 3 +- .../clang/lib/Parse/ParseCXXInlineMethods.cpp | 5 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 307 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 79 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 116 +- .../llvm-project/clang/lib/Parse/ParseExprCXX.cpp | 227 +- contrib/llvm-project/clang/lib/Parse/ParseInit.cpp | 8 +- contrib/llvm-project/clang/lib/Parse/ParseObjc.cpp | 64 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 527 + .../llvm-project/clang/lib/Parse/ParseOpenMP.cpp | 205 +- .../llvm-project/clang/lib/Parse/ParsePragma.cpp | 183 +- contrib/llvm-project/clang/lib/Parse/ParseStmt.cpp | 83 +- .../llvm-project/clang/lib/Parse/ParseTemplate.cpp | 15 +- .../clang/lib/Parse/ParseTentative.cpp | 31 + contrib/llvm-project/clang/lib/Parse/Parser.cpp | 70 +- .../llvm-project/clang/lib/Rewrite/Rewriter.cpp | 17 +- .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 133 +- .../clang/lib/Sema/CodeCompleteConsumer.cpp | 14 +- contrib/llvm-project/clang/lib/Sema/DeclSpec.cpp | 17 +- .../clang/lib/Sema/HLSLExternalSemaSource.cpp | 95 +- .../clang/lib/Sema/IdentifierResolver.cpp | 7 +- contrib/llvm-project/clang/lib/Sema/ParsedAttr.cpp | 13 +- contrib/llvm-project/clang/lib/Sema/ScopeInfo.cpp | 8 + contrib/llvm-project/clang/lib/Sema/Sema.cpp | 66 +- contrib/llvm-project/clang/lib/Sema/SemaAttr.cpp | 26 +- .../clang/lib/Sema/SemaAvailability.cpp | 23 + contrib/llvm-project/clang/lib/Sema/SemaCUDA.cpp | 95 +- .../clang/lib/Sema/SemaCXXScopeSpec.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaCast.cpp | 17 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 1239 +- .../clang/lib/Sema/SemaCodeComplete.cpp | 215 +- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 62 +- .../llvm-project/clang/lib/Sema/SemaCoroutine.cpp | 116 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 943 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 471 +- .../llvm-project/clang/lib/Sema/SemaDeclCXX.cpp | 846 +- .../llvm-project/clang/lib/Sema/SemaDeclObjC.cpp | 76 +- .../clang/lib/Sema/SemaExceptionSpec.cpp | 65 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 908 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 385 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 94 +- .../llvm-project/clang/lib/Sema/SemaExprObjC.cpp | 56 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 366 +- contrib/llvm-project/clang/lib/Sema/SemaLambda.cpp | 156 +- contrib/llvm-project/clang/lib/Sema/SemaLookup.cpp | 142 +- contrib/llvm-project/clang/lib/Sema/SemaModule.cpp | 74 +- .../clang/lib/Sema/SemaObjCProperty.cpp | 32 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 342 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 1399 +- .../clang/lib/Sema/SemaPseudoObject.cpp | 7 +- .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 71 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 33 +- .../llvm-project/clang/lib/Sema/SemaStmtAsm.cpp | 3 +- .../llvm-project/clang/lib/Sema/SemaStmtAttr.cpp | 103 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 492 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 222 +- .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 108 +- .../clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 253 +- .../clang/lib/Sema/SemaTemplateVariadic.cpp | 7 + contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 434 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 289 +- .../llvm-project/clang/lib/Sema/TypeLocBuilder.h | 3 + .../clang/lib/Serialization/ASTCommon.cpp | 1 - .../clang/lib/Serialization/ASTReader.cpp | 725 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 352 +- .../clang/lib/Serialization/ASTReaderInternals.h | 4 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 149 +- .../clang/lib/Serialization/ASTWriter.cpp | 446 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 606 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 84 +- .../clang/lib/Serialization/GeneratePCH.cpp | 12 +- .../clang/lib/Serialization/GlobalModuleIndex.cpp | 66 +- .../clang/lib/Serialization/ModuleManager.cpp | 64 +- .../clang/lib/Serialization/MultiOnDiskHashTable.h | 8 +- .../StaticAnalyzer/Checkers/ArrayBoundChecker.cpp | 10 +- .../Checkers/ArrayBoundCheckerV2.cpp | 464 +- .../Checkers/BasicObjCFoundationChecks.cpp | 12 +- .../Checkers/BitwiseShiftChecker.cpp | 370 + .../Checkers/BoolAssignmentChecker.cpp | 4 +- .../Checkers/BuiltinFunctionChecker.cpp | 28 +- .../lib/StaticAnalyzer/Checkers/CStringChecker.cpp | 97 +- .../StaticAnalyzer/Checkers/CXXDeleteChecker.cpp | 248 + .../Checkers/CallAndMessageChecker.cpp | 30 +- .../StaticAnalyzer/Checkers/CastSizeChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/CheckObjCDealloc.cpp | 4 +- .../Checkers/CheckSecuritySyntaxOnly.cpp | 115 +- .../lib/StaticAnalyzer/Checkers/ChrootChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/ConversionChecker.cpp | 5 +- .../StaticAnalyzer/Checkers/DeadStoresChecker.cpp | 2 +- .../lib/StaticAnalyzer/Checkers/DebugCheckers.cpp | 2 +- .../Checkers/DeleteWithNonVirtualDtorChecker.cpp | 155 - .../Checkers/DynamicTypePropagation.cpp | 20 +- .../Checkers/EnumCastOutOfRangeChecker.cpp | 62 +- .../lib/StaticAnalyzer/Checkers/ErrnoModeling.cpp | 12 - .../lib/StaticAnalyzer/Checkers/ErrnoModeling.h | 16 +- .../Checkers/ExprInspectionChecker.cpp | 18 +- .../Checkers/FixedAddressChecker.cpp | 15 +- .../Checkers/FuchsiaHandleChecker.cpp | 15 +- .../Checkers/GCDAntipatternChecker.cpp | 2 +- .../lib/StaticAnalyzer/Checkers/GTestChecker.cpp | 8 +- .../Checkers/GenericTaintChecker.cpp | 27 +- .../Checkers/IteratorRangeChecker.cpp | 2 +- .../Checkers/IvarInvalidationChecker.cpp | 4 +- .../Checkers/LocalizationChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/MallocChecker.cpp | 51 +- .../Checkers/MmapWriteExecChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/NSErrorChecker.cpp | 4 +- .../Checkers/NonNullParamChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/NullabilityChecker.cpp | 14 +- .../StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp | 14 +- .../Checkers/ObjCMissingSuperCallChecker.cpp | 4 +- .../Checkers/ObjCPropertyChecker.cpp | 2 +- .../Checkers/PointerArithChecker.cpp | 29 +- .../StaticAnalyzer/Checkers/PointerSubChecker.cpp | 14 +- .../RetainCountChecker/RetainCountChecker.h | 1 - .../RetainCountChecker/RetainCountDiagnostics.cpp | 3 - .../Checkers/ReturnPointerRangeChecker.cpp | 13 +- .../StaticAnalyzer/Checkers/ReturnUndefChecker.cpp | 22 +- .../Checkers/SimpleStreamChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/SmartPtrModeling.cpp | 3 +- .../Checkers/StackAddrEscapeChecker.cpp | 37 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 149 +- .../StaticAnalyzer/Checkers/StdVariantChecker.cpp | 298 + .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 238 +- .../StaticAnalyzer/Checkers/TaggedUnionModeling.h | 99 + .../Checkers/TestAfterDivZeroChecker.cpp | 4 +- .../StaticAnalyzer/Checkers/UndefBranchChecker.cpp | 6 +- .../Checkers/UndefCapturedBlockVarChecker.cpp | 2 +- .../StaticAnalyzer/Checkers/UndefResultChecker.cpp | 74 +- .../Checkers/UndefinedArraySubscriptChecker.cpp | 2 +- .../Checkers/UndefinedAssignmentChecker.cpp | 3 +- .../UninitializedObjectChecker.cpp | 4 +- .../lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp | 3 +- .../lib/StaticAnalyzer/Checkers/VforkChecker.cpp | 9 +- .../Checkers/WebKit/NoUncountedMembersChecker.cpp | 3 +- .../Checkers/WebKit/PtrTypesSemantics.cpp | 65 +- .../Checkers/WebKit/PtrTypesSemantics.h | 8 +- .../WebKit/RefCntblBaseVirtualDtorChecker.cpp | 49 +- .../Checkers/WebKit/UncountedCallArgsChecker.cpp | 3 +- .../Checkers/WebKit/UncountedLocalVarsChecker.cpp | 1 - .../clang/lib/StaticAnalyzer/Checkers/Yaml.h | 2 +- .../Checkers/cert/InvalidPtrChecker.cpp | 145 +- .../lib/StaticAnalyzer/Core/BasicValueFactory.cpp | 12 +- .../clang/lib/StaticAnalyzer/Core/BugReporter.cpp | 35 +- .../StaticAnalyzer/Core/BugReporterVisitors.cpp | 61 +- .../lib/StaticAnalyzer/Core/BugSuppression.cpp | 169 + .../clang/lib/StaticAnalyzer/Core/CallEvent.cpp | 41 +- .../lib/StaticAnalyzer/Core/CheckerContext.cpp | 5 +- .../StaticAnalyzer/Core/CheckerRegistryData.cpp | 6 +- .../lib/StaticAnalyzer/Core/ConstraintManager.cpp | 2 +- .../clang/lib/StaticAnalyzer/Core/CoreEngine.cpp | 4 +- .../lib/StaticAnalyzer/Core/DynamicExtent.cpp | 72 +- .../clang/lib/StaticAnalyzer/Core/ExprEngine.cpp | 18 +- .../clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp | 3 +- .../lib/StaticAnalyzer/Core/ExprEngineCXX.cpp | 18 +- .../Core/ExprEngineCallAndReturn.cpp | 2 +- .../lib/StaticAnalyzer/Core/ExprEngineObjC.cpp | 35 +- .../lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp | 29 +- .../clang/lib/StaticAnalyzer/Core/LoopWidening.cpp | 6 +- .../lib/StaticAnalyzer/Core/PlistDiagnostics.cpp | 2 +- .../StaticAnalyzer/Core/RangeConstraintManager.cpp | 22 + .../clang/lib/StaticAnalyzer/Core/SValBuilder.cpp | 51 +- .../clang/lib/StaticAnalyzer/Core/SVals.cpp | 87 +- .../Core/SimpleConstraintManager.cpp | 4 +- .../lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp | 144 +- .../clang/lib/StaticAnalyzer/Core/Store.cpp | 2 +- .../StaticAnalyzer/Frontend/AnalysisConsumer.cpp | 62 +- .../StaticAnalyzer/Frontend/AnalyzerHelpFlags.cpp | 10 +- .../StaticAnalyzer/Frontend/CheckerRegistry.cpp | 4 +- .../lib/StaticAnalyzer/Frontend/ModelInjector.cpp | 3 +- .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 105 +- .../clang/lib/Tooling/ASTDiff/ASTDiff.cpp | 2 +- .../clang/lib/Tooling/ArgumentsAdjusters.cpp | 14 +- .../clang/lib/Tooling/CompilationDatabase.cpp | 2 +- .../clang/lib/Tooling/Core/Replacement.cpp | 5 +- .../DependencyScanningFilesystem.cpp | 4 +- .../DependencyScanningService.cpp | 4 +- .../DependencyScanning/DependencyScanningTool.cpp | 23 +- .../DependencyScanningWorker.cpp | 98 +- .../DependencyScanning/ModuleDepCollector.cpp | 233 +- .../clang/lib/Tooling/DumpTool/ClangSrcLocDump.cpp | 6 +- .../lib/Tooling/Inclusions/HeaderAnalysis.cpp | 11 +- .../lib/Tooling/Inclusions/HeaderIncludes.cpp | 18 +- *** 875030 LINES SKIPPED *** From nobody Sat Apr 20 10:34:12 2024 X-Original-To: dev-commits-src-branches@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 4VM7D53rKJz5HWQg; Sat, 20 Apr 2024 10:34:13 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7D51WWsz4SHZ; Sat, 20 Apr 2024 10:34:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609253; 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=Veq6gKSYnOWXFT871moTpRY44jMQLpo8LkwUwy4O/N0=; b=RjHf0+WH+9EEHcqvIFjgtSWq9Jm3WhXdXLaWBth3HXhL/EVWJHF+yhiLb4LSbyLXU4Bgj+ UWEHd4cF+GBtUqVFlwh4TyEHqSCQys3FJl5v2NDMCLP85zwT6aNN2cYz4dScPpdqSC8qvd 492KUTHoFYndhxguViAPtnU4pOlybfV7ahcy8i2p7/HzmuBYBV1FgsnzNGpT8vluVycKZ8 9SlLaiBMi6gY6g8gOVZI+1AgM76dVwFNDCIPCgtYagRVWcQRXxKm97XLpYCABdfWZ+m0Gm FTlu9nvl7R7tVcG5ME3YUpkND0BRtWSEFQjNBySluRZ2mVuQtbQfNuXfGxhCCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609253; a=rsa-sha256; cv=none; b=VgCMP+FvuQMxw/tYDF5/C54s9Va1u/vQC2Er8PAIsHy265sk+1LfjQF419TkYRsYPSgq1T 99qAV6JS4EFMceSkmSHJnrVyXRxlxWBSEAPjMpQyocaP83+QZPeOYaesmos/fu40J0iBjH 1QYIAk3wJaRhbJVMVJP6EVmOLSZ9dwSUFQzuSBIMsE1U/Fm7eW5Biri4AaD/DWNCxLXsGi Be31aH1NL13udaDlIr7rn+/DnOnduXtY/wXVqsqaVwGmqCux7F/KLzrBnG9G4DV3UZlR+2 +jDXi5CBjYzFbbtfKZJdAavkhnvcqpvRlGTt3CWUVqSnW9PlvCCgzYgspOv6Fg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609253; 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=Veq6gKSYnOWXFT871moTpRY44jMQLpo8LkwUwy4O/N0=; b=TZvSvBkfgySRC1gbkfNWUxV50sBgdwHDcQwFx6hLCgxFux0Ms8a/rcbxbZF0JIUoRgQAzs x1H9z7A1UsfyjQga1ipuCntUhgDHx2BrK8wzuBH/DIEgz/YBUGtvPc5vASm6jLSSpoDVnv RdR1HHL/Un1kmwNzFpbeBEy/MiVmeWZZosDq2ObyxIT9FznJ6hYqR9HVhGNOK2mlgtAMzc qq6XSKYeBcQD16MfKKO3jAxxdHn7ACPRPlWtiGa0+uDALNqPjhwW30tkgquwsnT6yOHPjz JC72/uzENQzZI2XipIwjZHZZ8Zdt+tcCn6G2Wzcmo5166qUQKzs3iLWR0mqkuA== 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 4VM7D50J9tzZCQ; Sat, 20 Apr 2024 10:34:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYCRT013229; Sat, 20 Apr 2024 10:34:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYCg4013226; Sat, 20 Apr 2024 10:34:12 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:12 GMT Message-Id: <202404201034.43KAYCg4013226@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: b168c9a3e534 - stable/13 - Tentatively apply https://github.com/llvm/llvm-project/pull/76175 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: b168c9a3e534d5d65fd7070687b85e27217e2bcd Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=b168c9a3e534d5d65fd7070687b85e27217e2bcd commit b168c9a3e534d5d65fd7070687b85e27217e2bcd Author: Dimitry Andric AuthorDate: 2023-12-21 22:30:02 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:23:57 +0000 Tentatively apply https://github.com/llvm/llvm-project/pull/76175 This fixes libsa including compiler-rt builtins. PR: 276104 MFC after: 1 month (cherry picked from commit 3d68ee6cbdb244de9fab1df8a2525d2fa592571e) --- contrib/llvm-project/compiler-rt/lib/builtins/int_types.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h b/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h index 18bf0a7f3bf9..0d4ed224fa72 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h +++ b/contrib/llvm-project/compiler-rt/lib/builtins/int_types.h @@ -139,7 +139,6 @@ typedef union { udwords u; double f; } double_bits; -#endif typedef struct { #if _YUGA_LITTLE_ENDIAN @@ -220,7 +219,6 @@ typedef union { #define CRT_HAS_TF_MODE #endif -#if CRT_HAS_FLOATING_POINT #if __STDC_VERSION__ >= 199901L typedef float _Complex Fcomplex; typedef double _Complex Dcomplex; From nobody Sat Apr 20 10:34:14 2024 X-Original-To: dev-commits-src-branches@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 4VM7D95fL8z5HW6c; Sat, 20 Apr 2024 10:34:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7D92NmHz4SFp; Sat, 20 Apr 2024 10:34:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609257; 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=GVseG7fsSbY6Wwa6g5LS0DP72wx1PX5nYcgTPNfndUU=; b=CaTC+zX5zPFuibudKjATusdyLLlW2vjZvYjYq/K3VoY/qiX4UabFJ88+EVt1b9p+Zn+DB6 tCp3htzFH8LKrTnRAREV/tEd9OcoB8JNLxh//7kxihl/+Wp6SQDtHYY/pns/HB1sumRdDm KMvVbOSVqGYABZO1BVLIerzDxsZM82iiVNXMmuh4wUha3yOSHDz8qrHvPusjRDLUtVdo3F QWGiU+dYCu2fFBMDM6I7wFoL4zrumE35HgoSBnyiK/8pFtPjSry4sbLlGFoNyiUCHsfKy/ 5ZYj6HzRxI1EJQoGOobJPRnOrZ1OJoXVtgoCq/WOAjjn3Tr7KSFnvULds/0ubg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609257; a=rsa-sha256; cv=none; b=tKMYvh1ymARJID3PPrX+ZYfNSSBVhMftmmw1b2xjaUpQaEBMHphvwtKna0taZutmnNXgEb i3usrfPgxozGEui/6+8sVgoYPQWjyVMYi40suL//bzH2XFwQil3u7jU0XYiatF47WFu3kY lPbRDAImDBkgeUwun6cBfL2TOEO5FwZSYCER4bNRj5f7U3A1e/0aJh5OejLje+lOcpduWR bHoXDyohhOEpxUeNDIRLN3+c5bV5gNxo6a4omXDL2+YFK/NTwEGI9+//5O8p7CdzwgB702 ZRgwl3hntsXkAMzowIaKP0EDtso6kWZwUcPrMaeHAepXXiQj3XObj2ELahV72g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609257; 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=GVseG7fsSbY6Wwa6g5LS0DP72wx1PX5nYcgTPNfndUU=; b=dI2+HjZ5rkJLZyKju1yk1evvmbOXFXMw9X2slTslg03TRBaVvbr0sXnESW6HehefYng/bE apcNs8nCcBwSjZhi6UAZcs11bdStORnal6Lgv/KxDMur3noVCUDYsMVy7hlA1NskPF8lGF LkT8dIZRRwXmLn1QZMar0M1omiwTl5JiV0A4wpF3/v/Ej8mOEFWVNujGrOeYWuYh7WgA9v X8kFfvRx9IKv5+U9xAqIDgWczckVUYSOtpANUc5x1Vsid3ulg+ZpAmoRphbm2d6Yt/M6Gx X9PlQh2un+PvIATyvHde7iCDlgBCAd8ZDN6iQoQziaCDfoq03xoy8zqEgEpBVg== 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 4VM7D91gFVzZBM; Sat, 20 Apr 2024 10:34:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYHPA013281; Sat, 20 Apr 2024 10:34:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYEPQ013265; Sat, 20 Apr 2024 10:34:14 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:14 GMT Message-Id: <202404201034.43KAYEPQ013265@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: a20559610011 - stable/13 - Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: a2055961001193c277cffdfffba259ca8fad3835 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a2055961001193c277cffdfffba259ca8fad3835 commit a2055961001193c277cffdfffba259ca8fad3835 Author: Dimitry Andric AuthorDate: 2023-12-25 17:35:41 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:23:58 +0000 Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-15692-g007ed0dccd6a. PR: 276104 MFC after: 1 month (cherry picked from commit cb14a3fe5122c879eae1fb480ed7ce82a699ddb6) --- .../llvm-project/clang/include/clang/AST/Decl.h | 27 +- .../clang/include/clang/AST/DeclBase.h | 10 - .../clang/include/clang/AST/RecursiveASTVisitor.h | 7 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 80 +- .../clang/Analysis/FlowSensitive/RecordOps.h | 12 +- .../include/clang/Analysis/FlowSensitive/Value.h | 40 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 18 - .../clang/include/clang/Basic/AttrDocs.td | 66 - .../clang/include/clang/Basic/DiagnosticGroups.td | 6 +- .../include/clang/Basic/DiagnosticParseKinds.td | 4 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 28 +- .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Basic/OpenACCKinds.h | 24 + .../clang/include/clang/Basic/PlistSupport.h | 3 +- .../clang/include/clang/Basic/TargetInfo.h | 1 + .../clang/include/clang/Basic/Version.h | 3 + .../clang/include/clang/Basic/arm_sme.td | 317 + .../clang/include/clang/Basic/arm_sve.td | 1399 +-- .../clang/include/clang/Basic/riscv_vector.td | 18 +- .../clang/include/clang/Driver/Options.td | 5 +- .../include/clang/Interpreter/CodeCompletion.h | 25 +- .../clang/include/clang/Interpreter/Interpreter.h | 1 + .../llvm-project/clang/include/clang/Sema/Sema.h | 7 +- .../clang/include/clang/Sema/TypoCorrection.h | 12 +- .../clang/include/clang/Serialization/ASTReader.h | 2 + .../clang/include/clang/Serialization/ASTWriter.h | 88 +- .../include/clang/Support/RISCVVIntrinsicUtils.h | 7 +- .../clang/lib/APINotes/APINotesManager.cpp | 2 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 48 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 12 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 41 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 74 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 83 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 90 +- .../Models/UncheckedOptionalAccessModel.cpp | 31 +- .../clang/lib/Analysis/FlowSensitive/RecordOps.cpp | 33 +- .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 25 +- .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 2 +- .../clang/lib/Basic/Targets/AArch64.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 4 + .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 1 + contrib/llvm-project/clang/lib/Basic/Version.cpp | 18 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 3 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 209 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 129 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 26 +- .../clang/lib/CodeGen/CGHLSLRuntime.cpp | 63 +- .../llvm-project/clang/lib/CodeGen/CGHLSLRuntime.h | 2 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 148 +- .../clang/lib/CodeGen/CodeGenFunction.h | 16 - .../clang/lib/CodeGen/CodeGenModule.cpp | 10 +- .../clang/lib/CodeGen/Targets/AArch64.cpp | 2 + .../clang/lib/Driver/ToolChains/AIX.cpp | 6 + .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 4 + .../clang/lib/Driver/ToolChains/Clang.cpp | 15 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 59 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 127 +- .../clang/lib/Format/ContinuationIndenter.cpp | 20 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 8 +- .../clang/lib/Format/MatchFilePath.cpp | 122 + .../llvm-project/clang/lib/Format/MatchFilePath.h | 22 + .../clang/lib/Format/TokenAnnotator.cpp | 3 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 6 +- contrib/llvm-project/clang/lib/Headers/adcintrin.h | 160 + contrib/llvm-project/clang/lib/Headers/adxintrin.h | 143 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 8 +- .../clang/lib/Headers/riscv_bitmanip.h | 24 +- .../clang/lib/Interpreter/CodeCompletion.cpp | 223 +- .../clang/lib/Interpreter/Interpreter.cpp | 4 + .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 22 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 92 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 77 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 45 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 90 - contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 28 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 4 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 214 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 13 + .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 19 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 7 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 28 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 52 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 405 +- .../clang/lib/Serialization/ASTWriter.cpp | 15 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 574 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 241 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 86 + .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 2 +- .../clang/tools/clang-repl/ClangRepl.cpp | 24 +- .../clang/utils/TableGen/NeonEmitter.cpp | 28 + .../clang/utils/TableGen/RISCVVEmitter.cpp | 40 +- .../clang/utils/TableGen/SveEmitter.cpp | 87 + .../llvm-project/clang/utils/TableGen/TableGen.cpp | 18 + .../clang/utils/TableGen/TableGenBackends.h | 3 + .../compiler-rt/lib/asan/asan_posix.cpp | 51 +- .../compiler-rt/lib/asan/asan_rtl_x86_64.S | 10 + .../compiler-rt/lib/builtins/cpu_model/aarch64.c | 151 + .../lib/builtins/cpu_model/aarch64/fmv/android.inc | 36 + .../lib/builtins/cpu_model/aarch64/fmv/apple.inc | 69 + .../lib/builtins/cpu_model/aarch64/fmv/freebsd.inc | 27 + .../lib/builtins/cpu_model/aarch64/fmv/fuchsia.inc | 51 + .../lib/builtins/cpu_model/aarch64/fmv/mrs.inc | 196 + .../lib/builtins/cpu_model/aarch64/fmv/sysauxv.inc | 21 + .../cpu_model/aarch64/fmv/unimplemented.inc | 8 + .../lib/builtins/cpu_model/aarch64/hwcap.inc | 180 + .../cpu_model/aarch64/lse_atomics/android.inc | 28 + .../cpu_model/aarch64/lse_atomics/freebsd.inc | 5 + .../cpu_model/aarch64/lse_atomics/fuchsia.inc | 12 + .../cpu_model/aarch64/lse_atomics/sysauxv.inc | 6 + .../compiler-rt/lib/builtins/cpu_model/cpu_model.h | 41 + .../lib/builtins/{cpu_model.c => cpu_model/x86.c} | 692 +- .../lib/dfsan/dfsan_chained_origin_depot.cpp | 6 + .../lib/dfsan/dfsan_chained_origin_depot.h | 3 + .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 12 +- .../compiler-rt/lib/hwasan/hwasan_linux.cpp | 46 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 68 +- .../compiler-rt/lib/lsan/lsan_posix.cpp | 33 +- .../lib/msan/msan_chained_origin_depot.cpp | 8 +- .../lib/msan/msan_chained_origin_depot.h | 4 +- .../compiler-rt/lib/msan/msan_linux.cpp | 32 +- .../compiler-rt/lib/orc/macho_platform.cpp | 4 + .../lib/profile/InstrProfilingPlatformWindows.c | 10 + .../sanitizer_chained_origin_depot.cpp | 6 +- .../sanitizer_chained_origin_depot.h | 4 +- .../lib/sanitizer_common/sanitizer_stack_store.cpp | 9 +- .../lib/sanitizer_common/sanitizer_stackdepot.cpp | 8 +- .../lib/sanitizer_common/sanitizer_stackdepot.h | 4 +- .../sanitizer_common/sanitizer_stackdepotbase.h | 9 +- .../sanitizer_common/sanitizer_suppressions.cpp | 5 +- .../sanitizer_symbolizer_posix_libcdep.cpp | 27 +- .../symbolizer/sanitizer_symbolize.cpp | 6 +- .../compiler-rt/lib/scudo/standalone/combined.h | 13 - .../lib/tsan/rtl/tsan_interceptors_posix.cpp | 19 + .../libcxx/include/__algorithm/binary_search.h | 20 +- .../libcxx/include/__algorithm/comp_ref_type.h | 66 +- .../libcxx/include/__algorithm/copy_backward.h | 16 +- .../libcxx/include/__algorithm/copy_if.h | 23 +- .../libcxx/include/__algorithm/copy_move_common.h | 25 +- .../libcxx/include/__algorithm/copy_n.h | 59 +- .../libcxx/include/__algorithm/equal.h | 29 +- .../libcxx/include/__algorithm/equal_range.h | 11 +- .../llvm-project/libcxx/include/__algorithm/fill.h | 26 +- .../libcxx/include/__algorithm/fill_n.h | 20 +- .../llvm-project/libcxx/include/__algorithm/find.h | 19 + .../libcxx/include/__algorithm/find_end.h | 92 +- .../libcxx/include/__algorithm/find_first_of.h | 21 +- .../llvm-project/libcxx/include/__algorithm/fold.h | 125 + .../libcxx/include/__algorithm/for_each_n.h | 5 +- .../libcxx/include/__algorithm/generate.h | 10 +- .../libcxx/include/__algorithm/generate_n.h | 16 +- .../libcxx/include/__algorithm/half_positive.h | 14 +- .../libcxx/include/__algorithm/in_found_result.h | 2 +- .../libcxx/include/__algorithm/in_fun_result.h | 2 +- .../libcxx/include/__algorithm/in_in_out_result.h | 14 +- .../libcxx/include/__algorithm/in_in_result.h | 6 +- .../libcxx/include/__algorithm/in_out_out_result.h | 14 +- .../libcxx/include/__algorithm/in_out_result.h | 8 +- .../libcxx/include/__algorithm/includes.h | 31 +- .../libcxx/include/__algorithm/inplace_merge.h | 304 +- .../libcxx/include/__algorithm/is_heap.h | 20 +- .../libcxx/include/__algorithm/is_heap_until.h | 56 +- .../libcxx/include/__algorithm/is_partitioned.h | 21 +- .../libcxx/include/__algorithm/is_permutation.h | 177 +- .../libcxx/include/__algorithm/is_sorted.h | 20 +- .../libcxx/include/__algorithm/is_sorted_until.h | 33 +- .../libcxx/include/__algorithm/iter_swap.h | 3 +- .../include/__algorithm/iterator_operations.h | 67 +- .../include/__algorithm/lexicographical_compare.h | 49 +- .../libcxx/include/__algorithm/lower_bound.h | 15 +- .../libcxx/include/__algorithm/make_heap.h | 16 +- .../libcxx/include/__algorithm/make_projected.h | 47 +- .../llvm-project/libcxx/include/__algorithm/max.h | 39 +- .../libcxx/include/__algorithm/max_element.h | 33 +- .../libcxx/include/__algorithm/merge.h | 65 +- .../llvm-project/libcxx/include/__algorithm/min.h | 39 +- .../libcxx/include/__algorithm/min_element.h | 23 +- .../libcxx/include/__algorithm/min_max_result.h | 2 +- .../libcxx/include/__algorithm/minmax.h | 48 +- .../libcxx/include/__algorithm/minmax_element.h | 31 +- .../libcxx/include/__algorithm/mismatch.h | 25 +- .../llvm-project/libcxx/include/__algorithm/move.h | 3 +- .../libcxx/include/__algorithm/move_backward.h | 6 +- .../libcxx/include/__algorithm/next_permutation.h | 61 +- .../libcxx/include/__algorithm/nth_element.h | 386 +- .../libcxx/include/__algorithm/partial_sort.h | 39 +- .../libcxx/include/__algorithm/partial_sort_copy.h | 94 +- .../libcxx/include/__algorithm/partition.h | 84 +- .../libcxx/include/__algorithm/partition_copy.h | 36 +- .../libcxx/include/__algorithm/partition_point.h | 34 +- .../libcxx/include/__algorithm/pop_heap.h | 18 +- .../libcxx/include/__algorithm/prev_permutation.h | 64 +- .../libcxx/include/__algorithm/push_heap.h | 24 +- .../libcxx/include/__algorithm/ranges_contains.h | 61 + .../libcxx/include/__algorithm/ranges_max.h | 5 +- .../libcxx/include/__algorithm/ranges_min.h | 5 +- .../libcxx/include/__algorithm/ranges_minmax.h | 5 +- .../libcxx/include/__algorithm/remove.h | 26 +- .../libcxx/include/__algorithm/remove_copy.h | 20 +- .../libcxx/include/__algorithm/remove_copy_if.h | 20 +- .../libcxx/include/__algorithm/remove_if.h | 26 +- .../libcxx/include/__algorithm/replace.h | 12 +- .../libcxx/include/__algorithm/replace_copy.h | 23 +- .../libcxx/include/__algorithm/replace_copy_if.h | 23 +- .../libcxx/include/__algorithm/replace_if.h | 12 +- .../libcxx/include/__algorithm/reverse.h | 40 +- .../libcxx/include/__algorithm/reverse_copy.h | 12 +- .../libcxx/include/__algorithm/rotate.h | 264 +- .../libcxx/include/__algorithm/rotate_copy.h | 8 +- .../libcxx/include/__algorithm/sample.h | 83 +- .../libcxx/include/__algorithm/search.h | 123 +- .../libcxx/include/__algorithm/search_n.h | 96 +- .../libcxx/include/__algorithm/set_difference.h | 2 +- .../libcxx/include/__algorithm/shift_left.h | 43 +- .../libcxx/include/__algorithm/shift_right.h | 123 +- .../libcxx/include/__algorithm/shuffle.h | 127 +- .../libcxx/include/__algorithm/sift_down.h | 141 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 245 +- .../libcxx/include/__algorithm/sort_heap.h | 16 +- .../libcxx/include/__algorithm/stable_partition.h | 487 +- .../libcxx/include/__algorithm/stable_sort.h | 332 +- .../libcxx/include/__algorithm/swap_ranges.h | 9 +- .../libcxx/include/__algorithm/transform.h | 29 +- .../uniform_random_bit_generator_adaptor.h | 14 +- .../libcxx/include/__algorithm/unwrap_iter.h | 10 +- .../llvm-project/libcxx/include/__atomic/atomic.h | 812 +- .../libcxx/include/__atomic/atomic_base.h | 321 +- .../libcxx/include/__atomic/atomic_flag.h | 246 +- .../libcxx/include/__atomic/atomic_lock_free.h | 52 +- .../libcxx/include/__atomic/atomic_sync.h | 90 +- .../libcxx/include/__atomic/check_memory_order.h | 22 +- .../libcxx/include/__atomic/contention_t.h | 4 +- .../libcxx/include/__atomic/cxx_atomic_impl.h | 560 +- .../llvm-project/libcxx/include/__atomic/fence.h | 16 +- .../libcxx/include/__atomic/kill_dependency.h | 6 +- .../libcxx/include/__atomic/memory_order.h | 11 +- contrib/llvm-project/libcxx/include/__availability | 82 +- .../llvm-project/libcxx/include/__bit/bit_cast.h | 3 +- .../llvm-project/libcxx/include/__bit/bit_ceil.h | 2 +- .../llvm-project/libcxx/include/__bit/byteswap.h | 11 +- contrib/llvm-project/libcxx/include/__bit/countl.h | 84 +- contrib/llvm-project/libcxx/include/__bit/countr.h | 17 +- contrib/llvm-project/libcxx/include/__bit/endian.h | 2 +- .../llvm-project/libcxx/include/__bit/popcount.h | 15 +- .../libcxx/include/__chrono/calendar.h | 12 +- .../libcxx/include/__chrono/convert_to_timespec.h | 15 +- contrib/llvm-project/libcxx/include/__chrono/day.h | 91 +- .../libcxx/include/__chrono/duration.h | 693 +- .../libcxx/include/__chrono/file_clock.h | 24 +- .../libcxx/include/__chrono/formatter.h | 63 +- .../libcxx/include/__chrono/hh_mm_ss.h | 117 +- .../include/__chrono/high_resolution_clock.h | 3 +- .../libcxx/include/__chrono/literals.h | 24 +- .../llvm-project/libcxx/include/__chrono/month.h | 94 +- .../libcxx/include/__chrono/month_weekday.h | 104 +- .../libcxx/include/__chrono/monthday.h | 134 +- .../libcxx/include/__chrono/steady_clock.h | 18 +- .../libcxx/include/__chrono/system_clock.h | 24 +- .../libcxx/include/__chrono/time_point.h | 186 +- .../llvm-project/libcxx/include/__chrono/weekday.h | 201 +- .../llvm-project/libcxx/include/__chrono/year.h | 104 +- .../libcxx/include/__chrono/year_month.h | 102 +- .../libcxx/include/__chrono/year_month_day.h | 460 +- .../libcxx/include/__chrono/year_month_weekday.h | 369 +- .../include/__compare/common_comparison_category.h | 27 +- .../__compare/compare_partial_order_fallback.h | 68 +- .../__compare/compare_strong_order_fallback.h | 62 +- .../libcxx/include/__compare/compare_three_way.h | 19 +- .../include/__compare/compare_three_way_result.h | 23 +- .../__compare/compare_weak_order_fallback.h | 62 +- .../libcxx/include/__compare/ordering.h | 164 +- .../libcxx/include/__compare/partial_order.h | 63 +- .../libcxx/include/__compare/strong_order.h | 173 +- .../include/__compare/three_way_comparable.h | 36 +- .../libcxx/include/__compare/weak_order.h | 115 +- contrib/llvm-project/libcxx/include/__config | 4 +- .../libcxx/include/__coroutine/coroutine_handle.h | 257 +- .../libcxx/include/__coroutine/coroutine_traits.h | 9 +- .../include/__coroutine/noop_coroutine_handle.h | 103 +- .../include/__coroutine/trivial_awaitables.h | 18 +- .../libcxx/include/__debug_utils/randomize_range.h | 3 +- .../libcxx/include/__expected/expected.h | 205 +- .../libcxx/include/__filesystem/copy_options.h | 50 +- .../libcxx/include/__filesystem/directory_entry.h | 251 +- .../include/__filesystem/directory_iterator.h | 73 +- .../include/__filesystem/directory_options.h | 44 +- .../libcxx/include/__filesystem/file_status.h | 28 +- .../libcxx/include/__filesystem/file_type.h | 14 +- .../libcxx/include/__filesystem/operations.h | 224 +- .../libcxx/include/__filesystem/path.h | 652 +- .../libcxx/include/__filesystem/path_iterator.h | 50 +- .../libcxx/include/__filesystem/perm_options.h | 39 +- .../libcxx/include/__filesystem/perms.h | 56 +- .../__filesystem/recursive_directory_iterator.h | 85 +- .../libcxx/include/__filesystem/u8path.h | 48 +- .../llvm-project/libcxx/include/__format/buffer.h | 52 +- .../libcxx/include/__format/concepts.h | 2 +- .../libcxx/include/__format/format_arg.h | 32 +- .../libcxx/include/__format/format_arg_store.h | 10 +- .../libcxx/include/__format/format_args.h | 5 +- .../libcxx/include/__format/format_context.h | 72 +- .../libcxx/include/__format/format_error.h | 17 +- .../libcxx/include/__format/format_functions.h | 184 +- .../libcxx/include/__format/format_parse_context.h | 30 +- .../libcxx/include/__format/format_string.h | 20 +- .../libcxx/include/__format/formatter.h | 4 +- .../include/__format/formatter_floating_point.h | 92 +- .../libcxx/include/__format/formatter_integer.h | 37 +- .../libcxx/include/__format/formatter_integral.h | 77 +- .../libcxx/include/__format/formatter_output.h | 58 +- .../libcxx/include/__format/formatter_pointer.h | 9 +- .../libcxx/include/__format/formatter_string.h | 18 +- .../include/__format/parser_std_format_spec.h | 79 +- .../llvm-project/libcxx/include/__format/unicode.h | 10 +- .../libcxx/include/__format/write_escaped.h | 19 +- .../libcxx/include/__functional/binary_function.h | 16 +- .../libcxx/include/__functional/binary_negate.h | 25 +- .../libcxx/include/__functional/bind.h | 385 +- .../libcxx/include/__functional/bind_back.h | 34 +- .../libcxx/include/__functional/bind_front.h | 21 +- .../libcxx/include/__functional/binder1st.h | 35 +- .../libcxx/include/__functional/binder2nd.h | 35 +- .../include/__functional/boyer_moore_searcher.h | 128 +- .../libcxx/include/__functional/compose.h | 25 +- .../libcxx/include/__functional/default_searcher.h | 31 +- .../libcxx/include/__functional/function.h | 1645 ++-- .../libcxx/include/__functional/hash.h | 682 +- .../libcxx/include/__functional/identity.h | 20 +- .../libcxx/include/__functional/invoke.h | 30 +- .../libcxx/include/__functional/is_transparent.h | 3 +- .../libcxx/include/__functional/mem_fn.h | 36 +- .../libcxx/include/__functional/mem_fun_ref.h | 183 +- .../libcxx/include/__functional/not_fn.h | 25 +- .../libcxx/include/__functional/operations.h | 540 +- .../libcxx/include/__functional/perfect_forward.h | 48 +- .../__functional/pointer_to_binary_function.h | 20 +- .../__functional/pointer_to_unary_function.h | 20 +- .../include/__functional/ranges_operations.h | 24 +- .../include/__functional/reference_wrapper.h | 97 +- .../libcxx/include/__functional/unary_function.h | 12 +- .../libcxx/include/__functional/unary_negate.h | 25 +- .../libcxx/include/__functional/weak_result_type.h | 225 +- contrib/llvm-project/libcxx/include/__fwd/get.h | 48 +- contrib/llvm-project/libcxx/include/__fwd/span.h | 3 +- .../libcxx/include/__fwd/string_view.h | 8 +- .../llvm-project/libcxx/include/__fwd/subrange.h | 2 +- contrib/llvm-project/libcxx/include/__hash_table | 3216 +++---- contrib/llvm-project/libcxx/include/__ios/fpos.h | 9 +- .../libcxx/include/__iterator/access.h | 67 +- .../libcxx/include/__iterator/advance.h | 57 +- .../include/__iterator/back_insert_iterator.h | 53 +- .../libcxx/include/__iterator/common_iterator.h | 211 +- .../libcxx/include/__iterator/concepts.h | 338 +- .../libcxx/include/__iterator/counted_iterator.h | 200 +- .../llvm-project/libcxx/include/__iterator/data.h | 32 +- .../libcxx/include/__iterator/default_sentinel.h | 2 +- .../libcxx/include/__iterator/distance.h | 49 +- .../llvm-project/libcxx/include/__iterator/empty.h | 19 +- .../libcxx/include/__iterator/erase_if_container.h | 4 +- .../include/__iterator/front_insert_iterator.h | 51 +- .../include/__iterator/incrementable_traits.h | 33 +- .../include/__iterator/indirectly_comparable.h | 3 +- .../libcxx/include/__iterator/insert_iterator.h | 57 +- .../libcxx/include/__iterator/istream_iterator.h | 95 +- .../include/__iterator/istreambuf_iterator.h | 131 +- .../libcxx/include/__iterator/iter_move.h | 68 +- .../libcxx/include/__iterator/iter_swap.h | 100 +- .../libcxx/include/__iterator/iterator.h | 16 +- .../libcxx/include/__iterator/iterator_traits.h | 397 +- .../libcxx/include/__iterator/mergeable.h | 15 +- .../libcxx/include/__iterator/move_iterator.h | 419 +- .../libcxx/include/__iterator/move_sentinel.h | 21 +- .../llvm-project/libcxx/include/__iterator/next.h | 13 +- .../libcxx/include/__iterator/ostream_iterator.h | 55 +- .../include/__iterator/ostreambuf_iterator.h | 61 +- .../libcxx/include/__iterator/permutable.h | 3 +- .../llvm-project/libcxx/include/__iterator/prev.h | 13 +- .../libcxx/include/__iterator/readable_traits.h | 46 +- .../libcxx/include/__iterator/reverse_access.h | 60 +- .../libcxx/include/__iterator/reverse_iterator.h | 366 +- .../llvm-project/libcxx/include/__iterator/size.h | 32 +- .../libcxx/include/__iterator/sortable.h | 4 +- .../include/__iterator/unreachable_sentinel.h | 5 +- .../libcxx/include/__iterator/wrap_iter.h | 258 +- contrib/llvm-project/libcxx/include/__locale | 2434 +++-- .../locale_base_api/bsd_locale_defaults.h | 28 +- .../locale_base_api/bsd_locale_fallbacks.h | 144 +- .../__locale_dir/locale_base_api/locale_guard.h | 67 +- contrib/llvm-project/libcxx/include/__mbstate_t.h | 16 +- .../libcxx/include/__memory/addressof.h | 35 +- .../libcxx/include/__memory/aligned_alloc.h | 42 +- .../libcxx/include/__memory/allocate_at_least.h | 10 +- .../libcxx/include/__memory/allocation_guard.h | 98 +- .../libcxx/include/__memory/allocator.h | 331 +- .../libcxx/include/__memory/allocator_arg_t.h | 45 +- .../libcxx/include/__memory/allocator_destructor.h | 24 +- .../libcxx/include/__memory/allocator_traits.h | 379 +- .../libcxx/include/__memory/assume_aligned.h | 3 +- .../libcxx/include/__memory/auto_ptr.h | 94 +- .../include/__memory/builtin_new_allocator.h | 23 +- .../libcxx/include/__memory/compressed_pair.h | 81 +- .../libcxx/include/__memory/concepts.h | 15 +- .../libcxx/include/__memory/construct_at.h | 65 +- .../libcxx/include/__memory/destruct_n.h | 61 +- .../libcxx/include/__memory/pointer_traits.h | 174 +- .../libcxx/include/__memory/ranges_construct_at.h | 28 +- .../__memory/ranges_uninitialized_algorithms.h | 89 +- .../libcxx/include/__memory/raw_storage_iterator.h | 66 +- .../libcxx/include/__memory/shared_ptr.h | 2495 ++--- .../libcxx/include/__memory/temp_value.h | 32 +- .../libcxx/include/__memory/temporary_buffer.h | 78 +- .../include/__memory/uninitialized_algorithms.h | 461 +- .../libcxx/include/__memory/unique_ptr.h | 373 +- .../libcxx/include/__memory/uses_allocator.h | 27 +- contrib/llvm-project/libcxx/include/__node_handle | 224 +- .../libcxx/include/__numeric/accumulate.h | 28 +- .../libcxx/include/__numeric/adjacent_difference.h | 57 +- .../libcxx/include/__numeric/exclusive_scan.h | 2 +- .../libcxx/include/__numeric/gcd_lcm.h | 82 +- .../libcxx/include/__numeric/inclusive_scan.h | 9 +- .../libcxx/include/__numeric/inner_product.h | 34 +- .../llvm-project/libcxx/include/__numeric/iota.h | 10 +- .../libcxx/include/__numeric/midpoint.h | 61 +- .../libcxx/include/__numeric/partial_sum.h | 53 +- .../llvm-project/libcxx/include/__numeric/reduce.h | 8 +- .../include/__numeric/transform_exclusive_scan.h | 33 +- .../include/__numeric/transform_inclusive_scan.h | 42 +- .../libcxx/include/__numeric/transform_reduce.h | 24 +- .../include/__random/bernoulli_distribution.h | 160 +- .../include/__random/binomial_distribution.h | 291 +- .../libcxx/include/__random/cauchy_distribution.h | 194 +- .../include/__random/chi_squared_distribution.h | 161 +- .../libcxx/include/__random/clamp_to_integral.h | 22 +- .../libcxx/include/__random/discard_block_engine.h | 256 +- .../include/__random/discrete_distribution.h | 340 +- .../include/__random/exponential_distribution.h | 171 +- .../include/__random/extreme_value_distribution.h | 196 +- .../include/__random/fisher_f_distribution.h | 194 +- .../libcxx/include/__random/gamma_distribution.h | 280 +- .../libcxx/include/__random/generate_canonical.h | 28 +- .../include/__random/geometric_distribution.h | 157 +- .../include/__random/independent_bits_engine.h | 331 +- .../libcxx/include/__random/is_seed_sequence.h | 8 +- .../libcxx/include/__random/is_valid.h | 53 +- .../include/__random/linear_congruential_engine.h | 491 +- .../llvm-project/libcxx/include/__random/log2.h | 39 +- .../include/__random/lognormal_distribution.h | 189 +- .../include/__random/mersenne_twister_engine.h | 1224 ++- .../__random/negative_binomial_distribution.h | 232 +- .../libcxx/include/__random/normal_distribution.h | 278 +- .../__random/piecewise_constant_distribution.h | 508 +- .../__random/piecewise_linear_distribution.h | 537 +- .../libcxx/include/__random/poisson_distribution.h | 392 +- .../libcxx/include/__random/random_device.h | 87 +- .../llvm-project/libcxx/include/__random/ranlux.h | 2 +- .../libcxx/include/__random/seed_seq.h | 231 +- .../libcxx/include/__random/shuffle_order_engine.h | 355 +- .../include/__random/student_t_distribution.h | 169 +- .../include/__random/subtract_with_carry_engine.h | 468 +- .../include/__random/uniform_int_distribution.h | 403 +- .../__random/uniform_random_bit_generator.h | 14 +- .../include/__random/uniform_real_distribution.h | 194 +- .../libcxx/include/__random/weibull_distribution.h | 185 +- .../llvm-project/libcxx/include/__ranges/access.h | 237 +- contrib/llvm-project/libcxx/include/__ranges/all.h | 55 +- .../libcxx/include/__ranges/common_view.h | 83 +- .../libcxx/include/__ranges/concepts.h | 126 +- .../llvm-project/libcxx/include/__ranges/counted.h | 62 +- .../llvm-project/libcxx/include/__ranges/data.h | 91 +- .../libcxx/include/__ranges/drop_view.h | 303 +- .../llvm-project/libcxx/include/__ranges/empty.h | 71 +- .../libcxx/include/__ranges/empty_view.h | 40 +- .../libcxx/include/__ranges/enable_view.h | 11 +- .../libcxx/include/__ranges/filter_view.h | 381 +- .../libcxx/include/__ranges/iota_view.h | 569 +- .../libcxx/include/__ranges/istream_view.h | 3 +- .../libcxx/include/__ranges/join_view.h | 647 +- .../libcxx/include/__ranges/lazy_split_view.h | 245 +- .../include/__ranges/non_propagating_cache.h | 129 +- .../libcxx/include/__ranges/owning_view.h | 106 +- .../libcxx/include/__ranges/range_adaptor.h | 32 +- .../llvm-project/libcxx/include/__ranges/rbegin.h | 67 +- .../libcxx/include/__ranges/ref_view.h | 80 +- .../llvm-project/libcxx/include/__ranges/rend.h | 71 +- .../libcxx/include/__ranges/reverse_view.h | 297 +- .../libcxx/include/__ranges/single_view.h | 16 +- .../llvm-project/libcxx/include/__ranges/size.h | 52 +- .../libcxx/include/__ranges/subrange.h | 356 +- .../libcxx/include/__ranges/take_view.h | 194 +- .../libcxx/include/__ranges/transform_view.h | 300 +- .../libcxx/include/__ranges/view_interface.h | 94 +- .../llvm-project/libcxx/include/__ranges/views.h | 2 +- .../libcxx/include/__ranges/zip_view.h | 235 +- contrib/llvm-project/libcxx/include/__split_buffer | 604 +- .../libcxx/include/__string/char_traits.h | 1093 ++- .../libcxx/include/__system_error/errc.h | 172 +- .../libcxx/include/__thread/formatter.h | 62 +- .../libcxx/include/__thread/poll_with_backoff.h | 37 +- .../libcxx/include/__thread/this_thread.h | 63 +- .../llvm-project/libcxx/include/__thread/thread.h | 324 +- .../libcxx/include/__thread/timed_backoff_policy.h | 28 +- .../libcxx/include/__threading_support | 410 +- contrib/llvm-project/libcxx/include/__tree | 3613 ++++---- .../libcxx/include/__tuple/make_tuple_types.h | 24 +- .../libcxx/include/__tuple/sfinae_helpers.h | 136 +- .../libcxx/include/__tuple/tuple_element.h | 64 +- .../libcxx/include/__tuple/tuple_indices.h | 10 +- .../libcxx/include/__tuple/tuple_like_ext.h | 24 +- .../libcxx/include/__tuple/tuple_size.h | 47 +- .../libcxx/include/__tuple/tuple_types.h | 3 +- .../libcxx/include/__type_traits/datasizeof.h | 11 +- .../libcxx/include/__utility/as_const.h | 4 +- .../llvm-project/libcxx/include/__utility/cmp.h | 73 +- .../libcxx/include/__utility/convert_to_integral.h | 50 +- .../libcxx/include/__utility/exchange.h | 14 +- .../libcxx/include/__utility/in_place.h | 12 +- .../libcxx/include/__utility/integer_sequence.h | 104 +- .../libcxx/include/__utility/is_pointer_in_range.h | 2 +- .../llvm-project/libcxx/include/__utility/pair.h | 1162 +-- .../libcxx/include/__utility/piecewise_construct.h | 4 +- .../libcxx/include/__utility/priority_tag.h | 6 +- .../libcxx/include/__utility/rel_ops.h | 41 +- .../libcxx/include/__utility/to_underlying.h | 6 +- .../libcxx/include/__utility/unreachable.h | 4 +- .../libcxx/include/__variant/monostate.h | 2 +- .../llvm-project/libcxx/include/__verbose_abort | 4 +- contrib/llvm-project/libcxx/include/algorithm | 30 + contrib/llvm-project/libcxx/include/any | 788 +- contrib/llvm-project/libcxx/include/array | 535 +- contrib/llvm-project/libcxx/include/barrier | 356 +- contrib/llvm-project/libcxx/include/bitset | 1290 ++- contrib/llvm-project/libcxx/include/cctype | 29 +- contrib/llvm-project/libcxx/include/cmath | 173 +- contrib/llvm-project/libcxx/include/codecvt | 776 +- contrib/llvm-project/libcxx/include/complex | 1921 ++-- .../llvm-project/libcxx/include/condition_variable | 223 +- contrib/llvm-project/libcxx/include/cstddef | 52 +- contrib/llvm-project/libcxx/include/ctype.h | 28 +- contrib/llvm-project/libcxx/include/cuchar | 2 +- contrib/llvm-project/libcxx/include/deque | 3722 ++++---- contrib/llvm-project/libcxx/include/errno.h | 522 +- contrib/llvm-project/libcxx/include/expected | 1 - .../libcxx/include/experimental/__config | 22 +- .../libcxx/include/experimental/__memory | 90 +- .../libcxx/include/experimental/__simd/abi_tag.h | 55 - .../include/experimental/__simd/aligned_tag.h | 13 +- .../include/experimental/__simd/declaration.h | 52 +- .../experimental/__simd/internal_declaration.h | 41 - .../libcxx/include/experimental/__simd/scalar.h | 2 +- .../libcxx/include/experimental/__simd/simd.h | 2 - .../libcxx/include/experimental/__simd/simd_mask.h | 2 - .../libcxx/include/experimental/__simd/traits.h | 15 +- .../libcxx/include/experimental/__simd/vec_ext.h | 6 +- .../libcxx/include/experimental/iterator | 69 +- .../libcxx/include/experimental/propagate_const | 305 +- .../llvm-project/libcxx/include/experimental/simd | 1 - .../libcxx/include/experimental/type_traits | 69 +- .../libcxx/include/experimental/utility | 2 +- contrib/llvm-project/libcxx/include/ext/__hash | 130 +- contrib/llvm-project/libcxx/include/ext/hash_map | 1132 +-- contrib/llvm-project/libcxx/include/ext/hash_set | 634 +- contrib/llvm-project/libcxx/include/fenv.h | 70 +- contrib/llvm-project/libcxx/include/float.h | 12 +- contrib/llvm-project/libcxx/include/forward_list | 2031 ++-- contrib/llvm-project/libcxx/include/fstream | 2095 ++--- contrib/llvm-project/libcxx/include/future | 2551 +++-- .../llvm-project/libcxx/include/initializer_list | 71 +- contrib/llvm-project/libcxx/include/inttypes.h | 10 +- contrib/llvm-project/libcxx/include/iomanip | 754 +- contrib/llvm-project/libcxx/include/ios | 953 +- contrib/llvm-project/libcxx/include/iosfwd | 65 +- contrib/llvm-project/libcxx/include/istream | 2051 ++-- contrib/llvm-project/libcxx/include/latch | 98 +- contrib/llvm-project/libcxx/include/limits | 1078 ++- contrib/llvm-project/libcxx/include/list | 2390 ++--- contrib/llvm-project/libcxx/include/locale | 6071 ++++++------ contrib/llvm-project/libcxx/include/locale.h | 2 +- contrib/llvm-project/libcxx/include/map | 2618 +++--- contrib/llvm-project/libcxx/include/math.h | 81 +- .../libcxx/include/module.modulemap.in | 4 +- contrib/llvm-project/libcxx/include/mutex | 467 +- contrib/llvm-project/libcxx/include/new | 220 +- contrib/llvm-project/libcxx/include/numbers | 93 +- contrib/llvm-project/libcxx/include/optional | 1759 ++-- contrib/llvm-project/libcxx/include/ostream | 1349 ++- contrib/llvm-project/libcxx/include/print | 14 +- contrib/llvm-project/libcxx/include/queue | 1008 +- contrib/llvm-project/libcxx/include/ranges | 2 +- contrib/llvm-project/libcxx/include/ratio | 396 +- contrib/llvm-project/libcxx/include/regex | 8356 +++++++---------- .../llvm-project/libcxx/include/scoped_allocator | 821 +- contrib/llvm-project/libcxx/include/semaphore | 193 +- contrib/llvm-project/libcxx/include/set | 1577 ++-- contrib/llvm-project/libcxx/include/span | 701 +- contrib/llvm-project/libcxx/include/sstream | 1274 ++- contrib/llvm-project/libcxx/include/stack | 349 +- contrib/llvm-project/libcxx/include/stdatomic.h | 18 +- contrib/llvm-project/libcxx/include/stdbool.h | 10 +- contrib/llvm-project/libcxx/include/stddef.h | 28 +- contrib/llvm-project/libcxx/include/stdexcept | 232 +- contrib/llvm-project/libcxx/include/stdint.h | 6 +- contrib/llvm-project/libcxx/include/stdio.h | 36 +- contrib/llvm-project/libcxx/include/stdlib.h | 86 +- contrib/llvm-project/libcxx/include/streambuf | 530 +- contrib/llvm-project/libcxx/include/string | 4686 +++++----- contrib/llvm-project/libcxx/include/string.h | 2 +- contrib/llvm-project/libcxx/include/string_view | 1135 +-- contrib/llvm-project/libcxx/include/strstream | 334 +- contrib/llvm-project/libcxx/include/thread | 2 +- contrib/llvm-project/libcxx/include/tuple | 2126 ++--- contrib/llvm-project/libcxx/include/typeindex | 65 +- contrib/llvm-project/libcxx/include/typeinfo | 242 +- contrib/llvm-project/libcxx/include/uchar.h | 12 +- contrib/llvm-project/libcxx/include/unordered_map | 3111 +++---- contrib/llvm-project/libcxx/include/unordered_set | 1953 ++-- contrib/llvm-project/libcxx/include/valarray | 4682 ++++------ contrib/llvm-project/libcxx/include/variant | 1235 +-- contrib/llvm-project/libcxx/include/vector | 3840 ++++---- contrib/llvm-project/libcxx/include/version | 6 +- contrib/llvm-project/libcxx/include/wchar.h | 157 +- contrib/llvm-project/libcxx/include/wctype.h | 43 +- .../llvm-project/libcxx/modules/std/algorithm.inc | 16 +- .../llvm-project/libcxx/modules/std/ostream.inc | 5 +- contrib/llvm-project/libcxx/src/any.cpp | 16 +- contrib/llvm-project/libcxx/src/atomic.cpp | 216 +- contrib/llvm-project/libcxx/src/barrier.cpp | 106 +- contrib/llvm-project/libcxx/src/bind.cpp | 23 +- contrib/llvm-project/libcxx/src/call_once.cpp | 62 +- contrib/llvm-project/libcxx/src/charconv.cpp | 33 +- contrib/llvm-project/libcxx/src/chrono.cpp | 118 +- .../llvm-project/libcxx/src/condition_variable.cpp | 95 +- .../libcxx/src/condition_variable_destructor.cpp | 20 +- contrib/llvm-project/libcxx/src/exception.cpp | 28 +- .../libcxx/src/filesystem/directory_entry.cpp | 9 +- .../libcxx/src/filesystem/directory_iterator.cpp | 84 +- contrib/llvm-project/libcxx/src/filesystem/error.h | 24 +- .../libcxx/src/filesystem/file_descriptor.h | 53 +- .../libcxx/src/filesystem/filesystem_clock.cpp | 20 +- .../libcxx/src/filesystem/filesystem_error.cpp | 12 +- .../libcxx/src/filesystem/int128_builtins.cpp | 14 +- .../libcxx/src/filesystem/operations.cpp | 323 +- .../llvm-project/libcxx/src/filesystem/path.cpp | 79 +- .../libcxx/src/filesystem/path_parser.h | 58 +- .../libcxx/src/filesystem/posix_compat.h | 231 +- .../libcxx/src/filesystem/time_utils.h | 164 +- contrib/llvm-project/libcxx/src/functional.cpp | 10 +- contrib/llvm-project/libcxx/src/future.cpp | 319 +- contrib/llvm-project/libcxx/src/hash.cpp | 899 +- .../libcxx/src/include/apple_availability.h | 34 +- .../libcxx/src/include/atomic_support.h | 156 +- .../llvm-project/libcxx/src/include/config_elast.h | 18 +- .../llvm-project/libcxx/src/include/refstring.h | 137 +- contrib/llvm-project/libcxx/src/include/ryu/ryu.h | 1 - .../libcxx/src/include/sso_allocator.h | 81 +- contrib/llvm-project/libcxx/src/ios.cpp | 569 +- contrib/llvm-project/libcxx/src/iostream.cpp | 165 +- contrib/llvm-project/libcxx/src/locale.cpp | 9786 +++++++++----------- contrib/llvm-project/libcxx/src/memory.cpp | 229 +- contrib/llvm-project/libcxx/src/mutex.cpp | 207 +- .../llvm-project/libcxx/src/mutex_destructor.cpp | 20 +- contrib/llvm-project/libcxx/src/optional.cpp | 14 +- contrib/llvm-project/libcxx/src/ostream.cpp | 42 + contrib/llvm-project/libcxx/src/random.cpp | 181 +- contrib/llvm-project/libcxx/src/random_shuffle.cpp | 35 +- contrib/llvm-project/libcxx/src/regex.cpp | 293 +- contrib/llvm-project/libcxx/src/std_stream.h | 572 +- contrib/llvm-project/libcxx/src/string.cpp | 368 +- .../libcxx/src/support/ibm/mbsnrtowcs.cpp | 30 +- .../libcxx/src/support/ibm/wcsnrtombs.cpp | 27 +- .../libcxx/src/support/ibm/xlocale_zos.cpp | 44 +- .../src/support/runtime/exception_fallback.ipp | 139 +- .../src/support/runtime/exception_glibcxx.ipp | 18 +- .../src/support/runtime/exception_libcxxabi.ipp | 15 +- .../src/support/runtime/exception_libcxxrt.ipp | 11 +- .../libcxx/src/support/runtime/exception_msvc.ipp | 145 +- .../support/runtime/exception_pointer_cxxabi.ipp | 73 +- .../support/runtime/exception_pointer_glibcxx.ipp | 61 +- .../src/support/runtime/exception_pointer_msvc.ipp | 22 +- .../runtime/exception_pointer_unimplemented.ipp | 43 +- .../src/support/runtime/stdexcept_default.ipp | 8 +- .../src/support/runtime/stdexcept_vcruntime.ipp | 2 +- contrib/llvm-project/libcxx/src/system_error.cpp | 225 +- contrib/llvm-project/libcxx/src/thread.cpp | 222 +- contrib/llvm-project/libcxx/src/typeinfo.cpp | 30 +- contrib/llvm-project/libcxx/src/valarray.cpp | 56 +- contrib/llvm-project/libcxx/src/variant.cpp | 6 +- contrib/llvm-project/libcxx/src/vector.cpp | 8 +- contrib/llvm-project/libcxx/src/verbose_abort.cpp | 6 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 20 + contrib/llvm-project/lld/ELF/InputSection.cpp | 22 +- contrib/llvm-project/lld/MachO/InputFiles.h | 2 +- contrib/llvm-project/lld/MachO/Options.td | 2 +- .../lldb/bindings/python/python-typemaps.swig | 2 +- .../lldb/include/lldb/Core/ValueObject.h | 8 - .../lldb/include/lldb/Host/HostGetOpt.h | 4 - .../lldb/include/lldb/Utility/FileSpec.h | 19 - contrib/llvm-project/lldb/source/API/SBValue.cpp | 11 +- .../llvm-project/lldb/source/Core/ValueObject.cpp | 40 - .../lldb/source/Host/common/FileSystem.cpp | 1 - .../lldb/source/Interpreter/CommandInterpreter.cpp | 6 +- .../SymbolFile/DWARF/DWARFASTParserClang.cpp | 2 +- .../lldb/source/Target/JITLoaderList.cpp | 2 +- .../llvm-project/llvm/include/llvm/ADT/StringRef.h | 8 +- contrib/llvm-project/llvm/include/llvm/ADT/Twine.h | 2 +- .../llvm/include/llvm/Analysis/LazyValueInfo.h | 9 +- .../llvm/include/llvm/Analysis/TargetLibraryInfo.h | 10 + .../include/llvm/Analysis/TargetTransformInfo.h | 4 + .../llvm/include/llvm/Analysis/ValueLattice.h | 5 +- .../llvm/include/llvm/Analysis/ValueTracking.h | 5 + .../llvm/include/llvm/Analysis/VecFuncs.def | 2 + .../llvm/include/llvm/Analysis/VectorUtils.h | 10 + .../llvm/include/llvm/CodeGen/AccelTable.h | 8 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 9 +- .../llvm/include/llvm/CodeGen/LowerEmuTLS.h | 29 + .../include/llvm/CodeGen/MachinePassRegistry.def | 7 +- .../llvm/include/llvm/CodeGen/MacroFusion.h | 12 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 2 + .../llvm/include/llvm/CodeGen/TargetLowering.h | 6 + .../llvm/CodeGen/TargetLoweringObjectFileImpl.h | 2 + .../llvm/include/llvm/Frontend/HLSL/HLSLResource.h | 27 +- .../llvm-project/llvm/include/llvm/IR/Constants.h | 7 +- .../llvm/include/llvm/IR/DiagnosticHandler.h | 1 + .../llvm/IR/GenericConvergenceVerifierImpl.h | 13 +- .../llvm/include/llvm/IR/GlobalValue.h | 4 + .../llvm/include/llvm/IR/IntrinsicInst.h | 24 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 28 +- .../llvm/include/llvm/IR/IntrinsicsRISCV.td | 2 +- .../llvm/include/llvm/IR/PatternMatch.h | 26 + .../llvm-project/llvm/include/llvm/MC/MCAsmInfo.h | 3 +- .../llvm/include/llvm/MC/MCTargetOptions.h | 2 + .../llvm/include/llvm/Object/ELFObjectFile.h | 1 + .../llvm-project/llvm/include/llvm/Object/Wasm.h | 1 - .../llvm/ProfileData/Coverage/CoverageMapping.h | 2 +- .../llvm/include/llvm/ProfileData/InstrProf.h | 26 +- .../include/llvm/ProfileData/RawMemProfReader.h | 11 +- .../llvm/include/llvm/ProfileData/SampleProf.h | 4 +- .../llvm/include/llvm/Support/CommandLine.h | 27 +- .../llvm/include/llvm/Support/YAMLTraits.h | 17 +- .../llvm/include/llvm/Support/raw_ostream.h | 49 - .../llvm/include/llvm/Support/raw_socket_stream.h | 66 + .../llvm/TargetParser/AArch64TargetParser.h | 9 +- .../llvm/TargetParser/ARMTargetParserCommon.h | 1 + .../llvm/include/llvm/TextAPI/DylibReader.h | 48 + .../llvm/include/llvm/TextAPI/Record.h | 13 +- .../llvm/include/llvm/TextAPI/RecordVisitor.h | 54 + .../llvm/include/llvm/TextAPI/RecordsSlice.h | 14 +- .../llvm/include/llvm/TextAPI/TextAPIError.h | 3 +- .../llvm-project/llvm/include/llvm/TextAPI/Utils.h | 34 + .../llvm/include/llvm/Transforms/IPO/Attributor.h | 10 + .../llvm/Transforms/IPO/ProfiledCallGraph.h | 5 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 2 +- .../llvm/lib/Analysis/LazyValueInfo.cpp | 18 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 2 +- .../llvm/lib/Analysis/MemoryDependenceAnalysis.cpp | 18 +- .../llvm/lib/Analysis/ScalarEvolution.cpp | 7 +- .../llvm/lib/Analysis/TargetLibraryInfo.cpp | 10 + .../llvm/lib/Analysis/VFABIDemangling.cpp | 4 +- .../llvm/lib/Analysis/ValueTracking.cpp | 126 +- .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 28 + .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 4 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 1 + .../CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 62 +- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.h | 45 +- .../llvm/lib/CodeGen/LiveRangeEdit.cpp | 3 +- .../llvm-project/llvm/lib/CodeGen/LowerEmuTLS.cpp | 53 +- .../llvm/lib/CodeGen/MachineInstrBundle.cpp | 6 +- .../llvm-project/llvm/lib/CodeGen/MacroFusion.cpp | 12 +- .../llvm-project/llvm/lib/CodeGen/RegAllocFast.cpp | 139 +- .../llvm/lib/CodeGen/RegisterClassInfo.cpp | 3 +- .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 57 +- .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 211 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 19 +- .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 3 +- .../CodeGen/SelectionDAG/FunctionLoweringInfo.cpp | 3 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 18 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 23 + .../CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp | 17 + .../llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h | 2 + .../lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp | 12 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 6 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 3 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 24 +- .../llvm/lib/CodeGen/ShadowStackGCLowering.cpp | 7 +- .../lib/CodeGen/TargetLoweringObjectFileImpl.cpp | 7 + .../llvm/lib/CodeGen/TargetPassConfig.cpp | 1 + .../llvm/lib/CodeGen/TwoAddressInstructionPass.cpp | 3 +- .../lib/ExecutionEngine/JITLink/MachO_arm64.cpp | 32 +- .../lib/ExecutionEngine/JITLink/MachO_x86_64.cpp | 32 +- .../llvm/lib/Frontend/HLSL/HLSLResource.cpp | 17 +- contrib/llvm-project/llvm/lib/IR/ConstantFold.cpp | 2 +- contrib/llvm-project/llvm/lib/IR/Globals.cpp | 12 +- contrib/llvm-project/llvm/lib/IR/LLVMContext.cpp | 11 +- contrib/llvm-project/llvm/lib/IR/Metadata.cpp | 2 +- contrib/llvm-project/llvm/lib/IR/Type.cpp | 2 + contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 11 +- contrib/llvm-project/llvm/lib/MC/MCAsmStreamer.cpp | 5 +- contrib/llvm-project/llvm/lib/MC/MCContext.cpp | 14 +- contrib/llvm-project/llvm/lib/MC/MCExpr.cpp | 24 +- .../llvm/lib/ObjCopy/ELF/ELFObject.cpp | 2 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 69 + .../llvm/lib/Object/ModuleSymbolTable.cpp | 16 +- .../llvm/lib/Object/WasmObjectFile.cpp | 52 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassRegistry.def | 1 + .../llvm/lib/ProfileData/InstrProf.cpp | 36 +- .../llvm/lib/ProfileData/InstrProfReader.cpp | 9 +- .../llvm/lib/ProfileData/RawMemProfReader.cpp | 25 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 78 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 83 +- contrib/llvm-project/llvm/lib/Support/Signals.cpp | 2 +- .../llvm-project/llvm/lib/Support/raw_ostream.cpp | 163 +- .../llvm/lib/Support/raw_socket_stream.cpp | 179 + .../llvm/lib/Target/AArch64/AArch64.td | 19 +- .../llvm/lib/Target/AArch64/AArch64Combine.td | 11 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 18 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 11 +- .../llvm/lib/Target/AArch64/AArch64InstrFormats.td | 126 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 36 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.h | 3 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.td | 75 +- .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 229 + .../Target/AArch64/AArch64MachineFunctionInfo.cpp | 28 +- .../Target/AArch64/AArch64MachineFunctionInfo.h | 18 + .../llvm/lib/Target/AArch64/AArch64PointerAuth.cpp | 86 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 61 +- .../llvm/lib/Target/AArch64/AArch64SchedA64FX.td | 9 +- .../lib/Target/AArch64/AArch64SchedNeoverseN2.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV1.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV2.td | 2 +- .../lib/Target/AArch64/AArch64SystemOperands.td | 27 + .../Target/AArch64/AsmParser/AArch64AsmParser.cpp | 47 + .../AArch64/Disassembler/AArch64Disassembler.cpp | 18 + .../AArch64/GISel/AArch64InstructionSelector.cpp | 62 - .../AArch64/GISel/AArch64PostLegalizerLowering.cpp | 21 + .../AArch64/MCTargetDesc/AArch64AsmBackend.cpp | 14 + .../MCTargetDesc/AArch64ELFObjectWriter.cpp | 4 + .../AArch64/MCTargetDesc/AArch64FixupKinds.h | 5 + .../AArch64/MCTargetDesc/AArch64MCCodeEmitter.cpp | 29 + .../llvm/lib/Target/AArch64/SMEInstrFormats.td | 26 +- .../llvm/lib/Target/AArch64/SVEInstrFormats.td | 31 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 4 +- .../llvm/lib/Target/AMDGPU/AMDGPUIGroupLP.cpp | 29 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 37 +- .../Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp | 8 +- .../llvm/lib/Target/AMDGPU/AMDGPULibCalls.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp | 18 + .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 7 + .../Target/AMDGPU/AMDGPUTargetTransformInfo.cpp | 8 + .../lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h | 10 + .../llvm/lib/Target/AMDGPU/DSInstructions.td | 12 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 5 + .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 21 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 20 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 79 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 3 + .../llvm/lib/Target/ARM/ARMFrameLowering.cpp | 33 +- .../llvm/lib/Target/ARM/ARMFrameLowering.h | 3 + .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 58 + .../llvm/lib/Target/ARM/ARMISelLowering.h | 10 + .../llvm/lib/Target/ARM/ARMInstrVFP.td | 1 + .../llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp | 6 +- .../llvm/lib/Target/DirectX/DXILResource.cpp | 92 +- .../llvm/lib/Target/DirectX/DXILResource.h | 37 +- .../DirectX/DXILWriter/DXILBitcodeWriter.cpp | 3 +- .../lib/Target/Hexagon/HexagonConstPropagation.cpp | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 6 +- .../Target/Hexagon/HexagonLoopIdiomRecognition.cpp | 6 +- .../Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp | 2 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 78 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 9 +- .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 4 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 9 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | 8 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.td | 3 + .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 7 +- .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 9 + .../llvm/lib/Target/RISCV/RISCVFeatures.td | 86 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 3 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 182 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 7 +- .../llvm/lib/Target/RISCV/RISCVInstrFormats.td | 9 + .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 8 - .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 125 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td | 12 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZvk.td | 2 +- .../llvm/lib/Target/RISCV/RISCVMacroFusion.cpp | 82 +- .../llvm/lib/Target/RISCV/RISCVProcessors.td | 27 +- .../llvm/lib/Target/RISCV/RISCVSchedSiFive7.td | 1 + .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 18 +- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 2 +- .../llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp | 4 +- .../llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp | 6 +- .../llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp | 6 +- .../llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp | 2 +- .../llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.h | 2 +- .../llvm/lib/Target/SPIRV/SPIRVPreLegalizer.cpp | 2 +- .../SystemZ/MCTargetDesc/SystemZMCAsmInfo.cpp | 1 + .../llvm/lib/Target/SystemZ/SystemZAsmPrinter.cpp | 35 +- .../lib/Target/SystemZ/SystemZFrameLowering.cpp | 6 + .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 3 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 10 + .../llvm/lib/Target/SystemZ/SystemZISelLowering.h | 8 +- .../llvm-project/llvm/lib/Target/TargetMachine.cpp | 4 +- .../llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp | 36 +- .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 2 +- .../llvm/lib/Target/X86/X86FastISel.cpp | 7 +- .../llvm/lib/Target/X86/X86FloatingPoint.cpp | 3 +- .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 31 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 36 +- .../llvm/lib/Target/X86/X86InsertPrefetch.cpp | 6 +- .../llvm/lib/Target/X86/X86InstrAMX.td | 30 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 1082 +-- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1457 ++- .../llvm/lib/Target/X86/X86InstrAsmAlias.td | 13 + .../llvm/lib/Target/X86/X86InstrCompiler.td | 17 + .../llvm/lib/Target/X86/X86InstrFPStack.td | 8 +- .../llvm/lib/Target/X86/X86InstrFormats.td | 7 +- .../llvm/lib/Target/X86/X86InstrInfo.cpp | 8 +- .../llvm-project/llvm/lib/Target/X86/X86InstrKL.td | 22 +- .../llvm/lib/Target/X86/X86InstrMMX.td | 24 +- .../llvm/lib/Target/X86/X86InstrMisc.td | 211 +- .../llvm/lib/Target/X86/X86InstrRAOINT.td | 8 +- .../llvm/lib/Target/X86/X86InstrSGX.td | 6 +- .../llvm/lib/Target/X86/X86InstrSNP.td | 12 +- .../llvm/lib/Target/X86/X86InstrSSE.td | 952 +- .../llvm/lib/Target/X86/X86InstrShiftRotate.td | 28 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 141 +- .../llvm/lib/Target/X86/X86InstrTBM.td | 4 +- .../llvm/lib/Target/X86/X86InstrTDX.td | 14 +- .../llvm/lib/Target/X86/X86InstrTSX.td | 4 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 284 +- .../llvm/lib/Target/X86/X86InstrVMX.td | 38 +- .../llvm/lib/Target/X86/X86InstrXOP.td | 28 +- .../llvm/lib/Target/X86/X86MacroFusion.cpp | 3 +- .../llvm/lib/Target/X86/X86Subtarget.cpp | 9 +- .../lib/TargetParser/ARMTargetParserCommon.cpp | 6 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 52 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 15 +- .../llvm/lib/TextAPI/BinaryReader/DylibReader.cpp | 429 + .../llvm/lib/TextAPI/RecordVisitor.cpp | 65 + .../llvm-project/llvm/lib/TextAPI/RecordsSlice.cpp | 120 +- contrib/llvm-project/llvm/lib/TextAPI/Utils.cpp | 40 + .../lib/ToolDrivers/llvm-dlltool/DlltoolDriver.cpp | 2 +- .../lib/Transforms/IPO/AttributorAttributes.cpp | 53 +- .../llvm/lib/Transforms/IPO/OpenMPOpt.cpp | 18 +- .../llvm/lib/Transforms/IPO/SampleProfile.cpp | 13 +- .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 49 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 59 +- .../Transforms/InstCombine/InstCombineInternal.h | 17 +- .../InstCombine/InstCombineMulDivRem.cpp | 7 + .../Transforms/InstCombine/InstCombineSelect.cpp | 4 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 134 +- .../InstCombine/InstCombineVectorOps.cpp | 44 +- .../InstCombine/InstructionCombining.cpp | 106 +- .../Instrumentation/AddressSanitizer.cpp | 2 +- .../lib/Transforms/Instrumentation/MemProfiler.cpp | 2 +- .../Instrumentation/SanitizerCoverage.cpp | 2 +- .../lib/Transforms/Scalar/ConstantHoisting.cpp | 5 +- .../Transforms/Scalar/ConstraintElimination.cpp | 75 +- .../Scalar/CorrelatedValuePropagation.cpp | 6 +- .../lib/Transforms/Scalar/DFAJumpThreading.cpp | 2 +- .../llvm/lib/Transforms/Scalar/GVN.cpp | 2 +- .../llvm/lib/Transforms/Scalar/LoopFlatten.cpp | 5 +- .../lib/Transforms/Scalar/LoopStrengthReduce.cpp | 2 +- *** 229499 LINES SKIPPED *** From nobody Sat Apr 20 10:34:18 2024 X-Original-To: dev-commits-src-branches@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 4VM7DC4kzDz5HWNY; Sat, 20 Apr 2024 10:34:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DB3Dlwz4SZ6; Sat, 20 Apr 2024 10:34:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609258; 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=YXWLNksSoWBKl9Jdo0Fkj9iV/sAG8sEX+0Ct2qJ8CHk=; b=bzQLPcmOnvhBOmZX7oBH+jKfHT08+QSj9tMKNLaDUAm6NQAFbPhbzkyQgVjFxlxnO8aX4F 8K7S1GXJdzpwMKvz4eSz78GfvfFFXO/VM/1XpjW+quzuaSWvR0AMnWFzWmD8YLsvhOl/Wt GB89momZFlKZYlBvWJXd174bWLRwtEL4FEV9GD3cBjJHX2XecVC7alIHSx5ghZEE9tkCBw i4PO+jsYpZO9ZnrR1KZB1PcPsY66KFHSS8Z5RNkxQQMJZXYGWpBG3uWBp0yL/5dpWT4t8H Yc3xy5/9Q4Y9cLXaVARxMQK/zoXtPCYlT0lTbRbdfDrhct/CvutVBucyayQ/0w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609258; a=rsa-sha256; cv=none; b=IZKseHcIPz6vCsFMiyQGnJedwxIx23AIrPAnlJm9NSgjvjsITJeIaHUIWC8zAST6zfF7qy iu/0r1E1su75ZlzGUlvNNozyEYbyVeX5AVyUwGu61VKBt7lNh0gL9RM9zngOzhjcsCght6 CjW4MVRNh41rT8Ik1xal1rNkvD6QMaQ1Uu+zPe0shlSgNsfr+/NLtEoopb/q0nEV6Az2AQ yRZXsFoe3z3AilWKdX10dyQkJBvIlwjomRge0ID8jZ0YVqT4s0xSYxjYW5vu7FZotuoo3k nhcKdjXFE5x/vw77OKf8o6YgWFi0MT5/3WtrcS2No6jIscUw9qtkOjC8dl/I/Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609258; 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=YXWLNksSoWBKl9Jdo0Fkj9iV/sAG8sEX+0Ct2qJ8CHk=; b=efyNnQZ1F1EJyjS9qRZgMbIJo8LiV2piepvaPe09cwvgbKmAR59nAW1vLXYzDD1ZFXcDtg UlYr3rBpIMncDwDwlWN/FIQDVDcSojiEjYyrS59UN7e/99rtjA6ozPSK3FUQkPjwJPggiI ST8Ic0T+er8aqYql1Bj0zdSByK+nXH1t5xLUg1ixBCuZywV4aPYNEB/+sY7B5H+sqKShSJ V4B+reTNh0TatohWwP8rAPYGeqjMJDbxP24yYDznBjk38QGmDQZbTnwUYCs6tqCPwTIRl5 v7/gzzgBgghsb7jPn1pKIvWIXxbhTymH5RWaDmt2hwfOj+9rcLnis32cR3uKQQ== 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 4VM7DB2ShWzZJC; Sat, 20 Apr 2024 10:34:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYISS013332; Sat, 20 Apr 2024 10:34:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYILV013329; Sat, 20 Apr 2024 10:34:18 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:18 GMT Message-Id: <202404201034.43KAYILV013329@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: 92d4d6f1f60e - stable/13 - Revert commit 0e46b49de433 from llvm-project (by Matt Arsenault): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 92d4d6f1f60e5d9cb2c7e0dd5d632987e54741e8 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=92d4d6f1f60e5d9cb2c7e0dd5d632987e54741e8 commit 92d4d6f1f60e5d9cb2c7e0dd5d632987e54741e8 Author: Dimitry Andric AuthorDate: 2024-01-02 16:07:31 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:23:59 +0000 Revert commit 0e46b49de433 from llvm-project (by Matt Arsenault): Reapply "RegisterCoalescer: Add implicit-def of super register when coalescing SUBREG_TO_REG" This reverts commit c398fa009a47eb24f88383d5e911e59e70f8db86. PPC backend was fixed in 2f82662ce901c6666fceb9c6c5e0de216a1c9667 Since it causes an assertion failure building /sys/dev/fb/vga.c: https://github.com/llvm/llvm-project/issues/76416 PR: 276104 MFC after: 1 month (cherry picked from commit edc2dc17b1f2dfe45dc85e6cc0ff54bca1ac8214) --- .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 51 ++++------------------ 1 file changed, 9 insertions(+), 42 deletions(-) diff --git a/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp b/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp index 3fbb93795075..cbb1a74049fb 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/RegisterCoalescer.cpp @@ -305,11 +305,7 @@ namespace { /// number if it is not zero. If DstReg is a physical register and the /// existing subregister number of the def / use being updated is not zero, /// make sure to set it to the correct physical subregister. - /// - /// If \p IsSubregToReg, we are coalescing a DstReg = SUBREG_TO_REG - /// SrcReg. This introduces an implicit-def of DstReg on coalesced users. - void updateRegDefsUses(Register SrcReg, Register DstReg, unsigned SubIdx, - bool IsSubregToReg); + void updateRegDefsUses(Register SrcReg, Register DstReg, unsigned SubIdx); /// If the given machine operand reads only undefined lanes add an undef /// flag. @@ -1347,7 +1343,8 @@ bool RegisterCoalescer::reMaterializeTrivialDef(const CoalescerPair &CP, if (DstReg.isPhysical()) { Register NewDstReg = DstReg; - unsigned NewDstIdx = TRI->composeSubRegIndices(CP.getSrcIdx(), DefSubIdx); + unsigned NewDstIdx = TRI->composeSubRegIndices(CP.getSrcIdx(), + DefMI->getOperand(0).getSubReg()); if (NewDstIdx) NewDstReg = TRI->getSubReg(DstReg, NewDstIdx); @@ -1496,7 +1493,7 @@ bool RegisterCoalescer::reMaterializeTrivialDef(const CoalescerPair &CP, MRI->setRegClass(DstReg, NewRC); // Update machine operands and add flags. - updateRegDefsUses(DstReg, DstReg, DstIdx, false); + updateRegDefsUses(DstReg, DstReg, DstIdx); NewMI.getOperand(0).setSubReg(NewIdx); // updateRegDefUses can add an "undef" flag to the definition, since // it will replace DstReg with DstReg.DstIdx. If NewIdx is 0, make @@ -1816,7 +1813,7 @@ void RegisterCoalescer::addUndefFlag(const LiveInterval &Int, SlotIndex UseIdx, } void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, - unsigned SubIdx, bool IsSubregToReg) { + unsigned SubIdx) { bool DstIsPhys = DstReg.isPhysical(); LiveInterval *DstInt = DstIsPhys ? nullptr : &LIS->getInterval(DstReg); @@ -1856,8 +1853,6 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, if (DstInt && !Reads && SubIdx && !UseMI->isDebugInstr()) Reads = DstInt->liveAt(LIS->getInstructionIndex(*UseMI)); - bool FullDef = true; - // Replace SrcReg with DstReg in all UseMI operands. for (unsigned i = 0, e = Ops.size(); i != e; ++i) { MachineOperand &MO = UseMI->getOperand(Ops[i]); @@ -1865,13 +1860,9 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, // Adjust flags in case of sub-register joins. We don't want to // turn a full def into a read-modify-write sub-register def and vice // versa. - if (SubIdx && MO.isDef()) { + if (SubIdx && MO.isDef()) MO.setIsUndef(!Reads); - if (!Reads) - FullDef = false; - } - // A subreg use of a partially undef (super) register may be a complete // undef use now and then has to be marked that way. if (MO.isUse() && !DstIsPhys) { @@ -1903,25 +1894,6 @@ void RegisterCoalescer::updateRegDefsUses(Register SrcReg, Register DstReg, MO.substVirtReg(DstReg, SubIdx, *TRI); } - if (IsSubregToReg && !FullDef) { - // If the coalesed instruction doesn't fully define the register, we need - // to preserve the original super register liveness for SUBREG_TO_REG. - // - // We pretended SUBREG_TO_REG was a regular copy for coalescing purposes, - // but it introduces liveness for other subregisters. Downstream users may - // have been relying on those bits, so we need to ensure their liveness is - // captured with a def of other lanes. - - // FIXME: Need to add new subrange if tracking subranges. We could also - // skip adding this if we knew the other lanes are dead, and only for - // other lanes. - - assert(!MRI->shouldTrackSubRegLiveness(DstReg) && - "this should update subranges"); - MachineInstrBuilder MIB(*MF, UseMI); - MIB.addReg(DstReg, RegState::ImplicitDefine); - } - LLVM_DEBUG({ dbgs() << "\t\tupdated: "; if (!UseMI->isDebugInstr()) @@ -2121,8 +2093,6 @@ bool RegisterCoalescer::joinCopy(MachineInstr *CopyMI, bool &Again) { }); } - const bool IsSubregToReg = CopyMI->isSubregToReg(); - ShrinkMask = LaneBitmask::getNone(); ShrinkMainRange = false; @@ -2190,12 +2160,9 @@ bool RegisterCoalescer::joinCopy(MachineInstr *CopyMI, bool &Again) { // Rewrite all SrcReg operands to DstReg. // Also update DstReg operands to include DstIdx if it is set. - if (CP.getDstIdx()) { - assert(!IsSubregToReg && "can this happen?"); - updateRegDefsUses(CP.getDstReg(), CP.getDstReg(), CP.getDstIdx(), false); - } - updateRegDefsUses(CP.getSrcReg(), CP.getDstReg(), CP.getSrcIdx(), - IsSubregToReg); + if (CP.getDstIdx()) + updateRegDefsUses(CP.getDstReg(), CP.getDstReg(), CP.getDstIdx()); + updateRegDefsUses(CP.getSrcReg(), CP.getDstReg(), CP.getSrcIdx()); // Shrink subregister ranges if necessary. if (ShrinkMask.any()) { From nobody Sat Apr 20 10:34:19 2024 X-Original-To: dev-commits-src-branches@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 4VM7DD6s7Xz5HW06; Sat, 20 Apr 2024 10:34:20 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DD0nndz4SZH; Sat, 20 Apr 2024 10:34:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609260; 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=511EuIxWU1ArrGg+O/TpX4jLcK8ifK1+lLGu212dymo=; b=FQHAVy4mBBa8NXn7bBeV05WJ4613RgtgeJ/8pQp4pFzED3/ZFMcrEikTOiTr8SWrgGjan9 0wBmUjiWQyg753SfXUXA5tKU2iQatNVQ3BI6Cvbn556MPnEpZ7tYDe0N8y30UXUqaFNtLw 2iHrMSTWqJhftq+6TEBOGHpGfKwGw7br6OqbmOmNKy5/WU4EhhQ5o2ATln8VVC6R0GXM7X XKwhlE95TZ4wp8fWPDtxb9pxXn8Pylo8NpUVO43jX4i5shsPS9gxFq5oeH1/eGKyYhNIza lJYD4cKJhxe6xVpXzA+R1pSrT9h+YKC85rdifw1i64Czq238jH21a4MPb0fXlA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609260; a=rsa-sha256; cv=none; b=sGMicYXbbrm6HhzCtfez+K0KhNSGdGLXJYsfQGs312VqaGovuBcQAY/EM6rNreI5ADBlcP RW/s+Vu02YvrwKs+p1NaEfmFW7fUASVkhEZvO1E62ejVhMNAqrVY6nyfBX2l8Lidc2hJUI r0Ng62tvChEebBjRAAOZnTtQdkfE5HsHVYiRqimlLVHAiDT1D50cZZ99JDaJYxoHY0E2Ye FQuloZ4Mi9wMw7peqdYar6ONwLy53VNWkMzqY5rjH7+TtdUm4JxsS9gTYewAvfrTQGaJO7 F91io8jATJGGVRZZ8tab6VtFg6cQxN6R0BQOIQxMdaZ3MAGWsIP4g8KdlXo22Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609260; 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=511EuIxWU1ArrGg+O/TpX4jLcK8ifK1+lLGu212dymo=; b=fLSSVNCCQa2tjH9TdcyN738vFKE0+Vi6N3xZU5n1tG+CsGVhNemR7Zvi+uYGakfEi4gXsz lrXWj1xQbUkf0Bq2tkGLrik3F+b+04byiZLi070pjHFBrS8lbfLidnJrzmB/4C2DSvPAwZ dAbW8inDNLB1WsGtyfBq3qXq5YQGBPXBVBcTOExqoqus4w+/3uwzEsC3IySAsddIhxn5RR 0x4PBixRCwSiQ5eXnvyV3CaYnVnn5KHicfLNCdu/S/90ki/uVk9ax9OcoyGxQ6gKLGiQUO 3AzgRF7i1+GlV7AOsVRB2Bc0M9JbdedrIc/DTbLAeVNJYeKBEHcpiZ2cMn+Wgg== 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 4VM7DD09WKzYqp; Sat, 20 Apr 2024 10:34:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYJGL013371; Sat, 20 Apr 2024 10:34:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYJww013368; Sat, 20 Apr 2024 10:34:19 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:19 GMT Message-Id: <202404201034.43KAYJww013368@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: 0c85e2760f6b - stable/13 - Merge llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 0c85e2760f6b5016c16d29f8c2f63f3ba2cf5298 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=0c85e2760f6b5016c16d29f8c2f63f3ba2cf5298 commit 0c85e2760f6b5016c16d29f8c2f63f3ba2cf5298 Author: Dimitry Andric AuthorDate: 2024-01-03 18:04:11 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:24 +0000 Merge llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16003-gfc5f51cf5af4. PR: 276104 MFC after: 1 month (cherry picked from commit 647cbc5de815c5651677bf8582797f716ec7b48d) --- ObsoleteFiles.inc | 105 +- .../llvm-project/clang/include/clang/AST/Type.h | 26 - .../clang/include/clang/Basic/BuiltinsAArch64.def | 3 + .../include/clang/Basic/riscv_sifive_vector.td | 28 +- .../clang/include/clang/Basic/riscv_vector.td | 8 +- .../include/clang/Basic/riscv_vector_common.td | 2 +- .../Core/BugReporter/CommonBugCategories.h | 1 + .../include/clang/StaticAnalyzer/Core/Checker.h | 14 +- .../clang/StaticAnalyzer/Core/CheckerManager.h | 11 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 1 - .../clang/lib/ASTMatchers/Dynamic/Parser.cpp | 6 +- .../clang/lib/Basic/IdentifierTable.cpp | 3 +- .../clang/lib/Basic/Targets/AArch64.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 3 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 3 +- contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 6 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 20 + .../clang/lib/CodeGen/CGStmtOpenMP.cpp | 61 +- .../clang/lib/CodeGen/CodeGenAction.cpp | 3 +- .../clang/lib/CodeGen/Targets/LoongArch.cpp | 7 - contrib/llvm-project/clang/lib/Driver/Driver.cpp | 14 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 13 +- .../clang/lib/Driver/ToolChains/Arch/X86.cpp | 4 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 7 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 23 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 12 +- .../clang/lib/Driver/ToolChains/Solaris.cpp | 3 +- .../clang/lib/Format/ContinuationIndenter.cpp | 2 +- .../clang/lib/Format/MatchFilePath.cpp | 4 +- .../clang/lib/Frontend/DependencyGraph.cpp | 3 +- .../clang/lib/Frontend/LayoutOverrideSource.cpp | 9 +- .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 3 +- .../llvm-project/clang/lib/Headers/usermsrintrin.h | 21 + .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 47 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 8 + contrib/llvm-project/clang/lib/Sema/SemaModule.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 2 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 2 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 11 +- .../StaticAnalyzer/Checkers/ArrayBoundChecker.cpp | 7 +- .../Checkers/BasicObjCFoundationChecks.cpp | 2 +- .../Checkers/BlockInCriticalSectionChecker.cpp | 57 +- .../Checkers/BoolAssignmentChecker.cpp | 7 +- .../lib/StaticAnalyzer/Checkers/CStringChecker.cpp | 382 +++--- .../StaticAnalyzer/Checkers/CXXDeleteChecker.cpp | 24 +- .../Checkers/CallAndMessageChecker.cpp | 9 +- .../StaticAnalyzer/Checkers/CastSizeChecker.cpp | 6 +- .../StaticAnalyzer/Checkers/CheckObjCDealloc.cpp | 48 +- .../Checkers/CheckSecuritySyntaxOnly.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/ChrootChecker.cpp | 6 +- .../lib/StaticAnalyzer/Checkers/CloneChecker.cpp | 15 +- .../StaticAnalyzer/Checkers/ConversionChecker.cpp | 7 +- .../Checkers/DebugContainerModeling.cpp | 15 +- .../Checkers/DebugIteratorModeling.cpp | 15 +- .../lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp | 16 +- .../StaticAnalyzer/Checkers/DynamicTypeChecker.cpp | 10 +- .../Checkers/EnumCastOutOfRangeChecker.cpp | 8 +- .../Checkers/ExprInspectionChecker.cpp | 8 +- .../Checkers/FixedAddressChecker.cpp | 6 +- .../Checkers/InvalidatedIteratorChecker.cpp | 28 +- .../clang/lib/StaticAnalyzer/Checkers/Iterator.cpp | 14 +- .../clang/lib/StaticAnalyzer/Checkers/Iterator.h | 15 +- .../StaticAnalyzer/Checkers/IteratorModeling.cpp | 49 +- .../Checkers/IteratorRangeChecker.cpp | 20 +- .../Checkers/LocalizationChecker.cpp | 12 +- .../Checkers/MPI-Checker/MPIBugReporter.cpp | 6 +- .../Checkers/MPI-Checker/MPIBugReporter.h | 21 +- .../Checkers/MacOSKeychainAPIChecker.cpp | 22 +- .../StaticAnalyzer/Checkers/MacOSXAPIChecker.cpp | 10 +- .../Checkers/MismatchedIteratorChecker.cpp | 49 +- .../Checkers/MmapWriteExecChecker.cpp | 16 +- .../Checkers/NSAutoreleasePoolChecker.cpp | 9 +- .../Checkers/NonNullParamChecker.cpp | 21 +- .../StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp | 17 +- .../Checkers/ObjCContainersChecker.cpp | 11 +- .../Checkers/ObjCSelfInitChecker.cpp | 9 +- .../Checkers/ObjCSuperDeallocChecker.cpp | 19 +- .../lib/StaticAnalyzer/Checkers/PaddingChecker.cpp | 9 +- .../Checkers/PointerArithChecker.cpp | 12 +- .../StaticAnalyzer/Checkers/PointerSubChecker.cpp | 6 +- .../Checkers/ReturnPointerRangeChecker.cpp | 10 +- .../StaticAnalyzer/Checkers/ReturnUndefChecker.cpp | 15 +- .../Checkers/SimpleStreamChecker.cpp | 27 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 16 +- .../StaticAnalyzer/Checkers/TaggedUnionModeling.h | 2 +- .../StaticAnalyzer/Checkers/TaintTesterChecker.cpp | 5 +- .../Checkers/TestAfterDivZeroChecker.cpp | 10 +- .../StaticAnalyzer/Checkers/UndefBranchChecker.cpp | 89 +- .../Checkers/UndefCapturedBlockVarChecker.cpp | 8 +- .../StaticAnalyzer/Checkers/UndefResultChecker.cpp | 8 +- .../Checkers/UndefinedArraySubscriptChecker.cpp | 7 +- .../Checkers/UndefinedAssignmentChecker.cpp | 11 +- .../UninitializedObject/UninitializedObject.h | 2 +- .../UninitializedObjectChecker.cpp | 11 +- .../lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp | 32 +- .../lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp | 20 +- .../lib/StaticAnalyzer/Checkers/VforkChecker.cpp | 7 +- .../StaticAnalyzer/Core/CommonBugCategories.cpp | 1 + .../clang/lib/StaticAnalyzer/Core/Environment.cpp | 2 +- .../clang/lib/StaticAnalyzer/Core/RegionStore.cpp | 6 +- .../clang/lib/Support/RISCVVIntrinsicUtils.cpp | 2 +- .../clang/lib/Tooling/Refactoring/Lookup.cpp | 4 +- contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 4 +- .../clang/tools/clang-format/ClangFormat.cpp | 69 +- .../clang/utils/TableGen/RISCVVEmitter.cpp | 2 +- .../clang/utils/TableGen/SveEmitter.cpp | 19 + .../compiler-rt/lib/asan/asan_linux.cpp | 13 +- .../compiler-rt/lib/asan/asan_new_delete.cpp | 9 - .../compiler-rt/lib/builtins/cpu_model/x86.c | 2 +- .../llvm-project/compiler-rt/lib/builtins/fp_lib.h | 12 - .../compiler-rt/lib/builtins/int_types.h | 2 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 11 +- .../compiler-rt/lib/memprof/memprof_linux.cpp | 1 - .../sanitizer_common_interceptors.inc | 4 +- .../lib/sanitizer_common/sanitizer_flat_map.h | 4 + .../lib/sanitizer_common/sanitizer_freebsd.h | 137 -- .../lib/sanitizer_common/sanitizer_linux.cpp | 9 +- .../sanitizer_common/sanitizer_linux_libcdep.cpp | 8 +- .../sanitizer_platform_interceptors.h | 5 +- .../sanitizer_platform_limits_freebsd.h | 2 + .../sanitizer_platform_limits_posix.h | 1 + .../sanitizer_common/sanitizer_procmaps_bsd.cpp | 11 - .../sanitizer_common/sanitizer_stackdepotbase.h | 22 +- .../compiler-rt/lib/tsan/rtl/tsan_platform.h | 32 + .../lib/tsan/rtl/tsan_platform_linux.cpp | 8 +- contrib/llvm-project/libcxx/include/__config | 10 + .../libcxx/include/__memory/shared_ptr.h | 4 +- .../libcxx/include/__memory/unique_ptr.h | 4 - .../libcxx/include/__ranges/chunk_by_view.h | 3 +- .../libcxx/include/__ranges/drop_view.h | 7 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 2 +- .../libcxx/include/__ranges/movable_box.h | 62 +- .../libcxx/include/__ranges/repeat_view.h | 4 +- .../libcxx/include/__ranges/single_view.h | 4 +- .../libcxx/include/__ranges/take_while_view.h | 3 +- .../libcxx/include/__ranges/transform_view.h | 3 +- contrib/llvm-project/libcxx/include/memory | 2 +- contrib/llvm-project/lld/COFF/Driver.cpp | 3 + contrib/llvm-project/lld/COFF/Writer.cpp | 2 +- .../llvm/include/llvm/ADT/GenericUniformityImpl.h | 6 + .../llvm/include/llvm/ADT/SmallString.h | 65 +- .../llvm/include/llvm/Analysis/ConstraintSystem.h | 7 - .../include/llvm/Analysis/TargetTransformInfo.h | 22 + .../llvm/Analysis/TargetTransformInfoImpl.h | 7 + .../llvm/CodeGen/GlobalISel/CombinerHelper.h | 18 +- .../include/llvm/Frontend/OpenMP/OMPIRBuilder.h | 7 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 10 +- .../include/llvm/Support/AMDHSAKernelDescriptor.h | 44 +- .../llvm/Support/X86DisassemblerDecoderCommon.h | 9 +- .../llvm/include/llvm/Target/GlobalISel/Combine.td | 15 +- .../llvm/lib/Analysis/ConstraintSystem.cpp | 10 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 32 +- .../llvm/lib/Analysis/LazyValueInfo.cpp | 163 ++- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 9 + .../llvm/lib/Analysis/ValueTracking.cpp | 34 - .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 2 + .../llvm/lib/Bitcode/Reader/BitcodeReader.cpp | 3 + .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 353 +++++- .../llvm/lib/CodeGen/MachineCopyPropagation.cpp | 42 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 16 +- .../llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp | 9 +- .../lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp | 3 +- .../lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp | 8 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 4 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 3 +- .../Orc/Debugging/DebugInfoSupport.cpp | 3 +- .../llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | 6 +- .../llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp | 12 +- .../llvm-project/llvm/lib/FuzzMutate/FuzzerCLI.cpp | 16 +- contrib/llvm-project/llvm/lib/IR/DebugInfo.cpp | 4 + .../llvm-project/llvm/lib/MC/WasmObjectWriter.cpp | 3 +- .../llvm/lib/Object/WasmObjectFile.cpp | 21 +- .../llvm/lib/ProfileData/InstrProfReader.cpp | 2 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 11 +- .../llvm-project/llvm/lib/Support/Windows/Path.inc | 5 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 39 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 59 +- .../AArch64/Disassembler/AArch64Disassembler.cpp | 2 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 14 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 18 +- .../llvm/lib/Target/AMDGPU/AMDGPUInstructions.td | 1 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 1 + .../llvm/lib/Target/AMDGPU/AMDGPURegisterBanks.td | 2 +- .../Target/AMDGPU/AMDGPUResourceUsageAnalysis.cpp | 3 +- .../lib/Target/AMDGPU/AMDGPURewriteUndefForPHI.cpp | 1 - .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 1 + .../AMDGPU/AMDGPUUnifyDivergentExitNodes.cpp | 3 - .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 9 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 57 +- .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 11 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp | 4 +- .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 6 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 58 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 24 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 10 + .../llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp | 12 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 76 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 2 - .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 22 +- .../llvm/lib/Target/ARC/ARCISelLowering.cpp | 2 +- .../llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp | 9 +- .../llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp | 28 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 69 +- .../llvm/lib/Target/AVR/AVRISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/AVR/AVRISelLowering.cpp | 5 +- .../llvm/lib/Target/BPF/BPFISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/CSKY/CSKYISelLowering.cpp | 4 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 34 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 6 +- .../lib/Target/Hexagon/HexagonISelLowering.cpp | 9 +- .../lib/Target/Hexagon/HexagonISelLoweringHVX.cpp | 4 +- .../llvm/lib/Target/Lanai/LanaiISelLowering.cpp | 4 +- .../LoongArch/AsmParser/LoongArchAsmParser.cpp | 12 +- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 59 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 1 + .../lib/Target/LoongArch/LoongArchLASXInstrInfo.td | 50 +- .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 4 +- .../MCTargetDesc/LoongArchMCCodeEmitter.cpp | 13 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.cpp | 7 +- .../LoongArch/MCTargetDesc/LoongArchMCExpr.h | 8 +- .../llvm/lib/Target/M68k/M68kExpandPseudo.cpp | 10 + .../llvm/lib/Target/M68k/M68kISelLowering.cpp | 243 ++-- .../llvm/lib/Target/M68k/M68kISelLowering.h | 9 + .../llvm/lib/Target/M68k/M68kInstrArithmetic.td | 70 +- .../llvm/lib/Target/M68k/M68kInstrData.td | 3 + .../llvm/lib/Target/M68k/M68kInstrFormats.td | 20 +- .../llvm/lib/Target/M68k/M68kInstrInfo.td | 30 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 6 +- .../llvm/lib/Target/Mips/Mips64InstrInfo.td | 12 +- .../llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp | 20 + .../llvm/lib/Target/Mips/MipsISelDAGToDAG.h | 1 + .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 4 +- .../llvm/lib/Target/Mips/MipsInstrCompiler.td | 33 + .../llvm/lib/Target/Mips/MipsInstrInfo.td | 13 +- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 8 +- .../llvm/lib/Target/Mips/MipsSEISelLowering.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 6 +- .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 5 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 134 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 45 +- .../RISCV/Disassembler/RISCVDisassembler.cpp | 31 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 2 +- .../Target/RISCV/MCTargetDesc/RISCVBaseInfo.cpp | 1 - .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 14 +- .../Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp | 5 +- .../llvm/lib/Target/RISCV/RISCVCallingConv.td | 4 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 29 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 6 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 230 +++- .../llvm/lib/Target/RISCV/RISCVInsertWriteVXRM.cpp | 14 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 11 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.td | 11 +- .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 152 +-- .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 58 + .../llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td | 83 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZc.td | 5 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZcmop.td | 34 + .../llvm/lib/Target/RISCV/RISCVInstrInfoZicfiss.td | 72 ++ .../llvm/lib/Target/RISCV/RISCVInstrInfoZimop.td | 59 + .../llvm/lib/Target/RISCV/RISCVProcessors.td | 3 +- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.cpp | 3 + .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 7 + .../llvm/lib/Target/RISCV/RISCVSystemOperands.td | 55 +- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 3 +- .../llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp | 6 +- .../llvm/lib/Target/Sparc/SparcISelLowering.cpp | 4 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 76 +- .../llvm/lib/Target/SystemZ/SystemZOperators.td | 4 +- .../llvm/lib/Target/VE/VEISelLowering.cpp | 14 +- .../llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp | 10 +- .../Target/X86/Disassembler/X86Disassembler.cpp | 6 +- .../X86/Disassembler/X86DisassemblerDecoder.h | 1 + .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 13 +- .../X86/MCTargetDesc/X86InstPrinterCommon.cpp | 3 + .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 43 +- contrib/llvm-project/llvm/lib/Target/X86/X86.td | 11 +- .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 10 +- .../llvm/lib/Target/X86/X86InsertPrefetch.cpp | 3 +- .../llvm/lib/Target/X86/X86InstrAMX.td | 68 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 11 + .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1306 +++++++++----------- .../llvm/lib/Target/X86/X86InstrFormats.td | 2 + .../llvm/lib/Target/X86/X86InstrPredicates.td | 3 +- .../llvm/lib/Target/X86/X86InstrSSE.td | 94 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 4 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 426 ++++++- .../llvm/lib/Target/X86/X86InstrVecCompiler.td | 9 + .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 26 +- .../llvm/lib/Target/X86/X86TargetTransformInfo.h | 5 + .../llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/XCore/XCoreISelLowering.cpp | 56 +- .../llvm/lib/TargetParser/ARMTargetParser.cpp | 6 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 2 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 3 +- .../llvm/lib/TargetParser/X86TargetParser.cpp | 4 +- .../llvm-project/llvm/lib/TextAPI/TextStubV5.cpp | 7 +- .../llvm/lib/Transforms/Coroutines/CoroFrame.cpp | 6 +- .../llvm/lib/Transforms/IPO/FunctionAttrs.cpp | 46 +- .../Transforms/InstCombine/InstCombineAddSub.cpp | 4 +- .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 14 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 6 + .../Transforms/InstCombine/InstCombineCompares.cpp | 196 ++- .../Transforms/InstCombine/InstCombineInternal.h | 7 +- .../Transforms/InstCombine/InstCombineSelect.cpp | 71 +- .../InstCombine/InstructionCombining.cpp | 58 +- .../Transforms/Scalar/ConstraintElimination.cpp | 64 +- .../Transforms/Utils/CanonicalizeFreezeInLoops.cpp | 60 +- .../llvm/lib/Transforms/Utils/Local.cpp | 5 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 63 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 146 ++- .../llvm/lib/Transforms/Vectorize/VPlan.h | 30 + .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 65 +- .../llvm/lib/Transforms/Vectorize/VPlanValue.h | 1 + .../llvm-project/llvm/tools/llvm-ar/llvm-ar.cpp | 3 +- .../llvm/tools/llvm-diff/llvm-diff.cpp | 3 +- .../llvm/utils/TableGen/X86DisassemblerTables.cpp | 21 +- .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 18 +- .../llvm/utils/TableGen/X86RecognizableInstr.cpp | 37 +- .../llvm/utils/TableGen/X86RecognizableInstr.h | 4 +- lib/clang/include/Plugins/Plugins.def | 1 + lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Config/AsmParsers.def | 23 + lib/clang/include/llvm/Config/AsmPrinters.def | 23 + lib/clang/include/llvm/Config/Disassemblers.def | 23 + lib/clang/include/llvm/Config/TargetMCAs.def | 23 + lib/clang/include/llvm/Config/Targets.def | 22 + lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/liblldb/Makefile | 1 + lib/clang/libllvm/Makefile | 1 + 335 files changed, 5221 insertions(+), 3749 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index f1db90f37d48..55479a7f6bfc 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -136,11 +136,14 @@ OLD_FILES+=usr/lib/clang/17/include/cmpccxaddintrin.h OLD_FILES+=usr/lib/clang/17/include/cpuid.h OLD_FILES+=usr/lib/clang/17/include/crc32intrin.h OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/algorithm +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/basic_string.h +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/basic_string.tcc OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/bits/shared_ptr_base.h OLD_DIRS+=usr/lib/clang/17/include/cuda_wrappers/bits OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/cmath OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/complex OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/new +OLD_FILES+=usr/lib/clang/17/include/cuda_wrappers/shared_ptr_base.h OLD_DIRS+=usr/lib/clang/17/include/cuda_wrappers OLD_FILES+=usr/lib/clang/17/include/emmintrin.h OLD_FILES+=usr/lib/clang/17/include/enqcmdintrin.h @@ -440,57 +443,57 @@ OLD_DIRS+=usr/lib/clang/17/share OLD_DIRS+=usr/lib/clang/17 # 20240419: new libc++ import which bumps version from 17 to 18 -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/algorithm_fwd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/algorithm_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/execution_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/execution_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_algorithm_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_algorithm_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_memory_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_memory_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_numeric_defs.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/glue_numeric_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/memory_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/numeric_fwd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/numeric_impl.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_for.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_for_each.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_invoke.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_merge.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_scan.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_stable_partial_sort.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_stable_sort.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_transform_reduce.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/parallel_transform_scan.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/omp/util.h -OLD_DIRS+=usr/include/include/c++/v1/__pstl/internal/omp -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_omp.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_serial.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_tbb.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/parallel_backend_utils.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/unseq_backend_simd.h -OLD_FILES+=usr/include/include/c++/v1/__pstl/internal/utils.h -OLD_DIRS+=usr/include/include/c++/v1/__pstl/internal -OLD_DIRS+=usr/include/include/c++/v1/__pstl -OLD_FILES+=usr/include/include/c++/v1/__pstl_algorithm -OLD_FILES+=usr/include/include/c++/v1/__pstl_memory -OLD_FILES+=usr/include/include/c++/v1/__pstl_numeric -OLD_FILES+=usr/include/include/c++/v1/__type_traits/predicate_traits.h -OLD_FILES+=usr/include/include/c++/v1/__utility/terminate_on_exception.h -OLD_FILES+=usr/include/include/c++/v1/experimental/deque -OLD_FILES+=usr/include/include/c++/v1/experimental/forward_list -OLD_FILES+=usr/include/include/c++/v1/experimental/list -OLD_FILES+=usr/include/include/c++/v1/experimental/map -OLD_FILES+=usr/include/include/c++/v1/experimental/memory_resource -OLD_FILES+=usr/include/include/c++/v1/experimental/regex -OLD_FILES+=usr/include/include/c++/v1/experimental/set -OLD_FILES+=usr/include/include/c++/v1/experimental/string -OLD_FILES+=usr/include/include/c++/v1/experimental/unordered_map -OLD_FILES+=usr/include/include/c++/v1/experimental/unordered_set -OLD_FILES+=usr/include/include/c++/v1/experimental/vector -OLD_FILES+=usr/include/include/c++/v1/limits.h -OLD_FILES+=usr/include/include/c++/v1/setjmp.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/algorithm_fwd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/algorithm_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/execution_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/execution_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_algorithm_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_algorithm_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_memory_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_memory_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_numeric_defs.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/glue_numeric_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/memory_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/numeric_fwd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/numeric_impl.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_for.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_for_each.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_invoke.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_merge.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_scan.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_stable_partial_sort.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_stable_sort.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_transform_reduce.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/parallel_transform_scan.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/omp/util.h +OLD_DIRS+=usr/include/c++/v1/__pstl/internal/omp +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_omp.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_serial.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_tbb.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/parallel_backend_utils.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/unseq_backend_simd.h +OLD_FILES+=usr/include/c++/v1/__pstl/internal/utils.h +OLD_DIRS+=usr/include/c++/v1/__pstl/internal +OLD_DIRS+=usr/include/c++/v1/__pstl +OLD_FILES+=usr/include/c++/v1/__pstl_algorithm +OLD_FILES+=usr/include/c++/v1/__pstl_memory +OLD_FILES+=usr/include/c++/v1/__pstl_numeric +OLD_FILES+=usr/include/c++/v1/__type_traits/predicate_traits.h +OLD_FILES+=usr/include/c++/v1/__utility/terminate_on_exception.h +OLD_FILES+=usr/include/c++/v1/experimental/deque +OLD_FILES+=usr/include/c++/v1/experimental/forward_list +OLD_FILES+=usr/include/c++/v1/experimental/list +OLD_FILES+=usr/include/c++/v1/experimental/map +OLD_FILES+=usr/include/c++/v1/experimental/memory_resource +OLD_FILES+=usr/include/c++/v1/experimental/regex +OLD_FILES+=usr/include/c++/v1/experimental/set +OLD_FILES+=usr/include/c++/v1/experimental/string +OLD_FILES+=usr/include/c++/v1/experimental/unordered_map +OLD_FILES+=usr/include/c++/v1/experimental/unordered_set +OLD_FILES+=usr/include/c++/v1/experimental/vector +OLD_FILES+=usr/include/c++/v1/limits.h +OLD_FILES+=usr/include/c++/v1/setjmp.h # 20240213: caroot bundle updated OLD_FILES+=usr/share/certs/trusted/Security_Communication_Root_CA.pem diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index b3ae66e6e769..1afa69367286 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -2383,10 +2383,6 @@ public: /// Check if the type is the CUDA device builtin texture type. bool isCUDADeviceBuiltinTextureType() const; - bool isRVVType(unsigned ElementCount) const; - - bool isRVVType(unsigned Bitwidth, bool IsFloat, bool IsBFloat = false) const; - /// Return the implicit lifetime for this type, which must not be dependent. Qualifiers::ObjCLifetime getObjCARCImplicitLifetime() const; @@ -7283,28 +7279,6 @@ inline bool Type::isOpenCLSpecificType() const { isQueueT() || isReserveIDT() || isPipeType() || isOCLExtOpaqueType(); } -inline bool Type::isRVVType(unsigned ElementCount) const { - bool Ret = false; -#define RVV_VECTOR_TYPE(Name, Id, SingletonId, NumEls, ElBits, NF, IsSigned, \ - IsFP, IsBF) \ - if (NumEls == ElementCount) \ - Ret |= isSpecificBuiltinType(BuiltinType::Id); -#include "clang/Basic/RISCVVTypes.def" - return Ret; -} - -inline bool Type::isRVVType(unsigned Bitwidth, bool IsFloat, - bool IsBFloat) const { - bool Ret = false; -#define RVV_TYPE(Name, Id, SingletonId) -#define RVV_VECTOR_TYPE(Name, Id, SingletonId, NumEls, ElBits, NF, IsSigned, \ - IsFP, IsBF) \ - if (ElBits == Bitwidth && IsFloat == IsFP && IsBFloat == IsBF) \ - Ret |= isSpecificBuiltinType(BuiltinType::Id); -#include "clang/Basic/RISCVVTypes.def" - return Ret; -} - inline bool Type::isTemplateTypeParmType() const { return isa(CanonicalType); } diff --git a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def index 82a1ba3c82ad..31ec84143f65 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def +++ b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAArch64.def @@ -68,6 +68,9 @@ TARGET_BUILTIN(__builtin_arm_ldg, "v*v*", "t", "mte") TARGET_BUILTIN(__builtin_arm_stg, "vv*", "t", "mte") TARGET_BUILTIN(__builtin_arm_subp, "Uiv*v*", "t", "mte") +// SME state function +BUILTIN(__builtin_arm_get_sme_state, "vULi*ULi*", "n") + // Memory Operations TARGET_BUILTIN(__builtin_arm_mops_memset_tag, "v*v*iz", "", "mte,mops") diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td index bb54e2664186..0d471f6c554c 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_sifive_vector.td @@ -109,10 +109,10 @@ multiclass RVVVFWMACCBuiltinSet> suffixes_prototypes> { Name = NAME, HasMasked = false, Log2LMUL = [-2, -1, 0, 1, 2] in - defm NAME : RVVOutOp1Op2BuiltinSet; + defm NAME : RVVOutOp1Op2BuiltinSet; } -multiclass RVVVQMACCBuiltinSet> suffixes_prototypes> { +multiclass RVVVQMACCDODBuiltinSet> suffixes_prototypes> { let OverloadedName = NAME, Name = NAME, HasMasked = false, @@ -120,6 +120,14 @@ multiclass RVVVQMACCBuiltinSet> suffixes_prototypes> { defm NAME : RVVOutOp1Op2BuiltinSet; } +multiclass RVVVQMACCQOQBuiltinSet> suffixes_prototypes> { + let OverloadedName = NAME, + Name = NAME, + HasMasked = false, + Log2LMUL = [-1, 0, 1, 2] in + defm NAME : RVVOutOp1Op2BuiltinSet; +} + multiclass RVVVFNRCLIPBuiltinSet { let Log2LMUL = [-3, -2, -1, 0, 1, 2], Name = NAME, @@ -130,18 +138,18 @@ multiclass RVVVFNRCLIPBuiltinSet; - defm sf_vqmacc_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; - defm sf_vqmaccus_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; - defm sf_vqmaccsu_2x8x2 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; + defm sf_vqmaccu_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; + defm sf_vqmacc_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; + defm sf_vqmaccus_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; + defm sf_vqmaccsu_2x8x2 : RVVVQMACCDODBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; } let UnMaskedPolicyScheme = HasPolicyOperand in let RequiredFeatures = ["Xsfvqmaccqoq"] in { - defm sf_vqmaccu_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; - defm sf_vqmacc_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)v"]]>; - defm sf_vqmaccus_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)SUv(FixedSEW:8)v"]]>; - defm sf_vqmaccsu_4x8x4 : RVVVQMACCBuiltinSet<[["", "v", "vv(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; + defm sf_vqmaccu_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)SUv(FixedSEW:8)Uv"]]>; + defm sf_vqmacc_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)Sv(FixedSEW:8)v"]]>; + defm sf_vqmaccus_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)SUv(FixedSEW:8)v"]]>; + defm sf_vqmaccsu_4x8x4 : RVVVQMACCQOQBuiltinSet<[["", "w", "ww(FixedSEW:8)Sv(FixedSEW:8)Uv"]]>; } let UnMaskedPolicyScheme = HasPolicyOperand in diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td index f2dde7f540fb..e7d78b03511f 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector.td @@ -2441,11 +2441,9 @@ let HasMasked = false, HasVL = false, IRName = "" in { return Builder.CreateInsertVector(ResultType, Ops[0], Ops[2], Ops[1]); } }] in { - let Log2LMUL = [0, 1, 2] in { - foreach dst_lmul = ["(LFixedLog2LMUL:1)", "(LFixedLog2LMUL:2)", "(LFixedLog2LMUL:3)"] in { - def : RVVBuiltin<"v" # dst_lmul # "v", dst_lmul # "v" # dst_lmul # "vKzv", "csilxfd">; - def : RVVBuiltin<"Uv" # dst_lmul # "Uv", dst_lmul # "Uv" # dst_lmul #"UvKzUv", "csil">; - } + foreach dst_lmul = ["(LFixedLog2LMUL:1)", "(LFixedLog2LMUL:2)", "(LFixedLog2LMUL:3)"] in { + def : RVVBuiltin<"v" # dst_lmul # "v", dst_lmul # "v" # dst_lmul # "vKzv", "csilxfd">; + def : RVVBuiltin<"Uv" # dst_lmul # "Uv", dst_lmul # "Uv" # dst_lmul #"UvKzUv", "csil">; } foreach nf = NFList in { defvar T = "(Tuple:" # nf # ")"; diff --git a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td index 4036ce8e6903..040db6f0cdbf 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td +++ b/contrib/llvm-project/clang/include/clang/Basic/riscv_vector_common.td @@ -41,7 +41,7 @@ // x: float16_t (half) // f: float32_t (float) // d: float64_t (double) -// b: bfloat16_t (bfloat16) +// y: bfloat16_t (bfloat16) // // This way, given an LMUL, a record with a TypeRange "sil" will cause the // definition of 3 builtins. Each type "t" in the TypeRange (in this example diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h index 5d2c96e5bc9d..45187433c069 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h @@ -13,6 +13,7 @@ namespace clang { namespace ento { namespace categories { +extern const char *const AppleAPIMisuse; extern const char *const CoreFoundationObjectiveC; extern const char *const LogicError; extern const char *const MemoryRefCount; diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h index 8a46282a595e..2ec54a837c42 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/Checker.h @@ -193,9 +193,8 @@ public: class Location { template - static void _checkLocation(void *checker, - const SVal &location, bool isLoad, const Stmt *S, - CheckerContext &C) { + static void _checkLocation(void *checker, SVal location, bool isLoad, + const Stmt *S, CheckerContext &C) { ((const CHECKER *)checker)->checkLocation(location, isLoad, S, C); } @@ -209,8 +208,7 @@ public: class Bind { template - static void _checkBind(void *checker, - const SVal &location, const SVal &val, const Stmt *S, + static void _checkBind(void *checker, SVal location, SVal val, const Stmt *S, CheckerContext &C) { ((const CHECKER *)checker)->checkBind(location, val, S, C); } @@ -456,10 +454,8 @@ namespace eval { class Assume { template - static ProgramStateRef _evalAssume(void *checker, - ProgramStateRef state, - const SVal &cond, - bool assumption) { + static ProgramStateRef _evalAssume(void *checker, ProgramStateRef state, + SVal cond, bool assumption) { return ((const CHECKER *)checker)->evalAssume(state, cond, assumption); } diff --git a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h index 39583c443eda..a45ba1bc573e 100644 --- a/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h +++ b/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h @@ -488,13 +488,11 @@ public: using CheckCallFunc = CheckerFn; - using CheckLocationFunc = - CheckerFn; + using CheckLocationFunc = CheckerFn; using CheckBindFunc = - CheckerFn; + CheckerFn; using CheckEndAnalysisFunc = CheckerFn; @@ -530,8 +528,7 @@ public: RegionAndSymbolInvalidationTraits *ITraits)>; using EvalAssumeFunc = - CheckerFn; + CheckerFn; using EvalCallFunc = CheckerFn; diff --git a/contrib/llvm-project/clang/lib/AST/Interp/Interp.h b/contrib/llvm-project/clang/lib/AST/Interp/Interp.h index a240d74d6342..828d4ea35526 100644 --- a/contrib/llvm-project/clang/lib/AST/Interp/Interp.h +++ b/contrib/llvm-project/clang/lib/AST/Interp/Interp.h @@ -37,7 +37,6 @@ namespace clang { namespace interp { -using APInt = llvm::APInt; using APSInt = llvm::APSInt; /// Convert a value to an APValue. diff --git a/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp b/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp index 27096a83b8dd..6a16c2184fcf 100644 --- a/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp +++ b/contrib/llvm-project/clang/lib/ASTMatchers/Dynamic/Parser.cpp @@ -299,10 +299,8 @@ private: /// Consume all leading whitespace from \c Code. void consumeWhitespace() { - Code = Code.drop_while([](char c) { - // Don't trim newlines. - return StringRef(" \t\v\f\r").contains(c); - }); + // Don't trim newlines. + Code = Code.ltrim(" \t\v\f\r"); } SourceLocation currentLocation() { diff --git a/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp b/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp index 5902c6dc3ce0..d0d8316385b4 100644 --- a/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp +++ b/contrib/llvm-project/clang/lib/Basic/IdentifierTable.cpp @@ -628,8 +628,7 @@ ObjCMethodFamily Selector::getMethodFamilyImpl(Selector sel) { return OMF_performSelector; // The other method families may begin with a prefix of underscores. - while (!name.empty() && name.front() == '_') - name = name.substr(1); + name = name.ltrim('_'); if (name.empty()) return OMF_None; switch (name.front()) { diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 3ee39133fcee..2f8395cb8932 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -1365,8 +1365,7 @@ bool AArch64TargetInfo::validateConstraintModifier( StringRef Constraint, char Modifier, unsigned Size, std::string &SuggestedModifier) const { // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); switch (Constraint[0]) { default: diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp index 6e1842fc64e5..01f9e844da12 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/ARM.cpp @@ -1230,8 +1230,7 @@ bool ARMTargetInfo::validateConstraintModifier( bool isInOut = (Constraint[0] == '+'); // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); switch (Constraint[0]) { default: diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp index 685462961ee3..6bc57a83a2d5 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/RISCV.cpp @@ -416,8 +416,7 @@ static void handleFullArchString(StringRef FullArchStr, Features.push_back("__RISCV_TargetAttrNeedOverride"); auto RII = llvm::RISCVISAInfo::parseArchString( FullArchStr, /* EnableExperimentalExtension */ true); - if (!RII) { - consumeError(RII.takeError()); + if (llvm::errorToBool(RII.takeError())) { // Forward the invalid FullArchStr. Features.push_back("+" + FullArchStr.str()); } else { diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp index b97f88647fa4..3deaa19f8d4f 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/X86.cpp @@ -1613,8 +1613,7 @@ bool X86TargetInfo::validateOutputSize(const llvm::StringMap &FeatureMap, StringRef Constraint, unsigned Size) const { // Strip off constraint modifiers. - while (Constraint[0] == '=' || Constraint[0] == '+' || Constraint[0] == '&') - Constraint = Constraint.substr(1); + Constraint = Constraint.ltrim("=+&"); return validateOperandSize(FeatureMap, Constraint, Size); } diff --git a/contrib/llvm-project/clang/lib/Basic/Warnings.cpp b/contrib/llvm-project/clang/lib/Basic/Warnings.cpp index bab1af4f03b6..92954cab6fb0 100644 --- a/contrib/llvm-project/clang/lib/Basic/Warnings.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Warnings.cpp @@ -96,11 +96,7 @@ void clang::ProcessWarningOptions(DiagnosticsEngine &Diags, // Check to see if this warning starts with "no-", if so, this is a // negative form of the option. - bool isPositive = true; - if (Opt.starts_with("no-")) { - isPositive = false; - Opt = Opt.substr(3); - } + bool isPositive = !Opt.consume_front("no-"); // Figure out how this option affects the warning. If -Wfoo, map the // diagnostic to a warning, if -Wno-foo, map it to ignore. diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp index 5081062da286..f71dbf1729a1 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGBuiltin.cpp @@ -10430,6 +10430,26 @@ Value *CodeGenFunction::EmitAArch64BuiltinExpr(unsigned BuiltinID, return Builder.CreateCall(F, llvm::ConstantInt::get(Int32Ty, HintID)); } + if (BuiltinID == clang::AArch64::BI__builtin_arm_get_sme_state) { + // Create call to __arm_sme_state and store the results to the two pointers. + CallInst *CI = EmitRuntimeCall(CGM.CreateRuntimeFunction( + llvm::FunctionType::get(StructType::get(CGM.Int64Ty, CGM.Int64Ty), {}, + false), + "__arm_sme_state")); + auto Attrs = + AttributeList() + .addFnAttribute(getLLVMContext(), "aarch64_pstate_sm_compatible") + .addFnAttribute(getLLVMContext(), "aarch64_pstate_za_preserved"); + CI->setAttributes(Attrs); + CI->setCallingConv( + llvm::CallingConv:: + AArch64_SME_ABI_Support_Routines_PreserveMost_From_X2); + Builder.CreateStore(Builder.CreateExtractValue(CI, 0), + EmitPointerWithAlignment(E->getArg(0))); + return Builder.CreateStore(Builder.CreateExtractValue(CI, 1), + EmitPointerWithAlignment(E->getArg(1))); + } + if (BuiltinID == clang::AArch64::BI__builtin_arm_rbit) { assert((getContext().getTypeSize(E->getType()) == 32) && "rbit of unusual size!"); diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp index ed426098ac69..e362c9da51fe 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGStmtOpenMP.cpp @@ -6406,13 +6406,11 @@ static void emitOMPAtomicCaptureExpr(CodeGenFunction &CGF, } } -static void emitOMPAtomicCompareExpr(CodeGenFunction &CGF, - llvm::AtomicOrdering AO, const Expr *X, - const Expr *V, const Expr *R, - const Expr *E, const Expr *D, - const Expr *CE, bool IsXBinopExpr, - bool IsPostfixUpdate, bool IsFailOnly, - SourceLocation Loc) { +static void emitOMPAtomicCompareExpr( + CodeGenFunction &CGF, llvm::AtomicOrdering AO, llvm::AtomicOrdering FailAO, + const Expr *X, const Expr *V, const Expr *R, const Expr *E, const Expr *D, + const Expr *CE, bool IsXBinopExpr, bool IsPostfixUpdate, bool IsFailOnly, + SourceLocation Loc) { llvm::OpenMPIRBuilder &OMPBuilder = CGF.CGM.getOpenMPRuntime().getOMPBuilder(); @@ -6477,13 +6475,21 @@ static void emitOMPAtomicCompareExpr(CodeGenFunction &CGF, R->getType().isVolatileQualified()}; } - CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( - CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, - IsPostfixUpdate, IsFailOnly)); + if (FailAO == llvm::AtomicOrdering::NotAtomic) { + // fail clause was not mentionend on the + // "#pragma omp atomic compare" construct. + CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( + CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, + IsPostfixUpdate, IsFailOnly)); + } else + CGF.Builder.restoreIP(OMPBuilder.createAtomicCompare( + CGF.Builder, XOpVal, VOpVal, ROpVal, EVal, DVal, AO, Op, IsXBinopExpr, + IsPostfixUpdate, IsFailOnly, FailAO)); } static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, - llvm::AtomicOrdering AO, bool IsPostfixUpdate, + llvm::AtomicOrdering AO, + llvm::AtomicOrdering FailAO, bool IsPostfixUpdate, const Expr *X, const Expr *V, const Expr *R, const Expr *E, const Expr *UE, const Expr *D, const Expr *CE, bool IsXLHSInRHSPart, @@ -6504,12 +6510,8 @@ static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, IsXLHSInRHSPart, Loc); break; case OMPC_compare: { - emitOMPAtomicCompareExpr(CGF, AO, X, V, R, E, D, CE, IsXLHSInRHSPart, - IsPostfixUpdate, IsFailOnly, Loc); - break; - } - case OMPC_fail: { - //TODO + emitOMPAtomicCompareExpr(CGF, AO, FailAO, X, V, R, E, D, CE, + IsXLHSInRHSPart, IsPostfixUpdate, IsFailOnly, Loc); break; } default: @@ -6519,6 +6521,8 @@ static void emitOMPAtomicExpr(CodeGenFunction &CGF, OpenMPClauseKind Kind, void CodeGenFunction::EmitOMPAtomicDirective(const OMPAtomicDirective &S) { llvm::AtomicOrdering AO = llvm::AtomicOrdering::Monotonic; + // Fail Memory Clause Ordering. + llvm::AtomicOrdering FailAO = llvm::AtomicOrdering::NotAtomic; bool MemOrderingSpecified = false; if (S.getSingleClause()) { AO = llvm::AtomicOrdering::SequentiallyConsistent; @@ -6572,12 +6576,27 @@ void CodeGenFunction::EmitOMPAtomicDirective(const OMPAtomicDirective &S) { } } + if (KindsEncountered.contains(OMPC_compare) && + KindsEncountered.contains(OMPC_fail)) { + Kind = OMPC_compare; + const auto *FailClause = S.getSingleClause(); + if (FailClause) { + OpenMPClauseKind FailParameter = FailClause->getFailParameter(); + if (FailParameter == llvm::omp::OMPC_relaxed) + FailAO = llvm::AtomicOrdering::Monotonic; + else if (FailParameter == llvm::omp::OMPC_acquire) + FailAO = llvm::AtomicOrdering::Acquire; + else if (FailParameter == llvm::omp::OMPC_seq_cst) + FailAO = llvm::AtomicOrdering::SequentiallyConsistent; + } + } + LexicalScope Scope(*this, S.getSourceRange()); EmitStopPoint(S.getAssociatedStmt()); - emitOMPAtomicExpr(*this, Kind, AO, S.isPostfixUpdate(), S.getX(), S.getV(), - S.getR(), S.getExpr(), S.getUpdateExpr(), S.getD(), - S.getCondExpr(), S.isXLHSInRHSPart(), S.isFailOnly(), - S.getBeginLoc()); + emitOMPAtomicExpr(*this, Kind, AO, FailAO, S.isPostfixUpdate(), S.getX(), + S.getV(), S.getR(), S.getExpr(), S.getUpdateExpr(), + S.getD(), S.getCondExpr(), S.isXLHSInRHSPart(), + S.isFailOnly(), S.getBeginLoc()); } static void emitCommonOMPTargetDirective(CodeGenFunction &CGF, diff --git a/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp b/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp index 753a8fd74fa6..f8038497d90a 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CodeGenAction.cpp @@ -1139,8 +1139,7 @@ CodeGenAction::loadModule(MemoryBufferRef MBRef) { // Strip off a leading diagnostic code if there is one. StringRef Msg = Err.getMessage(); - if (Msg.starts_with("error: ")) - Msg = Msg.substr(7); + Msg.consume_front("error: "); unsigned DiagID = CI.getDiagnostics().getCustomDiagID(DiagnosticsEngine::Error, "%0"); diff --git a/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp b/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp index 7b2c31139b0b..63b9a1fdb988 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/Targets/LoongArch.cpp *** 18251 LINES SKIPPED *** From nobody Sat Apr 20 10:34:21 2024 X-Original-To: dev-commits-src-branches@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 4VM7DF4frfz5HWWg; Sat, 20 Apr 2024 10:34:21 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DF1bB1z4SGZ; Sat, 20 Apr 2024 10:34:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609261; 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=0ls0aZ4POMrOsG7Eab8n4LSDzJBAFtA+u0NMUnDz0do=; b=SL/wF8oBRNj9fJC9ABYPXe8NN2Xq7uOIzdENFoSdhbKY/Ip+lHXUoO/Qub5f/hyvniba1o NV6E1jpRXO8esyCYoHAffPXktEefBOHLpetgJfRjNgInYyO6XlZFq+cs1PvaNUeZEmT/wr A452ZFRAYL4mNH1DmcAoLjI9Sfljzp+R+IvfySEIbep+NKplNK84MTfAjbEsOp65UjVhus X3gmJOjncwZDlsTRVmaKxtK0jlSus4Zol7yTX9xc7yDB5LQLzJTD+gdab14MJbBfjd4MMF OKdLSTP298qH1+smrxhKnhNpIU77NxLZh5mvxaJoBCs8k3kSiZIwAnh2I/QzTw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609261; a=rsa-sha256; cv=none; b=giNE+g3GQGgNfcxpt0RhddLUgDJUBMFCdzHUNrdQwRReIwR22tGqMMctrY3OhSvJvn+B4Q jg4mnceBTsjXOfe1HH74mxC40z5SQ8hDcBAW9/+M6DRaop+aNTxP/hLKkWy4+3tSmBQ0fx kUrEmWDLF9wlyXdilV1TAB1gDr5I0umy06SYtvgGCVDj1FaDyPjurTRjZ8jr2mFADr7gnR X8yehWGP+soyoyeIvhy1/8WwXbYdTmTo4BBvoVpyfAA9md3m3qGLcXQwcxe0BCBnw33xwI I+OHSaS9Iw10xzLp19F6U2u7OKM+P/gmTHIe4zaI8TPfiS95e7LScMh1dkfHyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609261; 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=0ls0aZ4POMrOsG7Eab8n4LSDzJBAFtA+u0NMUnDz0do=; b=iSs0zkdCwDNOeNZ/NEd1QjcACvIvd/A3dJ/WsYx0vV99AcIsC/Zu+E6TLqBSauEbnPbTJr R8FDkIcMwJ9ZCVpBlqrVdyOzJyLxpncXDvBbXt+3rXNIPXX1WJHHaPotpQsHYRaeK6tF2q 10w1SWNNuQAY06Pf+LgTQqvfn3jCJBvMhUirVr2I0ZNyB8v8AZpPPhdrcYOMfLVF6G11u2 bXTwZyxyg4dPkw8vF2Z/t023lMcNNXRBOQ+RWwa9LwlDtg1tlMPy4Lu5HMu/xCfWWplAQr SOrGO0USqsJ9joSpHbl+VHWNbsNBge7nFPhX3TOROJI7F9eoHZqRk3RizcLoWQ== 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 4VM7DF188gzYqs; Sat, 20 Apr 2024 10:34:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYLCj013413; Sat, 20 Apr 2024 10:34:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYL6r013410; Sat, 20 Apr 2024 10:34:21 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:21 GMT Message-Id: <202404201034.43KAYL6r013410@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: 15ce79bc8b1f - stable/13 - Tentatively merge https://github.com/llvm/llvm-project/pull/77242 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 15ce79bc8b1f02ad1dbab2f2d7f6806b4801c09b Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=15ce79bc8b1f02ad1dbab2f2d7f6806b4801c09b commit 15ce79bc8b1f02ad1dbab2f2d7f6806b4801c09b Author: Dimitry Andric AuthorDate: 2024-01-07 16:03:13 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:41 +0000 Tentatively merge https://github.com/llvm/llvm-project/pull/77242 [libcxx] Re-include in __config for FreeBSD In 0a97720d0197 some changes were made to `__config` for assuming that `__BYTE_ORDER__` is always present. However, this deleted a `` include for FreeBSD, which is required to get the value of `__FreeBSD_version`, and that is used later in the file to determine whether `_LIBCPP_C_HAS_NO_GETS` needs to be enabled. Include `` just after the other includes used for feature detection, to fix this. Note that when FreeBSD 13 is EOLed, this can be removed, as then all supported FreeBSD versions will no longer have `gets()`. PR: 276104 MFC after: 1 month (cherry picked from commit 653487bbc8006839d0895811942bb8a2fcdd5aa8) --- contrib/llvm-project/libcxx/include/__config | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 40e6da8bc03a..f52fb0441293 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -477,6 +477,10 @@ _LIBCPP_HARDENING_MODE_DEBUG # include // for __NATIVE_ASCII_F # endif +# ifdef __FreeBSD__ +# include // for __FreeBSD_version +# endif + # ifndef __BYTE_ORDER__ # error \ "Your compiler doesn't seem to define __BYTE_ORDER__, which is required by libc++ to know the endianness of your target platform" From nobody Sat Apr 20 10:34:22 2024 X-Original-To: dev-commits-src-branches@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 4VM7DH0Lp7z5HWWj; Sat, 20 Apr 2024 10:34:23 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DG2ZT6z4SPh; Sat, 20 Apr 2024 10:34:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609262; 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=Ek9/bzdA82lPmiG5b8dXxT4kmxqj78zqh9LJcahgPIA=; b=RO95UW5ttnmJG3z+JiQ5Yk7sFS4NcAvMGxtL/cyPo7BZ2nie/J2uoIVFCFbHNiQTe9JFuy /HFsY8pkDfYMcasrJejpj+yVUSq6Zp+EMoi+umbLCbi/4a/yDqT2jvk5JSfsW9tRbtRBQC YqKIKSpNKjJb12LnS6N8VesNYaiLBlFSAxYPSm69Q3ZgBRcnsBHOmlGDUtwNjpEcg8T5vH guV+V9JiOqakQSQQtqKzSA8XywUXDkl6HY9N7XRW82bDbjxJvIrShhnuJha4jxleeNuKQW EK+KxXNth660MCx1EiObWs0yriFY84jzBB0gi1OWWlpGMYbReKxos/XnwvYk6Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609262; a=rsa-sha256; cv=none; b=OrIYWAoA4vMhcF7N5TApHfrTV1UoT7gUOQpFKW+cw3Z0lvjgpKV4CWWiM6MIXXAaEhKyv1 4RsGjVwTJV5Q4grhumOtOkCpCxqINOPnPItLOGWsYLk5KTNlFkHVqExSkkQe5yYQSEg+Km vfJTqg/S6Gpb7CtJDG+cAcopMNg8QFlOdffsgsA8UWJhw4P4USU+8YRfldCbUlid5UOqlZ bUftnmEbU0Uvj5hNS02hjaxDhEKaMRMICmz0xT/iLTVzarGlJQgWddL1bGzSliaz8HUQE6 Okq1LmGECXoBGWAzwLWnMC8iX85qGOAH9hnxsWwLrtDu1eudlxS8XdTb73M3Fg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609262; 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=Ek9/bzdA82lPmiG5b8dXxT4kmxqj78zqh9LJcahgPIA=; b=rEKTjaHDmDJ/wH1E54b7/2jvAWGXfSp5MmgJfQcVk+iHN1h8i/GEBk/fnBrvmOgjKulxD2 +ItNBmpvABD1D3vwItdmbOgCqk89iXHpbfr/Gk2ZRZvC/3JrF3I6SNizG6dX7ZiiPGCJMu 2UpOg0j2fbj9j2DjzvSezM+/RMli4pyCs6TG61glHvJ2tzYDIxFMtPTamBykTbK1ha1Use Uin2+9Ryg2PulUdE3YrqNw9kvRUm4kmlqun6KrVv3ikWN93T7jA4Cdpe8sOl9JiHLJRlC9 9nIKxP+HAWcx56T7WwTnTXBy8b+hrz0JiGjepBnKG0LzY+n/76JDkExPwDAfWQ== 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 4VM7DG2BhrzYn4; Sat, 20 Apr 2024 10:34:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYMkR013459; Sat, 20 Apr 2024 10:34:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYMSC013456; Sat, 20 Apr 2024 10:34:22 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:22 GMT Message-Id: <202404201034.43KAYMSC013456@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: 335f7960dc37 - stable/13 - Add two FreeBSD customizations to libc++ List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 335f7960dc37e3f149c0d795909e2d3948c4a554 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=335f7960dc37e3f149c0d795909e2d3948c4a554 commit 335f7960dc37e3f149c0d795909e2d3948c4a554 Author: Dimitry Andric AuthorDate: 2024-01-07 11:32:29 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:41 +0000 Add two FreeBSD customizations to libc++ This is intended to better support ports usage of older clang versions: * Add _LIBCPP_ENABLE_COMPILER_VERSION_CHECKS block around compiler version checks, to avoid any warnings about support. This makes some ports that use -Werror fall over. * When using clang < 15.0, avoid using a type visibility attribute on the std namespace, as older versions of clang do not support this. PR: 276104 MFC after: 1 month (cherry picked from commit 412fa3436f0d1fe4a7e5e3b66783aa40f599125e) --- contrib/llvm-project/libcxx/include/__config | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index f52fb0441293..959082502a49 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -32,6 +32,7 @@ // Warn if a compiler version is used that is not supported anymore // LLVM RELEASE Update the minimum compiler versions +#if defined(_LIBCPP_ENABLE_COMPILER_VERSION_CHECKS) // FreeBSD customization # if defined(_LIBCPP_CLANG_VER) # if _LIBCPP_CLANG_VER < 1600 # warning "Libc++ only supports Clang 16 and later" @@ -45,6 +46,7 @@ # warning "Libc++ only supports GCC 13 and later" # endif # endif +#endif // _LIBCPP_ENABLE_COMPILER_VERSION_CHECKS // The attributes supported by clang are documented at https://clang.llvm.org/docs/AttributeReference.html @@ -725,7 +727,8 @@ typedef __char32_t char32_t; # define _LIBCPP_TEMPLATE_VIS # endif -# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) +# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) \ + && _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization # define _LIBCPP_TYPE_VISIBILITY_DEFAULT __attribute__((__type_visibility__("default"))) # else # define _LIBCPP_TYPE_VISIBILITY_DEFAULT From nobody Sat Apr 20 10:34:23 2024 X-Original-To: dev-commits-src-branches@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 4VM7DK5Ktlz5HWbx; Sat, 20 Apr 2024 10:34:25 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DJ4zPnz4Scm; Sat, 20 Apr 2024 10:34:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609264; 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=0hzTVwlNzhvjNbk+zT1PXyoL02Wy5IM5JMOL7lMF3jo=; b=USgRMfIMYBsYF+e/NkY0rwDfCcEiaBxjYwUk2VEXRNQVjYNIGfSRZ3EJxeJ1cNeCFSDWe8 zXJGsiNfGumPgszCAgR/N1YTbpZGdncDdd8egIibEzk3uUoGyPlv2WXZKVnb2/uzdcW+6w rmmFsfrlXdoCE4kibm2zg03MQEGuDvhTs1jT9VSDI6+EWpmga+nV3IdqRFddaQfV0cegit +KhRJSX+0KNOZqxincdEZe6+cDXD6z8D1ttD3OO6O+gyYx9sjHP+CpS6m/WDn/G6rHbv2L oJ8nK8pfeb7baoeeQrNsYUsrhrrnpMMBN6nHGmVKUAYeHeqmFTFmmU0AH+yoGA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609264; a=rsa-sha256; cv=none; b=ihAkt4RymDWUlTsjQle3EUBnniRTJzTR2vVrZ1bqFtlo9jvA5a9+SBLNKluVjBvx163Os7 Tdjx26NDwRnAe16mmaIgELEYz/dpPZTg6N2xllpnRjKIXEMuimotBUPOU/Nnfs77Oho4Zx 17bxufFdypsojA13D91saN6cs9V0O2eLlHQDJxhlvb8l/SWrN5mqNzcdQRsb3mlpLf/M6N LRHUBZxiUavskV4FlL7w6byoC9ueSPVSBPWCz4ZSG9FuMCIxPwX3DaJJReKfoAcWYYOIWm iX0rlPgBDx5JOZKHYUhiTDSSxDYQjTEQBJGWbxG+fylITFjQ5ccpSp2uwtPcVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609264; 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=0hzTVwlNzhvjNbk+zT1PXyoL02Wy5IM5JMOL7lMF3jo=; b=Q+mVFUsFKW7RFYBKt8V+Rmpceh5Y2XZrXV3zZokXkY/ha/iyvkDhY5NSHn8kUlE0b5q5JD yHTaxvSMuzsZPSATZWSuYQJiJ4KI7umm/lgI7GLbohrCd2JTWe5zphuigLkS6InLZt9r4T qjF0Yr8dW0wM31nibOBZzuM4nhyqcv+KA6/46dpyxUtzYHKO88vBfCV2UZsjVulAvg8135 7HNpHCnKpydA2FM7Jn3iVa+0HvbEvRg2Hk7RUg9h7lTHTKBPA554TPRSlyV3KA1HnR80le 72KDRAwe2A7fAQ/Zsp1OVH/2qBifnmFt0I4uUKO6PrqfKJmoOi92z04FHXdJ3Q== 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 4VM7DJ3fZ9zZFh; Sat, 20 Apr 2024 10:34:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYOkq013501; Sat, 20 Apr 2024 10:34:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYNt9013498; Sat, 20 Apr 2024 10:34:23 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:23 GMT Message-Id: <202404201034.43KAYNt9013498@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: ed89c59104c1 - stable/13 - Merge llvm-project main llvmorg-18-init-16595-g7c00a5be5cde List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: ed89c59104c13195cbbad881f64c6a71f687c1e4 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ed89c59104c13195cbbad881f64c6a71f687c1e4 commit ed89c59104c13195cbbad881f64c6a71f687c1e4 Author: Dimitry Andric AuthorDate: 2024-01-09 20:00:28 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:41 +0000 Merge llvm-project main llvmorg-18-init-16595-g7c00a5be5cde This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16595-g7c00a5be5cde. PR: 276104 MFC after: 1 month (cherry picked from commit 1db9f3b21e39176dd5b67cf8ac378633b172463e) --- .../llvm-project/clang/include/clang/AST/Attr.h | 1 + .../llvm-project/clang/include/clang/AST/DeclCXX.h | 8 + .../clang/include/clang/AST/TextNodeDumper.h | 2 + .../llvm-project/clang/include/clang/AST/Type.h | 2 + .../clang/Analysis/Analyses/UnsafeBufferUsage.h | 2 +- .../Analysis/Analyses/UnsafeBufferUsageGadgets.def | 1 + .../clang/include/clang/Analysis/CFG.h | 4 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 23 + .../clang/include/clang/Basic/AttrDocs.td | 35 +- .../clang/include/clang/Basic/CodeGenOptions.def | 1 + .../include/clang/Basic/DiagnosticCommonKinds.td | 3 + .../include/clang/Basic/DiagnosticDriverKinds.td | 3 + .../include/clang/Basic/DiagnosticParseKinds.td | 2 + .../include/clang/Basic/DiagnosticSemaKinds.td | 14 +- .../clang/include/clang/Basic/ObjCRuntime.h | 28 +- .../clang/include/clang/Basic/OpenACCKinds.h | 39 +- .../clang/include/clang/Basic/arm_sve.td | 115 ++- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 1 + .../include/clang/Basic/riscv_sifive_vector.td | 10 +- .../clang/include/clang/Driver/Options.td | 12 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 15 +- .../clang/include/clang/Sema/Template.h | 1 + contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 23 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 39 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 13 +- .../clang/lib/AST/ComputeDependence.cpp | 2 + contrib/llvm-project/clang/lib/AST/Decl.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 50 +- .../llvm-project/clang/lib/AST/FormatString.cpp | 1 - .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 4 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 6 - .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 10 + contrib/llvm-project/clang/lib/AST/Type.cpp | 7 + .../clang/lib/Analysis/PathDiagnostic.cpp | 7 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 38 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 64 ++ contrib/llvm-project/clang/lib/Basic/Targets/ARM.h | 13 + contrib/llvm-project/clang/lib/Basic/Targets/AVR.h | 4 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 23 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 3 + contrib/llvm-project/clang/lib/CodeGen/CGClass.cpp | 6 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 61 +- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 2 + contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 14 +- .../clang/lib/CodeGen/CodeGenFunction.cpp | 98 +- .../clang/lib/CodeGen/CodeGenFunction.h | 58 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 4 + .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 263 ++++- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.h | 14 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 405 +++++++- .../clang/lib/CodeGen/CoverageMappingGen.h | 12 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 3 + contrib/llvm-project/clang/lib/Driver/Driver.cpp | 11 + .../clang/lib/Driver/ToolChains/Arch/Mips.cpp | 8 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 6 +- .../clang/lib/Driver/ToolChains/BareMetal.cpp | 5 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 11 + .../clang/lib/Driver/ToolChains/Gnu.cpp | 9 + .../clang/lib/Driver/ToolChains/MinGW.cpp | 25 +- .../clang/lib/Format/TokenAnnotator.cpp | 8 + contrib/llvm-project/clang/lib/Headers/arm_acle.h | 59 ++ .../clang/lib/Headers/llvm_libc_wrappers/stdio.h | 34 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 4 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 3 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 2 + .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 129 ++- .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 23 +- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 17 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 94 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 19 + contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 44 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 55 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 56 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 90 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 11 + .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 79 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 78 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 20 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 1 + contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 8 +- .../clang/utils/TableGen/ClangASTNodesEmitter.cpp | 103 +- .../clang/utils/TableGen/SveEmitter.cpp | 3 + .../llvm-project/clang/utils/TableGen/TableGen.cpp | 3 +- .../clang/utils/TableGen/TableGenBackends.h | 10 +- .../compiler-rt/lib/asan/asan_suppressions.cpp | 7 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 6 +- .../compiler-rt/lib/lsan/lsan_common.cpp | 7 +- contrib/llvm-project/compiler-rt/lib/msan/msan.h | 34 +- .../compiler-rt/lib/msan/msan_allocator.cpp | 40 +- .../compiler-rt/lib/msan/msan_new_delete.cpp | 26 +- .../compiler-rt/lib/orc/executor_symbol_def.h | 151 +++ .../orc/tests/unit/executor_symbol_def_test.cpp | 19 + .../unit/simple_packed_serialization_test.cpp | 20 +- .../tests/unit/simple_packed_serialization_utils.h | 34 + .../lib/sanitizer_common/sanitizer_common.h | 3 + .../sanitizer_platform_interceptors.h | 3 +- .../sanitizer_stacktrace_libcdep.cpp | 12 +- .../lib/sanitizer_common/sanitizer_symbolizer.h | 20 + .../sanitizer_symbolizer_report.cpp | 25 +- .../compiler-rt/lib/tsan/rtl/tsan_report.cpp | 26 +- .../compiler-rt/lib/ubsan/ubsan_diag.cpp | 2 +- .../compiler-rt/lib/ubsan/ubsan_diag.h | 20 - .../libcxx/include/__algorithm/pop_heap.h | 3 +- .../libcxx/include/__algorithm/sift_down.h | 2 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 4 +- .../libcxx/include/__charconv/to_chars_base_10.h | 6 +- .../libcxx/include/__charconv/to_chars_integral.h | 2 +- .../libcxx/include/__charconv/traits.h | 4 +- .../include/__chrono/parser_std_format_spec.h | 7 +- contrib/llvm-project/libcxx/include/__config | 7 + .../include/__filesystem/directory_iterator.h | 3 +- .../libcxx/include/__filesystem/path_iterator.h | 4 +- .../llvm-project/libcxx/include/__format/buffer.h | 12 +- .../libcxx/include/__format/format_arg.h | 2 +- .../libcxx/include/__format/format_arg_store.h | 8 +- .../libcxx/include/__format/formatter_bool.h | 2 +- .../include/__format/formatter_floating_point.h | 55 +- .../libcxx/include/__format/formatter_integral.h | 16 +- .../libcxx/include/__format/formatter_output.h | 6 +- .../libcxx/include/__format/formatter_string.h | 5 +- .../include/__format/parser_std_format_spec.h | 7 +- .../libcxx/include/__format/range_formatter.h | 5 +- .../llvm-project/libcxx/include/__format/unicode.h | 14 +- .../libcxx/include/__format/write_escaped.h | 2 +- contrib/llvm-project/libcxx/include/__hash_table | 5 +- .../libcxx/include/__iterator/advance.h | 13 +- .../llvm-project/libcxx/include/__iterator/next.h | 6 +- .../llvm-project/libcxx/include/__iterator/prev.h | 6 +- .../__random/negative_binomial_distribution.h | 7 +- .../libcxx/include/__ranges/chunk_by_view.h | 20 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 3 +- .../llvm-project/libcxx/include/__thread/thread.h | 2 +- .../libcxx/include/__utility/exception_guard.h | 2 +- .../libcxx/include/__utility/unreachable.h | 2 +- contrib/llvm-project/libcxx/include/fstream | 50 + contrib/llvm-project/libcxx/include/print | 8 +- contrib/llvm-project/libcxx/include/regex | 23 +- contrib/llvm-project/libcxx/include/set | 32 +- contrib/llvm-project/libcxx/include/span | 18 + contrib/llvm-project/libcxx/include/sstream | 6 +- contrib/llvm-project/libcxx/include/tuple | 32 +- contrib/llvm-project/libcxx/include/version | 4 +- contrib/llvm-project/libcxx/src/filesystem/error.h | 2 +- .../libcxx/src/filesystem/format_string.h | 2 +- .../libcxx/src/filesystem/posix_compat.h | 6 +- contrib/llvm-project/libcxx/src/fstream.cpp | 37 + .../libcxx/src/include/to_chars_floating_point.h | 20 +- .../llvm-project/libcxx/src/memory_resource.cpp | 2 +- contrib/llvm-project/libcxx/src/strstream.cpp | 2 +- contrib/llvm-project/libcxx/src/system_error.cpp | 2 +- .../llvm-project/libunwind/src/UnwindCursor.hpp | 77 +- contrib/llvm-project/lld/COFF/Config.h | 4 +- contrib/llvm-project/lld/ELF/Arch/AArch64.cpp | 3 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 42 + contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 2 + contrib/llvm-project/lld/ELF/InputSection.cpp | 11 +- contrib/llvm-project/lld/ELF/LinkerScript.cpp | 4 + contrib/llvm-project/lld/ELF/Relocations.cpp | 6 +- contrib/llvm-project/lld/ELF/ScriptParser.cpp | 27 +- contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 24 +- contrib/llvm-project/lld/ELF/SyntheticSections.h | 6 +- contrib/llvm-project/lld/ELF/Target.h | 10 + contrib/llvm-project/lld/ELF/Writer.cpp | 21 +- contrib/llvm-project/lld/ELF/Writer.h | 1 + .../lldb/include/lldb/API/SBBreakpoint.h | 2 + .../include/lldb/Breakpoint/BreakpointIDList.h | 6 +- .../lldb/include/lldb/Symbol/CompileUnit.h | 23 +- .../lldb/include/lldb/Symbol/SymbolFile.h | 2 +- .../lldb/include/lldb/Symbol/SymbolFileOnDemand.h | 2 +- .../lldb/include/lldb/Utility/FileSpecList.h | 106 +- .../lldb/include/lldb/Utility/StructuredData.h | 28 +- .../llvm-project/lldb/source/API/SBCompileUnit.cpp | 2 +- .../lldb/source/Breakpoint/BreakpointIDList.cpp | 21 +- .../Breakpoint/BreakpointResolverAddress.cpp | 12 +- .../source/Breakpoint/BreakpointResolverName.cpp | 8 +- .../source/Commands/CommandObjectBreakpoint.cpp | 4 +- .../lldb/source/Commands/CommandObjectSource.cpp | 2 +- .../llvm-project/lldb/source/Core/ModuleList.cpp | 2 +- .../ExpressionParser/Clang/ClangUserExpression.cpp | 12 +- .../Clang/CppModuleConfiguration.cpp | 6 +- .../TSan/InstrumentationRuntimeTSan.cpp | 5 +- .../source/Plugins/JITLoader/GDB/JITLoaderGDB.cpp | 2 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.cpp | 5 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.h | 3 +- .../source/Plugins/SymbolFile/CTF/SymbolFileCTF.h | 2 +- .../SymbolFile/DWARF/DWARFASTParserClang.cpp | 34 +- .../Plugins/SymbolFile/DWARF/DWARFASTParserClang.h | 1 + .../source/Plugins/SymbolFile/DWARF/DWARFIndex.cpp | 20 + .../source/Plugins/SymbolFile/DWARF/DWARFIndex.h | 14 + .../SymbolFile/DWARF/DebugNamesDWARFIndex.cpp | 2 +- .../SymbolFile/DWARF/DebugNamesDWARFIndex.h | 2 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 116 ++- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.h | 9 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp | 4 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.h | 2 +- .../Plugins/SymbolFile/JSON/SymbolFileJSON.h | 2 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.cpp | 7 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.h | 2 +- .../Plugins/SymbolFile/PDB/SymbolFilePDB.cpp | 2 +- .../source/Plugins/SymbolFile/PDB/SymbolFilePDB.h | 2 +- .../Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp | 2 +- .../Plugins/SymbolFile/Symtab/SymbolFileSymtab.h | 2 +- .../lldb/source/Symbol/CompileUnit.cpp | 13 +- .../lldb/source/Symbol/SymbolFileOnDemand.cpp | 2 +- .../lldb/source/Target/DynamicRegisterInfo.cpp | 15 +- .../lldb/source/Utility/FileSpecList.cpp | 58 +- .../llvm/include/llvm/Analysis/AliasSetTracker.h | 1 + .../llvm/include/llvm/Analysis/AssumptionCache.h | 2 + .../include/llvm/Analysis/BlockFrequencyInfo.h | 2 + .../include/llvm/Analysis/BranchProbabilityInfo.h | 2 + .../llvm/include/llvm/Analysis/CFGSCCPrinter.h | 1 + .../llvm/include/llvm/Analysis/CallGraph.h | 4 + .../llvm/include/llvm/Analysis/CallPrinter.h | 2 + .../llvm/include/llvm/Analysis/CostModel.h | 2 + .../llvm/include/llvm/Analysis/CycleAnalysis.h | 2 + .../llvm-project/llvm/include/llvm/Analysis/DDG.h | 1 + .../llvm/include/llvm/Analysis/DDGPrinter.h | 1 + .../llvm/include/llvm/Analysis/Delinearization.h | 1 + .../llvm/include/llvm/Analysis/DemandedBits.h | 2 + .../include/llvm/Analysis/DependenceAnalysis.h | 2 + .../llvm/include/llvm/Analysis/DominanceFrontier.h | 2 + .../llvm/Analysis/FunctionPropertiesAnalysis.h | 2 + .../include/llvm/Analysis/IRSimilarityIdentifier.h | 1 + .../llvm/include/llvm/Analysis/InlineAdvisor.h | 3 +- .../llvm/include/llvm/Analysis/InlineCost.h | 1 + .../llvm/Analysis/InlineSizeEstimatorAnalysis.h | 2 + .../llvm/include/llvm/Analysis/LazyCallGraph.h | 4 + .../llvm/include/llvm/Analysis/LazyValueInfo.h | 2 + .../llvm/include/llvm/Analysis/LoopCacheAnalysis.h | 2 + .../llvm/include/llvm/Analysis/LoopInfo.h | 2 + .../llvm/include/llvm/Analysis/LoopNestAnalysis.h | 2 + .../llvm/include/llvm/Analysis/MemDerefPrinter.h | 1 + .../llvm/include/llvm/Analysis/MemoryBuiltins.h | 165 ++-- .../llvm/include/llvm/Analysis/MemorySSA.h | 5 + .../include/llvm/Analysis/ModuleDebugInfoPrinter.h | 1 + .../llvm/include/llvm/Analysis/MustExecute.h | 2 + .../llvm/include/llvm/Analysis/PhiValues.h | 1 + .../llvm/include/llvm/Analysis/PostDominators.h | 2 + .../include/llvm/Analysis/ProfileSummaryInfo.h | 1 + .../llvm/include/llvm/Analysis/RegionInfo.h | 3 + .../llvm/include/llvm/Analysis/ScalarEvolution.h | 3 + .../llvm/include/llvm/Analysis/StackLifetime.h | 1 + .../include/llvm/Analysis/StackSafetyAnalysis.h | 2 + .../llvm/include/llvm/Analysis/StructuralHash.h | 2 + .../include/llvm/Analysis/TargetTransformInfo.h | 8 + .../llvm/Analysis/TargetTransformInfoImpl.h | 4 +- .../include/llvm/Analysis/UniformityAnalysis.h | 2 + .../llvm/include/llvm/Analysis/ValueTracking.h | 9 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 36 + .../llvm/include/llvm/BinaryFormat/ELF.h | 1 + .../llvm/BinaryFormat/ELFRelocs/LoongArch.def | 23 + .../llvm/include/llvm/Bitstream/BitstreamWriter.h | 6 +- .../llvm/include/llvm/CodeGen/AccelTable.h | 15 +- .../llvm/CodeGen/BasicBlockSectionsProfileReader.h | 83 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 25 +- .../llvm/include/llvm/CodeGen/CodeGenPrepare.h | 35 + .../llvm/include/llvm/CodeGen/FastISel.h | 14 + .../llvm/include/llvm/CodeGen/GCMetadata.h | 11 + .../include/llvm/CodeGen/GlobalISel/IRTranslator.h | 4 + .../GlobalISel/LegalizationArtifactCombiner.h | 21 +- .../llvm/CodeGen/GlobalISel/LegalizerHelper.h | 18 +- .../llvm/CodeGen/GlobalISel/LegalizerInfo.h | 10 +- .../include/llvm/CodeGen/MachinePassRegistry.def | 9 +- .../llvm/CodeGen/NonRelocatableStringpool.h | 3 +- .../llvm/include/llvm/CodeGen/Passes.h | 4 +- .../llvm/include/llvm/CodeGen/RuntimeLibcalls.h | 6 + .../llvm/include/llvm/CodeGen/SelectionDAGNodes.h | 20 +- .../include/llvm/CodeGen/ShadowStackGCLowering.h | 24 + .../llvm/include/llvm/CodeGen/StackProtector.h | 93 +- .../include/llvm/CodeGen/SwitchLoweringUtils.h | 16 + .../AddressesMap.h | 10 +- .../llvm/DWARFLinker/{ => Classic}/DWARFLinker.h | 216 +--- .../{ => Classic}/DWARFLinkerCompileUnit.h | 12 +- .../{ => Classic}/DWARFLinkerDeclContext.h | 12 +- .../llvm/DWARFLinker/{ => Classic}/DWARFStreamer.h | 28 +- .../DWARFFile.h | 17 +- .../include/llvm/DWARFLinker/DWARFLinkerBase.h | 100 ++ .../Parallel}/DWARFLinker.h | 108 +- .../StringPool.h | 25 +- .../include/llvm/DebugInfo/DWARF/DWARFDebugMacro.h | 9 +- .../llvm/include/llvm/DebugInfo/DWARF/DWARFUnit.h | 6 +- .../llvm/include/llvm/Demangle/Demangle.h | 5 +- .../llvm/include/llvm/Demangle/ItaniumDemangle.h | 22 +- .../include/llvm/ExecutionEngine/JITLink/JITLink.h | 5 + .../llvm/include/llvm/ExecutionEngine/Orc/Core.h | 10 +- .../Orc/EPCDynamicLibrarySearchGenerator.h | 23 +- .../ExecutionEngine/Orc/EPCGenericDylibManager.h | 7 +- .../llvm/ExecutionEngine/Orc/ExecutionUtils.h | 20 +- .../ExecutionEngine/Orc/Shared/ExecutorSymbolDef.h | 58 ++ .../llvm/ExecutionEngine/Orc/Shared/OrcRTBridge.h | 3 +- .../Orc/Shared/TargetProcessControlTypes.h | 3 +- .../Orc/TargetProcess/JITLoaderGDB.h | 26 + .../Orc/TargetProcess/SimpleExecutorDylibManager.h | 5 +- .../llvm-project/llvm/include/llvm/IR/Dominators.h | 3 + .../include/llvm/IR/GetElementPtrTypeIterator.h | 57 +- .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 7 +- .../llvm/include/llvm/IR/IntrinsicsSPIRV.td | 1 + .../llvm/include/llvm/IR/PatternMatch.h | 2 +- .../llvm/include/llvm/IR/SafepointIRVerifier.h | 2 + .../llvm/include/llvm/InitializePasses.h | 4 +- contrib/llvm-project/llvm/include/llvm/LTO/LTO.h | 4 +- .../llvm-project/llvm/include/llvm/LinkAllPasses.h | 2 +- .../llvm/include/llvm/MC/MCAsmBackend.h | 6 +- .../llvm/include/llvm/Object/ELFObjectFile.h | 36 + .../llvm/include/llvm/Object/ELFTypes.h | 3 + .../llvm/include/llvm/Object/ObjectFile.h | 1 + .../include/llvm/Passes/StandardInstrumentations.h | 2 +- .../llvm/include/llvm/Support/RISCVISAInfo.h | 6 +- .../llvm/Target/GlobalISel/SelectionDAGCompat.td | 1 + .../include/llvm/Target/TargetInstrPredicate.td | 6 + .../llvm/include/llvm/Target/TargetMachine.h | 4 +- .../llvm/include/llvm/Target/TargetSchedule.td | 113 +++ .../llvm/include/llvm/Target/TargetSelectionDAG.td | 13 + .../llvm/TargetParser/AArch64TargetParser.h | 7 +- .../llvm/include/llvm/TargetParser/Triple.h | 6 + .../llvm/Transforms/Scalar/IVUsersPrinter.h | 1 + .../Transforms/Scalar/LoopAccessAnalysisPrinter.h | 1 + .../include/llvm/Transforms/Utils/PredicateInfo.h | 2 + .../llvm/lib/Analysis/AssumptionCache.cpp | 13 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 61 +- .../llvm/lib/Analysis/ConstraintSystem.cpp | 4 +- .../llvm-project/llvm/lib/Analysis/InlineCost.cpp | 2 +- .../llvm/lib/Analysis/InstructionSimplify.cpp | 14 +- contrib/llvm-project/llvm/lib/Analysis/Local.cpp | 2 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 5 +- .../llvm-project/llvm/lib/Analysis/LoopInfo.cpp | 4 +- .../llvm/lib/Analysis/MemoryBuiltins.cpp | 308 +++--- .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 17 +- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 9 + .../llvm/lib/Analysis/VFABIDemangling.cpp | 9 +- .../llvm/lib/Analysis/ValueTracking.cpp | 11 +- .../lib/BinaryFormat/AMDGPUMetadataVerifier.cpp | 1 + .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 67 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 80 +- .../llvm/lib/CodeGen/BasicBlockPathCloning.cpp | 11 +- .../llvm/lib/CodeGen/BasicBlockSections.cpp | 8 +- .../CodeGen/BasicBlockSectionsProfileReader.cpp | 52 +- contrib/llvm-project/llvm/lib/CodeGen/CodeGen.cpp | 2 +- .../llvm/lib/CodeGen/CodeGenPrepare.cpp | 127 ++- .../llvm/lib/CodeGen/GCRootLowering.cpp | 33 +- .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 81 +- .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 312 +++++- .../llvm/lib/CodeGen/NonRelocatableStringpool.cpp | 3 - .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 160 +-- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 10 +- .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 329 ++++--- .../llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp | 4 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 26 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 48 +- .../CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp | 17 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h | 2 + .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 10 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 14 +- .../SelectionDAG/SelectionDAGAddressAnalysis.cpp | 19 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 117 +-- .../lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h | 6 - .../CodeGen/SelectionDAG/SelectionDAGDumper.cpp | 5 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 19 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 72 +- .../llvm/lib/CodeGen/ShadowStackGCLowering.cpp | 97 +- .../llvm/lib/CodeGen/StackProtector.cpp | 154 ++- .../llvm/lib/CodeGen/SwitchLoweringUtils.cpp | 81 ++ .../llvm/lib/CodeGen/TargetLoweringBase.cpp | 40 +- .../llvm/lib/CodeGen/TargetPassConfig.cpp | 4 +- .../lib/DWARFLinker/{ => Classic}/DWARFLinker.cpp | 66 +- .../{ => Classic}/DWARFLinkerCompileUnit.cpp | 7 +- .../{ => Classic}/DWARFLinkerDeclContext.cpp | 7 +- .../DWARFLinker/{ => Classic}/DWARFStreamer.cpp | 36 +- .../Parallel}/AcceleratorRecordsSaver.cpp | 8 +- .../Parallel}/AcceleratorRecordsSaver.h | 14 +- .../Parallel}/ArrayList.h | 18 +- .../Parallel}/DIEAttributeCloner.cpp | 8 +- .../Parallel}/DIEAttributeCloner.h | 14 +- .../Parallel}/DIEGenerator.h | 14 +- .../Parallel}/DWARFEmitterImpl.cpp | 10 +- .../Parallel}/DWARFEmitterImpl.h | 16 +- .../Parallel}/DWARFLinker.cpp | 12 +- .../Parallel}/DWARFLinkerCompileUnit.cpp | 5 +- .../Parallel}/DWARFLinkerCompileUnit.h | 16 +- .../Parallel}/DWARFLinkerGlobalData.h | 24 +- .../Parallel}/DWARFLinkerImpl.cpp | 207 ++-- .../Parallel}/DWARFLinkerImpl.h | 20 +- .../Parallel}/DWARFLinkerTypeUnit.cpp | 7 +- .../Parallel}/DWARFLinkerTypeUnit.h | 14 +- .../Parallel}/DWARFLinkerUnit.cpp | 8 +- .../Parallel}/DWARFLinkerUnit.h | 18 +- .../Parallel}/DebugLineSectionEmitter.h | 31 +- .../Parallel}/DependencyTracker.cpp | 8 +- .../Parallel}/DependencyTracker.h | 14 +- .../Parallel}/IndexedValuesMap.h | 14 +- .../Parallel}/OutputSections.cpp | 27 +- .../Parallel}/OutputSections.h | 34 +- .../StringEntryToDwarfStringPoolEntryMap.h | 16 +- .../Parallel}/SyntheticTypeNameBuilder.cpp | 8 +- .../Parallel}/SyntheticTypeNameBuilder.h | 14 +- .../Parallel}/TypePool.h | 35 +- .../Parallel}/Utils.h | 14 +- .../StringPool.cpp => DWARFLinker/Utils.cpp} | 4 +- .../llvm/lib/DWARFLinkerParallel/DWARFFile.cpp | 17 - .../llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | 9 +- .../llvm-project/llvm/lib/Demangle/Demangle.cpp | 5 +- .../llvm/lib/Demangle/ItaniumDemangle.cpp | 4 +- .../lib/ExecutionEngine/Interpreter/Execution.cpp | 2 +- .../llvm/lib/ExecutionEngine/JITLink/JITLink.cpp | 35 + .../lib/ExecutionEngine/JITLink/JITLinkGeneric.cpp | 14 + .../Orc/EPCDebugObjectRegistrar.cpp | 3 +- .../Orc/EPCDynamicLibrarySearchGenerator.cpp | 16 +- .../ExecutionEngine/Orc/EPCGenericDylibManager.cpp | 10 +- .../lib/ExecutionEngine/Orc/ExecutionUtils.cpp | 12 +- .../ExecutionEngine/Orc/ExecutorProcessControl.cpp | 6 +- .../ExecutionEngine/Orc/LookupAndRecordAddrs.cpp | 2 +- .../llvm/lib/ExecutionEngine/Orc/MachOPlatform.cpp | 2 + .../lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp | 14 +- .../Orc/TargetProcess/JITLoaderGDB.cpp | 23 - .../TargetProcess/SimpleExecutorDylibManager.cpp | 9 +- contrib/llvm-project/llvm/lib/IR/AsmWriter.cpp | 13 +- contrib/llvm-project/llvm/lib/IR/AutoUpgrade.cpp | 499 +++++----- contrib/llvm-project/llvm/lib/IR/DataLayout.cpp | 5 +- contrib/llvm-project/llvm/lib/IR/Operator.cpp | 12 +- contrib/llvm-project/llvm/lib/IR/Value.cpp | 2 +- contrib/llvm-project/llvm/lib/LTO/LTO.cpp | 36 +- contrib/llvm-project/llvm/lib/MC/MCAssembler.cpp | 6 +- contrib/llvm-project/llvm/lib/MC/MCExpr.cpp | 6 + contrib/llvm-project/llvm/lib/Object/ELF.cpp | 7 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 2 +- .../llvm-project/llvm/lib/Object/ObjectFile.cpp | 11 +- .../llvm/lib/Object/WasmObjectFile.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 9 +- .../llvm-project/llvm/lib/Passes/PassRegistry.def | 6 + .../llvm/lib/Passes/StandardInstrumentations.cpp | 52 +- .../llvm/lib/ProfileData/InstrProf.cpp | 27 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 9 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 41 +- .../llvm-project/llvm/lib/Target/AArch64/AArch64.h | 1 + .../llvm/lib/Target/AArch64/AArch64.td | 2 +- .../llvm/lib/Target/AArch64/AArch64FastISel.cpp | 19 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 6 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 15 +- .../llvm/lib/Target/AArch64/AArch64InstrFormats.td | 1 + .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 828 ++++++++++++++++ .../lib/Target/AArch64/AArch64LoopIdiomTransform.h | 25 + .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 5 +- .../lib/Target/AArch64/AArch64SelectionDAGInfo.cpp | 2 +- .../lib/Target/AArch64/AArch64TargetMachine.cpp | 11 + .../llvm/lib/Target/AArch64/AArch64TargetMachine.h | 4 + .../Target/AArch64/AArch64TargetTransformInfo.h | 2 + .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 59 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.h | 4 +- .../llvm/lib/Target/AArch64/SVEInstrFormats.td | 12 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUCallingConv.td | 26 +- .../llvm/lib/Target/AMDGPU/AMDGPUCombine.td | 9 +- .../Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp | 10 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 23 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 14 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 58 +- .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 8 +- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 29 +- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.h | 4 +- .../llvm/lib/Target/AMDGPU/AMDGPULibCalls.cpp | 32 +- .../lib/Target/AMDGPU/AMDGPUMachineFunction.cpp | 39 +- .../llvm/lib/Target/AMDGPU/AMDGPUMachineFunction.h | 7 + .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 34 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 168 +++- .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.h | 5 + .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.h | 3 +- .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 37 +- .../llvm/lib/Target/AMDGPU/BUFInstructions.td | 10 +- .../llvm/lib/Target/AMDGPU/DSDIRInstructions.td | 192 ++++ .../llvm/lib/Target/AMDGPU/DSInstructions.td | 1 - .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 6 + .../llvm/lib/Target/AMDGPU/EXPInstructions.td | 1 + .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 46 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 9 +- .../llvm/lib/Target/AMDGPU/LDSDIRInstructions.td | 116 --- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 139 ++- .../Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h | 10 +- .../AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.cpp | 19 +- .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 8 +- .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 148 ++- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 287 +++++- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 2 + .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 10 + .../llvm/lib/Target/AMDGPU/SIInstrFormats.td | 2 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 210 +++- .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 6 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 19 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 174 +++- .../llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp | 70 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 8 +- .../llvm/lib/Target/AMDGPU/SIWholeQuadMode.cpp | 4 +- .../llvm/lib/Target/AMDGPU/SMInstructions.td | 44 +- .../llvm/lib/Target/AMDGPU/SOPInstructions.td | 52 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 106 +- .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 11 +- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 2 +- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 18 +- .../llvm/lib/Target/ARC/ARCISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/ARC/ARCISelLowering.cpp | 2 + .../llvm/lib/Target/ARC/ARCTargetMachine.cpp | 7 + .../llvm/lib/Target/ARM/ARMFastISel.cpp | 2 +- .../llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp | 24 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 19 +- .../llvm/lib/Target/ARM/ARMLegalizerInfo.cpp | 10 +- .../llvm/lib/Target/ARM/ARMLegalizerInfo.h | 4 +- .../llvm/lib/Target/AVR/AVRISelLowering.cpp | 4 +- .../llvm/lib/Target/BPF/BPFISelLowering.cpp | 1 + .../llvm/lib/Target/BPF/BPFTargetMachine.cpp | 5 +- .../llvm/lib/Target/BPF/BPFTargetMachine.h | 3 +- .../llvm/lib/Target/DirectX/DXILResourceAnalysis.h | 1 + .../lib/Target/DirectX/DirectXTargetMachine.cpp | 3 +- .../llvm/lib/Target/DirectX/DirectXTargetMachine.h | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 2 +- .../lib/Target/Hexagon/HexagonISelLoweringHVX.cpp | 6 +- .../lib/Target/Hexagon/HexagonTargetMachine.cpp | 3 +- .../llvm/lib/Target/Hexagon/HexagonTargetMachine.h | 3 +- .../llvm/lib/Target/Lanai/LanaiISelLowering.cpp | 2 + .../llvm/lib/Target/Lanai/LanaiTargetMachine.cpp | 7 + .../LoongArch/AsmParser/LoongArchAsmParser.cpp | 61 ++ .../LoongArch/LoongArchExpandPseudoInsts.cpp | 521 +++++----- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 65 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 7 +- .../lib/Target/LoongArch/LoongArchInstrInfo.td | 106 +- .../lib/Target/LoongArch/LoongArchMCInstLower.cpp | 3 + .../lib/Target/LoongArch/LoongArchRegisterInfo.cpp | 23 + .../lib/Target/LoongArch/LoongArchRegisterInfo.h | 1 + .../Target/LoongArch/LoongArchTargetMachine.cpp | 4 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 69 +- .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 3 + .../LoongArch/MCTargetDesc/LoongArchBaseInfo.h | 1 + .../MCTargetDesc/LoongArchELFObjectWriter.cpp | 2 + .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 5 +- .../MCTargetDesc/LoongArchMCCodeEmitter.cpp | 3 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.cpp | 3 + .../LoongArch/MCTargetDesc/LoongArchMCExpr.h | 1 + .../llvm/lib/Target/M68k/GISel/M68kLegalizerInfo.h | 1 - .../llvm/lib/Target/M68k/M68kISelLowering.cpp | 4 +- .../llvm/lib/Target/MSP430/MSP430ISelDAGToDAG.cpp | 4 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 7 +- .../llvm/lib/Target/MSP430/MSP430TargetMachine.cpp | 7 + .../llvm/lib/Target/Mips/MipsFastISel.cpp | 2 +- .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 3 +- .../llvm/lib/Target/Mips/MipsLegalizerInfo.cpp | 5 +- .../llvm/lib/Target/Mips/MipsLegalizerInfo.h | 3 +- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 3 +- .../llvm/lib/Target/NVPTX/NVPTXTargetMachine.cpp | 3 +- .../llvm/lib/Target/NVPTX/NVPTXTargetMachine.h | 3 +- .../lib/Target/NVPTX/NVPTXTargetTransformInfo.cpp | 34 - .../llvm/lib/Target/PowerPC/PPCFastISel.cpp | 2 +- .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 13 +- .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 16 +- .../llvm/lib/Target/PowerPC/PPCRegisterInfo.td | 9 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 9 +- .../lib/Target/RISCV/GISel/RISCVCallLowering.cpp | 2 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 7 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.h | 4 +- .../lib/Target/RISCV/MCA/RISCVCustomBehaviour.cpp | 33 +- .../Target/RISCV/MCTargetDesc/RISCVAsmBackend.cpp | 9 +- .../Target/RISCV/MCTargetDesc/RISCVAsmBackend.h | 4 +- .../lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h | 1 - .../lib/Target/RISCV/MCTargetDesc/RISCVMCExpr.cpp | 2 - .../llvm/lib/Target/RISCV/RISCVAsmPrinter.cpp | 3 - .../lib/Target/RISCV/RISCVExpandPseudoInsts.cpp | 10 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 6 + .../Target/RISCV/RISCVGatherScatterLowering.cpp | 2 +- .../llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp | 10 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 375 +++---- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 13 +- .../llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp | 5 + .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 7 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.td | 54 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoA.td | 12 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoD.td | 2 + .../lib/Target/RISCV/RISCVInstrInfoVPseudos.td | 2 + .../lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td | 16 + .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 122 +-- .../llvm/lib/Target/RISCV/RISCVInstrInfoZa.td | 44 + .../llvm/lib/Target/RISCV/RISCVOptWInstrs.cpp | 6 +- .../llvm/lib/Target/RISCV/RISCVProcessors.td | 3 +- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 2 +- .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 7 + .../lib/Target/RISCV/RISCVTargetTransformInfo.cpp | 114 ++- .../lib/Target/RISCV/RISCVTargetTransformInfo.h | 3 + .../llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp | 7 +- .../llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp | 125 ++- .../llvm/lib/Target/SPIRV/SPIRVLegalizerInfo.cpp | 5 +- .../llvm/lib/Target/SPIRV/SPIRVLegalizerInfo.h | 3 +- .../llvm/lib/Target/SPIRV/SPIRVPreLegalizer.cpp | 59 +- .../llvm/lib/Target/SPIRV/SPIRVTargetMachine.cpp | 14 + .../llvm/lib/Target/SPIRV/SPIRVUtils.cpp | 4 +- .../llvm/lib/Target/SPIRV/SPIRVUtils.h | 2 +- .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 8 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 27 +- .../lib/Target/WebAssembly/WebAssemblyFastISel.cpp | 2 +- .../Target/WebAssembly/WebAssemblyISelLowering.cpp | 7 +- .../llvm/lib/Target/X86/GISel/X86LegalizerInfo.h | 1 - .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 16 - .../Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp | 3 + contrib/llvm-project/llvm/lib/Target/X86/X86.h | 8 +- .../X86/{X86EvexToVex.cpp => X86CompressEVEX.cpp} | 168 ++-- .../llvm/lib/Target/X86/X86DomainReassignment.cpp | 67 +- .../llvm/lib/Target/X86/X86FastISel.cpp | 12 +- .../llvm/lib/Target/X86/X86FlagsCopyLowering.cpp | 1 - .../llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 2 +- .../llvm/lib/Target/X86/X86ISelLowering.cpp | 122 ++- .../llvm/lib/Target/X86/X86ISelLowering.h | 10 - .../llvm/lib/Target/X86/X86ISelLoweringCall.cpp | 37 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 248 ++--- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 1030 ++++++++++++-------- .../llvm/lib/Target/X86/X86InstrFormats.td | 6 - .../llvm/lib/Target/X86/X86InstrInfo.h | 4 +- .../llvm/lib/Target/X86/X86InstrMisc.td | 120 +-- .../llvm/lib/Target/X86/X86InstrPredicates.td | 33 + .../llvm/lib/Target/X86/X86InstrShiftRotate.td | 2 +- .../llvm/lib/Target/X86/X86InstrSystem.td | 13 +- .../llvm/lib/Target/X86/X86InstrUtils.td | 10 +- .../llvm/lib/Target/X86/X86MCInstLower.cpp | 7 +- .../llvm/lib/Target/X86/X86TargetMachine.cpp | 4 +- .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 1 + .../llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp | 2 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 3 +- .../llvm-project/llvm/lib/TargetParser/Triple.cpp | 7 +- .../llvm/lib/Transforms/Coroutines/CoroFrame.cpp | 12 +- .../lib/Transforms/IPO/AttributorAttributes.cpp | 6 +- .../Transforms/InstCombine/InstCombineAddSub.cpp | 7 - .../Transforms/InstCombine/InstCombineCalls.cpp | 62 +- .../Transforms/InstCombine/InstCombineCompares.cpp | 68 +- .../Transforms/InstCombine/InstCombineInternal.h | 23 +- .../InstCombine/InstCombineMulDivRem.cpp | 7 - .../InstCombine/InstructionCombining.cpp | 135 ++- .../Instrumentation/AddressSanitizer.cpp | 50 +- .../Transforms/Instrumentation/BoundsChecking.cpp | 8 +- .../Transforms/Instrumentation/InstrProfiling.cpp | 10 +- .../Instrumentation/PGOInstrumentation.cpp | 51 +- .../Transforms/Scalar/ConstraintElimination.cpp | 91 +- .../Scalar/CorrelatedValuePropagation.cpp | 51 +- .../llvm/lib/Transforms/Scalar/SROA.cpp | 6 +- .../Scalar/SeparateConstOffsetFromGEP.cpp | 6 +- .../Scalar/StraightLineStrengthReduce.cpp | 2 +- .../lib/Transforms/Utils/InjectTLIMappings.cpp | 46 +- .../llvm/lib/Transforms/Utils/SCCPSolver.cpp | 10 +- .../llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 35 +- .../llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp | 20 +- .../Transforms/Vectorize/LoadStoreVectorizer.cpp | 2 +- .../Vectorize/LoopVectorizationPlanner.h | 27 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 481 ++++----- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 24 +- .../lib/Transforms/Vectorize/VPRecipeBuilder.h | 7 +- .../llvm/lib/Transforms/Vectorize/VPlan.cpp | 1 + .../llvm/lib/Transforms/Vectorize/VPlan.h | 34 +- .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 88 +- .../lib/Transforms/Vectorize/VPlanTransforms.cpp | 23 +- .../llvm-project/llvm/tools/lli/ExecutionUtils.cpp | 32 +- .../llvm/tools/lli/ForwardingMemoryManager.h | 9 +- contrib/llvm-project/llvm/tools/lli/lli.cpp | 9 +- .../llvm-project/llvm/tools/llvm-cxxfilt/Opts.td | 2 + .../llvm/tools/llvm-cxxfilt/llvm-cxxfilt.cpp | 10 +- .../llvm/tools/llvm-dwarfutil/DebugInfoLinker.cpp | 32 +- .../llvm/tools/llvm-profdata/llvm-profdata.cpp | 23 +- .../llvm/tools/llvm-readobj/ELFDumper.cpp | 1 + contrib/llvm-project/llvm/tools/opt/opt.cpp | 2 +- .../utils/TableGen/GlobalISelCombinerEmitter.cpp | 16 +- .../TableGen/MacroFusionPredicatorEmitter.cpp | 236 +++++ .../llvm/utils/TableGen/PredicateExpander.cpp | 8 + .../llvm/utils/TableGen/PredicateExpander.h | 1 + .../TableGen/X86CompressEVEXTablesEmitter.cpp | 206 ++++ .../utils/TableGen/X86EVEX2VEXTablesEmitter.cpp | 210 ---- .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 6 +- .../utils/TableGen/X86ManualCompressEVEXTables.def | 331 +++++++ contrib/llvm-project/openmp/runtime/src/kmp.h | 7 + .../openmp/runtime/src/kmp_config.h.cmake | 2 +- .../openmp/runtime/src/kmp_ftn_entry.h | 2 +- .../llvm-project/openmp/runtime/src/kmp_global.cpp | 2 +- .../openmp/runtime/src/kmp_gsupport.cpp | 3 +- contrib/llvm-project/openmp/runtime/src/kmp_os.h | 9 +- .../llvm-project/openmp/runtime/src/kmp_platform.h | 32 +- .../openmp/runtime/src/kmp_runtime.cpp | 8 +- .../openmp/runtime/src/kmp_settings.cpp | 4 +- .../openmp/runtime/src/kmp_wrapper_getpid.h | 5 + .../openmp/runtime/src/z_Linux_util.cpp | 21 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 7 +- usr.bin/clang/llvm-tblgen/Makefile | 3 +- 691 files changed, 13954 insertions(+), 6431 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/Attr.h b/contrib/llvm-project/clang/include/clang/AST/Attr.h index 1b831c9511e2..8e9b7ad8b468 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Attr.h +++ b/contrib/llvm-project/clang/include/clang/AST/Attr.h @@ -25,6 +25,7 @@ #include "clang/Basic/Sanitizers.h" #include "clang/Basic/SourceLocation.h" #include "llvm/Frontend/HLSL/HLSLResource.h" +#include "llvm/Support/CodeGen.h" #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/VersionTuple.h" #include "llvm/Support/raw_ostream.h" diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h index 432293583576..984a4d8bab5e 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h @@ -2044,6 +2044,14 @@ public: // Implement isa/cast/dyncast/etc. static bool classof(const Decl *D) { return classofKind(D->getKind()); } static bool classofKind(Kind K) { return K == RequiresExprBody; } + + static DeclContext *castToDeclContext(const RequiresExprBodyDecl *D) { + return static_cast(const_cast(D)); + } + + static RequiresExprBodyDecl *castFromDeclContext(const DeclContext *DC) { + return static_cast(const_cast(DC)); + } }; /// Represents a static or instance method of a struct/union/class. diff --git a/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h b/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h index 2f4ed082a0c7..732749ad305e 100644 --- a/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h +++ b/contrib/llvm-project/clang/include/clang/AST/TextNodeDumper.h @@ -252,6 +252,8 @@ public: void VisitGotoStmt(const GotoStmt *Node); void VisitCaseStmt(const CaseStmt *Node); void VisitReturnStmt(const ReturnStmt *Node); + void VisitCoawaitExpr(const CoawaitExpr *Node); + void VisitCoreturnStmt(const CoreturnStmt *Node); void VisitCompoundStmt(const CompoundStmt *Node); void VisitConstantExpr(const ConstantExpr *Node); void VisitCallExpr(const CallExpr *Node); diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index 1afa69367286..9e9f896ebef7 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -4224,6 +4224,8 @@ public: ExceptionSpecInfo() = default; ExceptionSpecInfo(ExceptionSpecificationType EST) : Type(EST) {} + + void instantiate(); }; /// Extra information about a function prototype. ExtProtoInfo is not diff --git a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h index 8a2d56668e32..b28f2c6b99c5 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h +++ b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h @@ -66,7 +66,7 @@ public: /// Invoked when an unsafe operation over raw pointers is found. virtual void handleUnsafeOperation(const Stmt *Operation, - bool IsRelatedToDecl) = 0; + bool IsRelatedToDecl, ASTContext &Ctx) = 0; /// Invoked when a fix is suggested against a variable. This function groups /// all variables that must be fixed together (i.e their types must be changed diff --git a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def index 757ee452ced7..c97661688365 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def +++ b/contrib/llvm-project/clang/include/clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def @@ -30,6 +30,7 @@ WARNING_GADGET(Decrement) WARNING_GADGET(ArraySubscript) WARNING_GADGET(PointerArithmetic) WARNING_GADGET(UnsafeBufferUsageAttr) +WARNING_GADGET(DataInvocation) FIXABLE_GADGET(ULCArraySubscript) // `DRE[any]` in an Unspecified Lvalue Context FIXABLE_GADGET(DerefSimplePtrArithFixable) FIXABLE_GADGET(PointerDereference) diff --git a/contrib/llvm-project/clang/include/clang/Analysis/CFG.h b/contrib/llvm-project/clang/include/clang/Analysis/CFG.h index 67383bb316d3..9f776ca6cc26 100644 --- a/contrib/llvm-project/clang/include/clang/Analysis/CFG.h +++ b/contrib/llvm-project/clang/include/clang/Analysis/CFG.h @@ -1215,7 +1215,9 @@ public: //===--------------------------------------------------------------------===// class BuildOptions { - std::bitset alwaysAddMask; + // Stmt::lastStmtConstant has the same value as the last Stmt kind, + // so make sure we add one to account for this! + std::bitset alwaysAddMask; public: using ForcedBlkExprs = llvm::DenseMap; diff --git a/contrib/llvm-project/clang/include/clang/Basic/Attr.td b/contrib/llvm-project/clang/include/clang/Basic/Attr.td index db17211747b1..d5eabaad4889 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/Attr.td +++ b/contrib/llvm-project/clang/include/clang/Basic/Attr.td @@ -143,6 +143,11 @@ def ExternalGlobalVar : SubsetSubjectisLocalExternDecl()}], "external global variables">; +def NonTLSGlobalVar : SubsetSubjecthasGlobalStorage() && + S->getTLSKind() == 0}], + "non-TLS global variables">; + def InlineFunction : SubsetSubjectisInlineSpecified()}], "inline functions">; @@ -431,6 +436,7 @@ def TargetAArch64 : TargetArch<["aarch64", "aarch64_be", "aarch64_32"]>; def TargetAnyArm : TargetArch; def TargetAVR : TargetArch<["avr"]>; def TargetBPF : TargetArch<["bpfel", "bpfeb"]>; +def TargetLoongArch : TargetArch<["loongarch32", "loongarch64"]>; def TargetMips32 : TargetArch<["mips", "mipsel"]>; def TargetAnyMips : TargetArch<["mips", "mipsel", "mips64", "mips64el"]>; def TargetMSP430 : TargetArch<["msp430"]>; @@ -1121,6 +1127,14 @@ def CoroLifetimeBound : InheritableAttr { let SimpleHandler = 1; } +def CoroDisableLifetimeBound : InheritableAttr { + let Spellings = [Clang<"coro_disable_lifetimebound">]; + let Subjects = SubjectList<[Function]>; + let LangOpts = [CPlusPlus]; + let Documentation = [CoroLifetimeBoundDoc]; + let SimpleHandler = 1; +} + // OSObject-based attributes. def OSConsumed : InheritableParamAttr { let Spellings = [Clang<"os_consumed">]; @@ -2730,6 +2744,15 @@ def PragmaClangTextSection : InheritableAttr { let Documentation = [InternalOnly]; } +def CodeModel : InheritableAttr, TargetSpecificAttr { + let Spellings = [GCC<"model">]; + let Args = [EnumArgument<"Model", "llvm::CodeModel::Model", + ["normal", "medium", "extreme"], ["Small", "Medium", "Large"], + /*opt=*/0, /*fake=*/0, /*isExternalType=*/1>]; + let Subjects = SubjectList<[NonTLSGlobalVar], ErrorDiag>; + let Documentation = [CodeModelDocs]; +} + def Sentinel : InheritableAttr { let Spellings = [GCC<"sentinel">]; let Args = [DefaultIntArgument<"Sentinel", 0>, diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 98a7ecc7fd7d..5416a0cbdd07 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -57,6 +57,15 @@ global variable or function should be in after translation. let Heading = "section, __declspec(allocate)"; } +def CodeModelDocs : Documentation { + let Category = DocCatVariable; + let Content = [{ +The ``model`` attribute allows overriding the translation unit's +code model (specified by ``-mcmodel``) for a specific global variable. + }]; + let Heading = "model"; +} + def UsedDocs : Documentation { let Category = DocCatFunction; let Content = [{ @@ -7671,9 +7680,12 @@ The ``[[clang::coro_lifetimebound]]`` is a class attribute which can be applied to a coroutine return type (`CRT`_) (i.e. it should also be annotated with ``[[clang::coro_return_type]]``). -All parameters of a function are considered to be lifetime bound. See `documentation`_ -of ``[[clang::lifetimebound]]`` for more details. -if the function returns a coroutine return type (CRT) annotated with ``[[clang::coro_lifetimebound]]``. +All parameters of a function are considered to be lifetime bound if the function returns a +coroutine return type (CRT) annotated with ``[[clang::coro_lifetimebound]]``. +This lifetime bound analysis can be disabled for a coroutine wrapper or a coroutine by annotating the function +with ``[[clang::coro_disable_lifetimebound]]`` function attribute . +See `documentation`_ of ``[[clang::lifetimebound]]`` for details about lifetime bound analysis. + Reference parameters of a coroutine are susceptible to capturing references to temporaries or local variables. @@ -7703,7 +7715,7 @@ Both coroutines and coroutine wrappers are part of this analysis. }; Task coro(const int& a) { co_return a + 1; } - Task [[clang::coro_wrapper]] coro_wrapper(const int& a, const int& b) { + [[clang::coro_wrapper]] Task coro_wrapper(const int& a, const int& b) { return a > b ? coro(a) : coro(b); } Task temporary_reference() { @@ -7718,6 +7730,21 @@ Both coroutines and coroutine wrappers are part of this analysis. return coro(a); // warning: returning address of stack variable `a`. } +This analysis can be disabled for all calls to a particular function by annotating the function +with function attribute ``[[clang::coro_disable_lifetimebound]]``. +For example, this could be useful for coroutine wrappers which accept reference parameters +but do not pass them to the underlying coroutine or pass them by value. + +.. code-block:: c++ + + Task coro(int a) { co_return a + 1; } + [[clang::coro_wrapper, clang::coro_disable_lifetimebound]] Task coro_wrapper(const int& a) { + return coro(a + 1); + } + void use() { + auto task = coro_wrapper(1); // use of temporary is fine as the argument is not lifetime bound. + } + .. _`documentation`: https://clang.llvm.org/docs/AttributeReference.html#lifetimebound .. _`CRT`: https://clang.llvm.org/docs/AttributeReference.html#coro-return-type }]; diff --git a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def index 0acb5ae134ea..2c4fb6745bc1 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def @@ -209,6 +209,7 @@ CODEGENOPT(CoverageMapping , 1, 0) ///< Generate coverage mapping regions to ///< enable code coverage analysis. CODEGENOPT(DumpCoverageMapping , 1, 0) ///< Dump the generated coverage mapping ///< regions. +CODEGENOPT(MCDCCoverage , 1, 0) ///< Enable MC/DC code coverage criteria. /// If -fpcc-struct-return or -freg-struct-return is specified. ENUM_CODEGENOPT(StructReturnConvention, StructReturnConventionKind, 2, SRCK_Default) diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td index 65a33f61a694..72952b08c04a 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td @@ -349,6 +349,9 @@ def warn_invalid_feature_combination : Warning< def warn_target_unrecognized_env : Warning< "mismatch between architecture and environment in target triple '%0'; did you mean '%1'?">, InGroup; +def warn_knl_knm_isa_support_removed : Warning< + "KNL, KNM related Intel Xeon Phi CPU's specific ISA's supports will be removed in LLVM 19.">, + InGroup>; // Source manager def err_cannot_open_file : Error<"cannot open file '%0': %1">, DefaultFatal; diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td index 676f1a62b49d..0a8a77fadbeb 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDriverKinds.td @@ -786,4 +786,7 @@ def warn_android_unversioned_fallback : Warning< " directories will not be used in Clang 19. Provide a versioned directory" " for the target version or lower instead.">, InGroup>; + +def err_drv_triple_version_invalid : Error< + "version '%0' in target triple '%1' is invalid">; } diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td index e4b1069cde18..088f8b74983c 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticParseKinds.td @@ -1364,6 +1364,8 @@ def err_acc_invalid_clause : Error<"invalid OpenACC clause %0">; def err_acc_missing_directive : Error<"expected OpenACC directive">; def err_acc_invalid_open_paren : Error<"expected clause-list or newline in OpenACC directive">; +def err_acc_invalid_default_clause_kind + : Error<"invalid value for 'default' clause; expected 'present' or 'none'">; // OpenMP support. def warn_pragma_omp_ignored : Warning< diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index cb68ded1f38c..e81d1a4fc288 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td *** 39310 LINES SKIPPED *** From nobody Sat Apr 20 10:34:25 2024 X-Original-To: dev-commits-src-branches@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 4VM7DL31qMz5HWYq; Sat, 20 Apr 2024 10:34:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DL1nMfz4SW5; Sat, 20 Apr 2024 10:34:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609266; 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=YTFV1v7+i5xLxwghKf40EYimmZ5Qxvi+ySsdPMT7GBc=; b=JAiuXKdFmpUL3fzyaIoBK8o9PXbg35iOXURNOXtZU3DYq9+bJxwrLzw/r0kC5zB33qNyFm qinTR1880WFdRq2ub950oSwJcCl3s82OK37Apl486+H9NtE62U9j6ly0JWeeMgTlfYq0UF VMEHJ0Okq+UvG8kyiW7g77KzhcnmaxpcUw/8kY/aGDA09LAu7RanlJlHEBFkEFfXFquiZC HDwu9Z8h4Lobhyim58QXflMu2cn+b4ikeVqGOtHfutaQ82sIQtlycl4uwSm+fH/FtND/zE vrw+IrIa3OeLgK8R1j4ItfLOQKewvIELyF6swUh2YIyPrNPYw2yHfqZnReYw9w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609266; a=rsa-sha256; cv=none; b=TurWakO+EswXG1NuQa73menDJzJmq3LElEXaSBKPe5cZtBW1Fa+8fmGw0+/BGOFfWHY6yY oewbzkHja8VKyOVDKfKhKn9jT5xDe+pXqedLWkDj0VYsUXlaO6NWzz1QKQzlYJrdFWAwRh FFR97dJd9vfsdBPG8tnt4JlXv4CQhL391+04tKvU3CPPU77Jfd7OuaKZqY2ACMNe7gn069 5hZ0S9BR8oX+bD2bY+C8RYbEFXg/gv97Q0fCOELW7g0Ww/z9zwIQ6Qoq5W0e9892QEOU32 T3zblfVtGfMqm43+YCW+W/T7h3Yv/iPjPd819T4crn/OTLPtJIZNn+KQOJTy1Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609266; 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=YTFV1v7+i5xLxwghKf40EYimmZ5Qxvi+ySsdPMT7GBc=; b=A4BJ//Wr0HjUkVlt0XuWaNP+p6Rox3nd306xA4yIZQD/kAXNaUANEW4w2IiuKS8eojkqsD foaiBHjs6ZLnExiWx+OaccYsAISvF5NZEIjY7w4oWD3EqF1wXO8rn3fVJMfsjXDiDQG3YZ BzjigPUIpQw/6OGAzuHOzt4MOFXef4jb9tmRZcj+GidPoVg/+SmmmhfY0uoZ/0WRi3pe+A YUtpMVn/9F2kaYkydV7yJi5Q0IXDBxjhws5jjg9vt94+LqMQhc909B83K4/M1BAPXVoUoo 9w3hDDK6VkzPn9cK9a8txN4DZcRuR/4aNEa1q54MzA5CXdRgwO94OD/KtnYfMg== 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 4VM7DL14BQzYkf; Sat, 20 Apr 2024 10:34:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYQ8o013542; Sat, 20 Apr 2024 10:34:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYPh3013537; Sat, 20 Apr 2024 10:34:25 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:25 GMT Message-Id: <202404201034.43KAYPh3013537@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: 52e4ee64c25f - stable/13 - Merge llvm-project main llvmorg-18-init-16864-g3b3ee1f53424 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 52e4ee64c25fe0837e9cf783a63e8c214b3180cf Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=52e4ee64c25fe0837e9cf783a63e8c214b3180cf commit 52e4ee64c25fe0837e9cf783a63e8c214b3180cf Author: Dimitry Andric AuthorDate: 2024-01-11 18:29:01 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:43 +0000 Merge llvm-project main llvmorg-18-init-16864-g3b3ee1f53424 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-16864-g3b3ee1f53424. PR: 276104 MFC after: 1 month (cherry picked from commit 297eecfb02bb25902531dbb5c3b9a88caf8adf29) --- .../clang/include/clang/AST/DeclBase.h | 10 + .../llvm-project/clang/include/clang/AST/DeclCXX.h | 3 + .../llvm-project/clang/include/clang/AST/Stmt.h | 6 +- .../llvm-project/clang/include/clang/AST/Type.h | 3 + .../llvm-project/clang/include/clang/Basic/Attr.td | 18 + .../clang/include/clang/Basic/AttrDocs.td | 78 +++ .../include/clang/Basic/DiagnosticFrontendKinds.td | 2 +- .../include/clang/Basic/DiagnosticSemaKinds.td | 15 + .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Basic/TargetInfo.h | 1 + .../clang/include/clang/Basic/arm_sve.td | 22 +- .../clang/include/clang/Driver/Options.td | 18 +- .../clang/include/clang/Format/Format.h | 20 +- .../clang/include/clang/Parse/Parser.h | 24 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 3 + .../clang/include/clang/Sema/TypoCorrection.h | 12 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 7 + contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 37 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 74 ++- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 13 + contrib/llvm-project/clang/lib/AST/Expr.cpp | 83 +--- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 7 + .../clang/lib/AST/Interp/Descriptor.cpp | 6 +- .../llvm-project/clang/lib/AST/Interp/Descriptor.h | 7 +- .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 12 + .../clang/lib/AST/Interp/InterpBuiltin.cpp | 33 +- .../llvm-project/clang/lib/AST/Interp/Program.cpp | 16 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 34 +- .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 355 +++++++------- .../clang/lib/Basic/Targets/AArch64.cpp | 7 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 5 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 244 +++++++++- contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 2 + .../llvm-project/clang/lib/CodeGen/CGException.cpp | 7 +- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 340 +++++++++++++- .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 35 +- .../clang/lib/CodeGen/CodeGenFunction.h | 22 + .../clang/lib/CodeGen/CodeGenModule.cpp | 2 + .../clang/lib/CodeGen/CoverageMappingGen.cpp | 13 +- .../clang/lib/CodeGen/Targets/AArch64.cpp | 2 + .../clang/lib/Driver/ToolChains/Clang.cpp | 6 +- .../clang/lib/Driver/ToolChains/Flang.cpp | 57 ++- .../clang/lib/Driver/ToolChains/Flang.h | 7 + .../clang/lib/Driver/ToolChains/Gnu.cpp | 8 +- .../clang/lib/Driver/ToolChains/Linux.cpp | 8 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 30 +- .../llvm-project/clang/lib/Format/FormatToken.cpp | 4 +- .../llvm-project/clang/lib/Format/FormatToken.h | 25 +- .../clang/lib/Format/TokenAnnotator.cpp | 14 +- .../clang/lib/Format/UnwrappedLineFormatter.cpp | 10 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 4 +- .../clang/lib/Format/WhitespaceManager.cpp | 9 +- .../clang/lib/Format/WhitespaceManager.h | 1 + .../lib/Frontend/VerifyDiagnosticConsumer.cpp | 15 +- .../llvm-project/clang/lib/Headers/ia32intrin.h | 376 +++++++-------- .../clang/lib/Interpreter/Interpreter.cpp | 1 + contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 8 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 26 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 65 +-- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 6 + .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 133 ++++++ contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 16 +- .../llvm-project/clang/lib/Sema/SemaExprMember.cpp | 3 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 10 + contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 2 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 20 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 21 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 59 ++- .../clang/tools/clang-format/ClangFormat.cpp | 65 ++- .../compiler-rt/include/profile/InstrProfData.inc | 2 + .../lib/profile/InstrProfilingPlatformLinux.c | 9 - .../lib/sanitizer_common/sanitizer_flags.inc | 3 + .../sanitizer_symbolizer_report.cpp | 36 +- .../sanitizer_thread_arg_retval.cpp | 23 +- .../sanitizer_common/sanitizer_thread_arg_retval.h | 1 + .../lib/scudo/standalone/condition_variable.h | 2 +- contrib/llvm-project/libcxx/include/__config | 5 - .../libcxx/include/__memory/shared_ptr.h | 4 +- contrib/llvm-project/libcxx/include/cstdio | 2 +- contrib/llvm-project/libcxx/include/regex | 3 + contrib/llvm-project/libcxx/include/tuple | 2 +- contrib/llvm-project/lld/ELF/Arch/AArch64.cpp | 3 + contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 110 ++--- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 7 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 10 +- contrib/llvm-project/lld/ELF/Target.h | 2 +- .../llvm-project/lldb/include/lldb/Core/Module.h | 6 + .../llvm-project/lldb/include/lldb/Symbol/Type.h | 4 + .../lldb/include/lldb/Utility/StreamString.h | 2 +- contrib/llvm-project/lldb/source/Core/Module.cpp | 17 + .../ExpressionParser/Clang/ClangASTImporter.cpp | 51 +- .../Language/CPlusPlus/CPlusPlusLanguage.cpp | 35 ++ .../source/Plugins/Language/CPlusPlus/LibCxx.cpp | 57 +++ .../source/Plugins/Language/CPlusPlus/LibCxx.h | 8 + .../source/Plugins/SymbolFile/DWARF/DWARFDIE.cpp | 44 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 11 +- .../intel-pt/CommandObjectTraceStartIntelPT.cpp | 4 +- .../Plugins/Trace/intel-pt/DecodedThread.cpp | 32 +- .../source/Plugins/Trace/intel-pt/DecodedThread.h | 26 +- .../Plugins/Trace/intel-pt/LibiptDecoder.cpp | 4 +- .../Plugins/Trace/intel-pt/TraceCursorIntelPT.cpp | 4 +- .../Trace/intel-pt/TraceIntelPTBundleLoader.cpp | 13 +- contrib/llvm-project/lldb/source/Symbol/Type.cpp | 4 + .../lldb/source/Target/ProcessTrace.cpp | 2 + .../lldb/source/Utility/StreamString.cpp | 2 +- .../llvm-project/llvm/include/llvm/ADT/STLExtras.h | 29 +- .../llvm-project/llvm/include/llvm/ADT/StringRef.h | 4 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 190 ++++---- .../llvm/BinaryFormat/ELFRelocs/AArch64.def | 1 + .../include/llvm/BinaryFormat/ELFRelocs/RISCV.def | 3 +- .../llvm/CodeGen/AssignmentTrackingAnalysis.h | 29 +- .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 1 + .../llvm/CodeGen/GlobalISel/CombinerHelper.h | 3 + .../llvm/CodeGen/GlobalISel/GenericMachineInstrs.h | 18 + .../include/llvm/CodeGen/GlobalISel/Localizer.h | 7 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 16 + .../llvm/include/llvm/CodeGen/SelectionDAGNodes.h | 7 + .../Parallel => include/llvm/DWARFLinker}/Utils.h | 36 +- .../llvm/include/llvm/Frontend/OpenACC/ACC.td | 66 +-- .../llvm/include/llvm/IR/IntrinsicsAArch64.td | 6 +- .../llvm/include/llvm/IR/IntrinsicsNVVM.td | 10 + .../llvm/include/llvm/IR/ModuleSummaryIndex.h | 6 + .../llvm/include/llvm/IR/PatternMatch.h | 36 ++ .../llvm/include/llvm/ProfileData/InstrProf.h | 3 +- .../include/llvm/ProfileData/InstrProfData.inc | 2 + .../llvm/include/llvm/Support/RISCVISAInfo.h | 22 +- .../llvm/include/llvm/Support/TargetOpcodes.def | 3 + .../llvm/include/llvm/Target/GenericOpcodes.td | 21 + .../llvm/Target/GlobalISel/SelectionDAGCompat.td | 3 + .../llvm/include/llvm/Target/TargetPfmCounters.td | 21 + .../llvm/TargetParser/ARMTargetParserCommon.h | 1 + .../llvm/lib/Analysis/LazyValueInfo.cpp | 8 +- .../llvm/lib/Bitcode/Writer/BitcodeWriter.cpp | 17 +- .../lib/CodeGen/AssignmentTrackingAnalysis.cpp | 34 ++ .../llvm/lib/CodeGen/BranchFolding.cpp | 17 + .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 84 ++++ .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 12 + .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 10 + .../llvm/lib/CodeGen/GlobalISel/Localizer.cpp | 55 ++- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 9 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 74 +-- .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 2 +- .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 12 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 48 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 5 +- .../lib/CodeGen/TargetLoweringObjectFileImpl.cpp | 11 +- .../llvm/lib/DWARFLinker/Classic/DWARFLinker.cpp | 15 +- .../Parallel/AcceleratorRecordsSaver.cpp | 2 +- .../Parallel/DWARFLinkerCompileUnit.cpp | 23 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.cpp | 2 +- .../DWARFLinker/Parallel/DebugLineSectionEmitter.h | 38 +- .../llvm-project/llvm/lib/DWARFLinker/Utils.cpp | 2 + contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 11 + .../llvm/lib/MC/MCParser/ELFAsmParser.cpp | 6 +- contrib/llvm-project/llvm/lib/MC/MCSectionELF.cpp | 18 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 1 + .../llvm-project/llvm/lib/Passes/PassRegistry.def | 4 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 331 +++++++------ contrib/llvm-project/llvm/lib/TableGen/Record.cpp | 15 +- .../llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp | 5 + .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 4 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 3 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 3 + .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 64 ++- .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 2 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 18 +- .../Target/AArch64/AArch64TargetTransformInfo.cpp | 98 ++-- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 3 +- .../MCTargetDesc/AArch64ELFObjectWriter.cpp | 8 +- .../llvm/lib/Target/AArch64/SMEInstrFormats.td | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUCombine.td | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 12 +- .../lib/Target/AMDGPU/AMDGPULowerModuleLDSPass.cpp | 52 ++ .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 46 +- .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 43 +- .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 17 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 2 + .../Target/AMDGPU/MCTargetDesc/AMDGPUMCAsmInfo.cpp | 1 - .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 8 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 5 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 33 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 33 +- .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 55 ++- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 14 +- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 13 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 9 +- .../llvm/lib/Target/MSP430/MSP430ISelLowering.cpp | 13 +- .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 6 +- .../llvm/lib/Target/NVPTX/NVPTXInstrInfo.td | 3 + .../llvm/lib/Target/NVPTX/NVPTXIntrinsics.td | 13 + .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 2 +- .../llvm/lib/Target/PowerPC/PPCInstrInfo.td | 2 +- .../lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp | 77 ++- .../RISCV/Disassembler/RISCVDisassembler.cpp | 6 +- .../lib/Target/RISCV/GISel/RISCVLegalizerInfo.cpp | 40 ++ .../RISCV/MCTargetDesc/RISCVELFObjectWriter.cpp | 2 + .../Target/RISCV/MCTargetDesc/RISCVELFStreamer.cpp | 7 + .../lib/Target/RISCV/RISCVExpandPseudoInsts.cpp | 12 +- .../llvm/lib/Target/RISCV/RISCVFeatures.td | 1 + .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 46 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.h | 6 +- .../llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp | 37 +- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 17 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoA.td | 140 +++--- .../llvm/lib/Target/RISCV/RISCVInstrInfoD.td | 16 +- .../lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td | 33 +- .../lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td | 38 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZa.td | 98 +++- .../llvm/lib/Target/RISCV/RISCVRegisterInfo.td | 45 +- .../lib/Target/SystemZ/SystemZISelDAGToDAG.cpp | 2 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 7 + .../lib/Target/WebAssembly/WebAssemblyFastISel.cpp | 4 +- .../llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h | 16 + .../llvm/lib/Target/X86/X86FlagsCopyLowering.cpp | 1 + .../llvm/lib/Target/X86/X86ISelLowering.cpp | 53 ++- .../llvm/lib/Target/X86/X86InstrArithmetic.td | 110 +++-- .../llvm/lib/Target/X86/X86InstrCompiler.td | 380 ++++++++------- .../llvm/lib/Target/X86/X86InstrMisc.td | 12 +- .../llvm/lib/Target/X86/X86PfmCounters.td | 18 + .../lib/TargetParser/ARMTargetParserCommon.cpp | 7 +- .../llvm/lib/TextAPI/InterfaceFile.cpp | 8 + .../IPO/MemProfContextDisambiguation.cpp | 521 ++++++++++++++++++--- .../Transforms/InstCombine/InstCombineAddSub.cpp | 24 + .../Transforms/InstCombine/InstCombineAndOrXor.cpp | 114 +++-- .../Transforms/InstCombine/InstCombineCalls.cpp | 4 + .../Transforms/InstCombine/InstCombineSelect.cpp | 4 +- .../Instrumentation/AddressSanitizer.cpp | 2 +- .../Instrumentation/PGOInstrumentation.cpp | 12 +- .../llvm/lib/Transforms/Scalar/LoopFlatten.cpp | 79 ++-- .../Transforms/Scalar/RewriteStatepointsForGC.cpp | 23 +- .../Scalar/SeparateConstOffsetFromGEP.cpp | 58 +-- .../Scalar/StraightLineStrengthReduce.cpp | 55 +-- .../llvm/lib/Transforms/Utils/Local.cpp | 3 +- .../llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 13 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 6 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 69 ++- .../llvm/utils/TableGen/CodeGenDAGPatterns.cpp | 2 +- .../llvm/utils/TableGen/DAGISelMatcherEmitter.cpp | 81 +++- .../llvm/utils/TableGen/ExegesisEmitter.cpp | 52 +- .../utils/TableGen/GlobalISelCombinerEmitter.cpp | 2 +- .../openmp/runtime/src/z_Linux_util.cpp | 2 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 32 +- lib/libc++/Makefile | 40 +- lib/libc++/module.modulemap | 4 +- 247 files changed, 5252 insertions(+), 2361 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h index 10dcbdb262d8..5b1038582bc6 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h @@ -19,6 +19,7 @@ #include "clang/AST/SelectorLocationsKind.h" #include "clang/Basic/IdentifierTable.h" #include "clang/Basic/LLVM.h" +#include "clang/Basic/LangOptions.h" #include "clang/Basic/SourceLocation.h" #include "clang/Basic/Specifiers.h" #include "llvm/ADT/ArrayRef.h" @@ -488,6 +489,15 @@ public: // Return true if this is a FileContext Decl. bool isFileContextDecl() const; + /// Whether it resembles a flexible array member. This is a static member + /// because we want to be able to call it with a nullptr. That allows us to + /// perform non-Decl specific checks based on the object's type and strict + /// flex array level. + static bool isFlexibleArrayMemberLike( + ASTContext &Context, const Decl *D, QualType Ty, + LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel, + bool IgnoreTemplateOrMacroSubstitution); + ASTContext &getASTContext() const LLVM_READONLY; /// Helper to get the language options from the ASTContext. diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h index 984a4d8bab5e..648f5f946408 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclCXX.h @@ -1425,6 +1425,9 @@ public: /// (C++11 [class]p6). bool isTriviallyCopyable() const; + /// Determine whether this class is considered trivially copyable per + bool isTriviallyCopyConstructible() const; + /// Determine whether this class is considered trivial. /// /// C++11 [class]p6: diff --git a/contrib/llvm-project/clang/include/clang/AST/Stmt.h b/contrib/llvm-project/clang/include/clang/AST/Stmt.h index da7b37ce0e12..e1fde24e6477 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Stmt.h +++ b/contrib/llvm-project/clang/include/clang/AST/Stmt.h @@ -1631,8 +1631,10 @@ public: SourceLocation RB); // Build an empty compound statement with a location. - explicit CompoundStmt(SourceLocation Loc) - : Stmt(CompoundStmtClass), LBraceLoc(Loc), RBraceLoc(Loc) { + explicit CompoundStmt(SourceLocation Loc) : CompoundStmt(Loc, Loc) {} + + CompoundStmt(SourceLocation Loc, SourceLocation EndLoc) + : Stmt(CompoundStmtClass), LBraceLoc(Loc), RBraceLoc(EndLoc) { CompoundStmtBits.NumStmts = 0; CompoundStmtBits.HasFPFeatures = 0; } diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index 9e9f896ebef7..d4e5310fb3ab 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -917,6 +917,9 @@ public: /// Return true if this is a trivially copyable type (C++0x [basic.types]p9) bool isTriviallyCopyableType(const ASTContext &Context) const; + /// Return true if this is a trivially copyable type + bool isTriviallyCopyConstructibleType(const ASTContext &Context) const; + /// Return true if this is a trivially relocatable type. bool isTriviallyRelocatableType(const ASTContext &Context) const; diff --git a/contrib/llvm-project/clang/include/clang/Basic/Attr.td b/contrib/llvm-project/clang/include/clang/Basic/Attr.td index d5eabaad4889..a03b0e44e15f 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/Attr.td +++ b/contrib/llvm-project/clang/include/clang/Basic/Attr.td @@ -4372,3 +4372,21 @@ def CodeAlign: StmtAttr { static constexpr int MaximumAlignment = 4096; }]; } + +def CountedBy : InheritableAttr { + let Spellings = [Clang<"counted_by">]; + let Subjects = SubjectList<[Field]>; + let Args = [IdentifierArgument<"CountedByField">]; + let Documentation = [CountedByDocs]; + let LangOpts = [COnly]; + // FIXME: This is ugly. Let using a DeclArgument would be nice, but a Decl + // isn't yet available due to the fact that we're still parsing the + // structure. Maybe that code could be changed sometime in the future. + code AdditionalMembers = [{ + private: + SourceRange CountedByFieldLoc; + public: + SourceRange getCountedByFieldLoc() const { return CountedByFieldLoc; } + void setCountedByFieldLoc(SourceRange Loc) { CountedByFieldLoc = Loc; } + }]; +} diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 5416a0cbdd07..2e8d7752c975 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -7749,3 +7749,81 @@ but do not pass them to the underlying coroutine or pass them by value. .. _`CRT`: https://clang.llvm.org/docs/AttributeReference.html#coro-return-type }]; } + +def CountedByDocs : Documentation { + let Category = DocCatField; + let Content = [{ +Clang supports the ``counted_by`` attribute on the flexible array member of a +structure in C. The argument for the attribute is the name of a field member +holding the count of elements in the flexible array. This information can be +used to improve the results of the array bound sanitizer and the +``__builtin_dynamic_object_size`` builtin. The ``count`` field member must be +within the same non-anonymous, enclosing struct as the flexible array member. + +This example specifies that the flexible array member ``array`` has the number +of elements allocated for it in ``count``: + +.. code-block:: c + + struct bar; + + struct foo { + size_t count; + char other; + struct bar *array[] __attribute__((counted_by(count))); + }; + +This establishes a relationship between ``array`` and ``count``. Specifically, +``array`` must have at least ``count`` number of elements available. It's the +user's responsibility to ensure that this relationship is maintained through +changes to the structure. + +In the following example, the allocated array erroneously has fewer elements +than what's specified by ``p->count``. This would result in an out-of-bounds +access not being detected. + +.. code-block:: c + + #define SIZE_INCR 42 + + struct foo *p; + + void foo_alloc(size_t count) { + p = malloc(MAX(sizeof(struct foo), + offsetof(struct foo, array[0]) + count * sizeof(struct bar *))); + p->count = count + SIZE_INCR; + } + +The next example updates ``p->count``, but breaks the relationship requirement +that ``p->array`` must have at least ``p->count`` number of elements available: + +.. code-block:: c + + #define SIZE_INCR 42 + + struct foo *p; + + void foo_alloc(size_t count) { + p = malloc(MAX(sizeof(struct foo), + offsetof(struct foo, array[0]) + count * sizeof(struct bar *))); + p->count = count; + } + + void use_foo(int index, int val) { + p->count += SIZE_INCR + 1; /* 'count' is now larger than the number of elements of 'array'. */ + p->array[index] = val; /* The sanitizer can't properly check this access. */ + } + +In this example, an update to ``p->count`` maintains the relationship +requirement: + +.. code-block:: c + + void use_foo(int index, int val) { + if (p->count == 0) + return; + --p->count; + p->array[index] = val; + } + }]; +} diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td index 568000106a84..85ecfdf9de62 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticFrontendKinds.td @@ -167,7 +167,7 @@ def err_verify_no_such_marker : Error< def err_verify_missing_start : Error< "cannot find start ('{{') of expected %0">; def err_verify_missing_end : Error< - "cannot find end ('}}') of expected %0">; + "cannot find end ('%1') of expected %0">; def err_verify_invalid_content : Error< "invalid expected %0: %1">; def err_verify_missing_regex : Error< diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index e81d1a4fc288..e46779349475 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -2253,6 +2253,8 @@ def warn_cxx17_compat_aggregate_init_paren_list : Warning< def err_reference_bind_to_bitfield : Error< "%select{non-const|volatile}0 reference cannot bind to " "bit-field%select{| %1}2">; +def err_reference_bind_to_bitfield_in_cce : Error< + "reference cannot bind to bit-field in converted constant expression">; def err_reference_bind_to_vector_element : Error< "%select{non-const|volatile}0 reference cannot bind to vector element">; def err_reference_bind_to_matrix_element : Error< @@ -6439,6 +6441,19 @@ def warn_superclass_variable_sized_type_not_at_end : Warning< "field %0 can overwrite instance variable %1 with variable sized type %2" " in superclass %3">, InGroup; +def err_flexible_array_count_not_in_same_struct : Error< + "'counted_by' field %0 isn't within the same struct as the flexible array">; +def err_counted_by_attr_not_on_flexible_array_member : Error< + "'counted_by' only applies to C99 flexible array members">; +def err_counted_by_attr_refers_to_flexible_array : Error< + "'counted_by' cannot refer to the flexible array %0">; +def err_counted_by_must_be_in_structure : Error< + "field %0 in 'counted_by' not inside structure">; +def err_flexible_array_counted_by_attr_field_not_integer : Error< + "field %0 in 'counted_by' must be a non-boolean integer type">; +def note_flexible_array_counted_by_attr_field : Note< + "field %0 declared here">; + let CategoryName = "ARC Semantic Issue" in { // ARC-mode diagnostics. diff --git a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def index 21abc346cf17..0428b70c6020 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def @@ -457,6 +457,7 @@ ENUM_LANGOPT(SignReturnAddressKey, SignReturnAddressKeyKind, 1, SignReturnAddres "Key used for return address signing") LANGOPT(BranchTargetEnforcement, 1, 0, "Branch-target enforcement enabled") LANGOPT(BranchProtectionPAuthLR, 1, 0, "Use PC as a diversifier using PAuthLR NOP instructions.") +LANGOPT(GuardedControlStack, 1, 0, "Guarded control stack enabled") LANGOPT(SpeculativeLoadHardening, 1, 0, "Speculative load hardening enabled") diff --git a/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h b/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h index ac3c324c6c29..3eb23ebdacf0 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h +++ b/contrib/llvm-project/clang/include/clang/Basic/TargetInfo.h @@ -1373,6 +1373,7 @@ public: LangOptions::SignReturnAddressKeyKind::AKey; bool BranchTargetEnforcement = false; bool BranchProtectionPAuthLR = false; + bool GuardedControlStack = false; }; /// Determine if the Architecture in this TargetInfo supports branch diff --git a/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td b/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td index 7f80fb0386cc..6f35e25617ad 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td +++ b/contrib/llvm-project/clang/include/clang/Basic/arm_sve.td @@ -454,11 +454,11 @@ let TargetGuard = "sve,bf16" in { let TargetGuard = "sve2p1" in { // Contiguous truncating store from quadword (single vector). - def SVST1UWQ : MInst<"svst1uwq[_{d}]", "vPcd", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1uwq">; - def SVST1UWQ_VNUM : MInst<"svst1uwq_vnum[_{d}]", "vPcld", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1uwq">; + def SVST1UWQ : MInst<"svst1wq[_{d}]", "vPcd", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1wq">; + def SVST1UWQ_VNUM : MInst<"svst1wq_vnum[_{d}]", "vPcld", "iUif", [IsStore], MemEltTyInt32, "aarch64_sve_st1wq">; - def SVST1UDQ : MInst<"svst1udq[_{d}]", "vPcd", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1udq">; - def SVST1UDQ_VNUM : MInst<"svst1udq_vnum[_{d}]", "vPcld", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1udq">; + def SVST1UDQ : MInst<"svst1dq[_{d}]", "vPcd", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1dq">; + def SVST1UDQ_VNUM : MInst<"svst1dq_vnum[_{d}]", "vPcld", "lUld", [IsStore], MemEltTyInt64, "aarch64_sve_st1dq">; // Store one vector (vector base + scalar offset) def SVST1Q_SCATTER_U64BASE_OFFSET : MInst<"svst1q_scatter[_{2}base]_offset[_{d}]", "vPgld", "cUcsUsiUilUlfhdb", [IsScatterStore, IsByteIndexed], MemEltTyDefault, "aarch64_sve_st1q_scatter_scalar_offset">; @@ -2040,12 +2040,12 @@ let TargetGuard = "sve2p1|sme2" in { } let TargetGuard = "sve2p1" in { -def SVDOT_X2_S : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "i", MergeNone, "aarch64_sve_sdot_x2", [], []>; -def SVDOT_X2_U : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "Ui", MergeNone, "aarch64_sve_udot_x2", [], []>; -def SVDOT_X2_F : SInst<"svdot[_{d}_{2}_{3}]", "ddhh", "f", MergeNone, "aarch64_sve_fdot_x2", [], []>; -def SVDOT_LANE_X2_S : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "i", MergeNone, "aarch64_sve_sdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; -def SVDOT_LANE_X2_U : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "Ui", MergeNone, "aarch64_sve_udot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; -def SVDOT_LANE_X2_F : SInst<"svdot_lane[_{d}_{2}_{3}]", "ddhhi", "f", MergeNone, "aarch64_sve_fdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_X2_S : SInst<"svdot[_{d}_{2}]", "ddhh", "i", MergeNone, "aarch64_sve_sdot_x2", [], []>; +def SVDOT_X2_U : SInst<"svdot[_{d}_{2}]", "ddhh", "Ui", MergeNone, "aarch64_sve_udot_x2", [], []>; +def SVDOT_X2_F : SInst<"svdot[_{d}_{2}]", "ddhh", "f", MergeNone, "aarch64_sve_fdot_x2", [], []>; +def SVDOT_LANE_X2_S : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "i", MergeNone, "aarch64_sve_sdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_LANE_X2_U : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "Ui", MergeNone, "aarch64_sve_udot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; +def SVDOT_LANE_X2_F : SInst<"svdot_lane[_{d}_{2}]", "ddhhi", "f", MergeNone, "aarch64_sve_fdot_lane_x2", [], [ImmCheck<3, ImmCheck0_3>]>; } let TargetGuard = "sve2p1|sme2" in { @@ -2208,7 +2208,7 @@ let TargetGuard = "sve2p1" in { def SVTBLQ : SInst<"svtblq[_{d}]", "ddu", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_tblq">; def SVTBXQ : SInst<"svtbxq[_{d}]", "dddu", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_tbxq">; // EXTQ - def EXTQ : SInst<"svextq_lane[_{d}]", "dddk", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_extq_lane", [], [ImmCheck<2, ImmCheck0_15>]>; + def EXTQ : SInst<"svextq[_{d}]", "dddk", "cUcsUsiUilUlbhfd", MergeNone, "aarch64_sve_extq", [], [ImmCheck<2, ImmCheck0_15>]>; // PMOV // Move to Pred multiclass PMOV_TO_PRED flags=[], ImmCheckType immCh > { diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index 84648c6d5500..7f97d6b6faa3 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -4267,7 +4267,7 @@ def iquote : JoinedOrSeparate<["-"], "iquote">, Group, Visibility<[ClangOption, CC1Option]>, HelpText<"Add directory to QUOTE include search path">, MetaVarName<"">; def isysroot : JoinedOrSeparate<["-"], "isysroot">, Group, - Visibility<[ClangOption, CC1Option]>, + Visibility<[ClangOption, CC1Option, FlangOption]>, HelpText<"Set the system root directory (usually /)">, MetaVarName<"">, MarshallingInfoString, [{"/"}]>; def isystem : JoinedOrSeparate<["-"], "isystem">, Group, @@ -4585,11 +4585,13 @@ let Flags = [TargetSpecific] in { def menable_experimental_extensions : Flag<["-"], "menable-experimental-extensions">, Group, HelpText<"Enable use of experimental RISC-V extensions.">; def mrvv_vector_bits_EQ : Joined<["-"], "mrvv-vector-bits=">, Group, - HelpText<"Specify the size in bits of an RVV vector register. Defaults to " - "the vector length agnostic value of \"scalable\". Accepts power of " - "2 values between 64 and 65536. Also accepts \"zvl\" " - "to use the value implied by -march/-mcpu. Value will be reflected " - "in __riscv_v_fixed_vlen preprocessor define (RISC-V only)">; + Visibility<[ClangOption, FlangOption]>, + HelpText<"Specify the size in bits of an RVV vector register">, + DocBrief<"Defaults to the vector length agnostic value of \"scalable\". " + "Accepts power of 2 values between 64 and 65536. Also accepts " + "\"zvl\" to use the value implied by -march/-mcpu. On Clang, value " + "will be reflected in __riscv_v_fixed_vlen preprocessor define " + "(RISC-V only)">; def munaligned_access : Flag<["-"], "munaligned-access">, Group, HelpText<"Allow memory accesses to be unaligned (AArch32/AArch64/LoongArch/RISC-V only)">; @@ -5197,7 +5199,7 @@ def nohipwrapperinc : Flag<["-"], "nohipwrapperinc">, Group, HelpText<"Do not include the default HIP wrapper headers and include paths">; def : Flag<["-"], "nocudainc">, Alias; def nogpulib : Flag<["-"], "nogpulib">, MarshallingInfoFlag>, - Visibility<[ClangOption, CC1Option]>, + Visibility<[ClangOption, CC1Option, FlangOption, FC1Option]>, HelpText<"Do not link device library for CUDA/HIP device compilation">; def : Flag<["-"], "nocudalib">, Alias; def gpulibc : Flag<["-"], "gpulibc">, Visibility<[ClangOption, CC1Option, FlangOption, FC1Option]>, @@ -7010,6 +7012,8 @@ def mbranch_target_enforce : Flag<["-"], "mbranch-target-enforce">, MarshallingInfoFlag>; def mbranch_protection_pauth_lr : Flag<["-"], "mbranch-protection-pauth-lr">, MarshallingInfoFlag>; +def mguarded_control_stack : Flag<["-"], "mguarded-control-stack">, + MarshallingInfoFlag>; def fno_dllexport_inlines : Flag<["-"], "fno-dllexport-inlines">, MarshallingInfoNegativeFlag>; def cfguard_no_checks : Flag<["-"], "cfguard-no-checks">, diff --git a/contrib/llvm-project/clang/include/clang/Format/Format.h b/contrib/llvm-project/clang/include/clang/Format/Format.h index 8604dea689f9..59b645ecab71 100755 --- a/contrib/llvm-project/clang/include/clang/Format/Format.h +++ b/contrib/llvm-project/clang/include/clang/Format/Format.h @@ -225,6 +225,22 @@ struct FormatStyle { /// bbb = 2; /// \endcode bool AlignCompound; + /// Only for ``AlignConsecutiveDeclarations``. Whether function pointers are + /// aligned. + /// \code + /// true: + /// unsigned i; + /// int &r; + /// int *p; + /// int (*f)(); + /// + /// false: + /// unsigned i; + /// int &r; + /// int *p; + /// int (*f)(); + /// \endcode + bool AlignFunctionPointers; /// Only for ``AlignConsecutiveAssignments``. Whether short assignment /// operators are left-padded to the same length as long ones in order to /// put all assignment operators to the right of the left hand side. @@ -247,7 +263,9 @@ struct FormatStyle { bool operator==(const AlignConsecutiveStyle &R) const { return Enabled == R.Enabled && AcrossEmptyLines == R.AcrossEmptyLines && AcrossComments == R.AcrossComments && - AlignCompound == R.AlignCompound && PadOperators == R.PadOperators; + AlignCompound == R.AlignCompound && + AlignFunctionPointers == R.AlignFunctionPointers && + PadOperators == R.PadOperators; } bool operator!=(const AlignConsecutiveStyle &R) const { return !(*this == R); diff --git a/contrib/llvm-project/clang/include/clang/Parse/Parser.h b/contrib/llvm-project/clang/include/clang/Parse/Parser.h index 2dbe090bd093..186dbb770858 100644 --- a/contrib/llvm-project/clang/include/clang/Parse/Parser.h +++ b/contrib/llvm-project/clang/include/clang/Parse/Parser.h @@ -234,6 +234,26 @@ class Parser : public CodeCompletionHandler { /// Parsing OpenACC directive mode. bool OpenACCDirectiveParsing = false; + /// Currently parsing a situation where an OpenACC array section could be + /// legal, such as a 'var-list'. + bool AllowOpenACCArraySections = false; + + /// RAII object to set reset OpenACC parsing a context where Array Sections + /// are allowed. + class OpenACCArraySectionRAII { + Parser &P; + + public: + OpenACCArraySectionRAII(Parser &P) : P(P) { + assert(!P.AllowOpenACCArraySections); + P.AllowOpenACCArraySections = true; + } + ~OpenACCArraySectionRAII() { + assert(P.AllowOpenACCArraySections); + P.AllowOpenACCArraySections = false; + } + }; + /// When true, we are directly inside an Objective-C message /// send expression. /// @@ -3546,8 +3566,8 @@ private: ExprResult ParseOpenACCIDExpression(); /// Parses the variable list for the `cache` construct. void ParseOpenACCCacheVarList(); - /// Parses a single variable in a variable list for the 'cache' construct. - bool ParseOpenACCCacheVar(); + /// Parses a single variable in a variable list for OpenACC. + bool ParseOpenACCVar(); bool ParseOpenACCWaitArgument(); private: diff --git a/contrib/llvm-project/clang/include/clang/Sema/Sema.h b/contrib/llvm-project/clang/include/clang/Sema/Sema.h index edaee4c4b66d..cf2d4fbe6d3b 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Sema.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Sema.h @@ -4799,6 +4799,8 @@ public: bool CheckAlwaysInlineAttr(const Stmt *OrigSt, const Stmt *CurSt, const AttributeCommonInfo &A); + bool CheckCountedByAttr(Scope *Scope, const FieldDecl *FD); + /// Adjust the calling convention of a method to be the ABI default if it /// wasn't specified explicitly. This handles method types formed from /// function type typedefs and typename template arguments. @@ -5642,6 +5644,7 @@ public: CorrectionCandidateCallback &CCC, TemplateArgumentListInfo *ExplicitTemplateArgs = nullptr, ArrayRef Args = std::nullopt, + DeclContext *LookupCtx = nullptr, TypoExpr **Out = nullptr); DeclResult LookupIvarInObjCMethod(LookupResult &Lookup, Scope *S, diff --git a/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h b/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h index e0f8d152dbe5..09de164297e7 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h +++ b/contrib/llvm-project/clang/include/clang/Sema/TypoCorrection.h @@ -282,7 +282,7 @@ class CorrectionCandidateCallback { public: static const unsigned InvalidDistance = TypoCorrection::InvalidDistance; - explicit CorrectionCandidateCallback(IdentifierInfo *Typo = nullptr, + explicit CorrectionCandidateCallback(const IdentifierInfo *Typo = nullptr, NestedNameSpecifier *TypoNNS = nullptr) : Typo(Typo), TypoNNS(TypoNNS) {} @@ -319,7 +319,7 @@ public: /// this method. virtual std::unique_ptr clone() = 0; - void setTypoName(IdentifierInfo *II) { Typo = II; } + void setTypoName(const IdentifierInfo *II) { Typo = II; } void setTypoNNS(NestedNameSpecifier *NNS) { TypoNNS = NNS; } // Flags for context-dependent keywords. WantFunctionLikeCasts is only @@ -345,13 +345,13 @@ protected: candidate.getCorrectionSpecifier() == TypoNNS; } - IdentifierInfo *Typo; + const IdentifierInfo *Typo; NestedNameSpecifier *TypoNNS; }; class DefaultFilterCCC final : public CorrectionCandidateCallback { public: - explicit DefaultFilterCCC(IdentifierInfo *Typo = nullptr, + explicit DefaultFilterCCC(const IdentifierInfo *Typo = nullptr, NestedNameSpecifier *TypoNNS = nullptr) : CorrectionCandidateCallback(Typo, TypoNNS) {} @@ -365,6 +365,10 @@ public: template class DeclFilterCCC final : public CorrectionCandidateCallback { public: + explicit DeclFilterCCC(const IdentifierInfo *Typo = nullptr, + NestedNameSpecifier *TypoNNS = nullptr) + : CorrectionCandidateCallback(Typo, TypoNNS) {} + bool ValidateCandidate(const TypoCorrection &candidate) override { return candidate.getCorrectionDeclAs(); } diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index b60dcfaabfd1..d9cefcaa84d7 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -1318,6 +1318,13 @@ void ASTContext::InitBuiltinTypes(const TargetInfo &Target, InitBuiltinType(OMPArrayShapingTy, BuiltinType::OMPArrayShaping); InitBuiltinType(OMPIteratorTy, BuiltinType::OMPIterator); } + // Placeholder type for OpenACC array sections. + if (LangOpts.OpenACC) { + // FIXME: Once we implement OpenACC array sections in Sema, this will either + // be combined with the OpenMP type, or given its own type. In the meantime, + // just use the OpenMP type so that parsing can work. + InitBuiltinType(OMPArraySectionTy, BuiltinType::OMPArraySection); + } if (LangOpts.MatrixTypes) InitBuiltinType(IncompleteMatrixIdxTy, BuiltinType::IncompleteMatrixIdx); diff --git a/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp b/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp index 5e5570bb42a1..b762d6a4cd38 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTImporter.cpp @@ -5929,15 +5929,22 @@ ExpectedDecl ASTNodeImporter::VisitClassTemplateDecl(ClassTemplateDecl *D) { if (ToD) return ToD; - bool IsFriendTemplate = D->getFriendObjectKind() != Decl::FOK_None; - bool IsDependentContext = DC != LexicalDC ? LexicalDC->isDependentContext() - : DC->isDependentContext(); - bool DependentFriend = IsFriendTemplate && IsDependentContext; + // Should check if a declaration is friend in a dependent context. + // Such templates are not linked together in a declaration chain. + // The ASTImporter strategy is to map existing forward declarations to + // imported ones only if strictly necessary, otherwise import these as new + // forward declarations. In case of the "dependent friend" declarations, new + // declarations are created, but not linked in a declaration chain. + auto IsDependentFriend = [](ClassTemplateDecl *TD) { + return TD->getFriendObjectKind() != Decl::FOK_None && + TD->getLexicalDeclContext()->isDependentContext(); + }; + bool DependentFriend = IsDependentFriend(D); ClassTemplateDecl *FoundByLookup = nullptr; // We may already have a template of the same name; try to find and match it. - if (!DependentFriend && !DC->isFunctionOrMethod()) { + if (!DC->isFunctionOrMethod()) { SmallVector ConflictingDecls; auto FoundDecls = Importer.findDeclsInToCtx(DC, Name); for (auto *FoundDecl : FoundDecls) { @@ -5953,10 +5960,13 @@ ExpectedDecl ASTNodeImporter::VisitClassTemplateDecl(ClassTemplateDecl *D) { // FIXME: sufficient conditon for 'IgnoreTemplateParmDepth'? bool IgnoreTemplateParmDepth = - FoundTemplate->getFriendObjectKind() != Decl::FOK_None && - !D->specializations().empty(); + (FoundTemplate->getFriendObjectKind() != Decl::FOK_None) != + (D->getFriendObjectKind() != Decl::FOK_None); if (IsStructuralMatch(D, FoundTemplate, /*Complain=*/true, IgnoreTemplateParmDepth)) { + if (DependentFriend || IsDependentFriend(FoundTemplate)) + continue; + ClassTemplateDecl *TemplateWithDef = getTemplateDefinition(FoundTemplate); if (D->isThisDeclarationADefinition() && TemplateWithDef) @@ -9030,6 +9040,10 @@ class AttrImporter { public: AttrImporter(ASTImporter &I) : Importer(I), NImporter(I) {} + // Useful for accessing the imported attribute. + template T *castAttrAs() { return cast(ToAttr); } + template const T *castAttrAs() const { return cast(ToAttr); } + // Create an "importer" for an attribute parameter. // Result of the 'value()' of that object is to be passed to the function // 'importAttr', in the order that is expected by the attribute class. @@ -9243,6 +9257,15 @@ Expected ASTImporter::Import(const Attr *FromAttr) { From->args_size()); break; } + case attr::CountedBy: { + AI.cloneAttr(FromAttr); + const auto *CBA = cast(FromAttr); + Expected SR = Import(CBA->getCountedByFieldLoc()).get(); + if (!SR) + return SR.takeError(); + AI.castAttrAs()->setCountedByFieldLoc(SR.get()); + break; + } default: { // The default branch works for attributes that have no arguments to import. diff --git a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp index b1733c2d052a..8163f9bdaf8d 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp @@ -29,7 +29,6 @@ #include "clang/AST/Type.h" #include "clang/Basic/IdentifierTable.h" #include "clang/Basic/LLVM.h" -#include "clang/Basic/LangOptions.h" #include "clang/Basic/Module.h" #include "clang/Basic/ObjCRuntime.h" #include "clang/Basic/PartialDiagnostic.h" @@ -411,6 +410,79 @@ bool Decl::isFileContextDecl() const { return DC && DC->isFileContext(); } +bool Decl::isFlexibleArrayMemberLike( + ASTContext &Ctx, const Decl *D, QualType Ty, + LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel, + bool IgnoreTemplateOrMacroSubstitution) { + // For compatibility with existing code, we treat arrays of length 0 or + // 1 as flexible array members. + const auto *CAT = Ctx.getAsConstantArrayType(Ty); + if (CAT) { + using FAMKind = LangOptions::StrictFlexArraysLevelKind; + + llvm::APInt Size = CAT->getSize(); + if (StrictFlexArraysLevel == FAMKind::IncompleteOnly) + return false; + + // GCC extension, only allowed to represent a FAM. + if (Size.isZero()) + return true; + + if (StrictFlexArraysLevel == FAMKind::ZeroOrIncomplete && Size.uge(1)) + return false; + + if (StrictFlexArraysLevel == FAMKind::OneZeroOrIncomplete && Size.uge(2)) + return false; + } else if (!Ctx.getAsIncompleteArrayType(Ty)) { + return false; + } + + if (const auto *OID = dyn_cast_if_present(D)) + return OID->getNextIvar() == nullptr; + + const auto *FD = dyn_cast_if_present(D); + if (!FD) + return false; + + if (CAT) { + // GCC treats an array memeber of a union as an FAM if the size is one or + // zero. + llvm::APInt Size = CAT->getSize(); + if (FD->getParent()->isUnion() && (Size.isZero() || Size.isOne())) + return true; + } + + // Don't consider sizes resulting from macro expansions or template argument + // substitution to form C89 tail-padded arrays. + if (IgnoreTemplateOrMacroSubstitution) { + TypeSourceInfo *TInfo = FD->getTypeSourceInfo(); + while (TInfo) { + TypeLoc TL = TInfo->getTypeLoc(); + + // Look through typedefs. + if (TypedefTypeLoc TTL = TL.getAsAdjusted()) { + const TypedefNameDecl *TDL = TTL.getTypedefNameDecl(); + TInfo = TDL->getTypeSourceInfo(); + continue; + } + + if (auto CTL = TL.getAs()) { + if (const Expr *SizeExpr = + dyn_cast_if_present(CTL.getSizeExpr()); + !SizeExpr || SizeExpr->getExprLoc().isMacroID()) + return false; + } + + break; + } + } + + // Test that the field is the last in the structure. + RecordDecl::field_iterator FI( + DeclContext::decl_iterator(const_cast(FD))); + return ++FI == FD->getParent()->field_end(); +} + TranslationUnitDecl *Decl::getTranslationUnitDecl() { if (auto *TUD = dyn_cast(this)) return TUD; diff --git a/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp b/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp index c944862fcefe..98b0a6dc28ea 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclCXX.cpp @@ -587,6 +587,19 @@ bool CXXRecordDecl::isTriviallyCopyable() const { return true; } +bool CXXRecordDecl::isTriviallyCopyConstructible() const { + + // A trivially copy constructible class is a class that: + // -- has no non-trivial copy constructors, + if (hasNonTrivialCopyConstructor()) + return false; + // -- has a trivial destructor. + if (!hasTrivialDestructor()) + return false; + + return true; +} + void CXXRecordDecl::markedVirtualFunctionPure() { // C++ [class.abstract]p2: // A class is abstract if it has at least one pure virtual function. diff --git a/contrib/llvm-project/clang/lib/AST/Expr.cpp b/contrib/llvm-project/clang/lib/AST/Expr.cpp index a90f92d07f86..b125fc676da8 100644 --- a/contrib/llvm-project/clang/lib/AST/Expr.cpp +++ b/contrib/llvm-project/clang/lib/AST/Expr.cpp @@ -205,85 +205,22 @@ bool Expr::isKnownToHaveBooleanValue(bool Semantic) const { *** 13055 LINES SKIPPED *** From nobody Sat Apr 20 10:34:27 2024 X-Original-To: dev-commits-src-branches@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 4VM7DN04v7z5HWTN; Sat, 20 Apr 2024 10:34:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DM2PPmz4SMx; Sat, 20 Apr 2024 10:34:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609267; 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=oIkZBqFAx1X3TiUDPH7HzRm/A8jikwiVRa3VqRNhlIQ=; b=HPzI/vgmZouFRlJI5u8gIW+cyE1P9jDOrPyceob0YXxyRAb2gIs8fQVfrVSsbwVoCTfXUd XF7f3mP7k/RH9wnClVpm0b/32A0f9Daj+RYZ/3WkeFUyw4oHlN7PRQ0OGdklsPZud0b3s8 fdo4f666KEmtYscqkSxAP7C2DempQMhjswUUx3cfWu5h0nxmrbIWMiqGR52Ckuo+6zJIR+ kIYiQw/eO9lP55So3HDcHJzyar9kSevRj7MpsWKikYNTVx8BEgpkrXsJGSLZDIwbeRwWOJ xT62JTMNXl+0V/2lOLjWC22yu44nnMoTY1/+Xed4NCm0OCgHLvlH/s/RTDCZiA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609267; a=rsa-sha256; cv=none; b=IE9U9xM6KPsZNoTorLDVSrmz+X3q/XVb5nW8SzIUCLdlJzclFVP/B6shgP91uSsHVLn/B9 3pOPsVU8IHpg47Zv7GLexakuKGgcvkAzPldulCLzFGOvoaU2yEykFVGzxQz1tNUZHBns8i MCgEUv20FlSti8PMqhDyc/fSjxYZwOHQs7wKfz+fUJQ0dfViESUnX5nIJi5g53XKySR1EE WItqKijcacEp2Jk7PUQWgyz5Btl+uVubFvTLOpu7+bJ45eBTPE+lZfYJW6LK2Io3BmYPao Q7fNXkjEV3gQ6qZ9m/AC/T/FqPxQpRHNe23cqJkDNmy7jKXsVlfu2T1kSNVR7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609267; 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=oIkZBqFAx1X3TiUDPH7HzRm/A8jikwiVRa3VqRNhlIQ=; b=tR2tSUxZTL00TSp6erczbbdUkwVHCDp+eOKoqSW1vjS4SxjqE41P0ROdBFJ6IFcy1rLMqa uled5/H/sOov1d69sXLbNbTin7WTFoLC+XLJ+xfve2LtXJ986/6KvrZ2etUpGog0Fu/eAi rW91D7LSzUP1wwH9pq6SUyLnmIhmTQfKyw/VmPrEjdAe60RoT6AftD7ZWFylZwaVjy5NVo qUtriA9cZHJO0ObKiREz4lRF6/+lyg6MwRajt+TG0XzSfZ84cv4b2dgGECzPQKzFk0pIII +vcgPQm4XBDaoaEydHzUbPZ1K8LXGghNO8rNdH+mjJP2lQSTpTsac1tv/hcWnw== 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 4VM7DM1zQPzYkg; Sat, 20 Apr 2024 10:34:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYReB013582; Sat, 20 Apr 2024 10:34:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYRpM013579; Sat, 20 Apr 2024 10:34:27 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:27 GMT Message-Id: <202404201034.43KAYRpM013579@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: 412542983a5b - stable/13 - Redo libc++ customizations List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 412542983a5ba62902141a8a7e155cceb9196a66 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=412542983a5ba62902141a8a7e155cceb9196a66 commit 412542983a5ba62902141a8a7e155cceb9196a66 Author: Dimitry Andric AuthorDate: 2024-01-14 13:20:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:43 +0000 Redo libc++ customizations * Remove osreldate include because _LIBCPP_HAS_NO_GETS has disappeared * Instead, add direct major __FreeBSD__ check for using ::gets declaration * Mark EINTEGRITY values as FreeBSD customization * Reformat _LIBCPP_TYPE_VISIBILITY_DEFAULT customization PR: 276104 MFC after: 1 month (cherry picked from commit 46c59ea9b61755455ff6bf9f3e7b834e1af634ea) --- contrib/llvm-project/libcxx/include/__config | 8 ++------ contrib/llvm-project/libcxx/include/__system_error/errc.h | 4 ++-- contrib/llvm-project/libcxx/include/cstdio | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index ce4cece198b1..9154be8d8577 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -486,10 +486,6 @@ _LIBCPP_HARDENING_MODE_DEBUG # include // for __NATIVE_ASCII_F # endif -# ifdef __FreeBSD__ -# include // for __FreeBSD_version -# endif - # ifndef __BYTE_ORDER__ # error \ "Your compiler doesn't seem to define __BYTE_ORDER__, which is required by libc++ to know the endianness of your target platform" @@ -734,8 +730,8 @@ typedef __char32_t char32_t; # define _LIBCPP_TEMPLATE_VIS # endif -# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) \ - && _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization +# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__) && \ + _LIBCPP_CLANG_VER >= 1500 // FreeBSD customization # define _LIBCPP_TYPE_VISIBILITY_DEFAULT __attribute__((__type_visibility__("default"))) # else # define _LIBCPP_TYPE_VISIBILITY_DEFAULT diff --git a/contrib/llvm-project/libcxx/include/__system_error/errc.h b/contrib/llvm-project/libcxx/include/__system_error/errc.h index a14ec56070c4..b0cdacc5ec1d 100644 --- a/contrib/llvm-project/libcxx/include/__system_error/errc.h +++ b/contrib/llvm-project/libcxx/include/__system_error/errc.h @@ -45,7 +45,7 @@ enum class errc identifier_removed, // EIDRM illegal_byte_sequence, // EILSEQ inappropriate_io_control_operation, // ENOTTY - integrity_check_failed, // EINTEGRITY + integrity_check_failed, // EINTEGRITY // FreeBSD customization interrupted, // EINTR invalid_argument, // EINVAL invalid_seek, // ESPIPE @@ -143,7 +143,7 @@ _LIBCPP_DECLARE_STRONG_ENUM(errc){ illegal_byte_sequence = EILSEQ, inappropriate_io_control_operation = ENOTTY, #ifdef EINTEGRITY - integrity_check_failed = EINTEGRITY, + integrity_check_failed = EINTEGRITY, // FreeBSD customization #endif interrupted = EINTR, invalid_argument = EINVAL, diff --git a/contrib/llvm-project/libcxx/include/cstdio b/contrib/llvm-project/libcxx/include/cstdio index 0a867cec1a38..383655036d5f 100644 --- a/contrib/llvm-project/libcxx/include/cstdio +++ b/contrib/llvm-project/libcxx/include/cstdio @@ -159,7 +159,7 @@ using ::tmpfile _LIBCPP_USING_IF_EXISTS; using ::tmpnam _LIBCPP_USING_IF_EXISTS; using ::getchar _LIBCPP_USING_IF_EXISTS; -#if _LIBCPP_STD_VER <= 11 +#if _LIBCPP_STD_VER <= 11 && !(defined(__FreeBSD__) && __FreeBSD__ >= 13) // FreeBSD customization using ::gets _LIBCPP_USING_IF_EXISTS; #endif using ::scanf _LIBCPP_USING_IF_EXISTS; From nobody Sat Apr 20 10:34:28 2024 X-Original-To: dev-commits-src-branches@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 4VM7DR2YM5z5HW0Q; Sat, 20 Apr 2024 10:34:31 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DR1Xmwz4SYy; Sat, 20 Apr 2024 10:34:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609271; 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=hLbpoBgvvcp+ZGCj81Dlc+R1PzrsFVQQbHH85tjJSsQ=; b=nv8DzCQ/oq4wA4tqagbi+2ISbRmmAvSEc7TrwTxNZzbFDFLlB585bDt9RacMYKTo8nSPLA GVVZmuSSh1KD0nzPgiUGNKR0DZVu0XWEg9FOPati5R+TMALTRh/sh3wbN41vI7G6YelW1D rVA3Ni7uW2dloOO7IYXEGIQgJiqSVUqbpsyR8rTUd4M4Izn8o0LOMfT5WOPcIh8PInsZ8p +yqhZOji2+Wjv8vEYeP8kcKruhoZkmXJwcp5U7moxuh45u09vvVPh32wqixNtBn6pd9pKy Q8QpJJSXC3CqHrEiFe0e3QOsmco5hPJy+qDNDYqb8/gRlJWG5TpHKl0tJBbdWQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609271; a=rsa-sha256; cv=none; b=DzhGp9j9MWA8aVfKQleVLFduIESr4h0RSaa9WRp4RcTpS5/DHMIYtsqOqJKljukm1L6Hdm 1SfCMJ1kDEgzShUac8dkGXOKpcA3SIVgwrl0Z+gXM/s8Db47sYtLjcuYvNnCjE6tgWVrzG lKYrhAq4a+AQ4GYxFfI4gGA8IzxW41ZQ7YVtK2x7KAhK5eK9wADramlM4A6sDxo+Fjch/G 4jl7oOpy25tdJTW0JOxWgKFEpV35WSgLEMjh/jC+XTOmLAkpeOnOLztWt2dVgDOHUbovNn 8X82Sy9SNquHUPcdpTe0ygJjEEiFI+5pQ8QV8BnJpyGzdujTGsyhSZpYqe00tA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609271; 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=hLbpoBgvvcp+ZGCj81Dlc+R1PzrsFVQQbHH85tjJSsQ=; b=rXleARMkJlVJ4ZCnGnAf8Nttom8kIDoCkzE9/SxFMa1Z4GWXBG82QLe0ISQo12q4fPgw0m 3D75qMlLjb9KV4ekPgE6xmCZ7DKgX0lEJ2Ygx5QKh3TWVPf2HLXo3rxZbkKFHFKwwI98PV VM0Ol0jIwYnvyH++flJWE9u9kvYyV8iLkrq1XgB3lVptIxMqiOJUP2HWc8yAwGq3q6hosX 0iECz9sv4cPPLOX6Lz/YyugeTHss/0TRlIKFJkFAMQ1qQSSz14RAr41bNgBJ4CIIhgkM8F Tlt0GAwQJDmA5F7MWmsUgWurEEjoE+kfZhghykgrjp+M7u/IasPGHsDnqDd4jw== 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 4VM7DR0lBjzZFj; Sat, 20 Apr 2024 10:34:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYV0p013624; Sat, 20 Apr 2024 10:34:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYS0S013618; Sat, 20 Apr 2024 10:34:28 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:28 GMT Message-Id: <202404201034.43KAYS0S013618@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: ab50317e96e5 - stable/13 - Merge llvm-project main llvmorg-18-init-18359-g93248729cfae List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: ab50317e96e57dee5b3ff4ad3f16f205b2a3359e Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ab50317e96e57dee5b3ff4ad3f16f205b2a3359e commit ab50317e96e57dee5b3ff4ad3f16f205b2a3359e Author: Dimitry Andric AuthorDate: 2024-01-24 19:17:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:44 +0000 Merge llvm-project main llvmorg-18-init-18359-g93248729cfae This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project main llvmorg-18-init-18359-g93248729cfae, the last commit before the upstream release/18.x branch was created. PR: 276104 MFC after: 1 month (cherry picked from commit 7a6dacaca14b62ca4b74406814becb87a3fefac0) --- contrib/llvm-project/FREEBSD-Xlist | 7 +- .../clang/include/clang/AST/APNumericStorage.h | 71 + .../llvm-project/clang/include/clang/AST/Decl.h | 25 +- .../clang/include/clang/AST/DeclBase.h | 9 +- .../llvm-project/clang/include/clang/AST/DeclCXX.h | 41 +- .../llvm-project/clang/include/clang/AST/Expr.h | 64 +- .../llvm-project/clang/include/clang/AST/ExprCXX.h | 19 +- .../llvm-project/clang/include/clang/AST/ODRHash.h | 3 + .../clang/include/clang/AST/PropertiesBase.td | 14 + .../clang/include/clang/AST/RecursiveASTVisitor.h | 2 + .../llvm-project/clang/include/clang/AST/Stmt.h | 8 +- .../include/clang/AST/TemplateArgumentVisitor.h | 2 + .../clang/include/clang/AST/TemplateBase.h | 86 +- .../llvm-project/clang/include/clang/AST/Type.h | 88 +- .../clang/include/clang/ASTMatchers/ASTMatchers.h | 205 +- .../clang/ASTMatchers/ASTMatchersInternal.h | 3 + .../Analysis/FlowSensitive/ControlFlowContext.h | 3 +- .../Analysis/FlowSensitive/DataflowAnalysis.h | 21 +- .../Analysis/FlowSensitive/DataflowEnvironment.h | 3 +- .../include/clang/Analysis/FlowSensitive/Formula.h | 4 + .../clang/Analysis/FlowSensitive/Transfer.h | 13 +- .../FlowSensitive/TypeErasedDataflowAnalysis.h | 9 +- .../llvm-project/clang/include/clang/Basic/Attr.td | 98 +- .../clang/include/clang/Basic/AttrDocs.td | 84 +- .../include/clang/Basic/AttributeCommonInfo.h | 13 + .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 28 +- .../include/clang/Basic/BuiltinsLoongArchBase.def | 5 + .../include/clang/Basic/BuiltinsLoongArchLASX.def | 6 + .../include/clang/Basic/BuiltinsLoongArchLSX.def | 6 + .../clang/include/clang/Basic/BuiltinsPPC.def | 4 + .../clang/include/clang/Basic/CodeGenOptions.def | 15 +- .../clang/include/clang/Basic/CodeGenOptions.h | 3 + .../include/clang/Basic/DiagnosticCommonKinds.td | 8 +- .../include/clang/Basic/DiagnosticDriverKinds.td | 15 +- .../include/clang/Basic/DiagnosticParseKinds.td | 12 + .../include/clang/Basic/DiagnosticSemaKinds.td | 41 +- .../clang/Basic/DiagnosticSerializationKinds.td | 6 +- .../clang/include/clang/Basic/Features.def | 4 + .../clang/include/clang/Basic/LangOptions.def | 28 +- .../clang/include/clang/Basic/LangOptions.h | 44 +- .../clang/include/clang/Basic/ObjCRuntime.h | 15 +- .../clang/include/clang/Basic/OpenACCKinds.h | 294 +- .../clang/include/clang/Basic/TargetBuiltins.h | 4 +- .../clang/include/clang/Basic/TokenKinds.def | 5 +- .../clang/include/clang/Basic/TokenKinds.h | 4 +- .../clang/include/clang/Basic/arm_sme.td | 572 +- .../clang/include/clang/Basic/arm_sve.td | 222 +- .../clang/include/clang/Basic/arm_sve_sme_incl.td | 72 +- .../clang/include/clang/Basic/riscv_vector.td | 44 +- .../clang/include/clang/Driver/Options.td | 69 +- .../clang/include/clang/Driver/Types.def | 6 +- .../clang/include/clang/ExtractAPI/API.h | 289 +- .../include/clang/ExtractAPI/AvailabilityInfo.h | 55 +- .../clang/ExtractAPI/DeclarationFragments.h | 5 +- .../include/clang/ExtractAPI/ExtractAPIVisitor.h | 195 +- .../ExtractAPI/Serialization/SerializerBase.h | 12 +- .../Serialization/SymbolGraphSerializer.h | 4 +- .../clang/include/clang/Format/Format.h | 11 + .../clang/include/clang/Frontend/ASTUnit.h | 2 +- .../clang/include/clang/Frontend/Utils.h | 4 +- .../clang/include/clang/Interpreter/Interpreter.h | 4 +- .../llvm-project/clang/include/clang/Lex/Lexer.h | 2 +- .../clang/include/clang/Lex/Preprocessor.h | 14 +- .../clang/include/clang/Parse/Parser.h | 32 + .../clang/include/clang/Sema/ScopeInfo.h | 6 +- .../llvm-project/clang/include/clang/Sema/Sema.h | 64 +- .../clang/include/clang/Serialization/ASTReader.h | 4 + .../include/clang/Support/RISCVVIntrinsicUtils.h | 2 +- .../clang/lib/ARCMigrate/FileRemapper.cpp | 2 +- .../llvm-project/clang/lib/ARCMigrate/ObjCMT.cpp | 2 +- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 12 +- contrib/llvm-project/clang/lib/AST/ASTImporter.cpp | 39 +- .../clang/lib/AST/ASTStructuralEquivalence.cpp | 62 +- contrib/llvm-project/clang/lib/AST/Decl.cpp | 21 +- contrib/llvm-project/clang/lib/AST/DeclCXX.cpp | 31 +- contrib/llvm-project/clang/lib/AST/DeclPrinter.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Expr.cpp | 9 +- contrib/llvm-project/clang/lib/AST/ExprCXX.cpp | 10 +- .../llvm-project/clang/lib/AST/ExprConstant.cpp | 45 +- .../clang/lib/AST/Interp/ByteCodeEmitter.cpp | 13 +- .../clang/lib/AST/Interp/ByteCodeEmitter.h | 10 +- .../clang/lib/AST/Interp/ByteCodeExprGen.cpp | 96 +- .../clang/lib/AST/Interp/ByteCodeExprGen.h | 6 +- .../clang/lib/AST/Interp/ByteCodeStmtGen.cpp | 68 +- .../llvm-project/clang/lib/AST/Interp/Context.cpp | 106 +- .../llvm-project/clang/lib/AST/Interp/Context.h | 3 + .../clang/lib/AST/Interp/EvalEmitter.cpp | 174 +- .../clang/lib/AST/Interp/EvalEmitter.h | 15 +- .../clang/lib/AST/Interp/EvaluationResult.cpp | 196 + .../clang/lib/AST/Interp/EvaluationResult.h | 111 + .../llvm-project/clang/lib/AST/Interp/IntegralAP.h | 12 +- .../llvm-project/clang/lib/AST/Interp/Interp.cpp | 166 +- contrib/llvm-project/clang/lib/AST/Interp/Interp.h | 37 +- .../llvm-project/clang/lib/AST/Interp/Opcodes.td | 9 +- .../llvm-project/clang/lib/AST/Interp/Pointer.cpp | 154 +- .../llvm-project/clang/lib/AST/Interp/Pointer.h | 3 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 40 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 7 +- contrib/llvm-project/clang/lib/AST/Mangle.cpp | 2 +- .../llvm-project/clang/lib/AST/MicrosoftMangle.cpp | 78 +- .../llvm-project/clang/lib/AST/ODRDiagsEmitter.cpp | 4 +- contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 120 +- .../clang/lib/AST/RecordLayoutBuilder.cpp | 4 +- contrib/llvm-project/clang/lib/AST/StmtPrinter.cpp | 5 +- contrib/llvm-project/clang/lib/AST/StmtProfile.cpp | 6 + .../llvm-project/clang/lib/AST/TemplateBase.cpp | 113 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 2 +- contrib/llvm-project/clang/lib/AST/Type.cpp | 12 +- contrib/llvm-project/clang/lib/AST/TypeLoc.cpp | 1 + contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 39 +- .../llvm-project/clang/lib/AST/VTableBuilder.cpp | 18 +- .../clang/lib/ASTMatchers/ASTMatchersInternal.cpp | 1 + .../clang/lib/ASTMatchers/Dynamic/Registry.cpp | 7 + .../clang/lib/Analysis/ExprMutationAnalyzer.cpp | 17 +- .../Analysis/FlowSensitive/ControlFlowContext.cpp | 2 +- .../FlowSensitive/DataflowAnalysisContext.cpp | 8 +- .../Analysis/FlowSensitive/DataflowEnvironment.cpp | 24 +- .../Analysis/FlowSensitive/SimplifyConstraints.cpp | 4 +- .../clang/lib/Analysis/FlowSensitive/Transfer.cpp | 2 + .../FlowSensitive/TypeErasedDataflowAnalysis.cpp | 92 +- .../clang/lib/Analysis/FlowSensitive/Value.cpp | 14 +- .../clang/lib/Analysis/RetainSummaryManager.cpp | 2 +- .../clang/lib/Analysis/UnsafeBufferUsage.cpp | 5 +- .../clang/lib/Basic/CodeGenOptions.cpp | 2 + .../llvm-project/clang/lib/Basic/FileManager.cpp | 2 +- contrib/llvm-project/clang/lib/Basic/Targets.cpp | 2 + .../clang/lib/Basic/Targets/AArch64.cpp | 27 +- .../llvm-project/clang/lib/Basic/Targets/AMDGPU.h | 17 +- .../llvm-project/clang/lib/Basic/Targets/ARM.cpp | 4 + .../clang/lib/Basic/Targets/OSTargets.h | 6 +- .../llvm-project/clang/lib/Basic/Targets/PPC.cpp | 1 + .../llvm-project/clang/lib/Basic/Targets/RISCV.cpp | 93 +- .../llvm-project/clang/lib/Basic/Targets/RISCV.h | 12 + .../llvm-project/clang/lib/Basic/Targets/SPIR.h | 6 +- .../llvm-project/clang/lib/Basic/Targets/X86.cpp | 11 + contrib/llvm-project/clang/lib/Basic/Warnings.cpp | 3 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 8 +- .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 45 +- .../llvm-project/clang/lib/CodeGen/CGCUDANV.cpp | 2 +- contrib/llvm-project/clang/lib/CodeGen/CGCXX.cpp | 5 + contrib/llvm-project/clang/lib/CodeGen/CGCall.cpp | 28 +- contrib/llvm-project/clang/lib/CodeGen/CGCleanup.h | 1 + .../llvm-project/clang/lib/CodeGen/CGDebugInfo.cpp | 12 +- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 14 + .../llvm-project/clang/lib/CodeGen/CGException.cpp | 4 + contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 12 +- .../llvm-project/clang/lib/CodeGen/CGExprCXX.cpp | 60 +- .../clang/lib/CodeGen/CGExprComplex.cpp | 10 +- .../clang/lib/CodeGen/CGExprScalar.cpp | 18 +- contrib/llvm-project/clang/lib/CodeGen/CGObjC.cpp | 5 + .../llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp | 244 +- .../clang/lib/CodeGen/CGOpenMPRuntime.cpp | 7 + contrib/llvm-project/clang/lib/CodeGen/CGStmt.cpp | 4 +- .../llvm-project/clang/lib/CodeGen/CGVTables.cpp | 2 +- .../clang/lib/CodeGen/CodeGenModule.cpp | 122 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 4 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 437 +- .../llvm-project/clang/lib/CodeGen/TargetInfo.h | 3 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 35 +- .../llvm-project/clang/lib/CodeGen/Targets/X86.cpp | 5 + .../clang/lib/CrossTU/CrossTranslationUnit.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 45 +- .../clang/lib/Driver/SanitizerArgs.cpp | 10 +- .../llvm-project/clang/lib/Driver/ToolChain.cpp | 8 +- .../clang/lib/Driver/ToolChains/AMDGPU.cpp | 33 +- .../clang/lib/Driver/ToolChains/AVR.cpp | 2 +- .../clang/lib/Driver/ToolChains/Arch/AArch64.cpp | 288 +- .../clang/lib/Driver/ToolChains/Arch/ARM.cpp | 5 +- .../clang/lib/Driver/ToolChains/Arch/RISCV.cpp | 4 + .../clang/lib/Driver/ToolChains/CSKYToolChain.cpp | 2 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 129 +- .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 23 +- .../clang/lib/Driver/ToolChains/Cuda.cpp | 2 +- .../clang/lib/Driver/ToolChains/Darwin.cpp | 79 +- .../clang/lib/Driver/ToolChains/Darwin.h | 21 +- .../clang/lib/Driver/ToolChains/Fuchsia.cpp | 4 +- .../clang/lib/Driver/ToolChains/Gnu.cpp | 24 +- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 2 +- .../clang/lib/Driver/ToolChains/Hurd.cpp | 18 +- .../clang/lib/Driver/ToolChains/MSP430.cpp | 2 +- .../clang/lib/Driver/ToolChains/MSVC.cpp | 12 +- .../clang/lib/Driver/ToolChains/MSVC.h | 5 +- .../clang/lib/Driver/ToolChains/MinGW.cpp | 8 +- .../clang/lib/Driver/ToolChains/MinGW.h | 5 +- .../clang/lib/Driver/ToolChains/MipsLinux.cpp | 2 +- .../clang/lib/Driver/ToolChains/OpenBSD.cpp | 4 +- .../clang/lib/Driver/ToolChains/PS4CPU.cpp | 8 +- .../clang/lib/Driver/ToolChains/RISCVToolchain.cpp | 2 +- contrib/llvm-project/clang/lib/Driver/Types.cpp | 7 +- contrib/llvm-project/clang/lib/ExtractAPI/API.cpp | 150 +- .../clang/lib/ExtractAPI/AvailabilityInfo.cpp | 63 +- .../clang/lib/ExtractAPI/DeclarationFragments.cpp | 89 +- .../Serialization/SymbolGraphSerializer.cpp | 74 +- .../clang/lib/Format/ContinuationIndenter.cpp | 34 +- contrib/llvm-project/clang/lib/Format/Format.cpp | 7 +- .../llvm-project/clang/lib/Format/FormatToken.h | 76 + .../clang/lib/Format/FormatTokenLexer.cpp | 84 + .../clang/lib/Format/FormatTokenLexer.h | 7 + .../clang/lib/Format/TokenAnnotator.cpp | 17 +- .../clang/lib/Format/UnwrappedLineFormatter.cpp | 2 +- .../clang/lib/Format/UnwrappedLineParser.cpp | 66 +- .../clang/lib/Format/WhitespaceManager.cpp | 15 +- .../clang/lib/Format/WhitespaceManager.h | 2 +- .../clang/lib/Frontend/CompilerInstance.cpp | 6 +- .../clang/lib/Frontend/CompilerInvocation.cpp | 53 +- .../clang/lib/Frontend/InitPreprocessor.cpp | 24 +- .../clang/lib/Frontend/LogDiagnosticPrinter.cpp | 2 +- .../clang/lib/Frontend/Rewrite/FrontendActions.cpp | 4 +- .../clang/lib/Frontend/TextDiagnosticBuffer.cpp | 8 +- contrib/llvm-project/clang/lib/Headers/arm_acle.h | 70 +- contrib/llvm-project/clang/lib/Headers/bmiintrin.h | 273 +- .../llvm-project/clang/lib/Headers/ia32intrin.h | 444 +- contrib/llvm-project/clang/lib/Headers/immintrin.h | 57 + .../llvm-project/clang/lib/Headers/larchintrin.h | 12 + .../llvm-project/clang/lib/Headers/lasxintrin.h | 24 + .../clang/lib/Headers/llvm_libc_wrappers/string.h | 4 +- contrib/llvm-project/clang/lib/Headers/lsxintrin.h | 24 + .../llvm-project/clang/lib/Index/USRGeneration.cpp | 10 + .../clang/lib/Interpreter/Interpreter.cpp | 34 +- .../llvm-project/clang/lib/Lex/HeaderSearch.cpp | 78 +- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 2 +- .../llvm-project/clang/lib/Lex/Preprocessor.cpp | 5 + .../llvm-project/clang/lib/Lex/UnicodeCharSets.h | 47 +- contrib/llvm-project/clang/lib/Parse/ParseDecl.cpp | 75 +- .../llvm-project/clang/lib/Parse/ParseDeclCXX.cpp | 28 +- contrib/llvm-project/clang/lib/Parse/ParseExpr.cpp | 13 +- .../llvm-project/clang/lib/Parse/ParseExprCXX.cpp | 9 +- contrib/llvm-project/clang/lib/Parse/ParseObjc.cpp | 6 +- .../llvm-project/clang/lib/Parse/ParseOpenACC.cpp | 523 +- .../clang/lib/Parse/ParseTentative.cpp | 3 +- contrib/llvm-project/clang/lib/Parse/Parser.cpp | 5 + .../clang/lib/Sema/AnalysisBasedWarnings.cpp | 17 +- contrib/llvm-project/clang/lib/Sema/Sema.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 133 +- .../llvm-project/clang/lib/Sema/SemaCoroutine.cpp | 5 + contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 174 +- .../llvm-project/clang/lib/Sema/SemaDeclAttr.cpp | 120 +- .../llvm-project/clang/lib/Sema/SemaDeclCXX.cpp | 41 +- .../llvm-project/clang/lib/Sema/SemaDeclObjC.cpp | 4 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 43 +- .../llvm-project/clang/lib/Sema/SemaExprCXX.cpp | 49 +- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 70 +- contrib/llvm-project/clang/lib/Sema/SemaLambda.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaLookup.cpp | 1 + .../clang/lib/Sema/SemaObjCProperty.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaOpenMP.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 187 +- .../clang/lib/Sema/SemaRISCVVectorLookup.cpp | 5 +- contrib/llvm-project/clang/lib/Sema/SemaStmt.cpp | 6 + .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 265 +- .../clang/lib/Sema/SemaTemplateDeduction.cpp | 64 +- .../clang/lib/Sema/SemaTemplateInstantiate.cpp | 17 +- .../clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 23 +- .../clang/lib/Sema/SemaTemplateVariadic.cpp | 2 + contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 269 +- .../llvm-project/clang/lib/Sema/TreeTransform.h | 24 +- .../clang/lib/Serialization/ASTReader.cpp | 90 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 6 +- .../clang/lib/Serialization/ASTReaderStmt.cpp | 1 + .../clang/lib/Serialization/ASTWriter.cpp | 23 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 2 +- .../clang/lib/Serialization/ASTWriterStmt.cpp | 1 + .../Checkers/CheckSecuritySyntaxOnly.cpp | 2 + .../Checkers/LocalizationChecker.cpp | 6 +- .../Checkers/StdLibraryFunctionsChecker.cpp | 91 +- .../lib/StaticAnalyzer/Checkers/StreamChecker.cpp | 183 + .../StaticAnalyzer/Checkers/VirtualCallChecker.cpp | 2 +- .../lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp | 14 +- .../clang/lib/Tooling/ASTDiff/ASTDiff.cpp | 4 +- .../clang/lib/Tooling/CompilationDatabase.cpp | 6 +- .../DependencyScanningWorker.cpp | 2 +- .../clang/lib/Tooling/Syntax/Tokens.cpp | 6 + contrib/llvm-project/clang/lib/Tooling/Tooling.cpp | 2 +- .../clang/tools/clang-format/ClangFormat.cpp | 24 +- contrib/llvm-project/clang/tools/driver/driver.cpp | 4 +- .../clang/utils/TableGen/ClangAttrEmitter.cpp | 63 +- ...ngCommentHTMLNamedCharacterReferenceEmitter.cpp | 2 +- .../utils/TableGen/ClangDiagnosticsEmitter.cpp | 2 +- .../clang/utils/TableGen/MveEmitter.cpp | 2 +- .../clang/utils/TableGen/RISCVVEmitter.cpp | 2 +- .../clang/utils/TableGen/SveEmitter.cpp | 56 +- .../llvm-project/clang/utils/TableGen/TableGen.cpp | 21 +- .../clang/utils/TableGen/TableGenBackends.h | 4 +- .../include/profile/instr_prof_interface.h | 92 + .../llvm-project/compiler-rt/lib/asan/asan_win.cpp | 7 +- .../lib/builtins/aarch64/sme-libc-routines.c | 87 + .../compiler-rt/lib/builtins/cpu_model/aarch64.c | 1 + .../lib/builtins/cpu_model/aarch64/fmv/apple.inc | 30 +- .../lib/builtins/cpu_model/aarch64/fmv/mrs.inc | 2 + .../lib/builtins/cpu_model/aarch64/hwcap.inc | 3 + .../compiler-rt/lib/builtins/cpu_model/x86.c | 5 +- .../compiler-rt/lib/builtins/fp_extend_impl.inc | 2 +- .../compiler-rt/lib/builtins/int_lib.h | 10 +- .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 8 +- .../compiler-rt/lib/hwasan/hwasan_report.cpp | 2 +- .../compiler-rt/lib/interception/interception.h | 5 +- .../lib/interception/interception_win.cpp | 33 +- .../compiler-rt/lib/orc/coff_platform.cpp | 8 +- .../compiler-rt/lib/orc/wrapper_function_utils.h | 6 +- .../compiler-rt/lib/profile/InstrProfiling.h | 61 +- .../compiler-rt/lib/profile/InstrProfilingFile.c | 14 +- .../compiler-rt/lib/profile/InstrProfilingMerge.c | 5 + .../compiler-rt/lib/profile/InstrProfilingValue.c | 5 + .../compiler-rt/lib/profile/WindowsMMap.c | 3 +- .../compiler-rt/lib/profile/WindowsMMap.h | 6 + .../lib/sanitizer_common/sanitizer_asm.h | 23 + .../sanitizer_common_interceptors.inc | 8 +- .../lib/sanitizer_common/sanitizer_fuchsia.cpp | 87 +- .../lib/sanitizer_common/sanitizer_internal_defs.h | 9 +- .../sanitizer_symbolizer_report.cpp | 3 +- .../symbolizer/scripts/build_symbolizer.sh | 1 + .../compiler-rt/lib/tsan/rtl/tsan_dispatch_defs.h | 7 - .../compiler-rt/lib/tsan/rtl/tsan_platform.h | 2 +- .../lib/tsan/rtl/tsan_platform_linux.cpp | 140 +- .../compiler-rt/lib/tsan/rtl/tsan_platform_mac.cpp | 5 +- .../lib/tsan/rtl/tsan_platform_posix.cpp | 43 +- .../libcxx/include/__algorithm/clamp.h | 2 +- .../libcxx/include/__algorithm/comp_ref_type.h | 5 +- .../libcxx/include/__algorithm/nth_element.h | 8 +- .../libcxx/include/__algorithm/ranges_clamp.h | 5 +- .../llvm-project/libcxx/include/__algorithm/sort.h | 22 +- .../include/__algorithm/three_way_comp_ref_type.h | 6 +- contrib/llvm-project/libcxx/include/__assert | 6 +- .../libcxx/include/__atomic/is_always_lock_free.h | 2 +- contrib/llvm-project/libcxx/include/__availability | 29 +- .../llvm-project/libcxx/include/__bit/bit_ceil.h | 2 +- .../llvm-project/libcxx/include/__chrono/ostream.h | 9 +- .../libcxx/include/__concepts/arithmetic.h | 4 + contrib/llvm-project/libcxx/include/__config | 71 +- .../libcxx/include/__coroutine/coroutine_handle.h | 16 +- .../__debug_utils/strict_weak_ordering_check.h | 14 +- .../libcxx/include/__exception/exception_ptr.h | 50 + .../libcxx/include/__expected/expected.h | 1142 +- contrib/llvm-project/libcxx/include/__hash_table | 2 +- .../libcxx/include/__iterator/iterator_traits.h | 2 +- .../libcxx/include/__memory/allocator.h | 14 +- .../libcxx/include/__memory/assume_aligned.h | 4 +- .../__memory_resource/polymorphic_allocator.h | 5 +- .../libcxx/include/__numeric/gcd_lcm.h | 2 +- .../include/__numeric/saturation_arithmetic.h | 110 + .../libcxx/include/__ranges/chunk_by_view.h | 3 +- .../libcxx/include/__ranges/drop_while_view.h | 3 +- .../libcxx/include/__ranges/filter_view.h | 2 +- .../libcxx/include/__ranges/repeat_view.h | 2 +- .../libcxx/include/__ranges/single_view.h | 2 +- .../libcxx/include/__ranges/take_while_view.h | 3 +- .../libcxx/include/__ranges/transform_view.h | 3 +- .../llvm-project/libcxx/include/__utility/cmp.h | 43 +- contrib/llvm-project/libcxx/include/any | 3 + contrib/llvm-project/libcxx/include/barrier | 23 +- contrib/llvm-project/libcxx/include/chrono | 4 + contrib/llvm-project/libcxx/include/concepts | 2 +- .../llvm-project/libcxx/include/condition_variable | 93 +- .../include/experimental/__simd/aligned_tag.h | 3 +- .../libcxx/include/experimental/__simd/scalar.h | 7 + .../libcxx/include/experimental/__simd/simd.h | 6 + .../libcxx/include/experimental/__simd/simd_mask.h | 6 + .../libcxx/include/experimental/__simd/vec_ext.h | 11 + contrib/llvm-project/libcxx/include/future | 11 +- contrib/llvm-project/libcxx/include/latch | 21 +- contrib/llvm-project/libcxx/include/libcxx.imp | 888 +- contrib/llvm-project/libcxx/include/locale | 12 +- contrib/llvm-project/libcxx/include/memory | 2 +- .../libcxx/include/module.modulemap.in | 1 + contrib/llvm-project/libcxx/include/new | 1 - contrib/llvm-project/libcxx/include/numeric | 13 + contrib/llvm-project/libcxx/include/ostream | 21 +- contrib/llvm-project/libcxx/include/print | 18 +- contrib/llvm-project/libcxx/include/regex | 11 +- contrib/llvm-project/libcxx/include/semaphore | 19 +- contrib/llvm-project/libcxx/include/shared_mutex | 11 +- contrib/llvm-project/libcxx/include/span | 16 + contrib/llvm-project/libcxx/include/sstream | 2 +- contrib/llvm-project/libcxx/include/stop_token | 11 +- contrib/llvm-project/libcxx/include/string | 5 +- contrib/llvm-project/libcxx/include/string_view | 7 +- contrib/llvm-project/libcxx/include/thread | 11 +- contrib/llvm-project/libcxx/include/typeinfo | 1 - contrib/llvm-project/libcxx/include/variant | 53 +- contrib/llvm-project/libcxx/include/vector | 14 +- contrib/llvm-project/libcxx/include/version | 4 +- .../llvm-project/libcxx/modules/modules.json.in | 26 + .../llvm-project/libcxx/modules/std.compat.cppm.in | 125 +- .../libcxx/modules/std.compat/cstdlib.inc | 4 +- .../libcxx/modules/std.compat/ctime.inc | 2 +- contrib/llvm-project/libcxx/modules/std.cppm.in | 1 + contrib/llvm-project/libcxx/modules/std/ctime.inc | 2 +- contrib/llvm-project/libcxx/modules/std/memory.inc | 2 + .../llvm-project/libcxx/modules/std/numeric.inc | 10 + .../libcxx/src/filesystem/operations.cpp | 26 +- .../libcxx/src/include/overridable_function.h | 119 + .../libcxx/src/include/to_chars_floating_point.h | 2 +- .../llvm-project/libcxx/src/memory_resource.cpp | 3 +- contrib/llvm-project/libcxx/src/mutex.cpp | 8 +- contrib/llvm-project/libcxx/src/new.cpp | 107 +- contrib/llvm-project/libcxx/src/ostream.cpp | 2 +- .../support/runtime/exception_pointer_cxxabi.ipp | 8 + .../support/runtime/exception_pointer_glibcxx.ipp | 8 + .../runtime/exception_pointer_unimplemented.ipp | 6 + .../vendor/llvm/default_assertion_handler.in | 31 + .../llvm-project/libunwind/src/UnwindCursor.hpp | 4 +- contrib/llvm-project/libunwind/src/libunwind.cpp | 6 +- contrib/llvm-project/lld/COFF/Driver.cpp | 12 +- contrib/llvm-project/lld/COFF/DriverUtils.cpp | 8 +- contrib/llvm-project/lld/COFF/InputFiles.cpp | 4 +- contrib/llvm-project/lld/COFF/Writer.cpp | 2 + contrib/llvm-project/lld/Common/Args.cpp | 15 +- .../llvm-project/lld/Common/DriverDispatcher.cpp | 1 - contrib/llvm-project/lld/ELF/Arch/ARM.cpp | 6 +- contrib/llvm-project/lld/ELF/Arch/Mips.cpp | 7 +- contrib/llvm-project/lld/ELF/Arch/PPC64.cpp | 2 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 10 +- contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 8 +- contrib/llvm-project/lld/ELF/Config.h | 2 + contrib/llvm-project/lld/ELF/Driver.cpp | 200 +- contrib/llvm-project/lld/ELF/DriverUtils.cpp | 2 +- contrib/llvm-project/lld/ELF/InputFiles.cpp | 10 +- contrib/llvm-project/lld/ELF/InputFiles.h | 11 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 4 +- contrib/llvm-project/lld/ELF/InputSection.h | 3 +- contrib/llvm-project/lld/ELF/LTO.cpp | 84 +- contrib/llvm-project/lld/ELF/LTO.h | 4 +- contrib/llvm-project/lld/ELF/LinkerScript.cpp | 8 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 17 +- contrib/llvm-project/lld/ELF/ScriptLexer.h | 4 +- contrib/llvm-project/lld/ELF/ScriptParser.cpp | 3 +- contrib/llvm-project/lld/ELF/Symbols.cpp | 6 +- contrib/llvm-project/lld/ELF/Symbols.h | 32 +- contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 4 +- contrib/llvm-project/lld/ELF/Target.cpp | 2 +- contrib/llvm-project/lld/ELF/Writer.cpp | 38 +- contrib/llvm-project/lld/MachO/Arch/ARM64.cpp | 51 +- contrib/llvm-project/lld/MachO/Arch/ARM64Common.h | 37 +- contrib/llvm-project/lld/MachO/Arch/ARM64_32.cpp | 11 +- contrib/llvm-project/lld/MachO/Arch/X86_64.cpp | 20 +- contrib/llvm-project/lld/MachO/Driver.cpp | 17 +- contrib/llvm-project/lld/MachO/DriverUtils.cpp | 2 +- .../llvm-project/lld/MachO/SyntheticSections.cpp | 42 +- contrib/llvm-project/lld/MachO/SyntheticSections.h | 2 +- contrib/llvm-project/lld/MachO/Target.h | 9 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 4 + contrib/llvm-project/lld/tools/lld/lld.cpp | 2 - contrib/llvm-project/lldb/include/lldb/API/LLDB.h | 1 + .../lldb/include/lldb/Breakpoint/Breakpoint.h | 2 +- .../include/lldb/Breakpoint/BreakpointIDList.h | 17 +- .../lldb/include/lldb/Breakpoint/Watchpoint.h | 2 - .../llvm-project/lldb/include/lldb/Core/Address.h | 10 +- .../lldb/include/lldb/Core/DebuggerEvents.h | 7 +- .../llvm-project/lldb/include/lldb/Core/Progress.h | 16 +- .../lldb/include/lldb/Core/ValueObject.h | 3 +- .../lldb/include/lldb/Host/Config.h.cmake | 2 + .../lldb/include/lldb/Symbol/CompileUnit.h | 16 +- .../lldb/include/lldb/Symbol/LineEntry.h | 10 +- .../llvm-project/lldb/include/lldb/Symbol/Symbol.h | 6 +- .../lldb/include/lldb/Symbol/SymbolContext.h | 16 +- .../lldb/include/lldb/Target/Platform.h | 26 + .../lldb/include/lldb/Utility/Broadcaster.h | 6 +- .../lldb/include/lldb/Utility/FileSpec.h | 24 +- .../lldb/include/lldb/Utility/FileSpecList.h | 33 +- .../lldb/include/lldb/Utility/Stream.h | 18 +- .../lldb/include/lldb/Utility/SupportFile.h | 55 + .../lldb/include/lldb/Utility/XcodeSDK.h | 2 + .../lldb/include/lldb/lldb-enumerations.h | 1 + .../llvm-project/lldb/include/lldb/lldb-forward.h | 2 + .../llvm-project/lldb/source/API/SBTypeFilter.cpp | 2 +- .../llvm-project/lldb/source/API/SBTypeFormat.cpp | 2 +- .../llvm-project/lldb/source/API/SBTypeSummary.cpp | 2 +- .../lldb/source/API/SBTypeSynthetic.cpp | 2 +- .../lldb/source/Breakpoint/Breakpoint.cpp | 53 +- .../lldb/source/Breakpoint/BreakpointIDList.cpp | 66 +- .../lldb/source/Breakpoint/BreakpointList.cpp | 7 +- .../lldb/source/Breakpoint/BreakpointLocation.cpp | 6 +- .../lldb/source/Breakpoint/BreakpointResolver.cpp | 3 +- .../lldb/source/Breakpoint/Watchpoint.cpp | 22 +- .../lldb/source/Breakpoint/WatchpointList.cpp | 23 +- .../source/Commands/CommandObjectBreakpoint.cpp | 54 +- .../lldb/source/Commands/CommandObjectFrame.cpp | 1 + .../lldb/source/Commands/CommandObjectSource.cpp | 4 +- .../lldb/source/Commands/CommandObjectTarget.cpp | 38 +- contrib/llvm-project/lldb/source/Core/Address.cpp | 26 +- .../llvm-project/lldb/source/Core/Disassembler.cpp | 5 +- .../llvm-project/lldb/source/Core/FormatEntity.cpp | 38 +- contrib/llvm-project/lldb/source/Core/Module.cpp | 16 +- .../llvm-project/lldb/source/Core/ModuleList.cpp | 28 +- contrib/llvm-project/lldb/source/Core/Progress.cpp | 30 +- .../llvm-project/lldb/source/Core/ValueObject.cpp | 343 +- .../lldb/source/Expression/DiagnosticManager.cpp | 15 +- .../Instruction/ARM/EmulateInstructionARM.cpp | 1 + .../Language/CPlusPlus/CPlusPlusLanguage.cpp | 84 +- .../source/Plugins/Language/CPlusPlus/LibCxx.cpp | 94 +- .../source/Plugins/Language/CPlusPlus/LibCxx.h | 12 + .../ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp | 6 +- .../Plugins/ObjectFile/ELF/ObjectFileELF.cpp | 5 +- .../Utility/RegisterContextPOSIX_mips64.cpp | 23 +- .../gdb-remote/GDBRemoteCommunicationClient.cpp | 3 +- .../Process/gdb-remote/ProcessGDBRemote.cpp | 79 +- .../SymbolFile/Breakpad/SymbolFileBreakpad.cpp | 9 +- .../Plugins/SymbolFile/CTF/SymbolFileCTF.cpp | 1 + .../Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp | 6 + .../Plugins/SymbolFile/DWARF/DWARFDebugInfo.h | 5 + .../Plugins/SymbolFile/DWARF/DWARFFormValue.cpp | 24 +- .../Plugins/SymbolFile/DWARF/DWARFFormValue.h | 6 + .../source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp | 24 + .../source/Plugins/SymbolFile/DWARF/DWARFUnit.h | 5 + .../Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp | 5 +- .../Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp | 16 +- .../SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp | 11 +- .../SymbolFile/NativePDB/SymbolFileNativePDB.cpp | 6 +- .../Debuginfod/SymbolLocatorDebuginfod.cpp | 83 +- .../SymbolLocatorDebuginfodProperties.td | 8 +- .../SymbolLocator/Default/SymbolLocatorDefault.cpp | 6 +- .../Plugins/TypeSystem/Clang/TypeSystemClang.cpp | 5 +- .../lldb/source/Symbol/CompileUnit.cpp | 11 +- .../llvm-project/lldb/source/Symbol/LineEntry.cpp | 23 +- .../llvm-project/lldb/source/Symbol/LineTable.cpp | 12 +- contrib/llvm-project/lldb/source/Symbol/Symbol.cpp | 17 +- .../lldb/source/Symbol/SymbolContext.cpp | 46 +- .../llvm-project/lldb/source/Target/Process.cpp | 10 +- contrib/llvm-project/lldb/source/Target/Target.cpp | 15 +- .../lldb/source/Target/TargetProperties.td | 2 +- contrib/llvm-project/lldb/source/Target/Thread.cpp | 15 +- .../llvm-project/lldb/source/Target/ThreadList.cpp | 10 +- .../lldb/source/Target/ThreadPlanStepOverRange.cpp | 12 +- .../lldb/source/Target/ThreadPlanStepRange.cpp | 4 +- .../lldb/source/Utility/Broadcaster.cpp | 5 +- .../llvm-project/lldb/source/Utility/FileSpec.cpp | 9 +- .../lldb/source/Utility/FileSpecList.cpp | 9 +- .../llvm-project/lldb/source/Utility/Stream.cpp | 17 +- .../llvm-project/lldb/source/Utility/XcodeSDK.cpp | 23 + contrib/llvm-project/lldb/tools/driver/Driver.cpp | 3 + .../lldb/tools/lldb-server/lldb-server.cpp | 4 +- .../llvm/include/llvm/ADT/APFixedPoint.h | 2 +- .../llvm/include/llvm/ADT/FunctionExtras.h | 7 +- .../llvm-project/llvm/include/llvm/ADT/Hashing.h | 4 +- .../llvm-project/llvm/include/llvm/ADT/SetVector.h | 2 +- .../llvm/include/llvm/ADT/SmallVector.h | 19 +- .../llvm/include/llvm/ADT/StringExtras.h | 2 +- .../llvm/include/llvm/Analysis/AliasAnalysis.h | 2 + .../llvm/include/llvm/Analysis/AliasSetTracker.h | 244 +- .../include/llvm/Analysis/BlockFrequencyInfoImpl.h | 5 +- .../include/llvm/Analysis/DOTGraphTraitsPass.h | 28 +- .../llvm/include/llvm/Analysis/RegionInfoImpl.h | 33 +- .../include/llvm/Analysis/TargetTransformInfo.h | 10 + .../llvm/Analysis/TargetTransformInfoImpl.h | 9 + .../llvm/include/llvm/Analysis/VecFuncs.def | 146 + .../llvm/include/llvm/Analysis/VectorUtils.h | 187 +- .../llvm/include/llvm/AsmParser/LLParser.h | 33 +- .../llvm/include/llvm/BinaryFormat/ELF.h | 2 + .../include/llvm/BinaryFormat/ELFRelocs/RISCV.def | 5 + .../llvm/include/llvm/BinaryFormat/MachO.def | 2 + .../llvm/include/llvm/BinaryFormat/Magic.h | 1 + .../llvm/include/llvm/BinaryFormat/Wasm.h | 396 +- .../llvm/include/llvm/BinaryFormat/WasmTraits.h | 5 +- .../llvm/include/llvm/Bitcode/BitcodeWriterPass.h | 10 +- .../llvm/include/llvm/CodeGen/AccelTable.h | 53 +- .../llvm/include/llvm/CodeGen/AsmPrinter.h | 4 - .../llvm/include/llvm/CodeGen/CodeGenPassBuilder.h | 210 +- .../llvm/include/llvm/CodeGen/CommandFlags.h | 3 + .../include/llvm/CodeGen/GlobalISel/CallLowering.h | 4 +- .../llvm/CodeGen/GlobalISel/GenericMachineInstrs.h | 19 +- .../include/llvm/CodeGen/GlobalISel/IRTranslator.h | 37 +- .../llvm/CodeGen/GlobalISel/LegalizerHelper.h | 16 - .../llvm/include/llvm/CodeGen/GlobalISel/Utils.h | 19 + .../llvm/include/llvm/CodeGen/GlobalMerge.h | 50 + .../llvm/include/llvm/CodeGen/MachineBasicBlock.h | 4 +- .../llvm/include/llvm/CodeGen/MachineOperand.h | 4 + .../llvm/include/llvm/CodeGen/MachineOutliner.h | 11 +- .../include/llvm/CodeGen/MachinePassRegistry.def | 3 +- .../llvm/include/llvm/CodeGen/MachinePipeliner.h | 18 +- .../llvm/include/llvm/CodeGen/MachineScheduler.h | 10 +- .../llvm/include/llvm/CodeGen/SelectionDAGISel.h | 8 + .../llvm/include/llvm/CodeGen/StackMaps.h | 21 +- .../llvm/include/llvm/CodeGen/TargetLowering.h | 28 +- .../llvm/include/llvm/CodeGen/TargetPassConfig.h | 24 +- .../include/llvm/CodeGen/TargetSubtargetInfo.h | 4 + .../llvm/include/llvm/DWARFLinker/AddressesMap.h | 24 +- .../include/llvm/DWARFLinker/Classic/DWARFLinker.h | 45 +- .../llvm/DWARFLinker/Classic/DWARFStreamer.h | 18 +- .../include/llvm/DWARFLinker/DWARFLinkerBase.h | 47 + .../llvm/DWARFLinker}/IndexedValuesMap.h | 11 +- .../llvm/DWARFLinker/Parallel/DWARFLinker.h | 59 +- .../llvm/include/llvm/DebugInfo/DIContext.h | 1 + .../include/llvm/DebugInfo/DWARF/DWARFContext.h | 8 +- .../llvm/include/llvm/Debuginfod/Debuginfod.h | 14 + .../include/llvm/ExecutionEngine/JITLink/aarch32.h | 162 +- .../llvm/ExecutionEngine/Orc/MachOBuilder.h | 83 +- .../llvm/ExecutionEngine/Orc/MachOPlatform.h | 46 +- .../llvm/ExecutionEngine/RuntimeDyldChecker.h | 2 +- .../llvm/Frontend/Offloading/OffloadWrapper.h | 52 + .../include/llvm/Frontend/Offloading/Utility.h | 6 + .../llvm-project/llvm/include/llvm/IR/Attributes.h | 2 +- .../llvm/include/llvm/IR/CallingConv.h | 10 + .../llvm-project/llvm/include/llvm/IR/DebugInfo.h | 26 +- .../llvm/include/llvm/IR/DebugInfoMetadata.h | 4 + .../llvm/include/llvm/IR/DebugProgramInstruction.h | 109 +- .../llvm-project/llvm/include/llvm/IR/Function.h | 3 +- .../llvm/include/llvm/IR/GlobalObject.h | 1 + .../llvm/include/llvm/IR/GlobalValue.h | 3 +- .../llvm-project/llvm/include/llvm/IR/IRBuilder.h | 10 + .../llvm/include/llvm/IR/Instruction.h | 3 + .../llvm/include/llvm/IR/Intrinsics.td | 10 + .../llvm/include/llvm/IR/IntrinsicsAArch64.td | 36 +- .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 335 +- .../llvm/include/llvm/IR/IntrinsicsLoongArch.td | 13 + .../llvm/include/llvm/IR/IntrinsicsNVVM.td | 85 +- .../llvm/include/llvm/IR/IntrinsicsPowerPC.td | 5 + .../llvm/include/llvm/IR/IntrinsicsRISCV.td | 29 +- .../llvm-project/llvm/include/llvm/IR/Metadata.h | 87 +- .../llvm/include/llvm/IR/ModuleSummaryIndex.h | 2 +- .../llvm/include/llvm/IR/ProfileSummary.h | 8 +- .../llvm/include/llvm/IR/VFABIDemangler.h | 217 + .../llvm/include/llvm/IR/VPIntrinsics.def | 18 +- contrib/llvm-project/llvm/include/llvm/IR/Value.h | 15 +- .../llvm/include/llvm/MC/MCObjectWriter.h | 3 + .../llvm-project/llvm/include/llvm/MC/MCSymbol.h | 2 +- .../llvm/include/llvm/MC/MCSymbolWasm.h | 4 +- .../llvm/include/llvm/Object/COFFImportFile.h | 2 + .../llvm/include/llvm/Object/ELFObjectFile.h | 11 +- .../llvm-project/llvm/include/llvm/Object/MachO.h | 2 +- .../llvm/include/llvm/Object/OffloadBinary.h | 25 + .../llvm/include/llvm/Passes/PassBuilder.h | 132 +- .../llvm/ProfileData/Coverage/CoverageMapping.h | 18 +- .../llvm/include/llvm/ProfileData/SampleProf.h | 2 + .../llvm/include/llvm/Support/AMDGPUMetadata.h | 10 +- .../llvm/include/llvm/Support/FormatCommon.h | 4 +- .../llvm/include/llvm/Support/GenericDomTree.h | 7 +- .../llvm/include/llvm/Support/GenericLoopInfo.h | 18 +- .../include/llvm/Support/GenericLoopInfoImpl.h | 29 +- .../llvm-project/llvm/include/llvm/Support/JSON.h | 15 +- .../llvm/include/llvm/Support/MathExtras.h | 4 +- .../llvm/include/llvm/Support/RISCVAttributes.h | 2 +- .../llvm/include/llvm/Support/TargetOpcodes.def | 11 +- .../include/llvm/TableGen/StringToOffsetTable.h | 2 +- .../llvm/include/llvm/Target/CGPassBuilderOption.h | 2 +- .../llvm/include/llvm/Target/Target.td | 92 +- .../llvm/include/llvm/Target/TargetMachine.h | 3 + .../llvm/include/llvm/Target/TargetOptions.h | 17 +- .../llvm/include/llvm/Target/TargetPfmCounters.td | 7 + .../llvm/include/llvm/Target/TargetSchedule.td | 37 +- .../llvm/TargetParser/AArch64TargetParser.h | 135 +- .../include/llvm/TargetParser/ARMTargetParser.def | 5 + .../llvm/include/llvm/TargetParser/Triple.h | 25 +- .../include/llvm/TargetParser/X86TargetParser.def | 5 +- .../include/llvm/Transforms/IPO/EmbedBitcodePass.h | 16 +- .../llvm/Transforms/Instrumentation/CGProfile.h | 4 + .../llvm/Transforms/Scalar/ConstantHoisting.h | 1 + .../include/llvm/Transforms/Utils/ModuleUtils.h | 6 - .../llvm/Transforms/Utils/NameAnonGlobals.h | 2 + .../llvm/lib/Analysis/AliasAnalysis.cpp | 5 + .../llvm/lib/Analysis/AliasSetTracker.cpp | 338 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 25 +- .../llvm-project/llvm/lib/Analysis/InlineOrder.cpp | 2 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 23 +- .../llvm/lib/Analysis/ScalarEvolution.cpp | 4 + .../llvm/lib/Analysis/StackSafetyAnalysis.cpp | 2 +- .../llvm/lib/Analysis/TargetLibraryInfo.cpp | 9 +- .../llvm/lib/Analysis/TargetTransformInfo.cpp | 5 + .../llvm/lib/Analysis/ValueTracking.cpp | 24 +- .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 93 +- .../llvm-project/llvm/lib/AsmParser/LLParser.cpp | 235 +- .../llvm-project/llvm/lib/BinaryFormat/Magic.cpp | 2 + .../llvm/lib/Bitcode/Reader/MetadataLoader.cpp | 37 +- .../llvm/lib/Bitcode/Writer/BitcodeWriterPass.cpp | 24 +- .../llvm/lib/Bitcode/Writer/ValueEnumerator.cpp | 4 +- .../llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp | 127 +- .../llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 84 +- .../llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp | 12 +- .../lib/CodeGen/AssignmentTrackingAnalysis.cpp | 802 +- .../llvm/lib/CodeGen/BasicBlockSections.cpp | 10 +- .../CodeGen/BasicBlockSectionsProfileReader.cpp | 7 - .../llvm/lib/CodeGen/BranchFolding.cpp | 2 +- .../llvm/lib/CodeGen/CodeGenPrepare.cpp | 23 +- .../llvm-project/llvm/lib/CodeGen/CommandFlags.cpp | 8 + .../llvm/lib/CodeGen/ExpandVectorPredication.cpp | 2 + .../llvm/lib/CodeGen/GlobalISel/CallLowering.cpp | 42 +- .../llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp | 30 +- .../llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp | 214 +- .../lib/CodeGen/GlobalISel/InstructionSelect.cpp | 11 + .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 168 +- .../llvm/lib/CodeGen/GlobalISel/Utils.cpp | 147 + .../llvm-project/llvm/lib/CodeGen/GlobalMerge.cpp | 167 +- .../CodeGen/LiveDebugValues/InstrRefBasedImpl.h | 4 +- .../llvm/lib/CodeGen/MachineCopyPropagation.cpp | 2 +- .../llvm/lib/CodeGen/MachineOperand.cpp | 13 + .../llvm/lib/CodeGen/MachineOutliner.cpp | 27 +- .../llvm/lib/CodeGen/MachinePipeliner.cpp | 482 +- .../llvm/lib/CodeGen/MachineScheduler.cpp | 37 +- .../llvm/lib/CodeGen/PatchableFunction.cpp | 52 +- .../llvm/lib/CodeGen/PreISelIntrinsicLowering.cpp | 5 +- contrib/llvm-project/llvm/lib/CodeGen/RDFGraph.cpp | 2 +- .../llvm/lib/CodeGen/ReplaceWithVeclib.cpp | 31 +- .../llvm-project/llvm/lib/CodeGen/SafeStack.cpp | 22 +- .../llvm/lib/CodeGen/SelectOptimize.cpp | 408 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 10 + .../llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 5 +- .../llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 3 +- .../CodeGen/SelectionDAG/LegalizeFloatTypes.cpp | 9 +- .../CodeGen/SelectionDAG/LegalizeVectorTypes.cpp | 4 + .../llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 24 +- .../CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 87 +- .../lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h | 4 +- .../lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 30 +- .../lib/CodeGen/SelectionDAG/TargetLowering.cpp | 8 +- .../llvm-project/llvm/lib/CodeGen/SlotIndexes.cpp | 2 +- .../llvm-project/llvm/lib/CodeGen/StackMaps.cpp | 42 +- .../llvm/lib/CodeGen/TargetLoweringBase.cpp | 4 +- .../llvm/lib/CodeGen/TargetPassConfig.cpp | 116 +- .../llvm/lib/CodeGen/TwoAddressInstructionPass.cpp | 13 +- .../llvm/lib/CodeGen/UnreachableBlockElim.cpp | 2 +- .../llvm/lib/DWARFLinker/Classic/DWARFLinker.cpp | 66 +- .../llvm/lib/DWARFLinker/Classic/DWARFStreamer.cpp | 90 +- .../llvm/lib/DWARFLinker/DWARFLinkerBase.cpp | 64 + .../lib/DWARFLinker/Parallel/DWARFEmitterImpl.cpp | 66 - .../lib/DWARFLinker/Parallel/DWARFEmitterImpl.h | 23 +- .../Parallel/DWARFLinkerCompileUnit.cpp | 20 +- .../DWARFLinker/Parallel/DWARFLinkerCompileUnit.h | 7 +- .../DWARFLinker/Parallel/DWARFLinkerGlobalData.h | 29 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.cpp | 98 +- .../lib/DWARFLinker/Parallel/DWARFLinkerImpl.h | 23 +- .../DWARFLinker/Parallel/DWARFLinkerTypeUnit.cpp | 12 +- .../lib/DWARFLinker/Parallel/DWARFLinkerTypeUnit.h | 2 +- .../lib/DWARFLinker/Parallel/DWARFLinkerUnit.h | 2 +- .../lib/DWARFLinker/Parallel/DependencyTracker.cpp | 4 +- .../lib/DWARFLinker/Parallel/OutputSections.cpp | 53 - .../llvm/lib/DWARFLinker/Parallel/OutputSections.h | 124 +- .../llvm/lib/DebugInfo/DWARF/DWARFCompileUnit.cpp | 10 +- .../llvm/lib/DebugInfo/DWARF/DWARFContext.cpp | 45 +- .../llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp | 2 +- .../llvm/lib/DebugInfo/DWARF/DWARFTypePrinter.cpp | 3 +- .../llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | 16 +- .../LogicalView/Readers/LVCodeViewReader.cpp | 4 +- .../llvm/lib/DebugInfo/Symbolize/MarkupFilter.cpp | 9 +- .../DebugInfo/Symbolize/SymbolizableObjectFile.cpp | 4 +- .../llvm/lib/DebugInfo/Symbolize/Symbolize.cpp | 8 +- .../llvm/lib/Debuginfod/Debuginfod.cpp | 36 +- .../llvm/lib/ExecutionEngine/ExecutionEngine.cpp | 4 +- .../ExecutionEngine/JITLink/ELFLinkGraphBuilder.h | 6 + .../lib/ExecutionEngine/JITLink/ELF_aarch32.cpp | 66 +- .../llvm/lib/ExecutionEngine/JITLink/aarch32.cpp | 286 +- .../llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | 6 + .../llvm/lib/ExecutionEngine/Orc/MachOPlatform.cpp | 60 +- .../Orc/TargetProcess/JITLoaderPerf.cpp | 2 +- .../RuntimeDyld/RuntimeDyldChecker.cpp | 27 +- .../RuntimeDyld/RuntimeDyldCheckerImpl.h | 3 +- .../llvm-project/llvm/lib/FileCheck/FileCheck.cpp | 61 +- .../llvm/lib/FileCheck/FileCheckImpl.h | 20 +- .../lib/Frontend/Offloading/OffloadWrapper.cpp | 620 + .../llvm/lib/Frontend/Offloading/Utility.cpp | 21 +- .../llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp | 7 +- contrib/llvm-project/llvm/lib/IR/AsmWriter.cpp | 28 +- contrib/llvm-project/llvm/lib/IR/AutoUpgrade.cpp | 305 +- contrib/llvm-project/llvm/lib/IR/BasicBlock.cpp | 19 +- contrib/llvm-project/llvm/lib/IR/ConstantFold.cpp | 49 +- contrib/llvm-project/llvm/lib/IR/DebugInfo.cpp | 258 +- .../llvm/lib/IR/DebugProgramInstruction.cpp | 190 +- contrib/llvm-project/llvm/lib/IR/Dominators.cpp | 5 +- contrib/llvm-project/llvm/lib/IR/Globals.cpp | 3 +- contrib/llvm-project/llvm/lib/IR/Instruction.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Instructions.cpp | 4 +- contrib/llvm-project/llvm/lib/IR/Metadata.cpp | 103 +- .../llvm-project/llvm/lib/IR/StructuralHash.cpp | 9 +- .../VFABIDemangling.cpp => IR/VFABIDemangler.cpp} | 133 +- contrib/llvm-project/llvm/lib/IR/Value.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Verifier.cpp | 28 + .../llvm/lib/InterfaceStub/IFSHandler.cpp | 6 + .../llvm/lib/InterfaceStub/IFSStub.cpp | 3 +- contrib/llvm-project/llvm/lib/LTO/LTO.cpp | 2 +- .../llvm/lib/LTO/ThinLTOCodeGenerator.cpp | 6 +- .../llvm/lib/LineEditor/LineEditor.cpp | 2 +- .../llvm-project/llvm/lib/MC/ELFObjectWriter.cpp | 11 +- contrib/llvm-project/llvm/lib/MC/MCFragment.cpp | 2 +- .../llvm-project/llvm/lib/MC/MCObjectFileInfo.cpp | 4 + .../llvm/lib/MC/MCParser/DarwinAsmParser.cpp | 2 + contrib/llvm-project/llvm/lib/MC/MCStreamer.cpp | 9 + .../llvm-project/llvm/lib/MC/WasmObjectWriter.cpp | 2 +- .../llvm-project/llvm/lib/ObjCopy/CommonConfig.cpp | 6 +- contrib/llvm-project/llvm/lib/Object/Archive.cpp | 2 +- .../llvm-project/llvm/lib/Object/ArchiveWriter.cpp | 2 +- contrib/llvm-project/llvm/lib/Object/Binary.cpp | 1 + .../llvm/lib/Object/COFFImportFile.cpp | 80 +- .../llvm-project/llvm/lib/Object/ELFObjectFile.cpp | 4 + .../llvm-project/llvm/lib/Object/ObjectFile.cpp | 1 + .../llvm-project/llvm/lib/Object/OffloadBinary.cpp | 32 + .../llvm/lib/Object/RelocationResolver.cpp | 12 +- .../llvm/lib/Object/WasmObjectFile.cpp | 23 +- .../llvm-project/llvm/lib/Passes/PassBuilder.cpp | 237 +- .../llvm/lib/Passes/PassBuilderPipelines.cpp | 20 +- .../llvm-project/llvm/lib/Passes/PassRegistry.def | 17 +- .../llvm/lib/Passes/StandardInstrumentations.cpp | 4 +- .../lib/ProfileData/Coverage/CoverageMapping.cpp | 52 +- contrib/llvm-project/llvm/lib/ProfileData/GCOV.cpp | 2 +- .../llvm/lib/ProfileData/InstrProf.cpp | 8 +- .../llvm/lib/Remarks/YAMLRemarkParser.cpp | 14 +- .../llvm/lib/Support/BalancedPartitioning.cpp | 16 +- contrib/llvm-project/llvm/lib/Support/Caching.cpp | 4 +- .../llvm-project/llvm/lib/Support/CommandLine.cpp | 37 +- .../llvm/lib/Support/FileCollector.cpp | 2 +- .../llvm/lib/Support/FormatVariadic.cpp | 3 +- .../llvm-project/llvm/lib/Support/GraphWriter.cpp | 2 +- contrib/llvm-project/llvm/lib/Support/InitLLVM.cpp | 5 + .../llvm/lib/Support/LockFileManager.cpp | 8 +- contrib/llvm-project/llvm/lib/Support/Path.cpp | 4 +- contrib/llvm-project/llvm/lib/Support/Process.cpp | 2 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 22 +- .../llvm-project/llvm/lib/Support/SmallVector.cpp | 3 +- .../llvm-project/llvm/lib/Support/StringRef.cpp | 15 +- contrib/llvm-project/llvm/lib/Support/Unicode.cpp | 342 +- .../llvm/lib/Support/UnicodeCaseFold.cpp | 13 +- .../llvm/lib/Support/UnicodeNameToCodepoint.cpp | 3 +- .../Support/UnicodeNameToCodepointGenerated.cpp | 39628 ++++++++++--------- .../llvm-project/llvm/lib/Support/Unix/Program.inc | 2 +- .../llvm-project/llvm/lib/Support/VersionTuple.cpp | 6 +- .../llvm/lib/Support/VirtualFileSystem.cpp | 12 +- .../llvm-project/llvm/lib/Support/Windows/Path.inc | 41 +- .../llvm-project/llvm/lib/Target/AArch64/AArch64.h | 2 + .../llvm/lib/Target/AArch64/AArch64.td | 3 +- .../Target/AArch64/AArch64Arm64ECCallLowering.cpp | 769 + .../llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp | 77 + .../lib/Target/AArch64/AArch64CallingConvention.h | 16 + .../lib/Target/AArch64/AArch64CallingConvention.td | 128 + .../llvm/lib/Target/AArch64/AArch64Combine.td | 11 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 18 +- .../llvm/lib/Target/AArch64/AArch64FastISel.cpp | 3 + .../lib/Target/AArch64/AArch64FrameLowering.cpp | 26 + .../lib/Target/AArch64/AArch64GlobalsTagging.cpp | 26 +- .../lib/Target/AArch64/AArch64ISelDAGToDAG.cpp | 62 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 524 +- .../llvm/lib/Target/AArch64/AArch64ISelLowering.h | 16 +- .../llvm/lib/Target/AArch64/AArch64InstrGISel.td | 30 + .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 68 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.td | 131 +- .../Target/AArch64/AArch64LoopIdiomTransform.cpp | 11 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.cpp | 55 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.h | 3 + .../Target/AArch64/AArch64MachineFunctionInfo.h | 7 + .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 3 + .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 10 +- .../llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td | 4 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.cpp | 19 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.h | 5 +- .../lib/Target/AArch64/AArch64SystemOperands.td | 2 + .../lib/Target/AArch64/AArch64TargetMachine.cpp | 8 +- .../lib/Target/AArch64/AArch64TargetObjectFile.cpp | 10 + .../lib/Target/AArch64/AArch64TargetObjectFile.h | 7 + .../Target/AArch64/AArch64TargetTransformInfo.cpp | 69 +- .../Target/AArch64/AArch64TargetTransformInfo.h | 2 + .../Target/AArch64/AsmParser/AArch64AsmParser.cpp | 24 +- .../Target/AArch64/GISel/AArch64CallLowering.cpp | 24 +- .../AArch64/GISel/AArch64InstructionSelector.cpp | 9 +- .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 66 +- .../AArch64/GISel/AArch64PreLegalizerCombiner.cpp | 222 +- .../llvm/lib/Target/AArch64/SMEABIPass.cpp | 132 +- .../lib/Target/AArch64/Utils/AArch64BaseInfo.h | 39 +- .../Target/AArch64/Utils/AArch64SMEAttributes.cpp | 53 +- .../Target/AArch64/Utils/AArch64SMEAttributes.h | 78 +- .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.h | 3 + .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 54 +- .../llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp | 26 +- .../llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUCallLowering.cpp | 17 +- .../llvm/lib/Target/AMDGPU/AMDGPUGISel.td | 16 +- .../Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp | 3 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 21 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 35 + .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.h | 8 + .../Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp | 38 +- .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 28 +- .../lib/Target/AMDGPU/AMDGPUInstructionSelector.h | 6 +- .../llvm/lib/Target/AMDGPU/AMDGPUInstructions.td | 3 + .../lib/Target/AMDGPU/AMDGPULateCodeGenPrepare.cpp | 10 + .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 63 +- .../Target/AMDGPU/AMDGPULowerKernelArguments.cpp | 3 +- .../Target/AMDGPU/AMDGPULowerKernelAttributes.cpp | 5 +- .../Target/AMDGPU/AMDGPUMachineCFGStructurizer.cpp | 2 +- .../Target/AMDGPU/AMDGPUMarkLastScratchLoad.cpp | 142 + .../Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp | 6 + .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 42 +- .../AMDGPU/AMDGPURemoveIncompatibleFunctions.cpp | 3 +- .../Target/AMDGPU/AMDGPUResourceUsageAnalysis.cpp | 2 +- .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 10 + .../llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp | 2 +- .../llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp | 3 + .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 144 +- .../llvm/lib/Target/AMDGPU/BUFInstructions.td | 96 +- .../llvm/lib/Target/AMDGPU/DSInstructions.td | 41 +- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 7 +- .../llvm/lib/Target/AMDGPU/FLATInstructions.td | 189 +- .../llvm/lib/Target/AMDGPU/GCNDPPCombine.cpp | 28 +- .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 31 +- .../llvm/lib/Target/AMDGPU/GCNNSAReassign.cpp | 2 +- .../llvm/lib/Target/AMDGPU/GCNSubtarget.h | 49 +- .../AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp | 14 +- .../AMDGPU/MCTargetDesc/AMDGPUELFObjectWriter.cpp | 19 +- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 17 +- .../AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.cpp | 43 +- .../AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h | 4 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp | 134 +- .../AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.h | 59 +- .../llvm/lib/Target/AMDGPU/MIMGInstructions.td | 5 + .../llvm/lib/Target/AMDGPU/R600ISelLowering.cpp | 13 +- .../lib/Target/AMDGPU/SIAnnotateControlFlow.cpp | 7 +- .../llvm/lib/Target/AMDGPU/SIDefines.h | 10 +- .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 14 +- .../llvm/lib/Target/AMDGPU/SIFrameLowering.cpp | 7 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 262 +- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 3 +- .../llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 1095 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.cpp | 44 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 41 +- .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 291 +- .../llvm/lib/Target/AMDGPU/SIInstructions.td | 24 +- .../llvm/lib/Target/AMDGPU/SILowerSGPRSpills.cpp | 12 +- .../lib/Target/AMDGPU/SIMachineFunctionInfo.cpp | 54 +- .../llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | 25 +- .../llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp | 180 + .../llvm/lib/Target/AMDGPU/SIModeRegister.cpp | 2 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp | 9 +- .../llvm/lib/Target/AMDGPU/SMInstructions.td | 77 +- .../llvm/lib/Target/AMDGPU/SOPInstructions.td | 47 +- .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 233 +- .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 154 +- .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 8 +- .../llvm/lib/Target/AMDGPU/VOP2Instructions.td | 45 +- .../llvm/lib/Target/AMDGPU/VOP3Instructions.td | 4 +- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 83 +- .../llvm/lib/Target/AMDGPU/VOPCInstructions.td | 44 +- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 19 +- contrib/llvm-project/llvm/lib/Target/ARM/ARM.td | 18 + .../llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp | 19 +- .../llvm/lib/Target/ARM/ARMCallLowering.cpp | 6 +- .../llvm/lib/Target/ARM/ARMISelLowering.cpp | 11 +- .../llvm/lib/Target/ARM/ARMInstrMVE.td | 2 +- .../llvm/lib/Target/ARM/ARMSubtarget.h | 1 + .../llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp | 14 +- .../lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp | 20 +- .../lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp | 1 + .../lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h | 2 +- .../lib/Target/ARM/MVEGatherScatterLowering.cpp | 4 +- .../llvm/lib/Target/ARM/Thumb1InstrInfo.cpp | 4 +- .../llvm/lib/Target/ARM/Thumb2InstrInfo.cpp | 6 +- .../Hexagon/Disassembler/HexagonDisassembler.cpp | 2 + .../llvm/lib/Target/Hexagon/HexagonEarlyIfConv.cpp | 4 +- .../lib/Target/Hexagon/HexagonISelDAGToDAG.cpp | 3 +- .../lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp | 3 +- .../lib/Target/Hexagon/HexagonVectorCombine.cpp | 3 +- .../Hexagon/MCTargetDesc/HexagonMCInstrInfo.cpp | 6 +- .../llvm/lib/Target/LoongArch/LoongArch.td | 12 + .../Target/LoongArch/LoongArchFloat32InstrInfo.td | 8 + .../Target/LoongArch/LoongArchFloat64InstrInfo.td | 8 + .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 8 + .../lib/Target/LoongArch/LoongArchInstrInfo.td | 34 +- .../lib/Target/LoongArch/LoongArchLASXInstrInfo.td | 58 + .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 30 + .../llvm/lib/Target/LoongArch/LoongArchSubtarget.h | 4 + .../LoongArch/LoongArchTargetTransformInfo.cpp | 18 + .../LoongArch/LoongArchTargetTransformInfo.h | 2 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp | 196 + .../LoongArch/MCTargetDesc/LoongArchAsmBackend.h | 20 + .../LoongArch/MCTargetDesc/LoongArchFixupKinds.h | 2 + .../llvm/lib/Target/Mips/MipsAsmPrinter.cpp | 5 +- .../llvm/lib/Target/Mips/MipsCallLowering.cpp | 2 +- .../llvm/lib/Target/Mips/MipsRegisterBankInfo.cpp | 8 +- .../llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp | 24 + .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 50 +- *** 132333 LINES SKIPPED *** From nobody Sat Apr 20 10:34:33 2024 X-Original-To: dev-commits-src-branches@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 4VM7DV02RYz5HWfK; Sat, 20 Apr 2024 10:34:34 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DT2h9vz4SsX; Sat, 20 Apr 2024 10:34:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609273; 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=UqTkprAR8JhFZR1Wt69sWH2bVkMSVwHgUJ2p1OR/soU=; b=ZREtPPRrGe8gV0u+mIa0bbIxvTdyCr3i/b7gw5POH7IQlltc59d/8xijf8hAviF2FYb3HI SLPy4SZza5gJndL43jdEljgtBhRWjwGAFDEwKjbZQrsFcey1pXAaMcgxiej4n3ywg+hjpt AM+3/Csi/vOwuZjBHsxH8wiuV9Vz3+NFpLJu1BQSmJdwlnNn5zHTQ68gAcGpYZaijcWD08 XPc/mFjqplOgrfXrfyQnT09nEYVs7bexy3kD1LiLtPXPL+0+JXvFsJKyHHEoqoZxuFuRTk X2GVnhyolRHS8roatfIhBzZlroV9x/rb9oKXJ4dKEF0XdrVvybOaeoJjS63IFg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609273; a=rsa-sha256; cv=none; b=qQNbxlRkn7X5i3UzzKMZL7ZGLWOAL2i5Q+s6KAx5Ppq6QJeLVhW3Q2Zr1lEosgmT6D5JdC cpaIvJOLB9p9iRAyNTVjlh8HGl9JQGxWNDMHPZlWxEQg5oO6GAJhopkZq0HRd/ww9XNx0P n5AZmDHPbGd1Sw9AYPKzaU1wrlizqnb/3B4w+BFCARCeIuw94AV/aQ2QRCG3UqcFR0SG3U R0qQsN2/IPoZOFi0UeNr0DTw6uQcb58nFao+R+21qc+CX1wDGw9dF+VZ57UUdBpwoDvlVQ 5IJIBjz0ag4x2kKYLYjLF8TKs4RhNZ1zRTOthHQ8J1qp8kISW3QzrCuVtYqtLw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609273; 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=UqTkprAR8JhFZR1Wt69sWH2bVkMSVwHgUJ2p1OR/soU=; b=Lp2nVIpK1uXT0gJDty6tKJZbjVnFutDoyRIAsXESQpf17oYhO5NQN+6wRAKQo0HChxvaFi dmn3xX2pX4g3K/bGMT0esJK+3XXq1B0JpHnPIdndJ5yvWwKZAwZyjiZPRXEaBVshvTBdqB ZxKkgZqyz9PEFfrTLUI/tbGCEghBX9yacqbjIQCN6jNm+7FlPrfPKclv5HxHoL17s+WH6h +1ry5ONx4Q+DlSsdSYKBT6U1yvjynwMmPvzh+XTUP/DqLjykSMSORjy6nOLHSGqNB1Df0a enqZK17wuTCXMvudTEwtF1icd8RK3wWm5mfsyXEaf7+Py9iL+SHPZoSJfxyQHQ== 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 4VM7DT2HC0zZJN; Sat, 20 Apr 2024 10:34:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYXph013709; Sat, 20 Apr 2024 10:34:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYXvD013706; Sat, 20 Apr 2024 10:34:33 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:33 GMT Message-Id: <202404201034.43KAYXvD013706@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: a1f98ae0a8cd - stable/13 - Merge llvm-project release/18.x llvmorg-18-init-18361-g22683463740e List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: a1f98ae0a8cd6e032065e2b615f9dc2ed1520011 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a1f98ae0a8cd6e032065e2b615f9dc2ed1520011 commit a1f98ae0a8cd6e032065e2b615f9dc2ed1520011 Author: Dimitry Andric AuthorDate: 2024-01-26 15:04:14 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:45 +0000 Merge llvm-project release/18.x llvmorg-18-init-18361-g22683463740e This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18-init-18361-g22683463740e. PR: 276104 MFC after: 1 month (cherry picked from commit 878ed4957e077721efaf90ab5b70dce86dc94f4b) --- contrib/llvm-project/libcxx/include/__config | 2 +- lib/clang/include/VCSVersion.inc | 6 +++--- lib/clang/include/clang/Basic/Version.inc | 6 +++--- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +++--- lib/clang/include/llvm/Config/config.h | 4 ++-- lib/clang/include/llvm/Config/llvm-config.h | 4 ++-- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 2eada10e96ce..8248cf3d2239 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -64,7 +64,7 @@ // _LIBCPP_VERSION represents the version of libc++, which matches the version of LLVM. // Given a LLVM release LLVM XX.YY.ZZ (e.g. LLVM 17.0.1 == 17.00.01), _LIBCPP_VERSION is // defined to XXYYZZ. -# define _LIBCPP_VERSION 180000 +# define _LIBCPP_VERSION 180100 # define _LIBCPP_CONCAT_IMPL(_X, _Y) _X##_Y # define _LIBCPP_CONCAT(_X, _Y) _LIBCPP_CONCAT_IMPL(_X, _Y) diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index c4390452d813..ca4f5d50df14 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLVM_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define CLANG_REVISION "llvmorg-18-init-18361-g22683463740e" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLDB_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/clang/Basic/Version.inc b/lib/clang/include/clang/Basic/Version.inc index adf6c5966121..26d6b3b2938f 100644 --- a/lib/clang/include/clang/Basic/Version.inc +++ b/lib/clang/include/clang/Basic/Version.inc @@ -1,8 +1,8 @@ -#define CLANG_VERSION 18.0.0git -#define CLANG_VERSION_STRING "18.0.0git" +#define CLANG_VERSION 18.1.0rc +#define CLANG_VERSION_STRING "18.1.0rc" #define CLANG_VERSION_MAJOR 18 #define CLANG_VERSION_MAJOR_STRING "18" -#define CLANG_VERSION_MINOR 0 +#define CLANG_VERSION_MINOR 1 #define CLANG_VERSION_PATCHLEVEL 0 #define CLANG_VENDOR "FreeBSD " diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index 1ffb3458abd0..ff41eaf5ebbe 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400006 -#define LLD_VERSION_STRING "18.0.0 (FreeBSD llvmorg-18-init-18359-g93248729cfae-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18-init-18361-g22683463740e-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/lldb/Version/Version.inc b/lib/clang/include/lldb/Version/Version.inc index c5e07a4eefbd..7a9546b4696f 100644 --- a/lib/clang/include/lldb/Version/Version.inc +++ b/lib/clang/include/lldb/Version/Version.inc @@ -1,6 +1,6 @@ -#define LLDB_VERSION 18.0.0git -#define LLDB_VERSION_STRING "18.0.0git" +#define LLDB_VERSION 18.1.0rc +#define LLDB_VERSION_STRING "18.1.0rc" #define LLDB_VERSION_MAJOR 18 -#define LLDB_VERSION_MINOR 0 +#define LLDB_VERSION_MINOR 1 #define LLDB_VERSION_PATCH 0 /* #undef LLDB_FULL_VERSION_STRING */ diff --git a/lib/clang/include/llvm/Config/config.h b/lib/clang/include/llvm/Config/config.h index fdc104e49231..718c44fff94d 100644 --- a/lib/clang/include/llvm/Config/config.h +++ b/lib/clang/include/llvm/Config/config.h @@ -344,10 +344,10 @@ #define PACKAGE_NAME "LLVM" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "LLVM 18.0.0git" +#define PACKAGE_STRING "LLVM 18.1.0rc" /* Define to the version of this package. */ -#define PACKAGE_VERSION "18.0.0git" +#define PACKAGE_VERSION "18.1.0rc" /* Define to the vendor of this package. */ /* #undef PACKAGE_VENDOR */ diff --git a/lib/clang/include/llvm/Config/llvm-config.h b/lib/clang/include/llvm/Config/llvm-config.h index f3555d0868e2..111e0a296ed5 100644 --- a/lib/clang/include/llvm/Config/llvm-config.h +++ b/lib/clang/include/llvm/Config/llvm-config.h @@ -177,13 +177,13 @@ #define LLVM_VERSION_MAJOR 18 /* Minor version of the LLVM API */ -#define LLVM_VERSION_MINOR 0 +#define LLVM_VERSION_MINOR 1 /* Patch version of the LLVM API */ #define LLVM_VERSION_PATCH 0 /* LLVM version string */ -#define LLVM_VERSION_STRING "18.0.0git" +#define LLVM_VERSION_STRING "18.1.0rc" /* Whether LLVM records statistics for use with GetStatistics(), * PrintStatistics() or PrintStatisticsJSON() diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index 7cc55b62be19..fa5c1df71357 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-18-init-18359-g93248729cfae" +#define LLVM_REVISION "llvmorg-18-init-18361-g22683463740e" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" From nobody Sat Apr 20 10:34:32 2024 X-Original-To: dev-commits-src-branches@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 4VM7DS47vhz5HWNv; Sat, 20 Apr 2024 10:34: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DS1mXsz4Sc8; Sat, 20 Apr 2024 10:34:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609272; 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=jk3Lz4p8scNxeBAfgY1MqZEREWaiAiYRUTPtguRH9hM=; b=iza8sQ0989+3BM7v08gz4iZmNo2T37pZDfEHsNoYGOJ0yIAUp17tcI8h6qh/U9RbJIkoVb eXEXX6hnxPRbgeb+alQZ413tdebg1v1oev/d1Zlf1CEByiSaa7IExiaPJPsgv5xYvwitxo sPwT84tCX3sqKPpTax45cKmkfTnhP/lybe/0rlo30MRo0tfRzHCNkHZyOACTG9s6mNXkpe vwq81uCMboSrD/JREAMdwgVSFoBUQVp6a+63j57CVEPi/WkDyToSXGMqki9gQvlzLgwf4a +ygVv4SCVr4CKgWkMDNOTWeywdeLbzW2JeAlMtLc6jqO6HRJ3DZ/Uc2oSW6+OQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609272; a=rsa-sha256; cv=none; b=KYXoeyA30rpvdPrd0q/r375fy4WvxYr5/EJI6z/z92tXqlsQiCPrPrym/ud4Yf+g3iVDls w07mwyuz6u6Oftd+4GW/cQ/uQ+o5rcU1IWKJJftxkFCEti7/U+EcZhgtS4bayPfMi9qTVw kmxp3www/74h5PRZK9S5fs44tMkaFTtjiSzwW8Zjv4uaq77T92nTSIHGQLpxNG7LZIJDCi Wl9SYf3uHz9SxWmB8lUShl/TGqSbAYMvZes2F/byejopz0V6eF85Um7LooSbB7AtN7418Y SYeJ/V+wF2/XFT+OR7nQJz52bBiFI+ixy+CoRPYlL8ZMOtUiSp1+3K66rRUUKA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609272; 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=jk3Lz4p8scNxeBAfgY1MqZEREWaiAiYRUTPtguRH9hM=; b=C4QD1D9ZXH1pcsSsqTwanHTq0mGSAsYtbPmMj93DEWqEM/U2qdyqPZ0ITEIFcqdL77rP7m /gxamP3CmPhUHuUxnapUZ2yrQgIu0sdIRsD3gieLN9tmw1M8JzkhmC+LMf3D0k4cKNrQkL qzQjPrTYjRJB9q5w4Y5XAlm74940X1dmHh6QNVYqyfl4R2I/BoJ+MREbInfMmlvXbpjtip 78/vgiqDTCP/PKMGD8Q/D+wZHIjHizBS9FugWdEWNFK/FrDFSh/hiJpts1GZgenMCLmLm5 azgdSfqkTHEZ1yaLYINnTEJkKa142PDWp63ShARTB0gGixfgkUPPmWnbda7eQA== 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 4VM7DS1LghzYkj; Sat, 20 Apr 2024 10:34:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYWhP013666; Sat, 20 Apr 2024 10:34:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYWF0013663; Sat, 20 Apr 2024 10:34:32 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:32 GMT Message-Id: <202404201034.43KAYWF0013663@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: 206cf542ef75 - stable/13 - Tentatively apply https://github.com/libcxxrt/libcxxrt/pull/27 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 206cf542ef75ae895d82cb518e8de81b8a403d85 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=206cf542ef75ae895d82cb518e8de81b8a403d85 commit 206cf542ef75ae895d82cb518e8de81b8a403d85 Author: Dimitry Andric AuthorDate: 2024-01-26 15:03:20 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:45 +0000 Tentatively apply https://github.com/libcxxrt/libcxxrt/pull/27 This marks __cxa_allocate_exception, __cxa_free_exception and __cxa_init_primary_exception noexcept, to ensure compatibility with libc++'s declarations. PR: 276104 MFC after: 1 month (cherry picked from commit 3fb2e045791eb6f003205902cdc4f74702770ec6) --- contrib/libcxxrt/cxxabi.h | 6 +++--- contrib/libcxxrt/exception.cc | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/contrib/libcxxrt/cxxabi.h b/contrib/libcxxrt/cxxabi.h index e021f85c905a..ef4076a08a0a 100644 --- a/contrib/libcxxrt/cxxabi.h +++ b/contrib/libcxxrt/cxxabi.h @@ -204,12 +204,12 @@ __cxa_eh_globals *__cxa_get_globals_fast(void); std::type_info * __cxa_current_exception_type(); -void *__cxa_allocate_exception(size_t thrown_size); +void *__cxa_allocate_exception(size_t thrown_size) throw(); -void __cxa_free_exception(void* thrown_exception); +void __cxa_free_exception(void* thrown_exception) throw(); __cxa_exception *__cxa_init_primary_exception( - void *object, std::type_info* tinfo, void (*dest)(void *)); + void *object, std::type_info* tinfo, void (*dest)(void *)) throw(); /** * Throws an exception returned by __cxa_current_primary_exception(). This diff --git a/contrib/libcxxrt/exception.cc b/contrib/libcxxrt/exception.cc index b1659c902f56..35ff997dd445 100644 --- a/contrib/libcxxrt/exception.cc +++ b/contrib/libcxxrt/exception.cc @@ -121,7 +121,7 @@ static inline _Unwind_Reason_Code continueUnwinding(struct _Unwind_Exception *ex } -extern "C" void __cxa_free_exception(void *thrown_exception); +extern "C" void __cxa_free_exception(void *thrown_exception) throw(); extern "C" void __cxa_free_dependent_exception(void *thrown_exception); extern "C" void* __dynamic_cast(const void *sub, const __class_type_info *src, @@ -611,7 +611,7 @@ static void free_exception(char *e) * emergency buffer if malloc() fails, and may block if there are no such * buffers available. */ -extern "C" void *__cxa_allocate_exception(size_t thrown_size) +extern "C" void *__cxa_allocate_exception(size_t thrown_size) throw() { size_t size = thrown_size + sizeof(__cxa_exception); char *buffer = alloc_or_die(size); @@ -633,7 +633,7 @@ extern "C" void *__cxa_allocate_dependent_exception(void) * In this implementation, it is also called by __cxa_end_catch() and during * thread cleanup. */ -extern "C" void __cxa_free_exception(void *thrown_exception) +extern "C" void __cxa_free_exception(void *thrown_exception) throw() { __cxa_exception *ex = reinterpret_cast<__cxa_exception*>(thrown_exception) - 1; // Free the object that was thrown, calling its destructor @@ -794,7 +794,7 @@ static void throw_exception(__cxa_exception *ex) } extern "C" __cxa_exception *__cxa_init_primary_exception( - void *object, std::type_info* tinfo, void (*dest)(void *)) { + void *object, std::type_info* tinfo, void (*dest)(void *)) throw() { __cxa_exception *ex = reinterpret_cast<__cxa_exception*>(object) - 1; ex->referenceCount = 0; From nobody Sat Apr 20 10:34:34 2024 X-Original-To: dev-commits-src-branches@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 4VM7DW2crwz5HWRL; Sat, 20 Apr 2024 10:34:35 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DV3Ys7z4SwC; Sat, 20 Apr 2024 10:34:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609274; 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=zSmgAJc0QqwsYrEVK5+c5jLokhlGACqkVs/4MI/nBUE=; b=TOg1/gKvtJcViTntGJr1QEa489uS7HRtslSSH78RBJrWQcTgoWOFaOwbql1b47OS8oJ3wR 58MVwzqWOXVUYImH1nEY4ZwqdxPGZVMx9ewLp0B3nv2wQbBsive5ROKUmgIKJMKX+98MDt 3Aect0jv4hdS7xokIsA4/pGT5x1OdZ//RN6t54Q9rySXNwIYMk/3qRR5T2Kei3AEXv0Ldw Yi4DcGw40i0nkuc4qm7DSgRps8cOPeXePbFX8ctq+zNgtncN11cEYVJhCi4IV0B6iy5OWw 2G1jRoImanqJvfD6+ntQKZ1wx/xVPEHOOcBDOvtCrv1qDRe/WqGPppXujwQD7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609274; a=rsa-sha256; cv=none; b=K8zOcVIE2j0lzjir7D31vwuyoixwQ8SCm1rykkbkcSu6eTBvsuIQPBbM4XkEIeozdok486 IZk87irdpmkviZGZfsPK4iMbLLFxSOpM6gH4mvDkjcqonjEqr9vAT/ToavGbivYSYWvi++ 06I5fwafo/NAMpsplvnAnj0bHB4SNdvIdnhmD6VV5Q2VbHLbKNQbp5ioiMnL/rNRJyU2m5 oNiVNIrm7sCCtGojcJSLCIKXBUOoqH+wLH9mXkU1bK1OK/kvbloyeNagBEI1rsHgQyNz/g fdedb9WFXvEMXHC8IymIRYVc7dph+C3MzmaaDb88Ao7MWXll0xfOg/oMQYLH7A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609274; 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=zSmgAJc0QqwsYrEVK5+c5jLokhlGACqkVs/4MI/nBUE=; b=JVzmsH93GCXvs3dF+9JoTpgPWdLLZr2c0jyQa4+FYeerIYJ0bCkpjwCc1+i7x4RN06VnGx P8PjJVP3oLbLMw5RTVfZob5SeJ/BYuew+H4rNbtUz0K3asxzV1tL5U07Iaohpi7xucJZxp 0Meqn5ud1t7Sb6U8J6qodrm3hoEIffQkUwuu8dt1bk2X8zxqngS0TE9BQ5ge3NjK2Y7OWe SR+V/UP8MYLhgWeIttx0MLTyQlxoJ4iyMUVPelt9H13TCXw8ZSOjyukWnwIQZiR5wnYR0p FxBEX687juP9DJEKdXWL+yGyI//DidIMQueRSqJJvBkmsuH97y2S00cQLrMrfw== 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 4VM7DV39CNzYr0; Sat, 20 Apr 2024 10:34:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYY79013760; Sat, 20 Apr 2024 10:34:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYYZQ013757; Sat, 20 Apr 2024 10:34:34 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:34 GMT Message-Id: <202404201034.43KAYYZQ013757@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: 3731f53de156 - stable/13 - Merge commit 6e4930c67508 from llvm-project (by Alexander Kornienko): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 3731f53de15670dda105c051325295188df05c64 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=3731f53de15670dda105c051325295188df05c64 commit 3731f53de15670dda105c051325295188df05c64 Author: Dimitry Andric AuthorDate: 2024-01-28 20:34:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:45 +0000 Merge commit 6e4930c67508 from llvm-project (by Alexander Kornienko): Revert "[SemaCXX] Implement CWG2137 (list-initialization from objects of the same type) (#77768)" This reverts commit 924701311aa79180e86ad8ce43d253f27d25ec7d. Causes compilation errors on valid code, see https://github.com/llvm/llvm-project/pull/77768#issuecomment-1908062472. In particular, this fixes bogus "call to constructor of 'SomeType' is ambiguous" errors. PR: 276104 MFC after: 1 month (cherry picked from commit ddbac700c256bec42c441b75a5cb5f74e9be601f) --- contrib/llvm-project/clang/lib/Sema/SemaInit.cpp | 40 ++++++---------------- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 38 ++++++-------------- 2 files changed, 20 insertions(+), 58 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp b/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp index 91e4cb7b68a2..457fa377355a 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaInit.cpp @@ -4200,7 +4200,7 @@ static OverloadingResult ResolveConstructorOverload( /// \param IsListInit Is this list-initialization? /// \param IsInitListCopy Is this non-list-initialization resulting from a /// list-initialization from {x} where x is the same -/// aggregate type as the entity? +/// type as the entity? static void TryConstructorInitialization(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, @@ -4230,14 +4230,6 @@ static void TryConstructorInitialization(Sema &S, Entity.getKind() != InitializedEntity::EK_LambdaToBlockConversionBlockElement); - bool CopyElisionPossible = false; - auto ElideConstructor = [&] { - // Convert qualifications if necessary. - Sequence.AddQualificationConversionStep(DestType, VK_PRValue); - if (ILE) - Sequence.RewrapReferenceInitList(DestType, ILE); - }; - // C++17 [dcl.init]p17: // - If the initializer expression is a prvalue and the cv-unqualified // version of the source type is the same class as the class of the @@ -4250,17 +4242,11 @@ static void TryConstructorInitialization(Sema &S, if (S.getLangOpts().CPlusPlus17 && !RequireActualConstructor && UnwrappedArgs.size() == 1 && UnwrappedArgs[0]->isPRValue() && S.Context.hasSameUnqualifiedType(UnwrappedArgs[0]->getType(), DestType)) { - if (ILE && !DestType->isAggregateType()) { - // CWG2311: T{ prvalue_of_type_T } is not eligible for copy elision - // Make this an elision if this won't call an initializer-list - // constructor. (Always on an aggregate type or check constructors first.) - assert(!IsInitListCopy && - "IsInitListCopy only possible with aggregate types"); - CopyElisionPossible = true; - } else { - ElideConstructor(); - return; - } + // Convert qualifications if necessary. + Sequence.AddQualificationConversionStep(DestType, VK_PRValue); + if (ILE) + Sequence.RewrapReferenceInitList(DestType, ILE); + return; } const RecordType *DestRecordType = DestType->getAs(); @@ -4305,12 +4291,6 @@ static void TryConstructorInitialization(Sema &S, S, Kind.getLocation(), Args, CandidateSet, DestType, Ctors, Best, CopyInitialization, AllowExplicit, /*OnlyListConstructors=*/true, IsListInit, RequireActualConstructor); - - if (CopyElisionPossible && Result == OR_No_Viable_Function) { - // No initializer list candidate - ElideConstructor(); - return; - } } // C++11 [over.match.list]p1: @@ -4592,9 +4572,9 @@ static void TryListInitialization(Sema &S, return; } - // C++11 [dcl.init.list]p3, per DR1467 and DR2137: - // - If T is an aggregate class and the initializer list has a single element - // of type cv U, where U is T or a class derived from T, the object is + // C++11 [dcl.init.list]p3, per DR1467: + // - If T is a class type and the initializer list has a single element of + // type cv U, where U is T or a class derived from T, the object is // initialized from that element (by copy-initialization for // copy-list-initialization, or by direct-initialization for // direct-list-initialization). @@ -4605,7 +4585,7 @@ static void TryListInitialization(Sema &S, // - Otherwise, if T is an aggregate, [...] (continue below). if (S.getLangOpts().CPlusPlus11 && InitList->getNumInits() == 1 && !IsDesignatedInit) { - if (DestType->isRecordType() && DestType->isAggregateType()) { + if (DestType->isRecordType()) { QualType InitType = InitList->getInit(0)->getType(); if (S.Context.hasSameUnqualifiedType(InitType, DestType) || S.IsDerivedFrom(InitList->getBeginLoc(), InitType, DestType)) { diff --git a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp index 030878899b81..c9eb67898356 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp @@ -1568,37 +1568,19 @@ TryUserDefinedConversion(Sema &S, Expr *From, QualType ToType, // called for those cases. if (CXXConstructorDecl *Constructor = dyn_cast(ICS.UserDefined.ConversionFunction)) { - QualType FromType; - SourceLocation FromLoc; - // C++11 [over.ics.list]p6, per DR2137: - // C++17 [over.ics.list]p6: - // If C is not an initializer-list constructor and the initializer list - // has a single element of type cv U, where U is X or a class derived - // from X, the implicit conversion sequence has Exact Match rank if U is - // X, or Conversion rank if U is derived from X. - if (const auto *InitList = dyn_cast(From); - InitList && InitList->getNumInits() == 1 && - !S.isInitListConstructor(Constructor)) { - const Expr *SingleInit = InitList->getInit(0); - FromType = SingleInit->getType(); - FromLoc = SingleInit->getBeginLoc(); - } else { - FromType = From->getType(); - FromLoc = From->getBeginLoc(); - } - QualType FromCanon = - S.Context.getCanonicalType(FromType.getUnqualifiedType()); + QualType FromCanon + = S.Context.getCanonicalType(From->getType().getUnqualifiedType()); QualType ToCanon = S.Context.getCanonicalType(ToType).getUnqualifiedType(); if (Constructor->isCopyConstructor() && (FromCanon == ToCanon || - S.IsDerivedFrom(FromLoc, FromCanon, ToCanon))) { + S.IsDerivedFrom(From->getBeginLoc(), FromCanon, ToCanon))) { // Turn this into a "standard" conversion sequence, so that it // gets ranked with standard conversion sequences. DeclAccessPair Found = ICS.UserDefined.FoundConversionFunction; ICS.setStandard(); ICS.Standard.setAsIdentityConversion(); - ICS.Standard.setFromType(FromType); + ICS.Standard.setFromType(From->getType()); ICS.Standard.setAllToTypes(ToType); ICS.Standard.CopyConstructor = Constructor; ICS.Standard.FoundCopyConstructor = Found; @@ -5324,18 +5306,18 @@ TryListConversion(Sema &S, InitListExpr *From, QualType ToType, IsDesignatedInit) return Result; - // Per DR1467 and DR2137: - // If the parameter type is an aggregate class X and the initializer list - // has a single element of type cv U, where U is X or a class derived from - // X, the implicit conversion sequence is the one required to convert the - // element to the parameter type. + // Per DR1467: + // If the parameter type is a class X and the initializer list has a single + // element of type cv U, where U is X or a class derived from X, the + // implicit conversion sequence is the one required to convert the element + // to the parameter type. // // Otherwise, if the parameter type is a character array [... ] // and the initializer list has a single element that is an // appropriately-typed string literal (8.5.2 [dcl.init.string]), the // implicit conversion sequence is the identity conversion. if (From->getNumInits() == 1 && !IsDesignatedInit) { - if (ToType->isRecordType() && ToType->isAggregateType()) { + if (ToType->isRecordType()) { QualType InitType = From->getInit(0)->getType(); if (S.Context.hasSameUnqualifiedType(InitType, ToType) || S.IsDerivedFrom(From->getBeginLoc(), InitType, ToType)) From nobody Sat Apr 20 10:34:35 2024 X-Original-To: dev-commits-src-branches@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 4VM7DX2962z5HWV0; Sat, 20 Apr 2024 10:34:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DW5Tx0z4SyL; Sat, 20 Apr 2024 10:34:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609275; 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=sQjFmkNCCJEMnjPQD4phf+ff750ad5a8yfU6uEE/+cg=; b=Y2RcVA3aHjzywpdOTjfo1sSyS69ldtr6CKSABqWHMpTyma+RtNHZOJZqd+HP+I1ZexqaEF blFgaUvxnHcU/1RlOwQw/YJdU2P7/T5x1mCEkG44FYBm9M9onF7h4XmnrgFziSOw7T/wLm bSm+HHhRvvd4zqgsmaHhRVStAG8ck86yiK0LaHkfc6IhDL5kkT0b5F8JfSe22XLyOp2dQm 9o5PsS6jqJYvfYYwqiQBOC0956zaj8q3VzTI9NKBpnYimtiDax+m6YrO/oCfnbW6/59aKr lBKrhql998U77gkRCCTm1QbiKnWDFiOfzDozZt07GPW5SUb/0xK6GX64YLXXnA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609275; a=rsa-sha256; cv=none; b=Vg5+sAFp/BztYyI8u42kGuCauBMrxoXzxKw9dC9ru9PpOOt4JgGlfHgCazTtcNAHWXZ1gD 11/58wAZlbn7T7Booyty3oJ2IYy9V0LZpeRUcLb/ukSDUdgH+DNXdN8343773VBpMo5cUN cQIvw6tpXxkLda74UIeSqI8mbQCs8GT/Swv4AXlwPKlXq+3xMDv4EJmsj/K4yrbiGUqogG tHX+6GhVIafTStvU1gIK5mgon3HjlRKoznItKEBkkjf3sBiZmkAjIbshdZLNGdKDN4hYWz /Q3Pr3hv3lF5mUrDIzov7oyFoz4JZ7bjiheQL3J9q2Xqm95EjvrW1ekDMDO2WQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609275; 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=sQjFmkNCCJEMnjPQD4phf+ff750ad5a8yfU6uEE/+cg=; b=TorBe/DJIvjC1uKWVfBHo7K8o9Z+ineLctwJ50mC+9aFhYrH8VwOi+NTHpS8yiRAS7OObP WuFMFpTzJB13yi+QXDuL5Yuh46Z5Z0b2I9hDHtYM6bLLPCoQpKq2FLXCRBENYGa2a0EB4l ZEDIoLcNhvtbtv5Ae3LkiiT8AS8slz8wfnEzcRHgmQQqFTvrmdgwUOV37cEHRfOb914lDR SmsfNnJVug7pem4S3HMwGVm67Xhvb3/ovN1Ms8T7Qu4Y3BSAcDi4EyCP4n2/NGC5oIQnbV nJlyL7Uk1ICwGVTqTb9MNCHF07HLwPqCEXJQrD/O5HgTWqhneNqT7egjMhcfmg== 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 4VM7DW4ctxzZFn; Sat, 20 Apr 2024 10:34:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYZbQ013813; Sat, 20 Apr 2024 10:34:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYZC1013810; Sat, 20 Apr 2024 10:34:35 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:35 GMT Message-Id: <202404201034.43KAYZC1013810@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: 6c596be66539 - stable/13 - Merge commit 5f4ee5a2dfa9 from llvm-project (by Shanzhi): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 6c596be66539299d553c77acf94db2bed63a6fc5 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=6c596be66539299d553c77acf94db2bed63a6fc5 commit 6c596be66539299d553c77acf94db2bed63a6fc5 Author: Dimitry Andric AuthorDate: 2024-02-05 09:16:17 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:46 +0000 Merge commit 5f4ee5a2dfa9 from llvm-project (by Shanzhi): [Clang][AST] Fix a crash on attaching doc comments (#78716) This crash is basically caused by calling `ASTContext::getRawCommentForDeclNoCacheImp` with its input arguments `RepresentativeLocForDecl` and `CommentsInTheFile` refering to different files. A reduced reproducer is provided in this patch. After the source locations for instantiations of funtion template are corrected in the commit 256a0b298c68b89688b80350b034daf2f7785b67, the variable `CommitsInThisFile` in the function `ASTContext::attachCommentsToJustParsedDecls` would refer to the source file rather than the header file for implicit function template instantiation. Therefore, in the first loop in `ASTContext::attachCommentsToJustParsedDecls`, `D` should also be adjusted for relevant scenarios like the second loop. Fixes #67979 Fixes #68524 Fixes #70550 This should fix a segfault when compiling graphics/gdal. PR: 276104 MFC after: 1 month (cherry picked from commit dc36515b628331e03ac8c23a6749f7f3eb1ebec8) --- contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index 5eb7aa366456..9a0ede201059 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -498,7 +498,11 @@ void ASTContext::attachCommentsToJustParsedDecls(ArrayRef Decls, return; FileID File; - for (Decl *D : Decls) { + for (const Decl *D : Decls) { + if (D->isInvalidDecl()) + continue; + + D = &adjustDeclToTemplate(*D); SourceLocation Loc = D->getLocation(); if (Loc.isValid()) { // See if there are any new comments that are not attached to a decl. From nobody Sat Apr 20 10:34:36 2024 X-Original-To: dev-commits-src-branches@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 4VM7DY0l1gz5HWRQ; Sat, 20 Apr 2024 10:34:37 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DX5gTkz4SlM; Sat, 20 Apr 2024 10:34:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609276; 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=jkW3LazM8aARiSeyuyGYYMuMIjJ+itgDed5GWc8Qcq8=; b=SCgHSj1gq/lMHsYX1vzcxcnQk8NDktzwlR93IXLGuqjbcrIdik0ZXdOHphVjEwlEXNPQ5h PHUWJwQr/tmO0gjsJ8cnlmGQDPG8DJ3L90upJWxxY26oXprpkJEagUJW6omuActIgXSXj0 oxG9hjRhXWpOpW8GG+jgLXt0WZJ9F536A8Ee0/9jZwFJEM64xOtef/oLarfFDbKo1JeWhn tLKIXte2O43E7aAvOeCJ9EVx7kylaX+VRgL8A4JQa8PHX+jJSRjxM32Er8QwNR7PdN2woF ahheJ2avRUlsKwSl8B7A58S2uKHUgi/20ea5lo2MW3/+m9vYzeR40x3ZlI51jA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609276; a=rsa-sha256; cv=none; b=TOCTWynUbk/nHWwrXzRi4ZEr9V2zMtrRADXVN5T2sUmEfqVuhxuMOqJE57FnM+tgAf2jmh OCi45TNc8EzFwMHemLQO/gglZb7Vf/MDY3yEMI/TUztZQXD/EDP5sQLoTjfiIn9AyrkC/c trSZGnrsaLuOq7Vsv4+KssIyb3/ecIjg3RzqQBDWXpJffvUXDid28T5A1dh/lplPeOVPz9 iUXN6WN8M+FZOz/s2p2Bc7f+i5nJ8xLKJffhBXyTg3bbsg0dxYILFXq48ZmWj6zADEgRmu t51NCrWPukIr9lyK9Pfmv8QSpa833aVTUq1h+w0+1WOz60aaBotT5ge/d7n8uQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609276; 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=jkW3LazM8aARiSeyuyGYYMuMIjJ+itgDed5GWc8Qcq8=; b=IdE1zf5kfkOZWEaJ1zgG6OIMN/+mLBQeuxXcoN++3lmVD0xOVQ6hpQvr2FYahM7Ok20k2Z oHD2TjaXFduDLAz6GX4rl6kwfbvcCqFs4bgk54B6YetsTnomfx6C4S9mqjzbJ7Rxb0Y/FW FpXqrf2kDeMMknwdoTJBGuJybrBF1pmfz5r8zrorbHltnKmau66GlVPTs62ArVuF0qrmRk +/PBQ4UWv3rUYax+bFDaWTkMErUXUH7RB5CBrjeBmc6UaCr1yoFyBvc6LpgAhuhTPokL6i TXpi3mE4oV4BsFJLkrYB5p61JnZ+W2PxZd4IcE6KpFze77YdxKo/Sd4/Zj2YqA== 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 4VM7DX5HskzYn7; Sat, 20 Apr 2024 10:34:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYaCj013864; Sat, 20 Apr 2024 10:34:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYaBt013861; Sat, 20 Apr 2024 10:34:36 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:36 GMT Message-Id: <202404201034.43KAYaBt013861@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: af050415f0c5 - stable/13 - [libc++] Rename __bit_reference template parameter to avoid conflict List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: af050415f0c5d1d2d0a22a45a7a8c964902399f7 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=af050415f0c5d1d2d0a22a45a7a8c964902399f7 commit af050415f0c5d1d2d0a22a45a7a8c964902399f7 Author: Dimitry Andric AuthorDate: 2024-02-05 11:41:51 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:46 +0000 [libc++] Rename __bit_reference template parameter to avoid conflict As of 4d20cfcf4eb08217ed37c4d4c38dc395d7a66d26, `__bit_reference` contains a template `__fill_n` with a bool `_FillValue` parameter. Unfortunately there is a relatively widely used piece of scientific software called NetCDF, which exposes a (C) macro `_FillValue` in its public headers. When building the NetCDF C++ bindings, this quickly leads to compilation errors when the macro interferes with the template in `__bit_reference`. Rename the parameter to `_FillVal` to avoid the conflict. PR: 276104 MFC after: 1 month (cherry picked from commit 868ee3f2855615016ba87c14b9444c18a2e1ba30) --- contrib/llvm-project/libcxx/include/__bit_reference | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__bit_reference b/contrib/llvm-project/libcxx/include/__bit_reference index 9032b8f01809..3a5339b72ddc 100644 --- a/contrib/llvm-project/libcxx/include/__bit_reference +++ b/contrib/llvm-project/libcxx/include/__bit_reference @@ -173,7 +173,7 @@ private: // fill_n -template +template _LIBCPP_CONSTEXPR_SINCE_CXX20 _LIBCPP_HIDE_FROM_ABI void __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { using _It = __bit_iterator<_Cp, false>; @@ -185,7 +185,7 @@ __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); __storage_type __dn = std::min(__clz_f, __n); __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - if (_FillValue) + if (_FillVal) *__first.__seg_ |= __m; else *__first.__seg_ &= ~__m; @@ -194,13 +194,13 @@ __fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) { } // do middle whole words __storage_type __nw = __n / __bits_per_word; - std::fill_n(std::__to_address(__first.__seg_), __nw, _FillValue ? static_cast<__storage_type>(-1) : 0); + std::fill_n(std::__to_address(__first.__seg_), __nw, _FillVal ? static_cast<__storage_type>(-1) : 0); __n -= __nw * __bits_per_word; // do last partial word if (__n > 0) { __first.__seg_ += __nw; __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - if (_FillValue) + if (_FillVal) *__first.__seg_ |= __m; else *__first.__seg_ &= ~__m; @@ -1007,7 +1007,7 @@ private: friend class __bit_iterator<_Cp, true>; template friend struct __bit_array; - template + template _LIBCPP_CONSTEXPR_SINCE_CXX20 friend void __fill_n(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n); template From nobody Sat Apr 20 10:34:39 2024 X-Original-To: dev-commits-src-branches@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 4VM7Db4ldNz5HWcc; Sat, 20 Apr 2024 10:34:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Db3k4Cz4SnY; Sat, 20 Apr 2024 10:34:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609279; 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=bK186pO+fEk3Q7MDqOBmcJXkkJCqEuAnLCacew2KiUA=; b=um/dEAHzB1H4LBINiLlaHLwKgHspTjv+0VWd5cuhRPcWD/uuzyJHXpcDjIgASWZ+PRNHZf tR5y/yDzaLbOp8iv9Lw5LLOLkVbX/mufrTcPofUVKwpREWlg0rnxGRtxegVIFJV9b2V+Uh ikY58tC0uUe4Z0vpmDHXxDm+8SsKjbFjbLGqhKE06NCPRkn3Yd/pwUo5qcsPsg5zPmFYq0 nIg08Uha7/Ea0M/u3x5adYU5XLtldV/3UkkWh6VumWxI6YhQo+hp6zjtbCavxmoNsjANrV qiQdXGYkeir5HUj8iYuOzZmiaewJMa6RmOLixFUDlDGrQZgCpZCpHuocdHP/0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609279; a=rsa-sha256; cv=none; b=nf+/uMmk0ww0urZNynfIfang9P+vsZuNEX/FxT4cJHOo6iyZY5uQ+MazKCfreDqhcyICC6 +W+2OqWD3HxP8LvGQ+7iA/NLuBRGTyRBfzPIPLO5Mfjn2/UxN9T9u4eeacaYsqadX8DhmM ueVumioq1dppMa50icENq837nEBGKQFa5aA+kCh30nFSrx/YcErIuVuMsZi+ccRfknqA+v lyknf7J9bbPvkPk31sXWAY5Pvc1VIIbYcAbz10rdwKCFoiXyj6JRtVpIrHUDKJt04UGD5r kGAoQQAqC0GaUIQTi9nry5/kNB/+UOODAUonxFsGK1hOuCxoy6rZcieaWOCaAQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609279; 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=bK186pO+fEk3Q7MDqOBmcJXkkJCqEuAnLCacew2KiUA=; b=KyTS6QMdcq+k5qBH9MRlUikJungokG9RSnfhFrcIBhow9v29qznbwvjdXTPK1RBeQnREWl f9PT2fpW/IVZWsqEWj25BfUkKm6v5kxtnel8Vz3QlXKJNu5xJz4pnMTULVmjNJEDznjGVr e/NhApY76uS3u9y3WL1SifSK1U/8/7TevpBTo5njz3GrSPDMSUjulefMwYxWTcHkWFG/Yt ty8nFtHAGOQHmtxBIJ2eXaiMgOkOXjlf/oAqcDMSb5cfGY75go986CwKcHnmD7zAnxwy21 7UoXhWZO66P7HCeoTmdEo6p5YgQVy/rvivX3m7aVvK2158r6mVnqpW2wp7UTDw== 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 4VM7Db3CbGzZJR; Sat, 20 Apr 2024 10:34:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYdjO013956; Sat, 20 Apr 2024 10:34:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYdPr013953; Sat, 20 Apr 2024 10:34:39 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:39 GMT Message-Id: <202404201034.43KAYdPr013953@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: c80674ff65c5 - stable/13 - Merge llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: c80674ff65c5ff9f2a844e4ed6fe7e5f935f6e4c Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=c80674ff65c5ff9f2a844e4ed6fe7e5f935f6e4c commit c80674ff65c5ff9f2a844e4ed6fe7e5f935f6e4c Author: Dimitry Andric AuthorDate: 2024-02-20 18:57:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:47 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc2-53-gc7b0a6ecd442. PR: 276104 MFC after: 1 month (cherry picked from commit 74626c16ff489c0d64cf2843dfd522e7c544f3ce) --- .../clang/include/clang/Basic/arm_sme.td | 28 +- .../clang/include/clang/Driver/Options.td | 12 + .../clang/lib/Basic/Targets/AArch64.cpp | 9 +- .../clang/lib/Driver/ToolChains/Arch/Sparc.cpp | 81 +++ .../clang/lib/Format/UnwrappedLineParser.cpp | 2 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 2 +- .../clang/tools/clang-format/ClangFormat.cpp | 49 +- .../compiler-rt/lib/dfsan/dfsan_custom.cpp | 203 ++----- .../compiler-rt/lib/dfsan/done_abilist.txt | 6 + .../lib/dfsan/libc_ubuntu1404_abilist.txt | 5 + .../lib/profile/InstrProfilingPlatformAIX.c | 4 +- contrib/llvm-project/libcxx/include/print | 14 +- .../llvm-project/libcxx/modules/CMakeLists.txt.in | 88 +++ .../llvm-project/libcxx/modules/std/ostream.inc | 4 +- contrib/llvm-project/libcxx/src/print.cpp | 25 +- contrib/llvm-project/lld/COFF/Driver.cpp | 10 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 156 +++++- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 29 +- contrib/llvm-project/lld/ELF/Arch/SystemZ.cpp | 607 +++++++++++++++++++++ contrib/llvm-project/lld/ELF/Driver.cpp | 3 +- contrib/llvm-project/lld/ELF/InputFiles.cpp | 2 + contrib/llvm-project/lld/ELF/InputSection.cpp | 14 +- contrib/llvm-project/lld/ELF/InputSection.h | 24 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 27 +- contrib/llvm-project/lld/ELF/Relocations.h | 3 + contrib/llvm-project/lld/ELF/ScriptParser.cpp | 1 + contrib/llvm-project/lld/ELF/SyntheticSections.cpp | 3 + contrib/llvm-project/lld/ELF/Target.cpp | 2 + contrib/llvm-project/lld/ELF/Target.h | 4 + contrib/llvm-project/lld/ELF/Writer.cpp | 4 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 53 +- .../llvm/include/llvm/BinaryFormat/ELF.h | 1 + .../llvm/lib/Analysis/ValueTracking.cpp | 7 +- .../lib/CodeGen/GlobalISel/LegalizerHelper.cpp | 2 + .../llvm/lib/CodeGen/RegisterCoalescer.cpp | 27 +- .../llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 2 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 11 +- .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 4 + .../Target/AArch64/GISel/AArch64LegalizerInfo.cpp | 5 +- .../lib/Target/Mips/AsmParser/MipsAsmParser.cpp | 7 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 98 ++-- .../llvm/lib/Target/RISCV/RISCVInstrInfo.cpp | 3 +- .../llvm-project/llvm/lib/Target/Sparc/Sparc.td | 14 + .../llvm/lib/Target/Sparc/SparcISelLowering.cpp | 43 ++ .../llvm/lib/Target/Sparc/SparcRegisterInfo.cpp | 14 +- .../llvm/lib/Target/Sparc/SparcRegisterInfo.h | 1 + .../llvm/lib/Target/Sparc/SparcRegisterInfo.td | 4 + .../llvm/lib/Target/Sparc/SparcSubtarget.cpp | 1 + .../llvm/lib/Target/Sparc/SparcSubtarget.h | 10 + .../llvm/lib/Target/X86/X86ISelLowering.cpp | 10 +- .../llvm/lib/Transforms/IPO/LowerTypeTests.cpp | 28 +- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 14 +- contrib/llvm-project/openmp/runtime/src/kmp.h | 7 +- .../openmp/runtime/src/kmp_csupport.cpp | 5 +- .../openmp/runtime/src/kmp_gsupport.cpp | 2 +- .../llvm-project/openmp/runtime/src/kmp_lock.cpp | 6 +- contrib/llvm-project/openmp/runtime/src/kmp_lock.h | 17 +- .../openmp/runtime/src/kmp_settings.cpp | 5 + lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- usr.bin/clang/lld/Makefile | 1 + 62 files changed, 1481 insertions(+), 352 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td b/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td index 695e1bddf9ff..2da0e8d2aba9 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td +++ b/contrib/llvm-project/clang/include/clang/Basic/arm_sme.td @@ -44,6 +44,7 @@ defm SVLD1_ZA32 : ZALoad<"za32", "i", "aarch64_sme_ld1w", [ImmCheck<0, ImmCheck0 defm SVLD1_ZA64 : ZALoad<"za64", "l", "aarch64_sme_ld1d", [ImmCheck<0, ImmCheck0_7>]>; defm SVLD1_ZA128 : ZALoad<"za128", "q", "aarch64_sme_ld1q", [ImmCheck<0, ImmCheck0_15>]>; +let TargetGuard = "sme" in { def SVLDR_VNUM_ZA : MInst<"svldr_vnum_za", "vmQl", "", [IsOverloadNone, IsStreamingCompatible, IsInOutZA], MemEltTyDefault, "aarch64_sme_ldr">; @@ -51,6 +52,7 @@ def SVLDR_VNUM_ZA : MInst<"svldr_vnum_za", "vmQl", "", def SVLDR_ZA : MInst<"svldr_za", "vmQ", "", [IsOverloadNone, IsStreamingCompatible, IsInOutZA], MemEltTyDefault, "aarch64_sme_ldr", []>; +} //////////////////////////////////////////////////////////////////////////////// // Stores @@ -81,6 +83,7 @@ defm SVST1_ZA32 : ZAStore<"za32", "i", "aarch64_sme_st1w", [ImmCheck<0, ImmCheck defm SVST1_ZA64 : ZAStore<"za64", "l", "aarch64_sme_st1d", [ImmCheck<0, ImmCheck0_7>]>; defm SVST1_ZA128 : ZAStore<"za128", "q", "aarch64_sme_st1q", [ImmCheck<0, ImmCheck0_15>]>; +let TargetGuard = "sme" in { def SVSTR_VNUM_ZA : MInst<"svstr_vnum_za", "vm%l", "", [IsOverloadNone, IsStreamingCompatible, IsInZA], MemEltTyDefault, "aarch64_sme_str">; @@ -88,6 +91,7 @@ def SVSTR_VNUM_ZA : MInst<"svstr_vnum_za", "vm%l", "", def SVSTR_ZA : MInst<"svstr_za", "vm%", "", [IsOverloadNone, IsStreamingCompatible, IsInZA], MemEltTyDefault, "aarch64_sme_str", []>; +} //////////////////////////////////////////////////////////////////////////////// // Read horizontal/vertical ZA slices @@ -277,22 +281,22 @@ multiclass ZAAddSub { def NAME # _ZA32_VG1x2_I32 : Inst<"sv" # n_suffix # "_za32[_{d}]_vg1x2", "vm2", "iUif", MergeNone, "aarch64_sme_" # n_suffix # "_za32_vg1x2", [IsStreaming, IsInOutZA], []>; def NAME # _ZA32_VG1X4_I32 : Inst<"sv" # n_suffix # "_za32[_{d}]_vg1x4", "vm4", "iUif", MergeNone, "aarch64_sme_" # n_suffix # "_za32_vg1x4", [IsStreaming, IsInOutZA], []>; + } - let TargetGuard = "sme-i16i64" in { - def NAME # _WRITE_SINGLE_ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x2", "vm2d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_SINGLE_ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x4", "vm4d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x4", [IsStreaming, IsInOutZA], []>; + let TargetGuard = "sme2,sme-i16i64" in { + def NAME # _WRITE_SINGLE_ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x2", "vm2d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_SINGLE_ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_write[_single]_za64[_{d}]_vg1x4", "vm4d", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_single_za_vg1x4", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_ZA64_VG1x2_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x2", "vm22", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _WRITE_ZA64_VG1x4_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x4", "vm44", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x4", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_ZA64_VG1x2_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x2", "vm22", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _WRITE_ZA64_VG1x4_I64 : Inst<"sv" # n_suffix # "_write_za64[_{d}]_vg1x4", "vm44", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_write_za_vg1x4", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; - } + def NAME # _ZA64_VG1X2_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _ZA64_VG1X4_I64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "lUl", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; + } - let TargetGuard = "sme-f64f64" in { - def NAME # _ZA64_VG1X2_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; - def NAME # _ZA64_VG1X4_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; - } + let TargetGuard = "sme2,sme-f64f64" in { + def NAME # _ZA64_VG1X2_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x2", "vm2", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x2", [IsStreaming, IsInOutZA], []>; + def NAME # _ZA64_VG1X4_F64 : Inst<"sv" # n_suffix # "_za64[_{d}]_vg1x4", "vm4", "d", MergeNone, "aarch64_sme_" # n_suffix # "_za64_vg1x4", [IsStreaming, IsInOutZA], []>; } } diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index e8d03fc26902..175bedbfb4d0 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -5815,6 +5815,18 @@ def mvis3 : Flag<["-"], "mvis3">, Group; def mno_vis3 : Flag<["-"], "mno-vis3">, Group; def mhard_quad_float : Flag<["-"], "mhard-quad-float">, Group; def msoft_quad_float : Flag<["-"], "msoft-quad-float">, Group; +foreach i = 1 ... 7 in + def ffixed_g#i : Flag<["-"], "ffixed-g"#i>, Group, + HelpText<"Reserve the G"#i#" register (SPARC only)">; +foreach i = 0 ... 5 in + def ffixed_o#i : Flag<["-"], "ffixed-o"#i>, Group, + HelpText<"Reserve the O"#i#" register (SPARC only)">; +foreach i = 0 ... 7 in + def ffixed_l#i : Flag<["-"], "ffixed-l"#i>, Group, + HelpText<"Reserve the L"#i#" register (SPARC only)">; +foreach i = 0 ... 5 in + def ffixed_i#i : Flag<["-"], "ffixed-i"#i>, Group, + HelpText<"Reserve the I"#i#" register (SPARC only)">; } // let Flags = [TargetSpecific] // M68k features flags diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 336b7a5e3d72..3036f461c1de 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -1187,6 +1187,8 @@ TargetInfo::BuiltinVaListKind AArch64TargetInfo::getBuiltinVaListKind() const { } const char *const AArch64TargetInfo::GCCRegNames[] = { + // clang-format off + // 32-bit Integer registers "w0", "w1", "w2", "w3", "w4", "w5", "w6", "w7", "w8", "w9", "w10", "w11", "w12", "w13", "w14", "w15", "w16", "w17", "w18", "w19", "w20", "w21", "w22", @@ -1223,7 +1225,12 @@ const char *const AArch64TargetInfo::GCCRegNames[] = { // SVE predicate-as-counter registers "pn0", "pn1", "pn2", "pn3", "pn4", "pn5", "pn6", "pn7", "pn8", - "pn9", "pn10", "pn11", "pn12", "pn13", "pn14", "pn15" + "pn9", "pn10", "pn11", "pn12", "pn13", "pn14", "pn15", + + // SME registers + "za", "zt0", + + // clang-format on }; ArrayRef AArch64TargetInfo::getGCCRegNames() const { diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp index 22e583021515..ae1a4ba78826 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/Arch/Sparc.cpp @@ -178,4 +178,85 @@ void sparc::getSparcTargetFeatures(const Driver &D, const ArgList &Args, else Features.push_back("-hard-quad-float"); } + + if (Args.hasArg(options::OPT_ffixed_g1)) + Features.push_back("+reserve-g1"); + + if (Args.hasArg(options::OPT_ffixed_g2)) + Features.push_back("+reserve-g2"); + + if (Args.hasArg(options::OPT_ffixed_g3)) + Features.push_back("+reserve-g3"); + + if (Args.hasArg(options::OPT_ffixed_g4)) + Features.push_back("+reserve-g4"); + + if (Args.hasArg(options::OPT_ffixed_g5)) + Features.push_back("+reserve-g5"); + + if (Args.hasArg(options::OPT_ffixed_g6)) + Features.push_back("+reserve-g6"); + + if (Args.hasArg(options::OPT_ffixed_g7)) + Features.push_back("+reserve-g7"); + + if (Args.hasArg(options::OPT_ffixed_o0)) + Features.push_back("+reserve-o0"); + + if (Args.hasArg(options::OPT_ffixed_o1)) + Features.push_back("+reserve-o1"); + + if (Args.hasArg(options::OPT_ffixed_o2)) + Features.push_back("+reserve-o2"); + + if (Args.hasArg(options::OPT_ffixed_o3)) + Features.push_back("+reserve-o3"); + + if (Args.hasArg(options::OPT_ffixed_o4)) + Features.push_back("+reserve-o4"); + + if (Args.hasArg(options::OPT_ffixed_o5)) + Features.push_back("+reserve-o5"); + + if (Args.hasArg(options::OPT_ffixed_l0)) + Features.push_back("+reserve-l0"); + + if (Args.hasArg(options::OPT_ffixed_l1)) + Features.push_back("+reserve-l1"); + + if (Args.hasArg(options::OPT_ffixed_l2)) + Features.push_back("+reserve-l2"); + + if (Args.hasArg(options::OPT_ffixed_l3)) + Features.push_back("+reserve-l3"); + + if (Args.hasArg(options::OPT_ffixed_l4)) + Features.push_back("+reserve-l4"); + + if (Args.hasArg(options::OPT_ffixed_l5)) + Features.push_back("+reserve-l5"); + + if (Args.hasArg(options::OPT_ffixed_l6)) + Features.push_back("+reserve-l6"); + + if (Args.hasArg(options::OPT_ffixed_l7)) + Features.push_back("+reserve-l7"); + + if (Args.hasArg(options::OPT_ffixed_i0)) + Features.push_back("+reserve-i0"); + + if (Args.hasArg(options::OPT_ffixed_i1)) + Features.push_back("+reserve-i1"); + + if (Args.hasArg(options::OPT_ffixed_i2)) + Features.push_back("+reserve-i2"); + + if (Args.hasArg(options::OPT_ffixed_i3)) + Features.push_back("+reserve-i3"); + + if (Args.hasArg(options::OPT_ffixed_i4)) + Features.push_back("+reserve-i4"); + + if (Args.hasArg(options::OPT_ffixed_i5)) + Features.push_back("+reserve-i5"); } diff --git a/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp b/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp index b904e0e56d9e..573919798870 100644 --- a/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp +++ b/contrib/llvm-project/clang/lib/Format/UnwrappedLineParser.cpp @@ -2515,7 +2515,7 @@ bool UnwrappedLineParser::parseParens(TokenType AmpAmpTokenType) { parseChildBlock(); break; case tok::r_paren: - if (!MightBeStmtExpr && + if (!MightBeStmtExpr && !Line->InMacroBody && Style.RemoveParentheses > FormatStyle::RPS_Leave) { const auto *Prev = LeftParen->Previous; const auto *Next = Tokens->peekNextToken(); diff --git a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp index 4efcb3590355..0d9c087ed0cd 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp @@ -14062,7 +14062,7 @@ inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS, Expr::EvalResult EVResult; if (RHS.get()->EvaluateAsInt(EVResult, Context)) { llvm::APSInt Result = EVResult.Val.getInt(); - if ((getLangOpts().Bool && !RHS.get()->getType()->isBooleanType() && + if ((getLangOpts().CPlusPlus && !RHS.get()->getType()->isBooleanType() && !RHS.get()->getExprLoc().isMacroID()) || (Result != 0 && Result != 1)) { Diag(Loc, diag::warn_logical_instead_of_bitwise) diff --git a/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp b/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp index 5ee6092bb9bb..e122cea50f72 100644 --- a/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp +++ b/contrib/llvm-project/clang/tools/clang-format/ClangFormat.cpp @@ -399,7 +399,8 @@ class ClangFormatDiagConsumer : public DiagnosticConsumer { }; // Returns true on error. -static bool format(StringRef FileName, bool IsSTDIN) { +static bool format(StringRef FileName) { + const bool IsSTDIN = FileName == "-"; if (!OutputXML && Inplace && IsSTDIN) { errs() << "error: cannot use -i when reading from stdin.\n"; return false; @@ -545,24 +546,25 @@ static void PrintVersion(raw_ostream &OS) { } // Dump the configuration. -static int dumpConfig(bool IsSTDIN) { +static int dumpConfig() { std::unique_ptr Code; - - // `FileNames` must have at least "-" in it even if no file was specified. - assert(!FileNames.empty()); - - // Read in the code in case the filename alone isn't enough to detect the - // language. - ErrorOr> CodeOrErr = - MemoryBuffer::getFileOrSTDIN(FileNames[0]); - if (std::error_code EC = CodeOrErr.getError()) { - llvm::errs() << EC.message() << "\n"; - return 1; + // We can't read the code to detect the language if there's no file name. + if (!FileNames.empty()) { + // Read in the code in case the filename alone isn't enough to detect the + // language. + ErrorOr> CodeOrErr = + MemoryBuffer::getFileOrSTDIN(FileNames[0]); + if (std::error_code EC = CodeOrErr.getError()) { + llvm::errs() << EC.message() << "\n"; + return 1; + } + Code = std::move(CodeOrErr.get()); } - Code = std::move(CodeOrErr.get()); - llvm::Expected FormatStyle = - clang::format::getStyle(Style, IsSTDIN ? AssumeFileName : FileNames[0], + clang::format::getStyle(Style, + FileNames.empty() || FileNames[0] == "-" + ? AssumeFileName + : FileNames[0], FallbackStyle, Code ? Code->getBuffer() : ""); if (!FormatStyle) { llvm::errs() << llvm::toString(FormatStyle.takeError()) << "\n"; @@ -682,11 +684,8 @@ int main(int argc, const char **argv) { return 0; } - if (FileNames.empty()) - FileNames.push_back("-"); - if (DumpConfig) - return dumpConfig(FileNames[0] == "-"); + return dumpConfig(); if (!Files.empty()) { std::ifstream ExternalFileOfFiles{std::string(Files)}; @@ -699,7 +698,10 @@ int main(int argc, const char **argv) { errs() << "Clang-formating " << LineNo << " files\n"; } - if (FileNames.size() != 1 && + if (FileNames.empty()) + return clang::format::format("-"); + + if (FileNames.size() > 1 && (!Offsets.empty() || !Lengths.empty() || !LineRanges.empty())) { errs() << "error: -offset, -length and -lines can only be used for " "single file.\n"; @@ -709,14 +711,13 @@ int main(int argc, const char **argv) { unsigned FileNo = 1; bool Error = false; for (const auto &FileName : FileNames) { - const bool IsSTDIN = FileName == "-"; - if (!IsSTDIN && isIgnored(FileName)) + if (isIgnored(FileName)) continue; if (Verbose) { errs() << "Formatting [" << FileNo++ << "/" << FileNames.size() << "] " << FileName << "\n"; } - Error |= clang::format::format(FileName, IsSTDIN); + Error |= clang::format::format(FileName); } return Error ? 1 : 0; } diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp b/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp index 85b796bd6349..3af26e9f64c9 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/dfsan_custom.cpp @@ -55,6 +55,10 @@ using namespace __dfsan; #define DECLARE_WEAK_INTERCEPTOR_HOOK(f, ...) \ SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE void f(__VA_ARGS__); +#define WRAPPER_ALIAS(fun, real) \ + SANITIZER_INTERFACE_ATTRIBUTE void __dfsw_##fun() ALIAS(__dfsw_##real); \ + SANITIZER_INTERFACE_ATTRIBUTE void __dfso_##fun() ALIAS(__dfso_##real); + // Async-safe, non-reentrant spin lock. class SignalSpinLocker { public: @@ -1197,16 +1201,20 @@ char *__dfso_strcpy(char *dest, const char *src, dfsan_label dst_label, *ret_origin = dst_origin; return ret; } +} -static long int dfsan_strtol(const char *nptr, char **endptr, int base, - char **tmp_endptr) { +template +static ALWAYS_INLINE auto dfsan_strtol_impl( + Fn real, const char *nptr, char **endptr, int base, + char **tmp_endptr) -> decltype(real(nullptr, nullptr, 0)) { assert(tmp_endptr); - long int ret = strtol(nptr, tmp_endptr, base); + auto ret = real(nptr, tmp_endptr, base); if (endptr) *endptr = *tmp_endptr; return ret; } +extern "C" { static void dfsan_strtolong_label(const char *nptr, const char *tmp_endptr, dfsan_label base_label, dfsan_label *ret_label) { @@ -1236,30 +1244,6 @@ static void dfsan_strtolong_origin(const char *nptr, const char *tmp_endptr, } } -SANITIZER_INTERFACE_ATTRIBUTE -long int __dfsw_strtol(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - long int ret = dfsan_strtol(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long int __dfso_strtol(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - long int ret = dfsan_strtol(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - static double dfsan_strtod(const char *nptr, char **endptr, char **tmp_endptr) { assert(tmp_endptr); double ret = strtod(nptr, tmp_endptr); @@ -1307,108 +1291,40 @@ double __dfso_strtod(const char *nptr, char **endptr, dfsan_label nptr_label, return ret; } -static long long int dfsan_strtoll(const char *nptr, char **endptr, int base, - char **tmp_endptr) { - assert(tmp_endptr); - long long int ret = strtoll(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long int __dfsw_strtoll(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - long long int ret = dfsan_strtoll(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long int __dfso_strtoll(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, - dfsan_origin endptr_origin, - dfsan_origin base_origin, - dfsan_origin *ret_origin) { - char *tmp_endptr; - long long int ret = dfsan_strtoll(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - -static unsigned long int dfsan_strtoul(const char *nptr, char **endptr, - int base, char **tmp_endptr) { - assert(tmp_endptr); - unsigned long int ret = strtoul(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -unsigned long int __dfsw_strtoul(const char *nptr, char **endptr, int base, - dfsan_label nptr_label, dfsan_label endptr_label, - dfsan_label base_label, dfsan_label *ret_label) { - char *tmp_endptr; - unsigned long int ret = dfsan_strtoul(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -unsigned long int __dfso_strtoul( - const char *nptr, char **endptr, int base, dfsan_label nptr_label, - dfsan_label endptr_label, dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - unsigned long int ret = dfsan_strtoul(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} - -static long long unsigned int dfsan_strtoull(const char *nptr, char **endptr, - int base, char **tmp_endptr) { - assert(tmp_endptr); - long long unsigned int ret = strtoull(nptr, tmp_endptr, base); - if (endptr) - *endptr = *tmp_endptr; - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long unsigned int __dfsw_strtoull(const char *nptr, char **endptr, - int base, dfsan_label nptr_label, - dfsan_label endptr_label, - dfsan_label base_label, - dfsan_label *ret_label) { - char *tmp_endptr; - long long unsigned int ret = dfsan_strtoull(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -long long unsigned int __dfso_strtoull( - const char *nptr, char **endptr, int base, dfsan_label nptr_label, - dfsan_label endptr_label, dfsan_label base_label, dfsan_label *ret_label, - dfsan_origin nptr_origin, dfsan_origin endptr_origin, - dfsan_origin base_origin, dfsan_origin *ret_origin) { - char *tmp_endptr; - long long unsigned int ret = dfsan_strtoull(nptr, endptr, base, &tmp_endptr); - dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); - dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, base_origin, - ret_origin); - return ret; -} +WRAPPER_ALIAS(__isoc23_strtod, strtod) + +#define WRAPPER_STRTO(ret_type, fun) \ + SANITIZER_INTERFACE_ATTRIBUTE ret_type __dfsw_##fun( \ + const char *nptr, char **endptr, int base, dfsan_label nptr_label, \ + dfsan_label endptr_label, dfsan_label base_label, \ + dfsan_label *ret_label) { \ + char *tmp_endptr; \ + auto ret = dfsan_strtol_impl(fun, nptr, endptr, base, &tmp_endptr); \ + dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); \ + return ret; \ + } \ + SANITIZER_INTERFACE_ATTRIBUTE ret_type __dfso_##fun( \ + const char *nptr, char **endptr, int base, dfsan_label nptr_label, \ + dfsan_label endptr_label, dfsan_label base_label, \ + dfsan_label *ret_label, dfsan_origin nptr_origin, \ + dfsan_origin endptr_origin, dfsan_origin base_origin, \ + dfsan_origin *ret_origin) { \ + char *tmp_endptr; \ + auto ret = dfsan_strtol_impl(fun, nptr, endptr, base, &tmp_endptr); \ + dfsan_strtolong_label(nptr, tmp_endptr, base_label, ret_label); \ + dfsan_strtolong_origin(nptr, tmp_endptr, base_label, ret_label, \ + base_origin, ret_origin); \ + return ret; \ + } + +WRAPPER_STRTO(long, strtol) +WRAPPER_STRTO(long long, strtoll) +WRAPPER_STRTO(unsigned long, strtoul) +WRAPPER_STRTO(unsigned long long, strtoull) +WRAPPER_ALIAS(__isoc23_strtol, strtol) +WRAPPER_ALIAS(__isoc23_strtoll, strtoll) +WRAPPER_ALIAS(__isoc23_strtoul, strtoul) +WRAPPER_ALIAS(__isoc23_strtoull, strtoull) SANITIZER_INTERFACE_ATTRIBUTE time_t __dfsw_time(time_t *t, dfsan_label t_label, dfsan_label *ret_label) { @@ -2231,7 +2147,7 @@ SANITIZER_INTERFACE_ATTRIBUTE int __dfso_write( *ret_label = 0; return write(fd, buf, count); } -} // namespace __dfsan +} // namespace __dfsan // Type used to extract a dfsan_label with va_arg() typedef int dfsan_label_va; @@ -2866,31 +2782,8 @@ int __dfso_sscanf(char *str, const char *format, dfsan_label str_label, return ret; } -SANITIZER_INTERFACE_ATTRIBUTE -int __dfsw___isoc99_sscanf(char *str, const char *format, dfsan_label str_label, - dfsan_label format_label, dfsan_label *va_labels, - dfsan_label *ret_label, ...) { - va_list ap; - va_start(ap, ret_label); - int ret = scan_buffer(str, ~0ul, format, va_labels, ret_label, nullptr, - nullptr, ap); - va_end(ap); - return ret; -} - -SANITIZER_INTERFACE_ATTRIBUTE -int __dfso___isoc99_sscanf(char *str, const char *format, dfsan_label str_label, - dfsan_label format_label, dfsan_label *va_labels, - dfsan_label *ret_label, dfsan_origin str_origin, - dfsan_origin format_origin, dfsan_origin *va_origins, - dfsan_origin *ret_origin, ...) { - va_list ap; - va_start(ap, ret_origin); - int ret = scan_buffer(str, ~0ul, format, va_labels, ret_label, &str_origin, - ret_origin, ap); - va_end(ap); - return ret; -} +WRAPPER_ALIAS(__isoc99_sscanf, sscanf) +WRAPPER_ALIAS(__isoc23_sscanf, sscanf) static void BeforeFork() { StackDepotLockBeforeFork(); diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt b/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt index c582584d77e4..86a42ee1b4dc 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/done_abilist.txt @@ -270,6 +270,11 @@ fun:strtoul=custom fun:strtoull=custom fun:strcat=custom fun:strncat=custom +fun:__isoc23_strtod=custom +fun:__isoc23_strtol=custom +fun:__isoc23_strtoll=custom +fun:__isoc23_strtoul=custom +fun:__isoc23_strtoull=custom # Functions that produce an output that is computed from the input, but is not # necessarily data dependent. @@ -311,6 +316,7 @@ fun:snprintf=custom # scanf-like fun:sscanf=custom fun:__isoc99_sscanf=custom +fun:__isoc23_sscanf=custom # TODO: custom fun:asprintf=discard diff --git a/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt b/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt index 433092e2b27b..9ffa56a23818 100644 --- a/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt +++ b/contrib/llvm-project/compiler-rt/lib/dfsan/libc_ubuntu1404_abilist.txt @@ -1,3 +1,8 @@ +fun:__isoc23_sscanf=uninstrumented +fun:__isoc23_strtol=uninstrumented +fun:__isoc23_strtoll=uninstrumented +fun:__isoc23_strtoul=uninstrumented +fun:__isoc23_strtoull=uninstrumented fun:_Exit=uninstrumented fun:_IO_adjust_column=uninstrumented fun:_IO_adjust_wcolumn=uninstrumented diff --git a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c index 9f46a98d78ac..002bec164d7e 100644 --- a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c +++ b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingPlatformAIX.c @@ -195,6 +195,8 @@ static const int dummy_name[0] COMPILER_RT_SECTION( COMPILER_RT_SEG INSTR_PROF_NAME_SECT_NAME); static int dummy_vnds[0] COMPILER_RT_SECTION( COMPILER_RT_SEG INSTR_PROF_VNODES_SECT_NAME); +static int dummy_orderfile[0] COMPILER_RT_SECTION( + COMPILER_RT_SEG INSTR_PROF_ORDERFILE_SECT_NAME); // To avoid GC'ing of the dummy variables by the linker, reference them in an // array and reference the array in the runtime registration code @@ -206,7 +208,7 @@ static int dummy_vnds[0] COMPILER_RT_SECTION( COMPILER_RT_VISIBILITY void *__llvm_profile_keep[] = {(void *)&dummy_cnts, (void *)&dummy_bits, (void *)&dummy_data, (void *)&dummy_name, - (void *)&dummy_vnds}; + (void *)&dummy_vnds, (void *)&dummy_orderfile}; #ifdef __GNUC__ #pragma GCC diagnostic pop #endif diff --git a/contrib/llvm-project/libcxx/include/print b/contrib/llvm-project/libcxx/include/print index 7f2b5bac3dcf..543a540ee4f2 100644 --- a/contrib/llvm-project/libcxx/include/print +++ b/contrib/llvm-project/libcxx/include/print @@ -32,6 +32,7 @@ namespace std { */ #include <__assert> // all public C++ headers provide the assertion handler +#include <__availability> #include <__concepts/same_as.h> #include <__config> #include <__system_error/system_error.h> @@ -43,10 +44,6 @@ namespace std { #include #include -#if __has_include() -# include -#endif - #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) # pragma GCC system_header #endif @@ -68,7 +65,8 @@ _LIBCPP_EXPORTED_FROM_ABI bool __is_windows_terminal(FILE* __stream); // Note the function is only implemented on the Windows platform. _LIBCPP_EXPORTED_FROM_ABI void __write_to_windows_console(FILE* __stream, wstring_view __view); # endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS - +#elif __has_include() +_LIBCPP_EXPORTED_FROM_ABI bool __is_posix_terminal(FILE* __stream); #endif // _LIBCPP_WIN32API #if _LIBCPP_STD_VER >= 23 @@ -195,15 +193,17 @@ inline constexpr bool __use_unicode_execution_charset = _MSVC_EXECUTION_CHARACTE inline constexpr bool __use_unicode_execution_charset = true; # endif -_LIBCPP_HIDE_FROM_ABI inline bool __is_terminal(FILE* __stream) { +_LIBCPP_HIDE_FROM_ABI inline bool __is_terminal([[maybe_unused]] FILE* __stream) { // The macro _LIBCPP_TESTING_PRINT_IS_TERMINAL is used to change // the behavior in the test. This is not part of the public API. # ifdef _LIBCPP_TESTING_PRINT_IS_TERMINAL return _LIBCPP_TESTING_PRINT_IS_TERMINAL(__stream); +# elif _LIBCPP_AVAILABILITY_HAS_PRINT == 0 + return false; # elif defined(_LIBCPP_WIN32API) return std::__is_windows_terminal(__stream); # elif __has_include() - return isatty(fileno(__stream)); + return std::__is_posix_terminal(__stream); # else # error "Provide a way to determine whether a FILE* is a terminal" # endif diff --git a/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in b/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in new file mode 100644 index 000000000000..e332d70cc163 --- /dev/null +++ b/contrib/llvm-project/libcxx/modules/CMakeLists.txt.in @@ -0,0 +1,88 @@ +cmake_minimum_required(VERSION 3.26) + +project(libc++-modules LANGUAGES CXX) + +# Enable CMake's module support +if(CMAKE_VERSION VERSION_LESS "3.28.0") + if(CMAKE_VERSION VERSION_LESS "3.27.0") + set(CMAKE_EXPERIMENTAL_CXX_MODULE_CMAKE_API "2182bf5c-ef0d-489a-91da-49dbc3090d2a") + else() + set(CMAKE_EXPERIMENTAL_CXX_MODULE_CMAKE_API "aa1f7df0-828a-4fcd-9afc-2dc80491aca7") + endif() + set(CMAKE_EXPERIMENTAL_CXX_MODULE_DYNDEP 1) +else() + cmake_policy(VERSION 3.28) +endif() + +# Default to C++ extensions being off. Libc++'s modules support have trouble +# with extensions right now. +set(CMAKE_CXX_EXTENSIONS OFF) + +# Propagates the CMake options to the modules. +# +# This uses the std module hard-coded since the std.compat module does not +# depend on these flags. +macro(compile_define_if_not condition def) + if (NOT ${condition}) + target_compile_definitions(std PRIVATE ${def}) + endif() +endmacro() +macro(compile_define_if condition def) + if (${condition}) + target_compile_definitions(std PRIVATE ${def}) + endif() +endmacro() + +### STD + +add_library(std) +target_sources(std + PUBLIC FILE_SET cxx_modules TYPE CXX_MODULES FILES + std.cppm +) + +target_include_directories(std SYSTEM PRIVATE @LIBCXX_CONFIGURED_INCLUDE_DIRS@) + +if (NOT @LIBCXX_ENABLE_EXCEPTIONS@) + target_compile_options(std PUBLIC -fno-exceptions) +endif() + +target_compile_options(std + PUBLIC + -nostdinc++ + -Wno-reserved-module-identifier + -Wno-reserved-user-defined-literal + @LIBCXX_COMPILE_FLAGS@ +) +set_target_properties(std + PROPERTIES + OUTPUT_NAME "c++std" +) + +### STD.COMPAT + +add_library(std.compat) +target_sources(std.compat + PUBLIC FILE_SET cxx_modules TYPE CXX_MODULES FILES + std.compat.cppm +) + +target_include_directories(std.compat SYSTEM PRIVATE @LIBCXX_CONFIGURED_INCLUDE_DIRS@) + +if (NOT @LIBCXX_ENABLE_EXCEPTIONS@) + target_compile_options(std.compat PUBLIC -fno-exceptions) +endif() + +target_compile_options(std.compat + PUBLIC + -nostdinc++ + -Wno-reserved-module-identifier + -Wno-reserved-user-defined-literal + -fmodule-file=std=${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/std.dir/std.pcm + @LIBCXX_COMPILE_FLAGS@ +) +set_target_properties(std.compat + PROPERTIES + OUTPUT_NAME "c++std.compat" +) +add_dependencies(std.compat std) diff --git a/contrib/llvm-project/libcxx/modules/std/ostream.inc b/contrib/llvm-project/libcxx/modules/std/ostream.inc index 8fcbfb4bdc18..0e0e2d54fe6b 100644 --- a/contrib/llvm-project/libcxx/modules/std/ostream.inc +++ b/contrib/llvm-project/libcxx/modules/std/ostream.inc @@ -33,8 +33,10 @@ export namespace std { using std::println; using std::vprint_nonunicode; +# ifndef _LIBCPP_HAS_NO_UNICODE using std::vprint_unicode; -# endif // _LIBCPP_STD_VER >= 23 +# endif // _LIBCPP_HAS_NO_UNICODE +# endif // _LIBCPP_STD_VER >= 23 #endif // _LIBCPP_HAS_NO_LOCALIZATION } // namespace std diff --git a/contrib/llvm-project/libcxx/src/print.cpp b/contrib/llvm-project/libcxx/src/print.cpp index 3692187a5954..8fa59fdd097b 100644 --- a/contrib/llvm-project/libcxx/src/print.cpp +++ b/contrib/llvm-project/libcxx/src/print.cpp @@ -8,22 +8,26 @@ #include <__config> -#if defined(_LIBCPP_WIN32API) +#include +#include + +#include <__system_error/system_error.h> -# include -# include +#include "filesystem/error.h" +#if defined(_LIBCPP_WIN32API) # define WIN32_LEAN_AND_MEAN # define NOMINMAX # include # include - -# include <__system_error/system_error.h> - -# include "filesystem/error.h" +#elif __has_include() +# include +#endif _LIBCPP_BEGIN_NAMESPACE_STD +#if defined(_LIBCPP_WIN32API) + _LIBCPP_EXPORTED_FROM_ABI bool __is_windows_terminal(FILE* __stream) { // Note the Standard does this in one call, but it's unclear whether // an invalid handle is allowed when calling GetConsoleMode. @@ -52,6 +56,9 @@ __write_to_windows_console([[maybe_unused]] FILE* __stream, [[maybe_unused]] wst } # endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS -_LIBCPP_END_NAMESPACE_STD +#elif __has_include() // !_LIBCPP_WIN32API -#endif // !_LIBCPP_WIN32API +_LIBCPP_EXPORTED_FROM_ABI bool __is_posix_terminal(FILE* __stream) { return isatty(fileno(__stream)); } +#endif + +_LIBCPP_END_NAMESPACE_STD diff --git a/contrib/llvm-project/lld/COFF/Driver.cpp b/contrib/llvm-project/lld/COFF/Driver.cpp index e0afb6b18805..22ee2f133be9 100644 --- a/contrib/llvm-project/lld/COFF/Driver.cpp +++ b/contrib/llvm-project/lld/COFF/Driver.cpp @@ -1825,7 +1825,15 @@ void LinkerDriver::linkerMain(ArrayRef argsArr) { } } else { config->repro = false; - config->timestamp = time(nullptr); + if (std::optional epoch = + Process::GetEnv("SOURCE_DATE_EPOCH")) { + StringRef value(*epoch); + if (value.getAsInteger(0, config->timestamp)) + fatal(Twine("invalid SOURCE_DATE_EPOCH timestamp: ") + value + + ". Expected 32-bit integer"); + } else { + config->timestamp = time(nullptr); + } } // Handle /alternatename diff --git a/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp b/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp index ab2ec5b447d0..05fd38fb753f 100644 --- a/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp +++ b/contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp @@ -36,6 +36,8 @@ public: bool usesOnlyLowPageBits(RelType type) const override; void relocate(uint8_t *loc, const Relocation &rel, uint64_t val) const override; + bool relaxOnce(int pass) const override; + void finalizeRelax(int passes) const override; }; } // end anonymous namespace @@ -465,8 +467,9 @@ RelExpr LoongArch::getRelExpr(const RelType type, const Symbol &s, case R_LARCH_TLS_GD_HI20: return R_TLSGD_GOT; case R_LARCH_RELAX: - // LoongArch linker relaxation is not implemented yet. - return R_NONE; *** 2151 LINES SKIPPED *** From nobody Sat Apr 20 10:34:37 2024 X-Original-To: dev-commits-src-branches@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 4VM7DZ2gJlz5HWRR; Sat, 20 Apr 2024 10:34:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7DZ1lt5z4Swt; Sat, 20 Apr 2024 10:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609278; 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=W/daDKkIo3HQL3nbI0StIp+K1UgyjLG7tIzbHYP+amI=; b=r5ubTRp4zPhlwalQ6um4eMD66YNRLyeAMleI8DXcQtXjv3mZwPNLmyMmvnsaKCMTqN49Xj AAeq6jwi1rhoEYJ4DpXGvSxy5Aj6HgEIo0nBkwozXpobeM84EFRb58N7K+hwwXd1kKwMIb Z6yUsfFQyHBAe9qUt/K9pbP4gLcWjpAgDyQ8tq/G9MZWTPa7ttHgdAnm+HWj3xbH/S2jeV ijCVrVw5sA2vqC7dZDC87hgiFEP/hQyf5GHjUpw0gEK76NOUGqmau9fRUEuRi6RF+DpRs0 A0nJeIcTV/E/TC+3311VGH/4QOhJxAZ5+Dk1QlGCVZTxRjzMpeP0iRarp1kJ0A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609278; a=rsa-sha256; cv=none; b=WryhOQPcz0ZnHt497LI1/j6VRpMJ8QIAJjfjVbfrfc5NXB/UzxdJbJ0WZ2Z4KJCKSRrjyR ICRcmBj1k9FP0gZsx7NbAKNdHFb6rjyRtctpk9FKIUda5EvJhuiqPIDxa0yFC1Je4GkkFE f8EWyosaSMr02oZASMBA7zJXQxyko3We8M8Pj8qWow5IUlxCc3iFDy0r3eMWZLSZ9tclw1 qLtlrJNHgmQF7IVdMEAHyR2UFG2ksA04+4NaxYt8WC7vchhrakFITt+2JWqiCxX01k2o8V M3+bFM47lNIHkpbiawL8D7MZu95/zqMF8X57MMRYxjmXSrrZqUOZc5SEq/eRQg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609278; 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=W/daDKkIo3HQL3nbI0StIp+K1UgyjLG7tIzbHYP+amI=; b=h71iXkkG2oKqyjzzSs0RRwPVdc4ECg/tmLGCnauQ539xAKCnE5H+frXrZ7c+e20p+iG495 8XajCAXAk19z/XHshddIu3DttSpwH6T4LEvRFza1PZwTh9cldyBFgFbgk3tC0ZPdjuixxS HjYuSl4YkEdfkx+Ql8ufTy0wkxsmbPd19bU6y4GVs/qQDDdzKKBnLKNwGi5CsX2wjmK0NQ Fb8Tg8aHUdIWHQ9pYS4ml4J8VNJONVLqnDXFzTqiujdv42PQH6WNZGuSm5eehxlvKhd6BZ mRZrjC8C2Bg+irRL7VbiTDHcN2LcnPJsb+QsJM8vDPiscmIki/q4vf3hP7Dpdg== 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 4VM7DZ1LpqzYr3; Sat, 20 Apr 2024 10:34:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYcZP013917; Sat, 20 Apr 2024 10:34:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYbEi013914; Sat, 20 Apr 2024 10:34:37 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:37 GMT Message-Id: <202404201034.43KAYbEi013914@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: 83e37ae556b2 - stable/13 - Merge llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 83e37ae556b23e8e91169c618618d28d83ddb61b Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=83e37ae556b23e8e91169c618618d28d83ddb61b commit 83e37ae556b23e8e91169c618618d28d83ddb61b Author: Dimitry Andric AuthorDate: 2024-02-07 14:58:02 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:46 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc2-0-gc6c86965d967. PR: 276104 MFC after: 1 month (cherry picked from commit b3edf4467982447620505a28fc82e38a414c07dc) --- .../llvm-project/clang/include/clang/AST/Type.h | 3 + .../clang/include/clang/Basic/AttrDocs.td | 5 +- .../clang/include/clang/Basic/BuiltinsAMDGPU.def | 62 +++ .../clang/include/clang/Basic/CodeGenOptions.def | 3 + .../include/clang/Basic/DiagnosticCommonKinds.td | 2 +- .../clang/include/clang/Basic/DiagnosticDocs.td | 9 + .../include/clang/Basic/DiagnosticSemaKinds.td | 6 + .../clang/include/clang/Basic/LangOptions.def | 1 + .../clang/include/clang/Driver/Options.td | 13 + .../clang/include/clang/Format/Format.h | 43 +- .../clang/include/clang/Lex/Preprocessor.h | 11 +- .../llvm-project/clang/include/clang/Sema/Lookup.h | 3 +- .../clang/include/clang/Serialization/ASTReader.h | 6 + contrib/llvm-project/clang/lib/AST/ASTContext.cpp | 20 +- .../llvm-project/clang/lib/AST/ExprConstant.cpp | 9 +- .../llvm-project/clang/lib/AST/ItaniumMangle.cpp | 25 +- .../llvm-project/clang/lib/AST/JSONNodeDumper.cpp | 3 + contrib/llvm-project/clang/lib/AST/ODRHash.cpp | 49 +- .../llvm-project/clang/lib/AST/TemplateBase.cpp | 3 +- .../llvm-project/clang/lib/AST/TextNodeDumper.cpp | 3 + contrib/llvm-project/clang/lib/AST/Type.cpp | 15 +- contrib/llvm-project/clang/lib/AST/TypePrinter.cpp | 2 + .../clang/lib/Basic/Targets/AArch64.cpp | 23 + .../llvm-project/clang/lib/Basic/Targets/AArch64.h | 1 + .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 1 + .../llvm-project/clang/lib/CodeGen/CGBuiltin.cpp | 177 +++++++- contrib/llvm-project/clang/lib/CodeGen/CGExpr.cpp | 17 +- .../clang/lib/CodeGen/CoverageMappingGen.cpp | 6 +- .../clang/lib/CodeGen/Targets/RISCV.cpp | 21 +- contrib/llvm-project/clang/lib/Driver/Driver.cpp | 6 +- .../clang/lib/Driver/ToolChains/Clang.cpp | 15 + .../clang/lib/Driver/ToolChains/CommonArgs.cpp | 52 +++ .../clang/lib/Driver/ToolChains/CommonArgs.h | 3 + contrib/llvm-project/clang/lib/Format/Format.cpp | 23 +- .../clang/lib/Format/TokenAnnotator.cpp | 11 +- .../llvm-project/clang/lib/Lex/PPDirectives.cpp | 2 +- .../llvm-project/clang/lib/Lex/PPExpressions.cpp | 4 +- .../llvm-project/clang/lib/Sema/SemaChecking.cpp | 55 ++- .../llvm-project/clang/lib/Sema/SemaConcept.cpp | 8 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 3 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 6 +- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 44 +- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 44 +- contrib/llvm-project/clang/lib/Sema/SemaType.cpp | 21 +- .../clang/lib/Serialization/ASTReader.cpp | 3 + .../clang/lib/Serialization/ASTReaderDecl.cpp | 38 +- .../clang/lib/Serialization/ASTWriter.cpp | 8 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 13 +- .../clang/lib/StaticAnalyzer/Core/Environment.cpp | 8 +- .../compiler-rt/lib/builtins/i386/chkstk.S | 2 - .../compiler-rt/lib/builtins/x86_64/chkstk.S | 2 - .../lib/profile/InstrProfilingPlatformWindows.c | 2 +- .../sanitizer_symbolizer_report.cpp | 4 +- .../libcxx/include/__algorithm/copy_move_common.h | 5 + .../libcxx/include/__algorithm/equal.h | 5 + .../libcxx/include/__algorithm/equal_range.h | 5 + .../llvm-project/libcxx/include/__algorithm/fold.h | 5 + .../libcxx/include/__algorithm/in_found_result.h | 5 + .../libcxx/include/__algorithm/in_fun_result.h | 5 + .../libcxx/include/__algorithm/in_in_out_result.h | 5 + .../libcxx/include/__algorithm/in_in_result.h | 5 + .../libcxx/include/__algorithm/in_out_out_result.h | 5 + .../libcxx/include/__algorithm/includes.h | 5 + .../libcxx/include/__algorithm/next_permutation.h | 5 + .../libcxx/include/__algorithm/nth_element.h | 5 + .../libcxx/include/__algorithm/partial_sort.h | 5 + .../libcxx/include/__algorithm/partial_sort_copy.h | 5 + .../libcxx/include/__algorithm/partition.h | 5 + .../libcxx/include/__algorithm/prev_permutation.h | 5 + .../include/__algorithm/pstl_any_all_none_of.h | 5 + .../pstl_backends/cpu_backends/transform_reduce.h | 5 + .../libcxx/include/__algorithm/pstl_copy.h | 5 + .../libcxx/include/__algorithm/pstl_count.h | 5 + .../libcxx/include/__algorithm/pstl_equal.h | 5 + .../libcxx/include/__algorithm/pstl_fill.h | 5 + .../libcxx/include/__algorithm/pstl_find.h | 5 + .../libcxx/include/__algorithm/pstl_for_each.h | 5 + .../libcxx/include/__algorithm/pstl_generate.h | 5 + .../include/__algorithm/pstl_is_partitioned.h | 5 + .../libcxx/include/__algorithm/pstl_merge.h | 5 + .../libcxx/include/__algorithm/pstl_move.h | 5 + .../libcxx/include/__algorithm/pstl_replace.h | 5 + .../libcxx/include/__algorithm/pstl_rotate_copy.h | 5 + .../libcxx/include/__algorithm/pstl_sort.h | 5 + .../libcxx/include/__algorithm/pstl_stable_sort.h | 5 + .../libcxx/include/__algorithm/pstl_transform.h | 5 + .../libcxx/include/__algorithm/ranges_all_of.h | 5 + .../libcxx/include/__algorithm/ranges_any_of.h | 5 + .../include/__algorithm/ranges_binary_search.h | 5 + .../libcxx/include/__algorithm/ranges_clamp.h | 5 + .../libcxx/include/__algorithm/ranges_contains.h | 5 + .../libcxx/include/__algorithm/ranges_copy.h | 5 + .../include/__algorithm/ranges_copy_backward.h | 5 + .../libcxx/include/__algorithm/ranges_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_copy_n.h | 5 + .../libcxx/include/__algorithm/ranges_count.h | 5 + .../libcxx/include/__algorithm/ranges_count_if.h | 5 + .../libcxx/include/__algorithm/ranges_ends_with.h | 5 + .../libcxx/include/__algorithm/ranges_equal.h | 5 + .../include/__algorithm/ranges_equal_range.h | 5 + .../libcxx/include/__algorithm/ranges_fill.h | 5 + .../libcxx/include/__algorithm/ranges_fill_n.h | 5 + .../libcxx/include/__algorithm/ranges_find.h | 5 + .../libcxx/include/__algorithm/ranges_find_end.h | 5 + .../include/__algorithm/ranges_find_first_of.h | 5 + .../libcxx/include/__algorithm/ranges_find_if.h | 5 + .../include/__algorithm/ranges_find_if_not.h | 5 + .../libcxx/include/__algorithm/ranges_for_each.h | 5 + .../libcxx/include/__algorithm/ranges_for_each_n.h | 5 + .../libcxx/include/__algorithm/ranges_generate.h | 5 + .../libcxx/include/__algorithm/ranges_generate_n.h | 5 + .../libcxx/include/__algorithm/ranges_includes.h | 5 + .../include/__algorithm/ranges_inplace_merge.h | 5 + .../libcxx/include/__algorithm/ranges_is_heap.h | 5 + .../include/__algorithm/ranges_is_heap_until.h | 5 + .../include/__algorithm/ranges_is_partitioned.h | 5 + .../include/__algorithm/ranges_is_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_is_sorted.h | 5 + .../include/__algorithm/ranges_is_sorted_until.h | 5 + .../include/__algorithm/ranges_iterator_concept.h | 5 + .../__algorithm/ranges_lexicographical_compare.h | 5 + .../include/__algorithm/ranges_lower_bound.h | 5 + .../libcxx/include/__algorithm/ranges_make_heap.h | 5 + .../include/__algorithm/ranges_max_element.h | 5 + .../libcxx/include/__algorithm/ranges_merge.h | 5 + .../include/__algorithm/ranges_min_element.h | 5 + .../include/__algorithm/ranges_minmax_element.h | 5 + .../libcxx/include/__algorithm/ranges_mismatch.h | 5 + .../libcxx/include/__algorithm/ranges_move.h | 5 + .../include/__algorithm/ranges_move_backward.h | 5 + .../include/__algorithm/ranges_next_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_none_of.h | 5 + .../include/__algorithm/ranges_nth_element.h | 5 + .../include/__algorithm/ranges_partial_sort.h | 5 + .../include/__algorithm/ranges_partial_sort_copy.h | 5 + .../libcxx/include/__algorithm/ranges_partition.h | 5 + .../include/__algorithm/ranges_partition_copy.h | 5 + .../include/__algorithm/ranges_partition_point.h | 5 + .../libcxx/include/__algorithm/ranges_pop_heap.h | 5 + .../include/__algorithm/ranges_prev_permutation.h | 5 + .../libcxx/include/__algorithm/ranges_push_heap.h | 5 + .../libcxx/include/__algorithm/ranges_remove.h | 5 + .../include/__algorithm/ranges_remove_copy.h | 5 + .../include/__algorithm/ranges_remove_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_remove_if.h | 5 + .../libcxx/include/__algorithm/ranges_replace.h | 5 + .../include/__algorithm/ranges_replace_copy.h | 5 + .../include/__algorithm/ranges_replace_copy_if.h | 5 + .../libcxx/include/__algorithm/ranges_replace_if.h | 5 + .../include/__algorithm/ranges_reverse_copy.h | 5 + .../libcxx/include/__algorithm/ranges_rotate.h | 5 + .../include/__algorithm/ranges_rotate_copy.h | 5 + .../libcxx/include/__algorithm/ranges_sample.h | 5 + .../libcxx/include/__algorithm/ranges_search_n.h | 5 + .../include/__algorithm/ranges_set_difference.h | 6 + .../include/__algorithm/ranges_set_intersection.h | 6 + .../__algorithm/ranges_set_symmetric_difference.h | 6 + .../libcxx/include/__algorithm/ranges_set_union.h | 5 + .../libcxx/include/__algorithm/ranges_shuffle.h | 5 + .../libcxx/include/__algorithm/ranges_sort.h | 5 + .../libcxx/include/__algorithm/ranges_sort_heap.h | 5 + .../include/__algorithm/ranges_stable_partition.h | 5 + .../include/__algorithm/ranges_stable_sort.h | 5 + .../include/__algorithm/ranges_starts_with.h | 5 + .../include/__algorithm/ranges_swap_ranges.h | 5 + .../libcxx/include/__algorithm/ranges_transform.h | 5 + .../libcxx/include/__algorithm/ranges_unique.h | 5 + .../include/__algorithm/ranges_unique_copy.h | 5 + .../libcxx/include/__algorithm/remove.h | 5 + .../libcxx/include/__algorithm/remove_if.h | 5 + .../libcxx/include/__algorithm/reverse.h | 5 + .../libcxx/include/__algorithm/rotate.h | 5 + .../libcxx/include/__algorithm/set_difference.h | 5 + .../libcxx/include/__algorithm/set_intersection.h | 5 + .../include/__algorithm/set_symmetric_difference.h | 5 + .../libcxx/include/__algorithm/set_union.h | 5 + .../libcxx/include/__algorithm/shift_left.h | 5 + .../libcxx/include/__algorithm/shift_right.h | 5 + .../llvm-project/libcxx/include/__algorithm/sort.h | 5 + .../libcxx/include/__algorithm/sort_heap.h | 5 + .../libcxx/include/__algorithm/stable_partition.h | 5 + .../libcxx/include/__algorithm/stable_sort.h | 5 + .../libcxx/include/__algorithm/swap_ranges.h | 5 + .../libcxx/include/__algorithm/unique.h | 5 + .../libcxx/include/__algorithm/unique_copy.h | 5 + .../libcxx/include/__algorithm/unwrap_iter.h | 2 +- .../libcxx/include/__algorithm/unwrap_range.h | 5 + contrib/llvm-project/libcxx/include/__config | 9 +- .../include/__filesystem/directory_iterator.h | 5 + .../libcxx/include/__filesystem/path.h | 5 + .../__filesystem/recursive_directory_iterator.h | 5 + .../libcxx/include/__format/format_arg.h | 5 + .../libcxx/include/__format/format_context.h | 5 + .../libcxx/include/__format/format_functions.h | 5 + .../libcxx/include/__format/formatter_output.h | 5 + .../libcxx/include/__format/write_escaped.h | 5 + .../libcxx/include/__functional/function.h | 5 + .../include/__iterator/cpp17_iterator_concepts.h | 5 + .../libcxx/include/__iterator/iterator_with_data.h | 5 + .../__memory/ranges_uninitialized_algorithms.h | 5 + .../libcxx/include/__memory/raw_storage_iterator.h | 5 + .../libcxx/include/__memory/shared_ptr.h | 5 + .../include/__memory/uninitialized_algorithms.h | 5 + .../libcxx/include/__mutex/once_flag.h | 5 + .../libcxx/include/__numeric/pstl_reduce.h | 5 + .../include/__numeric/pstl_transform_reduce.h | 5 + .../llvm-project/libcxx/include/__numeric/reduce.h | 5 + .../include/__numeric/saturation_arithmetic.h | 5 + .../libcxx/include/__numeric/transform_reduce.h | 5 + .../llvm-project/libcxx/include/__ranges/counted.h | 5 + .../libcxx/include/__ranges/drop_while_view.h | 5 + .../libcxx/include/__ranges/elements_view.h | 5 + .../libcxx/include/__ranges/filter_view.h | 5 + .../libcxx/include/__ranges/iota_view.h | 5 + .../libcxx/include/__ranges/join_view.h | 5 + .../libcxx/include/__ranges/lazy_split_view.h | 5 + .../libcxx/include/__ranges/repeat_view.h | 5 + .../libcxx/include/__ranges/reverse_view.h | 5 + .../libcxx/include/__ranges/single_view.h | 5 + .../libcxx/include/__ranges/split_view.h | 5 + .../libcxx/include/__ranges/take_while_view.h | 5 + .../libcxx/include/__ranges/transform_view.h | 5 + .../llvm-project/libcxx/include/__thread/jthread.h | 5 + .../llvm-project/libcxx/include/__thread/thread.h | 5 + contrib/llvm-project/libcxx/include/array | 5 + .../llvm-project/libcxx/include/condition_variable | 5 + .../libcxx/include/experimental/iterator | 5 + contrib/llvm-project/libcxx/include/future | 5 + contrib/llvm-project/libcxx/include/ios | 5 + contrib/llvm-project/libcxx/include/map | 5 + contrib/llvm-project/libcxx/include/ostream | 5 + contrib/llvm-project/libcxx/include/queue | 5 + contrib/llvm-project/libcxx/include/set | 5 + contrib/llvm-project/libcxx/include/stack | 5 + contrib/llvm-project/libcxx/include/string | 7 +- contrib/llvm-project/libcxx/include/strstream | 5 + contrib/llvm-project/libcxx/include/unordered_map | 5 + contrib/llvm-project/libcxx/include/unordered_set | 5 + contrib/llvm-project/libcxx/include/version | 14 +- contrib/llvm-project/libcxx/modules/std/atomic.inc | 2 + contrib/llvm-project/libcxx/modules/std/iosfwd.inc | 2 + contrib/llvm-project/libcxx/modules/std/string.inc | 4 + .../libcxx/modules/std/string_view.inc | 2 + contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 199 ++++++-- contrib/llvm-project/lld/ELF/InputFiles.cpp | 7 +- contrib/llvm-project/lld/ELF/InputSection.cpp | 13 +- contrib/llvm-project/lld/ELF/Relocations.cpp | 50 ++- contrib/llvm-project/lld/ELF/Writer.cpp | 12 +- contrib/llvm-project/lld/docs/ReleaseNotes.rst | 62 +++ .../llvm/include/llvm/Analysis/AliasAnalysis.h | 7 + .../include/llvm/Analysis/BasicAliasAnalysis.h | 14 +- .../include/llvm/Analysis/BranchProbabilityInfo.h | 13 +- .../llvm/include/llvm/Analysis/Loads.h | 12 +- .../llvm/include/llvm/Analysis/VecFuncs.def | 18 +- .../llvm/include/llvm/CodeGen/LivePhysRegs.h | 11 +- .../llvm/include/llvm/CodeGen/MachineBasicBlock.h | 6 + .../llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 119 +++-- .../llvm/include/llvm/Support/X86FoldTablesUtils.h | 11 +- .../include/llvm/Target/TargetInstrPredicate.td | 34 ++ .../llvm/TargetParser/AArch64TargetParser.h | 3 +- .../llvm/include/llvm/TargetParser/Triple.h | 6 +- .../llvm/lib/Analysis/BasicAliasAnalysis.cpp | 6 +- contrib/llvm-project/llvm/lib/Analysis/Lint.cpp | 3 +- contrib/llvm-project/llvm/lib/Analysis/Loads.cpp | 9 +- .../llvm/lib/Analysis/LoopAccessAnalysis.cpp | 53 ++- .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 22 +- .../llvm/lib/CodeGen/BranchFolding.cpp | 6 +- .../lib/ProfileData/Coverage/CoverageMapping.cpp | 240 ++++++++-- .../ProfileData/Coverage/CoverageMappingWriter.cpp | 10 +- .../llvm-project/llvm/lib/Support/RISCVISAInfo.cpp | 3 +- .../Target/AArch64/AArch64ExpandPseudoInsts.cpp | 6 + .../lib/Target/AArch64/AArch64FrameLowering.cpp | 6 +- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 28 +- .../llvm/lib/Target/AArch64/AArch64ISelLowering.h | 4 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.cpp | 20 +- .../llvm/lib/Target/AArch64/AArch64InstrInfo.h | 3 - .../Target/AArch64/AArch64LoadStoreOptimizer.cpp | 229 ---------- .../lib/Target/AArch64/AArch64RegisterInfo.cpp | 35 ++ .../llvm/lib/Target/AArch64/AArch64SMEInstrInfo.td | 22 + .../Target/AArch64/AArch64TargetTransformInfo.cpp | 17 +- .../llvm-project/llvm/lib/Target/AMDGPU/AMDGPU.td | 1 + .../llvm/lib/Target/AMDGPU/AMDGPUGISel.td | 24 + .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp | 330 ++++++++++++++ .../llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h | 10 + .../llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp | 1 + .../Target/AMDGPU/AMDGPUInstructionSelector.cpp | 213 +++++++++ .../lib/Target/AMDGPU/AMDGPUInstructionSelector.h | 13 + .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp | 79 +++- .../llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.h | 1 + .../llvm/lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp | 16 +- .../lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp | 16 + .../lib/Target/AMDGPU/AMDGPUSearchableTables.td | 16 + .../Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp | 142 +++++- .../AMDGPU/Disassembler/AMDGPUDisassembler.cpp | 34 ++ .../llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp | 19 +- .../AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp | 47 ++ .../Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h | 4 + .../llvm/lib/Target/AMDGPU/SIDefines.h | 3 + .../llvm/lib/Target/AMDGPU/SIFoldOperands.cpp | 1 + .../llvm/lib/Target/AMDGPU/SIISelLowering.cpp | 111 ++++- .../llvm/lib/Target/AMDGPU/SIISelLowering.h | 1 + .../llvm/lib/Target/AMDGPU/SIInstrFormats.td | 5 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.h | 8 + .../llvm/lib/Target/AMDGPU/SIInstrInfo.td | 18 +- .../llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | 32 +- .../llvm/lib/Target/AMDGPU/SIRegisterInfo.td | 5 + .../lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 11 + .../llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h | 3 + .../llvm/lib/Target/AMDGPU/VOP1Instructions.td | 93 +++- .../llvm/lib/Target/AMDGPU/VOP3Instructions.td | 53 ++- .../llvm/lib/Target/AMDGPU/VOP3PInstructions.td | 500 ++++++++++++++++++++- .../llvm/lib/Target/AMDGPU/VOPInstructions.td | 32 +- .../llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp | 13 +- .../LoongArch/LoongArchTargetTransformInfo.cpp | 11 +- .../llvm/lib/Target/Mips/MipsAsmPrinter.cpp | 39 -- .../llvm/lib/Target/Mips/MipsAsmPrinter.h | 2 - .../Target/PowerPC/PPCExpandAtomicPseudoInsts.cpp | 14 +- .../llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 13 +- .../llvm-project/llvm/lib/Target/RISCV/RISCV.td | 6 + .../llvm/lib/Target/RISCV/RISCVFeatures.td | 26 +- .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 2 +- .../llvm/lib/Target/RISCV/RISCVInstrInfoZicond.td | 2 - .../llvm/lib/Target/RISCV/RISCVMacroFusion.cpp | 210 --------- .../llvm/lib/Target/RISCV/RISCVMacroFusion.h | 28 -- .../llvm/lib/Target/RISCV/RISCVMacroFusion.td | 93 ++++ .../llvm/lib/Target/RISCV/RISCVSubtarget.cpp | 8 +- .../llvm/lib/Target/RISCV/RISCVSubtarget.h | 8 +- .../llvm/lib/Target/RISCV/RISCVTargetMachine.cpp | 13 +- .../lib/Target/SystemZ/SystemZFrameLowering.cpp | 12 +- .../llvm/lib/Target/X86/X86AsmPrinter.cpp | 1 - .../llvm/lib/Target/X86/X86FrameLowering.cpp | 15 +- .../llvm/lib/Target/X86/X86InstrAVX512.td | 2 +- .../llvm/lib/Target/X86/X86InstrFoldTables.cpp | 11 +- .../llvm/lib/Target/X86/X86InstrInfo.cpp | 35 +- .../llvm/lib/TargetParser/TargetParser.cpp | 1 + .../InstCombine/InstCombineLoadStoreAlloca.cpp | 3 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 3 + .../Transforms/Scalar/ConstraintElimination.cpp | 7 +- .../llvm/lib/Transforms/Scalar/JumpThreading.cpp | 13 +- .../lib/Transforms/Vectorize/LoopVectorize.cpp | 62 ++- .../llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp | 12 +- .../llvm/utils/TableGen/DAGISelMatcherEmitter.cpp | 3 +- .../llvm/utils/TableGen/PredicateExpander.cpp | 34 ++ .../llvm/utils/TableGen/PredicateExpander.h | 4 + .../llvm/utils/TableGen/X86FoldTablesEmitter.cpp | 58 +-- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/libllvm/Makefile | 3 +- usr.bin/clang/clang/clang-driver.cpp | 2 + usr.bin/clang/lld/lld-driver.cpp | 2 + usr.bin/clang/llvm-ar/llvm-ar-driver.cpp | 2 + usr.bin/clang/llvm-cxxfilt/llvm-cxxfilt-driver.cpp | 2 + usr.bin/clang/llvm-dwp/llvm-dwp-driver.cpp | 2 + usr.bin/clang/llvm-nm/llvm-nm-driver.cpp | 2 + usr.bin/clang/llvm-objcopy/llvm-objcopy-driver.cpp | 2 + usr.bin/clang/llvm-objdump/llvm-objdump-driver.cpp | 2 + .../clang/llvm-profdata/llvm-profdata-driver.cpp | 2 + usr.bin/clang/llvm-readobj/llvm-readobj-driver.cpp | 2 + usr.bin/clang/llvm-size/llvm-size-driver.cpp | 2 + .../llvm-symbolizer/llvm-symbolizer-driver.cpp | 2 + 361 files changed, 4552 insertions(+), 1284 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/Type.h b/contrib/llvm-project/clang/include/clang/AST/Type.h index ea425791fc97..6384cf9420b8 100644 --- a/contrib/llvm-project/clang/include/clang/AST/Type.h +++ b/contrib/llvm-project/clang/include/clang/AST/Type.h @@ -3495,6 +3495,9 @@ enum class VectorKind { /// is RISC-V RVV fixed-length data vector RVVFixedLengthData, + + /// is RISC-V RVV fixed-length mask vector + RVVFixedLengthMask, }; /// Represents a GCC generic vector type. This type is created using diff --git a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td index 7e633f8e2635..e02a1201e2ad 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/AttrDocs.td @@ -2424,7 +2424,10 @@ only be a power of 2 between 64 and 65536. For types where LMUL!=1, ``__riscv_v_fixed_vlen`` needs to be scaled by the LMUL of the type before passing to the attribute. -``vbool*_t`` types are not supported at this time. +For ``vbool*_t`` types, ``__riscv_v_fixed_vlen`` needs to be divided by the +number from the type name. For example, ``vbool8_t`` needs to use +``__riscv_v_fixed_vlen`` / 8. If the resulting value is not a multiple of 8, +the type is not supported for that value of ``__riscv_v_fixed_vlen``. }]; } diff --git a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def index d208342d9c51..74dfd1d214e8 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def +++ b/contrib/llvm-project/clang/include/clang/Basic/BuiltinsAMDGPU.def @@ -436,5 +436,67 @@ TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_i32, "ii*1", "nc", "gfx12-insts,w TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_v4i16, "V4sV4s*1", "nc", "gfx12-insts,wavefrontsize64") TARGET_BUILTIN(__builtin_amdgcn_global_load_tr_v4f16, "V4hV4h*1", "nc", "gfx12-insts,wavefrontsize64") +//===----------------------------------------------------------------------===// +// WMMA builtins. +// Postfix w32 indicates the builtin requires wavefront size of 32. +// Postfix w64 indicates the builtin requires wavefront size of 64. +// +// Some of these are very similar to their GFX11 counterparts, but they don't +// require replication of the A,B matrices, so they use fewer vector elements. +// Therefore, we add an "_gfx12" suffix to distinguish them from the existing +// builtins. +//===----------------------------------------------------------------------===// +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_f16_w32_gfx12, "V8fV8hV8hV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf16_w32_gfx12, "V8fV8sV8sV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f16_16x16x16_f16_w32_gfx12, "V8hV8hV8hV8h", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_bf16_16x16x16_bf16_w32_gfx12, "V8sV8sV8sV8s", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu8_w32_gfx12, "V8iIbV2iIbV2iV8iIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu4_w32_gfx12, "V8iIbiIbiV8iIb", "nc", "gfx12-insts,wavefrontsize32") +// These are gfx12-only, but for consistency with the other WMMA variants we're +// keeping the "_gfx12" suffix. +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_fp8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_bf8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_fp8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_bf8_w32_gfx12, "V8fV2iV2iV8f", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x32_iu4_w32_gfx12, "V8iIbV2iIbV2iV8iIb", "nc", "gfx12-insts,wavefrontsize32") + +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_f16_w64_gfx12, "V4fV4hV4hV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf16_w64_gfx12, "V4fV4sV4sV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f16_16x16x16_f16_w64_gfx12, "V4hV4hV4hV4h", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_bf16_16x16x16_bf16_w64_gfx12, "V4sV4sV4sV4s", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu8_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x16_iu4_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") +// These are gfx12-only, but for consistency with the other WMMA variants we're +// keeping the "_gfx12" suffix. +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_fp8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_fp8_bf8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_fp8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_f32_16x16x16_bf8_bf8_w64_gfx12, "V4fiiV4f", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_wmma_i32_16x16x32_iu4_w64_gfx12, "V4iIbiIbiV4iIb", "nc", "gfx12-insts,wavefrontsize64") + +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_f16_w32, "V8fV8hV16hV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf16_w32, "V8fV8sV16sV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f16_16x16x32_f16_w32, "V8hV8hV16hV8hs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_bf16_16x16x32_bf16_w32, "V8sV8sV16sV8ss", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu8_w32, "V8iIbV2iIbV4iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu4_w32, "V8iIbiIbV2iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x64_iu4_w32, "V8iIbV2iIbV4iV8isIb", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_fp8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_bf8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_fp8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_bf8_w32, "V8fV2iV4iV8fs", "nc", "gfx12-insts,wavefrontsize32") + +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_f16_w64, "V4fV4hV8hV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf16_w64, "V4fV4sV8sV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f16_16x16x32_f16_w64, "V4hV4hV8hV4hs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_bf16_16x16x32_bf16_w64, "V4sV4sV8sV4ss", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu8_w64, "V4iIbiIbV2iV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x32_iu4_w64, "V4iIbiIbiV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_i32_16x16x64_iu4_w64, "V4iIbiIbV2iV4isIb", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_fp8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_fp8_bf8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_fp8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") +TARGET_BUILTIN(__builtin_amdgcn_swmmac_f32_16x16x32_bf8_bf8_w64, "V4fiV2iV4fs", "nc", "gfx12-insts,wavefrontsize64") + #undef BUILTIN #undef TARGET_BUILTIN diff --git a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def index 2f2e45d5cf63..7c0bfe328496 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/CodeGenOptions.def @@ -369,6 +369,9 @@ ENUM_CODEGENOPT(VecLib, llvm::driver::VectorLibrary, 3, llvm::driver::VectorLibr /// The default TLS model to use. ENUM_CODEGENOPT(DefaultTLSModel, TLSModel, 2, GeneralDynamicTLSModel) +/// Whether to enable TLSDESC. AArch64 enables TLSDESC regardless of this value. +CODEGENOPT(EnableTLSDESC, 1, 0) + /// Bit size of immediate TLS offsets (0 == use the default). VALUE_CODEGENOPT(TLSSize, 8, 0) diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td index b1bada65cb6b..08bb1d81ba29 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticCommonKinds.td @@ -73,7 +73,7 @@ def warn_pragma_debug_unexpected_argument : Warning< def warn_fp_nan_inf_when_disabled : Warning< "use of %select{infinity|NaN}0%select{| via a macro}1 is undefined behavior " "due to the currently enabled floating-point options">, - InGroup>; + InGroup>; } // Parse && Sema diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td index e9862422b499..8c024b5cad74 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticDocs.td @@ -87,3 +87,12 @@ program by treating all string literals as having type ``const char *`` instead of ``char *``. This can cause unexpected behaviors with type-sensitive constructs like ``_Generic``. }]; + +defvar NanInfDisabledDocs = [{ +This warning is enabled when source code using the macros ``INFINITY`` or ``NAN`` +is compiled with floating-point options preventing these two values. This can +lead to undefined behavior. Check the order of command line arguments that modify +this behavior, such as ``-ffast-math``, ``-fhonor-infinities``, and +``-fhonor-nans`` (etc), as well as ``#pragma`` directives if this diagnostic is +generated unexpectedly. +}]; diff --git a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td index c5f1b67c4aa1..07ba4ecf7e12 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/contrib/llvm-project/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -3711,6 +3711,12 @@ def err_sme_za_call_no_za_state : Error< "call to a shared ZA function requires the caller to have ZA state">; def err_sme_zt0_call_no_zt0_state : Error< "call to a shared ZT0 function requires the caller to have ZT0 state">; +def err_sme_unimplemented_za_save_restore : Error< + "call to a function that shares state other than 'za' from a " + "function that has live 'za' state requires a spill/fill of ZA, which is not yet " + "implemented">; +def note_sme_use_preserves_za : Note< + "add '__arm_preserves(\"za\")' to the callee if it preserves ZA">; def err_sme_definition_using_sm_in_non_sme_target : Error< "function executed in streaming-SVE mode requires 'sme'">; def err_sme_definition_using_za_in_non_sme_target : Error< diff --git a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def index 8fc75e1cca03..4942dcaa086e 100644 --- a/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def +++ b/contrib/llvm-project/clang/include/clang/Basic/LangOptions.def @@ -174,6 +174,7 @@ LANGOPT(MathErrno , 1, 1, "errno in math functions") BENIGN_LANGOPT(HeinousExtensions , 1, 0, "extensions that we really don't like and may be ripped out at any time") LANGOPT(Modules , 1, 0, "modules semantics") COMPATIBLE_LANGOPT(CPlusPlusModules, 1, 0, "C++ modules syntax") +LANGOPT(SkipODRCheckInGMF, 1, 0, "Skip ODR checks for decls in the global module fragment") LANGOPT(BuiltinHeadersInSystemModules, 1, 0, "builtin headers belong to system modules, and _Builtin_ modules are ignored for cstdlib headers") BENIGN_ENUM_LANGOPT(CompilingModule, CompilingModuleKind, 3, CMK_None, "compiling a module interface") diff --git a/contrib/llvm-project/clang/include/clang/Driver/Options.td b/contrib/llvm-project/clang/include/clang/Driver/Options.td index 7f4fa33748fa..e8d03fc26902 100644 --- a/contrib/llvm-project/clang/include/clang/Driver/Options.td +++ b/contrib/llvm-project/clang/include/clang/Driver/Options.td @@ -2985,6 +2985,14 @@ def fmodule_output : Flag<["-"], "fmodule-output">, Flags<[NoXarchOption]>, Visibility<[ClangOption, CC1Option]>, HelpText<"Save intermediate module file results when compiling a standard C++ module unit.">; +defm skip_odr_check_in_gmf : BoolOption<"f", "skip-odr-check-in-gmf", + LangOpts<"SkipODRCheckInGMF">, DefaultFalse, + PosFlag, + NegFlag>, + Group; + def fmodules_prune_interval : Joined<["-"], "fmodules-prune-interval=">, Group, Visibility<[ClangOption, CC1Option]>, MetaVarName<"">, HelpText<"Specify the interval (in seconds) between attempts to prune the module cache">, @@ -4419,6 +4427,8 @@ def mtls_size_EQ : Joined<["-"], "mtls-size=">, Group, HelpText<"Specify bit size of immediate TLS offsets (AArch64 ELF only): " "12 (for 4KB) | 24 (for 16MB, default) | 32 (for 4GB) | 48 (for 256TB, needs -mcmodel=large)">, MarshallingInfoInt>; +def mtls_dialect_EQ : Joined<["-"], "mtls-dialect=">, Group, + Flags<[TargetSpecific]>, HelpText<"Which thread-local storage dialect to use for dynamic accesses of TLS variables">; def mimplicit_it_EQ : Joined<["-"], "mimplicit-it=">, Group; def mdefault_build_attributes : Joined<["-"], "mdefault-build-attributes">, Group; def mno_default_build_attributes : Joined<["-"], "mno-default-build-attributes">, Group; @@ -7066,6 +7076,9 @@ def fexperimental_assignment_tracking_EQ : Joined<["-"], "fexperimental-assignme Values<"disabled,enabled,forced">, NormalizedValues<["Disabled","Enabled","Forced"]>, MarshallingInfoEnum, "Enabled">; +def enable_tlsdesc : Flag<["-"], "enable-tlsdesc">, + MarshallingInfoFlag>; + } // let Visibility = [CC1Option] //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/clang/include/clang/Format/Format.h b/contrib/llvm-project/clang/include/clang/Format/Format.h index bc9eecd42f9e..efcb4e1d87ea 100755 --- a/contrib/llvm-project/clang/include/clang/Format/Format.h +++ b/contrib/llvm-project/clang/include/clang/Format/Format.h @@ -4157,14 +4157,9 @@ struct FormatStyle { /// Different ways to put a space before opening parentheses. enum SpaceBeforeParensStyle : int8_t { - /// Never put a space before opening parentheses. - /// \code - /// void f() { - /// if(true) { - /// f(); - /// } - /// } - /// \endcode + /// This is **deprecated** and replaced by ``Custom`` below, with all + /// ``SpaceBeforeParensOptions`` but ``AfterPlacementOperator`` set to + /// ``false``. SBPO_Never, /// Put a space before opening parentheses only after control statement /// keywords (``for/if/while...``). @@ -4273,28 +4268,14 @@ struct FormatStyle { /// object.operator++ (10); object.operator++(10); /// \endcode bool AfterOverloadedOperator; - /// Styles for adding spacing between ``new/delete`` operators and opening - /// parentheses. - enum AfterPlacementOperatorStyle : int8_t { - /// Remove space after ``new/delete`` operators and before ``(``. - /// \code - /// new(buf) T; - /// delete(buf) T; - /// \endcode - APO_Never, - /// Always add space after ``new/delete`` operators and before ``(``. - /// \code - /// new (buf) T; - /// delete (buf) T; - /// \endcode - APO_Always, - /// Leave placement ``new/delete`` expressions as they are. - APO_Leave, - }; - /// Defines in which cases to put a space between ``new/delete`` operators - /// and opening parentheses. - /// \version 18 - AfterPlacementOperatorStyle AfterPlacementOperator; + /// If ``true``, put a space between operator ``new``/``delete`` and opening + /// parenthesis. + /// \code + /// true: false: + /// new (buf) T; vs. new(buf) T; + /// delete (buf) T; delete(buf) T; + /// \endcode + bool AfterPlacementOperator; /// If ``true``, put space between requires keyword in a requires clause and /// opening parentheses, if there is one. /// \code @@ -4327,7 +4308,7 @@ struct FormatStyle { : AfterControlStatements(false), AfterForeachMacros(false), AfterFunctionDeclarationName(false), AfterFunctionDefinitionName(false), AfterIfMacros(false), - AfterOverloadedOperator(false), AfterPlacementOperator(APO_Leave), + AfterOverloadedOperator(false), AfterPlacementOperator(true), AfterRequiresInClause(false), AfterRequiresInExpression(false), BeforeNonEmptyParentheses(false) {} diff --git a/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h b/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h index 2d9c53cdf5bd..b0a8ec0fec5e 100644 --- a/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h +++ b/contrib/llvm-project/clang/include/clang/Lex/Preprocessor.h @@ -2828,7 +2828,8 @@ public: return AnnotationInfos.find(II)->second; } - void emitMacroExpansionWarnings(const Token &Identifier) const { + void emitMacroExpansionWarnings(const Token &Identifier, + bool IsIfnDef = false) const { IdentifierInfo *Info = Identifier.getIdentifierInfo(); if (Info->isDeprecatedMacro()) emitMacroDeprecationWarning(Identifier); @@ -2837,12 +2838,12 @@ public: !SourceMgr.isInMainFile(Identifier.getLocation())) emitRestrictExpansionWarning(Identifier); - if (Info->getName() == "INFINITY") - if (getLangOpts().NoHonorInfs) + if (!IsIfnDef) { + if (Info->getName() == "INFINITY" && getLangOpts().NoHonorInfs) emitRestrictInfNaNWarning(Identifier, 0); - if (Info->getName() == "NAN") - if (getLangOpts().NoHonorNaNs) + if (Info->getName() == "NAN" && getLangOpts().NoHonorNaNs) emitRestrictInfNaNWarning(Identifier, 1); + } } static void processPathForFileMacro(SmallVectorImpl &Path, diff --git a/contrib/llvm-project/clang/include/clang/Sema/Lookup.h b/contrib/llvm-project/clang/include/clang/Sema/Lookup.h index 9c93bf1e6fb4..2f2f2607a937 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Lookup.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Lookup.h @@ -754,7 +754,8 @@ public: private: void diagnoseAccess() { - if (isClassLookup() && getSema().getLangOpts().AccessControl) + if (!isAmbiguous() && isClassLookup() && + getSema().getLangOpts().AccessControl) getSema().CheckLookupAccess(*this); } diff --git a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h index dd1451bbf2d2..cd28226c295b 100644 --- a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h +++ b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h @@ -2452,6 +2452,12 @@ private: uint32_t CurrentBitsIndex = ~0; }; +inline bool shouldSkipCheckingODR(const Decl *D) { + return D->getOwningModule() && + D->getASTContext().getLangOpts().SkipODRCheckInGMF && + D->getOwningModule()->isExplicitGlobalModule(); +} + } // namespace clang #endif // LLVM_CLANG_SERIALIZATION_ASTREADER_H diff --git a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp index 9a0ede201059..cc5de9a6295e 100644 --- a/contrib/llvm-project/clang/lib/AST/ASTContext.cpp +++ b/contrib/llvm-project/clang/lib/AST/ASTContext.cpp @@ -1949,7 +1949,8 @@ TypeInfo ASTContext::getTypeInfoImpl(const Type *T) const { else if (VT->getVectorKind() == VectorKind::SveFixedLengthPredicate) // Adjust the alignment for fixed-length SVE predicates. Align = 16; - else if (VT->getVectorKind() == VectorKind::RVVFixedLengthData) + else if (VT->getVectorKind() == VectorKind::RVVFixedLengthData || + VT->getVectorKind() == VectorKind::RVVFixedLengthMask) // Adjust the alignment for fixed-length RVV vectors. Align = std::min(64, Width); break; @@ -9420,7 +9421,9 @@ bool ASTContext::areCompatibleVectorTypes(QualType FirstVec, Second->getVectorKind() != VectorKind::SveFixedLengthData && Second->getVectorKind() != VectorKind::SveFixedLengthPredicate && First->getVectorKind() != VectorKind::RVVFixedLengthData && - Second->getVectorKind() != VectorKind::RVVFixedLengthData) + Second->getVectorKind() != VectorKind::RVVFixedLengthData && + First->getVectorKind() != VectorKind::RVVFixedLengthMask && + Second->getVectorKind() != VectorKind::RVVFixedLengthMask) return true; return false; @@ -9526,8 +9529,11 @@ static uint64_t getRVVTypeSize(ASTContext &Context, const BuiltinType *Ty) { ASTContext::BuiltinVectorTypeInfo Info = Context.getBuiltinVectorTypeInfo(Ty); - uint64_t EltSize = Context.getTypeSize(Info.ElementType); - uint64_t MinElts = Info.EC.getKnownMinValue(); + unsigned EltSize = Context.getTypeSize(Info.ElementType); + if (Info.ElementType == Context.BoolTy) + EltSize = 1; + + unsigned MinElts = Info.EC.getKnownMinValue(); return VScale->first * MinElts * EltSize; } @@ -9541,6 +9547,12 @@ bool ASTContext::areCompatibleRVVTypes(QualType FirstType, auto IsValidCast = [this](QualType FirstType, QualType SecondType) { if (const auto *BT = FirstType->getAs()) { if (const auto *VT = SecondType->getAs()) { + if (VT->getVectorKind() == VectorKind::RVVFixedLengthMask) { + BuiltinVectorTypeInfo Info = getBuiltinVectorTypeInfo(BT); + return FirstType->isRVVVLSBuiltinType() && + Info.ElementType == BoolTy && + getTypeSize(SecondType) == getRVVTypeSize(*this, BT); + } if (VT->getVectorKind() == VectorKind::RVVFixedLengthData || VT->getVectorKind() == VectorKind::Generic) return FirstType->isRVVVLSBuiltinType() && diff --git a/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp b/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp index f1d07d022b25..edf9b5e2d52b 100644 --- a/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp +++ b/contrib/llvm-project/clang/lib/AST/ExprConstant.cpp @@ -7951,7 +7951,8 @@ public: // Overloaded operator calls to member functions are represented as normal // calls with '*this' as the first argument. const CXXMethodDecl *MD = dyn_cast(FD); - if (MD && MD->isImplicitObjectMemberFunction()) { + if (MD && + (MD->isImplicitObjectMemberFunction() || (OCE && MD->isStatic()))) { // FIXME: When selecting an implicit conversion for an overloaded // operator delete, we sometimes try to evaluate calls to conversion // operators without a 'this' parameter! @@ -7960,7 +7961,11 @@ public: if (!EvaluateObjectArgument(Info, Args[0], ThisVal)) return false; - This = &ThisVal; + + // If we are calling a static operator, the 'this' argument needs to be + // ignored after being evaluated. + if (MD->isInstance()) + This = &ThisVal; // If this is syntactically a simple assignment using a trivial // assignment operator, start the lifetimes of union members as needed, diff --git a/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp b/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp index 40b1e086ddd0..688141b30441 100644 --- a/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp +++ b/contrib/llvm-project/clang/lib/AST/ItaniumMangle.cpp @@ -3994,7 +3994,8 @@ void CXXNameMangler::mangleAArch64FixedSveVectorType( } void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { - assert(T->getVectorKind() == VectorKind::RVVFixedLengthData && + assert((T->getVectorKind() == VectorKind::RVVFixedLengthData || + T->getVectorKind() == VectorKind::RVVFixedLengthMask) && "expected fixed-length RVV vector!"); QualType EltType = T->getElementType(); @@ -4009,7 +4010,10 @@ void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { TypeNameOS << "int8"; break; case BuiltinType::UChar: - TypeNameOS << "uint8"; + if (T->getVectorKind() == VectorKind::RVVFixedLengthData) + TypeNameOS << "uint8"; + else + TypeNameOS << "bool"; break; case BuiltinType::Short: TypeNameOS << "int16"; @@ -4048,12 +4052,16 @@ void CXXNameMangler::mangleRISCVFixedRVVVectorType(const VectorType *T) { auto VScale = getASTContext().getTargetInfo().getVScaleRange( getASTContext().getLangOpts()); unsigned VLen = VScale->first * llvm::RISCV::RVVBitsPerBlock; - TypeNameOS << 'm'; - if (VecSizeInBits >= VLen) - TypeNameOS << (VecSizeInBits / VLen); - else - TypeNameOS << 'f' << (VLen / VecSizeInBits); + if (T->getVectorKind() == VectorKind::RVVFixedLengthData) { + TypeNameOS << 'm'; + if (VecSizeInBits >= VLen) + TypeNameOS << (VecSizeInBits / VLen); + else + TypeNameOS << 'f' << (VLen / VecSizeInBits); + } else { + TypeNameOS << (VLen / VecSizeInBits); + } TypeNameOS << "_t"; Out << "9__RVV_VLSI" << 'u' << TypeNameStr.size() << TypeNameStr << "Lj" @@ -4093,7 +4101,8 @@ void CXXNameMangler::mangleType(const VectorType *T) { T->getVectorKind() == VectorKind::SveFixedLengthPredicate) { mangleAArch64FixedSveVectorType(T); return; - } else if (T->getVectorKind() == VectorKind::RVVFixedLengthData) { + } else if (T->getVectorKind() == VectorKind::RVVFixedLengthData || + T->getVectorKind() == VectorKind::RVVFixedLengthMask) { mangleRISCVFixedRVVVectorType(T); return; } diff --git a/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp b/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp index 3daba13d0fce..3c11b75d7472 100644 --- a/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp +++ b/contrib/llvm-project/clang/lib/AST/JSONNodeDumper.cpp @@ -703,6 +703,9 @@ void JSONNodeDumper::VisitVectorType(const VectorType *VT) { case VectorKind::RVVFixedLengthData: JOS.attribute("vectorKind", "fixed-length rvv data vector"); break; + case VectorKind::RVVFixedLengthMask: + JOS.attribute("vectorKind", "fixed-length rvv mask vector"); + break; } } diff --git a/contrib/llvm-project/clang/lib/AST/ODRHash.cpp b/contrib/llvm-project/clang/lib/AST/ODRHash.cpp index 5b98646a1e8d..2dbc259138a8 100644 --- a/contrib/llvm-project/clang/lib/AST/ODRHash.cpp +++ b/contrib/llvm-project/clang/lib/AST/ODRHash.cpp @@ -745,55 +745,8 @@ void ODRHash::AddEnumDecl(const EnumDecl *Enum) { if (Enum->isScoped()) AddBoolean(Enum->isScopedUsingClassTag()); - if (Enum->getIntegerTypeSourceInfo()) { - // FIMXE: This allows two enums with different spellings to have the same - // hash. - // - // // mod1.cppm - // module; - // extern "C" { - // typedef unsigned __int64 size_t; - // } - // namespace std { - // using :: size_t; - // } - // - // extern "C++" { - // namespace std { - // enum class align_val_t : std::size_t {}; - // } - // } - // - // export module mod1; - // export using std::align_val_t; - // - // // mod2.cppm - // module; - // extern "C" { - // typedef unsigned __int64 size_t; - // } - // - // extern "C++" { - // namespace std { - // enum class align_val_t : size_t {}; - // } - // } - // - // export module mod2; - // import mod1; - // export using std::align_val_t; - // - // The above example should be disallowed since it violates - // [basic.def.odr]p14: - // - // Each such definition shall consist of the same sequence of tokens - // - // The definitions of `std::align_val_t` in two module units have different - // spellings but we failed to give an error here. - // - // See https://github.com/llvm/llvm-project/issues/76638 for details. + if (Enum->getIntegerTypeSourceInfo()) AddQualType(Enum->getIntegerType().getCanonicalType()); - } // Filter out sub-Decls which will not be processed in order to get an // accurate count of Decl's. diff --git a/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp b/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp index 2bdbeb08ef20..3310d7dc24c5 100644 --- a/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/TemplateBase.cpp @@ -450,7 +450,8 @@ bool TemplateArgument::structurallyEquals(const TemplateArgument &Other) const { getAsIntegral() == Other.getAsIntegral(); case StructuralValue: { - if (getStructuralValueType() != Other.getStructuralValueType()) + if (getStructuralValueType().getCanonicalType() != + Other.getStructuralValueType().getCanonicalType()) return false; llvm::FoldingSetNodeID A, B; diff --git a/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp b/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp index 48c6729a6738..ecf5de0be543 100644 --- a/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp +++ b/contrib/llvm-project/clang/lib/AST/TextNodeDumper.cpp @@ -1623,6 +1623,9 @@ void TextNodeDumper::VisitVectorType(const VectorType *T) { case VectorKind::RVVFixedLengthData: OS << " fixed-length rvv data vector"; break; + case VectorKind::RVVFixedLengthMask: + OS << " fixed-length rvv mask vector"; + break; } OS << " " << T->getNumElements(); } diff --git a/contrib/llvm-project/clang/lib/AST/Type.cpp b/contrib/llvm-project/clang/lib/AST/Type.cpp index 3db5ae182f32..d4103025591e 100644 --- a/contrib/llvm-project/clang/lib/AST/Type.cpp +++ b/contrib/llvm-project/clang/lib/AST/Type.cpp @@ -2479,6 +2479,9 @@ bool Type::isRVVVLSBuiltinType() const { IsFP, IsBF) \ case BuiltinType::Id: \ return NF == 1; +#define RVV_PREDICATE_TYPE(Name, Id, SingletonId, NumEls) \ + case BuiltinType::Id: \ + return true; #include "clang/Basic/RISCVVTypes.def" default: return false; @@ -2491,7 +2494,17 @@ QualType Type::getRVVEltType(const ASTContext &Ctx) const { assert(isRVVVLSBuiltinType() && "unsupported type!"); const BuiltinType *BTy = castAs(); - return Ctx.getBuiltinVectorTypeInfo(BTy).ElementType; + *** 11829 LINES SKIPPED *** From nobody Sat Apr 20 10:34:40 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dd1cmVz5HWg8; Sat, 20 Apr 2024 10:34:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dc46N3z4T6m; Sat, 20 Apr 2024 10:34:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609280; 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=WQSE4FQaaD8EDaCb/uzDrlxsgKfk6FLrfd/qBsz6gyM=; b=ot89J1dBzBaOfPaHfdkOUP/WRpn+WkPj5ynvATK/ycQoAd6NhkG8pEw88kKGk2lD5BjF/W QZvmLMOGtX+NTuSRbWfLscVkctWwHGdYHdhyBpz9B3gH0OAb5h3MGZBHWovVpM3NHlNSTo 5zBe9yIhH+gOzhBxuon7hIQnyxfULD/0+h1YTcJfby2kI7xEGCqTQ7JURAchiav9KojhAX EmDafqcYq7CBd394qWqbV7/5SnlwPQlCh9/qgL3tcYtYKMsaJGvkn3bJEHYFOKFgYUnSHa yLiaKSIKKRsI3OVzn+YZfiBvdIRS6bE6mADb1M+fazOYeRi8uqJsYV6NiCD7Jw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609280; a=rsa-sha256; cv=none; b=uNucoW5dxb9mg5ZYOi4oIuvJg08oYH+mmNGnDG1G8dKYgRfQmr0KnCYGEvbeRrpiGf0Wcb 6yJHbBPxSHXRRGP1/8duQKaGxDBmBZRvqFZ3bo64S2yMbrD+T/hDvqBhPymHlHhZxF+DzA krGLfTc4Mua1EOzapX8d7I80xKVM32CjXb5umDw7q3lPV4oxJbo9Z5tHq96cwm82sN3/OE 1ahPEG4S+LGx9pTGlhgcwpouxway4Th4Vr+An9O0IvHw5KcpmLIXWBZV5TuNDSWfc1q1rz f9NBNZ2TR//um2ywE/Yj2m5i3Yus508yJpwaOioN/QhtGEAU/s9UKCIizBFu8g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609280; 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=WQSE4FQaaD8EDaCb/uzDrlxsgKfk6FLrfd/qBsz6gyM=; b=YVCFCYrhjtBHpFiPxYXUx454Hxrp1FP0ZAxZ27DyMiq0ipWAyzvReaVdBi8FkIW3srTcOt pVEX5yDpRFXvLS0dXSqzIBuRfNWKIw5nhy9VVNDYqv/nAyUNKBQD6XSlsWNKo+VyTdgjVQ RvYDvPBuyIJbxvayXqcv2VUzu2dOnHDW6TFo18E/k4F+hXkkKxssC6XK9Km24aav0fyj0x UHWTCCwYaVC0MZsvANz+x27seWdSML9K9i4ZaJR0l2xKM06gF7zb/PWA/BwOc58LxhH58c OTLvHzSwtxnT/IgIa4P5xs1XGtGqTEQ5UG4nrSsB/tNhuwgLHEyUR2RIo7WWKQ== 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 4VM7Dc3jq1zZJS; Sat, 20 Apr 2024 10:34:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYeTm013995; Sat, 20 Apr 2024 10:34:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYedt013992; Sat, 20 Apr 2024 10:34:40 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:40 GMT Message-Id: <202404201034.43KAYedt013992@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: 7032a4352158 - stable/13 - Merge llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 7032a435215851c26dbcef63f5a4d1c1526e9ab9 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7032a435215851c26dbcef63f5a4d1c1526e9ab9 commit 7032a435215851c26dbcef63f5a4d1c1526e9ab9 Author: Dimitry Andric AuthorDate: 2024-02-21 10:24:23 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:47 +0000 Merge llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.0-rc3-0-g6c90f8dd5463. PR: 276104 MFC after: 1 month (cherry picked from commit 56727255ad47072ec2cc81b4ae728a099697b0e4) --- .../clang/lib/Serialization/ASTReaderDecl.cpp | 10 +- .../clang/lib/Serialization/ASTWriter.cpp | 6 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 15 +- .../compiler-rt/lib/profile/InstrProfilingFile.c | 3 + .../llvm/include/llvm/Analysis/ScalarEvolution.h | 7 + .../llvm/lib/Analysis/ScalarEvolution.cpp | 62 ++++ .../llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 37 +- .../InstCombine/InstructionCombining.cpp | 6 +- .../Transforms/Utils/ScalarEvolutionExpander.cpp | 57 +-- .../llvm/lib/Transforms/Utils/SimplifyIndVar.cpp | 18 +- .../llvm/tools/llvm-objcopy/ObjcopyOptions.cpp | 2 + .../llvm/tools/llvm-objdump/ELFDump.cpp | 3 + .../llvm/tools/llvm-readobj/ELFDumper.cpp | 1 + .../llvm-project/openmp/runtime/src/z_AIX_asm.S | 410 +++++++++++++++++++++ lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 17 files changed, 558 insertions(+), 89 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp index 1fadd8039462..321c11e55c14 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp @@ -800,11 +800,12 @@ void ASTDeclReader::VisitEnumDecl(EnumDecl *ED) { BitsUnpacker EnumDeclBits(Record.readInt()); ED->setNumPositiveBits(EnumDeclBits.getNextBits(/*Width=*/8)); ED->setNumNegativeBits(EnumDeclBits.getNextBits(/*Width=*/8)); + bool ShouldSkipCheckingODR = EnumDeclBits.getNextBit(); ED->setScoped(EnumDeclBits.getNextBit()); ED->setScopedUsingClassTag(EnumDeclBits.getNextBit()); ED->setFixed(EnumDeclBits.getNextBit()); - if (!shouldSkipCheckingODR(ED)) { + if (!ShouldSkipCheckingODR) { ED->setHasODRHash(true); ED->ODRHash = Record.readInt(); } @@ -1073,6 +1074,7 @@ void ASTDeclReader::VisitFunctionDecl(FunctionDecl *FD) { FD->setCachedLinkage((Linkage)FunctionDeclBits.getNextBits(/*Width=*/3)); FD->setStorageClass((StorageClass)FunctionDeclBits.getNextBits(/*Width=*/3)); + bool ShouldSkipCheckingODR = FunctionDeclBits.getNextBit(); FD->setInlineSpecified(FunctionDeclBits.getNextBit()); FD->setImplicitlyInline(FunctionDeclBits.getNextBit()); FD->setHasSkippedBody(FunctionDeclBits.getNextBit()); @@ -1102,7 +1104,7 @@ void ASTDeclReader::VisitFunctionDecl(FunctionDecl *FD) { if (FD->isExplicitlyDefaulted()) FD->setDefaultLoc(readSourceLocation()); - if (!shouldSkipCheckingODR(FD)) { + if (!ShouldSkipCheckingODR) { FD->ODRHash = Record.readInt(); FD->setHasODRHash(true); } @@ -1973,6 +1975,8 @@ void ASTDeclReader::ReadCXXDefinitionData( BitsUnpacker CXXRecordDeclBits = Record.readInt(); + bool ShouldSkipCheckingODR = CXXRecordDeclBits.getNextBit(); + #define FIELD(Name, Width, Merge) \ if (!CXXRecordDeclBits.canGetNextNBits(Width)) \ CXXRecordDeclBits.updateValue(Record.readInt()); \ @@ -1982,7 +1986,7 @@ void ASTDeclReader::ReadCXXDefinitionData( #undef FIELD // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) { + if (!ShouldSkipCheckingODR) { // Note: the caller has deserialized the IsLambda bit already. Data.ODRHash = Record.readInt(); Data.HasODRHash = true; diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp index 3b79a9238d1a..73018c1170d8 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp @@ -6010,6 +6010,9 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { BitsPacker DefinitionBits; + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + DefinitionBits.addBit(ShouldSkipCheckingODR); + #define FIELD(Name, Width, Merge) \ if (!DefinitionBits.canWriteNextNBits(Width)) { \ Record->push_back(DefinitionBits); \ @@ -6023,11 +6026,10 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { Record->push_back(DefinitionBits); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) { + if (!ShouldSkipCheckingODR) // getODRHash will compute the ODRHash if it has not been previously // computed. Record->push_back(D->getODRHash()); - } bool ModulesDebugInfo = Writer->Context->getLangOpts().ModulesDebugInfo && !D->isDependentType(); diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp index f224075643e9..e73800100e3c 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp @@ -488,13 +488,15 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { BitsPacker EnumDeclBits; EnumDeclBits.addBits(D->getNumPositiveBits(), /*BitWidth=*/8); EnumDeclBits.addBits(D->getNumNegativeBits(), /*BitWidth=*/8); + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + EnumDeclBits.addBit(ShouldSkipCheckingODR); EnumDeclBits.addBit(D->isScoped()); EnumDeclBits.addBit(D->isScopedUsingClassTag()); EnumDeclBits.addBit(D->isFixed()); Record.push_back(EnumDeclBits); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) + if (!ShouldSkipCheckingODR) Record.push_back(D->getODRHash()); if (MemberSpecializationInfo *MemberInfo = D->getMemberSpecializationInfo()) { @@ -678,6 +680,8 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { // FIXME: stable encoding FunctionDeclBits.addBits(llvm::to_underlying(D->getLinkageInternal()), 3); FunctionDeclBits.addBits((uint32_t)D->getStorageClass(), /*BitWidth=*/3); + bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + FunctionDeclBits.addBit(ShouldSkipCheckingODR); FunctionDeclBits.addBit(D->isInlineSpecified()); FunctionDeclBits.addBit(D->isInlined()); FunctionDeclBits.addBit(D->hasSkippedBody()); @@ -704,7 +708,7 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { Record.AddSourceLocation(D->getDefaultLoc()); // We only perform ODR checks for decls not in GMF. - if (!shouldSkipCheckingODR(D)) + if (!ShouldSkipCheckingODR) Record.push_back(D->getODRHash()); if (D->isDefaulted()) { @@ -2137,12 +2141,13 @@ getFunctionDeclAbbrev(serialization::DeclCode Code) { Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 11)); // IDNS Abv->Add(BitCodeAbbrevOp( BitCodeAbbrevOp::Fixed, - 27)); // Packed Function Bits: StorageClass, Inline, InlineSpecified, + 28)); // Packed Function Bits: StorageClass, Inline, InlineSpecified, // VirtualAsWritten, Pure, HasInheritedProto, HasWrittenProto, // Deleted, Trivial, TrivialForCall, Defaulted, ExplicitlyDefaulted, // IsIneligibleOrNotSelected, ImplicitReturnZero, Constexpr, // UsesSEHTry, SkippedBody, MultiVersion, LateParsed, - // FriendConstraintRefersToEnclosingTemplate, Linkage + // FriendConstraintRefersToEnclosingTemplate, Linkage, + // ShouldSkipCheckingODR Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // LocEnd Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 32)); // ODRHash // This Array slurps the rest of the record. Fortunately we want to encode @@ -2269,7 +2274,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // AddTypeRef Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // IntegerType Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // getPromotionType - Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 19)); // Enum Decl Bits + Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 20)); // Enum Decl Bits Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 32));// ODRHash Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // InstantiatedMembEnum // DC diff --git a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c index 867ae73f0d3b..f3b457d786e6 100644 --- a/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c +++ b/contrib/llvm-project/compiler-rt/lib/profile/InstrProfilingFile.c @@ -677,6 +677,7 @@ static void initializeProfileForContinuousMode(void) { PROF_ERR("Continuous counter sync mode is enabled, but raw profile is not" "page-aligned. CurrentFileOffset = %" PRIu64 ", pagesz = %u.\n", (uint64_t)CurrentFileOffset, PageSize); + fclose(File); return; } if (writeProfileWithFileObject(Filename, File) != 0) { @@ -692,6 +693,8 @@ static void initializeProfileForContinuousMode(void) { if (doMerging()) { lprofUnlockFileHandle(File); + } + if (File != NULL) { fclose(File); } } diff --git a/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h b/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h index af3ad822e0b0..0880f9c65aa4 100644 --- a/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h +++ b/contrib/llvm-project/llvm/include/llvm/Analysis/ScalarEvolution.h @@ -1314,6 +1314,13 @@ public: void getPoisonGeneratingValues(SmallPtrSetImpl &Result, const SCEV *S); + /// Check whether it is poison-safe to represent the expression S using the + /// instruction I. If such a replacement is performed, the poison flags of + /// instructions in DropPoisonGeneratingInsts must be dropped. + bool canReuseInstruction( + const SCEV *S, Instruction *I, + SmallVectorImpl &DropPoisonGeneratingInsts); + class FoldID { const SCEV *Op = nullptr; const Type *Ty = nullptr; diff --git a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp index 2acb45837c48..4b2db80bc1ec 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp @@ -4184,6 +4184,68 @@ void ScalarEvolution::getPoisonGeneratingValues( Result.insert(SU->getValue()); } +bool ScalarEvolution::canReuseInstruction( + const SCEV *S, Instruction *I, + SmallVectorImpl &DropPoisonGeneratingInsts) { + // If the instruction cannot be poison, it's always safe to reuse. + if (programUndefinedIfPoison(I)) + return true; + + // Otherwise, it is possible that I is more poisonous that S. Collect the + // poison-contributors of S, and then check whether I has any additional + // poison-contributors. Poison that is contributed through poison-generating + // flags is handled by dropping those flags instead. + SmallPtrSet PoisonVals; + getPoisonGeneratingValues(PoisonVals, S); + + SmallVector Worklist; + SmallPtrSet Visited; + Worklist.push_back(I); + while (!Worklist.empty()) { + Value *V = Worklist.pop_back_val(); + if (!Visited.insert(V).second) + continue; + + // Avoid walking large instruction graphs. + if (Visited.size() > 16) + return false; + + // Either the value can't be poison, or the S would also be poison if it + // is. + if (PoisonVals.contains(V) || isGuaranteedNotToBePoison(V)) + continue; + + auto *I = dyn_cast(V); + if (!I) + return false; + + // Disjoint or instructions are interpreted as adds by SCEV. However, we + // can't replace an arbitrary add with disjoint or, even if we drop the + // flag. We would need to convert the or into an add. + if (auto *PDI = dyn_cast(I)) + if (PDI->isDisjoint()) + return false; + + // FIXME: Ignore vscale, even though it technically could be poison. Do this + // because SCEV currently assumes it can't be poison. Remove this special + // case once we proper model when vscale can be poison. + if (auto *II = dyn_cast(I); + II && II->getIntrinsicID() == Intrinsic::vscale) + continue; + + if (canCreatePoison(cast(I), /*ConsiderFlagsAndMetadata*/ false)) + return false; + + // If the instruction can't create poison, we can recurse to its operands. + if (I->hasPoisonGeneratingFlagsOrMetadata()) + DropPoisonGeneratingInsts.push_back(I); + + for (Value *Op : I->operands()) + Worklist.push_back(Op); + } + return true; +} + const SCEV * ScalarEvolution::getSequentialMinMaxExpr(SCEVTypes Kind, SmallVectorImpl &Ops) { diff --git a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp index 26ed74108ec3..18a4223d481e 100644 --- a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp @@ -1635,7 +1635,8 @@ class BitPermutationSelector { default: break; case ISD::ROTL: if (isa(V.getOperand(1))) { - unsigned RotAmt = V.getConstantOperandVal(1); + assert(isPowerOf2_32(NumBits) && "rotl bits should be power of 2!"); + unsigned RotAmt = V.getConstantOperandVal(1) & (NumBits - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; @@ -1648,15 +1649,20 @@ class BitPermutationSelector { case ISD::SHL: case PPCISD::SHL: if (isa(V.getOperand(1))) { - unsigned ShiftAmt = V.getConstantOperandVal(1); + // sld takes 7 bits, slw takes 6. + unsigned ShiftAmt = V.getConstantOperandVal(1) & ((NumBits << 1) - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; - for (unsigned i = ShiftAmt; i < NumBits; ++i) - Bits[i] = LHSBits[i - ShiftAmt]; - - for (unsigned i = 0; i < ShiftAmt; ++i) - Bits[i] = ValueBit(ValueBit::ConstZero); + if (ShiftAmt >= NumBits) { + for (unsigned i = 0; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } else { + for (unsigned i = ShiftAmt; i < NumBits; ++i) + Bits[i] = LHSBits[i - ShiftAmt]; + for (unsigned i = 0; i < ShiftAmt; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } return std::make_pair(Interesting = true, &Bits); } @@ -1664,15 +1670,20 @@ class BitPermutationSelector { case ISD::SRL: case PPCISD::SRL: if (isa(V.getOperand(1))) { - unsigned ShiftAmt = V.getConstantOperandVal(1); + // srd takes lowest 7 bits, srw takes 6. + unsigned ShiftAmt = V.getConstantOperandVal(1) & ((NumBits << 1) - 1); const auto &LHSBits = *getValueBits(V.getOperand(0), NumBits).second; - for (unsigned i = 0; i < NumBits - ShiftAmt; ++i) - Bits[i] = LHSBits[i + ShiftAmt]; - - for (unsigned i = NumBits - ShiftAmt; i < NumBits; ++i) - Bits[i] = ValueBit(ValueBit::ConstZero); + if (ShiftAmt >= NumBits) { + for (unsigned i = 0; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } else { + for (unsigned i = 0; i < NumBits - ShiftAmt; ++i) + Bits[i] = LHSBits[i + ShiftAmt]; + for (unsigned i = NumBits - ShiftAmt; i < NumBits; ++i) + Bits[i] = ValueBit(ValueBit::ConstZero); + } return std::make_pair(Interesting = true, &Bits); } diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp index 249f4a7710e0..5d207dcfd18d 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -2594,10 +2594,10 @@ Instruction *InstCombinerImpl::visitGetElementPtrInst(GetElementPtrInst &GEP) { Value *V; if ((has_single_bit(TyAllocSize) && match(GEP.getOperand(1), - m_Exact(m_AShr(m_Value(V), - m_SpecificInt(countr_zero(TyAllocSize)))))) || + m_Exact(m_Shr(m_Value(V), + m_SpecificInt(countr_zero(TyAllocSize)))))) || match(GEP.getOperand(1), - m_Exact(m_SDiv(m_Value(V), m_SpecificInt(TyAllocSize))))) { + m_Exact(m_IDiv(m_Value(V), m_SpecificInt(TyAllocSize))))) { GetElementPtrInst *NewGEP = GetElementPtrInst::Create( Builder.getInt8Ty(), GEP.getPointerOperand(), V); NewGEP->setIsInBounds(GEP.isInBounds()); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp index a1d7f0f9ba0f..a3951fdf8a15 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp @@ -1366,61 +1366,6 @@ Value *SCEVExpander::expandCodeFor(const SCEV *SH, Type *Ty) { return V; } -static bool -canReuseInstruction(ScalarEvolution &SE, const SCEV *S, Instruction *I, - SmallVectorImpl &DropPoisonGeneratingInsts) { - // If the instruction cannot be poison, it's always safe to reuse. - if (programUndefinedIfPoison(I)) - return true; - - // Otherwise, it is possible that I is more poisonous that S. Collect the - // poison-contributors of S, and then check whether I has any additional - // poison-contributors. Poison that is contributed through poison-generating - // flags is handled by dropping those flags instead. - SmallPtrSet PoisonVals; - SE.getPoisonGeneratingValues(PoisonVals, S); - - SmallVector Worklist; - SmallPtrSet Visited; - Worklist.push_back(I); - while (!Worklist.empty()) { - Value *V = Worklist.pop_back_val(); - if (!Visited.insert(V).second) - continue; - - // Avoid walking large instruction graphs. - if (Visited.size() > 16) - return false; - - // Either the value can't be poison, or the S would also be poison if it - // is. - if (PoisonVals.contains(V) || isGuaranteedNotToBePoison(V)) - continue; - - auto *I = dyn_cast(V); - if (!I) - return false; - - // FIXME: Ignore vscale, even though it technically could be poison. Do this - // because SCEV currently assumes it can't be poison. Remove this special - // case once we proper model when vscale can be poison. - if (auto *II = dyn_cast(I); - II && II->getIntrinsicID() == Intrinsic::vscale) - continue; - - if (canCreatePoison(cast(I), /*ConsiderFlagsAndMetadata*/ false)) - return false; - - // If the instruction can't create poison, we can recurse to its operands. - if (I->hasPoisonGeneratingFlagsOrMetadata()) - DropPoisonGeneratingInsts.push_back(I); - - for (Value *Op : I->operands()) - Worklist.push_back(Op); - } - return true; -} - Value *SCEVExpander::FindValueInExprValueMap( const SCEV *S, const Instruction *InsertPt, SmallVectorImpl &DropPoisonGeneratingInsts) { @@ -1448,7 +1393,7 @@ Value *SCEVExpander::FindValueInExprValueMap( continue; // Make sure reusing the instruction is poison-safe. - if (canReuseInstruction(SE, S, EntInst, DropPoisonGeneratingInsts)) + if (SE.canReuseInstruction(S, EntInst, DropPoisonGeneratingInsts)) return V; DropPoisonGeneratingInsts.clear(); } diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp index 0ed3324a27b6..1b142f14d811 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp @@ -16,6 +16,7 @@ #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/Statistic.h" #include "llvm/Analysis/LoopInfo.h" +#include "llvm/Analysis/ValueTracking.h" #include "llvm/IR/Dominators.h" #include "llvm/IR/IRBuilder.h" #include "llvm/IR/Instructions.h" @@ -713,8 +714,11 @@ bool SimplifyIndvar::replaceFloatIVWithIntegerIV(Instruction *UseInst) { bool SimplifyIndvar::eliminateIdentitySCEV(Instruction *UseInst, Instruction *IVOperand) { if (!SE->isSCEVable(UseInst->getType()) || - (UseInst->getType() != IVOperand->getType()) || - (SE->getSCEV(UseInst) != SE->getSCEV(IVOperand))) + UseInst->getType() != IVOperand->getType()) + return false; + + const SCEV *UseSCEV = SE->getSCEV(UseInst); + if (UseSCEV != SE->getSCEV(IVOperand)) return false; // getSCEV(X) == getSCEV(Y) does not guarantee that X and Y are related in the @@ -742,6 +746,16 @@ bool SimplifyIndvar::eliminateIdentitySCEV(Instruction *UseInst, if (!LI->replacementPreservesLCSSAForm(UseInst, IVOperand)) return false; + // Make sure the operand is not more poisonous than the instruction. + if (!impliesPoison(IVOperand, UseInst)) { + SmallVector DropPoisonGeneratingInsts; + if (!SE->canReuseInstruction(UseSCEV, IVOperand, DropPoisonGeneratingInsts)) + return false; + + for (Instruction *I : DropPoisonGeneratingInsts) + I->dropPoisonGeneratingFlagsAndMetadata(); + } + LLVM_DEBUG(dbgs() << "INDVARS: Eliminated identity: " << *UseInst << '\n'); SE->forgetValue(UseInst); diff --git a/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp b/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp index f15307181fad..f63e5c61e802 100644 --- a/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-objcopy/ObjcopyOptions.cpp @@ -299,6 +299,8 @@ static const StringMap TargetMap{ // LoongArch {"elf32-loongarch", {ELF::EM_LOONGARCH, false, true}}, {"elf64-loongarch", {ELF::EM_LOONGARCH, true, true}}, + // SystemZ + {"elf64-s390", {ELF::EM_S390, true, false}}, }; static Expected diff --git a/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp b/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp index 34861ee92128..fda99bd6d33e 100644 --- a/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-objdump/ELFDump.cpp @@ -291,6 +291,9 @@ template void ELFDumper::printProgramHeaders() { case ELF::PT_OPENBSD_RANDOMIZE: outs() << "OPENBSD_RANDOMIZE "; break; + case ELF::PT_OPENBSD_SYSCALLS: + outs() << "OPENBSD_SYSCALLS "; + break; case ELF::PT_OPENBSD_WXNEEDED: outs() << "OPENBSD_WXNEEDED "; break; diff --git a/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp b/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp index f369a63add11..387124ad53e4 100644 --- a/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp +++ b/contrib/llvm-project/llvm/tools/llvm-readobj/ELFDumper.cpp @@ -1478,6 +1478,7 @@ static StringRef segmentTypeToString(unsigned Arch, unsigned Type) { LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_RANDOMIZE); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_WXNEEDED); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_NOBTCFI); + LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_SYSCALLS); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_BOOTDATA); default: return ""; diff --git a/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S b/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S new file mode 100644 index 000000000000..d711fcb7a785 --- /dev/null +++ b/contrib/llvm-project/openmp/runtime/src/z_AIX_asm.S @@ -0,0 +1,410 @@ +// z_AIX_asm.S: - microtasking routines specifically +// written for Power platforms running AIX OS + +// +////===----------------------------------------------------------------------===// +//// +//// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +//// See https://llvm.org/LICENSE.txt for license information. +//// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +//// +////===----------------------------------------------------------------------===// +// + +// ----------------------------------------------------------------------- +// macros +// ----------------------------------------------------------------------- + +#include "kmp_config.h" + +#if KMP_OS_AIX +//------------------------------------------------------------------------ +// int +// __kmp_invoke_microtask( void (*pkfn) (int *gtid, int *tid, ...), +// int gtid, int tid, +// int argc, void *p_argv[] +// #if OMPT_SUPPORT +// , +// void **exit_frame_ptr +// #endif +// ) { +// #if OMPT_SUPPORT +// *exit_frame_ptr = OMPT_GET_FRAME_ADDRESS(0); +// #endif +// +// (*pkfn)( & gtid, & tid, p_argv[0], ... ); +// +// // FIXME: This is done at call-site and can be removed here. +// #if OMPT_SUPPORT +// *exit_frame_ptr = 0; +// #endif +// +// return 1; +// } +// +// parameters: +// r3: pkfn +// r4: gtid +// r5: tid +// r6: argc +// r7: p_argv +// r8: &exit_frame +// +// return: r3 (always 1/TRUE) +// + +#if KMP_ARCH_PPC64_XCOFF + + .globl __kmp_invoke_microtask[DS] + .globl .__kmp_invoke_microtask + .align 4 + .csect __kmp_invoke_microtask[DS],3 + .vbyte 8, .__kmp_invoke_microtask + .vbyte 8, TOC[TC0] + .vbyte 8, 0 + .csect .text[PR],2 + .machine "pwr7" +.__kmp_invoke_microtask: + + +// -- Begin __kmp_invoke_microtask +// mark_begin; + +// We need to allocate a stack frame large enough to hold all of the parameters +// on the stack for the microtask plus what this function needs. That's 48 +// bytes under the XCOFF64 ABI, plus max(64, 8*(2 + argc)) for +// the parameters to the microtask (gtid, tid, argc elements of p_argv), +// plus 8 bytes to store the values of r4 and r5, and 8 bytes to store r31. +// With OMP-T support, we need an additional 8 bytes to save r30 to hold +// a copy of r8. +// Stack offsets relative to stack pointer: +// r31: -8, r30: -16, gtid: -20, tid: -24 + + mflr 0 + std 31, -8(1) # Save r31 to the stack + std 0, 16(1) # Save LR to the linkage area + +// This is unusual because normally we'd set r31 equal to r1 after the stack +// frame is established. In this case, however, we need to dynamically compute +// the stack frame size, and so we keep a direct copy of r1 to access our +// register save areas and restore the r1 value before returning. + mr 31, 1 + +// Compute the size of the "argc" portion of the parameter save area. +// The parameter save area is always at least 64 bytes long (i.e. 8 regs) +// The microtask has (2 + argc) parameters, so if argc <= 6, we need to +// to allocate 8*6 bytes, not 8*argc. + li 0, 6 + cmpwi 0, 6, 6 + iselgt 0, 6, 0 # r0 = (argc > 6)? argc : 6 + sldi 0, 0, 3 # r0 = 8 * max(argc, 6) + +// Compute the size necessary for the local stack frame. +// 88 = 48 + 4 (for r4) + 4 (for r5) + 8 (for r31) + 8 (for OMP-T r30) + +// 8 (parameter gtid) + 8 (parameter tid) + li 12, 88 + add 12, 0, 12 + neg 12, 12 + +// We need to make sure that the stack frame stays aligned (to 16 bytes). + li 0, -16 + and 12, 0, 12 + +// Establish the local stack frame. + stdux 1, 1, 12 + +#if OMPT_SUPPORT + std 30, -16(31) # Save r30 to the stack + std 1, 0(8) + mr 30, 8 +#endif + +// Store gtid and tid to the stack because they're passed by reference to the microtask. + stw 4, -20(31) # Save gtid to the stack + stw 5, -24(31) # Save tid to the stack + + mr 12, 6 # r12 = argc + mr 4, 7 # r4 = p_argv + + cmpwi 0, 12, 1 + blt 0, .Lcall # if (argc < 1) goto .Lcall + + ld 5, 0(4) # r5 = p_argv[0] + + cmpwi 0, 12, 2 + blt 0, .Lcall # if (argc < 2) goto .Lcall + + ld 6, 8(4) # r6 = p_argv[1] + + cmpwi 0, 12, 3 + blt 0, .Lcall # if (argc < 3) goto .Lcall + + ld 7, 16(4) # r7 = p_argv[2] + + cmpwi 0, 12, 4 + blt 0, .Lcall # if (argc < 4) goto .Lcall + + ld 8, 24(4) # r8 = p_argv[3] + + cmpwi 0, 12, 5 + blt 0, .Lcall # if (argc < 5) goto .Lcall + + ld 9, 32(4) # r9 = p_argv[4] + + cmpwi 0, 12, 6 + blt 0, .Lcall # if (argc < 6) goto .Lcall + + ld 10, 40(4) # r10 = p_argv[5] + + cmpwi 0, 12, 7 + blt 0, .Lcall # if (argc < 7) goto .Lcall + +// There are more than 6 microtask parameters, so we need to store the +// remainder to the stack. + addi 12, 12, -6 # argc -= 6 + mtctr 12 + +// These are set to 8 bytes before the first desired store address (we're using +// pre-increment loads and stores in the loop below). The parameter save area +// for the microtask begins 48 + 8*8 == 112 bytes above r1 for XCOFF64. + addi 4, 4, 40 # p_argv = p_argv + 5 + # (i.e. skip the 5 elements we already processed) + addi 12, 1, 104 # r12 = stack offset (112 - 8) + +.Lnext: + ldu 0, 8(4) + stdu 0, 8(12) + bdnz .Lnext + +.Lcall: + std 2, 40(1) # Save the TOC pointer to the linkage area +// Load the actual function address from the function descriptor. + ld 12, 0(3) # Function address + ld 2, 8(3) # TOC pointer + ld 11, 16(3) # Environment pointer + + addi 3, 31, -20 # r3 = >id + addi 4, 31, -24 # r4 = &tid + + mtctr 12 # CTR = function address + bctrl # Branch to CTR + ld 2, 40(1) # Restore TOC pointer from linkage area + +#if OMPT_SUPPORT + li 3, 0 + std 3, 0(30) +#endif + + li 3, 1 + +#if OMPT_SUPPORT + ld 30, -16(31) # Restore r30 from the saved value on the stack +#endif + + mr 1, 31 + ld 31, -8(1) # Restore r31 from the saved value on the stack + ld 0, 16(1) + mtlr 0 # Restore LR from the linkage area + blr # Branch to LR + +#else // KMP_ARCH_PPC_XCOFF + + .globl __kmp_invoke_microtask[DS] + .globl .__kmp_invoke_microtask + .align 4 + .csect __kmp_invoke_microtask[DS],2 + .vbyte 4, .__kmp_invoke_microtask + .vbyte 4, TOC[TC0] + .vbyte 4, 0 + .csect .text[PR],2 + .machine "pwr7" +.__kmp_invoke_microtask: + + +// -- Begin __kmp_invoke_microtask +// mark_begin; + +// We need to allocate a stack frame large enough to hold all of the parameters +// on the stack for the microtask plus what this function needs. That's 24 +// bytes under the XCOFF ABI, plus max(32, 8*(2 + argc)) for +// the parameters to the microtask (gtid, tid, argc elements of p_argv), +// plus 8 bytes to store the values of r4 and r5, and 4 bytes to store r31. +// With OMP-T support, we need an additional 4 bytes to save r30 to hold +// a copy of r8. +// Stack offsets relative to stack pointer: +// r31: -4, r30: -8, gtid: -12, tid: -16 + + mflr 0 + stw 31, -4(1) # Save r31 to the stack + stw 0, 8(1) # Save LR to the linkage area + +// This is unusual because normally we'd set r31 equal to r1 after the stack +// frame is established. In this case, however, we need to dynamically compute +// the stack frame size, and so we keep a direct copy of r1 to access our +// register save areas and restore the r1 value before returning. + mr 31, 1 + +// Compute the size of the "argc" portion of the parameter save area. +// The parameter save area is always at least 32 bytes long (i.e. 8 regs) +// The microtask has (2 + argc) parameters, so if argc <= 6, we need to +// to allocate 4*6 bytes, not 4*argc. + li 0, 6 + cmpwi 0, 6, 6 + iselgt 0, 6, 0 # r0 = (argc > 6)? argc : 6 + slwi 0, 0, 2 # r0 = 4 * max(argc, 6) + +// Compute the size necessary for the local stack frame. +// 56 = 32 + 4 (for r4) + 4 (for r5) + 4 (for r31) + 4 (for OMP-T r30) + +// 4 (parameter gtid) + 4 (parameter tid) + li 12, 56 + add 12, 0, 12 + neg 12, 12 + +// We need to make sure that the stack frame stays aligned (to 16 bytes). + li 0, -16 + and 12, 0, 12 + +// Establish the local stack frame. + stwux 1, 1, 12 + +#if OMPT_SUPPORT + stw 30, -8(31) # Save r30 to the stack + stw 1, 0(8) + mr 30, 8 +#endif + +// Store gtid and tid to the stack because they're passed by reference to the microtask. + stw 4, -12(31) # Save gtid to the stack + stw 5, -16(31) # Save tid to the stack + + mr 12, 6 # r12 = argc + mr 4, 7 # r4 = p_argv + + cmpwi 0, 12, 1 + blt 0, .Lcall # if (argc < 1) goto .Lcall + + lwz 5, 0(4) # r5 = p_argv[0] + + cmpwi 0, 12, 2 + blt 0, .Lcall # if (argc < 2) goto .Lcall + + lwz 6, 4(4) # r6 = p_argv[1] + + cmpwi 0, 12, 3 + blt 0, .Lcall # if (argc < 3) goto .Lcall + + lwz 7, 8(4) # r7 = p_argv[2] + + cmpwi 0, 12, 4 + blt 0, .Lcall # if (argc < 4) goto .Lcall + + lwz 8, 12(4) # r8 = p_argv[3] + + cmpwi 0, 12, 5 + blt 0, .Lcall # if (argc < 5) goto .Lcall + + lwz 9, 16(4) # r9 = p_argv[4] + + cmpwi 0, 12, 6 + blt 0, .Lcall # if (argc < 6) goto .Lcall + + lwz 10, 20(4) # r10 = p_argv[5] + + cmpwi 0, 12, 7 + blt 0, .Lcall # if (argc < 7) goto .Lcall + +// There are more than 6 microtask parameters, so we need to store the +// remainder to the stack. + addi 12, 12, -6 # argc -= 6 + mtctr 12 + +// These are set to 4 bytes before the first desired store address (we're using +// pre-increment loads and stores in the loop below). The parameter save area +// for the microtask begins 24 + 4*8 == 56 bytes above r1 for XCOFF. + addi 4, 4, 20 # p_argv = p_argv + 5 + # (i.e. skip the 5 elements we already processed) + addi 12, 1, 52 # r12 = stack offset (56 - 4) + +.Lnext: + lwzu 0, 4(4) + stwu 0, 4(12) + bdnz .Lnext + +.Lcall: + stw 2, 20(1) # Save the TOC pointer to the linkage area +// Load the actual function address from the function descriptor. + lwz 12, 0(3) # Function address + lwz 2, 4(3) # TOC pointer + lwz 11, 8(3) # Environment pointer + + addi 3, 31, -12 # r3 = >id + addi 4, 31, -16 # r4 = &tid + + mtctr 12 # CTR = function address + bctrl # Branch to CTR + lwz 2, 20(1) # Restore TOC pointer from linkage area + +#if OMPT_SUPPORT + li 3, 0 + stw 3, 0(30) +#endif + + li 3, 1 + +#if OMPT_SUPPORT + lwz 30, -8(31) # Restore r30 from the saved value on the stack +#endif + + mr 1, 31 + lwz 31, -4(1) # Restore r31 from the saved value on the stack + lwz 0, 8(1) + mtlr 0 # Restore LR from the linkage area + blr # Branch to LR + +#endif // KMP_ARCH_PPC64_XCOFF + +.Lfunc_end0: + .vbyte 4, 0x00000000 # Traceback table begin + .byte 0x00 # Version = 0 + .byte 0x09 # Language = CPlusPlus + .byte 0x20 # -IsGlobaLinkage, -IsOutOfLineEpilogOrPrologue + # +HasTraceBackTableOffset, -IsInternalProcedure + # -HasControlledStorage, -IsTOCless + # -IsFloatingPointPresent + # -IsFloatingPointOperationLogOrAbortEnabled + .byte 0x61 # -IsInterruptHandler, +IsFunctionNamePresent, +IsAllocaUsed + # OnConditionDirective = 0, -IsCRSaved, +IsLRSaved + .byte 0x80 # +IsBackChainStored, -IsFixup, NumOfFPRsSaved = 0 +#if OMPT_SUPPORT + .byte 0x02 # -HasExtensionTable, -HasVectorInfo, NumOfGPRsSaved = 2 + .byte 0x06 # NumberOfFixedParms = 6 +#else + .byte 0x01 # -HasExtensionTable, -HasVectorInfo, NumOfGPRsSaved = 1 + .byte 0x05 # NumberOfFixedParms = 5 +#endif + .byte 0x01 # NumberOfFPParms = 0, +HasParmsOnStack + .vbyte 4, 0x00000000 # Parameter type = i, i, i, i, i + .vbyte 4, .Lfunc_end0-.__kmp_invoke_microtask # Function size + .vbyte 2, 0x0016 # Function name len = 22 + .byte "__kmp_invoke_microtask" # Function Name + .byte 0x1f # AllocaRegister = 31 + # -- End function + +// -- End __kmp_invoke_microtask + +// Support for unnamed common blocks. + + .comm .gomp_critical_user_, 32, 3 +#if KMP_ARCH_PPC64_XCOFF + .csect __kmp_unnamed_critical_addr[RW],3 +#else + .csect __kmp_unnamed_critical_addr[RW],2 +#endif + .globl __kmp_unnamed_critical_addr[RW] + .ptr .gomp_critical_user_ + +// -- End unnamed common block + + .toc + +#endif // KMP_OS_AIX diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index fd0a56bce1b7..1dd3c861dbb2 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define LLVM_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define CLANG_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" +#define LLDB_REVISION "llvmorg-18.1.0-rc3-0-g6c90f8dd5463" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index 153e86106f12..002ec1eecc00 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400006 -#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18.1.0-rc2-53-gc7b0a6ecd442-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "18.1.0 (FreeBSD llvmorg-18.1.0-rc3-0-g6c90f8dd5463-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index d06ac507357e..6950d566ff2f 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-18.1.0-rc2-53-gc7b0a6ecd442" *** 2 LINES SKIPPED *** From nobody Sat Apr 20 10:34:41 2024 X-Original-To: dev-commits-src-branches@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 4VM7Df1n9nz5HWVC; Sat, 20 Apr 2024 10:34:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dd5pbKz4Sns; Sat, 20 Apr 2024 10:34:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609281; 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=AokKR5AxOF65t7X2HLQ7nixG3ZYE8ls+ZNkX9wcqoZo=; b=uzo7vbQJ9bjZGQSwc6qB5n8sCUlvzsILzyhzFv9VsNew/2XKa8sAdz/nOeSE4Uh/PV3p3s ACo8XH3QksnZTwnu9JM8t9nTDnXGAsDBNZx8gmnr9/Glt9bo0btR1Nd7iroHHOVxqPio6o lmJS8PYZzycpE7JyPTjmHf+C21Fla/+EA9u5y7aVt7Dw5r5HF14Nq/0W3E9NomgeVFHJxV Wx2Jxx9Jx3HJ7Ai1eRZjIJ2jjUVyxCwhqjem8HXuncuTE3QJOc/C12fYRI4+xYLWK4K/FY ft9WxOMoFc9drieoQEiwp0bjTw96Hz82ryiNwT3Bfipeehd4f2eCHOXwQSuhhw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609281; a=rsa-sha256; cv=none; b=ZtTX+xkwv2F3/0uxdciKnrJWxQn3POLX9A2lJ9dhg1QhVz94lrnDrI/c/dkW74796etJRa S/HaG0dkGv6lS1rtnAIcfiSm0RaQIvuk0KHYXv8YUqaAwKUuIYqp7nf8ChsMY/rQ6H02Je wc/GHFBzmPza1vud10hlve93Q4WsDli8/cQY+f3obrcfyr/f2LcIMfoLh8PNbRy0A0SQEO EdDNXnX+9wVqs0qwiEuZqV4P18OUaAEVIoxauO7+2PCgtx881p2Nv4pxfuGJgZLtgP2LiZ hrOYb6LjPK72FkpLnor8QxKLApNdgP3AiCd5tm1Pwt0PtbieyyLkp8oZZPRbQg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609281; 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=AokKR5AxOF65t7X2HLQ7nixG3ZYE8ls+ZNkX9wcqoZo=; b=anUneuyJvwOMxaywOOgJPR9tJGAvHknJNYkcTzvANnGgN4L7WjEhwPzHB6zz74eCgGt1qD uPFw0xqHDssCrCkiGFM/NWmJyingLq7gjVyOVJvmE/x4SeTbcNBmffISf8Tt3sf7e/Omo1 OX27+K0ri8yeBJ2URRDPyC//zbun64XhvJ/jjEb680HXS07HZjPqnxsFi91FQGwLMsq/f1 3gDMjqLXKU9ReAfh14ANgd88Ubj9j+r47bUVAkfYJnd6s5xeCyR8zJxX4qUXCuwwWMh39H oVNkLvmutRrDToulAuD8/X524z/NLaHz/v+nAI9CUeNeNwGOOoTbo+VO/ENWow== 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 4VM7Dd5QJWzYn9; Sat, 20 Apr 2024 10:34:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYfc6014034; Sat, 20 Apr 2024 10:34:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYfkR014031; Sat, 20 Apr 2024 10:34:41 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:41 GMT Message-Id: <202404201034.43KAYfkR014031@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: b09953d54d75 - stable/13 - Merge llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: b09953d54d755297cf5c14f69c315bd4148d4153 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=b09953d54d755297cf5c14f69c315bd4148d4153 commit b09953d54d755297cf5c14f69c315bd4148d4153 Author: Dimitry Andric AuthorDate: 2024-03-10 12:37:50 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:47 +0000 Merge llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.1-0-gdba2a75e9c7e. PR: 276104 MFC after: 1 month (cherry picked from commit 4c2d3b022a1d543dbbff75a0c53e8d3d7242216d) --- .../llvm-project/clang/include/clang/Sema/Sema.h | 4 +- .../clang/lib/Basic/Targets/AArch64.cpp | 1 - .../llvm-project/clang/lib/Basic/Targets/Mips.h | 4 +- .../llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp | 11 +- contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp | 4 +- contrib/llvm-project/libcxx/include/csetjmp | 8 +- .../llvm/include/llvm/ADT/iterator_range.h | 4 +- .../llvm/include/llvm/IR/Attributes.td | 28 +- .../llvm/TargetParser/AArch64TargetParser.h | 8 +- contrib/llvm-project/llvm/lib/Analysis/Loads.cpp | 6 +- contrib/llvm-project/llvm/lib/IR/Attributes.cpp | 5 + .../llvm/lib/Target/AArch64/AArch64.td | 27 + .../llvm/lib/Target/AArch64/AArch64SchedA53.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedA57.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedA64FX.td | 3 +- .../lib/Target/AArch64/AArch64SchedAmpere1B.td | 1149 ++++++++++++++++++++ .../llvm/lib/Target/AArch64/AArch64SchedCyclone.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM3.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM4.td | 2 +- .../lib/Target/AArch64/AArch64SchedExynosM5.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedFalkor.td | 2 +- .../llvm/lib/Target/AArch64/AArch64SchedKryo.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseN1.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseN2.td | 2 +- .../lib/Target/AArch64/AArch64SchedNeoverseV1.td | 3 +- .../lib/Target/AArch64/AArch64SchedNeoverseV2.td | 3 +- .../llvm/lib/Target/AArch64/AArch64SchedTSV110.td | 2 +- .../lib/Target/AArch64/AArch64SchedThunderX.td | 2 +- .../lib/Target/AArch64/AArch64SchedThunderX2T99.td | 2 +- .../Target/AArch64/AArch64SchedThunderX3T110.td | 2 +- .../llvm/lib/Target/AArch64/AArch64Subtarget.cpp | 1 + .../llvm/lib/Target/AArch64/AArch64Subtarget.h | 1 + .../lib/Target/Mips/AsmParser/MipsAsmParser.cpp | 78 +- .../llvm/lib/Target/Mips/MipsISelLowering.cpp | 10 +- .../lib/Target/SystemZ/SystemZISelLowering.cpp | 5 +- .../llvm-project/llvm/lib/TargetParser/Host.cpp | 1 + .../llvm/lib/Transforms/Utils/FlattenCFG.cpp | 14 +- .../llvm/lib/Transforms/Utils/Local.cpp | 8 +- .../llvm/tools/llvm-cov/SourceCoverageView.cpp | 2 +- .../llvm/tools/llvm-cov/SourceCoverageViewHTML.cpp | 9 +- .../llvm/tools/llvm-cov/SourceCoverageViewText.cpp | 3 +- .../llvm/tools/llvm-readobj/ObjDumper.cpp | 26 +- .../llvm/tools/llvm-readobj/ObjDumper.h | 4 +- .../llvm-project/llvm/tools/llvm-readobj/Opts.td | 2 + .../llvm/tools/llvm-readobj/llvm-readobj.cpp | 6 +- .../llvm/utils/TableGen/Attributes.cpp | 6 +- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- lib/clang/liblldb/LLDBWrapLua.cpp | 162 +-- 54 files changed, 1501 insertions(+), 163 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/Sema/Sema.h b/contrib/llvm-project/clang/include/clang/Sema/Sema.h index 1f1cbd11ff73..6adb8fb7966b 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/Sema.h +++ b/contrib/llvm-project/clang/include/clang/Sema/Sema.h @@ -1090,7 +1090,9 @@ public: if (FD) { FD->setWillHaveBody(true); S.ExprEvalContexts.back().InImmediateFunctionContext = - FD->isImmediateFunction(); + FD->isImmediateFunction() || + S.ExprEvalContexts[S.ExprEvalContexts.size() - 2] + .isConstantEvaluated(); S.ExprEvalContexts.back().InImmediateEscalatingFunctionContext = S.getLangOpts().CPlusPlus20 && FD->isImmediateEscalating(); } else diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp index 3036f461c1de..f5a5d689fa09 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Targets/AArch64.cpp @@ -258,7 +258,6 @@ void AArch64TargetInfo::getTargetDefinesARMV83A(const LangOptions &Opts, MacroBuilder &Builder) const { Builder.defineMacro("__ARM_FEATURE_COMPLEX", "1"); Builder.defineMacro("__ARM_FEATURE_JCVT", "1"); - Builder.defineMacro("__ARM_FEATURE_PAUTH", "1"); // Also include the Armv8.2 defines getTargetDefinesARMV82A(Opts, Builder); } diff --git a/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h b/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h index f46b95abfd75..23d4e1b598fa 100644 --- a/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h +++ b/contrib/llvm-project/clang/lib/Basic/Targets/Mips.h @@ -237,12 +237,14 @@ public: case 'r': // CPU registers. case 'd': // Equivalent to "r" unless generating MIPS16 code. case 'y': // Equivalent to "r", backward compatibility only. - case 'f': // floating-point registers. case 'c': // $25 for indirect jumps case 'l': // lo register case 'x': // hilo register pair Info.setAllowsRegister(); return true; + case 'f': // floating-point registers. + Info.setAllowsRegister(); + return FloatABI != SoftFloat; case 'I': // Signed 16-bit constant case 'J': // Integer 0 case 'K': // Unsigned 16-bit constant diff --git a/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp b/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp index 5d7c38477457..fb4e86e8bd80 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CodeGenPGO.cpp @@ -240,9 +240,12 @@ struct MapRegionCounters : public RecursiveASTVisitor { if (MCDCMaxCond == 0) return true; - /// At the top of the logical operator nest, reset the number of conditions. - if (LogOpStack.empty()) + /// At the top of the logical operator nest, reset the number of conditions, + /// also forget previously seen split nesting cases. + if (LogOpStack.empty()) { NumCond = 0; + SplitNestedLogicalOp = false; + } if (const Expr *E = dyn_cast(S)) { const BinaryOperator *BinOp = dyn_cast(E->IgnoreParens()); @@ -293,7 +296,7 @@ struct MapRegionCounters : public RecursiveASTVisitor { "contains an operation with a nested boolean expression. " "Expression will not be covered"); Diag.Report(S->getBeginLoc(), DiagID); - return false; + return true; } /// Was the maximum number of conditions encountered? @@ -304,7 +307,7 @@ struct MapRegionCounters : public RecursiveASTVisitor { "number of conditions (%0) exceeds max (%1). " "Expression will not be covered"); Diag.Report(S->getBeginLoc(), DiagID) << NumCond << MCDCMaxCond; - return false; + return true; } // Otherwise, allocate the number of bytes required for the bitmap diff --git a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp index 0d9c087ed0cd..4cce0abc2315 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaExpr.cpp @@ -18294,7 +18294,6 @@ void Sema::CheckUnusedVolatileAssignment(Expr *E) { } void Sema::MarkExpressionAsImmediateEscalating(Expr *E) { - assert(!FunctionScopes.empty() && "Expected a function scope"); assert(getLangOpts().CPlusPlus20 && ExprEvalContexts.back().InImmediateEscalatingFunctionContext && "Cannot mark an immediate escalating expression outside of an " @@ -18311,7 +18310,8 @@ void Sema::MarkExpressionAsImmediateEscalating(Expr *E) { } else { assert(false && "expected an immediately escalating expression"); } - getCurFunction()->FoundImmediateEscalatingExpression = true; + if (FunctionScopeInfo *FI = getCurFunction()) + FI->FoundImmediateEscalatingExpression = true; } ExprResult Sema::CheckForImmediateInvocation(ExprResult E, FunctionDecl *Decl) { diff --git a/contrib/llvm-project/libcxx/include/csetjmp b/contrib/llvm-project/libcxx/include/csetjmp index d219c8e6cb22..9012cad22ebe 100644 --- a/contrib/llvm-project/libcxx/include/csetjmp +++ b/contrib/llvm-project/libcxx/include/csetjmp @@ -33,7 +33,13 @@ void longjmp(jmp_buf env, int val); #include <__assert> // all public C++ headers provide the assertion handler #include <__config> -#include +// is not provided by libc++ +#if __has_include() +# include +# ifdef _LIBCPP_SETJMP_H +# error "If libc++ starts defining , the __has_include check should move to libc++'s " +# endif +#endif #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) # pragma GCC system_header diff --git a/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h b/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h index 2dc227935984..7d288ea4506b 100644 --- a/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h +++ b/contrib/llvm-project/llvm/include/llvm/ADT/iterator_range.h @@ -43,8 +43,8 @@ class iterator_range { IteratorT begin_iterator, end_iterator; public: -#if __GNUC__ == 7 - // Be careful no to break gcc-7 on the mlir target. +#if __GNUC__ == 7 || (__GNUC__ == 8 && __GNUC_MINOR__ < 4) + // Be careful no to break gcc-7 and gcc-8 < 8.4 on the mlir target. // See https://github.com/llvm/llvm-project/issues/63843 template #else diff --git a/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td b/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td index 864f87f33838..d22eb76d2292 100644 --- a/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td +++ b/contrib/llvm-project/llvm/include/llvm/IR/Attributes.td @@ -339,14 +339,26 @@ def UseSampleProfile : StrBoolAttr<"use-sample-profile">; def DenormalFPMath : ComplexStrAttr<"denormal-fp-math", [FnAttr]>; def DenormalFPMathF32 : ComplexStrAttr<"denormal-fp-math-f32", [FnAttr]>; +// Attribute compatiblity rules are generated to check the attribute of the +// caller and callee and decide whether inlining should be allowed. CompatRule +// and child classes are used for the rule generation. CompatRule takes only a +// compare function which could be templated with the attribute type. +// CompatRuleStrAttr takes the compare function and the string attribute for +// checking compatibility for inline substitution. class CompatRule { - // The name of the function called to check the attribute of the caller and - // callee and decide whether inlining should be allowed. The function's - // signature must match "bool(const Function&, const Function &)", where the - // first parameter is the reference to the caller and the second parameter is - // the reference to the callee. It must return false if the attributes of the - // caller and callee are incompatible, and true otherwise. + // The function's signature must match "bool(const Function&, const + // Function&)", where the first parameter is the reference to the caller and + // the second parameter is the reference to the callee. It must return false + // if the attributes of the caller and callee are incompatible, and true + // otherwise. string CompatFunc = F; + string AttrName = ""; +} + +class CompatRuleStrAttr : CompatRule { + // The checker function is extended with an third argument as the function + // attribute string "bool(const Function&, const Function&, const StringRef&)". + string AttrName = Attr; } def : CompatRule<"isEqual">; @@ -359,7 +371,9 @@ def : CompatRule<"isEqual">; def : CompatRule<"isEqual">; def : CompatRule<"isEqual">; def : CompatRule<"checkDenormMode">; - +def : CompatRuleStrAttr<"isEqual", "sign-return-address">; +def : CompatRuleStrAttr<"isEqual", "sign-return-address-key">; +def : CompatRuleStrAttr<"isEqual", "branch-protection-pauth-lr">; class MergeRule { // The name of the function called to merge the attributes of the caller and diff --git a/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h b/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h index 6d82748d8004..c10f92e28717 100644 --- a/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h +++ b/contrib/llvm-project/llvm/include/llvm/TargetParser/AArch64TargetParser.h @@ -478,7 +478,7 @@ inline constexpr ArchInfo ARMV8_1A = { VersionTuple{8, 1}, AProfile, "armv8.1-a inline constexpr ArchInfo ARMV8_2A = { VersionTuple{8, 2}, AProfile, "armv8.2-a", "+v8.2a", (ARMV8_1A.DefaultExts | AArch64::ExtensionBitset({AArch64::AEK_RAS}))}; inline constexpr ArchInfo ARMV8_3A = { VersionTuple{8, 3}, AProfile, "armv8.3-a", "+v8.3a", (ARMV8_2A.DefaultExts | - AArch64::ExtensionBitset({AArch64::AEK_RCPC, AArch64::AEK_JSCVT, AArch64::AEK_FCMA}))}; + AArch64::ExtensionBitset({AArch64::AEK_FCMA, AArch64::AEK_JSCVT, AArch64::AEK_PAUTH, AArch64::AEK_RCPC}))}; inline constexpr ArchInfo ARMV8_4A = { VersionTuple{8, 4}, AProfile, "armv8.4-a", "+v8.4a", (ARMV8_3A.DefaultExts | AArch64::ExtensionBitset({AArch64::AEK_DOTPROD}))}; inline constexpr ArchInfo ARMV8_5A = { VersionTuple{8, 5}, AProfile, "armv8.5-a", "+v8.5a", (ARMV8_4A.DefaultExts)}; @@ -805,6 +805,12 @@ inline constexpr CpuInfo CpuInfos[] = { {AArch64::AEK_FP16, AArch64::AEK_RAND, AArch64::AEK_SM4, AArch64::AEK_SHA3, AArch64::AEK_SHA2, AArch64::AEK_AES, AArch64::AEK_MTE, AArch64::AEK_SB, AArch64::AEK_SSBS}))}, + {"ampere1b", ARMV8_7A, + (AArch64::ExtensionBitset({AArch64::AEK_FP16, AArch64::AEK_RAND, + AArch64::AEK_SM4, AArch64::AEK_SHA3, + AArch64::AEK_SHA2, AArch64::AEK_AES, + AArch64::AEK_MTE, AArch64::AEK_SB, + AArch64::AEK_SSBS, AArch64::AEK_CSSC}))}, }; // An alias for a CPU. diff --git a/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp b/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp index 6bf0d2f56eb4..5916d2ab48ec 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/Loads.cpp @@ -364,7 +364,7 @@ bool llvm::isSafeToLoadUnconditionally(Value *V, Align Alignment, APInt &Size, if (Size.getBitWidth() > 64) return false; - const uint64_t LoadSize = Size.getZExtValue(); + const TypeSize LoadSize = TypeSize::getFixed(Size.getZExtValue()); // Otherwise, be a little bit aggressive by scanning the local block where we // want to check to see if the pointer is already being loaded or stored @@ -414,11 +414,11 @@ bool llvm::isSafeToLoadUnconditionally(Value *V, Align Alignment, APInt &Size, // Handle trivial cases. if (AccessedPtr == V && - LoadSize <= DL.getTypeStoreSize(AccessedTy)) + TypeSize::isKnownLE(LoadSize, DL.getTypeStoreSize(AccessedTy))) return true; if (AreEquivalentAddressValues(AccessedPtr->stripPointerCasts(), V) && - LoadSize <= DL.getTypeStoreSize(AccessedTy)) + TypeSize::isKnownLE(LoadSize, DL.getTypeStoreSize(AccessedTy))) return true; } return false; diff --git a/contrib/llvm-project/llvm/lib/IR/Attributes.cpp b/contrib/llvm-project/llvm/lib/IR/Attributes.cpp index fd5160209506..19076771ff2e 100644 --- a/contrib/llvm-project/llvm/lib/IR/Attributes.cpp +++ b/contrib/llvm-project/llvm/lib/IR/Attributes.cpp @@ -2045,6 +2045,11 @@ static bool isEqual(const Function &Caller, const Function &Callee) { Callee.getFnAttribute(AttrClass::getKind()); } +static bool isEqual(const Function &Caller, const Function &Callee, + const StringRef &AttrName) { + return Caller.getFnAttribute(AttrName) == Callee.getFnAttribute(AttrName); +} + /// Compute the logical AND of the attributes of the caller and the /// callee. /// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td index 36700f73df4b..feabd137c0cf 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64.td @@ -837,6 +837,7 @@ include "AArch64SchedA64FX.td" include "AArch64SchedThunderX3T110.td" include "AArch64SchedTSV110.td" include "AArch64SchedAmpere1.td" +include "AArch64SchedAmpere1B.td" include "AArch64SchedNeoverseN1.td" include "AArch64SchedNeoverseN2.td" include "AArch64SchedNeoverseV1.td" @@ -1376,6 +1377,24 @@ def TuneAmpere1A : SubtargetFeature<"ampere1a", "ARMProcFamily", "Ampere1A", FeatureLdpAlignedOnly, FeatureStpAlignedOnly]>; +def TuneAmpere1B : SubtargetFeature<"ampere1b", "ARMProcFamily", "Ampere1B", + "Ampere Computing Ampere-1B processors", [ + FeaturePostRAScheduler, + FeatureFuseAES, + FeatureFuseAdrpAdd, + FeatureAddrLSLFast, + FeatureALULSLFast, + FeatureAggressiveFMA, + FeatureArithmeticBccFusion, + FeatureCmpBccFusion, + FeatureFuseAddress, + FeatureFuseLiterals, + FeatureStorePairSuppress, + FeatureEnableSelectOptimize, + FeaturePredictableSelectIsExpensive, + FeatureLdpAlignedOnly, + FeatureStpAlignedOnly]>; + def ProcessorFeatures { list A53 = [HasV8_0aOps, FeatureCRC, FeatureCrypto, FeatureFPARMv8, FeatureNEON, FeaturePerfMon]; @@ -1529,6 +1548,11 @@ def ProcessorFeatures { FeatureMTE, FeatureSSBS, FeatureRandGen, FeatureSB, FeatureSM4, FeatureSHA2, FeatureSHA3, FeatureAES]; + list Ampere1B = [HasV8_7aOps, FeatureNEON, FeaturePerfMon, + FeatureMTE, FeatureSSBS, FeatureRandGen, + FeatureSB, FeatureSM4, FeatureSHA2, + FeatureSHA3, FeatureAES, FeatureCSSC, + FeatureWFxT, FeatureFullFP16]; // ETE and TRBE are future architecture extensions. We temporarily enable them // by default for users targeting generic AArch64. The extensions do not @@ -1696,6 +1720,9 @@ def : ProcessorModel<"ampere1", Ampere1Model, ProcessorFeatures.Ampere1, def : ProcessorModel<"ampere1a", Ampere1Model, ProcessorFeatures.Ampere1A, [TuneAmpere1A]>; +def : ProcessorModel<"ampere1b", Ampere1BModel, ProcessorFeatures.Ampere1B, + [TuneAmpere1B]>; + //===----------------------------------------------------------------------===// // Assembly parser //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td index 3e4168f5f445..c714bad92b7f 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA53.td @@ -29,7 +29,7 @@ def CortexA53Model : SchedMachineModel { list UnsupportedFeatures = !listconcat(SVEUnsupported.F, PAUnsupported.F, SMEUnsupported.F, - [HasMTE]); + [HasMTE, HasCSSC]); } diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td index 277ec772cf0f..ebbc3b72b506 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA57.td @@ -34,7 +34,7 @@ def CortexA57Model : SchedMachineModel { list UnsupportedFeatures = !listconcat(SVEUnsupported.F, PAUnsupported.F, SMEUnsupported.F, - [HasMTE]); + [HasMTE, HasCSSC]); } //===----------------------------------------------------------------------===// diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td index 7edce4b61605..d6fe84a2c9c9 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedA64FX.td @@ -22,7 +22,8 @@ def A64FXModel : SchedMachineModel { list UnsupportedFeatures = !listconcat(SMEUnsupported.F, SVEUnsupported.F, [HasMTE, HasMatMulInt8, HasBF16, - HasPAuth, HasPAuthLR, HasCPA]); + HasPAuth, HasPAuthLR, HasCPA, + HasCSSC]); let FullInstRWOverlapCheck = 0; } diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td new file mode 100644 index 000000000000..9c4f000cf351 --- /dev/null +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64SchedAmpere1B.td @@ -0,0 +1,1149 @@ +//=- AArch64SchedAmpere1B.td - Ampere-1B scheduling def -----*- tablegen -*-=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// +// +// This file defines the machine model for the Ampere Computing Ampere-1B to +// support instruction scheduling and other instruction cost heuristics. +// +//===----------------------------------------------------------------------===// + +// The Ampere-1B core is an out-of-order micro-architecture. The front +// end has branch prediction, with a 10-cycle recovery time from a +// mispredicted branch. Instructions coming out of the front end are +// decoded into internal micro-ops (uops). + +def Ampere1BModel : SchedMachineModel { + let IssueWidth = 12; // Maximum micro-ops dispatch rate. + let MicroOpBufferSize = 192; // micro-op re-order buffer size + let LoadLatency = 3; // Optimistic load latency + let MispredictPenalty = 10; // Branch mispredict penalty + let LoopMicroOpBufferSize = 32; // Instruction queue size + let CompleteModel = 1; + + list UnsupportedFeatures = !listconcat(SVEUnsupported.F, + SMEUnsupported.F, + PAUnsupported.F); +} + +let SchedModel = Ampere1BModel in { + +//===----------------------------------------------------------------------===// +// Define each kind of processor resource and number available on Ampere-1B. + +def Ampere1BUnitA : ProcResource<2>; // integer single-cycle, branch, and flags r/w +def Ampere1BUnitB : ProcResource<2>; // integer single-cycle, and complex shifts +def Ampere1BUnitBS : ProcResource<1>; // integer multi-cycle +def Ampere1BUnitL : ProcResource<2>; // load +def Ampere1BUnitS : ProcResource<2>; // store address calculation +def Ampere1BUnitX : ProcResource<1>; // FP and vector operations, and flag write +def Ampere1BUnitY : ProcResource<1>; // FP and vector operations, and crypto +def Ampere1BUnitZ : ProcResource<1>; // FP store data and FP-to-integer moves + +def Ampere1BUnitAB : ProcResGroup<[Ampere1BUnitA, Ampere1BUnitB]>; +def Ampere1BUnitXY : ProcResGroup<[Ampere1BUnitX, Ampere1BUnitY]>; + +//===----------------------------------------------------------------------===// +// Define customized scheduler read/write types specific to the Ampere-1. + +def Ampere1BWrite_1cyc_1A : SchedWriteRes<[Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_2A : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1B : SchedWriteRes<[Ampere1BUnitB]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1BS_1B : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitB]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1AB : SchedWriteRes<[Ampere1BUnitAB]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1AB_1A : SchedWriteRes<[Ampere1BUnitAB, Ampere1BUnitA]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_1cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_1S : SchedWriteRes<[Ampere1BUnitS]> { + let Latency = 1; + let NumMicroOps = 1; +} + +def Ampere1BWrite_1cyc_2S : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS]> { + let Latency = 1; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1Y : SchedWriteRes<[Ampere1BUnitY]> { + let Latency = 2; + let NumMicroOps = 1; +} + +def Ampere1BWrite_2cyc_2AB : SchedWriteRes<[Ampere1BUnitAB, Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1AB : SchedWriteRes<[Ampere1BUnitB, Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1S : SchedWriteRes<[Ampere1BUnitB, Ampere1BUnitS]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_2cyc_1B_1S_1AB : SchedWriteRes<[Ampere1BUnitB, + Ampere1BUnitS, + Ampere1BUnitAB]> { + let Latency = 2; + let NumMicroOps = 3; +} + +def Ampere1BWrite_2cyc_1S_2Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ, + Ampere1BUnitZ]> { + let Latency = 2; + let NumMicroOps = 3; +} + +def Ampere1BWrite_2cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 2; + let NumMicroOps = 1; +} + +def Ampere1BWrite_2cyc_1S_1Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitZ]> { + let Latency = 2; + let NumMicroOps = 2; +} + +def Ampere1BWrite_3cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1Z : SchedWriteRes<[Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 1; +} + +def Ampere1BWrite_3cyc_1S_1Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 2; +} + +def Ampere1BWrite_3cyc_1S_2Z : SchedWriteRes<[Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 3; +} + +def Ampere1BWrite_3cyc_2S_2Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 3; + let NumMicroOps = 4; +} + +def Ampere1BWrite_4cyc_1BS_1AB : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitAB]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1L : SchedWriteRes<[Ampere1BUnitL]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_2L : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1L_1B : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitB]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_4cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_1XY : SchedWriteRes<[Ampere1BUnitXY]> { + let Latency = 4; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 4; + let NumMicroOps = 2; +} + +def Ampere1BWrite_5cyc_1BS : SchedWriteRes<[Ampere1BUnitBS]> { + let Latency = 5; + let NumMicroOps = 1; +} + +def Ampere1BWrite_4cyc_1XY_1S_1Z : SchedWriteRes<[Ampere1BUnitXY, + Ampere1BUnitS, + Ampere1BUnitZ]> { + let Latency = 4; + let NumMicroOps = 3; +} + +def Ampere1BWrite_4cyc_3S_3Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 4; + let NumMicroOps = 6; +} + +def Ampere1BWrite_5cyc_4S_4Z : SchedWriteRes<[Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 5; + let NumMicroOps = 8; +} + +def Ampere1BWrite_5cyc_1L_1BS : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitBS]> { + let Latency = 5; + let NumMicroOps = 2; +} + +def Ampere1BWrite_5cyc_3L : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL]> { + let Latency = 5; + let NumMicroOps = 3; +} + +def Ampere1BWrite_5cyc_4L : SchedWriteRes<[Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL, + Ampere1BUnitL]> { + let Latency = 5; + let NumMicroOps = 4; +} + +def Ampere1BWrite_5cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 5; + let NumMicroOps = 1; +} + +def Ampere1BWrite_5cyc_2XY_2S_2Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 5; + let NumMicroOps = 6; +} + +def Ampere1BWrite_6cyc_1BS_1A : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitA]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_1BS_2A : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitA, + Ampere1BUnitA]> { + let Latency = 6; + let NumMicroOps = 3; +} + +def Ampere1BWrite_6cyc_1L_1XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_2L_2XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 4; +} + +def Ampere1BWrite_6cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 2; +} + +def Ampere1BWrite_6cyc_3XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY]> { + let Latency = 6; + let NumMicroOps = 3; +} + +def Ampere1BWrite_6cyc_2XY_2S_2Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 6; + let NumMicroOps = 6; +} + +def Ampere1BWrite_6cyc_3XY_3S_3Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 6; + let NumMicroOps = 9; +} + +def Ampere1BWrite_7cyc_1BS_1XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_1XY_1Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_1X_1Z : SchedWriteRes<[Ampere1BUnitX, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 2; +} + +def Ampere1BWrite_7cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 6; +} + +def Ampere1BWrite_7cyc_4L_4XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 7; + let NumMicroOps = 8; +} + +def Ampere1BWrite_7cyc_4XY_4S_4Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 7; + let NumMicroOps = 12; +} + +def Ampere1BWrite_8cyc_1BS_1L : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitL]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_1BS_1XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_2L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 5; +} + +def Ampere1BWrite_8cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 6; +} + +def Ampere1BWrite_8cyc_4L_4XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 8; +} + +def Ampere1BWrite_8cyc_2XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 2; +} + +def Ampere1BWrite_8cyc_4XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 8; + let NumMicroOps = 4; +} + +def Ampere1BWrite_9cyc_6XY_4S_4Z : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitS, Ampere1BUnitS, + Ampere1BUnitZ, Ampere1BUnitZ, + Ampere1BUnitZ, Ampere1BUnitZ]> { + let Latency = 9; + let NumMicroOps = 14; +} + +def Ampere1BWrite_9cyc_1A_1BS_1X : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitBS, Ampere1BUnitX]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_9cyc_1A_1BS_1XY : SchedWriteRes<[Ampere1BUnitA, Ampere1BUnitBS, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_9cyc_3L_3XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 6; +} + +def Ampere1BWrite_9cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 9; + let NumMicroOps = 1; +} + +def Ampere1BWrite_9cyc_3XY : SchedWriteRes<[Ampere1BUnitXY, Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 9; + let NumMicroOps = 3; +} + +def Ampere1BWrite_10cyc_4L_8XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 10; + let NumMicroOps = 12; +} + +def Ampere1BWrite_11cyc_1BS_2XY : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 11; + let NumMicroOps = 3; +} + +def Ampere1BWrite_11cyc_4L_8XY : SchedWriteRes<[Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitL, Ampere1BUnitL, + Ampere1BUnitXY, Ampere1BUnitXY, + Ampere1BUnitXY, Ampere1BUnitXY]> { + let Latency = 11; + let NumMicroOps = 12; +} + +def Ampere1BWrite_12cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 12; + let NumMicroOps = 1; +} + +def Ampere1BWrite_13cyc_1BS_1X : SchedWriteRes<[Ampere1BUnitBS, Ampere1BUnitX]> { + let Latency = 13; + let NumMicroOps = 2; +} + +def Ampere1BWrite_17cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 17; + let NumMicroOps = 1; +} + +def Ampere1BWrite_19cyc_2BS_1X : SchedWriteRes<[Ampere1BUnitBS, + Ampere1BUnitBS, + Ampere1BUnitX]> { + let Latency = 13; + let NumMicroOps = 3; +} + +def Ampere1BWrite_19cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 19; + let NumMicroOps = 1; +} + +def Ampere1BWrite_21cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 21; + let NumMicroOps = 1; +} + +def Ampere1BWrite_33cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 33; + let NumMicroOps = 1; +} + +def Ampere1BWrite_39cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 39; + let NumMicroOps = 1; +} + +def Ampere1BWrite_63cyc_1X : SchedWriteRes<[Ampere1BUnitX]> { + let Latency = 63; + let NumMicroOps = 1; +} + +// For basic arithmetic, we have more flexibility for short shifts (LSL shift <= 4), +// which are a single uop, and for extended registers, which have full flexibility +// across Unit A or B for both uops. +def Ampere1BWrite_Arith : SchedWriteVariant<[ + SchedVar, + SchedVar, + SchedVar]>; + +def Ampere1BWrite_ArithFlagsetting : SchedWriteVariant<[ + SchedVar, + SchedVar, + SchedVar]>; + +//===----------------------------------------------------------------------===// +// Map the target-defined scheduler read/write resources and latencies for Ampere-1. +// This provides a coarse model, which is then specialised below. + +def : WriteRes; // MOVN, MOVZ +def : WriteRes; // ALU +def : WriteRes { + let Latency = 2; + let NumMicroOps = 2; +} // ALU of Shifted-Reg +def : WriteRes { *** 1567 LINES SKIPPED *** From nobody Sat Apr 20 10:34:43 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dh24ZVz5HW10; Sat, 20 Apr 2024 10:34: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dh049Tz4T9C; Sat, 20 Apr 2024 10:34:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609284; 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=UtOIF4gs1uDyhQ3UKOKltez/3Ve+QjJ0tuqNtRe7VxA=; b=iMUeGsvsx2SXU4huAKSW9hxj+/if0BUREh9gIpAuqEfCG97tukhoD/vmAUFeDvneRBTIcs mf00nMaFce9lqcexb8Eu/qV/SdHGD+y4scitLMTSttp/i7Hc+fFy0JxuQhpOWVqwFnij8G fChtZj9NNv/k4Zw/YmxngpShmv/Ic4GiUe0KWjYyLztJvszcsK2a/07+VitbR2rkigurd2 ZbKa362qclFMFcEM43YVws1iZSeNxfZixVKUplxX+RaQAu0J9pLBk60QtIjqhaD4YEzrWW csB5aUJ8G3KDC7txolKyI4AjvIBImBZi0aA4E4Oh4r/zTfJ2P8dGRFTz6YeGdQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609284; a=rsa-sha256; cv=none; b=mkW4rxWgYKHYB8q1qd8BqPkqj7yXJ7VhU06S0D2SqENBkuIBV9bA193vzQKgpuhMj/bxsr /eTAaeptP4VL7GZ7Pevz4Yzt7DekYLUb0SDfJY7va/hLIJnVExohYRyrca9bBX7BF9eYmq MF/9dAyjE2fVoyhDcoZ6g2lScDzvoX3tbhX8awLsdtiDS2qocMZmb7aak2UWWBjGDO0ptG I4hf38bJBZtXC/hxyR4UnKMgOhPilS+rgNkUsrJulFI5CgkopAR4Bh0ezlmsBn44nc+3bk 1T1Fv66Fx6VGyx23d8VDEonB/BqW51FzwmApDpffldfiALVntz4yl22HWqL1vQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609284; 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=UtOIF4gs1uDyhQ3UKOKltez/3Ve+QjJ0tuqNtRe7VxA=; b=aO4Zk3IXlPKzC1ACH5ApID8RlduGv2RfPtnrpcX2NQnp0f2vTz+NMhauZFQ3ZBEDjJBUBJ XDWxKqzogWdhFYEKrC9HBJqGvaBwq3F5bU1UhT51Cs0aHWSSLSxG5Iz75Qe9iMRqQXgR3I NJFxJGSV0cU8ipOmAvAiW+p8kIQ4MwZNXQ7GwcA9zvxDb+nOeEo2iMExuzUjPC9Y+NZ3wT URL5MLStgUEx6f32rurx/HPvqGUKGwjJDR0zj3mPSaHcJkosd/NxSnP/wlYyDJs0xlCCHE NHGpa+pAQ7yVHy4U+0lF8O6/tFpz+Uhownvot1/lnI2SgkwUu9ANMM/hBF0csQ== 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 4VM7Dg6p7mzYkl; Sat, 20 Apr 2024 10:34:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYhsZ014144; Sat, 20 Apr 2024 10:34:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYho4014141; Sat, 20 Apr 2024 10:34:43 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:43 GMT Message-Id: <202404201034.43KAYho4014141@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: 8e0b0a282739 - stable/13 - Merge commit f5f3d5d6534f from llvm-project (by Qizhi Hu): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 8e0b0a282739fadcc6cdec8bf1d8080c50f22bd0 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=8e0b0a282739fadcc6cdec8bf1d8080c50f22bd0 commit 8e0b0a282739fadcc6cdec8bf1d8080c50f22bd0 Author: Dimitry Andric AuthorDate: 2024-03-21 20:50:26 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:48 +0000 Merge commit f5f3d5d6534f from llvm-project (by Qizhi Hu): [Clang][Sema] Fix a crash in lambda instantiation (#85565) Fix https://github.com/llvm/llvm-project/issues/85343 When build lambda expression in lambda instantiation, `ThisType` is required in `Sema::CheckCXXThisCapture` to build `this` capture. Set `this` type by import `Sema::CXXThisScopeRAII` and it will be used later in lambda expression transformation. Co-authored-by: huqizhi <836744285@qq.com> This fixes 'Assertion failed: (!isNull() && "Cannot retrieve a NULL type pointer"), function getCommonPtr" when building the x11-wm/wayfire port. PR: 276104 MFC after: 1 month (cherry picked from commit 49a6e426df84eff1ae54905a02f66910a6a177d3) --- contrib/llvm-project/clang/lib/Sema/TreeTransform.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/contrib/llvm-project/clang/lib/Sema/TreeTransform.h b/contrib/llvm-project/clang/lib/Sema/TreeTransform.h index e55e752b9cc3..2f012cade6b9 100644 --- a/contrib/llvm-project/clang/lib/Sema/TreeTransform.h +++ b/contrib/llvm-project/clang/lib/Sema/TreeTransform.h @@ -13516,6 +13516,16 @@ TreeTransform::TransformLambdaExpr(LambdaExpr *E) { // Capturing 'this' is trivial. if (C->capturesThis()) { + // If this is a lambda that is part of a default member initialiser + // and which we're instantiating outside the class that 'this' is + // supposed to refer to, adjust the type of 'this' accordingly. + // + // Otherwise, leave the type of 'this' as-is. + Sema::CXXThisScopeRAII ThisScope( + getSema(), + dyn_cast_if_present( + getSema().getFunctionLevelDeclContext()), + Qualifiers()); getSema().CheckCXXThisCapture(C->getLocation(), C->isExplicit(), /*BuildAndDiagnose*/ true, nullptr, C->getCaptureKind() == LCK_StarThis); From nobody Sat Apr 20 10:34:42 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dg14r3z5HWXK; Sat, 20 Apr 2024 10:34:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dg01PXz4T4m; Sat, 20 Apr 2024 10:34:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609283; 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=hhKpvD7gDtDjuMbZ/Pr7SWtE+fnRFJ+Wk/hpvVCDq5c=; b=qheAwbyGOPTyOnMnrPd9+Inh38/1CJFhKPifm5tLyI3OmSz6qzJBt9y7tmBfVv2TqCFr8T /9ap/YaEz9AW2FA3E9CMd1rVkEgxe5mw4Ss0muX4JSmCiBrG08Vw3ngVzKgYdt/wq62XkN mUQ7MgSBFJnz0Xtk6y9YCNvDnD2G55NKAErtXaWS5WCRrCigF89g1GIPJfQalQu3mC9HJ7 6SPZRANjRUK9aAbBgsri22Y2yTpottMkZ0AUX6ZD0vhlOp5YEyR2M4v44g6GUPVSZo3sbo yC1V/YMgUr5qIKLjtvSRvudK3HOfy52XrkzS+K965s3YqH2OTMhj0rGg7jI91Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609283; a=rsa-sha256; cv=none; b=IFDUL0nRDQzdJUQjq/GRxkRuYkhVV2Uh282PR6bZ47NaqJoMDup4OpOxKOt+hHRpLXAYmN 1WHZonhCHRVmsuLb9QUKyKuqEr1U2YP3oIkNo84JCRCTcOifcOZqHyK2ly70x28SQJdTKH VAVF/IuIjWZ3B8FrE75YnlpJlvPUSxMqmdThuj/aztLGX6VF1t0wZu4J3btFFwxti5aspK kChY8aAtArSlLjyFkFSOqU/uQLYTyLpnEMyOeC9DZOUPTr0e1yRVo1q+x6Mu55YKaYVkpx KXoxynORIc7rQXO6ZkB5KF7yPwXwREpOLRzMDW5KioqeYv2eIYH/t2MaZnS7LQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609283; 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=hhKpvD7gDtDjuMbZ/Pr7SWtE+fnRFJ+Wk/hpvVCDq5c=; b=d649eRSYjtp6MwNLToD3Q1KLy5djs5kE/ZbLCw1c1dbXHxtF80zRmffUbnUk4VZbTxXD0d agWMZz6jSiFwMoBym/Bx+cbemWNIQn4WexJcexWec3JGqVOKdMi6LRGzeZ1T8CH3DWVIqb tZy/KaKbSybakGI3corKI9fop2Wb5zGqcJavbWTmFhBPvrH6ROnlY7NuCoqEoffKgHd8cq O5dNGIDw/sb+6S+SDuJVRf/CYC94tuWroKie8vt0sVycqwu8C28D4ZlB+Sp+UYnJQfDPfT /0uwNvvhMCw2nQcw6bo+RVn10QBdvlbNgXYPbi8ybbNUWN9Vd1oNYTJ7Jv/ZGw== 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 4VM7Df6SkPzYr8; Sat, 20 Apr 2024 10:34:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYgW0014087; Sat, 20 Apr 2024 10:34:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYg9p014084; Sat, 20 Apr 2024 10:34:42 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:42 GMT Message-Id: <202404201034.43KAYg9p014084@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: 64816cf50d5e - stable/13 - Revert commit 6255157d24e2 from llvm-project (by Dimitry Andric): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 64816cf50d5e571e64f5d8a4143f05192788d09b Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=64816cf50d5e571e64f5d8a4143f05192788d09b commit 64816cf50d5e571e64f5d8a4143f05192788d09b Author: Dimitry Andric AuthorDate: 2024-03-19 13:07:27 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:48 +0000 Revert commit 6255157d24e2 from llvm-project (by Dimitry Andric): [libc++] Re-enable std::pair trivial copy constructor for FreeBSD >= 14 After many years of using the really old std::pair ABI which did not yet have a trivial copy constructor, FreeBSD 14 and later will finally get rid of it. Only use the old ABI for FreeBSD 13 and earlier. Note: on the FreeBSD side, we will bump our libc++.so version for this, and keep an old compatibility library in a separate package. Differential Revision: https://reviews.llvm.org/D126462 This ABI change can cause crashes when binaries compiled against older libc++ versions are run against binaries compiled against this libc++ version. For example, lang/ldc uses a precompiled bootstrap ldc2 binary that was compiled against the old libc++, but also links against libLLVM-15.so. If libLLVM-15.so is compiled against the new libc++ version, the ABI mismatch results in segfaults or even stack overflows. Note: we can only re-enable the std::pair trivial copy constructors again when the official libc++ ABI version is bumped to 2. PR: 276104 MFC after: 1 month (cherry picked from commit ce4f1f49e036fd806b534decfe38020dae32a384) --- contrib/llvm-project/libcxx/include/__config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index fa5535facb14..a5981984d37e 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -190,7 +190,7 @@ # endif // Feature macros for disabling pre ABI v1 features. All of these options // are deprecated. -# if defined(__FreeBSD__) && __FreeBSD__ < 14 +# if defined(__FreeBSD__) # define _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR # endif // For XCOFF linkers, we have problems if we see a weak hidden version of a symbol From nobody Sat Apr 20 10:34:46 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dl0Q6pz5HW1L; Sat, 20 Apr 2024 10:34:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dk4fVNz4TGd; Sat, 20 Apr 2024 10:34:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609286; 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=hhejDw/5ylgQk/gmUmaulv0/oXFlYDIo9apL9YZXYyM=; b=tCM6I6m/MyosYwEl9RhUUcizLKa16vn3ZDY7YIrw533nKapudvM/VsorX+UhLbuU/6FRLF NoniZ1QtaqhiUJnkAuzI4rkLHonPumHUwFQNTt4OY6zJtEL7v7KajmH7q8lEuyS9T1CMcT u5eVOKS161V0wCbPMz/tBYwV/GKc+HO2Zm//MwTnZSRFlJTNYJ8jiQkSJEwqXrGSiHRN0J GOWHI+aFNUScNFKBQQtbFJBzbgM0Vbk9WkFrd+JLdJla5Q8neASSXbJsHyO3EVft6xHu/X EgiUz/N37hdyCbm+Excu7egQYUYJr8RVYh8SAf9N8tu3EeO83uZZUhBgbkYaPQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609286; a=rsa-sha256; cv=none; b=xbhfdat3Cu04FDG4kEBX4xal3nYr+VfevoSDnonJaSzk9NdmHK2/cK06qMLqdYS4R9Ymyl uzId0N1CBuTxPryzgjgp0llf7LMNU4u3uQed9w7UEzW1TsyI8HJ70/FaY0ytzCJxzdPTTE j0uX+eTo3ZF5qBxkKpPJMgWL+1cUd7nDCEvbFCT7rvP4A3jxQuzW4XvjoeJkD/+XIQpEEv t3jVmiR3PU+VdWXmQrda3iKALGtKs+2T+tbXKvsOVFUZS+twEesLaf+hikBjJmOpORjpwu 7ImaYP0LBqgrt/X4uQSGAczlFE/TLxoW/ivz+Qfi9X4MJ62DuZYFvKdQWzNDqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609286; 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=hhejDw/5ylgQk/gmUmaulv0/oXFlYDIo9apL9YZXYyM=; b=YLGR21TcTVW8W6m70bvTNp8yUIxVHHpQ7NRX6SEwHYPnuCvFl2ngQfW7+0aDUBslUxqk1Z lCh0RXXtkjmx8/C352xk7p4zNOpy9RvJIiA3hbYrO3J6fsYcSaGpHtr3mMdCymvm0yX4sY BseUKQ5j9P/1kyxDHz2KWcTS5VWeRxkzNcQVwckAbrWOjCMqGEAa4xKlgjVJNd1xuUPqkZ HilTCnsCJUVKtIS2dFQRqDAJwMKpKI8vyvNEvb2urW5Og7kc9s+HvhqPNXhK2LjLohvHDU ICzHPHA8NFRYJHWFS93NgH9/cmgzhPnw8UvBEsEW7PvLo86Hzl8Skiwr4UHIlw== 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 4VM7Dk3znPzYnD; Sat, 20 Apr 2024 10:34:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYkbS014234; Sat, 20 Apr 2024 10:34:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYkh6014231; Sat, 20 Apr 2024 10:34:46 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:46 GMT Message-Id: <202404201034.43KAYkh6014231@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: 7b86b92ec1bd - stable/13 - Fix arm64 build after llvm 18.1.3 upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 7b86b92ec1bdfad552ece3eaa28bd8d28dff9a82 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=7b86b92ec1bdfad552ece3eaa28bd8d28dff9a82 commit 7b86b92ec1bdfad552ece3eaa28bd8d28dff9a82 Author: Dimitry Andric AuthorDate: 2024-04-07 00:07:38 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 Fix arm64 build after llvm 18.1.3 upgrade Apparently clang 18 has become more strict about using floating point registers in inline assembly when -mgeneral-regs-only is used. This causes sys/arm64/arm64/vfp.c to fail to compile, with "error: instruction requires: fp-armv8", and "error: expected readable system register". To fix it, similar to other files compiled for arm64, disable -mgeneral-regs-only for this particular file. PR: 276104 MFC after: 1 month (cherry picked from commit f4d93b67611f6f8b19db7bac6b0973b2ef0cfcb6) --- sys/conf/files.arm64 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64 index bb593a8f9a01..f72f5718ac19 100644 --- a/sys/conf/files.arm64 +++ b/sys/conf/files.arm64 @@ -76,7 +76,8 @@ arm64/arm64/uio_machdep.c standard arm64/arm64/uma_machdep.c standard arm64/arm64/undefined.c standard arm64/arm64/unwind.c optional ddb | kdtrace_hooks | stack -arm64/arm64/vfp.c standard +arm64/arm64/vfp.c standard \ + compile-with "${NORMAL_C:N-mgeneral-regs-only}" arm64/arm64/vm_machdep.c standard arm64/coresight/coresight.c standard From nobody Sat Apr 20 10:34:45 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dj5fdsz5HW18; Sat, 20 Apr 2024 10:34:45 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dj3HBSz4T10; Sat, 20 Apr 2024 10:34:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609285; 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=WdErGcY13ffisn/cxozXyz811VHmuhrba14Kc8TbN/M=; b=xl6MT6Ea9WalnxodOPpO0GnXxNbZY4FPOdW5rLSXfGxJVmfBptQNmOaF196UVSkceAFUt5 c4fXqS/wQw5eE1bR1a1Sk/m3WHIxQ994/mODTnp9a9W8my2kW1szGlvjkVQD1jQz5AERNv ZAdoQnCJqv5ne0MvKNu6GD/BFqDhecdv0sZqRY6cbk/nvboaDVnlDIdFi6E3xbg8rSlwMH RxwQEvsi/T0XvAZrN3Clstc78FQoelPX8tkfbu17NXkVWkk1/mJsGrkroRVFit44JZrfqH WRCLGkSVJnbJBAaLnasN/Be4RvPSLC33AWOQYYVX/vj+UcUIahthN5Os9CgUJw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609285; a=rsa-sha256; cv=none; b=J6w861I+FRkWeRyj+yyDG116t8wlDh7jpxuiJ7PLka86MFrKI9StVTArsBEkLQyYx5rxbF Wbc24b9u8SXuZ8SaoLeCFG+HGzGGpx1HpfomnvvnBBvssgMmNRS9qcJPXqY6Tlm3UX8Azp tXjjJXpC5YIr+xkaXbJhCViCM9rA0qB9FuQw+WdWocJgdH4PcmmiYUePGZBYRVRYYz92po idGELrTpVtK/An+bA+0SkwRNGpW1JdQKIyqHyD3Pnl9oKaec7LptJKcmMRImqdkPuQiG1X U4mCDfLnV9oSWEwQuqscA0SqNZA25I66KAywCeQxUNp4YbzCV4Z7y6VS0jftmg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609285; 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=WdErGcY13ffisn/cxozXyz811VHmuhrba14Kc8TbN/M=; b=VKcjNdq36JMYEQ/B2eyNMkw8kHsFn6p9Q6pQJ99Cw8v7pR3bo/aWBYvyBg8L8zitrw64Ks l+mcsx2ovwOFRZ0fjtjb7XRcheMw4kh0Mp9s0FQSg6b8mkvd+DgGArv8jFnfcepqbtCdFU 9zCp5U/a65oz2dcSpvYnNR/eBDHTAnNep7k81JwKJ6b7iuyky2yhaP1m0lM1xVI6XxwjDM xk5ODuoMLh17ARV7RsRCzX7weIMk8S3ROCHmc6qdDEQic9wffwwQ7rTVG2I8TbvEvDvBqu CAeN3/L9eaC8IHZSPhFy+rg0whTVca7gW2HIZoqmoHKwmeATQ2PwF/VTHrxFgw== 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 4VM7Dj2ts2zYr9; Sat, 20 Apr 2024 10:34:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYjal014183; Sat, 20 Apr 2024 10:34:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYjEI014180; Sat, 20 Apr 2024 10:34:45 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:45 GMT Message-Id: <202404201034.43KAYjEI014180@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: 3a287a03cf4a - stable/13 - Merge llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 3a287a03cf4a1ff66b247b4ac880b9a8914faacf Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=3a287a03cf4a1ff66b247b4ac880b9a8914faacf commit 3a287a03cf4a1ff66b247b4ac880b9a8914faacf Author: Dimitry Andric AuthorDate: 2024-04-05 22:02:56 +0000 Commit: Dimitry Andric CommitDate: 2024-04-19 21:24:48 +0000 Merge llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/18.x llvmorg-18.1.3-0-gc13b7485b879. PR: 276104 MFC after: 1 month (cherry picked from commit 439352ac8257c8419cb4a662abb7f260f31f9932) --- .../clang/include/clang/AST/DeclBase.h | 10 ++ .../clang/include/clang/Sema/ScopeInfo.h | 4 +- .../clang/include/clang/Serialization/ASTReader.h | 7 -- contrib/llvm-project/clang/lib/AST/Decl.cpp | 2 +- contrib/llvm-project/clang/lib/AST/DeclBase.cpp | 5 + contrib/llvm-project/clang/lib/Basic/Module.cpp | 7 +- .../llvm-project/clang/lib/CodeGen/BackendUtil.cpp | 32 ++--- contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp | 43 ++++--- .../clang/lib/Driver/ToolChains/WebAssembly.cpp | 27 ++++- .../clang/lib/Driver/ToolChains/WebAssembly.h | 2 +- .../llvm-project/clang/lib/Headers/__stddef_null.h | 2 +- .../clang/lib/Headers/__stddef_nullptr_t.h | 7 +- .../clang/lib/Headers/__stddef_offsetof.h | 7 +- .../clang/lib/Headers/__stddef_ptrdiff_t.h | 7 +- .../clang/lib/Headers/__stddef_rsize_t.h | 7 +- .../clang/lib/Headers/__stddef_size_t.h | 7 +- .../clang/lib/Headers/__stddef_unreachable.h | 7 +- .../clang/lib/Headers/__stddef_wchar_t.h | 7 +- .../llvm-project/clang/lib/Headers/larchintrin.h | 2 +- .../clang/lib/Headers/module.modulemap | 20 ++-- contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp | 9 +- contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 73 +++++++----- .../llvm-project/clang/lib/Sema/SemaOverload.cpp | 22 +++- .../llvm-project/clang/lib/Sema/SemaTemplate.cpp | 22 +++- .../clang/lib/Serialization/ASTReader.cpp | 2 +- .../clang/lib/Serialization/ASTReaderDecl.cpp | 8 +- .../clang/lib/Serialization/ASTWriter.cpp | 2 +- .../clang/lib/Serialization/ASTWriterDecl.cpp | 8 +- .../clang/lib/StaticAnalyzer/Core/CallEvent.cpp | 2 +- .../llvm-project/compiler-rt/lib/builtins/divtc3.c | 2 +- .../llvm-project/compiler-rt/lib/builtins/fp_lib.h | 41 ++++--- .../compiler-rt/lib/builtins/int_types.h | 8 +- .../llvm-project/compiler-rt/lib/builtins/multc3.c | 2 +- contrib/llvm-project/compiler-rt/lib/msan/msan.cpp | 2 +- contrib/llvm-project/compiler-rt/lib/msan/msan.h | 35 ++++-- .../compiler-rt/lib/msan/msan_allocator.cpp | 3 + .../compiler-rt/lib/msan/msan_linux.cpp | 67 ++++++++--- .../lib/tsan/rtl/tsan_interceptors_posix.cpp | 43 +++---- contrib/llvm-project/libcxx/include/__availability | 7 +- .../llvm-project/libcxx/modules/modules.json.in | 2 +- contrib/llvm-project/lld/COFF/DLL.cpp | 2 +- contrib/llvm-project/lld/ELF/Arch/LoongArch.cpp | 22 ++++ contrib/llvm-project/lld/ELF/Arch/PPC64.cpp | 3 +- contrib/llvm-project/lld/ELF/Arch/RISCV.cpp | 2 + contrib/llvm-project/lld/ELF/Arch/X86_64.cpp | 7 +- contrib/llvm-project/lld/ELF/Writer.cpp | 3 + contrib/llvm-project/lld/docs/ReleaseNotes.rst | 5 + .../llvm/include/llvm/Analysis/VectorUtils.h | 5 + .../llvm/include/llvm/BinaryFormat/COFF.h | 5 +- .../llvm-project/llvm/include/llvm/Object/COFF.h | 41 +++++++ .../llvm/include/llvm/Object/COFFImportFile.h | 35 +++++- .../llvm/include/llvm/Support/FormattedStream.h | 51 ++++++-- .../llvm/include/llvm/Target/TargetSchedule.td | 2 +- .../llvm/lib/Analysis/ValueTracking.cpp | 2 + .../llvm-project/llvm/lib/Analysis/VectorUtils.cpp | 25 ++++ .../llvm/lib/MC/MCParser/AsmParser.cpp | 4 +- .../llvm-project/llvm/lib/Object/ArchiveWriter.cpp | 11 ++ .../llvm/lib/Object/COFFImportFile.cpp | 114 +++++++++++++----- .../llvm/lib/Support/FormattedStream.cpp | 3 + .../Target/AArch64/AArch64Arm64ECCallLowering.cpp | 57 ++++++--- .../lib/Target/AArch64/AArch64CallingConvention.td | 3 + .../lib/Target/AArch64/AArch64ISelLowering.cpp | 10 +- .../llvm/lib/Target/AArch64/AArch64MCInstLower.cpp | 2 + .../lib/Target/AArch64/Utils/AArch64BaseInfo.h | 28 ----- .../llvm/lib/Target/ARM/ARMFrameLowering.cpp | 11 +- .../llvm/lib/Target/ARM/ARMFrameLowering.h | 4 + .../llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp | 23 ++-- .../llvm/lib/Target/AVR/AVRInstrInfo.td | 2 +- .../lib/Target/LoongArch/LoongArchISelLowering.cpp | 9 +- .../lib/Target/LoongArch/LoongArchISelLowering.h | 2 + .../lib/Target/LoongArch/LoongArchTargetMachine.h | 5 + .../Mips/MCTargetDesc/MipsTargetStreamer.cpp | 12 +- .../llvm/lib/Target/Mips/MipsExpandPseudo.cpp | 60 ++++++++-- .../llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 6 - .../llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 1 + .../llvm/lib/Target/RISCV/RISCVISelLowering.cpp | 20 ++-- .../lib/Target/RISCV/RISCVTargetTransformInfo.cpp | 3 + .../lib/Target/SystemZ/SystemZISelLowering.cpp | 34 ++++++ .../llvm/lib/Target/X86/X86ISelLowering.cpp | 11 +- .../llvm/lib/Target/X86/X86InstrVecCompiler.td | 3 + .../llvm/lib/Target/X86/X86TargetTransformInfo.cpp | 4 + .../llvm/lib/Transforms/IPO/ArgumentPromotion.cpp | 6 +- .../Transforms/InstCombine/InstCombineCalls.cpp | 13 ++- .../Transforms/InstCombine/InstCombineCasts.cpp | 4 +- .../Transforms/InstCombine/InstCombineCompares.cpp | 7 ++ .../Transforms/InstCombine/InstCombineSelect.cpp | 9 +- .../InstCombine/InstructionCombining.cpp | 1 + .../Transforms/Instrumentation/ThreadSanitizer.cpp | 9 +- .../lib/Transforms/Scalar/DeadStoreElimination.cpp | 31 ++++- .../llvm/lib/Transforms/Scalar/SROA.cpp | 80 ++++++++----- .../llvm-project/llvm/tools/llvm-mc/llvm-mc.cpp | 5 - .../llvm/tools/llvm-objdump/llvm-objdump.cpp | 7 -- .../llvm/tools/llvm-readobj/COFFImportDumper.cpp | 6 + .../TableGen/MacroFusionPredicatorEmitter.cpp | 12 +- contrib/llvm-project/openmp/runtime/src/kmp.h | 8 +- .../openmp/runtime/src/kmp_affinity.cpp | 129 +++++++++++++++++++-- .../llvm-project/openmp/runtime/src/kmp_affinity.h | 73 +++++++++++- contrib/llvm-project/openmp/runtime/src/kmp_lock.h | 3 +- contrib/llvm-project/openmp/runtime/src/kmp_os.h | 3 +- .../openmp/runtime/src/z_Linux_util.cpp | 37 +++++- lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 107 files changed, 1266 insertions(+), 431 deletions(-) diff --git a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h index 9a4736019d1b..eb7a1a320600 100644 --- a/contrib/llvm-project/clang/include/clang/AST/DeclBase.h +++ b/contrib/llvm-project/clang/include/clang/AST/DeclBase.h @@ -673,6 +673,16 @@ public: /// fragment. See [module.global.frag]p3,4 for details. bool isDiscardedInGlobalModuleFragment() const { return false; } + /// Check if we should skip checking ODRHash for declaration \param D. + /// + /// The existing ODRHash mechanism seems to be not stable enough and + /// the false positive ODR violation reports are annoying and we rarely see + /// true ODR violation reports. Also we learned that MSVC disabled ODR checks + /// for declarations in GMF. So we try to disable ODR checks in the GMF to + /// get better user experiences before we make the ODR violation checks stable + /// enough. + bool shouldSkipCheckingODR() const; + /// Return true if this declaration has an attribute which acts as /// definition of the entity, such as 'alias' or 'ifunc'. bool hasDefiningAttr() const; diff --git a/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h b/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h index 6eaa74382685..06e47eed4e93 100644 --- a/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h +++ b/contrib/llvm-project/clang/include/clang/Sema/ScopeInfo.h @@ -925,8 +925,8 @@ public: /// that were defined in parent contexts. Used to avoid warnings when the /// shadowed variables are uncaptured by this lambda. struct ShadowedOuterDecl { - const VarDecl *VD; - const VarDecl *ShadowedDecl; + const NamedDecl *VD; + const NamedDecl *ShadowedDecl; }; llvm::SmallVector ShadowingDecls; diff --git a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h index cd28226c295b..62c25f5b7a0d 100644 --- a/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h +++ b/contrib/llvm-project/clang/include/clang/Serialization/ASTReader.h @@ -2451,13 +2451,6 @@ private: uint32_t Value; uint32_t CurrentBitsIndex = ~0; }; - -inline bool shouldSkipCheckingODR(const Decl *D) { - return D->getOwningModule() && - D->getASTContext().getLangOpts().SkipODRCheckInGMF && - D->getOwningModule()->isExplicitGlobalModule(); -} - } // namespace clang #endif // LLVM_CLANG_SERIALIZATION_ASTREADER_H diff --git a/contrib/llvm-project/clang/lib/AST/Decl.cpp b/contrib/llvm-project/clang/lib/AST/Decl.cpp index 26fdfa040796..1ee33fd7576d 100644 --- a/contrib/llvm-project/clang/lib/AST/Decl.cpp +++ b/contrib/llvm-project/clang/lib/AST/Decl.cpp @@ -4476,7 +4476,7 @@ unsigned FunctionDecl::getODRHash() { } class ODRHash Hash; - Hash.AddFunctionDecl(this); + Hash.AddFunctionDecl(this, /*SkipBody=*/shouldSkipCheckingODR()); setHasODRHash(true); ODRHash = Hash.CalculateHash(); return ODRHash; diff --git a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp index 8163f9bdaf8d..6b3c13ff206d 100644 --- a/contrib/llvm-project/clang/lib/AST/DeclBase.cpp +++ b/contrib/llvm-project/clang/lib/AST/DeclBase.cpp @@ -1102,6 +1102,11 @@ bool Decl::isInAnotherModuleUnit() const { return M != getASTContext().getCurrentNamedModule(); } +bool Decl::shouldSkipCheckingODR() const { + return getASTContext().getLangOpts().SkipODRCheckInGMF && getOwningModule() && + getOwningModule()->isExplicitGlobalModule(); +} + static Decl::Kind getKind(const Decl *D) { return D->getKind(); } static Decl::Kind getKind(const DeclContext *DC) { return DC->getDeclKind(); } diff --git a/contrib/llvm-project/clang/lib/Basic/Module.cpp b/contrib/llvm-project/clang/lib/Basic/Module.cpp index 925217431d4d..0dac8748a98a 100644 --- a/contrib/llvm-project/clang/lib/Basic/Module.cpp +++ b/contrib/llvm-project/clang/lib/Basic/Module.cpp @@ -301,10 +301,9 @@ bool Module::directlyUses(const Module *Requested) { if (Requested->isSubModuleOf(Use)) return true; - // Anyone is allowed to use our builtin stdarg.h and stddef.h and their - // accompanying modules. - if (Requested->getTopLevelModuleName() == "_Builtin_stdarg" || - Requested->getTopLevelModuleName() == "_Builtin_stddef") + // Anyone is allowed to use our builtin stddef.h and its accompanying modules. + if (Requested->fullModuleNameIs({"_Builtin_stddef", "max_align_t"}) || + Requested->fullModuleNameIs({"_Builtin_stddef_wint_t"})) return true; if (NoUndeclaredIncludes) diff --git a/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp b/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp index 7877e20d77f7..4f22d35f9d3a 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/BackendUtil.cpp @@ -186,6 +186,14 @@ class EmitAssemblyHelper { TargetTriple.getVendor() != llvm::Triple::Apple; } + /// Check whether we should emit a flag for UnifiedLTO. + /// The UnifiedLTO module flag should be set when UnifiedLTO is enabled for + /// ThinLTO or Full LTO with module summaries. + bool shouldEmitUnifiedLTOModueFlag() const { + return CodeGenOpts.UnifiedLTO && + (CodeGenOpts.PrepareForThinLTO || shouldEmitRegularLTOSummary()); + } + public: EmitAssemblyHelper(DiagnosticsEngine &_Diags, const HeaderSearchOptions &HeaderSearchOpts, @@ -1029,7 +1037,8 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!actionRequiresCodeGen(Action) && CodeGenOpts.VerifyModule) MPM.addPass(VerifierPass()); - if (Action == Backend_EmitBC || Action == Backend_EmitLL) { + if (Action == Backend_EmitBC || Action == Backend_EmitLL || + CodeGenOpts.FatLTO) { if (CodeGenOpts.PrepareForThinLTO && !CodeGenOpts.DisableLLVMPasses) { if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", @@ -1040,11 +1049,9 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!ThinLinkOS) return; } - if (CodeGenOpts.UnifiedLTO) - TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); MPM.addPass(ThinLTOBitcodeWriterPass( *OS, ThinLinkOS ? &ThinLinkOS->os() : nullptr)); - } else { + } else if (Action == Backend_EmitLL) { MPM.addPass(PrintModulePass(*OS, "", CodeGenOpts.EmitLLVMUseLists, /*EmitLTOSummary=*/true)); } @@ -1058,24 +1065,17 @@ void EmitAssemblyHelper::RunOptimizationPipeline( if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", uint32_t(1)); - if (CodeGenOpts.UnifiedLTO) - TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); } - if (Action == Backend_EmitBC) + if (Action == Backend_EmitBC) { MPM.addPass(BitcodeWriterPass(*OS, CodeGenOpts.EmitLLVMUseLists, EmitLTOSummary)); - else + } else if (Action == Backend_EmitLL) { MPM.addPass(PrintModulePass(*OS, "", CodeGenOpts.EmitLLVMUseLists, EmitLTOSummary)); + } } - } - if (CodeGenOpts.FatLTO) { - // Set the EnableSplitLTOUnit and UnifiedLTO module flags, since FatLTO - // uses a different action than Backend_EmitBC or Backend_EmitLL. - if (!TheModule->getModuleFlag("EnableSplitLTOUnit")) - TheModule->addModuleFlag(llvm::Module::Error, "EnableSplitLTOUnit", - uint32_t(CodeGenOpts.EnableSplitLTOUnit)); - if (CodeGenOpts.UnifiedLTO && !TheModule->getModuleFlag("UnifiedLTO")) + + if (shouldEmitUnifiedLTOModueFlag()) TheModule->addModuleFlag(llvm::Module::Error, "UnifiedLTO", uint32_t(1)); } diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp index bbe14ef4c172..aa9997b87ecf 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGDecl.cpp @@ -1241,27 +1241,38 @@ static void emitStoresForConstant(CodeGenModule &CGM, const VarDecl &D, return; } - // If the initializer is small, use a handful of stores. + // If the initializer is small or trivialAutoVarInit is set, use a handful of + // stores. + bool IsTrivialAutoVarInitPattern = + CGM.getContext().getLangOpts().getTrivialAutoVarInit() == + LangOptions::TrivialAutoVarInitKind::Pattern; if (shouldSplitConstantStore(CGM, ConstantSize)) { if (auto *STy = dyn_cast(Ty)) { - const llvm::StructLayout *Layout = - CGM.getDataLayout().getStructLayout(STy); - for (unsigned i = 0; i != constant->getNumOperands(); i++) { - CharUnits CurOff = CharUnits::fromQuantity(Layout->getElementOffset(i)); - Address EltPtr = Builder.CreateConstInBoundsByteGEP( - Loc.withElementType(CGM.Int8Ty), CurOff); - emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, - constant->getAggregateElement(i), IsAutoInit); + if (STy == Loc.getElementType() || + (STy != Loc.getElementType() && IsTrivialAutoVarInitPattern)) { + const llvm::StructLayout *Layout = + CGM.getDataLayout().getStructLayout(STy); + for (unsigned i = 0; i != constant->getNumOperands(); i++) { + CharUnits CurOff = + CharUnits::fromQuantity(Layout->getElementOffset(i)); + Address EltPtr = Builder.CreateConstInBoundsByteGEP( + Loc.withElementType(CGM.Int8Ty), CurOff); + emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, + constant->getAggregateElement(i), IsAutoInit); + } + return; } - return; } else if (auto *ATy = dyn_cast(Ty)) { - for (unsigned i = 0; i != ATy->getNumElements(); i++) { - Address EltPtr = Builder.CreateConstGEP( - Loc.withElementType(ATy->getElementType()), i); - emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, - constant->getAggregateElement(i), IsAutoInit); + if (ATy == Loc.getElementType() || + (ATy != Loc.getElementType() && IsTrivialAutoVarInitPattern)) { + for (unsigned i = 0; i != ATy->getNumElements(); i++) { + Address EltPtr = Builder.CreateConstGEP( + Loc.withElementType(ATy->getElementType()), i); + emitStoresForConstant(CGM, D, EltPtr, isVolatile, Builder, + constant->getAggregateElement(i), IsAutoInit); + } + return; } - return; } } diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp index 57f4600727ec..0b16b660364f 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.cpp @@ -44,8 +44,15 @@ std::string wasm::Linker::getLinkerPath(const ArgList &Args) const { llvm::sys::fs::can_execute(UseLinker)) return std::string(UseLinker); - // Accept 'lld', and 'ld' as aliases for the default linker - if (UseLinker != "lld" && UseLinker != "ld") + // Interpret 'lld' as explicitly requesting `wasm-ld`, so look for that + // linker. Note that for `wasm32-wasip2` this overrides the default linker + // of `wasm-component-ld`. + if (UseLinker == "lld") { + return ToolChain.GetProgramPath("wasm-ld"); + } + + // Allow 'ld' as an alias for the default linker + if (UseLinker != "ld") ToolChain.getDriver().Diag(diag::err_drv_invalid_linker_name) << A->getAsString(Args); } @@ -73,6 +80,16 @@ void wasm::Linker::ConstructJob(Compilation &C, const JobAction &JA, if (Args.hasArg(options::OPT_s)) CmdArgs.push_back("--strip-all"); + // On `wasip2` the default linker is `wasm-component-ld` which wraps the + // execution of `wasm-ld`. Find `wasm-ld` and pass it as an argument of where + // to find it to avoid it needing to hunt and rediscover or search `PATH` for + // where it is. + if (llvm::sys::path::stem(Linker).ends_with_insensitive( + "wasm-component-ld")) { + CmdArgs.push_back("--wasm-ld-path"); + CmdArgs.push_back(Args.MakeArgString(ToolChain.GetProgramPath("wasm-ld"))); + } + Args.addAllArgs(CmdArgs, {options::OPT_L, options::OPT_u}); ToolChain.AddFilePathLibArgs(Args, CmdArgs); @@ -221,6 +238,12 @@ WebAssembly::WebAssembly(const Driver &D, const llvm::Triple &Triple, } } +const char *WebAssembly::getDefaultLinker() const { + if (getOS() == "wasip2") + return "wasm-component-ld"; + return "wasm-ld"; +} + bool WebAssembly::IsMathErrnoDefault() const { return false; } bool WebAssembly::IsObjCNonFragileABIDefault() const { return true; } diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h index ae60f464c108..76e0ca39bd74 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/WebAssembly.h @@ -67,7 +67,7 @@ private: llvm::opt::ArgStringList &CmdArgs) const override; SanitizerMask getSupportedSanitizers() const override; - const char *getDefaultLinker() const override { return "wasm-ld"; } + const char *getDefaultLinker() const override; CXXStdlibType GetDefaultCXXStdlibType() const override { return ToolChain::CST_Libcxx; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_null.h b/contrib/llvm-project/clang/lib/Headers/__stddef_null.h index 7336fdab3897..c10bd2d7d988 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_null.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_null.h @@ -7,7 +7,7 @@ *===-----------------------------------------------------------------------=== */ -#if !defined(NULL) || !__has_feature(modules) +#if !defined(NULL) || !__building_module(_Builtin_stddef) /* linux/stddef.h will define NULL to 0. glibc (and other) headers then define * __need_NULL and rely on stddef.h to redefine NULL to the correct value again. diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h index 183d394d56c1..7f3fbe6fe0d3 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_nullptr_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _NULLPTR_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_NULLPTR_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _NULLPTR_T #ifdef __cplusplus diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h b/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h index 3b347b3b92f6..84172c6cd273 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_offsetof.h @@ -7,6 +7,11 @@ *===-----------------------------------------------------------------------=== */ -#ifndef offsetof +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(offsetof) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define offsetof(t, d) __builtin_offsetof(t, d) #endif diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h index 3ea6d7d2852e..fd3c893c66c9 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_ptrdiff_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _PTRDIFF_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_PTRDIFF_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _PTRDIFF_T typedef __PTRDIFF_TYPE__ ptrdiff_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h index b6428d0c12b6..dd433d40d973 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_rsize_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _RSIZE_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_RSIZE_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _RSIZE_T typedef __SIZE_TYPE__ rsize_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h index e4a389510bcd..3dd7b1f37929 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_size_t.h @@ -7,7 +7,12 @@ *===-----------------------------------------------------------------------=== */ -#ifndef _SIZE_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_SIZE_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _SIZE_T typedef __SIZE_TYPE__ size_t; diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h b/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h index 3e7fe0197966..518580c92d3f 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_unreachable.h @@ -7,6 +7,11 @@ *===-----------------------------------------------------------------------=== */ -#ifndef unreachable +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(unreachable) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define unreachable() __builtin_unreachable() #endif diff --git a/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h b/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h index 16a6186512c0..bd69f6322541 100644 --- a/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h +++ b/contrib/llvm-project/clang/lib/Headers/__stddef_wchar_t.h @@ -9,7 +9,12 @@ #if !defined(__cplusplus) || (defined(_MSC_VER) && !_NATIVE_WCHAR_T_DEFINED) -#ifndef _WCHAR_T +/* + * When -fbuiltin-headers-in-system-modules is set this is a non-modular header + * and needs to behave as if it was textual. + */ +#if !defined(_WCHAR_T) || \ + (__has_feature(modules) && !__building_module(_Builtin_stddef)) #define _WCHAR_T #ifdef _MSC_EXTENSIONS diff --git a/contrib/llvm-project/clang/lib/Headers/larchintrin.h b/contrib/llvm-project/clang/lib/Headers/larchintrin.h index a613e5ca0e5e..f4218295919a 100644 --- a/contrib/llvm-project/clang/lib/Headers/larchintrin.h +++ b/contrib/llvm-project/clang/lib/Headers/larchintrin.h @@ -156,7 +156,7 @@ extern __inline unsigned char return (unsigned char)__builtin_loongarch_iocsrrd_b((unsigned int)_1); } -extern __inline unsigned char +extern __inline unsigned short __attribute__((__gnu_inline__, __always_inline__, __artificial__)) __iocsrrd_h(unsigned int _1) { return (unsigned short)__builtin_loongarch_iocsrrd_h((unsigned int)_1); diff --git a/contrib/llvm-project/clang/lib/Headers/module.modulemap b/contrib/llvm-project/clang/lib/Headers/module.modulemap index a786689d3917..56a13f69bc05 100644 --- a/contrib/llvm-project/clang/lib/Headers/module.modulemap +++ b/contrib/llvm-project/clang/lib/Headers/module.modulemap @@ -155,9 +155,9 @@ module _Builtin_intrinsics [system] [extern_c] { // Start -fbuiltin-headers-in-system-modules affected modules -// The following modules all ignore their top level headers -// when -fbuiltin-headers-in-system-modules is passed, and -// most of those headers join system modules when present. +// The following modules all ignore their headers when +// -fbuiltin-headers-in-system-modules is passed, and many of +// those headers join system modules when present. // e.g. if -fbuiltin-headers-in-system-modules is passed, then // float.h will not be in the _Builtin_float module (that module @@ -190,11 +190,6 @@ module _Builtin_stdalign [system] { export * } -// When -fbuiltin-headers-in-system-modules is passed, only -// the top level headers are removed, the implementation headers -// will always be in their submodules. That means when stdarg.h -// is included, it will still import this module and make the -// appropriate submodules visible. module _Builtin_stdarg [system] { textual header "stdarg.h" @@ -237,6 +232,8 @@ module _Builtin_stdbool [system] { module _Builtin_stddef [system] { textual header "stddef.h" + // __stddef_max_align_t.h is always in this module, even if + // -fbuiltin-headers-in-system-modules is passed. explicit module max_align_t { header "__stddef_max_align_t.h" export * @@ -283,9 +280,10 @@ module _Builtin_stddef [system] { } } -/* wint_t is provided by and not . It's here - * for compatibility, but must be explicitly requested. Therefore - * __stddef_wint_t.h is not part of _Builtin_stddef. */ +// wint_t is provided by and not . It's here +// for compatibility, but must be explicitly requested. Therefore +// __stddef_wint_t.h is not part of _Builtin_stddef. It is always in +// this module even if -fbuiltin-headers-in-system-modules is passed. module _Builtin_stddef_wint_t [system] { header "__stddef_wint_t.h" export * diff --git a/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp b/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp index afb2948f05ae..10c475f617d4 100644 --- a/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp +++ b/contrib/llvm-project/clang/lib/Lex/ModuleMap.cpp @@ -2498,9 +2498,12 @@ void ModuleMapParser::parseHeaderDecl(MMToken::TokenKind LeadingToken, } bool NeedsFramework = false; - // Don't add the top level headers to the builtin modules if the builtin headers - // belong to the system modules. - if (!Map.LangOpts.BuiltinHeadersInSystemModules || ActiveModule->isSubModule() || !isBuiltInModuleName(ActiveModule->Name)) + // Don't add headers to the builtin modules if the builtin headers belong to + // the system modules, with the exception of __stddef_max_align_t.h which + // always had its own module. + if (!Map.LangOpts.BuiltinHeadersInSystemModules || + !isBuiltInModuleName(ActiveModule->getTopLevelModuleName()) || + ActiveModule->fullModuleNameIs({"_Builtin_stddef", "max_align_t"})) Map.addUnresolvedHeader(ActiveModule, std::move(Header), NeedsFramework); if (NeedsFramework) diff --git a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp index a300badc6d02..f5bb3e0b42e2 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp @@ -8396,28 +8396,40 @@ void Sema::CheckShadow(NamedDecl *D, NamedDecl *ShadowedDecl, unsigned WarningDiag = diag::warn_decl_shadow; SourceLocation CaptureLoc; - if (isa(D) && isa(ShadowedDecl) && NewDC && - isa(NewDC)) { + if (isa(D) && NewDC && isa(NewDC)) { if (const auto *RD = dyn_cast(NewDC->getParent())) { if (RD->isLambda() && OldDC->Encloses(NewDC->getLexicalParent())) { - if (RD->getLambdaCaptureDefault() == LCD_None) { - // Try to avoid warnings for lambdas with an explicit capture list. + if (const auto *VD = dyn_cast(ShadowedDecl)) { const auto *LSI = cast(getCurFunction()); - // Warn only when the lambda captures the shadowed decl explicitly. - CaptureLoc = getCaptureLocation(LSI, cast(ShadowedDecl)); - if (CaptureLoc.isInvalid()) - WarningDiag = diag::warn_decl_shadow_uncaptured_local; - } else { - // Remember that this was shadowed so we can avoid the warning if the - // shadowed decl isn't captured and the warning settings allow it. + if (RD->getLambdaCaptureDefault() == LCD_None) { + // Try to avoid warnings for lambdas with an explicit capture + // list. Warn only when the lambda captures the shadowed decl + // explicitly. + CaptureLoc = getCaptureLocation(LSI, VD); + if (CaptureLoc.isInvalid()) + WarningDiag = diag::warn_decl_shadow_uncaptured_local; + } else { + // Remember that this was shadowed so we can avoid the warning if + // the shadowed decl isn't captured and the warning settings allow + // it. + cast(getCurFunction()) + ->ShadowingDecls.push_back({D, VD}); + return; + } + } + if (isa(ShadowedDecl)) { + // If lambda can capture this, then emit default shadowing warning, + // Otherwise it is not really a shadowing case since field is not + // available in lambda's body. + // At this point we don't know that lambda can capture this, so + // remember that this was shadowed and delay until we know. cast(getCurFunction()) - ->ShadowingDecls.push_back( - {cast(D), cast(ShadowedDecl)}); + ->ShadowingDecls.push_back({D, ShadowedDecl}); return; } } - - if (cast(ShadowedDecl)->hasLocalStorage()) { + if (const auto *VD = dyn_cast(ShadowedDecl); + VD && VD->hasLocalStorage()) { // A variable can't shadow a local variable in an enclosing scope, if // they are separated by a non-capturing declaration context. for (DeclContext *ParentDC = NewDC; @@ -8468,19 +8480,28 @@ void Sema::CheckShadow(NamedDecl *D, NamedDecl *ShadowedDecl, /// when these variables are captured by the lambda. void Sema::DiagnoseShadowingLambdaDecls(const LambdaScopeInfo *LSI) { for (const auto &Shadow : LSI->ShadowingDecls) { - const VarDecl *ShadowedDecl = Shadow.ShadowedDecl; + const NamedDecl *ShadowedDecl = Shadow.ShadowedDecl; // Try to avoid the warning when the shadowed decl isn't captured. - SourceLocation CaptureLoc = getCaptureLocation(LSI, ShadowedDecl); const DeclContext *OldDC = ShadowedDecl->getDeclContext(); - Diag(Shadow.VD->getLocation(), CaptureLoc.isInvalid() - ? diag::warn_decl_shadow_uncaptured_local - : diag::warn_decl_shadow) - << Shadow.VD->getDeclName() - << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; - if (!CaptureLoc.isInvalid()) - Diag(CaptureLoc, diag::note_var_explicitly_captured_here) - << Shadow.VD->getDeclName() << /*explicitly*/ 0; - Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + if (const auto *VD = dyn_cast(ShadowedDecl)) { + SourceLocation CaptureLoc = getCaptureLocation(LSI, VD); + Diag(Shadow.VD->getLocation(), + CaptureLoc.isInvalid() ? diag::warn_decl_shadow_uncaptured_local + : diag::warn_decl_shadow) + << Shadow.VD->getDeclName() + << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; + if (CaptureLoc.isValid()) + Diag(CaptureLoc, diag::note_var_explicitly_captured_here) + << Shadow.VD->getDeclName() << /*explicitly*/ 0; + Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + } else if (isa(ShadowedDecl)) { + Diag(Shadow.VD->getLocation(), + LSI->isCXXThisCaptured() ? diag::warn_decl_shadow + : diag::warn_decl_shadow_uncaptured_local) + << Shadow.VD->getDeclName() + << computeShadowedDeclKind(ShadowedDecl, OldDC) << OldDC; + Diag(ShadowedDecl->getLocation(), diag::note_previous_declaration); + } } } diff --git a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp index 940bcccb9e26..b708272ebe7d 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaOverload.cpp @@ -14470,6 +14470,23 @@ ExprResult Sema::CreateOverloadedBinOp(SourceLocation OpLoc, CurFPFeatureOverrides()); } + // If this is the .* operator, which is not overloadable, just + // create a built-in binary operator. + if (Opc == BO_PtrMemD) { + auto CheckPlaceholder = [&](Expr *&Arg) { + ExprResult Res = CheckPlaceholderExpr(Arg); + if (Res.isUsable()) + Arg = Res.get(); + return !Res.isUsable(); + }; + + // CreateBuiltinBinOp() doesn't like it if we tell it to create a '.*' + // expression that contains placeholders (in either the LHS or RHS). + if (CheckPlaceholder(Args[0]) || CheckPlaceholder(Args[1])) + return ExprError(); + return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); + } + // Always do placeholder-like conversions on the RHS. if (checkPlaceholderForOverload(*this, Args[1])) return ExprError(); @@ -14489,11 +14506,6 @@ ExprResult Sema::CreateOverloadedBinOp(SourceLocation OpLoc, if (Opc == BO_Assign && !Args[0]->getType()->isOverloadableType()) return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); - // If this is the .* operator, which is not overloadable, just - // create a built-in binary operator. - if (Opc == BO_PtrMemD) - return CreateBuiltinBinOp(OpLoc, Opc, Args[0], Args[1]); - // Build the overload set. OverloadCandidateSet CandidateSet(OpLoc, OverloadCandidateSet::CSK_Operator, OverloadCandidateSet::OperatorRewriteInfo( diff --git a/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp b/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp index a381d876a54c..b619f5d729e8 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaTemplate.cpp @@ -1830,7 +1830,27 @@ static TemplateParameterList *GetTemplateParameterList(TemplateDecl *TD) { // Make sure we get the template parameter list from the most // recent declaration, since that is the only one that is guaranteed to // have all the default template argument information. - return cast(TD->getMostRecentDecl())->getTemplateParameters(); + Decl *D = TD->getMostRecentDecl(); + // C++11 [temp.param]p12: + // A default template argument shall not be specified in a friend class + // template declaration. + // + // Skip past friend *declarations* because they are not supposed to contain + // default template arguments. Moreover, these declarations may introduce + // template parameters living in different template depths than the + // corresponding template parameters in TD, causing unmatched constraint + // substitution. + // + // FIXME: Diagnose such cases within a class template: + // template + // struct S { + // template friend struct C; + // }; + // template struct S; + while (D->getFriendObjectKind() != Decl::FriendObjectKind::FOK_None && + D->getPreviousDecl()) + D = D->getPreviousDecl(); + return cast(D)->getTemplateParameters(); } DeclResult Sema::CheckClassTemplate( diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp index 028610deb300..490b8cb10a48 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReader.cpp @@ -9745,7 +9745,7 @@ void ASTReader::finishPendingActions() { !NonConstDefn->isLateTemplateParsed() && // We only perform ODR checks for decls not in the explicit // global module fragment. - !shouldSkipCheckingODR(FD) && + !FD->shouldSkipCheckingODR() && FD->getODRHash() != NonConstDefn->getODRHash()) { if (!isa(FD)) { PendingFunctionOdrMergeFailures[FD].push_back(NonConstDefn); diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp index 321c11e55c14..110f55f8c0f4 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTReaderDecl.cpp @@ -832,7 +832,7 @@ void ASTDeclReader::VisitEnumDecl(EnumDecl *ED) { Reader.mergeDefinitionVisibility(OldDef, ED); // We don't want to check the ODR hash value for declarations from global // module fragment. - if (!shouldSkipCheckingODR(ED) && + if (!ED->shouldSkipCheckingODR() && OldDef->getODRHash() != ED->getODRHash()) Reader.PendingEnumOdrMergeFailures[OldDef].push_back(ED); } else { @@ -874,7 +874,7 @@ void ASTDeclReader::VisitRecordDecl(RecordDecl *RD) { VisitRecordDeclImpl(RD); // We should only reach here if we're in C/Objective-C. There is no // global module fragment. - assert(!shouldSkipCheckingODR(RD)); + assert(!RD->shouldSkipCheckingODR()); RD->setODRHash(Record.readInt()); // Maintain the invariant of a redeclaration chain containing only @@ -2152,7 +2152,7 @@ void ASTDeclReader::MergeDefinitionData( } // We don't want to check ODR for decls in the global module fragment. - if (shouldSkipCheckingODR(MergeDD.Definition)) + if (MergeDD.Definition->shouldSkipCheckingODR()) return; if (D->getODRHash() != MergeDD.ODRHash) { @@ -3526,7 +3526,7 @@ ASTDeclReader::FindExistingResult ASTDeclReader::findExisting(NamedDecl *D) { // same template specialization into the same CXXRecordDecl. auto MergedDCIt = Reader.MergedDeclContexts.find(D->getLexicalDeclContext()); if (MergedDCIt != Reader.MergedDeclContexts.end() && - !shouldSkipCheckingODR(D) && MergedDCIt->second == D->getDeclContext()) + !D->shouldSkipCheckingODR() && MergedDCIt->second == D->getDeclContext()) Reader.PendingOdrMergeChecks.push_back(D); return FindExistingResult(Reader, D, /*Existing=*/nullptr, diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp index 73018c1170d8..378a1f86bd53 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriter.cpp @@ -6010,7 +6010,7 @@ void ASTRecordWriter::AddCXXDefinitionData(const CXXRecordDecl *D) { BitsPacker DefinitionBits; - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); DefinitionBits.addBit(ShouldSkipCheckingODR); #define FIELD(Name, Width, Merge) \ diff --git a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp index e73800100e3c..42583c09f009 100644 --- a/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp +++ b/contrib/llvm-project/clang/lib/Serialization/ASTWriterDecl.cpp @@ -488,7 +488,7 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { BitsPacker EnumDeclBits; EnumDeclBits.addBits(D->getNumPositiveBits(), /*BitWidth=*/8); EnumDeclBits.addBits(D->getNumNegativeBits(), /*BitWidth=*/8); - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); EnumDeclBits.addBit(ShouldSkipCheckingODR); EnumDeclBits.addBit(D->isScoped()); EnumDeclBits.addBit(D->isScopedUsingClassTag()); @@ -514,7 +514,7 @@ void ASTDeclWriter::VisitEnumDecl(EnumDecl *D) { !D->isTopLevelDeclInObjCContainer() && !CXXRecordDecl::classofKind(D->getKind()) && !D->getIntegerTypeSourceInfo() && !D->getMemberSpecializationInfo() && - !needsAnonymousDeclarationNumber(D) && !shouldSkipCheckingODR(D) && + !needsAnonymousDeclarationNumber(D) && !D->shouldSkipCheckingODR() && D->getDeclName().getNameKind() == DeclarationName::Identifier) AbbrevToUse = Writer.getDeclEnumAbbrev(); @@ -680,7 +680,7 @@ void ASTDeclWriter::VisitFunctionDecl(FunctionDecl *D) { // FIXME: stable encoding FunctionDeclBits.addBits(llvm::to_underlying(D->getLinkageInternal()), 3); FunctionDeclBits.addBits((uint32_t)D->getStorageClass(), /*BitWidth=*/3); - bool ShouldSkipCheckingODR = shouldSkipCheckingODR(D); + bool ShouldSkipCheckingODR = D->shouldSkipCheckingODR(); FunctionDeclBits.addBit(ShouldSkipCheckingODR); FunctionDeclBits.addBit(D->isInlineSpecified()); FunctionDeclBits.addBit(D->isInlined()); @@ -1514,7 +1514,7 @@ void ASTDeclWriter::VisitCXXMethodDecl(CXXMethodDecl *D) { D->getFirstDecl() == D->getMostRecentDecl() && !D->isInvalidDecl() && !D->hasAttrs() && !D->isTopLevelDeclInObjCContainer() && D->getDeclName().getNameKind() == DeclarationName::Identifier && - !shouldSkipCheckingODR(D) && !D->hasExtInfo() && + !D->shouldSkipCheckingODR() && !D->hasExtInfo() && !D->isExplicitlyDefaulted()) { if (D->getTemplatedKind() == FunctionDecl::TK_NonTemplate || D->getTemplatedKind() == FunctionDecl::TK_FunctionTemplate || diff --git a/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp b/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp index 0ac1d91b79be..bc14aea27f67 100644 --- a/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp +++ b/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/CallEvent.cpp @@ -1409,7 +1409,7 @@ CallEventManager::getSimpleCall(const CallExpr *CE, ProgramStateRef State, if (const auto *OpCE = dyn_cast(CE)) { const FunctionDecl *DirectCallee = OpCE->getDirectCallee(); if (const auto *MD = dyn_cast(DirectCallee)) - if (MD->isInstance()) + if (MD->isImplicitObjectMemberFunction()) return create(OpCE, State, LCtx, ElemRef); } else if (CE->getCallee()->getType()->isBlockPointerType()) { diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c b/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c index e970cef574b2..099de5802daf 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c +++ b/contrib/llvm-project/compiler-rt/lib/builtins/divtc3.c @@ -13,7 +13,7 @@ #define QUAD_PRECISION #include "fp_lib.h" -#if defined(CRT_HAS_TF_MODE) +#if defined(CRT_HAS_F128) // Returns: the quotient of (a + ib) / (c + id) diff --git a/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h b/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h index af406e760497..c4f0a5b9587f 100644 --- a/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h +++ b/contrib/llvm-project/compiler-rt/lib/builtins/fp_lib.h @@ -22,6 +22,7 @@ #include "int_lib.h" #include "int_math.h" +#include "int_types.h" #include #include #include @@ -93,13 +94,14 @@ static __inline void wideMultiply(rep_t a, rep_t b, rep_t *hi, rep_t *lo) { COMPILER_RT_ABI fp_t __adddf3(fp_t a, fp_t b); #elif defined QUAD_PRECISION -#if defined(CRT_HAS_TF_MODE) +#if defined(CRT_HAS_F128) && defined(CRT_HAS_128BIT) typedef uint64_t half_rep_t; typedef __uint128_t rep_t; typedef __int128_t srep_t; typedef tf_float fp_t; #define HALF_REP_C UINT64_C #define REP_C (__uint128_t) +#if defined(CRT_HAS_IEEE_TF) // Note: Since there is no explicit way to tell compiler the constant is a // 128-bit integer, we let the constant be casted to 128-bit integer #define significandBits 112 @@ -188,7 +190,10 @@ static __inline void wideMultiply(rep_t a, rep_t b, rep_t *hi, rep_t *lo) { #undef Word_HiMask #undef Word_LoMask #undef Word_FullMask -#endif // defined(CRT_HAS_TF_MODE) *** 3106 LINES SKIPPED *** From nobody Sat Apr 20 10:34:47 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dm1MdDz5HWgM; Sat, 20 Apr 2024 10:34:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dl5BNDz4TJg; Sat, 20 Apr 2024 10:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609287; 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=jBeLsoqI6TrytbvdkzRiAd1uKP+CKsS87f97LsYmwVw=; b=WCzDXGPh/vtcWXKDH46ZwwVXgM4lyovp2/yEiGPBWawK2WMHRFhuvpbSoBh9wplOcUukoQ udzX6lUH+OnzCTYugFDwDzdcYJ9A/CM8u3012G8qW4khArcPRySR5SQX/q23y7Y9rUT7JG fnFy40sXKQNznrjuu7876H/wz9nrhqvR/vDOim1wWE+ZXmc8vLqzTaxCJDreFiK51rwy5n vsySd1CA+9SajE+eQo6rooVM7+C8k2XULtCDusyo2dhipDJtu1FKZ0jL/aiFRKJXpaWCr3 6ODQSC7u7jkLkVz3a15gMmn7AX1o+6kAfxpDfsoML7ePYmbAYRYtPCWv4GzFUw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609287; a=rsa-sha256; cv=none; b=kI6/nx18rT+QoJclQ1pRa9JgDk1OEps042iwdM8LTeN9khn/yHXRsAqw94FdYebkI/C1jE QdW8EBL7C5axGlNiWxTn3gwdUs8VsFFDo9XRbdTcnuJxKjW/48/LnOq/xArGe7Dd0l39ul EMu3X/Vi+nlPjNp03OGk20k03VL7pKYRCCB/E2HPYsOUSpMEbWM+qeByWciYEZsxhtjFIl 3auukb8h8vbHogGeUQvsR8BrPj4arJ+Lr/Iui1zwBIS/Sy+FEAKATKgxepJTOm5eDi/2wC fsmJLaP2Ecj16s9uRLIls6czDPsi5JCiMuwqw3J2mVlr7MOn4OQ1hGUBpFyHAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609287; 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=jBeLsoqI6TrytbvdkzRiAd1uKP+CKsS87f97LsYmwVw=; b=dVdbC7hzN6eJs4E7wobOK+5Jkg+e/kqOfzqjy5nP4pDl8Uf6pZBM96mtkQ+vspjV51wUCX Z7rmVV2dVpdiWEKoOsiWmAENh8SQVeHPtL7iVbjc6nks+L8tpRtFAZd6W3DGscvrhTq/k7 nnw3V1ow1MkC9KzD5q7t0M0CkKme/dOgPGsffm0bavb6MTxAyEflGuaNNYdHc4APTSp6DD bbvtvRkNqwRmE4lvHqqwYwsYmhcWIwBdG+otQsgCYo6QewGIsp0w//dT5nzOjJiErl5j1Z eq+cgfGikYVLOrkYnlbTauaDjVNqlxQGKo3pUUDS2W2Y6EtRqny6hkQDuekU+A== 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 4VM7Dl4m7LzYrC; Sat, 20 Apr 2024 10:34:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYlvT014289; Sat, 20 Apr 2024 10:34:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYlBq014286; Sat, 20 Apr 2024 10:34:47 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:47 GMT Message-Id: <202404201034.43KAYlBq014286@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: 0764680cf8fd - stable/13 - Fix arm64 build after llvm 18.1.3 upgrade (take 2) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 0764680cf8fdcd53b781a54c1a697bddedb075da Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=0764680cf8fdcd53b781a54c1a697bddedb075da commit 0764680cf8fdcd53b781a54c1a697bddedb075da Author: Dimitry Andric AuthorDate: 2024-04-07 09:23:06 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 Fix arm64 build after llvm 18.1.3 upgrade (take 2) Instead of compiling the whole sys/arm64/arm64/vfp.c file without -mgeneral-regs-only, which might have unwanted side effects, add ".arch_extension fp" / ".arch_extension nofp" pairs to the inline assembly. PR: 276104 Suggested by: andrew MFC after: 1 month (cherry picked from commit 61e482f2fcd53bbc7fd3d4cc8b7df79d5d57d75c) --- sys/arm64/arm64/vfp.c | 4 ++++ sys/conf/files.arm64 | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/vfp.c b/sys/arm64/arm64/vfp.c index 9cdeb751f81a..01f52dad271e 100644 --- a/sys/arm64/arm64/vfp.c +++ b/sys/arm64/arm64/vfp.c @@ -105,6 +105,7 @@ vfp_store(struct vfpstate *state) vfp_state = state->vfp_regs; __asm __volatile( + ".arch_extension fp\n" "mrs %0, fpcr \n" "mrs %1, fpsr \n" "stp q0, q1, [%2, #16 * 0]\n" @@ -123,6 +124,7 @@ vfp_store(struct vfpstate *state) "stp q26, q27, [%2, #16 * 26]\n" "stp q28, q29, [%2, #16 * 28]\n" "stp q30, q31, [%2, #16 * 30]\n" + ".arch_extension nofp\n" : "=&r"(fpcr), "=&r"(fpsr) : "r"(vfp_state)); state->vfp_fpcr = fpcr; @@ -140,6 +142,7 @@ vfp_restore(struct vfpstate *state) fpsr = state->vfp_fpsr; __asm __volatile( + ".arch_extension fp\n" "ldp q0, q1, [%2, #16 * 0]\n" "ldp q2, q3, [%2, #16 * 2]\n" "ldp q4, q5, [%2, #16 * 4]\n" @@ -158,6 +161,7 @@ vfp_restore(struct vfpstate *state) "ldp q30, q31, [%2, #16 * 30]\n" "msr fpcr, %0 \n" "msr fpsr, %1 \n" + ".arch_extension nofp\n" : : "r"(fpcr), "r"(fpsr), "r"(vfp_state)); } diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64 index f72f5718ac19..bb593a8f9a01 100644 --- a/sys/conf/files.arm64 +++ b/sys/conf/files.arm64 @@ -76,8 +76,7 @@ arm64/arm64/uio_machdep.c standard arm64/arm64/uma_machdep.c standard arm64/arm64/undefined.c standard arm64/arm64/unwind.c optional ddb | kdtrace_hooks | stack -arm64/arm64/vfp.c standard \ - compile-with "${NORMAL_C:N-mgeneral-regs-only}" +arm64/arm64/vfp.c standard arm64/arm64/vm_machdep.c standard arm64/coresight/coresight.c standard From nobody Sat Apr 20 10:34:48 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dn3LSfz5HWPP; Sat, 20 Apr 2024 10:34:49 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dm6gs8z4T8N; Sat, 20 Apr 2024 10:34:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609288; 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=HTiDrbNL2OTFfdRZz/jrEDt5cuatR9JOgbeym73t1N4=; b=FD6jbRe7cucf+NcKlhznQjNDPDshNnmZiCnhq39OwH+EwROJmNjkioVEjnoH+IhyWw+2Uq 5pHctL1GNcLXAl/F4NZh3rRGFgQ0aM+i92WLxAiu7dRoAzD45w/wglY2itWQnvT+0gj624 vgkl1h/uHMz83b+q/0Ud5kagY6+Ss+khqU6xBp8yx94XfK6Kn/AoH/yLL+jzrm4uTh2dYz 8ekWd8vIiGN/lP7T32Te4HPgS6kvJVt/L4onnf9SGiU85c+s3Po6vBsY8Ev8+K9zEPPfRC yUYeSP+VIkuIPRb3Bnb/fDID9X9xl6HYUiTrfai1Qnf00j80kfWFUa/6538VVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609288; a=rsa-sha256; cv=none; b=lBM72wZ40oucb4WkparA0Fvsdb0llueHsNigRR6PyTLtd9PcIJdXVujMbkGZ/y5XsYss9O HR0Uh98ynDJXHHQVOOU4UGBKKewANJM0R0zG/VI+YfZPxcuaLjehHUdXQ4cNDbh+gzTwAx aqHLTf4/mV0qkz9BOwtYx8Pu70xQSNmqqZ9AcJWsrSioCIE6PbE+tGbDSeg1dhOXXhpbVl u1AzApAjp4ZDHhgk6TolLFAyKec6Pn+ZjocwXK08avvcXPLSLXnGaXItWmgWEkJSSrDSTY D7i+YhzNSPx6A46+wdseOhmMMISIKaUxkd/5CSlYK7Vdk99hFFTj5ILx18+/Xw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609288; 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=HTiDrbNL2OTFfdRZz/jrEDt5cuatR9JOgbeym73t1N4=; b=tya+g8ZTmcKUIV6v30Lu73NyCE6tdY6RHzfZA5LpijTe6tmLaRZQBHDTwqOvaPm2sWPw7B +CGk2WaaYSwWXPRswogBdj1lLdX039PZ3CFaduPUOIb0o5S3GiwcKy8Hz/0V1x2akxEe+i Jz64GR4T7YRT1g2aKz9OQ+Xd8Rj13F2rcfxxaJZlVmwi0mBLexg1OiInCnxWZAb0WUmKcv f9+ybuK1+cmf8l8g1ze1sM9MBLd962boHBYmVqgsBVIpQZ8W6TnQnmueg1f0OcJJNoT47P KsrFv8iphskUfexBKRuF/WcQN03P4Qo8S/BzN1ujzlcUJDbXt97dA5X+SWsFhA== 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 4VM7Dm5xGRzZJY; Sat, 20 Apr 2024 10:34:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYmnh014338; Sat, 20 Apr 2024 10:34:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYm7f014334; Sat, 20 Apr 2024 10:34:48 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:48 GMT Message-Id: <202404201034.43KAYm7f014334@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: 89cc83362f4d - stable/13 - Fix GENERIC-KASAN kernel build for amd64 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 89cc83362f4d4d5733a2a7446b0b4be63596e09c Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=89cc83362f4d4d5733a2a7446b0b4be63596e09c commit 89cc83362f4d4d5733a2a7446b0b4be63596e09c Author: Dimitry Andric AuthorDate: 2024-04-07 17:56:03 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 Fix GENERIC-KASAN kernel build for amd64 Work around https://github.com/llvm/llvm-project/issues/87923, which leads to an assertion failure compiling several kernel source files with asan enabled. PR: 276104 MFC after: 1 month (cherry picked from commit b811dac2115a6ada606c03d7d823a95d11c5f3c9) --- sys/conf/kern.pre.mk | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index b47b89daa008..ea3cc1986575 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -119,6 +119,13 @@ SAN_CFLAGS+= -DSAN_NEEDS_INTERCEPTORS -DSAN_INTERCEPTOR_PREFIX=kasan \ -mllvm -asan-use-after-scope=true \ -mllvm -asan-instrumentation-with-call-threshold=0 \ -mllvm -asan-instrument-byval=false + +.if ${MACHINE_CPUARCH} == "amd64" && \ + ${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 180000 +# Work around https://github.com/llvm/llvm-project/issues/87923, which leads to +# an assertion failure compiling dtrace.c with asan enabled. +SAN_CFLAGS+= -mllvm -asan-use-stack-safety=0 +.endif .endif KCSAN_ENABLED!= grep KCSAN opt_global.h || true ; echo From nobody Sat Apr 20 10:34:49 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dp1jPbz5HWVc; Sat, 20 Apr 2024 10:34:50 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dp0CdXz4T8b; Sat, 20 Apr 2024 10:34:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609290; 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=IGNYleA893BtkfjMTiYV8VhYRDD6h3et1dntM/b/PPg=; b=rklfwWaaMOcf3EFgPN4EtbSaD0iLFWdKmBkh4Aq3yOpBAf6UtpxVHvy5LbvJibRnbevA94 D8CaORDqrMxclAzZNQ042uuEXG2NQOx97KnUht+IngizNPN3bcmAwVRrdy1q3W9nHVokmu 5r3zTcl6vr36oBj4HZ3Ds8ZI7/wRy3Ooio5gE7LPMjOxiheO90t+kjb7ir7s+sWPMBjCSo X1StJ7j1LkhixFXhMJ9Y6awBHzEwLjLLpAdc2H6tfU+goCGCxV5hIfGZtZO3attsrDblIt vqanx6I1yiFgr16iLCCoIsEOLYgnngPS+Ex5k6kg8bflnKKRenJcSh/8t9MAZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609290; a=rsa-sha256; cv=none; b=rhV/ZUZjuEW/6I0n+o8SpTh3DBoamlPANmS6BoJdPcgtTDLWmCYpBiXl+s8VFnnqnesEjG HyoDXA5xQ4n+4GdxbQmLQb4FC7Qx20J0jwOj9wGgSzoBLouVgk4T06pvY/CR+ziDtDHoLW jw0xYRJVY/W3cGxBfw3+gFRqoh/w+0IIQsr/D+maXacRqCBUdS91uVjYXzS0ZxsKvb/WLQ /ND8NAjEBdGFPKsAdsP61iTUPI6UZo1oWB2BQLwwWR481WzckHQMqlEvSfZ3ONmLvSvJiz vrY+OfqGZ0a9kk9LIvwckiFTop5QvpIC3O0aV/jnM8LZzO4YSfQKG8qrP21GXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609290; 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=IGNYleA893BtkfjMTiYV8VhYRDD6h3et1dntM/b/PPg=; b=tp+WYpG/Pc88zuWMQpsgJ6VJFnOdVOOZJiN/yosJa0q7CnB6hRbLySw1N/6/dENPrXZ5kQ um/ffVeRFA2p2j40lzUyt3924/3MDb9HhAHCnMuRdPPZYGrwBt+bdMjIw/nuzeNsYZc3GB qBMcUUtW5kIcgt6BOjzmMZqLCoHbqAEW1sVc3ouddxZXN5XF56UR9s6Qorjaludd1fMQRY xCta7jQjWf3QLCknPXNNV4/LYnAFIymLGtgJZr1+ffVv56Q8hj2KW90bjdyg6TXD84xjBB nOVErnVce9yiqy8nztycubdbPLuHQQNgzSSgUv6g+XZCRd5/OLAtWsUpKXTakQ== 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 4VM7Dn6vSTzZFw; Sat, 20 Apr 2024 10:34:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYnsR014382; Sat, 20 Apr 2024 10:34:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYnqU014379; Sat, 20 Apr 2024 10:34:49 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:49 GMT Message-Id: <202404201034.43KAYnqU014379@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: 5018444b289d - stable/13 - libcompiler_rt Makefile.inc: remove debugging messages List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 5018444b289d7bf730d543e60e4e9c21409cb848 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=5018444b289d7bf730d543e60e4e9c21409cb848 commit 5018444b289d7bf730d543e60e4e9c21409cb848 Author: Dimitry Andric AuthorDate: 2024-04-07 18:16:50 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 libcompiler_rt Makefile.inc: remove debugging messages PR: 276104 MFC after: 1 month (cherry picked from commit d00b9344bb10a9a35b02df33475bec951dfccd78) --- lib/libcompiler_rt/Makefile.inc | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index b47073b5a74d..eb2b04001b1e 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -1,6 +1,5 @@ CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/:C/powerpc/ppc/} -.info DIMDBG: CRTARCH=${CRTARCH} CRTSRC= ${SRCTOP}/contrib/llvm-project/compiler-rt/lib/builtins @@ -132,7 +131,6 @@ SRCF+= floatundisf # 80-bit long double functions, only used on x86. # .if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" -.info DIMDBG: Enabling 80-bit long double SRCF+= divxc3 SRCF+= extendxftf2 SRCF+= fixxfdi @@ -154,8 +152,6 @@ SRCS+= floatundixf.c SRCF+= floatdixf SRCF+= floatundixf .endif -.else -.info DIMDBG: NOT enabling 80-bit long double .endif # __cpu_model support, only used on aarch64 and x86 @@ -179,7 +175,6 @@ SRCF+= fp_mode # .if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ ${MACHINE_CPUARCH} == "riscv" -.info DIMDBG: Enabling 128-bit quad precision SRCF+= addtf3 SRCF+= comparetf2 SRCF+= divtc3 @@ -206,8 +201,6 @@ SRCF+= subtf3 SRCF+= trunctfdf2 SRCF+= trunctfhf2 SRCF+= trunctfsf2 -.else -.info DIMDBG: NOT enabling 128-bit quad precision .endif # These are already shipped by libc.a on some architectures. From nobody Sat Apr 20 10:34:51 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dq35vZz5HWdG; Sat, 20 Apr 2024 10:34:51 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dq1DBgz4T3R; Sat, 20 Apr 2024 10:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609291; 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=lisqsXXBeKjVEq5MZsVFvtrHTpqbdxb2xuGHqRWgVFc=; b=D66L+I4JTuG5IV70HOxC/6G+nIDOLYKG/RJWQitZ7kym8bsCGEuhMPv4BRIPH9q1BN8pd1 Pfqa6eM+qtnAOREY2kNgGDQ00+XBraXcmArUNA/r3EYAVkXnJHthYHUTYEvf0EvbSgv5Xb 9I80J2xBOU95HDEYCmIKfm2/thqfRQmo6xqA/M9Bd4MzCx8RxaWbuDJwTzveifAeIUa4uk YgfBEMjFNfT5gMNNeq3NVfTSn5Aa/Xn9S9078IuyS2VZhytk3U/EcZLPhRWXyxSesPmS3U 812m0mCxYphutgHemjEf9ZgHaSII9kDYm0Uou8D/NRXFrBwqN8E0OhVW7Irs7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609291; a=rsa-sha256; cv=none; b=ahkFS6T8SxgXX0K6mEBhF621oO7nGl7oi1EUpVGENQYsI3jOFmm2VxwHqpxoU79VY3B0Uj oM+SY2ZJ3LqPncZwceW5hIO1VaoVq0gMFON9TakHLZJWZRHMb/VQBFEmApziJS6CEK6Lcw 65WpH3j77Qy6za66npwzwNj5TqcsfVjiG8iE/52PIk9/ufrJesJF4l1YFRAGajI5tTOo+2 KKnytpZMfbFnHpxiDmgvqTEKcP8w7cPOzCQfPEV71HrrF4YkuqmsSr99utjD1PZIRybsVO b2FbGHuTiKppu6SJz+l3cKcYfMz0/3/3WYuD26oomuN35gkPf8FsB0Ixgd2u6A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609291; 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=lisqsXXBeKjVEq5MZsVFvtrHTpqbdxb2xuGHqRWgVFc=; b=D3ZtQ6nvG11YYyEGxZvvTsJ8H+wGobvrYFnGSlsH64KJ7I8FMRVEpLe9pSf+ntW47v58cL +Csj2/HMsHBOkZXQpTtt9/daysWBHcUNUyoNsMimLINaHIC0td9dK91Bkcn2AL+iShL3il Iz9qe5JDBZGBMtr2QXN0aZufl1+Eb1xY3nead0U2vugIADE/+diSDYNZybLBFQqfkevDdz 4pbH6iVjysupQPmtnVYWXHKurrTMmfPfBjAPHsOvKyJkqxNrXxBOixOFjsG/uN9pn97DC7 4Cfyyu9E+5LYQpc20pxkI7R0+4qI2Ydftm6vnRNgoEQsBqxcqlsSScClMD6lXg== 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 4VM7Dq0rxYzYrG; Sat, 20 Apr 2024 10:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYppC014450; Sat, 20 Apr 2024 10:34:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYprE014447; Sat, 20 Apr 2024 10:34:51 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:51 GMT Message-Id: <202404201034.43KAYprE014447@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: e2e4022725ac - stable/13 - libcompiler_rt Makefile.inc: don't build bfloat16 support for gcc < 13 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: e2e4022725aca1f7a1a698e241f926bcac506049 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=e2e4022725aca1f7a1a698e241f926bcac506049 commit e2e4022725aca1f7a1a698e241f926bcac506049 Author: Dimitry Andric AuthorDate: 2024-04-07 18:21:01 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 libcompiler_rt Makefile.inc: don't build bfloat16 support for gcc < 13 Older versions of gcc produce "error: unknown type name '__bf16'". PR: 276104 MFC after: 1 month (cherry picked from commit 2e226748a961329471f5b51483318b94c8735f34) --- lib/libcompiler_rt/Makefile.inc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index eb2b04001b1e..a4d0203b8ed3 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -230,9 +230,10 @@ SRCF+= comparesf2 # # bfloat16 support, only used on some architectures. # -.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ - ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ - !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv" +.if (${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ + ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ + !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv") && \ + !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 130000) SRCF+= truncdfbf2 SRCF+= truncsfbf2 .endif From nobody Sat Apr 20 10:34:53 2024 X-Original-To: dev-commits-src-branches@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 4VM7Ds625yz5HWbM; Sat, 20 Apr 2024 10:34:53 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Ds2tq7z4TMc; Sat, 20 Apr 2024 10:34:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609293; 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=r+PwqSRDM0l+szMt6QozjnPP6YoY0JmDNKStgoM9XI8=; b=bE/52Jb3bS2xx/5mYpZGMjeWZraUiqxrko4rPPGpziBC74Lgo7gOid9Elpg4MsTGw2wJEO QFwDwYgEd9OmrlMnIlUkaOgdQLZaSOxQW3BHWZGwA3wGzr+kC2YUpXsR24vxbtkeL94zdD 9pXYA3Tsiuqo3HSBWyqmMV4CWupiQ65gbKufGiy52JS9ynLnhwZHLExbaSeAuEbTrV/Elp ceuHaYAllqns2qKe/zWHNezNFsf8lE5nuDLOhJR5F5C1yfzHFcyk9erz3kB0hdYtoFGlNB NudbAHJOGQ3n4MCDTnmziV3CWTjYuQZ8dDMgiax6p16+7q71+eqrJOwDGZdR9w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609293; a=rsa-sha256; cv=none; b=hIHuAuCptjAdXHcrUuN6zU11isl4qX6rFXFJFKSR2tmZKx6TJtoKyFX3AHnV348vmxcYWh QUQMPSkZ5jmgIIeVv+io/Tne52xndbtaqzOURpd7mHuVVBiFmG/Uuv6G4QXLdA3QNXLKse pcoSVaqJxAONnd+RHZiSrSqsQLUYlSqhntwgSlzq/Ckvd8wjA2WQjZupgxsJN9LBQjaIg7 3tatZklJKFLGK/ffeKqJiFMFCLXtD8aXJn6KuSa5biGsNAeqwFa9mL6ZCfaO0Tw9EjU3KF LORWPz2OHy1uJ7I3pV6eELCt0PrU0hFm66FBhGDk1L5ZkjjVijgkvd8NLpi/qg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609293; 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=r+PwqSRDM0l+szMt6QozjnPP6YoY0JmDNKStgoM9XI8=; b=ecelruBxU0xgk2hGRVrcuzJGU086tZk7ubyiGR3L3hubITnVeXakbEab/lWoTNaYj7JK3m OTtl4/rxVJ/8Da1pNjm02KI/8C2m3NovJ246Lbp3mgseXTorNwcN40FOLWhlwkHTFrSNQM H5pwmLW+3uur0HM2xV0e/GbHn5Xk9QXfaoMviP0kv9wGXzepPfFfmOajZZY7mEXGhm15LF 2kgmOAxRqO1avai65IhP7DVCQAycKfbyy5VyZ5PL12lMTXJV4tP7Kdv54786XVYqWxYDAm G0PhjG3WLpMdI8uLOo0sl9GNB4mu6LpjKKnGhfUOmFtTS4W1gRl9Sp18EDv+AQ== 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 4VM7Ds2RnfzZCb; Sat, 20 Apr 2024 10:34:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYrRu014563; Sat, 20 Apr 2024 10:34:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYrXe014560; Sat, 20 Apr 2024 10:34:53 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:53 GMT Message-Id: <202404201034.43KAYrXe014560@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: 3f0f6c980669 - stable/13 - libllvm: add missed tlbgen headers and sources for BPF target List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 3f0f6c9806695c4ac32294f6f117b59aae0ea94a Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=3f0f6c9806695c4ac32294f6f117b59aae0ea94a commit 3f0f6c9806695c4ac32294f6f117b59aae0ea94a Author: Dimitry Andric AuthorDate: 2024-04-10 22:10:07 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:09 +0000 libllvm: add missed tlbgen headers and sources for BPF target Noticed by: vishwin PR: 276104 MFC after: 1 month (cherry picked from commit 442d351bd242d14b1c0bb67cd048ac022f2e82ad) --- lib/clang/libllvm/Makefile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/clang/libllvm/Makefile b/lib/clang/libllvm/Makefile index 5dc864fabbcd..528551aab852 100644 --- a/lib/clang/libllvm/Makefile +++ b/lib/clang/libllvm/Makefile @@ -1393,12 +1393,17 @@ SRCS_MIN+= Target/BPF/BPFMIChecking.cpp SRCS_MIN+= Target/BPF/BPFMIPeephole.cpp SRCS_MIN+= Target/BPF/BPFMISimplifyPatchable.cpp SRCS_MIN+= Target/BPF/BPFPreserveDIType.cpp +SRCS_MIN+= Target/BPF/BPFPreserveStaticOffset.cpp SRCS_MIN+= Target/BPF/BPFRegisterInfo.cpp SRCS_MIN+= Target/BPF/BPFSelectionDAGInfo.cpp SRCS_MIN+= Target/BPF/BPFSubtarget.cpp SRCS_MIN+= Target/BPF/BPFTargetMachine.cpp SRCS_MIN+= Target/BPF/BTFDebug.cpp SRCS_MIN+= Target/BPF/Disassembler/BPFDisassembler.cpp +SRCS_MIN+= Target/BPF/GISel/BPFCallLowering.cpp +SRCS_MIN+= Target/BPF/GISel/BPFInstructionSelector.cpp +SRCS_MIN+= Target/BPF/GISel/BPFLegalizerInfo.cpp +SRCS_MIN+= Target/BPF/GISel/BPFRegisterBankInfo.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFAsmBackend.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFELFObjectWriter.cpp SRCS_MIN+= Target/BPF/MCTargetDesc/BPFInstPrinter.cpp @@ -2199,8 +2204,10 @@ TGHDRS+= BPFGenAsmWriter.inc TGHDRS+= BPFGenCallingConv.inc TGHDRS+= BPFGenDAGISel.inc TGHDRS+= BPFGenDisassemblerTables.inc +TGHDRS+= BPFGenGlobalISel.inc TGHDRS+= BPFGenInstrInfo.inc TGHDRS+= BPFGenMCCodeEmitter.inc +TGHDRS+= BPFGenRegisterBank.inc TGHDRS+= BPFGenRegisterInfo.inc TGHDRS+= BPFGenSubtargetInfo.inc .endif # MK_LLVM_TARGET_BPF From nobody Sat Apr 20 10:34:54 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dw0Dpgz5HWS0; Sat, 20 Apr 2024 10:34:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dt4LrVz4T3y; Sat, 20 Apr 2024 10:34:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609294; 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=d2HQL84FXJ56Z7ZMf7wu2VeIBjqOutrzJB5lQR5rLSM=; b=WLwDrC9rv2KglG+eMznteeZgFSQiFbJc32B74NFDl2WItH1nsnPeeYbdpmiNC/gy3bQ4ou rr0sMj/kqK/Vk2lZMwJxRmXiWhwqSNNVlK1W8IbAnZXhV1AZSkcWdzJM4GI/bB4yMriku2 JykgMQFCbBeZI8BL5NOt/kRdqX4gBxc+F6XnD+t3J0yEZQroWyPnmu4zWX74o5LWlo3Cgz N5EYopmzC8AgFgdOcXHz2UoTbzs7Pr3QaYCmkgt1KuHqhbsPR0gFXcrh8ktDvkjyGbzpeC UPqNPS9Igk29YnUL8ScsONPyCfQncwJMkvTBB+Dx1Vp9FJnG70gfx/A7bhV+3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609294; a=rsa-sha256; cv=none; b=xEjsmOQGgdkMCGjeiyPWdyVQJJTlf5BuWpVEUAOjLL8/HSqoVkgMIDIivKHvmGNLMsUBc7 e4GAibrmCosXqwAy9SgW7SmnCxQFrVpGADRCCdYqcL1V2b7oGfS1Ik+9Y6q/uQoTxgeuzq XYGTucXbntHWmN9vzyb80ebLy048Vc0pvh6JOGRVRaNANVuo5UPdZVvGcSWaOUVnsPh9+c U6fN1dv3T6zcipsL7hcSbY5YQ5CTxgmLAO/52FZbXC0E69jhvjJd6pRVm00b8mJtPk4aiI 3K1wsa8GlX/0fM/YjfjNgCTbTbc2AlTvOkutVBUtRTtuaHStAHmlytF26r+xCQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609294; 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=d2HQL84FXJ56Z7ZMf7wu2VeIBjqOutrzJB5lQR5rLSM=; b=HC71PzcAFh096VswvMqdIErJrV/x6IiGfw2/+HhCTG6UIYT/0Rl1DS0p138rzsL8TMCuaX 9Tp3jsHnsDGaIJOrwW8tUnHE9XnyoSJt1xY8rsEkBkHDD/rf/Sd4ExFLQbGb7TTS6loKod y/0rjk2f6lunf5YsmXG6dDLUr2v0UHPhVvvTspjS4NY2Z7bQQUUV10tWuDse/KFa2drLNt KKE1dWs/YoZSL5WkzIWl8lerkMkaQxsWgQYoRiaIrT1XDo5MQHiom9Hh2HeIyPC4ycId5l n2FUMceMS6NHlSSe/pRJj0Entq+ZA61BfJR6XT4ZCAOMsdk+KDFG0pBp91hNNA== 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 4VM7Dt3yTGzYrH; Sat, 20 Apr 2024 10:34:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYsnK014619; Sat, 20 Apr 2024 10:34:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYst1014616; Sat, 20 Apr 2024 10:34:54 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:54 GMT Message-Id: <202404201034.43KAYst1014616@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: ac652ee7fbdc - stable/13 - Merge commit 55c466da2f2f from llvm-project (by Benjamin Kramer): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: ac652ee7fbdcf0651f23bc09455f7705980fd232 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ac652ee7fbdcf0651f23bc09455f7705980fd232 commit ac652ee7fbdcf0651f23bc09455f7705980fd232 Author: Dimitry Andric AuthorDate: 2024-04-11 21:12:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 Merge commit 55c466da2f2f from llvm-project (by Benjamin Kramer): [X86][AVX512BF16] Add a few missing insert/extract patterns These are really the same as the f16 (and i16) instructions, but we need them for any type that can occur. Merge commit 2e4e04c59043 from llvm-project (by Phoebe Wang): [X86][BF16] Do not lower to VCVTNEPS2BF16 without AVX512VL (#86395) Fixes: #86305 These should fix "fatal error: error in backend: Cannot select: t71: v32bf16 = insert_subvector t67, t64, Constant:i32<16>" when building the misc/ncnn port. PR: 278305 Reported by: yuri MFC after: 1 month (cherry picked from commit 78d3648e73d11c5a4dbcc0392907f0723bf1df1c) --- contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp | 7 +++++-- contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td | 12 ++++++++++++ 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp index 9e64726fb6ff..96bbd981ff24 100644 --- a/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/X86/X86ISelLowering.cpp @@ -21420,7 +21420,9 @@ SDValue X86TargetLowering::LowerFP_ROUND(SDValue Op, SelectionDAG &DAG) const { } if (VT.getScalarType() == MVT::bf16) { - if (SVT.getScalarType() == MVT::f32 && isTypeLegal(VT)) + if (SVT.getScalarType() == MVT::f32 && + ((Subtarget.hasBF16() && Subtarget.hasVLX()) || + Subtarget.hasAVXNECONVERT())) return Op; return SDValue(); } @@ -21527,7 +21529,8 @@ SDValue X86TargetLowering::LowerFP_TO_BF16(SDValue Op, SDLoc DL(Op); MVT SVT = Op.getOperand(0).getSimpleValueType(); - if (SVT == MVT::f32 && (Subtarget.hasBF16() || Subtarget.hasAVXNECONVERT())) { + if (SVT == MVT::f32 && ((Subtarget.hasBF16() && Subtarget.hasVLX()) || + Subtarget.hasAVXNECONVERT())) { SDValue Res; Res = DAG.getNode(ISD::SCALAR_TO_VECTOR, DL, MVT::v4f32, Op.getOperand(0)); Res = DAG.getNode(X86ISD::CVTNEPS2BF16, DL, MVT::v8bf16, Res); diff --git a/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td b/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td index bb5e22c71427..fdca58141f0f 100644 --- a/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td +++ b/contrib/llvm-project/llvm/lib/Target/X86/X86InstrAVX512.td @@ -494,6 +494,8 @@ defm : vinsert_for_size_lowering<"VINSERTI32x4Z256", v16i8x_info, v32i8x_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; defm : vinsert_for_size_lowering<"VINSERTF32x4Z256", v8f16x_info, v16f16x_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; +defm : vinsert_for_size_lowering<"VINSERTF32x4Z256", v8bf16x_info, v16bf16x_info, + vinsert128_insert, INSERT_get_vinsert128_imm, [HasVLX]>; // Codegen pattern with the alternative types insert VEC128 into VEC512 defm : vinsert_for_size_lowering<"VINSERTI32x4Z", v8i16x_info, v32i16_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; @@ -501,6 +503,8 @@ defm : vinsert_for_size_lowering<"VINSERTI32x4Z", v16i8x_info, v64i8_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; defm : vinsert_for_size_lowering<"VINSERTF32x4Z", v8f16x_info, v32f16_info, vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; +defm : vinsert_for_size_lowering<"VINSERTF32x4Z", v8bf16x_info, v32bf16_info, + vinsert128_insert, INSERT_get_vinsert128_imm, [HasAVX512]>; // Codegen pattern with the alternative types insert VEC256 into VEC512 defm : vinsert_for_size_lowering<"VINSERTI64x4Z", v16i16x_info, v32i16_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; @@ -508,6 +512,8 @@ defm : vinsert_for_size_lowering<"VINSERTI64x4Z", v32i8x_info, v64i8_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; defm : vinsert_for_size_lowering<"VINSERTF64x4Z", v16f16x_info, v32f16_info, vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; +defm : vinsert_for_size_lowering<"VINSERTF64x4Z", v16bf16x_info, v32bf16_info, + vinsert256_insert, INSERT_get_vinsert256_imm, [HasAVX512]>; multiclass vinsert_for_mask_cast; defm : vextract_for_size_lowering<"VEXTRACTF32x4Z256", v16f16x_info, v8f16x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasVLX]>; +defm : vextract_for_size_lowering<"VEXTRACTF32x4Z256", v16bf16x_info, v8bf16x_info, + vextract128_extract, EXTRACT_get_vextract128_imm, [HasVLX]>; // Codegen pattern with the alternative types extract VEC128 from VEC512 defm : vextract_for_size_lowering<"VEXTRACTI32x4Z", v32i16_info, v8i16x_info, @@ -803,6 +811,8 @@ defm : vextract_for_size_lowering<"VEXTRACTI32x4Z", v64i8_info, v16i8x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; defm : vextract_for_size_lowering<"VEXTRACTF32x4Z", v32f16_info, v8f16x_info, vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; +defm : vextract_for_size_lowering<"VEXTRACTF32x4Z", v32bf16_info, v8bf16x_info, + vextract128_extract, EXTRACT_get_vextract128_imm, [HasAVX512]>; // Codegen pattern with the alternative types extract VEC256 from VEC512 defm : vextract_for_size_lowering<"VEXTRACTI64x4Z", v32i16_info, v16i16x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; @@ -810,6 +820,8 @@ defm : vextract_for_size_lowering<"VEXTRACTI64x4Z", v64i8_info, v32i8x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; defm : vextract_for_size_lowering<"VEXTRACTF64x4Z", v32f16_info, v16f16x_info, vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; +defm : vextract_for_size_lowering<"VEXTRACTF64x4Z", v32bf16_info, v16bf16x_info, + vextract256_extract, EXTRACT_get_vextract256_imm, [HasAVX512]>; // A 128-bit extract from bits [255:128] of a 512-bit vector should use a From nobody Sat Apr 20 10:34:55 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dw1TKRz5HWbP; Sat, 20 Apr 2024 10:34:56 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dv74Ybz4TSZ; Sat, 20 Apr 2024 10:34:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609296; 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=MDqcY26wn4Z5qJus6SM8NjMi7K805ecJFIeBwDfFXFo=; b=oYT+ULKpfpE1lnxumQehkTytQseq70PaAHST05ki8T057mEfxG07h7tj6tFckIeUt60aoV T/2yKi+f/R+nK9w4DaL1rDLjwlUF8c6bqUxxSdpriNPPPss05awNJPVhwq4Fch3eBNgIce PewvnDi42rntp7inUKI7VYMAou1jsXhWJAt7IUXvpWfCf40VnIFXIp07SSRBvJ6hZpZ5AC wGs/l+TTNB6JbYYeAP5NnGY0o4RKvJabFdsFwZdc3J3VFq820QViRWxEOnBo0QVLozboa4 VuXgnWXSJvdGc/0FT/gIfAO6kbXA9z1s28nsDgNdqD3mv8docQ01wR34fmn1CQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609296; a=rsa-sha256; cv=none; b=qrfT4NdZ++dZL5DjLcl+LX1SLyGESvaZL1um+3R2R1znhDlhUer7WWH6Q0NodTyaDVzIK3 wIvGNrwgW182ylTFELlvXuumGfezFjJ7SP9Jk+fj1GGRs/xPl03beF+Tg1WuD/QkGvnaA6 Akk1BsZ2qA3oqRw+VfWTp9l93gqcWNQrLb8P6iaVLJks5d/cEQAiqf9GMwvj3t2zMTW8pH haUN6/AwETEEEJPDr0lmBgKLOIK2ehMCrP86Tcd82/jUhXywNrmvmd2naseNyAEB2Md5Yw n0nQ2uKE9rfkZBzfE++1YyMVjRefWLQK/BBOL7LExN+Xz6zAYS2BgUKZ+qdBiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609296; 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=MDqcY26wn4Z5qJus6SM8NjMi7K805ecJFIeBwDfFXFo=; b=pGy8iBTYEWTOIxjRv12b/rzVvAgFy6vHkYSzlDBhM2uVygiPtWh5eL6936bcLCjZK9YlLD 0FLjk5/EQ2ZQF1sxlpkqQgNHqbpDbCMre6gasGoJDn93kHO+PX2+nN66LVVaJXos0dN1nd Q28jAFocU82JKVa4/8KcPk2kmcxF3BFB804OELV7j9ruBFC1dxbM8RlYiqMJ4WbDUQhPdq 8E8GFGBvTpn4Y6ZTejJqYdGuP7047BSlC/VnlmfpnEQbcrb+O8R4/VFSA8ay/lpHA70f3C W45KBeh5obskGGhCdQjULkLy8pl9sE28LqvdJGsiaA+2TfotrBaYfm6pUEbeNQ== 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 4VM7Dv50QFzYrK; Sat, 20 Apr 2024 10:34:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYtvd014672; Sat, 20 Apr 2024 10:34:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYtMq014669; Sat, 20 Apr 2024 10:34:55 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:55 GMT Message-Id: <202404201034.43KAYtMq014669@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: 70ab6e9b180d - stable/13 - Revert commit 925a11a5f221 from llvm-project (by Nikolas Klauser): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 70ab6e9b180dd7ed0cce5c9c69dd3348099b63bd Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=70ab6e9b180dd7ed0cce5c9c69dd3348099b63bd commit 70ab6e9b180dd7ed0cce5c9c69dd3348099b63bd Author: Dimitry Andric AuthorDate: 2024-04-13 08:44:26 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 Revert commit 925a11a5f221 from llvm-project (by Nikolas Klauser): [libc++] Simplify is_convertible GCC 13 has added __is_convertible(), so we don't need to keep the fallback implementation around. Reviewed By: #libc, Mordante Spies: Mordante, libcxx-commits Differential Revision: https://reviews.llvm.org/D157939 This should allow buildworld with gcc 12 to work again. PR: 276104 MFC after: 1 month (cherry picked from commit 2365f012951e5f0333cf31c690f668299c86b30e) --- .../libcxx/include/__type_traits/is_convertible.h | 79 +++++++++++++++++++++- 1 file changed, 78 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h b/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h index bc91d8b23430..b378a20cedeb 100644 --- a/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h +++ b/contrib/llvm-project/libcxx/include/__type_traits/is_convertible.h @@ -24,12 +24,89 @@ _LIBCPP_BEGIN_NAMESPACE_STD +#if __has_builtin(__is_convertible) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + template struct _LIBCPP_TEMPLATE_VIS is_convertible : public integral_constant {}; +#elif __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + +template +struct _LIBCPP_TEMPLATE_VIS is_convertible : public integral_constant {}; + +// TODO: Remove this fallback when GCC < 13 support is no longer required. +// GCC 13 has the __is_convertible built-in. +#else // __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + +namespace __is_convertible_imp { +template +void __test_convert(_Tp); + +template +struct __is_convertible_test : public false_type {}; + +template +struct __is_convertible_test<_From, _To, decltype(__is_convertible_imp::__test_convert<_To>(std::declval<_From>()))> + : public true_type {}; + +// clang-format off +template ::value, + bool _IsFunction = is_function<_Tp>::value, + bool _IsVoid = is_void<_Tp>::value> + struct __is_array_function_or_void { enum { value = 0 }; }; +template struct __is_array_function_or_void<_Tp, true, false, false> { enum { value = 1 }; }; +template struct __is_array_function_or_void<_Tp, false, true, false> { enum { value = 2 }; }; +template struct __is_array_function_or_void<_Tp, false, false, true> { enum { value = 3 }; }; +// clang-format on +} // namespace __is_convertible_imp + +template >::value> +struct __is_convertible_check { + static const size_t __v = 0; +}; + +template +struct __is_convertible_check<_Tp, 0> { + static const size_t __v = sizeof(_Tp); +}; + +template ::value, + unsigned _T2_is_array_function_or_void = __is_convertible_imp::__is_array_function_or_void<_T2>::value> +struct __is_convertible + : public integral_constant::value >{}; + +// clang-format off +template struct __is_convertible<_T1, _T2, 0, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 1> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 1> : public false_type{}; + +template struct __is_convertible<_T1, _T2, 0, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 2> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 2> : public false_type{}; + +template struct __is_convertible<_T1, _T2, 0, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 1, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 2, 3> : public false_type{}; +template struct __is_convertible<_T1, _T2, 3, 3> : public true_type{}; +// clang-format on + +template +struct _LIBCPP_TEMPLATE_VIS is_convertible : public __is_convertible<_T1, _T2> { + static const size_t __complete_check1 = __is_convertible_check<_T1>::__v; + static const size_t __complete_check2 = __is_convertible_check<_T2>::__v; +}; + +#endif // __has_builtin(__is_convertible_to) && !defined(_LIBCPP_USE_IS_CONVERTIBLE_FALLBACK) + #if _LIBCPP_STD_VER >= 17 template -inline constexpr bool is_convertible_v = __is_convertible(_From, _To); +inline constexpr bool is_convertible_v = is_convertible<_From, _To>::value; #endif _LIBCPP_END_NAMESPACE_STD From nobody Sat Apr 20 10:34:57 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dz0d7jz5HWbT; Sat, 20 Apr 2024 10:34:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dy095cz4TQm; Sat, 20 Apr 2024 10:34:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609298; 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=1oQmA52zT7Bzytb+tLfByQe5DXXGfPpsnQLjPdzX+DY=; b=m94dDMEkRnm0hgxev8It85dZv4gPjC4BUFfsLh7+1gGKlKD0p2qeqSJEvXp6lOIQBVQZ7p igQybABPDTAlQiq3ZOl17RYVH1UhOJKgYsjIP6+OUHnjOac6gyLHeaDs8kdygj6t+T7/0x BbQIc/A9AxSAj08rCt8YnYTB0CMIspzzXQazObOr6Q+AfTXPYKSG28XpmRKz5CooGu5A2c DFYKCtRS0pOiunx10Dv4JDdzoqjjePxFmkYvortHrzRKXbNS+Vl6mLgTaqjTybF7ZTW6Uz 9ENe5WdPR7oy/qHZFDo8ZZD64fON1O5HdjhCI0bRz9OE9FL//52sD6LCjfxyLA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609298; a=rsa-sha256; cv=none; b=qmqX94U+86aaC59HD9JlwwEl/Pz96ZrDqrQ2mW43xORWvKJkWo6V8sSG0Gai/ccOy2LVTT ZKs+FRp2fQknVec2H7NoWdd/mUAhJ+XlIkaLzNwwS1HsISqvYvJWF7F7o9lxjZREH3MCc1 spr9o+xaAMbTy4Pqymuom9TsSUmH66JC7BbR0xWQxH2dnUf1dyRHg6i9pCzi6azJ/Js5Gg Tf255zEJJ4w00WndVO8AHvoBVJgObbwBYIW/e9JZupzAwneMUdmHLKpBEz+Z9200H2nPVf dk41g6W1z6+M8sH2IXEemK8Kl9bf6OjKJrAtChHd9dJAu9lNPoGZs6ZB8eJTRQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609298; 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=1oQmA52zT7Bzytb+tLfByQe5DXXGfPpsnQLjPdzX+DY=; b=XDiNSjJdNyXG6o8wQQDH6AQZ/ij22h7sO7jOc1qIAqSENvPCBwL2nZcZ/7oYrxqJYbLre3 dZtYNmbVzg3c79qWmaj3zvkq8RlR1OwG/AfjiZhtUWoctZF/MnewUIRieWJgHdmyQGeEnP iXVQcceva2PuBjn++x/s0yjV+9snkkxCgPfXg1tYTCd4S3WsVjh+nrctsnJ1oujHakPSR/ iD/1zD2sAEjGxrEjtX8w94jnDOBlLkziJhTcKfknYmw8ZbalVPnyUtC3hwariBmQASmhzF f4gi9iu2TfmITVCF+yamvgZvHSQ07/Icx6Tu8Qt4lzbVIq+d1e1ohSwyOcxKLA== 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 4VM7Dx6vWnzYkn; Sat, 20 Apr 2024 10:34:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYvEU014777; Sat, 20 Apr 2024 10:34:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYvcI014774; Sat, 20 Apr 2024 10:34:57 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:57 GMT Message-Id: <202404201034.43KAYvcI014774@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: 5b763c0e1f30 - stable/13 - Merge commit 37b7207651b4 from llvm-project (by zhongyunde@huawei.com): List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 5b763c0e1f30583f8447a0818e2a72498d2e2bc3 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=5b763c0e1f30583f8447a0818e2a72498d2e2bc3 commit 5b763c0e1f30583f8447a0818e2a72498d2e2bc3 Author: Dimitry Andric AuthorDate: 2024-04-15 16:24:39 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 Merge commit 37b7207651b4 from llvm-project (by zhongyunde@huawei.com): [SimplifyCFG] Fix crash when there is unreachable large index (#88616) The large case index out of scope is dead code, but it is still be created for TableContents in SwitchLookupTable::SwitchLookupTable, so make sure the table size after growing should not get smaller. Fix https://github.com/llvm/llvm-project/issues/88607 This should fix "Assertion failed: (idx < size()), function operator[]" when building the science/dynare port. PR: 276104, 278320 Reported by: yuri MFC after: 1 month (cherry picked from commit 514c98ba14a0f590891844d1a6bec0ac4de54489) --- contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp index 13eae549b2ce..f95dae1842fe 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/SimplifyCFG.cpp @@ -6710,9 +6710,11 @@ static bool SwitchToLookupTable(SwitchInst *SI, IRBuilder<> &Builder, return SwitchLookupTable::WouldFitInRegister( DL, UpperBound, KV.second /* ResultType */); })) { + // There may be some case index larger than the UpperBound (unreachable + // case), so make sure the table size does not get smaller. + TableSize = std::max(UpperBound, TableSize); // The default branch is unreachable after we enlarge the lookup table. // Adjust DefaultIsReachable to reuse code path. - TableSize = UpperBound; DefaultIsReachable = false; } } From nobody Sat Apr 20 10:34:56 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dx2XSZz5HWhq; Sat, 20 Apr 2024 10:34:57 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dw6DLLz4TC3; Sat, 20 Apr 2024 10:34:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609296; 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=wwkkqxwdHY01ow8Bt5O3ZxnCKhzpSCgixaQ4jEYATA0=; b=Ag2hZLIAqTwbABkXJ4NFhPLS861ZBifixzs8M1i9wQ32JM97BlmmjtiRqC9O/4K8VdZWf6 tisX7VZ1GKGqtP/l+D2M1HIEPZXfAzOhLjE3UnevDtRSAHJwv0PtU14izl3aDECzAOgCXs lGuPd2maR/sSaspjVSh8+qg5k4ecutBcmrNYL9mzNEMLIi1M0dtVUzq3KkkrQjk5dQuMVm CAmz16uWEyyF0nu4dCAOOw2YXdhObeEHje7xUE2VQS+D4vItXoX9xjbUUXDZ1jLG2fDk2X OppFs6DgJo+U0iVsPFGDTfCfbZ4lpgjx0CtWfei0ln45RxB2HWs2/3f5/d/fnQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609296; a=rsa-sha256; cv=none; b=oBK+t6LYh8xsaniDwlMIq5cRgeTEGkNO/cKO5QPtjz4poYM0yr9XwwcG4RHIY0MyMZeiEL Ur3V2ycDoSCeTULLnaHwQIvGgxNnZ8i96wHUXCHINnldsKf8lEYHdjeW4mQeEXeZ+BOSoJ pKQIO8P7beINWdmJtlxrPfBCUjcWHAEp0npzFp09ZPk9P5QIA5WG8Bjz7ndYbqDzUSqlzU iS9CsYjE8uy8pEDUkKt0icb7uD9yN2d3HeZh2z2ij6h5tN9RZ0gajitX/kTN//50ChgWFA n5GSB1/q+wDwI24eFR+LYxKi1pNT+syqR6WEOGhFmdWXO8uocKNQ7iaCskJmkQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609296; 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=wwkkqxwdHY01ow8Bt5O3ZxnCKhzpSCgixaQ4jEYATA0=; b=og4Aq37I4oI6vvA0OZJ9Mgnov1w7h7Jphp3jbt6XUH3aAhqQ7fDE2jKhgS33evx09Dtraa EjYR44YnsYa9HRoOjYX9cSjsuOUmtiPsw0ShLIK+5KYIBnBjAasmREm4NOI+CRPirTKC33 /aFTOX5agNrYsQlBsf6vTRbh1Y7VpMiA5InLGoNSDmnDL0JmYI5mBLs1sA9ykhodWNJS7N xmhpNIfn0fb/PT7XqCQ0JDkp+I68B+RP4+WfHU7rLOzczf8C4bSsGrbh/yDc6n8vG7dBOo KYIBkNLrI6vQZivuRBB01NoZGj9ZfXtRGNRhmetMazXMtLAb30aClNc5yp8NWw== 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 4VM7Dw5r1LzYkm; Sat, 20 Apr 2024 10:34:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYufH014729; Sat, 20 Apr 2024 10:34:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYupn014726; Sat, 20 Apr 2024 10:34:56 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:56 GMT Message-Id: <202404201034.43KAYupn014726@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: bf7e13e690c3 - stable/13 - sanitizers: mark __elf_aux_vector as weak, to allow linking without libsys List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: bf7e13e690c32a86fa2cb4aa31343c935dc6cdcb Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=bf7e13e690c32a86fa2cb4aa31343c935dc6cdcb commit bf7e13e690c32a86fa2cb4aa31343c935dc6cdcb Author: Dimitry Andric AuthorDate: 2024-04-14 17:38:42 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 sanitizers: mark __elf_aux_vector as weak, to allow linking without libsys After libsys was introduced, linking sanitized programs started failing with: # c++ -fsanitize=address main.cc ld: error: undefined symbol: __elf_aux_vector >>> referenced by sanitizer_linux_libcdep.cpp:950 (/usr/src/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp:950) >>> sanitizer_linux_libcdep.o:(__sanitizer::ReExec()) in archive /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a c++: error: linker command failed with exit code 1 (use -v to see invocation) Mark __elf_aux_vector as weak in the internal sanitizer declaration, so the linker will accept it at link time. The dynamic linker will then take care of the symbol at run time. Suggestion by: brooks PR: 276104, 277393 MFC after: 1 month (cherry picked from commit 8b181c2fbaa8c6b32e5510ef6e3a6d364ff4710e) --- .../compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp b/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp index cccbb4d256df..962fff53e447 100644 --- a/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp +++ b/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp @@ -53,7 +53,7 @@ // that, it was never implemented. So just define it to zero. # undef MAP_NORESERVE # define MAP_NORESERVE 0 -extern const Elf_Auxinfo *__elf_aux_vector; +extern const Elf_Auxinfo *__elf_aux_vector __attribute__ ((weak)); # endif # if SANITIZER_NETBSD From nobody Sat Apr 20 10:34:59 2024 X-Original-To: dev-commits-src-branches@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 4VM7Dz3BFsz5HWdX; Sat, 20 Apr 2024 10:34:59 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7Dz1SWZz4TNf; Sat, 20 Apr 2024 10:34:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609299; 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=tTjbmYBPpgvdnM7ki7wPoea3apO3phUGf0dz+7yVc4I=; b=nwPRo3a4/c4LVXAMGHAmKVqpe+ubs++Ude4WuikdK/jHrGsyw9gZ+A58sGJFQOsoMff/7m zIrl+5+/BUaSuMgGqFkhjq/tvDgyG4KkWPgj0tnZ+bp58blc8LZXzJDeCXJj9go2TTmke+ fglfmu/GzGs9m8INxDYBUBJweO2I6C+bi9dBzc5vwb34OZb+rvaMffqwlNsQ+2s7zFT+42 CpSBzIT2NK70JrwmIz2tQ9teLEyQ+VE+Mig/529Wdxojt+tqhnGRQVNvPiriTEERd8KUvE jEbNOP1WIcOAgG7du27HU5uPUD2av/0Olhq4DOTXYwqnIDAgXtS4J+sb1d0W3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609299; a=rsa-sha256; cv=none; b=XqKHtWnaSGyI4hWcvD4SjF6AEuiRaXiGxX0TB0AZiGoh7jruaxvaCImidtiV5hQc+rk5EG is0Ll2rtgW+rDUM3TSOn6kv4CrM/cCWIY6JJjg43Gq4DCBln6G0tUnSOQcZ3A6UfahoFWv lc4gxi0gB/hoLZtf8uarV+rdoKl5oDUdUEw9Of/1syKMWmmhX+UThMBDtlc8eAN3wbCa0Q ZP446qoMeAl2csptcW+QhA70sIakRHbaXB8Vcz9NlQLjfm5/IwzgsttwIsnBK+8ZVUL9Fs q2EDQScYic/6oO6S4RB95VLVW6IFgkSz2tnu5niOYwKjgU7MTQkkPs+8xFiolg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609299; 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=tTjbmYBPpgvdnM7ki7wPoea3apO3phUGf0dz+7yVc4I=; b=Yln5VyJDYRvq751baFHtW58yKpz0Dtzgi2hb/Op/Ro9dmmckrwTfDzP7Kca3CgJnRhlLSG +juz8K6/smQOxoEH8bJjrVQgFjgeajYSu3220KLP4+cLLr/HNUbeJbJtnQuzWBEFPZGeLv dD3AegqaW/hYWwNBZWnKQcswFi30Hmq8pCetD+K9Yw8C1lx34XVBLs5GEFELIApTki6wTo v7gNUvo9GpuN1n3bZa4iGNcmlaSa7BDhakJ6BqgoPDYWYE9GDrHu82FfQiB1n/4H0yZgLD 3GPZT/tdyZJL9Qe0yaVwV+N6gv0Feb1i55PJU5LWo/9xFvSzoPoHNNRk+oAoyw== 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 4VM7Dz0nSHzYrL; Sat, 20 Apr 2024 10:34:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAYxBx014819; Sat, 20 Apr 2024 10:34:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAYxrD014816; Sat, 20 Apr 2024 10:34:59 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:34:59 GMT Message-Id: <202404201034.43KAYxrD014816@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: 50fd2fbec96c - stable/13 - libcompiler_rt Makefile.inc: update _Float16/__bf16 checks List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 50fd2fbec96c46961addac790c10c1d49d3673f9 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=50fd2fbec96c46961addac790c10c1d49d3673f9 commit 50fd2fbec96c46961addac790c10c1d49d3673f9 Author: Dimitry Andric AuthorDate: 2024-04-17 20:20:47 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 libcompiler_rt Makefile.inc: update _Float16/__bf16 checks Clang supports __bf16 for riscv from version 18.0 onwards, so update the checks for it. While here, rewrite the checks so they are hopefully more readable, and also handle gcc a little better. In addition, define COMPILER_RT_HAS_FLOAT16 and COMPILER_RT_HAS_BFLOAT16 when these features should be available, since there are some parts in compiler-rt that check for these defines. PR: 276104 MFC after: 1 month (cherry picked from commit f276adc148433d009d198c2ebccdd3303377e237) --- lib/libcompiler_rt/Makefile.inc | 33 ++++++++++++++++++++++++++++----- 1 file changed, 28 insertions(+), 5 deletions(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index c0dacb5c9d7e..4fc02bae5710 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -228,13 +228,36 @@ SRCF+= comparedf2 SRCF+= comparesf2 .endif +# Helper to reduce complexity of _Float16 and __bf16 statements below. +.if ${MACHINE_CPUARCH} == "aarch64" || \ + ${MACHINE_CPUARCH} == "amd64" || \ + ${MACHINE_CPUARCH} == "arm" || \ + (${MACHINE_CPUARCH} == "i386" && !empty(MACHINE_CPU:Msse2)) +CRT_COMMON_F16_ARCH=t +.endif + +# +# _Float16 support, only on some architectures, and with certain compiler +# versions. +# +.if ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 150000) && \ + (defined(CRT_COMMON_F16_ARCH) || ${MACHINE_CPUARCH} == "riscv")) || \ + ((${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} >= 120000) && \ + (defined(CRT_COMMON_F16_ARCH))) +CFLAGS+= -DCOMPILER_RT_HAS_FLOAT16 +.endif + # -# bfloat16 support, only used on some architectures. +# __bf16 support, only on some architectures, and with certain compiler +# versions. # -.if (${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \ - ${MACHINE_CPUARCH} == "arm" || (${MACHINE_CPUARCH} == "i386" && \ - !empty(MACHINE_CPU:Msse2)) || ${MACHINE_CPUARCH} == "riscv") && \ - !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 130000) +.if ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 150000) && \ + (defined(CRT_COMMON_F16_ARCH))) || \ + ((${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 180000) && \ + ${MACHINE_CPUARCH} == "riscv") || \ + ((${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} >= 130000) && \ + (defined(CRT_COMMON_F16_ARCH))) +CFLAGS+= -DCOMPILER_RT_HAS_BFLOAT16 SRCF+= truncdfbf2 SRCF+= truncsfbf2 .endif From nobody Sat Apr 20 10:35:00 2024 X-Original-To: dev-commits-src-branches@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 4VM7F11rc0z5HWhv; Sat, 20 Apr 2024 10:35:01 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7F01lDzz4TNr; Sat, 20 Apr 2024 10:35:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609300; 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=XARSFNvQjGMDjtWPZPJNqIXDSuPRr4NcQ3ie39T+aBo=; b=F59MlhDhuiqyIZILOXDscyDZqss+EHxZgeVDCMftJvwKCLQ4o5z8pw3kt7OP1y1Lrm6MLA fwqqxhxEyWOpX20iPYp+/3y8ej2bBr3KOqYVYSLRUjHZF+sUGgR9snEjWqYeDqVjawVBed B4WdW+qwOTtq60LVfUZaJr7pYgDXx9zGHfJs8HNz4EefTir62wazebNHX/9hxnmxyoGGz8 tCiZc8gZJWWJYxWuYi8jE+4/mkbyiiaeypdTdlPuirSClk6A/8UiZP+IE0fXkRmbFtB6YS fcZbw2iHzLtWSFBtR4qPsts3nOCjCjuRyT78r6S40iD6t1af3yM0s6G+R2waKQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609300; a=rsa-sha256; cv=none; b=skNkosVK9DbJZjj5OphLHejUQpQJRhw6r/9cMo5c6Q2xgay/46en4J23l0dhQs+OLb0HZr /LHeBo5YLNTEuGfqbrSPs5RkSLElJVQnpUHTpmvXu5OEgKW+DRmkFIz8N8hGQbAsB5eVqZ cXcsmgRYc0FgK3UUEu8DMHnwwgSf78m/UOvXq7GGUr8eifm52RSx/jO1RbThUaScQVKmSE kqooMsmOU+yvKdf6h0YtKaDOw83jEqHlLwwrpvgQFHIUXJy6tkEL8lnykg+BX/+B8Ia5I9 B9z0lD6aBx3FmLS5V1YNN+dODt4YpbujhjNAB5oUMJG4bMZaYb9QsvpPSxZRcQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609300; 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=XARSFNvQjGMDjtWPZPJNqIXDSuPRr4NcQ3ie39T+aBo=; b=BE+RHg1jtu/4LDuV/WCuuvMAtqfLnJO0dwVJZ1JSUJjYDSjivX8ZBS53k149QYklWlV/7K GeWAXbZpnrCX2uTrnnPVJxl5aBkQi72QMG6S9jSEFujDFCX7c/9urkitonMcy2PqdHkAJS B+rcbXzczaTFM8O6vWfXA/1u/8spDh7zs7pVAPpLODa53M9ekRdnUDrYmAkhk4Gs/2YQQQ Q9q97lGtv//vBGcIw+jGDhe0qTUekjBzUuZsu3DsrvUhgrhZwKU2I+5VvEYT46rwK+KPIF qQBUuMCZfbUJHSQCKXUeqnLp1uMsmZGbMKfyjZzbWcJza/O6zpmIzbORaIoJ4w== 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 4VM7F01Mh5zYkp; Sat, 20 Apr 2024 10:35:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAZ0vc014880; Sat, 20 Apr 2024 10:35:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAZ0Vc014877; Sat, 20 Apr 2024 10:35:00 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:35:00 GMT Message-Id: <202404201035.43KAZ0Vc014877@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: 82d22a88c340 - stable/13 - libgcc_{eh,s}: restore __*_frame_info symbols post llvm18 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 82d22a88c340b83ef47a5499935b6033e898ff58 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=82d22a88c340b83ef47a5499935b6033e898ff58 commit 82d22a88c340b83ef47a5499935b6033e898ff58 Author: Brooks Davis AuthorDate: 2024-04-19 21:45:05 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 libgcc_{eh,s}: restore __*_frame_info symbols post llvm18 The upstream llvm commit 5eb44df1b64d made the addition of these GCC compatability symbols dependent on build configuration rather than hardcoded for amd64, i386, and powerpc. Reenable them. Reviewed by: dim Differential Revision: https://reviews.freebsd.org/D44877 (cherry picked from commit 0b9e3585805e83718c3ebdab923aca51597193cd) --- lib/libgcc_eh/Makefile.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/libgcc_eh/Makefile.inc b/lib/libgcc_eh/Makefile.inc index 4b93c139522a..9832b1a8c4e5 100644 --- a/lib/libgcc_eh/Makefile.inc +++ b/lib/libgcc_eh/Makefile.inc @@ -17,6 +17,9 @@ SRCS_EXC+= UnwindRegistersSave.S SRCS_EXC+= libunwind.cpp SRCS+= ${SRCS_EXC} +.if ${MACHINE} == "amd64" || ${MACHINE} == "i386" || ${MACHINE} == "powerpc" +CFLAGS.UnwindLevel1-gcc-ext.c+= -D_LIBUNWIND_SUPPORT_FRAME_APIS +.endif .for file in ${SRCS_EXC:M*.c} CFLAGS.${file}+= -fno-exceptions -funwind-tables .endfor From nobody Sat Apr 20 10:35:01 2024 X-Original-To: dev-commits-src-branches@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 4VM7F150RBz5HWdb; Sat, 20 Apr 2024 10:35:01 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7F12lm8z4TWm; Sat, 20 Apr 2024 10:35:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609301; 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=96eq9JCnuVY7/qs9bcAdhCUgmSTmJbHZ63m6s+FCCwo=; b=Y45b7ENYbJr78Eg97bANbsEbr5rrUyoV/nNv7eha2usIiKpBrqYJ9zEQqE+VSGqkh9ZIjL VrtIExXG+yVzPn5MjSAqX6/BfMKYLB9XQA/NdCukjHUZepdFHFQBuOBl9KhNpUxUm4gYYz AX7vntOyzpioEE8KITziOsFaQXwVWTRE/qMNp8HKsy5J7IvSCtuoVyFBzeRcrudWLzUHRg 4HVvDlTQAGoG0asXF2TpWPbnGbmfI6SLNWH9E2Ef7zu5IwqxPZD/7lA6AYGulskAobpDW5 yPEUjnPj1Hb+kymu2/cClgFk9V0x7iaHUmkKW7pByLHXuuEGmDDdtBIVzdE/6w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609301; a=rsa-sha256; cv=none; b=ZISWLcmYuZ/dT7seo6YlGYIu/F7ALy/GNM5+IF+Qf7ln0Ymuospy/QRNzARGnBPom/F1AB i2HyBxnDDqKRg2c1bLC+EBPhisU7VFS0+buvRqpUSgKD+PdudTmCja/kyTPkQVNt67ho1L /civ+HoZ4aZV31AHvT0APYv/lkgo4nfNGlL6oZKE9V1AmOHhmVtTgG03IODZWjMdk+5wsv HLL4Qmpext+jpPGucMWZjWRw9sMlCqvgCzELHHrenBZN4+P7pCEzwk09PNlPGnI0GFqqYq XWN3JlVzeG6UapfidivWzXVZ3lCDNyqhPDIbSk+p69YOSoC5wHNUX+cZC+79aQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609301; 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=96eq9JCnuVY7/qs9bcAdhCUgmSTmJbHZ63m6s+FCCwo=; b=n33GNwIOoVFbkR93RTg7TQDBmx43Ja9muM9UF7OAgPf0Q1saMgccLgIkLYJvQzSCcQ3I+i /FRdGAz+USXyHDbtPFDzAbzHQxQJebNRD//RxxS8fC69X7DGfZT4K72z0W0a71o9HPo/A1 EnpRKabLirL0DMvAm1fm5EfM3VqAmZOMlPL2dveaysU9seLB+lvRo+X9QW8OVo9N+1dzip W/JfqKVKfTgCueniVT4jX7bk+NKsKobAyJllPVUWaOsfFar1WC/AJWhk3fdn+BBPTzfj6Y gaE3FDRESWd08GrGh2D1s7Jc+vaQB3HpwaMRduvpBLlqW3PfWeGb9yGnYiZ56Q== 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 4VM7F12MwlzZ5w; Sat, 20 Apr 2024 10:35:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAZ1D7014938; Sat, 20 Apr 2024 10:35:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAZ1d0014935; Sat, 20 Apr 2024 10:35:01 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:35:01 GMT Message-Id: <202404201035.43KAZ1d0014935@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: 667a595fee5e - stable/13 - tau32-ddk.c: suppress warning about ignored attributes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 667a595fee5ef5663752d585c980d72aeeb7792b Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=667a595fee5ef5663752d585c980d72aeeb7792b commit 667a595fee5ef5663752d585c980d72aeeb7792b Author: Dimitry Andric AuthorDate: 2024-04-20 10:28:47 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 tau32-ddk.c: suppress warning about ignored attributes This driver is heavily obfuscated, and causes a -Werror warning with clang 18 now: sys/dev/ce/tau32-ddk.c:358:10: error: 'const' attribute on function returning 'void'; attribute ignored [-Werror,-Wignored-attributes] 358 | ((const))nvqbt(void){__asm __volatile("repe; nop; repe; nop;" | ^ Supress the warning since the driver can never be fixed. Direct commit to stable/13, since the driver has been removed in 14.x and later. PR: 276104 --- sys/conf/files.i386 | 2 +- sys/modules/ce/Makefile | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/files.i386 b/sys/conf/files.i386 index e2031ef2b200..04cbd47333ef 100644 --- a/sys/conf/files.i386 +++ b/sys/conf/files.i386 @@ -44,7 +44,7 @@ dev/agp/agp_via.c optional agp dev/ce/ceddk.c optional ce dev/ce/if_ce.c optional ce dev/ce/tau32-ddk.c optional ce \ - compile-with "${NORMAL_C} ${NO_WCONSTANT_CONVERSION} ${NO_WMISLEADING_INDENTATION}" + compile-with "${NORMAL_C} ${NO_WCONSTANT_CONVERSION} ${NO_WMISLEADING_INDENTATION} -Wno-ignored-attributes" dev/cp/cpddk.c optional cp \ compile-with "${NORMAL_C} ${NO_WMISLEADING_INDENTATION}" dev/cp/if_cp.c optional cp diff --git a/sys/modules/ce/Makefile b/sys/modules/ce/Makefile index cec4c21b2101..3e5c28ce2fb7 100644 --- a/sys/modules/ce/Makefile +++ b/sys/modules/ce/Makefile @@ -28,3 +28,4 @@ opt_ng_cronyx.h: CWARNFLAGS.tau32-ddk.c+= ${NO_WCONSTANT_CONVERSION} CWARNFLAGS.tau32-ddk.c+= ${NO_WMISLEADING_INDENTATION} +CWARNFLAGS.tau32-ddk.c+= -Wno-ignored-attributes From nobody Sat Apr 20 10:35:02 2024 X-Original-To: dev-commits-src-branches@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 4VM7F26xlgz5HWbY; Sat, 20 Apr 2024 10:35:02 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VM7F23djSz4Tfd; Sat, 20 Apr 2024 10:35:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609302; 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=oPnhAS/AYB+lr3J2PgCgTapMgULX52iqXWKrGxGufY8=; b=XPw/VXoq7QdnSl7taQJqixsV4DUk0FAMp+Zfhcg4U2kNkN6dWwrkepfI1HBEeGA6U9FkP/ C/93EytRyYsH/Sz7hkPh82wpagSjFFxQJNmC0P2W02OfHjUPvd+P0Ltbe3WS5f0w9XHiK5 DEE6s2H6mOuEpqpDReIorfSwTwNoO59Sc2rRQ5uYB9Yc/4n1UvJHWpiCm0g+qa5P9M2dYw 0f5gVLt36JMsTrT5GG2L7btq/5BLam71A0DxkHH14eim6AD9bihVY6xwn+AP/ehnU40Xk6 kI16jrkIX/u99bIRUp+wn4l2VjnjolA2tQLZuIky2qn/6pDez8LlAIxEZoUYZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713609302; a=rsa-sha256; cv=none; b=xqB6/lB/MtkSDWHuZxaHeq6uUPNQwy2gdU0xhBvgEHQmZz6gcXEpP3NSskG6Hq68+oNfmC ShHifHF0sr+Orv3/LUCFwkqMWN7yqNuSZ28qaAD7c6Hx+WRblPGMMm5FNJBtq8LWRxvbLe TrytM+il2JH6Jkh6fWs2zktjl+Lw0jioZzfrcPYSHJUpE8MdzbWeWqL52F/ZSZCIOaCFqo +v2+oGhYoYbmjDKFAhkgAO1eDSz2yHTbCuSivfR+Ln2exVBKBAt74bZ5Wi4dtI/TLQQjlE V28IuLOHx+zf5rfHzLMzv9tWDY/WMkFF6A/QG4EymYaPHyOZrPKYTeQwjvowOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713609302; 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=oPnhAS/AYB+lr3J2PgCgTapMgULX52iqXWKrGxGufY8=; b=qG+p9gg+zS9VMaioP89dhAWugxOWfr6yzWpM30tUJGaA8c4lXnULljiMxMoc+NlK3ziRhL SUAEgFGFVVNT3gwTGz/budjfqX4GFYTqZ7pF0IcQkPqmjcVwCFKFDEUj+GysBU4tTife4g /EZnVmeUS6eW+nfcwNbW/SUVPDlqDybrYg7awCHWUkZfwlqXr/v3RQhpHNWe4mzbK2qfXj JPlFPsxm2CsH4q+8Cj+8/liPzzZmEC96TCKeirguRpHn8x3nUNT6E0DxDYMY0czRHb+PBH dNiEOI0IXVoTqFLmxsW5CaZmhe6FAxp2r/uYOLsGGLwGUdtIIX1G00G0tjPeig== 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 4VM7F23GCGzYnH; Sat, 20 Apr 2024 10:35:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KAZ2wQ014986; Sat, 20 Apr 2024 10:35:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KAZ2ga014983; Sat, 20 Apr 2024 10:35:02 GMT (envelope-from git) Date: Sat, 20 Apr 2024 10:35:02 GMT Message-Id: <202404201035.43KAZ2ga014983@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: 055e875e6077 - stable/13 - Bump __FreeBSD_version for llvm 18.1.3 merge List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 055e875e6077ed1eb2256c3ab5de59a3f6fbce18 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=055e875e6077ed1eb2256c3ab5de59a3f6fbce18 commit 055e875e6077ed1eb2256c3ab5de59a3f6fbce18 Author: Dimitry Andric AuthorDate: 2024-04-06 20:15:21 +0000 Commit: Dimitry Andric CommitDate: 2024-04-20 10:29:10 +0000 Bump __FreeBSD_version for llvm 18.1.3 merge PR: 276104 MFC after: 1 month (cherry picked from commit 0192eda105b367d4670205547e8e830e3716bea3) --- sys/sys/param.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/param.h b/sys/sys/param.h index 3065513a8f24..155f04070ff1 100644 --- a/sys/sys/param.h +++ b/sys/sys/param.h @@ -59,7 +59,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 1303502 /* Master, propagated to newvers */ +#define __FreeBSD_version 1303503 /* Master, propagated to newvers */ /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From nobody Sat Apr 20 13:53:39 2024 X-Original-To: dev-commits-src-branches@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 4VMCfD1hXsz5HpV6; Sat, 20 Apr 2024 13:53:40 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMCfD0hfhz4Q5Q; Sat, 20 Apr 2024 13:53:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713621220; 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=M9yYl2hDuqzOLiZG+6A5/oZIX2byPg58DLslT9N/Puk=; b=GfHwyf0e3fFweoSPgoR4kZ4Pr1bnnoa36nhTtpDO5g8+n/C6jzniLJrwyG6UzTTZ6hWUcX 74yPEix2/7CIJJfiEHJwpJNdpjPi1aqMLRWx79SxixfvRJQs92WIxSqfKKXlDssN5xKBiX osyE5qAr2kiiP+WunPVY4EZTnsaXIiR8eWafIcTVvBB/iFsxp0RJFE40/uQkh+iJpKj9hp WKKu8Y33wb1z82f12TG4LrSp7QI9KKI6aBGboZkqs4QuDyKkb400O2Tjf1ErTS5aSR9RAe 43Gdg05HsRyeYauoQ1VcsdYB9IyBH5PJj2V4VayenhiQWgtIhtc7ROK5Pb3P+w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713621220; a=rsa-sha256; cv=none; b=C2mppi+1Q7Mw/NVp012sAMLPYjNh3Uf3VPRI786jvuJHo59O6vEtnvHfDPXYaV+WDY4Qq0 euGxtjzjHC9LGjucaLO47WGujIVvwY1Mz85jXqwYad3xQ7sR4yv54jJJIYWB34tqJTzMyx e9FsFh48aXg0FevMTT/c3uV8brkXBMwANM0Ab62Kp1PkoUIOWqf3dQrJtaaH5TgwVnkIdS GEL5qdZlD9BAuXu9x2ZrM6bqpOyjRmjOB5UMGSx4AOIc5NLA6PRlOVdRU8Bl5zAICsd32p 2Okk0nFSk0LDXcaId1tITm/QOzy3bGNmcX/IPFNlaj6+cyU1ACgLDGVOTajlng== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713621220; 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=M9yYl2hDuqzOLiZG+6A5/oZIX2byPg58DLslT9N/Puk=; b=f3BRm7RejIrKB7VsIp/uzRUYpvcbKmvh5Ckiw4hmVpvEBXH4oJFYxx1FZK+Gkbefg78/Mj DafGYto+zYFHaOKefaU/8Sxvl4BcX3SXd6m3neLRRgfauXsxHizsoUUsTekVLkn66Qv21+ G4Rl20fAI1cCxrci7tdatoEB/hL3iQ4DWXf7yXnGXTSRXHZ48wm6JXkTBLdQklyQ8sGp1t SUZaXmmRgcGMKnNpPapFjAcwStoVH60ZKeKcCHTsuu8Dwy40czjh4txzT5nQu6Cpx2a38Q tesqZI9+cKE5Ct+jz+eHUcRf7saxJuHAO6rNNQZ5wYF2bBMDKbABMI8Iucv61g== 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 4VMCfD0HtNzg8y; Sat, 20 Apr 2024 13:53:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43KDrdW4053622; Sat, 20 Apr 2024 13:53:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43KDrdjk053619; Sat, 20 Apr 2024 13:53:39 GMT (envelope-from git) Date: Sat, 20 Apr 2024 13:53:39 GMT Message-Id: <202404201353.43KDrdjk053619@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 0b56acfc498e - stable/14 - rtld: introduce STATIC_TLS_EXTRA List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0b56acfc498ed2cc325f6b8debfc7fdc3b03d676 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=0b56acfc498ed2cc325f6b8debfc7fdc3b03d676 commit 0b56acfc498ed2cc325f6b8debfc7fdc3b03d676 Author: Stephen J. Kiernan AuthorDate: 2023-10-29 21:13:10 +0000 Commit: Konstantin Belousov CommitDate: 2024-04-20 13:52:16 +0000 rtld: introduce STATIC_TLS_EXTRA (cherry picked from commit 95335dd3c19e0ade161bb4dc8462fc3d045ce4f8) --- libexec/rtld-elf/aarch64/reloc.c | 2 +- libexec/rtld-elf/amd64/reloc.c | 2 +- libexec/rtld-elf/arm/reloc.c | 3 ++- libexec/rtld-elf/i386/reloc.c | 2 +- libexec/rtld-elf/powerpc/reloc.c | 3 ++- libexec/rtld-elf/powerpc64/reloc.c | 3 ++- libexec/rtld-elf/riscv/reloc.c | 2 +- libexec/rtld-elf/rtld.1 | 8 +++++++- libexec/rtld-elf/rtld.c | 21 +++++++++++++++++---- libexec/rtld-elf/rtld.h | 1 + 10 files changed, 35 insertions(+), 12 deletions(-) diff --git a/libexec/rtld-elf/aarch64/reloc.c b/libexec/rtld-elf/aarch64/reloc.c index c8f09d797215..907377f2619a 100644 --- a/libexec/rtld-elf/aarch64/reloc.c +++ b/libexec/rtld-elf/aarch64/reloc.c @@ -521,7 +521,7 @@ allocate_initial_tls(Obj_Entry *objs) * use. */ tls_static_space = tls_last_offset + tls_last_size + - RTLD_STATIC_TLS_EXTRA; + ld_static_tls_extra; _tcb_set(allocate_tls(objs, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN)); } diff --git a/libexec/rtld-elf/amd64/reloc.c b/libexec/rtld-elf/amd64/reloc.c index ce74c54cc5c3..9c5887def356 100644 --- a/libexec/rtld-elf/amd64/reloc.c +++ b/libexec/rtld-elf/amd64/reloc.c @@ -527,7 +527,7 @@ allocate_initial_tls(Obj_Entry *objs) * offset allocated so far and adding a bit for dynamic * modules to use. */ - tls_static_space = tls_last_offset + RTLD_STATIC_TLS_EXTRA; + tls_static_space = tls_last_offset + ld_static_tls_extra; addr = allocate_tls(objs, 0, TLS_TCB_SIZE, TLS_TCB_ALIGN); diff --git a/libexec/rtld-elf/arm/reloc.c b/libexec/rtld-elf/arm/reloc.c index b2fb3fdad2c7..c3e95940be74 100644 --- a/libexec/rtld-elf/arm/reloc.c +++ b/libexec/rtld-elf/arm/reloc.c @@ -454,7 +454,8 @@ allocate_initial_tls(Obj_Entry *objs) * use. */ - tls_static_space = tls_last_offset + tls_last_size + RTLD_STATIC_TLS_EXTRA; + tls_static_space = tls_last_offset + tls_last_size + + ld_static_tls_extra; _tcb_set(allocate_tls(objs, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN)); } diff --git a/libexec/rtld-elf/i386/reloc.c b/libexec/rtld-elf/i386/reloc.c index 8e8966926839..04a8354343bc 100644 --- a/libexec/rtld-elf/i386/reloc.c +++ b/libexec/rtld-elf/i386/reloc.c @@ -510,7 +510,7 @@ allocate_initial_tls(Obj_Entry *objs) * offset allocated so far and adding a bit for dynamic modules to * use. */ - tls_static_space = tls_last_offset + RTLD_STATIC_TLS_EXTRA; + tls_static_space = tls_last_offset + ld_static_tls_extra; tls = allocate_tls(objs, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN); _tcb_set(tls); } diff --git a/libexec/rtld-elf/powerpc/reloc.c b/libexec/rtld-elf/powerpc/reloc.c index 8254f21a3ce6..73a1c89991e2 100644 --- a/libexec/rtld-elf/powerpc/reloc.c +++ b/libexec/rtld-elf/powerpc/reloc.c @@ -817,7 +817,8 @@ allocate_initial_tls(Obj_Entry *list) * use. */ - tls_static_space = tls_last_offset + tls_last_size + RTLD_STATIC_TLS_EXTRA; + tls_static_space = tls_last_offset + tls_last_size + + ld_static_tls_extra; _tcb_set(allocate_tls(list, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN)); } diff --git a/libexec/rtld-elf/powerpc64/reloc.c b/libexec/rtld-elf/powerpc64/reloc.c index 5bfb05116315..70928829aeda 100644 --- a/libexec/rtld-elf/powerpc64/reloc.c +++ b/libexec/rtld-elf/powerpc64/reloc.c @@ -714,7 +714,8 @@ allocate_initial_tls(Obj_Entry *list) * use. */ - tls_static_space = tls_last_offset + tls_last_size + RTLD_STATIC_TLS_EXTRA; + tls_static_space = tls_last_offset + tls_last_size + + ld_static_tls_extra; _tcb_set(allocate_tls(list, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN)); } diff --git a/libexec/rtld-elf/riscv/reloc.c b/libexec/rtld-elf/riscv/reloc.c index 5ed516bc4337..d806e1ec3d63 100644 --- a/libexec/rtld-elf/riscv/reloc.c +++ b/libexec/rtld-elf/riscv/reloc.c @@ -392,7 +392,7 @@ allocate_initial_tls(Obj_Entry *objs) * use. */ tls_static_space = tls_last_offset + tls_last_size + - RTLD_STATIC_TLS_EXTRA; + ld_static_tls_extra; _tcb_set(allocate_tls(objs, NULL, TLS_TCB_SIZE, TLS_TCB_ALIGN)); } diff --git a/libexec/rtld-elf/rtld.1 b/libexec/rtld-elf/rtld.1 index 807ecb31ad7c..4d97159b0aaf 100644 --- a/libexec/rtld-elf/rtld.1 +++ b/libexec/rtld-elf/rtld.1 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd November 10, 2022 +.Dd October 29, 2023 .Dt RTLD 1 .Os .Sh NAME @@ -320,6 +320,12 @@ If set, causes .Nm to dump content of the aux vector to standard output, before passing control to any user code. +.It Ev LD_STATIC_TLS_EXTRA +If the variable is specified and has a numeric value, +.Nm +will set the size of the static TLS extra space to the specified number +of bytes. The static TLS extra space is used when loading objects with +dlopen. The minimum value that can be specified is \'128\'. .El .Sh DIRECT EXECUTION MODE .Nm diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index 07068dff0b62..d5e702652058 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -225,6 +225,8 @@ static Obj_Entry *obj_main; /* The main program shared object */ static Obj_Entry obj_rtld; /* The dynamic linker shared object */ static unsigned int obj_count; /* Number of objects in obj_list */ static unsigned int obj_loads; /* Number of loads of objects (gen count) */ +size_t ld_static_tls_extra = /* Static TLS extra space (bytes) */ + RTLD_STATIC_TLS_EXTRA; static Objlist list_global = /* Objects dlopened with RTLD_GLOBAL */ STAILQ_HEAD_INITIALIZER(list_global); @@ -365,6 +367,7 @@ enum { LD_TRACE_LOADED_OBJECTS_FMT2, LD_TRACE_LOADED_OBJECTS_ALL, LD_SHOW_AUXV, + LD_STATIC_TLS_EXTRA, }; struct ld_env_var_desc { @@ -398,6 +401,7 @@ static struct ld_env_var_desc ld_env_vars[] = { LD_ENV_DESC(TRACE_LOADED_OBJECTS_FMT2, false), LD_ENV_DESC(TRACE_LOADED_OBJECTS_ALL, false), LD_ENV_DESC(SHOW_AUXV, false), + LD_ENV_DESC(STATIC_TLS_EXTRA, false), }; static const char * @@ -515,7 +519,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_proc, Obj_Entry **objp) struct stat st; Elf_Addr *argcp; char **argv, **env, **envp, *kexecpath; - const char *argv0, *binpath, *library_path_rpath; + const char *argv0, *binpath, *library_path_rpath, *static_tls_extra; struct ld_env_var_desc *lvd; caddr_t imgentry; char buf[MAXPATHLEN]; @@ -738,9 +742,16 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_proc, Obj_Entry **objp) else ld_library_path_rpath = false; } + static_tls_extra = ld_get_env_var(LD_STATIC_TLS_EXTRA); + if (static_tls_extra != NULL && static_tls_extra[0] != '\0') { + sz = parse_integer(static_tls_extra); + if (sz >= RTLD_STATIC_TLS_EXTRA && sz <= SIZE_T_MAX) + ld_static_tls_extra = sz; + } dangerous_ld_env = libmap_disable || libmap_override != NULL || ld_library_path != NULL || ld_preload != NULL || - ld_elf_hints_path != NULL || ld_loadfltr || !ld_dynamic_weak; + ld_elf_hints_path != NULL || ld_loadfltr || !ld_dynamic_weak || + static_tls_extra != NULL; ld_tracing = ld_get_env_var(LD_TRACE_LOADED_OBJECTS); ld_utrace = ld_get_env_var(LD_UTRACE); @@ -6165,13 +6176,15 @@ parse_args(char* argv[], int argc, bool *use_pathp, int *fdp, "Env prefix %s\n" "Default hint file %s\n" "Hint file %s\n" - "libmap file %s\n", + "libmap file %s\n" + "Optional static TLS size %zd bytes\n", machine, __FreeBSD_version, ld_standard_library_path, gethints(false), ld_env_prefix, ld_elf_hints_default, ld_elf_hints_path, - ld_path_libmap_conf); + ld_path_libmap_conf, + ld_static_tls_extra); _exit(0); } else { _rtld_error("Invalid argument: '%s'", arg); diff --git a/libexec/rtld-elf/rtld.h b/libexec/rtld-elf/rtld.h index c9e0d4ab0525..6311b3e6cc7f 100644 --- a/libexec/rtld-elf/rtld.h +++ b/libexec/rtld-elf/rtld.h @@ -50,6 +50,7 @@ extern size_t tls_last_size; extern size_t tls_static_space; extern Elf_Addr tls_dtv_generation; extern int tls_max_index; +extern size_t ld_static_tls_extra; extern int npagesizes; extern size_t *pagesizes; From nobody Sun Apr 21 03:16:07 2024 X-Original-To: dev-commits-src-branches@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 4VMYS7423Rz5HHrt; Sun, 21 Apr 2024 03:16:07 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMYS739SBz4FMq; Sun, 21 Apr 2024 03:16:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713669367; 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=FEKf4wD0eVTzVGApCU92ZS3i2pNMD23RCKM+gurI+qk=; b=H1C1jP9ppE/uKRbKHX2iMxDP1uKHy1eWRUXcaLjBJbMmG7NdfUqsXo4YuJkfVTrxpb+Y/J I048nmmfEv2MAqHetsBfErprmneSL5AuCmz6QdTPBS9daEDHQgavqg9B6MI/a1rcboJGTr AZyUCERvQP9+3j8But6ALQHXQOmwRqtIlspHgxS30jgr31foHJZmxY5AhtgLqmPXFD/1PJ HH+QQceUPT19LGx0bu8Y38JqOL5Sz5eaQx7LMZEqkjRR8gDm7wj7Wd0Tq7eFMf8GwWGnfG AyLAa2w8PTL1ccKL2mtNTF6uTQt1EExBJv1+F2cI1AZy/vGLnzPH/x9WUMgrqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713669367; a=rsa-sha256; cv=none; b=Hzniy+143QZuEaEPofxJBmErVbZtiCLeaw+5ILMXD6BLEqfMCOF7Kz3VnoFjc5+iZg6Wuc K1cUBAPPYj14Yxoma7KZGkO+g1lgHOBDLojTDhouId0NXWXJDjQC9yAwZCIt1wTGHbFKVE ZwhQ8Lpe5I9LbepTozw04kzgvsToi9Ncc3DAO0LWop0b5LEpPDcTWJJCem4BEyV0emOBjo dwj5EL+Vgw5XRi42ZfSzV8hojyKBuUER6egNjckvklkdBi+4H9oDG8qYKFLIpCSZ5SnpUP h+cyDfiy7zed0/VaRc+ZbmlC1LdxJzk7H20LwxwYhIbLo4KGTbrqcep4DPA7/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713669367; 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=FEKf4wD0eVTzVGApCU92ZS3i2pNMD23RCKM+gurI+qk=; b=bndiDrv0EorpAC12R/WpFwEbGjY5Ut3/G62SujU9EKyElWfoDr+4FsEy3+4wfulRxyEVct 3lbvv8+FX594tzmluYPrIb6JcOl/swsJG0MWX7Cb0v9dHu3pZlxc0ySrpOUR4bS7CC/gXO OFNpwAsjp5eiPZ3I8fdY7bCfn2ghawuti4JfsC9loxMkQmKZDsr36H2QSkEAGNrbX94Rj1 fm32PERxyt2IemjXYqyRwICp8++qngoOQHsuw+3lHdVWZw4dx260xHJyOCh0AEdkkkffkv FOLE6oNQWc89kn4r9xBUPoPIr8AzFrXVZ1U6zYrsr816mWdYROBAOzZutSXwfA== 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 4VMYS72mwlz13sk; Sun, 21 Apr 2024 03:16:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L3G7kI016042; Sun, 21 Apr 2024 03:16:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L3G74S016039; Sun, 21 Apr 2024 03:16:07 GMT (envelope-from git) Date: Sun, 21 Apr 2024 03:16:07 GMT Message-Id: <202404210316.43L3G74S016039@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Xin LI Subject: git: e4d8fe76c5d4 - stable/14 - amdsmn(4), amdtemp(4): add support for AMD Family 19h Models 10h-1Fh. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: delphij X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e4d8fe76c5d4833d2ba5b889b8af3e0d2907a531 Auto-Submitted: auto-generated The branch stable/14 has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=e4d8fe76c5d4833d2ba5b889b8af3e0d2907a531 commit e4d8fe76c5d4833d2ba5b889b8af3e0d2907a531 Author: Xin LI AuthorDate: 2024-04-14 07:45:17 +0000 Commit: Xin LI CommitDate: 2024-04-21 03:15:52 +0000 amdsmn(4), amdtemp(4): add support for AMD Family 19h Models 10h-1Fh. Tested on AMD Threadripper 7960X. PR: kern/278311 Tested by: jbo (cherry picked from commit 51c69c8682e8ab0e5d82ab3d6f2d16419d40bad4) --- sys/dev/amdsmn/amdsmn.c | 7 +++++++ sys/dev/amdtemp/amdtemp.c | 14 +++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/sys/dev/amdsmn/amdsmn.c b/sys/dev/amdsmn/amdsmn.c index bf2222bed5e3..36e3c5a5cae7 100644 --- a/sys/dev/amdsmn/amdsmn.c +++ b/sys/dev/amdsmn/amdsmn.c @@ -59,6 +59,7 @@ #define PCI_DEVICE_ID_AMD_17H_M10H_ROOT 0x15d0 #define PCI_DEVICE_ID_AMD_17H_M30H_ROOT 0x1480 /* Also M70H, F19H M00H/M20H */ #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 +#define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 #define PCI_DEVICE_ID_AMD_19H_M60H_ROOT 0x14d8 struct pciid; @@ -103,6 +104,12 @@ static const struct pciid { .amdsmn_addr_reg = F17H_SMN_ADDR_REG, .amdsmn_data_reg = F17H_SMN_DATA_REG, }, + { + .amdsmn_vendorid = CPU_VENDOR_AMD, + .amdsmn_deviceid = PCI_DEVICE_ID_AMD_19H_M10H_ROOT, + .amdsmn_addr_reg = F17H_SMN_ADDR_REG, + .amdsmn_data_reg = F17H_SMN_DATA_REG, + }, { .amdsmn_vendorid = CPU_VENDOR_AMD, .amdsmn_deviceid = PCI_DEVICE_ID_AMD_19H_M60H_ROOT, diff --git a/sys/dev/amdtemp/amdtemp.c b/sys/dev/amdtemp/amdtemp.c index b01ebe101c6b..73a4ba86bb84 100644 --- a/sys/dev/amdtemp/amdtemp.c +++ b/sys/dev/amdtemp/amdtemp.c @@ -70,7 +70,11 @@ typedef enum { CCD6, CCD7, CCD8, - CCD_MAX = CCD8, + CCD9, + CCD10, + CCD11, + CCD12, + CCD_MAX = CCD12, NUM_CCDS = CCD_MAX - CCD_BASE + 1, } amdsensor_t; @@ -110,6 +114,7 @@ struct amdtemp_softc { #define DEVICEID_AMD_HOSTB17H_M10H_ROOT 0x15d0 #define DEVICEID_AMD_HOSTB17H_M30H_ROOT 0x1480 /* Also M70H, F19H M00H/M20H */ #define DEVICEID_AMD_HOSTB17H_M60H_ROOT 0x1630 +#define DEVICEID_AMD_HOSTB19H_M10H_ROOT 0x14a4 #define DEVICEID_AMD_HOSTB19H_M60H_ROOT 0x14d8 static const struct amdtemp_product { @@ -135,6 +140,7 @@ static const struct amdtemp_product { { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M10H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M30H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M60H_ROOT, false }, + { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M10H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M60H_ROOT, false }, }; @@ -181,6 +187,7 @@ static const struct amdtemp_product { #define AMDTEMP_17H_CCD_TMP_BASE 0x59954 #define AMDTEMP_17H_CCD_TMP_VALID (1u << 11) +#define AMDTEMP_ZEN4_10H_CCD_TMP_BASE 0x59b00 #define AMDTEMP_ZEN4_CCD_TMP_BASE 0x59b08 /* @@ -861,6 +868,11 @@ amdtemp_probe_ccd_sensors19h(device_t dev, uint32_t model) maxreg = 8; _Static_assert((int)NUM_CCDS >= 8, ""); break; + case 0x10 ... 0x1f: + sc->sc_temp_base = AMDTEMP_ZEN4_10H_CCD_TMP_BASE; + maxreg = 12; + _Static_assert((int)NUM_CCDS >= 12, ""); + break; case 0x60 ... 0x6f: /* Zen4 Ryzen "Raphael" */ sc->sc_temp_base = AMDTEMP_ZEN4_CCD_TMP_BASE; maxreg = 8; From nobody Sun Apr 21 03:19:19 2024 X-Original-To: dev-commits-src-branches@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 4VMYWq4Gm7z5HHs6; Sun, 21 Apr 2024 03:19:19 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMYWq3jzLz4FnQ; Sun, 21 Apr 2024 03:19:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713669559; 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=ehZ3Ti7dLa9OEAvtgqIy4mLwGBvoo1hFyxn9pHVWQ/w=; b=LkoJ3qWEF1THQ2ydcVPrUgbf47zwBnvAwtahbk/aZ9jCP3aN78q7vN2tT5uKH6jWkNT1RV lRSlW+rF1DkS/0qGUTNB0MWh3W2gq9w4bEyg+XEf5JiuZ7CprH61BCl8VUUpI5Eqf1tfF/ UvOzao3293D9Sp4jiCYBmfFCAl+W8fYag12z68PRFp+hMtvw5YrjGT1Y6IkMhBLXKbQivO 4ilXTFaUKstRbp+QeA24dh7TQp4RypBIRuJnBo39hi3rWN6xJldfx6LC5lJa04Uno1UhtW /MaVh+2iQVbOHH32OuT92MG1BxzbdhgeoYpC9e3l5f2p0zMnvZpbipfEZiEbUQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713669559; a=rsa-sha256; cv=none; b=pg+2ZXK10SbTaUO82gfSlqs4Dg97/MkVpCoQ68tb8lSeRTg0Kcs6JG9xxTbBo8+6QPf2LL r0VeH7mZNVqaw/J5lMc4jcAl9f61FDMoIY/Ow1i2r6CfUqFvoJfyiMWQNAsR3AhW/IseqD reOJ7aI2+rg4JKhrfRXBNaiZ9LXWupJyEjPyJNL6hR6ayiXBhSPefMo8liYtIOiLLuXdyV tPcrBSUdc09kRoO0qBmrcrbg+UMi+hNcJr/iLGvLr/dWmJDBnsovl9Dql7A/dvlU7hodmq fJS1YFZKlvI+tBxSnwoeEK5TIswbfymAkVxiz7ooPX7vD13uDRomBaWbuvVJ6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713669559; 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=ehZ3Ti7dLa9OEAvtgqIy4mLwGBvoo1hFyxn9pHVWQ/w=; b=fJq8sgZNt9WdsEXBR67P1mHIghhIJZ+1YcFqI/tIiot1tWdkFBSDpig5nXlO5eNUqcunvJ /JxL0wDOebvNp4/Mfwy1aiVyRThypCPhWG+wVH52DyTeIUOdJ5kAgiGROBGz35CZPp1JW+ FCPvrR91BfpU6YTAYifEHlBQ540rE8b/wK8sPAC8zNv3QXjEtED9zBvPo2G+1w/TY/Zf4C gkWZXLURXzfmPjq/LHM4rc/DRBesO8pzjbbulH0AG2dqWHIrCeLOXib8NTdi24Sl/fJIMt 7jEj6UiG3oojUbKDxIvlBV33nzenXWURsK93lSxvnDDAbf3pXEp/ZQ5Z1PdI0Q== 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 4VMYWq31rgz13dl; Sun, 21 Apr 2024 03:19:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L3JJof016616; Sun, 21 Apr 2024 03:19:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L3JJpn016612; Sun, 21 Apr 2024 03:19:19 GMT (envelope-from git) Date: Sun, 21 Apr 2024 03:19:19 GMT Message-Id: <202404210319.43L3JJpn016612@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Xin LI Subject: git: c5179c2b8a5e - stable/13 - amdsmn(4), amdtemp(4): add support for AMD Family 19h Models 10h-1Fh. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: delphij X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c5179c2b8a5e5b826f6626634b9b53dd257d6499 Auto-Submitted: auto-generated The branch stable/13 has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=c5179c2b8a5e5b826f6626634b9b53dd257d6499 commit c5179c2b8a5e5b826f6626634b9b53dd257d6499 Author: Xin LI AuthorDate: 2024-04-14 07:45:17 +0000 Commit: Xin LI CommitDate: 2024-04-21 03:19:01 +0000 amdsmn(4), amdtemp(4): add support for AMD Family 19h Models 10h-1Fh. Tested on AMD Threadripper 7960X. PR: kern/278311 Tested by: jbo (cherry picked from commit 51c69c8682e8ab0e5d82ab3d6f2d16419d40bad4) --- sys/dev/amdsmn/amdsmn.c | 7 +++++++ sys/dev/amdtemp/amdtemp.c | 14 +++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/sys/dev/amdsmn/amdsmn.c b/sys/dev/amdsmn/amdsmn.c index 7737a3c3fa4c..decb2c1249ed 100644 --- a/sys/dev/amdsmn/amdsmn.c +++ b/sys/dev/amdsmn/amdsmn.c @@ -59,6 +59,7 @@ #define PCI_DEVICE_ID_AMD_17H_M10H_ROOT 0x15d0 #define PCI_DEVICE_ID_AMD_17H_M30H_ROOT 0x1480 /* Also M70H, F19H M00H/M20H */ #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 +#define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 #define PCI_DEVICE_ID_AMD_19H_M60H_ROOT 0x14d8 struct pciid; @@ -103,6 +104,12 @@ static const struct pciid { .amdsmn_addr_reg = F17H_SMN_ADDR_REG, .amdsmn_data_reg = F17H_SMN_DATA_REG, }, + { + .amdsmn_vendorid = CPU_VENDOR_AMD, + .amdsmn_deviceid = PCI_DEVICE_ID_AMD_19H_M10H_ROOT, + .amdsmn_addr_reg = F17H_SMN_ADDR_REG, + .amdsmn_data_reg = F17H_SMN_DATA_REG, + }, { .amdsmn_vendorid = CPU_VENDOR_AMD, .amdsmn_deviceid = PCI_DEVICE_ID_AMD_19H_M60H_ROOT, diff --git a/sys/dev/amdtemp/amdtemp.c b/sys/dev/amdtemp/amdtemp.c index 2fdecead6c0f..b38f92131c77 100644 --- a/sys/dev/amdtemp/amdtemp.c +++ b/sys/dev/amdtemp/amdtemp.c @@ -70,7 +70,11 @@ typedef enum { CCD6, CCD7, CCD8, - CCD_MAX = CCD8, + CCD9, + CCD10, + CCD11, + CCD12, + CCD_MAX = CCD12, NUM_CCDS = CCD_MAX - CCD_BASE + 1, } amdsensor_t; @@ -110,6 +114,7 @@ struct amdtemp_softc { #define DEVICEID_AMD_HOSTB17H_M10H_ROOT 0x15d0 #define DEVICEID_AMD_HOSTB17H_M30H_ROOT 0x1480 /* Also M70H, F19H M00H/M20H */ #define DEVICEID_AMD_HOSTB17H_M60H_ROOT 0x1630 +#define DEVICEID_AMD_HOSTB19H_M10H_ROOT 0x14a4 #define DEVICEID_AMD_HOSTB19H_M60H_ROOT 0x14d8 static const struct amdtemp_product { @@ -135,6 +140,7 @@ static const struct amdtemp_product { { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M10H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M30H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M60H_ROOT, false }, + { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M10H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M60H_ROOT, false }, }; @@ -181,6 +187,7 @@ static const struct amdtemp_product { #define AMDTEMP_17H_CCD_TMP_BASE 0x59954 #define AMDTEMP_17H_CCD_TMP_VALID (1u << 11) +#define AMDTEMP_ZEN4_10H_CCD_TMP_BASE 0x59b00 #define AMDTEMP_ZEN4_CCD_TMP_BASE 0x59b08 /* @@ -862,6 +869,11 @@ amdtemp_probe_ccd_sensors19h(device_t dev, uint32_t model) maxreg = 8; _Static_assert((int)NUM_CCDS >= 8, ""); break; + case 0x10 ... 0x1f: + sc->sc_temp_base = AMDTEMP_ZEN4_10H_CCD_TMP_BASE; + maxreg = 12; + _Static_assert((int)NUM_CCDS >= 12, ""); + break; case 0x60 ... 0x6f: /* Zen4 Ryzen "Raphael" */ sc->sc_temp_base = AMDTEMP_ZEN4_CCD_TMP_BASE; maxreg = 8; From nobody Sun Apr 21 07:34:10 2024 X-Original-To: dev-commits-src-branches@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 4VMg9t31vZz5HhCv; Sun, 21 Apr 2024 07:34:10 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMg9t23jzz4b8J; Sun, 21 Apr 2024 07:34:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684850; 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=ZJNiHt5ruxBQMIMvPm++n/lzEZag8uC28zfFbhlRWjc=; b=haCKIKcy/lKqTuqmaqOCwFsthm2NcrrLQFqcqVaDcfjcLJHMF52T3jHjbEN5zTEqZjHcwZ 9dlfVfX4aZ8dfmhjjDMXdL6XHj8w3CMfkSEvY4QZSdnLfIysBBr2EzWTfpUBVIftnk8lKR 5H51+O4Wbma/ZlXpr9seEoG/5DvqkLM23Btzu4XHgcH/73mC+mUdOTcDEjfobtNhf/jP20 fTSrwyzeA8NUU7yTO/x0PngBkEo2atY0Csb/PI0DZ714rQu03sHfk+B8lOGuq82JCuNzQ6 Fk+uZNrKtwaucWDsKKZctXkaY9BdAt6OEoAbdwA+j7YS8+XfNB9MfoE5yxcKtA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684850; a=rsa-sha256; cv=none; b=YNk7W0ZX521NmsiWee1acBkMUEdhugAZmx1mnxYqLnpdjGpJs3GM2eYzndKwX/Tr4JNSiJ vRREDDZCv5dla2mn1AESUz3EYFnxfiIHUTl0Ih/m6CvgiLqWeNyh9/ru+kN58BsCWgI1I9 /zzmKr7DZrqlNluXknA/kpiPj3wDreLPbgFtlBvSKq79SKSEWKVBRoULs3ss3S5XXz3mfC w5dat4ob9LazHsMdBA9HIURgfe0sX5YUp5XfnceLd6ksFgyK7oTCBmw1wqu77X+ZYZjnQs BlJ9kHMIlvTuuVVfVs3KrILVIQW2DJu1ifBRBLLiGxLez1R2/APOcu3MrQPhyw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684850; 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=ZJNiHt5ruxBQMIMvPm++n/lzEZag8uC28zfFbhlRWjc=; b=i73tTBDfECslsL5D2cofsJUfo5vzK7wNk5nHkPH/wXyTJSJIByYoVTRdMgBSU0BP8XNSTi shSEIbbd+mb5Y/jiu8/I+aaByqWOKdK2EX1rakOh2w7ikqi5n64wu2+YI63MuXx+26cTCN Ja3vftExT+1RT89TfWJ/uNqwd9e849F2Ghx9FvHJL6+hijg5BjMb/h6EKBllKbJAVlVPYW tZhri1TBt4jtDsLpGOBSw/E0q8lnWWF1EZXAi+9tcOhfDSJj3bvqNSGHL6diu2+u6B5XJZ HJ2WbIEKOhTQ6eww9kM47QCy80ybRYYQq/oTKeK7sXV4hPA9u3owYRfcLQ+Q/Q== 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 4VMg9t1gmHz1BVn; Sun, 21 Apr 2024 07:34:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7YADk054413; Sun, 21 Apr 2024 07:34:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7YAJ5054410; Sun, 21 Apr 2024 07:34:10 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:34:10 GMT Message-Id: <202404210734.43L7YAJ5054410@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: bf2582cf15f5 - stable/14 - netpfil: Fix typos in source code comments List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bf2582cf15f5250b3cdf1ad405b0ff8ea9b83dd7 Auto-Submitted: auto-generated The branch stable/14 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=bf2582cf15f5250b3cdf1ad405b0ff8ea9b83dd7 commit bf2582cf15f5250b3cdf1ad405b0ff8ea9b83dd7 Author: Gordon Bergling AuthorDate: 2024-04-18 14:17:10 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:33:02 +0000 netpfil: Fix typos in source code comments - s/addres/address/ (cherry picked from commit 8ce3ef5f35fd4dc442b1a33605ca7d3132047faf) --- sys/netpfil/ipfilter/netinet/ip_fil.h | 4 ++-- sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c | 2 +- sys/netpfil/pf/pf.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netpfil/ipfilter/netinet/ip_fil.h b/sys/netpfil/ipfilter/netinet/ip_fil.h index 3db2b23512ef..7343fd079564 100644 --- a/sys/netpfil/ipfilter/netinet/ip_fil.h +++ b/sys/netpfil/ipfilter/netinet/ip_fil.h @@ -593,8 +593,8 @@ typedef struct fripf { u_short fri_icmp; frtuc_t fri_tuc; - fr_atypes_t fri_satype; /* addres type */ - fr_atypes_t fri_datype; /* addres type */ + fr_atypes_t fri_satype; /* address type */ + fr_atypes_t fri_datype; /* address type */ int fri_sifpidx; /* doing dynamic addressing */ int fri_difpidx; /* index into fr_ifps[] to use when */ } fripf_t; diff --git a/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c b/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c index 8f1ee3d8d05f..3bc74247251a 100644 --- a/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c +++ b/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c @@ -1834,7 +1834,7 @@ ipf_p_ftp_epsv(ipf_ftp_softc_t *softf, fr_info_t *fin, ip_t *ip, nat_t *nat, s++; /* - * As per RFC 2428, there are no addres components in the EPSV + * As per RFC 2428, there are no address components in the EPSV * response. So we'll go straight to getting the port. */ while (*s && ISDIGIT(*s)) { diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index b0b0a02afaf4..5fc234c5aca9 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -6154,7 +6154,7 @@ again: break; } - /* Only add the addres if we've actually allowed the state. */ + /* Only add the address if we've actually allowed the state. */ pf_sctp_multihome_add_addr(pd, &j->src, v_tag); if (! do_extra) { From nobody Sun Apr 21 07:34:11 2024 X-Original-To: dev-commits-src-branches@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 4VMg9v3f1sz5HhpZ; Sun, 21 Apr 2024 07:34:11 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMg9v2lr8z4b1V; Sun, 21 Apr 2024 07:34:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684851; 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=DK3xR3mdFZNQIIOb17PlqklwsX7548S5N2xmft6b1D4=; b=YInqm6GCxBihjDe7p4qCrs7/6fV40GyparfwJxDvyvHHInXtldDBHjUZ6VvsdGO1ZFdzhN Mf1FlQQjR7CzGrcOSLmKZdtRfFlE5HOAqk1GcZLcg+ZexxJWWeEvPkopfXZ7z/bC91J0UB fVMXq6ti95jsc9UDXc4Jk+DfmZxxPgZf4qMMZeYuAeUI46ovkkWkgkyJGEOu0LRE9Astvt Ub6ILrAx3pLAWndXDBysywofNcpMm3QXeqSgT/FzS0DnSdxP0X7lF0UM9ReKzCtZ2InaYV qXgWI6d3BjivzsbRZX4tGuh2H4zddYT+JFcRri7lgVGgEBPDPRq+sBMpV2F0rA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684851; a=rsa-sha256; cv=none; b=p8iy+wjAzOjTsait5FSmOkaORNBnXlyBPOGbbp6/aTIhjp6kaY5XiyIU70tl236rS91dBU M2VUcBsb9vu45IRdnQE9LxD0o+z+KBOqjPsyFAoPRmXyJdKztHGN3N0889RYfabq7LGr91 XmTShrXxIrrIj6fPzvaL1AnTpwbpa2Moboy98deVQW9Nt0R4xkPBOxjGfOs9JigF3HP7ni 8sDQcdN+bkYv96xUCnFkq3dYBRRM+uO3idEROmWJ1tyovDopyscspiavZWv7DNU2t8YjDr g7iahHN+F1ac9A9epgBQ3sgZvwnHSq2jWJCJE45r1ttU/cUFhMkT7L1MapRsAw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684851; 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=DK3xR3mdFZNQIIOb17PlqklwsX7548S5N2xmft6b1D4=; b=UhfR+nkoQjF68aquznTVfwblh9QHyqRnA3cZRDG5LzbHqgW2bd2FwdIvxBllw1VLSSaIjX nBQXKfvpsMxgLPu5um1P8mmQVcUOyilVjKWJXh0mNUCQOFPjyKI0uujzIM02OhHbGh1LfV 99P5HvuI488ywu1sn0fu8WbxAnn/Pmis63D05hAWkrJdcQtZOeDIklK3UxpVew4oOvblXh P3jQXyVQ15+kGGYOiBAMj7AnudAAlxBxu9UnQtY8eJAfJuXrA9062JpiulqXeC9UKCFXV/ uBnVXbdO0c9LC+qdcXnDJ/icJ1SZDHT96eeQYSY44p2tKdi/R/ug/ujGFk40FA== 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 4VMg9v2MJ4z1BXt; Sun, 21 Apr 2024 07:34:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7YB2X054467; Sun, 21 Apr 2024 07:34:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7YBTI054464; Sun, 21 Apr 2024 07:34:11 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:34:11 GMT Message-Id: <202404210734.43L7YBTI054464@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 04ab41437ae8 - stable/14 - muge(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 04ab41437ae8cb77bc1a3f5e8d6449d5f375848f Auto-Submitted: auto-generated The branch stable/14 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=04ab41437ae8cb77bc1a3f5e8d6449d5f375848f commit 04ab41437ae8cb77bc1a3f5e8d6449d5f375848f Author: Gordon Bergling AuthorDate: 2024-04-18 14:18:26 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:33:29 +0000 muge(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit 046fe202e76623988ac612b20047940b86dd373f) --- sys/dev/usb/net/if_muge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/usb/net/if_muge.c b/sys/dev/usb/net/if_muge.c index 0337d6ddbe18..dd4a89aa8b05 100644 --- a/sys/dev/usb/net/if_muge.c +++ b/sys/dev/usb/net/if_muge.c @@ -1811,7 +1811,7 @@ done: * muge_multicast_write * @sc: device's soft context * - * Writes perfect addres filters and hash address filters to their + * Writes perfect address filters and hash address filters to their * corresponding registers and RAMs. * */ From nobody Sun Apr 21 07:34:12 2024 X-Original-To: dev-commits-src-branches@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 4VMg9w6KNtz5Hhh1; Sun, 21 Apr 2024 07:34:12 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMg9w3nHLz4bK2; Sun, 21 Apr 2024 07:34:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684852; 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=YI2oR+4NiaO7xaHEARJynLQ24DK382XILjAy4q8WQtg=; b=kksDz735vfOSk+uBFFT3yZ1uYPExr7aPRewR3qayyuDlVEOEQrbTXJONf9s0HdpuOellI7 C5iQbZNLEe7RMJJblqDPhuCMmUr+wN5554AEeKJ2JA+mq0X+xi+RG4i7K9f835+P/Swr9L nbZd00i0kcj9PFjLuJMX0KOPIitvrI44FztfBQhtSCWC1KHhIGDrUCLKGeIKsAd7qbT7lT oPQoNQ1b2Hr7/YGE4+yy5bLLQpI6mKsVKi/Eu+UO+oTiM3/Z5fU1F3nidtiFcfX+XvsJEu eV51JvM+G8Ijbf321juQ60f5NemVNt9+1jckkl/u0ZyxoJq6dYRO/HCH1hLSPQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684852; a=rsa-sha256; cv=none; b=LcclmDRZsNTTr1wrwDQ+LjMWePsOyTInwj3ERL74zTdSN1lCuv76wmGi5LZl6/XNvQg8u9 fLXWPZEsrA6n8BCZEBq6d8Wa5xG6VnPoTnBJvCwvqZU4G2NvYK3062G9sQdkVwvTI3QURd erhZQ+aFCfoonuyiCriTSsvRp2nsTJxxRsPwUg/KlrSXY6991GZa/tQaL+yGtioNagSpnQ /+2tLk6hq9XxFuekdzXkrt3HhyDham5ioegit+f2zGP6pl1RHfokFqVOTbUwboCjGLHWHk YRWJqcGrNMUsO+Jvcz+1x37/u98Aq7W2eaQmjMF12QWv22g9JcN7bEaXQ11Puw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684852; 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=YI2oR+4NiaO7xaHEARJynLQ24DK382XILjAy4q8WQtg=; b=GX3IPmujTe4DU2xncIcfR3e1ieSvJt10+ylslaR5EaTfavhG7cIx3vmDCw3g54axsr9/wr kF1spl4vsbVt2QryM65HhQZwp1IGXM2nJrYDrWjjyq70pPKmAaYHYVuH/21nU2kwUGPfeY PhJjY211fscY0+w+CM2QjzNQYJl1cKpo8F7Zx1yqK2s4CxuH8C2s9BUAzax6/OKzMKVbPc cb0ir/RvxdvX5i+vnwDsAyo4UkSkuMp42Y1/OtzqKrMd6MXo1tVKbOlmPp6LrfqONukukb fhMFVb5w3AWmzrlPwKZ5TuIFtpOTuUMK/ZHXpKV1RDgAmB/rAHpK6O2GGpLNqw== 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 4VMg9w3PKYz19tt; Sun, 21 Apr 2024 07:34:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7YCn6054521; Sun, 21 Apr 2024 07:34:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7YCuP054518; Sun, 21 Apr 2024 07:34:12 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:34:12 GMT Message-Id: <202404210734.43L7YCuP054518@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 2b343cd2d5f0 - stable/14 - oce(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2b343cd2d5f0f2c430e827fb225cf2147ed22b27 Auto-Submitted: auto-generated The branch stable/14 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=2b343cd2d5f0f2c430e827fb225cf2147ed22b27 commit 2b343cd2d5f0f2c430e827fb225cf2147ed22b27 Author: Gordon Bergling AuthorDate: 2024-04-18 14:19:18 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:33:52 +0000 oce(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit e991acd5d0f60fe3c57acb452003c551194a758b) --- sys/dev/oce/oce_mbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/oce/oce_mbox.c b/sys/dev/oce/oce_mbox.c index 3717eb91d36b..a51798119761 100644 --- a/sys/dev/oce/oce_mbox.c +++ b/sys/dev/oce/oce_mbox.c @@ -471,7 +471,7 @@ oce_read_mac_addr(POCE_SOFTC sc, uint32_t if_id, goto error; } - /* copy the mac addres in the output parameter */ + /* copy the mac address in the output parameter */ mac->size_of_struct = fwcmd->params.rsp.mac.size_of_struct; bcopy(&fwcmd->params.rsp.mac.mac_addr[0], &mac->mac_addr[0], mac->size_of_struct); From nobody Sun Apr 21 07:35:13 2024 X-Original-To: dev-commits-src-branches@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 4VMgC54pYPz5HhhK; Sun, 21 Apr 2024 07:35:13 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMgC53z4Qz4byR; Sun, 21 Apr 2024 07:35:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684913; 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=6YELgkRSloUeTV4ojgExjMaBhepboWksyo7CFqV6xQo=; b=DaCpdjDHZc+zdt+gkF1d6CrkWrRmQJzTiCfQLLJfqzVCB92/3JzG05XRLlB1YDwJx7Tot9 11pRYqbCVfZvvTlhh2xjLszCuxAQS+eEq6+C6YPQqHcM6FfIlclxgh/nK/ZXL4reFavX5l UAFy5UqK6rs6LavDjyaQU/o/robCPfEecw2JhwFQusSY0fNVFWoyRZYnI9shKRe3u3Y/Cu m6d5NCWJz8CTYQYNn+uk4J/zotKbgbh6tRHTWMHwVhrIsWOXq2QXLkVP0WSDv4P1QYCk/U 5UTHfmhSAQhfexIDVgrCAMTNi65WnARdsvs1PsnOsRqgXeJBy5tRvh/jMOUK7A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684913; a=rsa-sha256; cv=none; b=wh7q6aRTDWAlR07fcoCmPTe9RHFjcgH2LycqE8V4cnuxsJ5sAcYYhlSFPa6wXl3Xvec2BX zVTq8ec6wuk1BmtSQcOykFXopqvIitcvyOCfYUTzGvNlLeTB9PWsg/ullyhbE6by4lSqw+ wFV2QQIG7L6lQJYlvy4A7cH46oo8i/asahzJ7Z8CgiyYqOUZ8QzCaXFsHOHLvgQDIt35LA 3ButYPmb7n+g8cIGcK4Up2AktnzH2lS4ry5psUSQdKQjabX9wHmVzHziG08cg8MFLcTpA9 TVyoUncI+D/iMg96rtvNp/f+chRiF3+kffsxdBy7Qgu+CajcXRcrACYpJd+nog== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684913; 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=6YELgkRSloUeTV4ojgExjMaBhepboWksyo7CFqV6xQo=; b=pveLjkyBSQhscB6OVeKTSB52tcMyJkRRJTQ1TYmt8XQ3wMrVCYxInlsCBHoHJt7VGfqbCJ df5vGoFbnR+ecmpCPHqnYSUnX2SVlmLsxcBuVId7IZRh7Xz+S89FU/PF6p1+ZLsg2Tw2qZ zqtdu9hx99C/MKu3MmoYMXZkL3cyHyVHoIcuzOu3rfNHjfEMrbRW01/C7u9jiQNMMquIIB ox1y799eZlJ9Zr2JfmqC5xSeKhOSHPazVBUtb3GNLInaGHsIFvskiaY4zDJ6ilrt3OAsdL 2nHKRLe+xXO9ignoc2k8nVkSJ/DEvsa9mYlOw8GTqITL7gocTUpjVOBLf7Ht+w== 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 4VMgC53GJfz1BBP; Sun, 21 Apr 2024 07:35:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7ZDxL054869; Sun, 21 Apr 2024 07:35:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7ZDeK054866; Sun, 21 Apr 2024 07:35:13 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:35:13 GMT Message-Id: <202404210735.43L7ZDeK054866@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 36a642a06dea - stable/13 - netpfil: Fix typos in source code comments List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 36a642a06dea48613c20597c9f22567ed9b4a23b Auto-Submitted: auto-generated The branch stable/13 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=36a642a06dea48613c20597c9f22567ed9b4a23b commit 36a642a06dea48613c20597c9f22567ed9b4a23b Author: Gordon Bergling AuthorDate: 2024-04-18 14:17:10 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:34:36 +0000 netpfil: Fix typos in source code comments - s/addres/address/ (cherry picked from commit 8ce3ef5f35fd4dc442b1a33605ca7d3132047faf) --- sys/netpfil/ipfilter/netinet/ip_fil.h | 4 ++-- sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c | 2 +- sys/netpfil/pf/pf.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netpfil/ipfilter/netinet/ip_fil.h b/sys/netpfil/ipfilter/netinet/ip_fil.h index 3db2b23512ef..7343fd079564 100644 --- a/sys/netpfil/ipfilter/netinet/ip_fil.h +++ b/sys/netpfil/ipfilter/netinet/ip_fil.h @@ -593,8 +593,8 @@ typedef struct fripf { u_short fri_icmp; frtuc_t fri_tuc; - fr_atypes_t fri_satype; /* addres type */ - fr_atypes_t fri_datype; /* addres type */ + fr_atypes_t fri_satype; /* address type */ + fr_atypes_t fri_datype; /* address type */ int fri_sifpidx; /* doing dynamic addressing */ int fri_difpidx; /* index into fr_ifps[] to use when */ } fripf_t; diff --git a/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c b/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c index 863201e2fef3..7e16bbaf7ccc 100644 --- a/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c +++ b/sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c @@ -1836,7 +1836,7 @@ ipf_p_ftp_epsv(ipf_ftp_softc_t *softf, fr_info_t *fin, ip_t *ip, nat_t *nat, s++; /* - * As per RFC 2428, there are no addres components in the EPSV + * As per RFC 2428, there are no address components in the EPSV * response. So we'll go straight to getting the port. */ while (*s && ISDIGIT(*s)) { diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index e03fcbbe37a9..1fd5803117bd 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -5563,7 +5563,7 @@ again: break; } - /* Only add the addres if we've actually allowed the state. */ + /* Only add the address if we've actually allowed the state. */ pf_sctp_multihome_add_addr(pd, &j->src, v_tag); if (! do_extra) { From nobody Sun Apr 21 07:35:14 2024 X-Original-To: dev-commits-src-branches@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 4VMgC65Kcfz5Hj18; Sun, 21 Apr 2024 07:35:14 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMgC64Ll2z4btS; Sun, 21 Apr 2024 07:35:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684914; 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=o1iCkCs92sgRlw79mEjJSv9HysdmsBudjrLpVmGbGgM=; b=Ow54DoUF/Ov6c8UQO6MbvcfCLIgy/qegjZfj9SlGPJQL1uIy/iAu05rrNRuue6TupKziwY 5kppAxGqiNiTLR41nkL8zyokbT0yypQVJ1MX/XcoA+M6rkaGvkQUsywqgwKsDaOEZR53/5 uA8EflAxIKqKBMbfCgtQACsXuxGEWR3ZZwVu2CRkcio1r29pg4rKQf6EyI6cEjtOcUmYrv nv9nQIABObbRj3mom86XHKUMl4/7TXF9keTIBiCoQz/piO50+5WiXNyI85kE8ldfd+DTdV 7Wf3b95s8MkTng6SniXHxyNpPW6syzSAZA4ptgUN5VkV65weaCV1icjNwje9jg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684914; a=rsa-sha256; cv=none; b=ObOXaR/HGipP3nLyBW1ugaW/TBtKq9gSzYyDzAv2dQTgkzyO80zqmSBFD7iRLnvamtMWBf bQQ4tZKMsc8blltdn4eCYprVgFGs38zaHooUEsjUgLS6h7Ad4EqplrkltyYpoUIFy1u+2M QtON/aPDidy/EZhDLev5K+ezu+1R1JN7uYoBGHzQMmIM7UTqOEQnw4bn2Q2gYdD+f3UJoe +ODMsUKJWjeuGsZaDBtRwSdizvcGKmyYePpm3VmCOAK/bDRGjIPDBVxdVjxc0MYkmZR0Wt E84cauD7tKIXhwhsLWgyRIlAp7zzpej8CHReIF53rDJGTz20nVQcWduZjdFDuQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684914; 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=o1iCkCs92sgRlw79mEjJSv9HysdmsBudjrLpVmGbGgM=; b=TxNipVYwWW3N3EQuRL1uKiRKuIKT3PN2yt8KPw3yQ5+Pm46uKO55HptCj8za2vb+5wxMWA tp93DVAlhq0fs2kFoQzmCgNiPcxPH3Duzjx8wvL3jPFyTcM26sDTd92+V5KCOXbUQ/K4F/ Hm8/htdjBpdFEp9AdN4Ib9wBFj3+RkG39lB9BC0TshFJckkZiYZZlnSSdo0+cugC42vApd v53SpvHDODHd6xa+cofScB3Uj3vRXiwFj8NDEaG77oy6LciEsRrdV3zL9EM0xu1hKN0z/O +3AZOriCoz0Do8czvu6ui5Tyfb/1kn9NmHpFmnh/jsoH2dUY61sxjuvEzAdNNw== 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 4VMgC63x0Gz19SN; Sun, 21 Apr 2024 07:35:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7ZEoD054923; Sun, 21 Apr 2024 07:35:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7ZEAP054920; Sun, 21 Apr 2024 07:35:14 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:35:14 GMT Message-Id: <202404210735.43L7ZEAP054920@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 39ccab474ac8 - stable/13 - muge(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 39ccab474ac8829ab27c21df1b4aea6237507065 Auto-Submitted: auto-generated The branch stable/13 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=39ccab474ac8829ab27c21df1b4aea6237507065 commit 39ccab474ac8829ab27c21df1b4aea6237507065 Author: Gordon Bergling AuthorDate: 2024-04-18 14:18:26 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:34:51 +0000 muge(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit 046fe202e76623988ac612b20047940b86dd373f) --- sys/dev/usb/net/if_muge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/usb/net/if_muge.c b/sys/dev/usb/net/if_muge.c index f05d474b5c86..4e7acd7be930 100644 --- a/sys/dev/usb/net/if_muge.c +++ b/sys/dev/usb/net/if_muge.c @@ -1816,7 +1816,7 @@ done: * muge_multicast_write * @sc: device's soft context * - * Writes perfect addres filters and hash address filters to their + * Writes perfect address filters and hash address filters to their * corresponding registers and RAMs. * */ From nobody Sun Apr 21 07:35:15 2024 X-Original-To: dev-commits-src-branches@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 4VMgC80Km8z5Hhrr; Sun, 21 Apr 2024 07:35:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMgC75Pzjz4bwp; Sun, 21 Apr 2024 07:35:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684915; 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=Kz6sJVi3/itAKf55R6n139/jZLZRXSB1voaKsVmAs1M=; b=x8Ch4fgAA2gJklXbk8/nr2lMBgHjweBKqZZIQFD5mVQUyKSNfcOHbAORhu5eid2MoMYTyz LKhPHAphoEml9tYv4VY77OyICwU4NqDKJGwv6P04LV9qQAk/c2gM56KjBmY8Ajeo/ZGPUm xG9xyGFa7mHG0HOqIvrwNjoYA1PB/7gWiwaqjfAdOhldkEXZgyJZaADXHlsU4AMANuhiwG tkt5dOnZZeISp297P9kEUwTCNIANAtF8F2GgLPz6I/csSUrBovynwO6MbbRXGbnN0xyxzQ FY+8oR+t03kbR0xXnfJj6BD49fkDagsuH46XKrztQEO2mDEjAXXhSpY/vLKLYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684915; a=rsa-sha256; cv=none; b=lVQK2V9oGFl5sv7YxVryoRSfmRMqZQPYh/5YzrGqx8UIb/pGpfBfhkhNzq5c8lDI0z2Ygs zG/KIZ/phMji5lCi6TSsuFa6YxVA3z2/ITqvLVyRFsniKknWpRj52zpGxOnaD82Feo9Kuu KLLQXDDjwBuhYkM7JHMSILmZV7oTXHnoh2Ot3IXODVxeom5Ni0Y5AWzRn/CcjcF1av3AgM o+hvXfhCl2xyEewXDPbS7+W0/zoh6BtVVgSEGZXtVq79a4FqiurAGNKNxdxgxBMZft6fAO 0YJO/ve93Ed35Yq+BcOehqETFcJjMjRRzRxMURh3qSrxXzxU4qvFXhnbbm5ukw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684915; 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=Kz6sJVi3/itAKf55R6n139/jZLZRXSB1voaKsVmAs1M=; b=VKea58CgBOFotF1AcDDOEjtqU7ongo/+CEy+VJs3g2Gg6137AQ7Nnp7hss4JlkjsA2GoB7 A36zoAmfHAx6lC5oUC0VqzoZI0fq9G4ONxiMu03i3gYkDfU3+eoGate0dC9NYVbrhat+m5 Uya1OirdZ0+MvOO0SuwBWaVgbwrAUkgVeNMDnjqEaUx4wtIFUEjWPbyIY5zRDW7vqBE6h9 gRN5+MFIpel0N+BTBXjnFm9+hEcA7SfQuBlt/wxq6WvN0Hz9dHNHeq07GVfGUENzIiZKOw fsZzfqxYge3eXujK+SYZI3Wx2iKKfS+ci6YsCMLys57rhL9YuMAbGlGr/J4Gmg== 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 4VMgC74z7kz1BXv; Sun, 21 Apr 2024 07:35:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7ZFAH054980; Sun, 21 Apr 2024 07:35:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7ZFjm054977; Sun, 21 Apr 2024 07:35:15 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:35:15 GMT Message-Id: <202404210735.43L7ZFjm054977@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: c61eb1679d6a - stable/13 - oce(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c61eb1679d6a256db0436c97884e07d14c6d1213 Auto-Submitted: auto-generated The branch stable/13 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=c61eb1679d6a256db0436c97884e07d14c6d1213 commit c61eb1679d6a256db0436c97884e07d14c6d1213 Author: Gordon Bergling AuthorDate: 2024-04-18 14:19:18 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:35:02 +0000 oce(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit e991acd5d0f60fe3c57acb452003c551194a758b) --- sys/dev/oce/oce_mbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/oce/oce_mbox.c b/sys/dev/oce/oce_mbox.c index 867330a1c552..b38d899474bb 100644 --- a/sys/dev/oce/oce_mbox.c +++ b/sys/dev/oce/oce_mbox.c @@ -473,7 +473,7 @@ oce_read_mac_addr(POCE_SOFTC sc, uint32_t if_id, goto error; } - /* copy the mac addres in the output parameter */ + /* copy the mac address in the output parameter */ mac->size_of_struct = fwcmd->params.rsp.mac.size_of_struct; bcopy(&fwcmd->params.rsp.mac.mac_addr[0], &mac->mac_addr[0], mac->size_of_struct); From nobody Sun Apr 21 07:36:29 2024 X-Original-To: dev-commits-src-branches@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 4VMgDY4bwwz5Hhkl; Sun, 21 Apr 2024 07:36:29 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMgDY45JNz4cjB; Sun, 21 Apr 2024 07:36:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684989; 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=Txk5g21SjI3ozf4twWvbIChtwPMv7DpNqAi6HdXsHq4=; b=tr2DwAnL93xtzV89iXXQEqDEvjct7dY2xjvmNFBvpCzpLio/cOC2jlWu5E2HrruREK1GrZ FvKYxMFia7FVMs5TjLRPdNhip68StKIJhuJpl9GDUB4SzGkUtx0LQssuTUSZJilQ0JuVc/ 7aC7meHOkc7gouByKJcwREDq3j0TF00pIkixqiSeiqd6edBj6WrNSPuOB0PXzZsQTZ0yhT NqHdeLroL0Pht/7GP4JqnPAbZoaSI1LCE4WEbh9EdpVgovon8sahJHBRllVWLJijqAlMft /QUF75nwZWGF6mr/9djD5mAeOhkoPOeliJRCk5Du/p+o036coUeX02pZT8SAFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713684989; a=rsa-sha256; cv=none; b=S/VWM9yI0dvf20gg/5+qYdkzXobIsqfGnG+qUYAhIAolAOjD73uHcPDayoADvob4Dj3D0z pOOoyUoBt3XUl3FF0JBSNca6DS5zpqqTPuH3fJCpNZAfK5GjMdCAV9If0aABm0qVAYbVtT B7ZJyPpiYvXnVwd2v3aRBSrMN58AnZgDoqZPCMu+7haK9Dtm/ejy+c6H7wCuOWVFo57Ezr WeIt0WXQH1EizkgTkA055WVE0nAsW5/oVEjQQJ2AcWVzU1XPcj/PeWsSqt4HUKbe2U5CiO i4pTggC2v7U5KnXj4p7YQjl58BDw5n2nDuSCBGlWrYVeq7TPxd6jKkidMgS3pg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713684989; 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=Txk5g21SjI3ozf4twWvbIChtwPMv7DpNqAi6HdXsHq4=; b=E2ExOX+X4De9joRZgLPrRJpB3659STVf7KtUpbncPGkvWh9ZxAASZ14vTU7chxjt0q7jMJ zQGrY/LdWAbZ+rZWsYMXEzKwpev6LM86VTxtSGFcCxaAS2lxTW1S2VlEWMh6BlRf//HzGg EgcUeKGV9QY0exntUGX4uLrNocm1+Lk0+hNsq3E2JmiqH9ARRJDhSeHyUKbP5zEH++oANQ Fzx3Lp6NEAyMF7WFJU0cvG1Nlw/r7ljHIY8o/AUXxfMIEfR1h07dmaErkFsOAqmj8soF8U 8yfz9kO0CCgEfeoalJ2KN0rqOgaDkBW9SAJNpFIFJuyFfU4kTGzvK4AHw8RkiA== 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 4VMgDY3hcNz1B8B; Sun, 21 Apr 2024 07:36:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7aTvg055306; Sun, 21 Apr 2024 07:36:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7aTpH055302; Sun, 21 Apr 2024 07:36:29 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:36:29 GMT Message-Id: <202404210736.43L7aTpH055302@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 411f60811bb1 - stable/12 - muge(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 411f60811bb1c283bb9a4a317d67fc393defc085 Auto-Submitted: auto-generated The branch stable/12 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=411f60811bb1c283bb9a4a317d67fc393defc085 commit 411f60811bb1c283bb9a4a317d67fc393defc085 Author: Gordon Bergling AuthorDate: 2024-04-18 14:18:26 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:36:19 +0000 muge(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit 046fe202e76623988ac612b20047940b86dd373f) --- sys/dev/usb/net/if_muge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/usb/net/if_muge.c b/sys/dev/usb/net/if_muge.c index 359a167eaf02..ae0bfa011a6d 100644 --- a/sys/dev/usb/net/if_muge.c +++ b/sys/dev/usb/net/if_muge.c @@ -1818,7 +1818,7 @@ done: * muge_multicast_write * @sc: device's soft context * - * Writes perfect addres filters and hash address filters to their + * Writes perfect address filters and hash address filters to their * corresponding registers and RAMs. * */ From nobody Sun Apr 21 07:36:48 2024 X-Original-To: dev-commits-src-branches@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 4VMgDw3pY2z5HhhZ; Sun, 21 Apr 2024 07:36:48 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMgDw3242z4d7q; Sun, 21 Apr 2024 07:36:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713685008; 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=RcTXUhOZk+8+Yl/iz0IHgi0i0gTVV5eyCQIYUiTxlTY=; b=xWvecXJ7efmJsel5tlbhavguzPWndgVha55m7cfeDc0MpbVTGloZPUPXjx/ZfyBWJJXFfu ujsaCPwBdD2XOuBsI48g0M8ZYncsiPIAqs1NE71VOliao9mAJZUoq/vZ4nCYQUls9vDTzW Q3cH3mNqke7+kl8MoeFE5dYbax+B+8YBNaJxw+kLY7DHitwu3cR7btBpZDK2WxzgRv7aQl bvDeCEdmHOHTp3EiCaKhjHsp9M+OF6jduNHen+1K5q6mR1QD+xW3ZYYmRj5OH9zRzV1Lry xBJMNinDU4WDN6b4uDH+Fvq9fNSH9IL5hq7JHPR/1vY0niGyeGtw1r/erAUGCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713685008; a=rsa-sha256; cv=none; b=QHYgYnin1cF2ks+mhEIbpnCbyI5XLTJcly2NdJX6af8q+DFKa0A+52vDsioxcKbgHpqPKu 4MX/N7G6YA/JCCpB+Newy8EZ9Ew1Cz0+dKP4aVjGiWRvbB6FjxRA8Ddive7aWKKRiHnDE0 vKO4bfwn8S7YmklHc8sWcQu0ceXTDSYpSLbFJ1TLzkqgbW8b2q1VVTVCReGo98Vx1Frm7O cLg1CMTMl8fo1/lE0H2kvRZ9JFLtAAFtOqsSS+GI/nDHksFjSvvE0Hlb5Am6FXWWHQMAkh QCYvxw2JwohJLekD/LGzCTG8YhSz5Rga0OkJs/GJY94vApsABLaLexsLmPVmiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713685008; 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=RcTXUhOZk+8+Yl/iz0IHgi0i0gTVV5eyCQIYUiTxlTY=; b=SGp7VkQ7xWYyo0xsiUfh6q0JZM2sgQctnuKvpq8OhB0fA8yxi2921D07TWsAnr3MZfw64O ANMw4xViMFjLTxz6j7uxy4PSaKXAgfug30jk3ZPIoII/q35+6h31QMqd/vCV0KNxrx2HFl ADK6dECLgU976zDB+feZBYGI1LW0xwplFbqz6WwB+oSiaj7Hv22u4PTm+Cqp9s8fpb9Zgg IcnfhBeZSh+x6p7J23qt5IaqmUX1Q9dwHOK09k6jpwCfnqpFEHPIZAUs3SQJ5op+ayAEU1 k7QSvayaVh/Ba8SSx4TyKPP+F8v6bWvfUgIOZrIXCZko0FRYXk1FI3CJ65t10Q== 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 4VMgDw2d7Cz1BXw; Sun, 21 Apr 2024 07:36:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43L7am1j055493; Sun, 21 Apr 2024 07:36:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43L7am3q055490; Sun, 21 Apr 2024 07:36:48 GMT (envelope-from git) Date: Sun, 21 Apr 2024 07:36:48 GMT Message-Id: <202404210736.43L7am3q055490@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Bergling Subject: git: 05b5b4e966bf - stable/12 - oce(4): Fix a typo in a source code comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 05b5b4e966bf878959592006014c9f1f6ef0b6e2 Auto-Submitted: auto-generated The branch stable/12 has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=05b5b4e966bf878959592006014c9f1f6ef0b6e2 commit 05b5b4e966bf878959592006014c9f1f6ef0b6e2 Author: Gordon Bergling AuthorDate: 2024-04-18 14:19:18 +0000 Commit: Gordon Bergling CommitDate: 2024-04-21 07:36:37 +0000 oce(4): Fix a typo in a source code comment - s/addres/address/ (cherry picked from commit e991acd5d0f60fe3c57acb452003c551194a758b) --- sys/dev/oce/oce_mbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/oce/oce_mbox.c b/sys/dev/oce/oce_mbox.c index a1926526edbf..d24f468c0382 100644 --- a/sys/dev/oce/oce_mbox.c +++ b/sys/dev/oce/oce_mbox.c @@ -483,7 +483,7 @@ oce_read_mac_addr(POCE_SOFTC sc, uint32_t if_id, goto error; } - /* copy the mac addres in the output parameter */ + /* copy the mac address in the output parameter */ mac->size_of_struct = fwcmd->params.rsp.mac.size_of_struct; bcopy(&fwcmd->params.rsp.mac.mac_addr[0], &mac->mac_addr[0], mac->size_of_struct); From nobody Sun Apr 21 12:28:34 2024 X-Original-To: dev-commits-src-branches@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 4VMnjZ3VH0z5J7TN; Sun, 21 Apr 2024 12:28:34 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMnjZ2rPnz57Cf; Sun, 21 Apr 2024 12:28:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702514; 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=60TQcc5BqTm7PUW/AstyKkidBc5s4mjxETv1OdRIz6Q=; b=O8L3h2u0ImEOVdyk36rGOIM6XCSz9lpMAPXLbfL6v8j+a1NGt6H4SbYKI0e/tpMchOpBst i2QxInAVplrCOiKz6BWhzh5mLJsKD0Q7fE5DWMi1X1nbCIHkMhTEiND4L/bSLgWSOcOPUA sdVyFAOB1bhvIhwJNwoCbWMQdJkFixf6o35X0Leb7cuYbAXwhlpwLPqPITGl82vxblU4st eHuVaD7N9XA0GeEoAxQ90qFKSogsnGso8FPKYjRssRJc6aOfOUUfVAt5TvO5qA+9kLKSRh qmKX6DgOqupes/keBOmtc2ehyR4q3J2EQkneQOUfF4+O263cQWA7ld0G6F4m6w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713702514; a=rsa-sha256; cv=none; b=QRSa55W+KLMCCyiW82N1xHMIUEEAoH7qHYiFFlEP2T1Rn/XBipD08JP1ftuQCk+yuzWKXj tdnLOjNY4JaVekWjgEh19M0klScQ0ULlZdDEbNwA/uYKabVllbQ+9xjGbszDU5Ffm+pKKs eYOmSUw7LCWoCRU5XQbSr9eqGWWXmTrs17SsVEjzybA6fJe8qwC4g1ULGzqoJPvAxupEL8 ve/yviUwtx06Oma9tdllc6r5a2xHPsA/xecKLq64e+YIjPVNOZ3Gie0D+eZBeztVfoYoTL gz8a2kH7RzkUbxtYfw/pQ9bJUvBjUNM5xe0D3yft1ST7MDn5YUAm7e0IGYIh8A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702514; 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=60TQcc5BqTm7PUW/AstyKkidBc5s4mjxETv1OdRIz6Q=; b=yr9VEjdkuHD9ZQ4XxE0NKLCsrg8tL3CwxgM/gf5/rwAn5Pkqk89V2WLeEjU9A5NuVM4WR4 o8qzXcBDnVpcrE2zqONAn9KeQxfxeK8Ov/b67L/KajzJaOZIp4rASVvnVqTOBYLaoFftMl I6ukvfx78IkwQXw6bISylKLRwUUjPHaDWFRKpRPSj0GRrUB3PGsFARDmvsbnQSQwPTch+Q 8Khy8JmQScTc/OW4kyA9n24N+CfWMm5ZhfHbKtKtqGJaU+vBL7dt546H1OJQwLEJMa/6gF ZCx+5D9XAXHAmq+1zpia8lMgXx7d8iG+xBkbgTRUC4kbLlF9Qf6jt3xPTlpzRA== 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 4VMnjZ2RxXz1KM7; Sun, 21 Apr 2024 12:28:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LCSY40050127; Sun, 21 Apr 2024 12:28:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LCSY9U050124; Sun, 21 Apr 2024 12:28:34 GMT (envelope-from git) Date: Sun, 21 Apr 2024 12:28:34 GMT Message-Id: <202404211228.43LCSY9U050124@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andriy Gapon Subject: git: 73c9d514236e - stable/14 - Revert "dtrace: make 'ring' and 'fill' policies imply 'noswitch' flag" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: avg X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 73c9d514236e1d6f82f08204a3c9afbddd6929e2 Auto-Submitted: auto-generated The branch stable/14 has been updated by avg: URL: https://cgit.FreeBSD.org/src/commit/?id=73c9d514236e1d6f82f08204a3c9afbddd6929e2 commit 73c9d514236e1d6f82f08204a3c9afbddd6929e2 Author: Andriy Gapon AuthorDate: 2024-04-21 10:07:36 +0000 Commit: Andriy Gapon CommitDate: 2024-04-21 12:27:11 +0000 Revert "dtrace: make 'ring' and 'fill' policies imply 'noswitch' flag" This reverts commit e92491d95ff3500e140eafa614e88ca84ffb0d26. It was cherry-picked as fb9c50f983ff6bdd6f33a22ae7d5b391435dd02a. The general idea looked good to me. In particular, it allowed to save some memory and avoid memory allocation failures when a large buffer size was requested along with ring and fill policies. But I didn't take into account that the second, supposedly unused buffer, was actually used as the scratch buffer. The scratch buffer is used as a temporary space for DTrace subroutines like copyin, copyinstr, and alloca. I think that the change can be fixed by allocating a separate smaller buffer for the scratch buffer, but that fix would require more work than I am able to do now. Hence the revert. Reported by: Domagoj Stolfa Diagnosed by: Domagoj Stolfa, markj (cherry picked from commit b9827c007a7a39c7aeef73f8efc217b7b0099464) --- sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c index 83c0648b23b1..ce02676e0dc1 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c +++ b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c @@ -12058,6 +12058,7 @@ dtrace_buffer_switch(dtrace_buffer_t *buf) hrtime_t now; ASSERT(!(buf->dtb_flags & DTRACEBUF_NOSWITCH)); + ASSERT(!(buf->dtb_flags & DTRACEBUF_RING)); cookie = dtrace_interrupt_disable(); now = dtrace_gethrtime(); @@ -14865,10 +14866,10 @@ dtrace_state_buffer(dtrace_state_t *state, dtrace_buffer_t *buf, int which) if (which == DTRACEOPT_BUFSIZE) { if (opt[DTRACEOPT_BUFPOLICY] == DTRACEOPT_BUFPOLICY_RING) - flags |= DTRACEBUF_RING | DTRACEBUF_NOSWITCH; + flags |= DTRACEBUF_RING; if (opt[DTRACEOPT_BUFPOLICY] == DTRACEOPT_BUFPOLICY_FILL) - flags |= DTRACEBUF_FILL | DTRACEBUF_NOSWITCH; + flags |= DTRACEBUF_FILL; if (state != dtrace_anon.dta_state || state->dts_activity != DTRACE_ACTIVITY_ACTIVE) From nobody Sun Apr 21 12:29:25 2024 X-Original-To: dev-commits-src-branches@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 4VMnkZ1tggz5J792; Sun, 21 Apr 2024 12:29:26 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMnkY6QDZz57Sg; Sun, 21 Apr 2024 12:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702565; 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=u6Ul8Ko3ZjZs9XYiECE9y+so8ZLLk88MI9i994o8Swk=; b=igG4wwZx6UFGWqhMqnypUp62FX6STS7i4UXBWvMCPBP9B1b4f8CdB77H/zs0HgPolA9x4m tYsEcy+cP1lqeNuz2oC8T3wlpocY6i2UlnhxzLu6tMMBRO0i+PXHPM4x6MUR4jDIW5DHDy EIGiMgD9NlKRXS0w5W6g/Sd2c702sOKE1/iz8plxFRXPZ3PSSM/v13AAuxVxtV81bpAwi6 sUeLUBJn6dhq48EF2+LP3j3vJfcT4nuVG4VpKtrHH8hgW4XW1YrPnbuEDQmwtBpuMiNgBP 4pcF1r1BrjtodQbTKCx1YQHsNA36XVts+lAmXJ6frJBBuEShD/FLuMimSKsOAA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713702565; a=rsa-sha256; cv=none; b=KtkAVP4wChg0slYDFyeGXuqhnCcQ+iMkTF2TGNIGYQtVHBYkHiKYFApyLSIypVsrtfTNow mZIn8HgOY2t+9POBGCRnEsIBtkM29J7COI1i3f8lW9zvv0Ryd4EEcjHvwrL/8cmkPvP0Z8 qI3haT4BE3aE2wcxvzuHIuTk0vF2Ms4Gh7bAquc9hbwi/EPhahPVUhx6aJD8JHlpI/6cmT 5VEEzxUEPmVLDEd1OvaNyabHBj+qDUaoi5tcvO/DaP5zQkeYbH9JL/Rn1odpIbHqJFRdxc 5LgcIDuekIF4cDUe8HiWIge8B3t4Fqgux3kRO5BeSZuprz1FFm0rriPyAeG+zw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702565; 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=u6Ul8Ko3ZjZs9XYiECE9y+so8ZLLk88MI9i994o8Swk=; b=FwuC9gfNv8QfxiwGMbv/jBypjzv/xt2WlABmedCLQKjGJBSbB/HVE6/vFEiRAhHGq1tt48 22bM3/9TxHNAbjPO6oH46lPoR/82GigkgJBEmIHheobu7tUxjkdSzAmfuZCqb5+/f4jObu DiB2ZqGuRJxi1PDw5GeOpKRrlih/YVMLVLLLthENQzLQfeHcQLpJYS9mtlJ2ydrNNo/uxH zKtBwokDA0oNf6oLqgsYVSYH/6+oENxiyLjVLhqwzOryE3WKluwG/Lbg5O+iv9ppJfjwHk mvEHKQeK6zND7qXcFtwVi6KRoJC/UeG1+jB3t4XogUhHuspRvc4iSaOV6r1XUw== 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 4VMnkY4yDmz1K9V; Sun, 21 Apr 2024 12:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LCTP9h050407; Sun, 21 Apr 2024 12:29:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LCTPDP050404; Sun, 21 Apr 2024 12:29:25 GMT (envelope-from git) Date: Sun, 21 Apr 2024 12:29:25 GMT Message-Id: <202404211229.43LCTPDP050404@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andriy Gapon Subject: git: f12a50fed2df - stable/13 - Revert "dtrace: make 'ring' and 'fill' policies imply 'noswitch' flag" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: avg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f12a50fed2df3994b05d7c8702f06bb117c156d6 Auto-Submitted: auto-generated The branch stable/13 has been updated by avg: URL: https://cgit.FreeBSD.org/src/commit/?id=f12a50fed2df3994b05d7c8702f06bb117c156d6 commit f12a50fed2df3994b05d7c8702f06bb117c156d6 Author: Andriy Gapon AuthorDate: 2024-04-21 10:07:36 +0000 Commit: Andriy Gapon CommitDate: 2024-04-21 12:28:59 +0000 Revert "dtrace: make 'ring' and 'fill' policies imply 'noswitch' flag" This reverts commit e92491d95ff3500e140eafa614e88ca84ffb0d26. It was cherry-picked as f0ed49921c2891733b7ee65679a8dcba5398e3b6. The general idea looked good to me. In particular, it allowed to save some memory and avoid memory allocation failures when a large buffer size was requested along with ring and fill policies. But I didn't take into account that the second, supposedly unused buffer, was actually used as the scratch buffer. The scratch buffer is used as a temporary space for DTrace subroutines like copyin, copyinstr, and alloca. I think that the change can be fixed by allocating a separate smaller buffer for the scratch buffer, but that fix would require more work than I am able to do now. Hence the revert. Reported by: Domagoj Stolfa Diagnosed by: Domagoj Stolfa, markj (cherry picked from commit b9827c007a7a39c7aeef73f8efc217b7b0099464) --- sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c index 17d9536b2428..6ae0322ebb0f 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c +++ b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c @@ -12055,6 +12055,7 @@ dtrace_buffer_switch(dtrace_buffer_t *buf) hrtime_t now; ASSERT(!(buf->dtb_flags & DTRACEBUF_NOSWITCH)); + ASSERT(!(buf->dtb_flags & DTRACEBUF_RING)); cookie = dtrace_interrupt_disable(); now = dtrace_gethrtime(); @@ -14862,10 +14863,10 @@ dtrace_state_buffer(dtrace_state_t *state, dtrace_buffer_t *buf, int which) if (which == DTRACEOPT_BUFSIZE) { if (opt[DTRACEOPT_BUFPOLICY] == DTRACEOPT_BUFPOLICY_RING) - flags |= DTRACEBUF_RING | DTRACEBUF_NOSWITCH; + flags |= DTRACEBUF_RING; if (opt[DTRACEOPT_BUFPOLICY] == DTRACEOPT_BUFPOLICY_FILL) - flags |= DTRACEBUF_FILL | DTRACEBUF_NOSWITCH; + flags |= DTRACEBUF_FILL; if (state != dtrace_anon.dta_state || state->dts_activity != DTRACE_ACTIVITY_ACTIVE) From nobody Sun Apr 21 12:32:05 2024 X-Original-To: dev-commits-src-branches@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 4VMnnd68hRz5J7LY; Sun, 21 Apr 2024 12:32:05 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMnnd5fZpz5831; Sun, 21 Apr 2024 12:32:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702725; 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=d1vmmpvjSUbmg6m8kdOCBuhJM+1iLOOltDXmrqrGo94=; b=OMLrrULqxJery37yAisP0lyo9660G77UHzarANOco7z3ITmmygJW78CN0VWsEtp3ORSU0J 591G9K+hYQ/9UHoar0XDp1Mc9nih2U0E7tmGwC4PV4gDniIOlNk749GUZ9d65Jqaou9v/U MrM1bMpCTdwiltgansh1FPjplvR/SUsd3RRBzXeB6AMe3TpERrJIQfzIyaMxzlsayAlhFU J7lhXKZvZyhzMgt6gHdx777q6h0/csyGCKse7E2l8o6cDHvrdqGjQ3AYcDURNKkIGoWe5T kFSIznUzb4SVvVz6THaFLf2ShcjaDf2FHd4IdOdYOHvVhDwaDGpwwQzBUSoa2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713702725; a=rsa-sha256; cv=none; b=t44FbC8bFbLSEQ5xsDEwOFnj3AIkYwp4mL6lh4FMN76s9dsdmDCHoYd1F3iPYk6/HqDkf4 M2qCZyLfySmLpwPZ+HAIfu8gw70W+Ls6JjJGOO99TnoW9RwS8NK4jExri3sb/XuDlHTz6F 0MxqOHSgQPsBfjKbn/w6gpKG9nRmVZgCi16jUwD9ZVdMXfj6SNqavdf2OTURtP3EB9y4AZ z3PMwRCK3QUjStxUqFFY61wRCoEBT5biR0GCcszF3VKiRr3RyLhEX2M+ceeegB9bTWuxjm Wc32k0mfXWuU8FDZXGWZNzpa7clEI+RcDO3To4Ie+WuiZtrTADvNXvMkI5D55A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702725; 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=d1vmmpvjSUbmg6m8kdOCBuhJM+1iLOOltDXmrqrGo94=; b=kWVvj5fQVFjp+eVMMJKISLdsGcgGyiWcagDs30xmEoVv3+uIgAPfPHhC7Wh5w45m4/dUhi 1jLE7n2EoAPbx1kaZudgx/bGEOCONNAWZoEvGZnq3S4pZwAwEbRN+l0F68NmUd+NePiBFH jDR1MXNqOblE2hb6qB88M2+q/c0oM7ee2Z3+QzAy1WjcXyUC1k1H2fam4LXvNCvCkkLDLk PAG5kj6FZ+kfSyDTDkDhyREX0sL2oO43yRfLpgKs6cveVpcpP+xtaFGuEZOmvrCPRMSxn6 FjJLnqF+KfBOee6Xf5BCK7U0aCwXdl/uuO+9sO8BjaZOJEz2fjOnds0weFri8Q== 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 4VMnnd5FNgz1Kdh; Sun, 21 Apr 2024 12:32:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LCW5Nj065950; Sun, 21 Apr 2024 12:32:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LCW597065947; Sun, 21 Apr 2024 12:32:05 GMT (envelope-from git) Date: Sun, 21 Apr 2024 12:32:05 GMT Message-Id: <202404211232.43LCW597065947@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andriy Gapon Subject: git: 43bf62a364c1 - stable/14 - aw_gpio: temporarily switch to input function if read in eint mode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: avg X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 43bf62a364c1b150cfdc64eb6b5f62ab3b48ee14 Auto-Submitted: auto-generated The branch stable/14 has been updated by avg: URL: https://cgit.FreeBSD.org/src/commit/?id=43bf62a364c1b150cfdc64eb6b5f62ab3b48ee14 commit 43bf62a364c1b150cfdc64eb6b5f62ab3b48ee14 Author: Andriy Gapon AuthorDate: 2024-02-18 13:55:20 +0000 Commit: Andriy Gapon CommitDate: 2024-04-21 12:31:50 +0000 aw_gpio: temporarily switch to input function if read in eint mode This is needed for gpiokeys driver that needs to read input state after receiving an interrupt for either edge. PR: 248138 (cherry picked from commit b98558e69b0aefbb99120a8a6ca7efbb8cafab5b) --- sys/arm/allwinner/aw_gpio.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/arm/allwinner/aw_gpio.c b/sys/arm/allwinner/aw_gpio.c index 485d760f810b..1229d5bb146d 100644 --- a/sys/arm/allwinner/aw_gpio.c +++ b/sys/arm/allwinner/aw_gpio.c @@ -654,18 +654,30 @@ aw_gpio_pin_get_locked(struct aw_gpio_softc *sc,uint32_t pin, unsigned int *val) { uint32_t bank, reg_data; + int32_t func; + int err; AW_GPIO_LOCK_ASSERT(sc); if (pin > sc->conf->padconf->npins) return (EINVAL); + func = aw_gpio_get_function(sc, pin); + if (func == sc->conf->padconf->pins[pin].eint_func) { /* "pl_eintX */ + err = aw_gpio_set_function(sc, pin, AW_GPIO_INPUT); + if (err != 0) + return (err); + } + bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; reg_data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); *val = (reg_data & (1 << pin)) ? 1 : 0; + if (func == sc->conf->padconf->pins[pin].eint_func) + (void)aw_gpio_set_function(sc, pin, func); + return (0); } From nobody Sun Apr 21 12:32:26 2024 X-Original-To: dev-commits-src-branches@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 4VMnp41T8Dz5J7rq; Sun, 21 Apr 2024 12:32:28 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMnp368yhz58fn; Sun, 21 Apr 2024 12:32:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702747; 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=yM34t9iSIvEQ3cul2hPhHdbUTxYUOOPSaI+efXTQAeg=; b=P1Retb8PIEvsex3QQcbGtSzVgXmfbgwwXHKXdaHeZnIWhB4XminLf5Fy/ohGv9uSv0Gs00 Lc6MMR/8WX4UkgHDrxrEiBwdxs9ggxJYnFDzPVwkOE7uEPNPLRggp7FLDEgaeuNVcQUi7W LNz+2xnrYmD0yzi72FvZXqgBLDnPHME0YCixr6ySkadC1VUJxAw5Ay/0ZZ7m3ppxiHC7W4 12gRrfL85Y1FIoKjQa/jSo6+fWahC6XCDc5VRxlKhEkbTaI0urNeaEn4GMp1hxq7b+7qZX mS0o/Zr7nsPJLaljjfa7cZBBau9e2aB55fnu92c5MSjFCWpzcnlaE/SbYX8y1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713702747; a=rsa-sha256; cv=none; b=r+4jHHVOMNUuHYIMAtnJJq4wKyW7TB9KmKWqN14VRb4m2PY2R0IwICEmtaCWUbCNuKCY3K usOLXcyh+fjOE4kij1UMLkNouql1o45MpLh/24B4zFsKo1naA07IYBLQbh7V653N0yuu61 jaTMYq3LTrHGgCE8BEycOOSiXHqBqdjhuuNQw/upiRoaYIdfdHkanNwsM57OHRv14S4pFQ JZ9I65Xnukjz+f4WCsrpkDviSwt7G8HcMklAX5nUB2DPMnXOo5YP1zgC0M/rZ3wXtqczzQ nmTXJi4wJjeFZrJjc4XBI2yfyNpaaukMVmHAZAq5Ck34kCeUG/sTtznzbHPc5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713702747; 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=yM34t9iSIvEQ3cul2hPhHdbUTxYUOOPSaI+efXTQAeg=; b=tPjSC0O9UFxn4zbz0bvZ297h5I+VagcqFFGRa6naMnRD6H6YHFqrDFnYHQG9wiSTqcqbnK 7hnqMZhzQpupnFr8rW9hheK9dhef2UZfJk/AROFf5RZX/omDLMaSezsNaYei6rgYBQEFxO q/6HV7BzHoOkOYx3RpKP5RfTMr0eNyT3KYeOmMk1EUORAjvmVBMRBRqquQ3OV9g/E9Qgzs tIB5tKkTbPd8gFgrL1xnW5zVUD7ma4yCqFw12U0bMYBIgzOTdvAI6oEywfIBmmvs/raN5D 5hUBAOCSRrRFqzTAfFA+Wo2g7LPh4nSM0qPncoGHNfp/ZK0RRDsCddRaPazo3Q== 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 4VMnp26pmxz1Kvc; Sun, 21 Apr 2024 12:32:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LCWQlh066148; Sun, 21 Apr 2024 12:32:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LCWQTM066145; Sun, 21 Apr 2024 12:32:26 GMT (envelope-from git) Date: Sun, 21 Apr 2024 12:32:26 GMT Message-Id: <202404211232.43LCWQTM066145@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andriy Gapon Subject: git: 9c444571ab94 - stable/13 - aw_gpio: temporarily switch to input function if read in eint mode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: avg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9c444571ab94ac1c148100bfc85954f7029d7f09 Auto-Submitted: auto-generated The branch stable/13 has been updated by avg: URL: https://cgit.FreeBSD.org/src/commit/?id=9c444571ab94ac1c148100bfc85954f7029d7f09 commit 9c444571ab94ac1c148100bfc85954f7029d7f09 Author: Andriy Gapon AuthorDate: 2024-02-18 13:55:20 +0000 Commit: Andriy Gapon CommitDate: 2024-04-21 12:32:16 +0000 aw_gpio: temporarily switch to input function if read in eint mode This is needed for gpiokeys driver that needs to read input state after receiving an interrupt for either edge. PR: 248138 (cherry picked from commit b98558e69b0aefbb99120a8a6ca7efbb8cafab5b) --- sys/arm/allwinner/aw_gpio.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/arm/allwinner/aw_gpio.c b/sys/arm/allwinner/aw_gpio.c index 9d1defb5bf8c..5d0c3ded0c52 100644 --- a/sys/arm/allwinner/aw_gpio.c +++ b/sys/arm/allwinner/aw_gpio.c @@ -654,18 +654,30 @@ aw_gpio_pin_get_locked(struct aw_gpio_softc *sc,uint32_t pin, unsigned int *val) { uint32_t bank, reg_data; + int32_t func; + int err; AW_GPIO_LOCK_ASSERT(sc); if (pin > sc->conf->padconf->npins) return (EINVAL); + func = aw_gpio_get_function(sc, pin); + if (func == sc->conf->padconf->pins[pin].eint_func) { /* "pl_eintX */ + err = aw_gpio_set_function(sc, pin, AW_GPIO_INPUT); + if (err != 0) + return (err); + } + bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; reg_data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); *val = (reg_data & (1 << pin)) ? 1 : 0; + if (func == sc->conf->padconf->pins[pin].eint_func) + (void)aw_gpio_set_function(sc, pin, func); + return (0); } From nobody Sun Apr 21 14:10:19 2024 X-Original-To: dev-commits-src-branches@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 4VMqz01vP8z5H3NL; Sun, 21 Apr 2024 14:10:20 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMqz01R6xz47Zy; Sun, 21 Apr 2024 14:10:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713708620; 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=0VdKgSgX6Lm2e23Zen4zEfRktZDsJXnz5j3EUz9V0Uc=; b=OAytH+TD/BuR5tPaT/u7VL/m5UzuJI/TphHONZtwCon4P/y8RAh5fS71Wt7KH1cyzlp7v2 VykPg1o0w9VZHWRaMai70NpriMLxIvGN5J5oehOljAumiztXskF89H2qIEmMguYjsjG024 M0I9AqoB8U9Cs02ql4Uh3pL/IiwR8ajcd5rtrUml9cK8JQr01n1ypGikgpzvR3v5EiVwxM xSFvi1DzSfJyyTnBOFRFIuIGgve2JQJzKDqu3eN8vzK4WQTR7/zYBFVbfg3t+plAFRf+5w L7BO4DbJ9Xk70v8jde2PwIuYOnXBMvs5C3VATsTZ26un7gCNwVpyHTvCajn6/g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713708620; a=rsa-sha256; cv=none; b=mZWS8Zqw+CNKKmAChC/9vCpoOWSZMRLe/nFI1UAnivUAftjC9g+Wmb/OhUyZH+txUkoUEI I2CYFXz/tVtFeFxLV9ieM6D1Z5Dy8EpfP+C6foqa3/Lq3KvfYHqmW9XFStP/rzJf+2OCVf zZwya9wmC7PgNv6ZAKiUeQXRYiYG467uCDWK4tkDonLc17uPl3AW/rhhc/mYEBlPaRH24K rMhM0VHfFefnCp4ksoVtQmGQrQVBGTulTV5XuzDyiYf4LNlXMZREZ6avbhpZWSzzWzMslG FKseffsKQDk/PRZ96qqSCK1g+rdjiQq/f3PYW5Krw1qL6qOaVveSY2sWlrtqaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713708620; 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=0VdKgSgX6Lm2e23Zen4zEfRktZDsJXnz5j3EUz9V0Uc=; b=ox7i02foSTB3Je+fQRiOjTk+fZfOHMMewjWMAWHmDnoI02Vj4foZsbfErDbSe/JWdB/Zcs BYsvFDd6wURrTR0M7Dy7Z+LN0OIPW+TVxbDy9m32QN7XMFlodO19fICA1kGZOaN2fgU7e1 9cq3V/JJlPLYhz6Y0Q/90A36uS0oeUdlhkJ1eh8Q8HM5XPgw/T8AooCP8nAJq76SNfZGvD MsqopeAt71EvHyQoU0R9GZypG2l+3P8RdMIXPh1NrW4BIbIPQhVJQfq1yLcfxETjOQPPYE 9XRcbadkvv9EVfU4t85P6qA65a8IPfMwrh6szb6pQerw9S3eDZ3mvdN3VjVoYw== 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 4VMqz00wPkz1Mb9; Sun, 21 Apr 2024 14:10:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LEAJVp029075; Sun, 21 Apr 2024 14:10:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LEAJrn029072; Sun, 21 Apr 2024 14:10:19 GMT (envelope-from git) Date: Sun, 21 Apr 2024 14:10:19 GMT Message-Id: <202404211410.43LEAJrn029072@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 61ddfc0e55b4 - stable/14 - fusefs: only test for incoherency if FN_SIZECHANGE is set List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 61ddfc0e55b4fcdf4fd07a9764404760eecf2419 Auto-Submitted: auto-generated The branch stable/14 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=61ddfc0e55b4fcdf4fd07a9764404760eecf2419 commit 61ddfc0e55b4fcdf4fd07a9764404760eecf2419 Author: Emil Tsalapatis AuthorDate: 2024-02-08 01:13:43 +0000 Commit: Alan Somers CommitDate: 2024-04-21 14:09:43 +0000 fusefs: only test for incoherency if FN_SIZECHANGE is set FUSE emits spurious incoherency warnings in writethrough mode. The warnings are triggered by setattr calls generated by vnode truncation turning the cached va_size vattr stale, causing comparisons with the fresh version provided by the server to fail. Only validate the vnode's va_size vattr if the FN_SIZECHANGE flag is set. This is a part of the research work at RCSLab, University of Waterloo. Reviewed by: asomers Pull Request: https://github.com/freebsd/freebsd-src/pull/1110 (cherry picked from commit 8758bf0aaec1d4b2ebcb429e8cabc691c2c95461) --- sys/fs/fuse/fuse_internal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/fs/fuse/fuse_internal.c b/sys/fs/fuse/fuse_internal.c index 2d1c729a395a..30e3cebfa500 100644 --- a/sys/fs/fuse/fuse_internal.c +++ b/sys/fs/fuse/fuse_internal.c @@ -270,10 +270,10 @@ fuse_internal_cache_attrs(struct vnode *vp, struct fuse_attr *attr, if (vnode_isreg(vp) && fvdat->cached_attrs.va_size != VNOVAL && + fvdat->flag & FN_SIZECHANGE && attr->size != fvdat->cached_attrs.va_size) { - if ( data->cache_mode == FUSE_CACHE_WB && - fvdat->flag & FN_SIZECHANGE) + if (data->cache_mode == FUSE_CACHE_WB) { const char *msg; From nobody Sun Apr 21 14:11:06 2024 X-Original-To: dev-commits-src-branches@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 4VMqzt26Jyz5H3b1; Sun, 21 Apr 2024 14:11:06 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMqzt1fgdz49BT; Sun, 21 Apr 2024 14:11:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713708666; 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=GKZuiHyqmsCZn5Dib/Plj1K9AGR8vlDREUqh8If/hZU=; b=UF87uGWtuwmREQCsDUkI7lQf7wY6qsjK5yy5R3fk5VmGG0vL+oKCyOAXJbRor8fH8Vy8O7 w+MaNzgXaojoI2tcWG2/Yk5xaLyZ+qK6QtCLN+qU2m9YG9A6rBiiEkn6J6v9yMKz/+Kpmp smdQ3KpIHhZbOqF9DNdAEZEyJlCsgv2SJti9QjzN4kh25h623JtQwzHE0PoQ+T/CdBJyj7 yhW4ewAe3Sjc8l8LZuxayuc7kPCVNJoSqS+jNwfustShJFGhqlIePpUt0OzLWBLQTuxcUf NyRMICPRvpEWWILPu2mMBHJ2cqfaa7odhGQ+ZkXrLCFFmkx/12zjEiPPFLmuLg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713708666; a=rsa-sha256; cv=none; b=Gf4BdSYKufqB9MPwueYBOHvSb4OU7x+I/kpPajqMBsD0r64rDEgd7gTYEJHXeQtxHztZ2e 0jPcgXqLlxLJDbfrPCXrH/Rn5Mzd/DaTPTJpE0bnt2YHG1YsPZnpQs3UhGmgDQJ/7UYztu 6pQRjC4xn3aTaslSoSCmagGvAc0yjb/J+PDjBnOhtWRUk63fMcjLi0ooCPaxtaETmwG4sS WhN7Ogg3wAijwEzfK4PYs1048q3jceHD4dAbmtsXt8Y/J7covtVDM1AbzizQjt+DVknCOn Dn1Y+HikfdSzRyYuJS1DOOHrQNovntwCj3QRgbS/dYjmXQt4Ym+RPmVblj7+qA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713708666; 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=GKZuiHyqmsCZn5Dib/Plj1K9AGR8vlDREUqh8If/hZU=; b=Hjm+3UvZYmcDheW31jQ+5FQ5zjkRAiFLXOCnUABTRhleV68izp9ChuhFTCdLHoalCWsrsM v/sNYuZL+oFcs1HREsAj4y25Fs9gEPPBgXbrUuS/aBR6wy6KqFYJ0J9mcuxBG8IHwawW05 VzCoG8C1G+AQ9GH/t2cfxTveLnZjSNX28sN7bGpOUr6ezqcyvak5qyM/c4uQq+jZ58QW1J a4JHrg+9y/QkgHtjbpGXI4LDlChWxQmjOqQbPCGvsZrBRHVvLIuRmRRvpKU8ipylH9z5Tu gkYbjnjhsdFmIU1jmIZfE+yuAFqp4ESA6Wkagw3IDNOYF/U7JsNP3WpnQrF+tg== 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 4VMqzt1G4fz1MLP; Sun, 21 Apr 2024 14:11:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LEB6iK031021; Sun, 21 Apr 2024 14:11:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LEB6fR031018; Sun, 21 Apr 2024 14:11:06 GMT (envelope-from git) Date: Sun, 21 Apr 2024 14:11:06 GMT Message-Id: <202404211411.43LEB6fR031018@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 2d19c2cd00b4 - stable/14 - fusefs: correct a comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2d19c2cd00b4f27c5680f912a1620309b32752c3 Auto-Submitted: auto-generated The branch stable/14 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=2d19c2cd00b4f27c5680f912a1620309b32752c3 commit 2d19c2cd00b4f27c5680f912a1620309b32752c3 Author: Alan Somers AuthorDate: 2024-04-04 20:18:56 +0000 Commit: Alan Somers CommitDate: 2024-04-21 14:10:47 +0000 fusefs: correct a comment [skip ci] Sponsored by: Axcient (cherry picked from commit c1326c01df81dd06739ddf1946e1968ddaba0c8e) --- sys/fs/fuse/fuse_node.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/fs/fuse/fuse_node.c b/sys/fs/fuse/fuse_node.c index 1ff67ecf74e4..297ea4a1fad2 100644 --- a/sys/fs/fuse/fuse_node.c +++ b/sys/fs/fuse/fuse_node.c @@ -113,14 +113,15 @@ SYSCTL_COUNTER_U64(_vfs_fusefs_stats, OID_AUTO, node_count, CTLFLAG_RD, int fuse_data_cache_mode = FUSE_CACHE_WT; /* - * DEPRECATED - * This sysctl is no longer needed as of fuse protocol 7.23. Individual + * OBSOLETE + * This sysctl is no longer needed as of fuse protocol 7.23. Now, individual * servers can select the cache behavior they need for each mountpoint: * - writethrough: the default * - writeback: set FUSE_WRITEBACK_CACHE in fuse_init_out.flags * - uncached: set FOPEN_DIRECT_IO for every file - * The sysctl is retained primarily for use by jails supporting older FUSE - * protocols. It may be removed entirely once FreeBSD 11.3 and 12.0 are EOL. + * The sysctl is retained primarily due to the enduring popularity of libfuse2, + * which is frozen at protocol version 7.19. As of 4-April-2024, 90% of + * FreeBSD ports that use libfuse still bind to libfuse2. */ SYSCTL_PROC(_vfs_fusefs, OID_AUTO, data_cache_mode, CTLTYPE_INT | CTLFLAG_MPSAFE | CTLFLAG_RW, From nobody Sun Apr 21 19:05:39 2024 X-Original-To: dev-commits-src-branches@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 4VMyWl5Lbmz5HXkw; Sun, 21 Apr 2024 19:05:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyWl4YtSz4f5r; Sun, 21 Apr 2024 19:05:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726339; 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=Y+cT4OrmK/DMAgZdpY+g6U/rWM8qb+jJlf/sEtO1V4M=; b=cG0NsqAe7Rs2+evIAdBmzGfmdehP160p6gl3Xg6inOhD1MnDPmKqD+cKQYsegKZmbaihrR 1ZJCA96ZBWkWNHyObCgRTHbSYLoyttjpSRlvLz5RK1yeeFg/2EFq8LqlubTOSYT/kb9SOS zmCBlaQPAzHaxlQuCn3fFbPA16sfr7cbCja+vMFtYnPGiCePlI3suTZfBvCx0dG3yMRqYi JkgxdzIgh6KVxGIULA1L+6tiubX3lHlf4tPsZ2m7t6sbtyOqL71VBCU5OMBt1KgAE0ZZb/ ayCLsaLrhG+rJ7KQAUmYQO9xJlTDaWzrgqkwysCIOUQQncCqDQNYgPz9KdKvsA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726339; a=rsa-sha256; cv=none; b=FRWJl4BOXRT0S4ACGgWOQutDUmJkkZ3vS4fNpYx1AdyTDNeK9E7t8l4S/ynBChP5a0WVG5 v4UdrPl9La0YAzbjRSOxJSpOD9gfa9y+ezrIwJRmqHuBJLuuLfjU6hOna4Oj8U2gQrTF4x 9d7ktJ1CFWw+RgIiFT8Ji7v4fOSz99sOBM1U4/S7q2exrH+aJh/ZHsT72y2X9Zq9M+3Yzs WtzDCxIc+q4BeG0XuU7tKFdmDrMaXGJ51TnVOKQscYQWTJSpXDjxGzlH1+8VtnPAa2ub7D WlXQI4BY1EcPKVho6lWvATCTlJiZiVP5Iv1iX1J5Dl4PTEpuccplrTuztLLX9Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726339; 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=Y+cT4OrmK/DMAgZdpY+g6U/rWM8qb+jJlf/sEtO1V4M=; b=ud1fCJ0ngHeLENGzKhIf9GSUPlruhY9lYGFLNT95Ic/m2QQX6le/6IY/579elsmeMczdu4 ozMx/XLxhaJIkAX0MHsnRkj0wXCe7nFbvZDz8ZwVny9B2oN1sotahV4FizK78jLcZfJyLQ nwpCZ4VN3OWSM31m7pUHXwDbgoMNDroxDVJ0cgW6Pay5stJ8liM0WQMJRiV4d/RmXf3sJJ UoA4GehZEQBlBg1oiaE9OFHLNsNc2jWMsf/Q0yug5KJ3gmDVcevzxNAWgg6SpgXRQGH6Ck KZXdo+v2RQDYmBzuF+nOdddgajDslZmC5T/zwJUrnzVKVXi98CUSyUA3nKbI7g== 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 4VMyWl49HnzGtJ; Sun, 21 Apr 2024 19:05:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ5dFf028891; Sun, 21 Apr 2024 19:05:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ5dvk028888; Sun, 21 Apr 2024 19:05:39 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:05:39 GMT Message-Id: <202404211905.43LJ5dvk028888@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: 2dff504999f5 - stable/14 - share/mk/bsd.cpu.mk: add F16C feature for i386 and amd64 architectures List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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/14 X-Git-Reftype: branch X-Git-Commit: 2dff504999f570d45e969f62a3911f5d8310ab21 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=2dff504999f570d45e969f62a3911f5d8310ab21 commit 2dff504999f570d45e969f62a3911f5d8310ab21 Author: Dimitry Andric AuthorDate: 2024-04-18 17:46:57 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 18:44:21 +0000 share/mk/bsd.cpu.mk: add F16C feature for i386 and amd64 architectures As discussed in bug 278417, some ports require the F16C instruction set to compile, but there is no way yet to detect whether the currently chosen CPUTYPE supports this feature. Add the feature to the MACHINE_CPU variable, for each processor that supports it. The list of processors was extracted from clang 18's -dM output, filtered on the __F16C__ define. PR: 278417 Reviewed by: brooks, emaste MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D44848 (cherry picked from commit 2fd73b7126d7d7e5701e001af929411ce7a0c5f1) --- share/mk/bsd.cpu.mk | 42 ++++++++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index 3fee105e901d..730e4b4aa152 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -149,17 +149,18 @@ _CPUCFLAGS = -mcpu=${CPUTYPE} ########## i386 . if ${MACHINE_CPUARCH} == "i386" . if ${CPUTYPE} == "znver4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "bdver4" -MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 -. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" || \ - ${CPUTYPE} == "bdver1" +MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c +. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" +MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c +. elif ${CPUTYPE} == "bdver1" MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "btver2" -MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "btver1" MACHINE_CPU = ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "amdfam10" @@ -186,12 +187,14 @@ MACHINE_CPU = k5 i586 ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ ${CPUTYPE} == "x86-64-v4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ ${CPUTYPE} == "x86-64-v3" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 -. elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c +. elif ${CPUTYPE} == "ivybridge" +MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c +. elif ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \ @@ -232,17 +235,18 @@ MACHINE_CPU += i486 ########## amd64 . elif ${MACHINE_CPUARCH} == "amd64" . if ${CPUTYPE} == "znver4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "bdver4" -MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 -. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" || \ - ${CPUTYPE} == "bdver1" +MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c +. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" +MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 f16c +. elif ${CPUTYPE} == "bdver1" MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 . elif ${CPUTYPE} == "btver2" -MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "btver1" MACHINE_CPU = ssse3 sse4a sse3 . elif ${CPUTYPE} == "amdfam10" @@ -259,12 +263,14 @@ MACHINE_CPU = k8 3dnow ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ ${CPUTYPE} == "x86-64-v4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 f16c . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ ${CPUTYPE} == "x86-64-v3" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 -. elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 f16c +. elif ${CPUTYPE} == "ivybridge" +MACHINE_CPU = avx sse42 sse41 ssse3 sse3 f16c +. elif ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \ From nobody Sun Apr 21 19:06:38 2024 X-Original-To: dev-commits-src-branches@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 4VMyXt3jg0z5HXr7; Sun, 21 Apr 2024 19:06:38 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyXt31Zfz4fCs; Sun, 21 Apr 2024 19:06:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726398; 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=kMBirUWdxQaBpkW+YWDlPmLxDXelztfaesv9Awby2jQ=; b=YpbnafK2XgZJLmjApbbTgzPI8qjF0KE1y2/W6mXyn6jZw18VAm4FzaUi9zhRdknxX59fJC FnADIqd0vPvmSh5KBrjxQ8mt0UVnTw09zW2rStDhl32Bdo7hZ4G9Wi6PvYd67xQtbOvUZz UlaBuXFF/TlHFZLsZoOW0xQjOlZK7fvKMJ2IYmsXvBtUgH8S/zQa8rfyyo4b3QTvZoY3WE Ut3P0GWzwTZnIXXmDIU+D7L0BYi8JQSO0LZOsT0Vx3xJipzNUosFWXEOedWF0QKMRsuhVD dmFjbWQRCtnaZpd7EOIVTpYUrwPti6XyNQmsu7oLSyRBxrX8fSGgSZjrOWUGXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726398; a=rsa-sha256; cv=none; b=nHOYphf+WF+ZGJaK01K0vHSnntxfpURx3zVuHWn8s6g7yZYuSfrb8rTH4rJEphXbktnxhb xqZQGd5koD4MZ5LuhAHnlKZHMBDcCs7lv7utVmLrPr6tb9eCUEuYQmCII5SXBzu7Mrc/4G sZpqDoJc2JYryVyKpvzQVQYkmiG35N2uoaNZHaoj8emBZY8ohNqkdidBiFXjSS1AUNL/Zx v6hPgsD6TTPFk8zlA9wUPd6/OEV1n5KOqqToye4se6LkHT3lYtu5nqhx8lOTLQlmAfl9Qz eNJZUnila2aHEylzSvfS2YKuJHeUw5a4KpGjqX6J3hFIecWtI3EFVC4LdutzAQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726398; 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=kMBirUWdxQaBpkW+YWDlPmLxDXelztfaesv9Awby2jQ=; b=TfTey10yYso2dMGMKZmyDacllZIZ3JHCzCiOwGqa9MdhWdOBVtHmpcFp2ULDZRgcmB1ujo fnzmG4Pn9Zzw+SM4dubNc6bfCs/eSH69pa4yF/fO++qAKjWt0fd8GDjcDH4CefOkc7/z8R QHg6RqXWyEltElmq1oZdRcSOWGVF6oifyv06SkFqzh+BIifzjdMvXl1MawCqL+5N0BPYD5 eaYgOWpYfblaZrrDRcv5GLKObaws1bOi5eXpqWPnLqhHZ1jt38dJ4GhbaBbwEIXY9GVGCG yhqU8RrO59SeibwKo/ZyP7owm7TFvrpxR5qr3ba68BxQzVsRlnmuCdjBk3VcXA== 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 4VMyXt2cg4zGkr; Sun, 21 Apr 2024 19:06:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ6cPr029183; Sun, 21 Apr 2024 19:06:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ6c74029180; Sun, 21 Apr 2024 19:06:38 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:06:38 GMT Message-Id: <202404211906.43LJ6c74029180@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: 562855795e7f - stable/13 - Catch up with Clang 12. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 562855795e7f5b31e9a361dcd7f9f191cb5fb23f Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=562855795e7f5b31e9a361dcd7f9f191cb5fb23f commit 562855795e7f5b31e9a361dcd7f9f191cb5fb23f Author: Jung-uk Kim AuthorDate: 2021-06-14 22:42:59 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 19:02:07 +0000 Catch up with Clang 12. Add "znver3" for AMD and "alderlake" and "sapphirerapids" for Intel. (cherry picked from commit 09e7341c5ea40120bd1850c48c44bfbae5475f3f) --- share/examples/etc/make.conf | 18 +++++++++--------- share/mk/bsd.cpu.mk | 12 ++++++++---- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/share/examples/etc/make.conf b/share/examples/etc/make.conf index 6bc14d5be10f..9c3bb4d19442 100644 --- a/share/examples/etc/make.conf +++ b/share/examples/etc/make.conf @@ -29,19 +29,19 @@ # NO_CPU_CFLAGS variable below. # Currently the following CPU types are recognized: # Intel x86 architecture: -# (AMD CPUs) znver2, znver1, bdver4, bdver3, bdver2, bdver1, +# (AMD CPUs) znver3, znver2, znver1, bdver4, bdver3, bdver2, bdver1, # btver2, btver1, amdfam10, opteron-sse3, athlon64-sse3, # k8-sse3, opteron, athlon64, athlon-fx, k8, athlon-mp, # athlon-xp, athlon-4, athlon-tbird, athlon, k7, geode, # k6-3, k6-2, k6 -# (Intel CPUs) tigerlake, cooperlake, cascadelake, tremont, -# goldmont-plus, icelake-server, icelake-client, -# cannonlake, knm, skylake-avx512, knl, goldmont, -# skylake, broadwell, haswell, ivybridge, sandybridge, -# westmere, nehalem, silvermont, bonnell, core2, core, -# nocona, pentium4m, pentium4, prescott, pentium3m, -# pentium3, pentium-m, pentium2, pentiumpro, pentium-mmx, -# pentium, i486 +# (Intel CPUs) alderlake, sapphirerapids, tigerlake, cooperlake, +# cascadelake, tremont, goldmont-plus, icelake-server, +# icelake-client, cannonlake, knm, skylake-avx512, knl, +# goldmont, skylake, broadwell, haswell, ivybridge, +# sandybridge, westmere, nehalem, silvermont, bonnell, +# core2, core, nocona, pentium4m, pentium4, prescott, +# pentium3m, pentium3, pentium-m, pentium2, pentiumpro, +# pentium-mmx, pentium, i486 # (VIA CPUs) c7, c3-2, c3 # ARM architecture: armv5, armv5te, armv6, armv6t2, arm1176jzf-s, armv7, # armv7-a, armv7ve, generic-armv7-a, cortex-a5, diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index 2e35501c4126..51f9547c399f 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -159,7 +159,8 @@ _CPUCFLAGS = -mcpu=${CPUTYPE} ########## i386 . if ${MACHINE_CPUARCH} == "i386" -. if ${CPUTYPE} == "znver2" || ${CPUTYPE} == "znver1" +. if ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ + ${CPUTYPE} == "znver1" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "bdver4" MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 @@ -188,7 +189,8 @@ MACHINE_CPU = 3dnow mmx k6 k5 i586 MACHINE_CPU = mmx k6 k5 i586 . elif ${CPUTYPE} == "k5" MACHINE_CPU = k5 i586 -. elif ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ +. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "sapphirerapids" || \ + ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ ${CPUTYPE} == "cascadelake" || ${CPUTYPE} == "icelake-server" || \ ${CPUTYPE} == "icelake-client" || ${CPUTYPE} == "cannonlake" || \ ${CPUTYPE} == "knm" || ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" @@ -235,7 +237,8 @@ MACHINE_CPU = mmx MACHINE_CPU += i486 ########## amd64 . elif ${MACHINE_CPUARCH} == "amd64" -. if ${CPUTYPE} == "znver2" || ${CPUTYPE} == "znver1" +. if ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ + ${CPUTYPE} == "znver1" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 . elif ${CPUTYPE} == "bdver4" MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 @@ -254,7 +257,8 @@ MACHINE_CPU = k8 3dnow sse3 . elif ${CPUTYPE} == "opteron" || ${CPUTYPE} == "athlon64" || \ ${CPUTYPE} == "athlon-fx" || ${CPUTYPE} == "k8" MACHINE_CPU = k8 3dnow -. elif ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ +. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "sapphirerapids" || \ + ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ ${CPUTYPE} == "cascadelake" || ${CPUTYPE} == "icelake-server" || \ ${CPUTYPE} == "icelake-client" || ${CPUTYPE} == "cannonlake" || \ ${CPUTYPE} == "knm" || ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" From nobody Sun Apr 21 19:06:39 2024 X-Original-To: dev-commits-src-branches@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 4VMyXv5g59z5HXg3; Sun, 21 Apr 2024 19:06:39 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyXv3hqdz4fVV; Sun, 21 Apr 2024 19:06:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726399; 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=URuQVzJmer07Wx0lAiTqgOMk4dDmf2GYRB5c3G/ZTG4=; b=o0hCDv/qJrdZ0L8UtuZz7JwWY6AlZ0h5E2vinJy2F0U3q/E+J9/9BSPL1ZmL07Xk3vJ5ZD yT7y6p4SKSt4jTvZdptPjTN48q8ohnVZ7bmpJONnFL2uTwvnel3Qe5apqNGY9LA+7tqanu 320kY3URoUvAAQH1noY1EzRkgnl4lbymZEutx1pFtyy5QU38ZERe2wxLyr2m075AjCl9I1 Nwbyg0/Q3ZGYQAats/egAFhY2+6+2tK80bKnVW5kmQo7xrCxVDqs/wLalk+RjcxkaUVhLL FbC3oxviQqHgUqAH67ehgL8njUSX0dgsQxrK88vHztRuZMT1Ud2+8JOW4c5+sQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726399; a=rsa-sha256; cv=none; b=ocCbkDmCMTbBevrQ7rxPSiqKsSFlBoRQW365mjsiJoezZFiJKbrKVrRZOc/E9CavFBZJaB ZA6FEXEFWfjzG9mxQaBxCVNuYS1or1Nn1urC4l2iuPDTnAF/l2pUaPfIlpMKX1qlj5XkFI NSWwDHR4NGknXvTwBrnxIN0KhTM5SsgrMwjcvtYZ0wex0h2HRcj4jr0eXbSZ0N2HGNMfW+ 6K/nJFNWdZRhJOsE+lnDWoII4eyOiiQOA3MKDznzhTU3lbBf+Gbd1H6SzTCuYAFkNpBCcA NEg7TIPvvr2lCIHUKHo90OIxrR/x5zfchJ5UBQSRm8wpErNn8oZAp6mmqCppzw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726399; 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=URuQVzJmer07Wx0lAiTqgOMk4dDmf2GYRB5c3G/ZTG4=; b=vOdvHL94OqVjSE7IsUkNZZqzASdXTxeTbgOH8e4jBD5l6NACZpwqabyPNUDCqxzUz5VNce rg7ziyoejwfjXqukXwJc3MZaJnaROEFfPh4RAV05lRWtmJ0OirqA0k21bXEBJ3+jh9Vdi3 824UqCNl7nKMvVlYblTpN9mG99DXFSwmsxAEvP7fCP1h58F9mjLmhBQxQzf0RfnO1txLDq za/XuMLFDTMuSY4ghb25FqkVmVVQPhhHqcU8xuDQ+dKgu/jP6YDjlPNtfYlU6/N/ChY9Nk PXhdkM/XBNi/Myx9Ap/52JAfV33w9cA4oApdioLDc21vOHb9qYtBdhmrpCErlQ== 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 4VMyXv3JgSzGks; Sun, 21 Apr 2024 19:06:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ6diQ029231; Sun, 21 Apr 2024 19:06:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ6djJ029228; Sun, 21 Apr 2024 19:06:39 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:06:39 GMT Message-Id: <202404211906.43LJ6djJ029228@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: 445aa3bcc50c - stable/13 - bsd.cpu.mk: Correct MACHINE_CPU for Intel Alder Lake List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: 445aa3bcc50ca2d924a7d5e9974aa7fc8d3c49cb Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=445aa3bcc50ca2d924a7d5e9974aa7fc8d3c49cb commit 445aa3bcc50ca2d924a7d5e9974aa7fc8d3c49cb Author: Jung-uk Kim AuthorDate: 2021-06-14 23:06:03 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 19:02:08 +0000 bsd.cpu.mk: Correct MACHINE_CPU for Intel Alder Lake Apparently Intel Alder Lake lacks AVX-512 instructions. Fixes: 09e7341c5ea4 "Catch up with Clang 12" (cherry picked from commit e80145525b54a90672d36c9a168d83d0c7cb8161) --- share/mk/bsd.cpu.mk | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index 51f9547c399f..08b98e824492 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -189,14 +189,14 @@ MACHINE_CPU = 3dnow mmx k6 k5 i586 MACHINE_CPU = mmx k6 k5 i586 . elif ${CPUTYPE} == "k5" MACHINE_CPU = k5 i586 -. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "sapphirerapids" || \ - ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ - ${CPUTYPE} == "cascadelake" || ${CPUTYPE} == "icelake-server" || \ - ${CPUTYPE} == "icelake-client" || ${CPUTYPE} == "cannonlake" || \ - ${CPUTYPE} == "knm" || ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" +. elif ${CPUTYPE} == "sapphirerapids" || ${CPUTYPE} == "tigerlake" || \ + ${CPUTYPE} == "cooperlake" || ${CPUTYPE} == "cascadelake" || \ + ${CPUTYPE} == "icelake-server" || ${CPUTYPE} == "icelake-client" || \ + ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ + ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 -. elif ${CPUTYPE} == "skylake" || ${CPUTYPE} == "broadwell" || \ - ${CPUTYPE} == "haswell" +. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ + ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 @@ -257,14 +257,14 @@ MACHINE_CPU = k8 3dnow sse3 . elif ${CPUTYPE} == "opteron" || ${CPUTYPE} == "athlon64" || \ ${CPUTYPE} == "athlon-fx" || ${CPUTYPE} == "k8" MACHINE_CPU = k8 3dnow -. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "sapphirerapids" || \ - ${CPUTYPE} == "tigerlake" || ${CPUTYPE} == "cooperlake" || \ - ${CPUTYPE} == "cascadelake" || ${CPUTYPE} == "icelake-server" || \ - ${CPUTYPE} == "icelake-client" || ${CPUTYPE} == "cannonlake" || \ - ${CPUTYPE} == "knm" || ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" +. elif ${CPUTYPE} == "sapphirerapids" || ${CPUTYPE} == "tigerlake" || \ + ${CPUTYPE} == "cooperlake" || ${CPUTYPE} == "cascadelake" || \ + ${CPUTYPE} == "icelake-server" || ${CPUTYPE} == "icelake-client" || \ + ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ + ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 -. elif ${CPUTYPE} == "skylake" || ${CPUTYPE} == "broadwell" || \ - ${CPUTYPE} == "haswell" +. elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ + ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 From nobody Sun Apr 21 19:06:40 2024 X-Original-To: dev-commits-src-branches@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 4VMyXx1Jc3z5HXHC; Sun, 21 Apr 2024 19:06:41 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyXw4dBmz4fjn; Sun, 21 Apr 2024 19:06:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726400; 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=x1X8bh49jbO4cLr+DkWmdb6tRkKs2KOJ/P24YoIjAjQ=; b=yazC/qoLcECydbQo0xH3S5xHm6TiS5XfxfwCrTfAj5OU6ez0mbiEcBr+l+kOhJDlfus7Yx o8sxx0Ao+vhOVtk/Mu0tpkhAEm3EwTUq8j8UGU+y7myHQjkYMuvzQZ2JARyCwkmMM31cHu 1CfrZKCkGHDYTYO5Tuh/N14xJUdJP/oOthGlTe5/lnh020Mn3kSw/OyuWLnIFmwHA3kcA8 e9pUPihlHwOOF84uVCacANxnDFWSt+/Gqf84z05/jzohAqxGAPt4tEUz6hqiowd/xGvMtJ CSeZ+p0ENDa+peUdBC9wxSRz2tItSMEfiLA2Oy1BElzK9NY/HH9yhycefbPnjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726400; a=rsa-sha256; cv=none; b=ifF3cwRSuoy4NKmvRhNfmlINZiVBMOpcjE7zPCxbiS8rEiZrnAV/+QTLMQzc9vrtXry59N +chVPBey6r5jDXo1OmVieIlh91LyQbNq+CU0Z/1LF05pqVTb1rsAPLuonTXG+vHzfdKRMl B8MdBgHyPZeqGuSG71cqm7ET27PhkHxwad5O5q4h43Umww3ag0HM5rlz/hW79GyNAhbRpl lSupstpQNAaY0/zpz1nGXzXA0jHEOnyeDbYaUcj+Exq8s7bovAQTa8fEJL4e8gBZfASHVS hlOfx03lEYES7e+OY397LkZCsdiA/759Y6bPCxZAoVfN5txY6E5Mi6vWYw1X4Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726400; 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=x1X8bh49jbO4cLr+DkWmdb6tRkKs2KOJ/P24YoIjAjQ=; b=vvqNJVZBb5PzUQLM6AAnrp2PW0J+gBpw0KeqiapvuOX9grYncJKCMQjWS7dzXTe+1B1rr7 QuvmDkpB/2/G1XAJgcPkhOOeIjR4GFaf67dij8pG6IG8uQBqm7xK1NfId8teiZBKu9uJ3m D+2FYFUeVsa/ZbXLPwLiKrVEP9Zs2yhSM6kum3EeA6Fxvdjfc3iFQc5heCj7OUaMxGBSiz m5Eft4E6R4lwXg/XsdpSSioHRI7VwabIs7sbqJdt+pdZnAUUYvI3ITOe1wFLMkAqSyNHUp rYIqFos48cZnBQEM3K/vyKBuk+456FtE61wQsGWROTRN93bzwAkABoDa5bVJpg== 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 4VMyXw3xPtzHR3; Sun, 21 Apr 2024 19:06:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ6eLD029289; Sun, 21 Apr 2024 19:06:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ6ePK029286; Sun, 21 Apr 2024 19:06:40 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:06:40 GMT Message-Id: <202404211906.43LJ6ePK029286@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: ce159ac62d6c - stable/13 - bsd.cpu.mk: add support for x86-64-v[234] levels as CPUTYPE List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: ce159ac62d6c8761fdbe43bfef601f0a85209a29 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=ce159ac62d6c8761fdbe43bfef601f0a85209a29 commit ce159ac62d6c8761fdbe43bfef601f0a85209a29 Author: Val Packett AuthorDate: 2021-08-06 13:33:37 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 19:02:08 +0000 bsd.cpu.mk: add support for x86-64-v[234] levels as CPUTYPE These are supported in LLVM 12 and GCC 11: https://github.com/llvm/llvm-project/commit/012dd42e027e https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=324bec558e95584e8c1997575ae9d75978af59f1 Differential Revision: https://reviews.freebsd.org/D29150 (cherry picked from commit 362fef2f4a9954c0f5eeecbe512cc5abbdc44263) --- share/mk/bsd.cpu.mk | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index 08b98e824492..67d817e11101 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -193,16 +193,19 @@ MACHINE_CPU = k5 i586 ${CPUTYPE} == "cooperlake" || ${CPUTYPE} == "cascadelake" || \ ${CPUTYPE} == "icelake-server" || ${CPUTYPE} == "icelake-client" || \ ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ - ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" + ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ + ${CPUTYPE} == "x86-64-v4" MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ - ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" + ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ + ${CPUTYPE} == "x86-64-v3" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \ - ${CPUTYPE} == "nehalem" || ${CPUTYPE} == "silvermont" + ${CPUTYPE} == "nehalem" || ${CPUTYPE} == "silvermont" || \ + ${CPUTYPE} == "x86-64-v2" MACHINE_CPU = sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "penryn" MACHINE_CPU = sse41 ssse3 sse3 sse2 sse i686 mmx i586 @@ -211,7 +214,7 @@ MACHINE_CPU = ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "yonah" || ${CPUTYPE} == "prescott" MACHINE_CPU = sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "pentium4" || ${CPUTYPE} == "pentium4m" || \ - ${CPUTYPE} == "pentium-m" + ${CPUTYPE} == "pentium-m" || ${CPUTYPE} == "x86-64" MACHINE_CPU = sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "pentium3" || ${CPUTYPE} == "pentium3m" MACHINE_CPU = sse i686 mmx i586 @@ -261,16 +264,19 @@ MACHINE_CPU = k8 3dnow ${CPUTYPE} == "cooperlake" || ${CPUTYPE} == "cascadelake" || \ ${CPUTYPE} == "icelake-server" || ${CPUTYPE} == "icelake-client" || \ ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ - ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" + ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ + ${CPUTYPE} == "x86-64-v4" MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ - ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" + ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ + ${CPUTYPE} == "x86-64-v3" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \ - ${CPUTYPE} == "nehalem" || ${CPUTYPE} == "silvermont" + ${CPUTYPE} == "nehalem" || ${CPUTYPE} == "silvermont" || \ + ${CPUTYPE} == "x86-64-v2" MACHINE_CPU = sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "penryn" MACHINE_CPU = sse41 ssse3 sse3 From nobody Sun Apr 21 19:06:41 2024 X-Original-To: dev-commits-src-branches@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 4VMyXy2mHLz5HX81; Sun, 21 Apr 2024 19:06:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyXx5skFz4fjx; Sun, 21 Apr 2024 19:06:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726401; 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=dFMsgnLa3kE8YUIl1j/paLXhysrO+Esf9jo6v3Ye4Bo=; b=eU1sPSd4YmxngHQ1Mjj65cVmUECraWUvC63xlF57Rnw4H4cXTg2vfixuu6dWft5RsU+mAF pJQD2ztM/dXXB/EdtOAjk+i9arwnAP+iwdXAbEcRk0eEENvorj7zQ1ABivjYJz7Wnc7pss yqfoGqDc3GOI5W8rnc6S12KI8KzZ0wfPr/zGj5dr5kUA+UeBG7DYj3l0bT349BvctdI7ie VB8c2MVQeUpje/FyKv6wnHs4NXu1zA1+doiKeXmfpmf3aCzKFh7DnBqrYPS7hY7Jy/iWuv /vaKo9kPeKg6qBGYqUJ/WP7VM3uAWGH0xZz5ISqSqXhe2suQKnoL18pyIel91g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726401; a=rsa-sha256; cv=none; b=KjceTnqbmodH8ScwkX25zD6ResTu1C3DViSOda1iiBWcNEemoq0tmNGX/nYnIutRzBOGIx cXARj6tNWjqKnBl5SpresqpqUK7bUc9DXVDM4rGAe5Pt6YyGCA1h39jXQij/RdMRsbG4eB FtZSkNHcJbIrcwLnFMtblONM1mOZe3yAKBtBNvJf2idqc/KWtIYhcLNEF/zaPELxJfosCp wyFacCnye9tC1XzgXnIyGQSkFD9sblUVFv22A3GcO1pXMcv1Q0qmXxos6lRf1ZUptoE5d5 +zInRvJmp8l63/kDUFNMYYweacOqaz5lbwg5bjgUDDyyLg5zmqgrIjl9XuGC2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726401; 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=dFMsgnLa3kE8YUIl1j/paLXhysrO+Esf9jo6v3Ye4Bo=; b=VaSi3QIx79nYhdeyM56tl7kD8fIH4DnEY5NODkeVd4pEEZ4SMYoHyfzVtjE4F8N/FxnfNX 4TU99RqfHiTmpQJd3gXETLXCj/N00g3UKaDlJfoy+Fiaa8gzlqgLGLTG1efQEtKNCojY1C PpQK23vMWeUj/hnmYx9AgMHOFBTAZeReutDhQpu+D/GprtAtpaWaeufd0m+keBFDh40aO2 /acPbkEo0bodPS87PE/eXPNDVO+NMBQlaaQwjMib/xN8SB36bs3K06+VKzPP2da7ncI701 T8XK1FwepxD9pRXzVfYgZut0WHYxfVX1zGlMiKVAh+mCVdwuJjNDb0IdaToeew== 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 4VMyXx5Dh3zHBk; Sun, 21 Apr 2024 19:06:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ6fhu029339; Sun, 21 Apr 2024 19:06:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ6fwH029336; Sun, 21 Apr 2024 19:06:41 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:06:41 GMT Message-Id: <202404211906.43LJ6fwH029336@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: a45dd984457f - stable/13 - share/mk/bsd.cpu.mk: Add AMD Zen 4 for x86 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: a45dd984457f9f1273b1b9cd2867be39cdf774b7 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a45dd984457f9f1273b1b9cd2867be39cdf774b7 commit a45dd984457f9f1273b1b9cd2867be39cdf774b7 Author: Daniel Engberg AuthorDate: 2023-08-20 21:54:19 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 19:02:09 +0000 share/mk/bsd.cpu.mk: Add AMD Zen 4 for x86 Main difference between older Zen variants is that this supports AVX-512 Reviewed by: imp (previous version), emaste Approved by: emaste Differential Revision: https://reviews.freebsd.org/D41331 (cherry picked from commit ed3fb74e44b9ef37837cebc5acfd7e68867206ca) --- share/mk/bsd.cpu.mk | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index 67d817e11101..c3c19e2befa4 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -159,7 +159,9 @@ _CPUCFLAGS = -mcpu=${CPUTYPE} ########## i386 . if ${MACHINE_CPUARCH} == "i386" -. if ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ +. if ${CPUTYPE} == "znver4" +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +. elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "bdver4" @@ -240,7 +242,9 @@ MACHINE_CPU = mmx MACHINE_CPU += i486 ########## amd64 . elif ${MACHINE_CPUARCH} == "amd64" -. if ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ +. if ${CPUTYPE} == "znver4" +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 +. elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 . elif ${CPUTYPE} == "bdver4" From nobody Sun Apr 21 19:06:42 2024 X-Original-To: dev-commits-src-branches@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 4VMyXz2CCCz5HXnR; Sun, 21 Apr 2024 19:06:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VMyXy6gDhz4frd; Sun, 21 Apr 2024 19:06:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726403; 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=pu09OavuUy8WOKR7QBmNxeuvlc5gPy37PjHk5MM/oaA=; b=EhH3JNnIQ4Nmfe+rNrGN1snCETEjWACYztOocuos8bT6iOr3WER/n0b9J/mWyPL+gPy+/v pbW7QbNIAUyVm8406hxWRidnv37/buVjHIfWD8TxEsy1TeaN8o1px+zP36v7Q8M+rLHF4Z +I9hGPD+IiEL4BuIb33A/vipHsqTdkGXJTdGzLroeE94/uLCTMuR6v5IUGZwZaKq8pi+39 fvuovbTEmJstyf3JCkJ6vALn4un2BpV9oPV5Xa3AKv5yhE3MemSR1QADe21IC+GXkRZJQF jFq6w1gnLnIdma/ARoky2Z1NgAP+IVaq+gf0YdFVVzH+/i4RhnJepZxTe6q+0Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713726402; a=rsa-sha256; cv=none; b=J/XlKfH1pMoXbW8hJiV/jKwS3XnmRWt7Laqe+SPuOavf2cdoW+O/Qxfii6VdSFxILmIZa2 /Pbe4V16v1ukzasDJS4q/ywxdnfd+h8iz2BksvrFAnH/FD3PpjAXeHwZHpRCtqYzz3jQE0 7HwGV1eSq5AMc4hq6OKMiG8aWgBmT9d0GTxd+6BWgbIEzmGDMWqNffVb8bUb4Wnklc+bXL GLsFklCDvk4wTA4IfuFpRsukbXT7wjHr6JV7IEzeGaIWFd1Z3mhCrRbNDORXb+/vH4XU3T Vk6ruLxR9WuHsGHRNsrHeWI226IdJ4WBm8iQVmNSErec/ECol9RC/TiObbED4Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713726402; 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=pu09OavuUy8WOKR7QBmNxeuvlc5gPy37PjHk5MM/oaA=; b=mp+OAPmXdJfvR/gKm0tzKdwep67rgCp1REaqFhWG2weyEL4zJmvYSbUvYL4YNgJvzUI5A4 0MPPetIU8FQbU9Ld1MeNbcfSJI4xbKPqIMXyxQV0k6bIDhvdSjNUlM8BA4PsUFHRds5X14 pI/mMLNiggsJYo+clHVhyYEt12SYvBL+kIRGSIAaHxMGNTnF6buklqwI4LvM9ZxaslGWKg 56pMLXUbqJiW2XNAhN4gxf71vEYvTG89bI3+2Fk54d8S6rkm2rxmAy1Yq/fJLRzVOG8oz9 MmuAyAqZKmHOD+sTW35zBf+10Ab1n99wIijEveiPxZritSMXYnwsStAm7m7cag== 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 4VMyXy6H9lzGtM; Sun, 21 Apr 2024 19:06:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43LJ6ggY029393; Sun, 21 Apr 2024 19:06:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43LJ6gjp029390; Sun, 21 Apr 2024 19:06:42 GMT (envelope-from git) Date: Sun, 21 Apr 2024 19:06:42 GMT Message-Id: <202404211906.43LJ6gjp029390@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: b449894978b5 - stable/13 - share/mk/bsd.cpu.mk: add F16C feature for i386 and amd64 architectures List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: b449894978b56651bc8d2a19b03c4af67e4ec59c Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=b449894978b56651bc8d2a19b03c4af67e4ec59c commit b449894978b56651bc8d2a19b03c4af67e4ec59c Author: Dimitry Andric AuthorDate: 2024-04-18 17:46:57 +0000 Commit: Dimitry Andric CommitDate: 2024-04-21 19:02:09 +0000 share/mk/bsd.cpu.mk: add F16C feature for i386 and amd64 architectures As discussed in bug 278417, some ports require the F16C instruction set to compile, but there is no way yet to detect whether the currently chosen CPUTYPE supports this feature. Add the feature to the MACHINE_CPU variable, for each processor that supports it. The list of processors was extracted from clang 18's -dM output, filtered on the __F16C__ define. PR: 278417 Reviewed by: brooks, emaste MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D44848 (cherry picked from commit 2fd73b7126d7d7e5701e001af929411ce7a0c5f1) --- share/mk/bsd.cpu.mk | 42 ++++++++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk index c3c19e2befa4..2e2ec9d82af9 100644 --- a/share/mk/bsd.cpu.mk +++ b/share/mk/bsd.cpu.mk @@ -160,17 +160,18 @@ _CPUCFLAGS = -mcpu=${CPUTYPE} ########## i386 . if ${MACHINE_CPUARCH} == "i386" . if ${CPUTYPE} == "znver4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "bdver4" -MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 -. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" || \ - ${CPUTYPE} == "bdver1" +MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c +. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" +MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c +. elif ${CPUTYPE} == "bdver1" MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "btver2" -MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 +MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 f16c . elif ${CPUTYPE} == "btver1" MACHINE_CPU = ssse3 sse4a sse3 sse2 sse mmx k6 k5 i586 . elif ${CPUTYPE} == "amdfam10" @@ -197,12 +198,14 @@ MACHINE_CPU = k5 i586 ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ ${CPUTYPE} == "x86-64-v4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ ${CPUTYPE} == "x86-64-v3" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 -. elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c +. elif ${CPUTYPE} == "ivybridge" +MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 f16c +. elif ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 sse2 sse i686 mmx i586 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \ @@ -243,17 +246,18 @@ MACHINE_CPU += i486 ########## amd64 . elif ${MACHINE_CPUARCH} == "amd64" . if ${CPUTYPE} == "znver4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "znver3" || ${CPUTYPE} == "znver2" || \ ${CPUTYPE} == "znver1" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "bdver4" -MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 -. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" || \ - ${CPUTYPE} == "bdver1" +MACHINE_CPU = xop avx2 avx sse42 sse41 ssse3 sse4a sse3 f16c +. elif ${CPUTYPE} == "bdver3" || ${CPUTYPE} == "bdver2" +MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 f16c +. elif ${CPUTYPE} == "bdver1" MACHINE_CPU = xop avx sse42 sse41 ssse3 sse4a sse3 . elif ${CPUTYPE} == "btver2" -MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 +MACHINE_CPU = avx sse42 sse41 ssse3 sse4a sse3 f16c . elif ${CPUTYPE} == "btver1" MACHINE_CPU = ssse3 sse4a sse3 . elif ${CPUTYPE} == "amdfam10" @@ -270,12 +274,14 @@ MACHINE_CPU = k8 3dnow ${CPUTYPE} == "cannonlake" || ${CPUTYPE} == "knm" || \ ${CPUTYPE} == "skylake-avx512" || ${CPUTYPE} == "knl" || \ ${CPUTYPE} == "x86-64-v4" -MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 +MACHINE_CPU = avx512 avx2 avx sse42 sse41 ssse3 sse3 f16c . elif ${CPUTYPE} == "alderlake" || ${CPUTYPE} == "skylake" || \ ${CPUTYPE} == "broadwell" || ${CPUTYPE} == "haswell" || \ ${CPUTYPE} == "x86-64-v3" -MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 -. elif ${CPUTYPE} == "ivybridge" || ${CPUTYPE} == "sandybridge" +MACHINE_CPU = avx2 avx sse42 sse41 ssse3 sse3 f16c +. elif ${CPUTYPE} == "ivybridge" +MACHINE_CPU = avx sse42 sse41 ssse3 sse3 f16c +. elif ${CPUTYPE} == "sandybridge" MACHINE_CPU = avx sse42 sse41 ssse3 sse3 . elif ${CPUTYPE} == "tremont" || ${CPUTYPE} == "goldmont-plus" || \ ${CPUTYPE} == "goldmont" || ${CPUTYPE} == "westmere" || \