From nobody Sun Apr 07 09:24:21 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VC6HV23WQz5Gf8M; Sun, 7 Apr 2024 09:24: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 4VC6HV0BZCz4n8v; Sun, 7 Apr 2024 09:24:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1712481862; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hCbHa6IGQmfLAkC/gP04X9tjRdelceHxo/jvmL0hwmg=; b=ffbr0UIot0GGWVPgEbmhNgOOopCwwH733ah/Q015BsWnS9+gkFPnVnIl90+gD+kArsDS6E 9d7IdA9laYkuBNqgW6XbL0PTUhizqx20R2Ebkuid2yrI40X8m5v21jiPXx8QwoyIYbwfuF 0MouA7jtk4deCAe0tGsVUKvTJHXyfSfO63SZ7oWSKNjfN+zIDlMY6zTbY0rda4M4LZWpER VAI/0v57nAT46bCdKTZgCviePp0CkVwW8CFWg6CFbgZFKp8Ynv2oxSn//jeNpXmz79nKNr kdYWtLVANmjA4F9vfWIbWlJ1f6vPGWKB4+KDKt+QRMDGdzpkyFugVwiE045ZBQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1712481862; a=rsa-sha256; cv=none; b=TlaZ/QHUNzyF8TPpO86jyONow008N7u2pUzvIVMHCeSnuvSb2jCFBPrJ3LyIit5EXmP1E/ 2w/55uKNR9y631E30Vq4CcFp2rEMwh3Cps/L0ewWJgSxJ88RI88M8KLoQi2hWUEng2IqFk 7d7NMXIxLW/v+K4QhhRwi3eLzVQyHhD4i1McZLijpohrWCMJRnVWm0tLlTmYtPu7RoFMTv 6VJT6k1/fLBtVURFD4u+gORqKkPsCqVr9g7VPk8/QI+cLS5ufVs0Be0HrVk5aUUSvotx3l m4DZlIiDyVeJpqr9e16XvFuoPIh42nI3/wGoBNgogrqclyOUXB76rinSLzD/lg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1712481862; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hCbHa6IGQmfLAkC/gP04X9tjRdelceHxo/jvmL0hwmg=; b=nvO2gnyxuhR5OWPxWX2yLwf2zmuHpKpZ/80lsxv3abW5w7dGDEhIX3pGPwnIkymibr5g83 scrwr6i77VLKcTepaGyrn9aoDiqU1K1XRgx9WHG4ifCIgCzRVb+wnZfVCPbIhsbjZbztkG 3K+zew0iXt8AI3quwJ/F4uqVyQkqHWN3b2zlfwAoMaDNF1Vm71cd46QXqqPBcZUa5/O+f8 B4BKZd1hakQJqQJT8tzBBH44buIMHcCCuoD29PSuN8Xt8+U8zURWMf7hLouMycbH6RPF6l Z26jeuOsp7LgUS6nWZWiyNTxPo3WOt/Ydb+MRjcPZFF1mrEUQfdbNn8Xx+hsww== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VC6HT6wcWzMJL; Sun, 7 Apr 2024 09:24: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 4379OLC2064200; Sun, 7 Apr 2024 09:24:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 4379OLG7064197; Sun, 7 Apr 2024 09:24:21 GMT (envelope-from git) Date: Sun, 7 Apr 2024 09:24:21 GMT Message-Id: <202404070924.4379OLG7064197@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dimitry Andric Subject: git: 61e482f2fcd5 - main - Fix arm64 build after llvm 18.1.3 upgrade (take 2) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 61e482f2fcd53bbc7fd3d4cc8b7df79d5d57d75c Auto-Submitted: auto-generated The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=61e482f2fcd53bbc7fd3d4cc8b7df79d5d57d75c commit 61e482f2fcd53bbc7fd3d4cc8b7df79d5d57d75c Author: Dimitry Andric AuthorDate: 2024-04-07 09:23:06 +0000 Commit: Dimitry Andric CommitDate: 2024-04-07 09:23:06 +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 --- 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 749d5b81bfc8..f35cd960702b 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 0dd097eb3e0d..293a0ae1c0f9 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*:N-fno-sanitize*}" -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