Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp3197162rwe; Mon, 29 Aug 2022 07:27:25 -0700 (PDT) X-Google-Smtp-Source: AA6agR4FQXwmGXruniaOWoWfK9MSrg1dQwMwR8Zehwq+uFhJSTRyOrWNWizY04BpFIH76sjuVM9V X-Received: by 2002:a50:9fc2:0:b0:447:8c73:299e with SMTP id c60-20020a509fc2000000b004478c73299emr16300751edf.112.1661783244451; Mon, 29 Aug 2022 07:27:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661783244; cv=none; d=google.com; s=arc-20160816; b=CwY+dZ2WshKg3i3S/loznuJrMCncbjBn3h6b/GhvsGln3IQIbrGQ6goYEOVgF7eHqu O4Z+2Fm8qvFQQo2vrJDd1xkfg70YAhFgCVvM801/SBnWJEfXqEBHuhWRjOOBG0zRCnKB swBEytwxqTmWfcrewm3ygHR4xm1IxDX0XapaRb6+sJulOcc6j1wZfJedpGOKZHKcP8px BAUnJhaDtrcVLaJ977z4hMLOFXj41E7DHuE5buUfr2duvZA7Q4KJo8SHLyLJ2Em/rMbh OXdSDosvvxi1T/rZ7l8mRZou53JG+4aWPE1ARMmfkXPEf+zp69T07n69EKNB3KUb6FvR Ykog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uZrvxtNwFUmvP9Vak1eD+cAXrqomaHHYRj1Ir3F0fCA=; b=MaMxMhVcQpaCanPY0ebYOoIMHUKOzGX9fbwz7Xi2NWCcDMio3yUQ8bu7vo0RlG8Bxd kFFUoprhAJTGZZdiusfPa6JrbgOx8bSeTOJtOEL2retHDN6wGPkUepPI7s5WQBG22CsW 8Z4c5USInf4M6YBvtudpdoszoR7BIOcH6Q0sjDEp7+I4a8S2DjEGk2kUqAsjyFTFuder f9+HG0o69h/dEurP01jEVpQbSVsHdSkXwrr+qyx94jYS2XBVLEdntiwijB338Z3BZA1K cPvO7xON2+yOhx46yZIvtNyiKcqwgwuugvmxkN/IaDq3+sx29gdKRNN1RzQVbOE58RS5 mgmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@xry111.site header.s=default header.b=B+8Gj6th; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=xry111.site Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qb26-20020a1709077e9a00b0073d6c94fc3dsi7066666ejc.162.2022.08.29.07.26.58; Mon, 29 Aug 2022 07:27:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@xry111.site header.s=default header.b=B+8Gj6th; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=xry111.site Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229795AbiH2NfK (ORCPT + 99 others); Mon, 29 Aug 2022 09:35:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54104 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229577AbiH2NfG (ORCPT ); Mon, 29 Aug 2022 09:35:06 -0400 Received: from xry111.site (xry111.site [IPv6:2001:470:683e::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 212B51EEDD for ; Mon, 29 Aug 2022 06:35:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=xry111.site; s=default; t=1661780102; bh=owF+FNmRrMbe7xv+RTni/1sE0a+t4GDngroii48Nl7g=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=B+8Gj6thkXofgbnv7dQT3fcXFy7j5xLihma+EuHZDfvFU6SOfxdjKb07rD6VCh8Bo OZYHXdnz3DUtAY//u/0bn0eOt9qGtvqNl46BVy7YZjNdgEAkqmcuPMIr3CCZiHel9d F8Nh2zIZkoS6Yuo8nLa6YCgKWP2ZzxhzHUrW2SBs= Received: from xry111-x57s1.. (unknown [IPv6:240e:358:11dd:1900:dc73:854d:832e:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (Client did not present a certificate) (Authenticated sender: xry111@xry111.site) by xry111.site (Postfix) with ESMTPSA id 2F72E66903; Mon, 29 Aug 2022 09:34:56 -0400 (EDT) From: Xi Ruoyao To: loongarch@lists.linux.dev Cc: linux-kernel@vger.kernel.org, WANG Xuerui , Huacai Chen , Youling Tang , Jinyang He , Xi Ruoyao Subject: [PATCH v6 1/6] LoongArch: Add CONFIG_AS_HAS_EXPLICIT_RELOCS Date: Mon, 29 Aug 2022 21:31:41 +0800 Message-Id: <20220829133146.15236-2-xry111@xry111.site> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220829133146.15236-1-xry111@xry111.site> References: <20220829133146.15236-1-xry111@xry111.site> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FROM_SUSPICIOUS_NTLD, PDS_OTHER_BAD_TLD,SPF_HELO_PASS,SPF_PASS,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 lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org GNU as >= 2.40 and GCC >= 13 will support using explicit relocation hints in the assembly code, instead of la.* macros. The usage of explicit relocation hints can improve code generation so it's enabled by default by GCC >= 13. Introduce CONFIG_AS_HAS_EXPLICIT_RELOCS as the switch for "use explicit relocation hints or not." Signed-off-by: Xi Ruoyao --- arch/loongarch/Kconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/loongarch/Kconfig b/arch/loongarch/Kconfig index d3ce96a1a744..0721b4b2207a 100644 --- a/arch/loongarch/Kconfig +++ b/arch/loongarch/Kconfig @@ -204,6 +204,9 @@ config SCHED_OMIT_FRAME_POINTER bool default y +config AS_HAS_EXPLICIT_RELOCS + def_bool $(as-instr,x:pcalau12i \$t0$(comma)%pc_hi20(x)) + menu "Kernel type and options" source "kernel/Kconfig.hz" -- 2.37.0