From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by sourceware.org (Postfix) with ESMTP id E30623858D28 for ; Fri, 1 Jul 2022 14:49:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org E30623858D28 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id D98151515; Fri, 1 Jul 2022 07:49:17 -0700 (PDT) Received: from [10.2.78.56] (unknown [10.2.78.56]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id DF60A3F792; Fri, 1 Jul 2022 07:49:16 -0700 (PDT) Message-ID: <7cbe01d8-96a6-7e33-ebe0-761e8a6b14c7@foss.arm.com> Date: Fri, 1 Jul 2022 15:49:15 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [PATCH 7/12] arm: Emit build attributes for PACBTI target feature Content-Language: en-GB To: Andrea Corallo , Andrea Corallo via Gcc-patches Cc: Richard Earnshaw , nd References: From: Richard Earnshaw In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3490.8 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, KAM_SHORT, NICE_REPLY_A, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Jul 2022 14:49:19 -0000 On 28/04/2022 10:45, Andrea Corallo via Gcc-patches wrote: > This patch emits assembler directives for PACBTI build attributes as > defined by the > ABI. > > > > gcc/ChangeLog: > > * config/arm/arm.c (arm_file_start): Emit EABI attributes for > Tag_PAC_extension, Tag_BTI_extension, TAG_BTI_use, TAG_PACRET_use. This bit is OK. > > gcc/testsuite/ChangeLog: > > * gcc.target/arm/acle/pacbti-m-predef-1.c: New test. > * gcc.target/arm/acle/pacbti-m-predef-3: Likewise. > * gcc.target/arm/acle/pacbti-m-predef-6.c: Likewise. > * gcc.target/arm/acle/pacbti-m-predef-7.c: Likewise. These tests contain directives like: +/* { dg-additional-options " -mbranch-protection=pac-ret+bti --save-temps" } */ But they don't check that the architecture permits this (it has to be armv8-m.main or later). > > Co-Authored-By: Tejas Belagod > R.