]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
LoongArch: gas: Simplify relocations in sections without code flag master
authorJinyang He <hejinyang@loongson.cn>
Mon, 22 Apr 2024 09:49:50 +0000 (17:49 +0800)
committerliuzhensong <liuzhensong@loongson.cn>
Thu, 25 Apr 2024 03:53:15 +0000 (11:53 +0800)
commit035068a0cd846653e1fb0903aece42f4258803fb
tree70219d99f339e89d9312cc8a3096465fd775fcd6
parent66156bae7a0581879763514382d112716464db8a
LoongArch: gas: Simplify relocations in sections without code flag

Gas should not emit ADD/SUB relocation pairs for label differences
if they are in the same section without code flag even relax enabled.
Because the real value is not be affected by relaxation and it can be
compute out in assembly stage. Thus, correct the `TC_FORCE_RELOCATION
_SUB_SAME` and the label differences in same section without code
flag can be resolved in fixup_segment().
gas/config/tc-loongarch.h
gas/testsuite/gas/loongarch/relax_debug_line.d [new file with mode: 0644]
gas/testsuite/gas/loongarch/relax_debug_line.s [new file with mode: 0644]