diff options
author | Lulu Cai <cailulu@loongson.cn> | 2024-09-21 11:29:39 +0800 |
---|---|---|
committer | liuzhensong <liuzhensong@loongson.cn> | 2024-10-14 09:15:16 +0800 |
commit | 22c62092858e5623338a18a42491718d754977e8 (patch) | |
tree | a7448fba3b1e62de0531e3213c8448a5e4ff2736 /opcodes/loongarch-opc.c | |
parent | a134ad4780c1daf39d2213b015c93f9cc73e8156 (diff) | |
download | gdb-22c62092858e5623338a18a42491718d754977e8.zip gdb-22c62092858e5623338a18a42491718d754977e8.tar.gz gdb-22c62092858e5623338a18a42491718d754977e8.tar.bz2 |
LoongArch: Fixed R_LARCH_[32/64]_PCREL generation bug
The enum BFD_RELOC_[32/64] was mistakenly used in the macro instead
of the relocation in fixp. This can cause the second relocation
of a pair to be deleted when -mthin-add-sub is enabled. Apply the
correct macro to fix this.
Also sets the initial value of -mthin-add-sub.
Diffstat (limited to 'opcodes/loongarch-opc.c')
-rw-r--r-- | opcodes/loongarch-opc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/opcodes/loongarch-opc.c b/opcodes/loongarch-opc.c index 6bd436f..0ba745f 100644 --- a/opcodes/loongarch-opc.c +++ b/opcodes/loongarch-opc.c @@ -24,7 +24,8 @@ struct loongarch_ASEs_option LARCH_opts = { - .relax = 1 + .relax = 1, + .thin_add_sub = 0 }; size_t |