diff options
author | mengqinggang <mengqinggang@loongson.cn> | 2023-09-18 18:00:21 +0800 |
---|---|---|
committer | liuzhensong <liuzhensong@loongson.cn> | 2023-09-27 15:07:51 +0800 |
commit | f07dd5f7dd19d16b91bf680c7fa7773a7831c412 (patch) | |
tree | 919f45360a675018931416f6f811f1f33fc3b547 /opcodes/loongarch-opc.c | |
parent | 5f22c5abdc68b8a6eab049a30412511b941f65d8 (diff) | |
download | gdb-f07dd5f7dd19d16b91bf680c7fa7773a7831c412.zip gdb-f07dd5f7dd19d16b91bf680c7fa7773a7831c412.tar.gz gdb-f07dd5f7dd19d16b91bf680c7fa7773a7831c412.tar.bz2 |
Add support for "pcaddi rd, symbol"
Add a macro pcaddi instruction to support "pcaddi rd, symbol".
pcaddi has a 20-bit signed immediate, it can address a +/- 2MB pc relative
address, and the address should be 4-byte aligned.
Diffstat (limited to 'opcodes/loongarch-opc.c')
-rw-r--r-- | opcodes/loongarch-opc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/opcodes/loongarch-opc.c b/opcodes/loongarch-opc.c index 2f02e33..362b658 100644 --- a/opcodes/loongarch-opc.c +++ b/opcodes/loongarch-opc.c @@ -340,7 +340,7 @@ static struct loongarch_opcode loongarch_macro_opcodes[] = { 0, 0, "la.tls.gd", "r,l", INSN_LA_TLS_GD64, 0 }, { 0, 0, "la.tls.gd", "r,l", INSN_LA_TLS_GD64_LARGE_ABS, 0 }, { 0, 0, "la.tls.gd", "r,r,l", INSN_LA_TLS_GD64_LARGE_PCREL, 0 }, - + { 0, 0, "pcaddi", "r,la", "pcaddi %1, %%pcrel_20(%2)", &LARCH_opts.ase_ilp32, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0 } /* Terminate the list. */ }; |