diff options
author | Xi Ruoyao <xry111@xry111.site> | 2022-08-30 18:48:02 +0800 |
---|---|---|
committer | Hongchen Zhang <zhanghongchen@loongson.cn> | 2022-09-17 12:56:07 +0800 |
commit | 174aef16f9ea39928357142370d1dd3f5c82d990 (patch) | |
tree | 1f90c915298af41702145e1a700ef8e08f169241 | |
parent | 9780a0f13e4f75ecc532148cfe8916e09a547a06 (diff) | |
download | openEuler-kernel-174aef16f9ea39928357142370d1dd3f5c82d990.tar.gz |
LoongArch: Add Kconfig option AS_HAS_EXPLICIT_RELOCS
LoongArch inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I5OHOB
--------------------------------
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 a Kconfig option AS_HAS_EXPLICIT_RELOCS as the switch for
"use explicit relocation hints or not".
Signed-off-by: Xi Ruoyao <xry111@xry111.site>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
-rw-r--r-- | arch/loongarch/Kconfig | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/loongarch/Kconfig b/arch/loongarch/Kconfig index d586225cb96e0a..068515a599e70e 100644 --- a/arch/loongarch/Kconfig +++ b/arch/loongarch/Kconfig @@ -206,6 +206,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" |