From patchwork Fri May 5 10:53:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Szabolcs Nagy X-Patchwork-Id: 1777548 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=8.43.85.97; helo=sourceware.org; envelope-from=libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=Lr6onnEj; dkim-atps=neutral Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QCSHD2XSMz213r for ; Fri, 5 May 2023 20:54:16 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 61C303856DE7 for ; Fri, 5 May 2023 10:54:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 61C303856DE7 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1683284054; bh=P647dxwwd35lPUhpAoRsKy+MLw09bChumgx/8o5iJCk=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=Lr6onnEjhqlpeqndvIza40yAdnz4nOLuXLwD/yxD5folmyR2gh9TwR6MibSMi0o2V nTUx0/oJxfzO0tCSxtsr7q8h4J2bQwq4Ar5bfyOM0BIOuwH1aQsZzut6wElBQxbT6J 0sninrLsK5PJ3XXQekhWXpxi9el/zYM9+Yvalsbg= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on2077.outbound.protection.outlook.com [40.107.7.77]) by sourceware.org (Postfix) with ESMTPS id 7AA1C3858D20 for ; Fri, 5 May 2023 10:53:54 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7AA1C3858D20 Received: from AS9PR04CA0159.eurprd04.prod.outlook.com (2603:10a6:20b:530::20) by AS2PR08MB10206.eurprd08.prod.outlook.com (2603:10a6:20b:62f::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.22; Fri, 5 May 2023 10:53:49 +0000 Received: from AM7EUR03FT011.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:530:cafe::d5) by AS9PR04CA0159.outlook.office365.com (2603:10a6:20b:530::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.27 via Frontend Transport; Fri, 5 May 2023 10:53:49 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; pr=C Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM7EUR03FT011.mail.protection.outlook.com (100.127.140.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6387.12 via Frontend Transport; Fri, 5 May 2023 10:53:49 +0000 Received: ("Tessian outbound 3a01b65b5aad:v136"); Fri, 05 May 2023 10:53:49 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 5c9bea9b1f17cbe2 X-CR-MTA-TID: 64aa7808 Received: from 158ff9df1d5b.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id AF48FC91-8BB4-4A11-9FC4-45EB97CA37E0.1; Fri, 05 May 2023 10:53:42 +0000 Received: from EUR01-VE1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 158ff9df1d5b.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 05 May 2023 10:53:42 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=a/Dv6Pi1bOaVmhTJ9Pizi6MCeGJNNVNJBG4CIgOPrVyFL9sPR5qgwm43vW0K2I1KYi/nX0mfa921FrMM/eFLWMsO9Rx9k7zuLybSssxuUc9h6msIsG5i37FqY6f4HzHn6/xULYF+GQm+fZesbhkkMzifOG13ew3wqIj4QbWnf2aAvYnww9L94A3BN/u0OoTkfCgM7EM9MvzXPhP/AsXyFYXtAXi7e/2SEWGxFSB8+dxkkO7l7CaWKE3lf+hJpVK/cBMutDyJ5tPl4dKz7Xb9EHge2VVFQA6TkACI6yi4XCzWy9wWMLFXFM+DcuhVGrx22oNZ9Kr89xoveext8344fg== 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=P647dxwwd35lPUhpAoRsKy+MLw09bChumgx/8o5iJCk=; b=PW0PZ6jpiIHO5YvXJtczkg0Taqd9OydMhb8qLidufCSjHxLMCOPDWnl/j/W1KNvl7ZK2zwW/t7JGgfAzcuj1+sG9J2fnTJWU/L1OuaP0Sd3a0YSz/wTZmnlCh6s6rShulca50+CS5dsx6lsUZNZu/ASLThB4zHnx3h2sPr807N9ETRngmhsbszQcrhsV9Uerf5ouG6Ou22vuiBfHPVFoVibSmlQfvSwRNWntp4esYgLOlXYL5pxfDN/HoY+zxM4Tx6InbDFc+xkB21z1YXfpp16BGAGaD1cf6JgEKidMPbR2e/q7Ll0H+J6dCImhl91e23LpDkiHTg5Tfyu0AbnMAw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none Received: from DUZPR01CA0046.eurprd01.prod.exchangelabs.com (2603:10a6:10:469::14) by GV2PR08MB8100.eurprd08.prod.outlook.com (2603:10a6:150:7a::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.27; Fri, 5 May 2023 10:53:39 +0000 Received: from DBAEUR03FT005.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:469:cafe::ed) by DUZPR01CA0046.outlook.office365.com (2603:10a6:10:469::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.27 via Frontend Transport; Fri, 5 May 2023 10:53:39 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (40.67.248.234) by DBAEUR03FT005.mail.protection.outlook.com (100.127.142.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6363.27 via Frontend Transport; Fri, 5 May 2023 10:53:39 +0000 Received: from AZ-NEU-EX03.Arm.com (10.251.24.31) by AZ-NEU-EX04.Arm.com (10.251.24.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Fri, 5 May 2023 10:53:38 +0000 Received: from armchair.cambridge.arm.com (10.2.80.71) by mail.arm.com (10.251.24.31) with Microsoft SMTP Server id 15.1.2507.23 via Frontend Transport; Fri, 5 May 2023 10:53:38 +0000 To: Subject: [COMMITTED] aarch64: More configure checks for libmvec Date: Fri, 5 May 2023 11:53:37 +0100 Message-ID: <20230505105337.555134-1-szabolcs.nagy@arm.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DBAEUR03FT005:EE_|GV2PR08MB8100:EE_|AM7EUR03FT011:EE_|AS2PR08MB10206:EE_ X-MS-Office365-Filtering-Correlation-Id: 7c343307-d4a3-4267-15e9-08db4d57024c x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: R0x9HnQ8dvpD3VTqbP/ioHZ6lcdEUN0PM/gW5v1uYiGyVTNVXHGiV/913qz7aunuLNNB0T/qADCWbi54RNDDDebnT1WzS2YgVS00jcp8QFwc7DxvH8BS7wjuXxMmXHROo7wy7pyQDAMzqItL+3pF+/pY7IkusgysA1s3TV9kFvUGpPSzGfPmw/ZBxIzvrEfUzuqfH3+TCOA3pSoxWPO+Kf3F+nkjT6Z+chEpJ5hE535YYmo/FUTgKU0fkVMppGW/HFPi+5Aun3OKT7I4OW57Kwxt7OXf8NP7VbENNGuHVe7e9vzFNgtj8Qrzy06a8cn3iQOfUQEHmn9dG8ZD7U29TEE49OJdJEwRnFCrZXYqrHVaeHLOmOU4H8/6EynkpdJKaL7zwAPhWGy0Vvz3EWUvU33XLWNAquJ2z39SNsvxHAkCDT5Ifsb3HsJkyHAyxC4fGy83UmroZIziRqwZnbCwWsLPfK0aOov2EBREOMXCDMxGXhUWbkIofCLnmbxgNVGPqcO80PeaYWNJiIbhR8hRCKZFDz73/UCpNVJW8E5PHd3b6wjrRECRPsTT8OAAZrpWCZ9prnp4x2faEKvoblKr61VLW09yD5uQH/sLxrSd32gyjAv1o86ppexnr3q5rjYHqaBri6IUZ7sWACGmNNGuf6m48/xPsVi+sJ9SjTGis1Jd3LhZm91YBOjBNdsBFJaLhQPh65d2Urytixq33sjeATuzZ6bLI7LT+Ho/5auwyCfChL4mc4BANO6XMLDwHVp7/i7wqN5DMl1+UXWHoyJGBw== X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(136003)(39860400002)(376002)(396003)(346002)(451199021)(36840700001)(40470700004)(46966006)(41300700001)(2906002)(83380400001)(356005)(81166007)(40480700001)(36756003)(82310400005)(8676002)(8936002)(82740400003)(86362001)(44832011)(7696005)(478600001)(40460700003)(34020700004)(2616005)(426003)(336012)(47076005)(5660300002)(70206006)(70586007)(316002)(6916009)(36860700001)(26005)(186003)(1076003)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV2PR08MB8100 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM7EUR03FT011.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: ae90f831-4bf8-40b3-3870-08db4d56fbe9 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: pxylCF4CQIybxkir6GDWOCHGdN9cFRc4AsvqJmMBqRfX25cHx8xOAUfz+Y0JTaW6tvV5T/gcpHN7Mx/o4y6L9AyU4hgB+eUPZeqrDvSCTmyQJxC9nIrM+HWVvrS9VGjLxTLq8uc9JCYquD3cs63NM8MCpuzb+G9tZXn8XJjLyvpghfIJurVIdFLHqExhOLbeWF6miESYsLkj/waVvomK9ZAup8DtLWmh8praQfixgZk27KkZ5kv2h/0JpTyTC/8InuNB5YGs5EhDoHVsN4d/FLa5uFG/KaHjMJpRC4DoRXgr/QvcO1ZL2LL8fPkT841L+yBJc0C2R5oNLNORNmV1zivUjz9UFZa30si8SOymMWMMUi4GuoK+ZQK5S52VqXXl7nv4dPJ5aIa09oxHmA7tq35r59dqqOibH4zl4vzmX/NbWHY7fIIhJNAPuq2fd54diJNfMpMzPVW1Bc7GilX2jxomkYIMnyK26nQ2wVGnwGp9CH+1ew+yW6DY8PL2Fy6B6KVZw0qTORTC6XOmeS9mDe77Q/Kog13WyQQkvE8Z9/wxnO685kEUyzZdT6a4TvM7hwc5k7r3yIQtVJjzDNXRHNDGIyTAjPYzGRXycI74SuBtuDGkafvnAIeHVm60Q1ORWl9vIK+4fuBeu/m4hTePRz8vv/HvRgIfEjMX1lYpflfavV0ueEjKVyYPlhcWvmBw+GOTAjZ2FWK+u0QRMZ51cSBZP8mYaAOKjKDv7b69nxw= X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(13230028)(4636009)(39860400002)(376002)(136003)(346002)(396003)(451199021)(40470700004)(46966006)(36840700001)(336012)(2906002)(5660300002)(44832011)(36756003)(40460700003)(8676002)(8936002)(70586007)(70206006)(316002)(7696005)(41300700001)(82310400005)(40480700001)(478600001)(6916009)(86362001)(34020700004)(81166007)(47076005)(426003)(82740400003)(83380400001)(186003)(2616005)(1076003)(36860700001)(26005); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 May 2023 10:53:49.8466 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7c343307-d4a3-4267-15e9-08db4d57024c X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM7EUR03FT011.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS2PR08MB10206 X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FORGED_SPF_HELO, GIT_PATCH_0, KAM_DMARC_NONE, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Szabolcs Nagy via Libc-alpha From: Szabolcs Nagy Reply-To: Szabolcs Nagy Errors-To: libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org Sender: "Libc-alpha" Check assembler and linker support too, not just SVE ACLE in the compiler, since variant PCS requires at least binutils 2.32.1. --- sysdeps/aarch64/configure | 29 ++++++++++++++++++++++++++--- sysdeps/aarch64/configure.ac | 25 ++++++++++++++++++++++--- 2 files changed, 48 insertions(+), 6 deletions(-) diff --git a/sysdeps/aarch64/configure b/sysdeps/aarch64/configure index 030996c55a..5497dd397e 100644 --- a/sysdeps/aarch64/configure +++ b/sysdeps/aarch64/configure @@ -332,7 +332,7 @@ if test x"$build_mathvec" = xnotset; then build_mathvec=yes fi -# Check if compiler is sufficient to build mathvec (needs SVE ACLE) +# Check if compiler supports SVE ACLE. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for availability of SVE ACLE" >&5 $as_echo_n "checking for availability of SVE ACLE... " >&6; } if ${libc_cv_aarch64_sve_acle+:} false; then : @@ -355,6 +355,29 @@ EOF fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_aarch64_sve_acle" >&5 $as_echo "$libc_cv_aarch64_sve_acle" >&6; } -if test $build_mathvec = yes && test $libc_cv_aarch64_sve_acle = no; then - as_fn_error $? "mathvec is enabled but compiler does not have SVE ACLE. Either use a compatible compiler or configure with --disable-mathvec (this results in incomplete ABI)." "$LINENO" 5 + +# Check if compiler is sufficient to build mathvec +if test $build_mathvec = yes; then + fail=no + if test $libc_cv_aarch64_variant_pcs = no; then + fail=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: mathvec is enabled but linker does not support variant PCS." >&5 +$as_echo "$as_me: WARNING: mathvec is enabled but linker does not support variant PCS." >&2;} + fi + if test $libc_cv_aarch64_sve_asm = no; then + fail=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: mathvec is enabled but assembler does not support SVE." >&5 +$as_echo "$as_me: WARNING: mathvec is enabled but assembler does not support SVE." >&2;} + fi + if test $libc_cv_aarch64_sve_acle = no; then + fail=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: mathvec is enabled but compiler does not have SVE ACLE." >&5 +$as_echo "$as_me: WARNING: mathvec is enabled but compiler does not have SVE ACLE." >&2;} + fi + if test $fail = yes; then + as_fn_error $? "use a compatible toolchain or configure with --disable-mathvec (this results in incomplete ABI)." "$LINENO" 5 + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: mathvec is disabled, this results in incomplete ABI." >&5 +$as_echo "$as_me: WARNING: mathvec is disabled, this results in incomplete ABI." >&2;} fi diff --git a/sysdeps/aarch64/configure.ac b/sysdeps/aarch64/configure.ac index 76f78fcba9..27874eceb4 100644 --- a/sysdeps/aarch64/configure.ac +++ b/sysdeps/aarch64/configure.ac @@ -106,7 +106,7 @@ if test x"$build_mathvec" = xnotset; then build_mathvec=yes fi -# Check if compiler is sufficient to build mathvec (needs SVE ACLE) +# Check if compiler supports SVE ACLE. AC_CACHE_CHECK(for availability of SVE ACLE, libc_cv_aarch64_sve_acle, [dnl cat > conftest.c < @@ -117,6 +117,25 @@ EOF libc_cv_aarch64_sve_acle=no fi rm conftest.c]) -if test $build_mathvec = yes && test $libc_cv_aarch64_sve_acle = no; then - AC_MSG_ERROR([mathvec is enabled but compiler does not have SVE ACLE. Either use a compatible compiler or configure with --disable-mathvec (this results in incomplete ABI).]) + +# Check if compiler is sufficient to build mathvec +if test $build_mathvec = yes; then + fail=no + if test $libc_cv_aarch64_variant_pcs = no; then + fail=yes + AC_MSG_WARN([mathvec is enabled but linker does not support variant PCS.]) + fi + if test $libc_cv_aarch64_sve_asm = no; then + fail=yes + AC_MSG_WARN([mathvec is enabled but assembler does not support SVE.]) + fi + if test $libc_cv_aarch64_sve_acle = no; then + fail=yes + AC_MSG_WARN([mathvec is enabled but compiler does not have SVE ACLE.]) + fi + if test $fail = yes; then + AC_MSG_ERROR([use a compatible toolchain or configure with --disable-mathvec (this results in incomplete ABI).]) + fi +else + AC_MSG_WARN([mathvec is disabled, this results in incomplete ABI.]) fi