From patchwork Fri Nov 3 13:15:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Szabolcs Nagy X-Patchwork-Id: 161303 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp1046452vqu; Fri, 3 Nov 2023 06:52:29 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHCyyFx1UcO+ENbgnYKX9/g8FgUnNs+uMZMvyEEuUqZ5terUfAFgACa3wm6Y1xpirgZvgOS X-Received: by 2002:a05:6214:1cc5:b0:658:2220:d833 with SMTP id g5-20020a0562141cc500b006582220d833mr25023330qvd.0.1699019548714; Fri, 03 Nov 2023 06:52:28 -0700 (PDT) Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id e12-20020ad450cc000000b0066cfda15c48si1425035qvq.474.2023.11.03.06.52.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Nov 2023 06:52:28 -0700 (PDT) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=NqrJCutT; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=NqrJCutT; arc=fail (signature failed); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 899433858425 for ; Fri, 3 Nov 2023 13:52:27 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04on2076.outbound.protection.outlook.com [40.107.6.76]) by sourceware.org (Postfix) with ESMTPS id 4B1293858C50 for ; Fri, 3 Nov 2023 13:52:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4B1293858C50 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4B1293858C50 Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=40.107.6.76 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1699019540; cv=pass; b=uLRm4M0KqITI9kRGBkhANB+sqWHvYAf0K+ucoJPa05xj+Vq2c0mfOrV5hoiy5jpW+bGGYsVKAxRaa3EqGt63d07loFSL5KTYZcwQKOlI1mXOm9XnBs47tNmzC7JKvXQ7O5BZD/a5rvcnnMJiNoFs/iUwp7thXj9tclzKe/4YemA= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1699019540; c=relaxed/simple; bh=PB+qmqoxkslW/y3m9osa4TubXw6c+gkWOenI8J3MWWY=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=kyvtPCh4TunXXPoSvcrCyEoidVsQNyYtTHYA1sRK6vi6nGBjJCuq5QrqaGdD/bv0WDhfHR+j62qaRcWsXnDgjOIX8Bl7dgnrvHNXzSpRKjLZcytGHLqNeBneJ3uezdCPQ9k6ZGsshcQbQgWS07ujsvb0CJx7NBS2VjTCekYl6iA= ARC-Authentication-Results: i=3; server2.sourceware.org ARC-Seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=CswcnINcgQEwmH3t8nFxtEt+swyj2sg8LBjWuiYLYVBb/DLxqH6NG3iN6+OgbjdJmVtTXyOMtO05UNg8PSgMxVOHL/ww3Ij1b9hDp4Dt6DbfvgggkQGqLIlv8kfjrvGDpEBmXfTQA5DpchpMmvRxrJ+PdG6R7HbM1zwBZnKHKlUYdyp4Chs9mnDmiu194Zdws/wQ2bbX3rJCjh3WkuDo780glqg92VktzQdwAWcjucRSzjlhfQtxobPD/Ce13h2NjcPcopbcPlJvvV1F9vZ42yCcCsbCh39etdkImTX9NL6flM9M42Ohjm247N8RWSx7C40sz3zq7U18vVfce9ns3g== ARC-Message-Signature: i=2; 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=3AqEx0Fxl0OJ4+YvY1MFPN3kznMoURc3OcIY8tuGf98=; b=ZUybRS7nkeEinSs0W7hSGzaOQAQVrTXoOnnUBDbiMV45DnBnRJHTO+FljWT7nRJC3Ynj2PpGMCukt/JB9jQxeAinzC3oJ4ZOsPN/l5ufWrgqmue9bQuCoyftw5NWZEKQ6glNpQOZEypODNiy1gIpjX7Fbike2Cch7bBLsyZUOWykNKJtPlkIDOn/ma29MGhD0bWTFYHl2tLTHhBgNwGnFJbCqgXNGogmyuMV9qEswKbB5GIWaadAIOvkarRU+gsC96031YRiglXHKs+TH+/GxgV06n0Tkn54NpUhaOVXaWb2eB7SZEW1eCrWtEnjwDFoUoU5HMufIst5cXqrhzIGBA== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1, 1, smtp.mailfrom=arm.com] dmarc=[1, 1, header.from=arm.com]) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3AqEx0Fxl0OJ4+YvY1MFPN3kznMoURc3OcIY8tuGf98=; b=NqrJCutTHGU7WmURmZgC1WP3+aOZTdmvSH5h8leH+1r/9YCZkgxnG5Cm1mHfksXkEtqcVQcUtM8UGu3M3zmYaCzynz8VRpN0IAF3VTwJeNQ6ZbhAvks+4tmWH9RpnNv1YsF152jMOAaiWssGsYvCnqMQCl6et85skg4eU4AwqVQ= Received: from AS8P189CA0047.EURP189.PROD.OUTLOOK.COM (2603:10a6:20b:458::27) by DB9PR08MB7844.eurprd08.prod.outlook.com (2603:10a6:10:39f::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.21; Fri, 3 Nov 2023 13:52:07 +0000 Received: from AM4PEPF00027A6C.eurprd04.prod.outlook.com (2603:10a6:20b:458:cafe::bd) by AS8P189CA0047.outlook.office365.com (2603:10a6:20b:458::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.22 via Frontend Transport; Fri, 3 Nov 2023 13:52:07 +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 AM4PEPF00027A6C.mail.protection.outlook.com (10.167.16.90) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.19 via Frontend Transport; Fri, 3 Nov 2023 13:52:07 +0000 Received: ("Tessian outbound 8289ea11ec17:v228"); Fri, 03 Nov 2023 13:52:06 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 1084e87ff2ac7b63 X-CR-MTA-TID: 64aa7808 Received: from 6509518b4fa6.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 878355D3-D527-4DF7-87DF-574F602A8DC3.1; Fri, 03 Nov 2023 13:16:02 +0000 Received: from EUR05-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 6509518b4fa6.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 03 Nov 2023 13:16:02 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=a4HB1SwHfYWsXQ2j1kZngKKjhx4jrQV/4GNNzMg/vmoh+hyKWNgXgWV92zNYFJROQ0mNcM30kIOWCiP2LJlQm/G968Cr/2Q0LNHKe8qsg8fX540EC7iuXpYi8WFUULSRHiJakfYfCHz8Z2IJsFcLRJhtSWRVwSvF5WOiOJzA56lM9cyplrO25cEKYsS4ssXh+vLp8ifJE0Vhcy0Meu5y+LmHiI3yZlQmzTxgotOnilQrcnrvTpYNlXOOQUU/jIpzv4uQ39i8dIfsnZdPYf78rxp6X6Ws6ZZZ/yf7Y0uYqUidX+vhNBzpTx3/N30qq6tbGcKHyaaEP2zxI4LSAHczng== 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=3AqEx0Fxl0OJ4+YvY1MFPN3kznMoURc3OcIY8tuGf98=; b=CaZvBVZzkJE7Zev+NGISra1Jhb6vFfpWVWQBUn7DR7YT+ZmX6Xuz4CCPo5WUEfXsrud1oY/oPu0TAq1418NxPCxWdPRbF+b+DJJZXoMSRFiuldhfWrCBLc9SbvtkGx9UwIIu6XQn4uWs4Sh3HvWEHn+ssPJWxEX7CHmwydS/xpivRpPbLckwpaPoe2405/9IV63gP50Z6/oGyyj7YvgdFJNXOwzi0D7UZE3tE7DFcYI56uxmWj91BwfFKOL30/Z2/pAPCTACgwyJzsEkojZoJ0y1TIzFvhMQSedFSmTlksO7yW46OymWQi+sZOLA0MNdIAxQEHF2B8frQ9zWEJ33Fg== 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 (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3AqEx0Fxl0OJ4+YvY1MFPN3kznMoURc3OcIY8tuGf98=; b=NqrJCutTHGU7WmURmZgC1WP3+aOZTdmvSH5h8leH+1r/9YCZkgxnG5Cm1mHfksXkEtqcVQcUtM8UGu3M3zmYaCzynz8VRpN0IAF3VTwJeNQ6ZbhAvks+4tmWH9RpnNv1YsF152jMOAaiWssGsYvCnqMQCl6et85skg4eU4AwqVQ= Received: from DB8PR09CA0008.eurprd09.prod.outlook.com (2603:10a6:10:a0::21) by AS8PR08MB9930.eurprd08.prod.outlook.com (2603:10a6:20b:564::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.21; Fri, 3 Nov 2023 13:15:58 +0000 Received: from DU2PEPF0001E9C2.eurprd03.prod.outlook.com (2603:10a6:10:a0:cafe::7a) by DB8PR09CA0008.outlook.office365.com (2603:10a6:10:a0::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.21 via Frontend Transport; Fri, 3 Nov 2023 13:15:58 +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 DU2PEPF0001E9C2.mail.protection.outlook.com (10.167.8.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6954.19 via Frontend Transport; Fri, 3 Nov 2023 13:15:58 +0000 Received: from AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.32; Fri, 3 Nov 2023 13:15:57 +0000 Received: from AZ-NEU-EX03.Arm.com (10.251.24.31) by AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.32; Fri, 3 Nov 2023 13:15:57 +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.32 via Frontend Transport; Fri, 3 Nov 2023 13:15:57 +0000 From: Szabolcs Nagy To: Subject: [PATCH 5/5] ld: aarch64: Add BTI stub insertion test PR30930 Date: Fri, 3 Nov 2023 13:15:56 +0000 Message-ID: X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DU2PEPF0001E9C2:EE_|AS8PR08MB9930:EE_|AM4PEPF00027A6C:EE_|DB9PR08MB7844:EE_ X-MS-Office365-Filtering-Correlation-Id: e246f9ca-e47a-49f4-6658-08dbdc74117d 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: BzfQU/9QqJl++/rvTwJ+icGgjDhcSn7ItlKzuUB6HKMK9quwe5WJDqv/ZSvslEFvO3mzXAWYuDfYQ9a1pwVgCYLAADYn5IDqeaink6R6A79I8VWEdlDO/oD1JLdy3InjKq/91Vm6RujSUZm67p+Fe/VEvnUlVdjIoo7eUHhLHb2DQIe8EhgAy8mbV4Bju5p8bCggdaUjdcnILGrzmpYVzSg4O82S31//wbaDlzqxpR3g5n9DnMr65qk0WiodJW1U7xfj8oHo1F+gwddgqOpP0OX0si6zedYKjp8kMj3t2Rp/08QOn+wm0BeglUClAlamZFLdzLpF1xmUbY6ngz1P9w813MwRmE/J9SUJzkSP+uEerC61CyrA6fudBe1mBdWsVyH3IezSRmQeIag25x5BCCxJ0bRaD/K/2M17CXf0HK/7yhx44NCMJX0E3hqcEQgisEO8NfOuWSc0ahO+DTdS9AFO0rPivfSFJGYEh0tZ9fm0l5Rh40wwtTIg1YA3Qy4xVqHta16yOvWn1VjccAE03Vny/Qz45WfVOYxdoauRhxOXvMsvZIU1XLv4P+kUhgnK7JBCXF+kVnBxVL3qfDD7im0jM126gGDIykeRbVbCz62H/HSiw14qZBIpvH5ZYNZYwefS67obLuA8onncOHhkC9epRHu7FxJisxiyO7gB3KyeO6zCUF1+uKnJhSWGeGWskH9c4PGAmABoA6JqRcZYRdsZ8PQLQCROij2EM/GUp8d+fFidA8hbTrq/pWhQo3oNa7fgk41uZc2OSZhHFMsahQ== 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:(13230031)(4636009)(396003)(136003)(39860400002)(376002)(346002)(230922051799003)(451199024)(82310400011)(186009)(1800799009)(64100799003)(46966006)(36840700001)(40470700004)(40480700001)(478600001)(2906002)(40460700003)(36756003)(86362001)(70586007)(70206006)(5660300002)(47076005)(2616005)(41300700001)(26005)(44832011)(36860700001)(8936002)(336012)(8676002)(82740400003)(426003)(7696005)(6916009)(316002)(356005)(81166007)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB9930 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM4PEPF00027A6C.eurprd04.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 9dc20c53-e798-4807-f6f0-08dbdc6f04bc X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: KucqYVDjQaBWs6OI1s/0AYqKK1dnbwlfIFHVEMaatbYE5pfusNYcdbSPStLQOwxtiNfnscHHRCbSj2xKs7hG3T0RkC/J6AyR4WHJSKDbm7m8RPi1K1ARuvDLqB7UwhMOl0ayl79jvwJ9xDS3QhXgENskrWGhJ/4kcMiutxeVPmFm+DwPZH74alW57JwML+mUQfLY9GnhnwbeMqFgqB3HQX76ikjT+j/tidEcLKKR698izBvJwGmbdyn89Ztxhs4COjWCH0x33UGAmYZssnH+S9sBeQ+pg1NIVABcBy0kM6mR/GezvD/4Y5EcjsPrqSTGsu8MTeqaPPgSZIqKZqjrblsIhhb+MWbFbFfmDp3s1yLFLQB+L8zrvxyOssEHs46ZDWxrrARM+zDmCj21BECndjDZXyRM25tnng8YauRKyCDEup6w7WHUGVVE01HpzHzOiHYLKeMTytBZjk2+bx5hSuMnN4n53JGMHxcNtURq2T7WrE9CrRrElWoTgfG0dgsg6fB7f7D/xjoZvvIyC+k3dgm2TlyWADZDr68DmXnS17nNvEmrrMR5I1hKPHuJ8t5Bdh4X3ws6jvhlUpkxghDvsRW2DwYbGeKhBWMFKcYs4dsnuKEpe+lgwpeZ1JYc1L8jXlmgy3Z1ZUsY+S2CmO4TPMCiZ4i0YGAgzpds0uLcS+xvJGK/GXZUXaAzLEZJ2Qo1negAsb5T/0qn5mY2A7vLqE9fcc06+fjZtRx0R6wQstN7VNGwuBrWHgYy0uv8InlT 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:(13230031)(4636009)(39860400002)(136003)(376002)(346002)(396003)(230922051799003)(1800799009)(451199024)(64100799003)(82310400011)(186009)(40470700004)(36840700001)(46966006)(40460700003)(40480700001)(2616005)(26005)(478600001)(7696005)(36860700001)(47076005)(2906002)(426003)(8676002)(336012)(5660300002)(70206006)(41300700001)(44832011)(70586007)(316002)(6916009)(8936002)(81166007)(82740400003)(86362001)(36756003); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Nov 2023 13:52:07.0023 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e246f9ca-e47a-49f4-6658-08dbdc74117d 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: AM4PEPF00027A6C.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR08MB7844 X-Spam-Status: No, score=-11.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FORGED_SPF_HELO, GIT_PATCH_0, KAM_DMARC_NONE, KAM_NUMSUBJECT, 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: binutils@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781551122550814984 X-GMAIL-MSGID: 1781551122550814984 The test creates a large shared library and covers a number of BTI stub insertion cases. --- ld/testsuite/ld-aarch64/aarch64-elf.exp | 1 + ld/testsuite/ld-aarch64/bti-far-3.d | 87 +++++++++++++++++++++++++ ld/testsuite/ld-aarch64/bti-far-3.ld | 12 ++++ ld/testsuite/ld-aarch64/bti-far-3a.s | 23 +++++++ ld/testsuite/ld-aarch64/bti-far-3b.s | 25 +++++++ ld/testsuite/ld-aarch64/bti-far-3c.s | 24 +++++++ 6 files changed, 172 insertions(+) create mode 100644 ld/testsuite/ld-aarch64/bti-far-3.d create mode 100644 ld/testsuite/ld-aarch64/bti-far-3.ld create mode 100644 ld/testsuite/ld-aarch64/bti-far-3a.s create mode 100644 ld/testsuite/ld-aarch64/bti-far-3b.s create mode 100644 ld/testsuite/ld-aarch64/bti-far-3c.s diff --git a/ld/testsuite/ld-aarch64/aarch64-elf.exp b/ld/testsuite/ld-aarch64/aarch64-elf.exp index b025fcbd567..fa5ac3a2cdd 100644 --- a/ld/testsuite/ld-aarch64/aarch64-elf.exp +++ b/ld/testsuite/ld-aarch64/aarch64-elf.exp @@ -466,6 +466,7 @@ run_dump_test "undef-tls" run_dump_test "bti-far-1" run_dump_test "bti-far-2" run_dump_test "bti-far-opt" +run_dump_test "bti-far-3" if { ![skip_sframe_tests] } { run_dump_test "sframe-simple-1" diff --git a/ld/testsuite/ld-aarch64/bti-far-3.d b/ld/testsuite/ld-aarch64/bti-far-3.d new file mode 100644 index 00000000000..4c076985a0e --- /dev/null +++ b/ld/testsuite/ld-aarch64/bti-far-3.d @@ -0,0 +1,87 @@ +#name: Check linker stubs with indirect calls handle BTI (exe). +#source: bti-far-3a.s +#source: bti-far-3b.s +#source: bti-far-3c.s +#as: -mabi=lp64 +#ld: -shared -T bti-far-3.ld +#objdump: -dr + +[^:]*: *file format elf64-.*aarch64 + + +Disassembly of section \.plt: + +0000000000020000 <\.plt>: + 20000: d503245f bti c + 20004: a9bf7bf0 stp x16, x30, \[sp, #-16\]! + 20008: 900fff10 adrp x16, 20000000 <_GLOBAL_OFFSET_TABLE_> + 2000c: f9400e11 ldr x17, \[x16, #24\] + 20010: 91006210 add x16, x16, #0x18 + 20014: d61f0220 br x17 + 20018: d503201f nop + 2001c: d503201f nop + +0000000000020020 : + 20020: 900fff10 adrp x16, 20000000 <_GLOBAL_OFFSET_TABLE_> + 20024: f9401211 ldr x17, \[x16, #32\] + 20028: 91008210 add x16, x16, #0x20 + 2002c: d61f0220 br x17 + 20030: 14000004 b 20040 <__extern_func_bti_veneer\+0x8> + 20034: d503201f nop + +0000000000020038 <__extern_func_bti_veneer>: + 20038: d503245f bti c + 2003c: 17fffff9 b 20020 + +Disassembly of section \.text: + +0000000000030000 : + 30000: 15c00004 b 7030010 <__b_func_veneer> + 30004: 17ffc007 b 20020 + \.\.\. + 7030008: 1400000a b 7030030 <__a_func_bti_veneer\+0x8> + 703000c: d503201f nop + +0000000007030010 <__b_func_veneer>: + 7030010: 90040010 adrp x16, f030000 + 7030014: 9101e210 add x16, x16, #0x78 + 7030018: d61f0200 br x16 + \.\.\. + +0000000007030028 <__a_func_bti_veneer>: + 7030028: d503245f bti c + 703002c: 163ffff5 b 30000 + \.\.\. + +0000000008030030 : + 8030030: 15c00004 b f030040 <__c_func_veneer> + 8030034: 15c00005 b f030048 <__a_func_veneer> + \.\.\. + f030038: 14000012 b f030080 <__b_func_bti_veneer\+0x8> + f03003c: d503201f nop + +000000000f030040 <__c_func_veneer>: + f030040: d503245f bti c + f030044: 1440000f b 10030080 + +000000000f030048 <__a_func_veneer>: + f030048: 90fc0010 adrp x16, 7030000 + f03004c: 9100a210 add x16, x16, #0x28 + f030050: d61f0200 br x16 + \.\.\. + +000000000f030060 <__extern_func_veneer>: + f030060: 90f87f90 adrp x16, 20000 <\.plt> + f030064: 9100e210 add x16, x16, #0x38 + f030068: d61f0200 br x16 + \.\.\. + +000000000f030078 <__b_func_bti_veneer>: + f030078: d503245f bti c + f03007c: 163fffed b 8030030 + \.\.\. + +0000000010030080 : + 10030080: 17bffff2 b f030048 <__a_func_veneer> + 10030084: 17bffffd b f030078 <__b_func_bti_veneer> + 10030088: 17bffff6 b f030060 <__extern_func_veneer> diff --git a/ld/testsuite/ld-aarch64/bti-far-3.ld b/ld/testsuite/ld-aarch64/bti-far-3.ld new file mode 100644 index 00000000000..3265c55b8cc --- /dev/null +++ b/ld/testsuite/ld-aarch64/bti-far-3.ld @@ -0,0 +1,12 @@ +OUTPUT_ARCH(aarch64) +SECTIONS +{ + . = 0x00010000; + .rela.plt : { *(.rela.plt) *(.rela.iplt) } + . = 0x00020000; + .plt : { *(.plt) *(.iplt) } + . = 0x00030000; + .text : { *(.text) } + . = 0x20000000; + .got : { *(.got) *(.got.plt) } +} diff --git a/ld/testsuite/ld-aarch64/bti-far-3a.s b/ld/testsuite/ld-aarch64/bti-far-3a.s new file mode 100644 index 00000000000..ed53545fed7 --- /dev/null +++ b/ld/testsuite/ld-aarch64/bti-far-3a.s @@ -0,0 +1,23 @@ + .text + .hidden a_func + .hidden b_func + .hidden c_func + + .global a_func + .type a_func, %function +a_func: + b b_func + b extern_func + +.zero 0x07000000 + + .section .note.gnu.property,"a" + .align 3 + .word 4 + .word 16 + .word 5 + .string "GNU" + .word 3221225472 + .word 4 + .word 1 + .align 3 diff --git a/ld/testsuite/ld-aarch64/bti-far-3b.s b/ld/testsuite/ld-aarch64/bti-far-3b.s new file mode 100644 index 00000000000..1f3be3d15cf --- /dev/null +++ b/ld/testsuite/ld-aarch64/bti-far-3b.s @@ -0,0 +1,25 @@ + .text + .hidden a_func + .hidden b_func + .hidden c_func + +.zero 0x01000000 + + .global b_func + .type b_func, %function +b_func: + b c_func + b a_func + +.zero 0x07000000 + + .section .note.gnu.property,"a" + .align 3 + .word 4 + .word 16 + .word 5 + .string "GNU" + .word 3221225472 + .word 4 + .word 1 + .align 3 diff --git a/ld/testsuite/ld-aarch64/bti-far-3c.s b/ld/testsuite/ld-aarch64/bti-far-3c.s new file mode 100644 index 00000000000..8e2361fd771 --- /dev/null +++ b/ld/testsuite/ld-aarch64/bti-far-3c.s @@ -0,0 +1,24 @@ + .text + .hidden a_func + .hidden b_func + .hidden c_func + +.zero 0x01000000 + + .global c_func + .type c_func, %function +c_func: + b a_func + b b_func + b extern_func + + .section .note.gnu.property,"a" + .align 3 + .word 4 + .word 16 + .word 5 + .string "GNU" + .word 3221225472 + .word 4 + .word 1 + .align 3