]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
LoongArch: Make align symbol be in same section with alignment directive
authormengqinggang <mengqinggang@loongson.cn>
Wed, 29 May 2024 06:50:39 +0000 (14:50 +0800)
committerliuzhensong <liuzhensong@loongson.cn>
Tue, 4 Jun 2024 11:47:20 +0000 (19:47 +0800)
commit5f4fa40e4def33ed428b2d72aeb2bf24b50a664e
treeb2302f426f3b27b97b27b957ee0dc00717af4c42
parentb472e4cfd63c551543b6a1653f3cff03162b7403
LoongArch: Make align symbol be in same section with alignment directive

R_LARCH_ALIGN (psABI v2.30) requires a symbol index. The symbol is only
created at the first time to handle alignment directive. This means that
all other sections may use this symbol. If the section of this symbol is
discarded, there may be problems. Search it in its own section.

Remove elf_backend_data.is_rela_normal() function added at commit daeda14191c.

Co-authored-by: Jinyang He <hejinyang@loongson.cn>
Reported-by: WANG Xuerui <git@xen0n.name>
Link: https://lore.kernel.org/loongarch/2abbb633-a10e-71cc-a5e1-4d9e39074066@loongson.cn/T/#t
bfd/elf-bfd.h
bfd/elflink.c
bfd/elfnn-loongarch.c
bfd/elfxx-target.h
gas/config/tc-loongarch.c
gas/config/tc-loongarch.h
gas/testsuite/gas/loongarch/relax-align2.d [new file with mode: 0644]
gas/testsuite/gas/loongarch/relax-align2.s [new file with mode: 0644]
gas/testsuite/gas/loongarch/relax_align.d