aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorJohn Eric Martin <John.Martin@emmicro-us.com>2017-07-19 09:56:55 +0200
committerclaziss <claziss@synopsys.com>2017-07-19 09:56:55 +0200
commit684d5a10b1332e2a1b03a1d6e7a899ef87b3ea16 (patch)
tree86314acf8134b81adb49a35e6f5c685607e03205 /gas
parente4943f2c7569a829eb6129f10f7c5401a96aaa08 (diff)
downloadgdb-684d5a10b1332e2a1b03a1d6e7a899ef87b3ea16.zip
gdb-684d5a10b1332e2a1b03a1d6e7a899ef87b3ea16.tar.gz
gdb-684d5a10b1332e2a1b03a1d6e7a899ef87b3ea16.tar.bz2
[ARC] Add JLI support.
The following relocation types were added to GCC/binutils: ARC_JLI_SECTOFF is a relocation type in Metaware that is now used by GCC as well to adjust the index of function calls to functions with attribute jli_call_always. bfd/ 2017-07-19 Claudiu Zissulescu <claziss@synopsys.com> John Eric Martin <John.Martin@emmicro-us.com> * bfd-in2.h: Regenerate. * libbfd.h: Regenerate. * elf32-arc.c (JLI): Define. * reloc.c: Add JLI relocations. gas/ 2017-07-19 Claudiu Zissulescu <claziss@synopsys.com> * testsuite/gas/arc/jli-1.d: New file. * testsuite/gas/arc/jli-1.s: Likewise. * testsuite/gas/arc/taux.d: Update for jli_base. include/ 2017-07-19 Claudiu Zissulescu <claziss@synopsys.com> John Eric Martin <John.Martin@emmicro-us.com> * elf/arc-reloc.def: Add JLI relocs howto. * opcode/arc-func.h (replace_jli): New function. ld/ 2017-07-19 Claudiu Zissulescu <claziss@synopsys.com> John Eric Martin <John.Martin@emmicro-us.com> * emulparams/arcelf.sh (JLI_START_TABLE): Define. * scripttempl/elfarc.sc: Handle jlitab section. * scripttempl/elfarcv2.sc: Likewise. * testsuite/ld-arc/arc.exp: Add JLI test. * testsuite/ld-arc/jli-script.ld: New file. * testsuite/ld-arc/jli-simple.dd: Likewise. * testsuite/ld-arc/jli-simple.rd: Likewise. * testsuite/ld-arc/jli-simple.s: Likewise. * testsuite/ld/testsuite/ld-arc/jli-overflow.s: Likewise. * testsuite/ld/testsuite/ld-arc/jli-overflow.d: Likewise. * testsuite/ld/testsuite/ld-arc/jli-overflow.err: Likewise. opcode/ 2017-07-19 Claudiu Zissulescu <claziss@synopsys.com> John Eric Martin <John.Martin@emmicro-us.com> * arc-opc.c (UIMM10_6_S_JLIOFF): Define. (UIMM3_23): Adjust accordingly. * arc-regs.h: Add/correct jli_base register. * arc-tbl.h (jli_s): Likewise.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog6
-rw-r--r--gas/testsuite/gas/arc/jli-1.d25
-rw-r--r--gas/testsuite/gas/arc/jli-1.s11
-rw-r--r--gas/testsuite/gas/arc/taux.d1
4 files changed, 43 insertions, 0 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index dd6a34f..d247a5b 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,9 @@
+2017-07-19 Claudiu Zissulescu <claziss@synopsys.com>
+
+ * testsuite/gas/arc/jli-1.d: New file.
+ * testsuite/gas/arc/jli-1.s: Likewise.
+ * testsuite/gas/arc/taux.d: Update for jli_base.
+
2017-07-19 Tristan Gingold <gingold@adacore.com>
* as.c (start_sbrk): Remove.
diff --git a/gas/testsuite/gas/arc/jli-1.d b/gas/testsuite/gas/arc/jli-1.d
new file mode 100644
index 0000000..10550a2
--- /dev/null
+++ b/gas/testsuite/gas/arc/jli-1.d
@@ -0,0 +1,25 @@
+#as:
+#objdump: -Dr
+
+.*: +file format .*
+
+
+Disassembly of section .group:
+
+00000000 <jlitab.foo>:
+ 0: 0[10] 00 00 0[01] .word 0x00000001
+ 4: 0[60] 00 00 0[06] .word 0x00000006
+
+Disassembly of section .text:
+
+00000000 <.text>:
+ 0: 5800 jli_s 0
+ 0: R_ARC_JLI_SECTOFF __jli.foo
+
+Disassembly of section .jlitab:
+
+00000000 <__jli.foo>:
+ 0: 0001 0000 b 0 <foo>
+ 0: R_ARC_S25H_PCREL foo
+
+#...
diff --git a/gas/testsuite/gas/arc/jli-1.s b/gas/testsuite/gas/arc/jli-1.s
new file mode 100644
index 0000000..6890147
--- /dev/null
+++ b/gas/testsuite/gas/arc/jli-1.s
@@ -0,0 +1,11 @@
+;;; Test basic JLI relocs and constructs.
+
+ .cpu em4
+
+ jli_s __jli.foo ; Generates R_ARC_JLI_SECTOFF
+
+ .section .jlitab,"axG",%progbits,jlitab.foo,comdat
+ .align 4
+__jli.foo:
+ .weak __jli.foo
+ b @foo
diff --git a/gas/testsuite/gas/arc/taux.d b/gas/testsuite/gas/arc/taux.d
index 10f50ee..6303146 100644
--- a/gas/testsuite/gas/arc/taux.d
+++ b/gas/testsuite/gas/arc/taux.d
@@ -16,6 +16,7 @@
.* U d2l
.* U dpfp_status
.* U fp_status
+.* U jli_base
.* mx0
.* mx1
.* my0