From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 47502 invoked by alias); 27 Jun 2017 08:01:35 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 47060 invoked by uid 89); 27 Jun 2017 08:01:30 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD autolearn=no version=3.3.2 spammy= X-HELO: foss.arm.com Received: from foss.arm.com (HELO foss.arm.com) (217.140.101.70) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 27 Jun 2017 08:01:28 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 216942B; Tue, 27 Jun 2017 01:01:27 -0700 (PDT) Received: from [10.2.206.201] (e105545-lin.cambridge.arm.com [10.2.206.201]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 607AA3F581; Tue, 27 Jun 2017 01:01:26 -0700 (PDT) Subject: Re: [AARCH64] Disable pc relative literal load irrespective of TARGET_FIX_ERR_A53_84341 To: Kugan Vivekanandarajah , "gcc-patches@gcc.gnu.org" , James Greenhalgh , Richard Earnshaw References: From: Ramana Radhakrishnan Message-ID: <752a2d93-0641-134f-33dd-bc550618f7f3@foss.arm.com> Date: Tue, 27 Jun 2017 08:01:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2017-06/txt/msg01983.txt.bz2 On 27/06/17 02:20, Kugan Vivekanandarajah wrote: > https://gcc.gnu.org/ml/gcc-patches/2016-03/msg00614.html added this > workaround to get kernel building with when TARGET_FIX_ERR_A53_843419 > is enabled. > > This was added to support building kernel loadable modules. In kernel, > when CONFIG_ARM64_ERRATUM_843419 is selected, the relocation needed > for ADRP/LDR (R_AARCH64_ADR_PREL_PG_HI21 and > R_AARCH64_ADR_PREL_PG_HI21_NC are removed from the kernel to avoid > loading objects with possibly offending sequence). Thus, it could only > support pc relative literal loads. > > However, the following patch was posted to kernel to add > -mpc-relative-literal-loads > http://www.spinics.net/lists/arm-kernel/msg476149.html > > -mpc-relative-literal-loads is unconditionally added to the kernel > build as can be seen from: > https://github.com/torvalds/linux/blob/master/arch/arm64/Makefile > > Therefore this patch removes the hunk so that applications like > SPECcpu2017's 521/621.wrf can be built (with LTO in this case) without > -mno-pc-relative-literal-loads Is that because your compiler has defaulted to -mpc-relative-literal-loads because it has the workaround enabled by default ? I'm curious as to why others haven't seen this issue. regards Ramana