* config/tc-m68hc11.c: Add S12X and XGATE co-processor support.
Add option to offset S12 addresses into XGATE memory space. Tweak target flags to match other tools. (i.e. -m m68hc11). * doc/as.texinfo: Mention new options. * doc/c-m68hc11.texi: Document new options. * NEWS: Mention new support. * archures.c: Add bfd_arch_m9s12x and bfd_arch_m9s12xg. * config.bfd: Likewise. * cpu-m9s12x.c: New. * cpu-m9s12xg.c: New. * elf32-m68hc12.c: Add S12X and XGATE co-processor support. Add option to offset S12 addresses into XGATE memory space. Fix carry bug in IMM16 (IMM8 low/high) relocate. * Makefile.am (ALL_MACHINES): Add cpu-m9s12x and cpu-m9s12xg. (ALL_MACHINES_CFILES): Likewise. * reloc.c: Add S12X relocs. * Makefile.in: Regenerate. * bfd-in2.h: Regenerate. * libbfd.h: Regenerate. * gas/m68hc11/insns9s12x.s: New * gas/m68hc11/insns9s12x.d: New * gas/m68hc11/hexprefix.s: New * gas/m68hc11/hexprefix.d: New * gas/m68hc11/9s12x-exg-sex-tfr.s: New * gas/m68hc11/9s12x-exg-sex-tfr.d: New * gas/m68hc11/insns9s12xg.s: New * gas/m68hc11/insns9s12xg.d: New * gas/m68hc11/9s12x-mov.s: New * gas/m68hc11/9s12x-mov.d: New * gas/m68hc11/m68hc11.exp: Updated * gas/m68hc11/*.d: Brought in line with changed objdump output. * gas/all/gas.exp: XFAIL all hc11/12 targets for redef2,3. * gas/elf/elf.exp: XFAIL all hc11/12 targets for redef. * gas/elf/dwarf2-1.d: Skip for hc11/12 targets. * gas/elf/dwarf2-2.d: Likewise. * ld-m68hc11/xgate-link.s: New. * ld-m68hc11/xgate-link.d: New. * ld-m68hc11/xgate-offset.s: New. * ld-m68hc11/xgate-offset.d: New. * ld-m68hc11/xgate1.s: New. * ld-m68hc11/xgate1.d: New. * ld-m68hc11/xgate2.s: New. * ld-m68hc11/m68hc11.exp: Updated. * ld-m68hc11/*.d: Brought in line with changed objdump output. * ld-gc/gc.exp: Update CFLAGS for m68hc11. * ld-plugin/plugin.exp: Likewise. * ld-srec/srec.exp: XFAIL for m68hc11 and m68hc12. * configure.in: Add S12X and XGATE co-processor support to m68hc11 target. * disassemble.c: Likewise. * configure: Regenerate. * m68hc11-dis.c: Make objdump output more consistent, use hex instead of decimal and use 0x prefix for hex. * m68hc11-opc.c: Add S12X and XGATE opcodes. * dis-asm.h (print_insn_m9s12x): Prototype. (print_insn_m9s12xg): Prototype. * m68hc11.h (R_M68HC12_16B, R_M68HC12_PCREL_9, R_M68HC12_PCREL_10) R_M68HC12_HI8XG, R_M68HC12_LO8XG): New relocations. (E_M68HC11_XGATE_RAMOFFSET): Define. * m68hc11.h: Add XGate definitions. (struct m68hc11_opcode): Add xg_mask field.
This commit is contained in:
parent
9cc815f56d
commit
6927f98292
82 changed files with 5981 additions and 2514 deletions
|
@ -1,3 +1,7 @@
|
|||
2012-05-15 James Murray <jsm@jsm-net.demon.co.uk>
|
||||
|
||||
* NEWS: Mention the support for S12X processors.
|
||||
|
||||
2012-05-14 James Lemke <jwlemke@codesourcery.com>
|
||||
|
||||
* ldlang.c (walk_wild_consider_section): Don't copy section_flag_list.
|
||||
|
|
2
ld/NEWS
2
ld/NEWS
|
@ -1,5 +1,7 @@
|
|||
-*- text -*-
|
||||
|
||||
* Add support for S12X processor.
|
||||
|
||||
* Add support for the VLE extension to the PowerPC architecture.
|
||||
|
||||
* Add support for the Freescale XGATE architecture.
|
||||
|
|
|
@ -1,3 +1,18 @@
|
|||
2012-05-15 James Murray <jsm@jsm-net.demon.co.uk>
|
||||
|
||||
* ld-m68hc11/xgate-link.s: New.
|
||||
* ld-m68hc11/xgate-link.d: New.
|
||||
* ld-m68hc11/xgate-offset.s: New.
|
||||
* ld-m68hc11/xgate-offset.d: New.
|
||||
* ld-m68hc11/xgate1.s: New.
|
||||
* ld-m68hc11/xgate1.d: New.
|
||||
* ld-m68hc11/xgate2.s: New.
|
||||
* ld-m68hc11/m68hc11.exp: Updated.
|
||||
* ld-m68hc11/*.d: Brought in line with changed objdump output.
|
||||
* ld-gc/gc.exp: Update CFLAGS for m68hc11.
|
||||
* ld-plugin/plugin.exp: Likewise.
|
||||
* ld-srec/srec.exp: XFAIL for m68hc11 and m68hc12.
|
||||
|
||||
2012-05-14 David S. Miller <davem@davemloft.net>
|
||||
|
||||
* ld-sparc/tlssunbin32.rd: Update.
|
||||
|
|
|
@ -32,6 +32,11 @@ if [istarget powerpc64*-*-*] {
|
|||
set cflags "$cflags -mminimal-toc"
|
||||
}
|
||||
|
||||
if { [istarget m681*-*-*] || [istarget m68hc1*-*-*] } {
|
||||
# Otherwise tests FAIL due to _.frame
|
||||
set cflags "$cflags -fomit-frame-pointer -mshort"
|
||||
}
|
||||
|
||||
if { [is_remote host] || [which $CC] != 0 } {
|
||||
ld_compile "$CC -c $CFLAGS $cflags" $srcdir/$subdir/gc.c $objfile
|
||||
}
|
||||
|
|
|
@ -6,26 +6,26 @@
|
|||
.*: +file format elf32\-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> brclr 140,x \#\$c8 0+804a <L8>
|
||||
0+8004 <L1> addd \*0+4 <_toto>
|
||||
0+8006 <L1\+0x2> brclr 20,x \#\$03 0+8004 <L1>
|
||||
0+800a <L1\+0x6> brclr 90,x \#\$63 0+801a <L3>
|
||||
0+800e <L2> addd \*0+4 <_toto>
|
||||
0+8010 <L2\+0x2> brclr 19,y \#\$04 0+800e <L2>
|
||||
0+8015 <L2\+0x7> brclr 91,y \#\$62 0+8024 <L4>
|
||||
0+801a <L3> addd \*0+4 <_toto>
|
||||
0+801c <L3\+0x2> brset 18,x \#\$05 0+801a <L3>
|
||||
0+8020 <L3\+0x6> brset 92,x \#\$61 0+8030 <L5>
|
||||
0+8024 <L4> addd \*0+4 <_toto>
|
||||
0+8026 <L4\+0x2> brset 17,y \#\$06 0+8024 <L4>
|
||||
0+802b <L4\+0x7> brset 93,y \#\$60 0+8030 <L5>
|
||||
0+8030 <L5> addd \*0+4 <_toto>
|
||||
0+8032 <L5\+0x2> brset \*0+32 <_table> \#\$07 0+8030 <L5>
|
||||
0+8036 <L5\+0x6> brset \*0+3c <_table\+0xa> \#\$5f 0+8044 <L7>
|
||||
0+803a <L6> addd \*0+4 <_toto>
|
||||
0+803c <L6\+0x2> brclr \*0+33 <_table\+0x1> \#\$08 0+803a <L6>
|
||||
0+8040 <L6\+0x6> brset \*0+3d <_table\+0xb> \#\$5e 0+804a <L8>
|
||||
0+8044 <L7> addd \*0+4 <_toto>
|
||||
0+8046 <L7\+0x2> brclr \*0+33 <_table\+0x1> \#\$08 0+803a <L6>
|
||||
0+804a <L8> brclr 140,x \#\$c8 0+8000 <_start>
|
||||
0+8000 <_start> brclr 0x8c,x, #0xc8, 0x0+804a <L8>
|
||||
0+8004 <L1> addd \*0x0+4 <_toto>
|
||||
0+8006 <L1\+0x2> brclr 0x14,x, \#0x03, 0x0+8004 <L1>
|
||||
0+800a <L1\+0x6> brclr 0x5a,x, \#0x63, 0x0+801a <L3>
|
||||
0+800e <L2> addd \*0x0+4 <_toto>
|
||||
0+8010 <L2\+0x2> brclr 0x13,y, \#0x04, 0x0+800e <L2>
|
||||
0+8015 <L2\+0x7> brclr 0x5b,y, \#0x62, 0x0+8024 <L4>
|
||||
0+801a <L3> addd \*0x0+4 <_toto>
|
||||
0+801c <L3\+0x2> brset 0x12,x, \#0x05, 0x0+801a <L3>
|
||||
0+8020 <L3\+0x6> brset 0x5c,x, \#0x61, 0x0+8030 <L5>
|
||||
0+8024 <L4> addd \*0x0+4 <_toto>
|
||||
0+8026 <L4\+0x2> brset 0x11,y, \#0x06, 0x0+8024 <L4>
|
||||
0+802b <L4\+0x7> brset 0x5d,y, \#0x60, 0x0+8030 <L5>
|
||||
0+8030 <L5> addd \*0x0+4 <_toto>
|
||||
0+8032 <L5\+0x2> brset \*0x0+32 <_table>, \#0x07, 0x0+8030 <L5>
|
||||
0+8036 <L5\+0x6> brset \*0x0+3c <_table\+0xa>, \#0x5f, 0x0+8044 <L7>
|
||||
0+803a <L6> addd \*0x0+4 <_toto>
|
||||
0+803c <L6\+0x2> brclr \*0x0+33 <_table\+0x1>, \#0x08, 0x0+803a <L6>
|
||||
0+8040 <L6\+0x6> brset \*0x0+3d <_table\+0xb>, \#0x5e, 0x0+804a <L8>
|
||||
0+8044 <L7> addd \*0x0+4 <_toto>
|
||||
0+8046 <L7\+0x2> brclr \*0x0+33 <_table\+0x1>, \#0x08, 0x0+803a <L6>
|
||||
0+804a <L8> brclr 0x8c,x, \#0xc8, 0x0+8000 <_start>
|
||||
0+804e <L8\+0x4> rts
|
||||
|
|
|
@ -6,54 +6,54 @@
|
|||
.*: +file format elf32\-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> bra 0+8074 <L3>
|
||||
0+8000 <_start> bra 0x0+8074 <L3>
|
||||
...
|
||||
0+8016 <_start\+0x16> bra 0+8074 <L3>
|
||||
0+8018 <L1> addd 0,x
|
||||
0+801a <L1\+0x2> bne 0+8018 <L1>
|
||||
0+801c <L1\+0x4> addd \*0+4 <_toto>
|
||||
0+801e <L1\+0x6> beq 0+8018 <L1>
|
||||
0+8020 <L1\+0x8> addd \*0+5 <_toto\+0x1>
|
||||
0+8022 <L1\+0xa> bne 0+8018 <L1>
|
||||
0+8024 <L1\+0xc> bgt 0+8018 <L1>
|
||||
0+8026 <L1\+0xe> bge 0+8018 <L1>
|
||||
0+8028 <L1\+0x10> beq 0+8018 <L1>
|
||||
0+802a <L1\+0x12> ble 0+8018 <L1>
|
||||
0+802c <L1\+0x14> blt 0+8018 <L1>
|
||||
0+802e <L1\+0x16> bhi 0+8018 <L1>
|
||||
0+8030 <L1\+0x18> bcc 0+8018 <L1>
|
||||
0+8032 <L1\+0x1a> beq 0+8018 <L1>
|
||||
0+8034 <L1\+0x1c> bls 0+8018 <L1>
|
||||
0+8036 <L1\+0x1e> bcs 0+8018 <L1>
|
||||
0+8038 <L1\+0x20> bcs 0+8018 <L1>
|
||||
0+803a <L1\+0x22> bmi 0+8018 <L1>
|
||||
0+803c <L1\+0x24> bvs 0+8018 <L1>
|
||||
0+803e <L1\+0x26> bcc 0+8018 <L1>
|
||||
0+8040 <L1\+0x28> bpl 0+8018 <L1>
|
||||
0+8042 <L1\+0x2a> bvc 0+8018 <L1>
|
||||
0+8044 <L1\+0x2c> bne 0+8018 <L1>
|
||||
0+8046 <L1\+0x2e> brn 0+8018 <L1>
|
||||
0+8048 <L1\+0x30> bra 0+8018 <L1>
|
||||
0+804a <L1\+0x32> addd \*0+4 <_toto>
|
||||
0+804c <L1\+0x34> addd \*0+4 <_toto>
|
||||
0+804e <L1\+0x36> addd \*0+4 <_toto>
|
||||
0+8050 <L1\+0x38> addd \*0+4 <_toto>
|
||||
0+8052 <L1\+0x3a> addd \*0+4 <_toto>
|
||||
0+8054 <L1\+0x3c> addd \*0+4 <_toto>
|
||||
0+8056 <L1\+0x3e> addd \*0+4 <_toto>
|
||||
0+8058 <L1\+0x40> addd \*0+4 <_toto>
|
||||
0+805a <L1\+0x42> addd \*0+4 <_toto>
|
||||
0+805c <L1\+0x44> addd \*0+4 <_toto>
|
||||
0+805e <L1\+0x46> addd \*0+4 <_toto>
|
||||
0+8060 <L1\+0x48> addd \*0+4 <_toto>
|
||||
0+8062 <L1\+0x4a> addd \*0+4 <_toto>
|
||||
0+8064 <L1\+0x4c> addd \*0+4 <_toto>
|
||||
0+8066 <L1\+0x4e> addd \*0+4 <_toto>
|
||||
0+8068 <L2> bra 0+8000 <_start>
|
||||
0+806a <L2\+0x2> bne 0+8068 <L2>
|
||||
0+806c <L2\+0x4> beq 0+8074 <L3>
|
||||
0+806e <L2\+0x6> addd \*0+4 <_toto>
|
||||
0+8070 <L2\+0x8> beq 0+8074 <L3>
|
||||
0+8072 <L2\+0xa> addd \*0+4 <_toto>
|
||||
0+8074 <L3> addd \*0+4 <_toto>
|
||||
0+8016 <_start\+0x16> bra 0x0+8074 <L3>
|
||||
0+8018 <L1> addd 0x0,x
|
||||
0+801a <L1\+0x2> bne 0x0+8018 <L1>
|
||||
0+801c <L1\+0x4> addd \*0x0+4 <_toto>
|
||||
0+801e <L1\+0x6> beq 0x0+8018 <L1>
|
||||
0+8020 <L1\+0x8> addd \*0x0+5 <_toto\+0x1>
|
||||
0+8022 <L1\+0xa> bne 0x0+8018 <L1>
|
||||
0+8024 <L1\+0xc> bgt 0x0+8018 <L1>
|
||||
0+8026 <L1\+0xe> bge 0x0+8018 <L1>
|
||||
0+8028 <L1\+0x10> beq 0x0+8018 <L1>
|
||||
0+802a <L1\+0x12> ble 0x0+8018 <L1>
|
||||
0+802c <L1\+0x14> blt 0x0+8018 <L1>
|
||||
0+802e <L1\+0x16> bhi 0x0+8018 <L1>
|
||||
0+8030 <L1\+0x18> bcc 0x0+8018 <L1>
|
||||
0+8032 <L1\+0x1a> beq 0x0+8018 <L1>
|
||||
0+8034 <L1\+0x1c> bls 0x0+8018 <L1>
|
||||
0+8036 <L1\+0x1e> bcs 0x0+8018 <L1>
|
||||
0+8038 <L1\+0x20> bcs 0x0+8018 <L1>
|
||||
0+803a <L1\+0x22> bmi 0x0+8018 <L1>
|
||||
0+803c <L1\+0x24> bvs 0x0+8018 <L1>
|
||||
0+803e <L1\+0x26> bcc 0x0+8018 <L1>
|
||||
0+8040 <L1\+0x28> bpl 0x0+8018 <L1>
|
||||
0+8042 <L1\+0x2a> bvc 0x0+8018 <L1>
|
||||
0+8044 <L1\+0x2c> bne 0x0+8018 <L1>
|
||||
0+8046 <L1\+0x2e> brn 0x0+8018 <L1>
|
||||
0+8048 <L1\+0x30> bra 0x0+8018 <L1>
|
||||
0+804a <L1\+0x32> addd \*0x0+4 <_toto>
|
||||
0+804c <L1\+0x34> addd \*0x0+4 <_toto>
|
||||
0+804e <L1\+0x36> addd \*0x0+4 <_toto>
|
||||
0+8050 <L1\+0x38> addd \*0x0+4 <_toto>
|
||||
0+8052 <L1\+0x3a> addd \*0x0+4 <_toto>
|
||||
0+8054 <L1\+0x3c> addd \*0x0+4 <_toto>
|
||||
0+8056 <L1\+0x3e> addd \*0x0+4 <_toto>
|
||||
0+8058 <L1\+0x40> addd \*0x0+4 <_toto>
|
||||
0+805a <L1\+0x42> addd \*0x0+4 <_toto>
|
||||
0+805c <L1\+0x44> addd \*0x0+4 <_toto>
|
||||
0+805e <L1\+0x46> addd \*0x0+4 <_toto>
|
||||
0+8060 <L1\+0x48> addd \*0x0+4 <_toto>
|
||||
0+8062 <L1\+0x4a> addd \*0x0+4 <_toto>
|
||||
0+8064 <L1\+0x4c> addd \*0x0+4 <_toto>
|
||||
0+8066 <L1\+0x4e> addd \*0x0+4 <_toto>
|
||||
0+8068 <L2> bra 0x0+8000 <_start>
|
||||
0+806a <L2\+0x2> bne 0x0+8068 <L2>
|
||||
0+806c <L2\+0x4> beq 0x0+8074 <L3>
|
||||
0+806e <L2\+0x6> addd \*0x0+4 <_toto>
|
||||
0+8070 <L2\+0x8> beq 0x0+8074 <L3>
|
||||
0+8072 <L2\+0xa> addd \*0x0+4 <_toto>
|
||||
0+8074 <L3> addd \*0x0+4 <_toto>
|
||||
0+8076 <L3\+0x2> rts
|
||||
|
|
|
@ -6,6 +6,6 @@
|
|||
.*: +file format elf32-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> bset \*0+ <__bss_size> \#\$04
|
||||
0+8003 <L1> bra 0+8005 <toto>
|
||||
0+8000 <_start> bset \*0x0+ <__bss_size>, \#0x04
|
||||
0+8003 <L1> bra 0x0+8005 <toto>
|
||||
0+8005 <toto> rts
|
||||
|
|
|
@ -6,9 +6,9 @@
|
|||
.*: +file format elf32-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> tst 0+ <__bss_size>
|
||||
0+8003 <_start\+0x3> bne 0+8007 <L1>
|
||||
0+8005 <_start\+0x5> bsr 0+800b <foo>
|
||||
0+8007 <L1> bset \*0+ <__bss_size> \#\$04
|
||||
0+8000 <_start> tst 0x0+ <__bss_size>
|
||||
0+8003 <_start\+0x3> bne 0x0+8007 <L1>
|
||||
0+8005 <_start\+0x5> bsr 0x0+800b <foo>
|
||||
0+8007 <L1> bset \*0x0+ <__bss_size>, \#0x04
|
||||
0+800a <L2> rts
|
||||
0+800b <foo> rts
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
.*: +file format elf32-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> ldx #0+1100 <__data_section_start>
|
||||
0+8003 <_start\+0x3> bset 0,x \#\$04
|
||||
0+8006 <L1> ldd \#0+2 <__bss_size\+0x2>
|
||||
0+8009 <L1\+0x3> std \*0+ <__bss_size>
|
||||
0+8000 <_start> ldx #0x0+1100 <__data_section_start>
|
||||
0+8003 <_start\+0x3> bset 0x0,x, \#0x04
|
||||
0+8006 <L1> ldd \#0x0+2 <__bss_size\+0x2>
|
||||
0+8009 <L1\+0x3> std \*0x0+ <__bss_size>
|
||||
0+800b <L1\+0x5> rts
|
||||
|
|
|
@ -7,66 +7,66 @@
|
|||
|
||||
Disassembly of section .text:
|
||||
0+8000 <tramp._far_foo> pshb
|
||||
0+8001 <tramp._far_foo\+0x1> ldab \#0
|
||||
0+8003 <tramp._far_foo\+0x3> ldy \#0+8072 <_far_foo>
|
||||
0+8007 <tramp._far_foo\+0x7> jmp 0+8056 <__far_trampoline>
|
||||
0+8001 <tramp._far_foo\+0x1> ldab \#0x0
|
||||
0+8003 <tramp._far_foo\+0x3> ldy \#0x0+8072 <_far_foo>
|
||||
0+8007 <tramp._far_foo\+0x7> jmp 0x0+8056 <__far_trampoline>
|
||||
0+800a <tramp._far_bar> pshb
|
||||
0+800b <tramp._far_bar\+0x1> ldab \#0
|
||||
0+800d <tramp._far_bar\+0x3> ldy \#0+806a .*
|
||||
0+8011 <tramp._far_bar\+0x7> jmp 0+8056 <__far_trampoline>
|
||||
0+8014 <_start> lds \#0+64 <stack>
|
||||
0+8017 <_start\+0x3> ldx \#0+abcd .*
|
||||
0+800b <tramp._far_bar\+0x1> ldab \#0x0
|
||||
0+800d <tramp._far_bar\+0x3> ldy \#0x0+806a .*
|
||||
0+8011 <tramp._far_bar\+0x7> jmp 0x0+8056 <__far_trampoline>
|
||||
0+8014 <_start> lds \#0x0+64 <stack>
|
||||
0+8017 <_start\+0x3> ldx \#0x0+abcd .*
|
||||
0+801a <_start\+0x6> pshx
|
||||
0+801b <_start\+0x7> ldd \#0+1234 .*
|
||||
0+801e <_start\+0xa> ldx \#0+5678 .*
|
||||
0+8021 <_start\+0xd> jsr 0+800a <tramp._far_bar>
|
||||
0+8024 <_start\+0x10> cpx \#0+1234 .*
|
||||
0+8027 <_start\+0x13> bne 0+804e <fail>
|
||||
0+8029 <_start\+0x15> cpd \#0+5678 .*
|
||||
0+802d <_start\+0x19> bne 0+804e <fail>
|
||||
0+801b <_start\+0x7> ldd \#0x0+1234 .*
|
||||
0+801e <_start\+0xa> ldx \#0x0+5678 .*
|
||||
0+8021 <_start\+0xd> jsr 0x0+800a <tramp._far_bar>
|
||||
0+8024 <_start\+0x10> cpx \#0x0+1234 .*
|
||||
0+8027 <_start\+0x13> bne 0x0+804e <fail>
|
||||
0+8029 <_start\+0x15> cpd \#0x0+5678 .*
|
||||
0+802d <_start\+0x19> bne 0x0+804e <fail>
|
||||
0+802f <_start\+0x1b> pulx
|
||||
0+8030 <_start\+0x1c> cpx \#0+abcd .*
|
||||
0+8033 <_start\+0x1f> bne 0+804e <fail>
|
||||
0+8035 <_start\+0x21> ldd \#0+8000 <tramp._far_foo>
|
||||
0+8030 <_start\+0x1c> cpx \#0x0+abcd .*
|
||||
0+8033 <_start\+0x1f> bne 0x0+804e <fail>
|
||||
0+8035 <_start\+0x21> ldd \#0x0+8000 <tramp._far_foo>
|
||||
0+8038 <_start\+0x24> xgdx
|
||||
0+8039 <_start\+0x25> jsr 0,x
|
||||
0+803b <_start\+0x27> ldd \#0+800a <tramp._far_bar>
|
||||
0+8039 <_start\+0x25> jsr 0x0,x
|
||||
0+803b <_start\+0x27> ldd \#0x0+800a <tramp._far_bar>
|
||||
0+803e <_start\+0x2a> xgdy
|
||||
0+8040 <_start\+0x2c> jsr 0,y
|
||||
0+8043 <_start\+0x2f> ldaa \#0
|
||||
0+8045 <_start\+0x31> ldy \#0+8079 <_far_no_tramp>
|
||||
0+8049 <_start\+0x35> bsr 0+8066 <__call_a16>
|
||||
0+8040 <_start\+0x2c> jsr 0x0,y
|
||||
0+8043 <_start\+0x2f> ldaa \#0x0
|
||||
0+8045 <_start\+0x31> ldy \#0x0+8079 <_far_no_tramp>
|
||||
0+8049 <_start\+0x35> bsr 0x0+8066 <__call_a16>
|
||||
0+804b <_start\+0x37> clra
|
||||
0+804c <_start\+0x38> clrb
|
||||
0+804d <_start\+0x39> wai
|
||||
0+804e <fail> ldd \#0+1 <__bss_size\+0x1>
|
||||
0+804e <fail> ldd \#0x0+1 <__bss_size\+0x1>
|
||||
0+8051 <fail\+0x3> wai
|
||||
0+8052 <fail\+0x4> bra 0+8014 <_start>
|
||||
0+8052 <fail\+0x4> bra 0x0+8014 <_start>
|
||||
0+8054 <__return> ins
|
||||
0+8055 <__return\+0x1> rts
|
||||
0+8056 <__far_trampoline> psha
|
||||
0+8057 <__far_trampoline\+0x1> psha
|
||||
0+8058 <__far_trampoline\+0x2> pshx
|
||||
0+8059 <__far_trampoline\+0x3> tsx
|
||||
0+805a <__far_trampoline\+0x4> ldab 4,x
|
||||
0+805c <__far_trampoline\+0x6> ldaa 2,x
|
||||
0+805e <__far_trampoline\+0x8> staa 4,x
|
||||
0+805a <__far_trampoline\+0x4> ldab 0x4,x
|
||||
0+805c <__far_trampoline\+0x6> ldaa 0x2,x
|
||||
0+805e <__far_trampoline\+0x8> staa 0x4,x
|
||||
0+8060 <__far_trampoline\+0xa> pulx
|
||||
0+8061 <__far_trampoline\+0xb> pula
|
||||
0+8062 <__far_trampoline\+0xc> pula
|
||||
0+8063 <__far_trampoline\+0xd> jmp 0,y
|
||||
0+8063 <__far_trampoline\+0xd> jmp 0x0,y
|
||||
0+8066 <__call_a16> psha
|
||||
0+8067 <__call_a16\+0x1> jmp 0,y
|
||||
0+8067 <__call_a16\+0x1> jmp 0x0,y
|
||||
Disassembly of section .bank1:
|
||||
0+806a <_far_bar> jsr 0+8071 <local_bank1>
|
||||
0+806a <_far_bar> jsr 0x0+8071 <local_bank1>
|
||||
0+806d <_far_bar\+0x3> xgdx
|
||||
0+806e <_far_bar\+0x4> jmp 0+8054 <__return>
|
||||
0+806e <_far_bar\+0x4> jmp 0x0+8054 <__return>
|
||||
0+8071 <local_bank1> rts
|
||||
Disassembly of section .bank2:
|
||||
0+8072 <_far_foo> jsr 0+8078 <local_bank2>
|
||||
0+8075 <_far_foo\+0x3> jmp 0+8054 <__return>
|
||||
0+8072 <_far_foo> jsr 0x0+8078 <local_bank2>
|
||||
0+8075 <_far_foo\+0x3> jmp 0x0+8054 <__return>
|
||||
0+8078 <local_bank2> rts
|
||||
Disassembly of section .bank3:
|
||||
0+8079 <_far_no_tramp> jsr 0+807f <local_bank3>
|
||||
0+807c <_far_no_tramp\+0x3> jmp 0+8054 <__return>
|
||||
0+8079 <_far_no_tramp> jsr 0x0+807f <local_bank3>
|
||||
0+807c <_far_no_tramp\+0x3> jmp 0x0+8054 <__return>
|
||||
0+807f <local_bank3> rts
|
||||
|
|
|
@ -6,49 +6,49 @@
|
|||
.*: file format elf32\-m68hc12
|
||||
|
||||
Disassembly of section .text:
|
||||
0+c000 <tramp\._far_foo> ldy \#0+8000 <__bank_start>
|
||||
0+c003 <tramp\._far_foo\+0x3> call 0+c049 <__far_trampoline> \{0+c049 <__far_trampoline>, 1\}
|
||||
0+c007 <tramp\._far_bar> ldy \#0+8000 <__bank_start>
|
||||
0+c00a <tramp\._far_bar\+0x3> call 0+c049 <__far_trampoline> \{0+c049 <__far_trampoline>, 0\}
|
||||
0+c00e <_start> lds \#0+2063 <stack-0x1>
|
||||
0+c011 <_start\+0x3> ldx \#0+abcd <__bank_start\+0x2bcd>
|
||||
0+c000 <tramp\._far_foo> ldy \#0x0+8000 <__bank_start>
|
||||
0+c003 <tramp\._far_foo\+0x3> call 0x0+c049 <__far_trampoline> \{0x0+c049 <__far_trampoline>, 0x1\}
|
||||
0+c007 <tramp\._far_bar> ldy \#0x0+8000 <__bank_start>
|
||||
0+c00a <tramp\._far_bar\+0x3> call 0x0+c049 <__far_trampoline> \{0x0+c049 <__far_trampoline>, 0x0\}
|
||||
0+c00e <_start> lds \#0x0+2063 <stack-0x1>
|
||||
0+c011 <_start\+0x3> ldx \#0x0+abcd <__bank_start\+0x2bcd>
|
||||
0+c014 <_start\+0x6> pshx
|
||||
0+c015 <_start\+0x7> ldd \#0+1234 <stack\-0xe30>
|
||||
0+c018 <_start\+0xa> ldx \#0+5678 <__bank_size\+0x1678>
|
||||
0+c01b <_start\+0xd> jsr 0+c007 <tramp._far_bar>
|
||||
0+c01e <_start\+0x10> cpx \#0+1234 <stack\-0xe30>
|
||||
0+c021 <_start\+0x13> bne 0+c043 <fail>
|
||||
0+c023 <_start\+0x15> cpd \#0+5678 <__bank_size\+0x1678>
|
||||
0+c026 <_start\+0x18> bne 0+c043 <fail>
|
||||
0+c015 <_start\+0x7> ldd \#0x0+1234 <stack\-0xe30>
|
||||
0+c018 <_start\+0xa> ldx \#0x0+5678 <__bank_size\+0x1678>
|
||||
0+c01b <_start\+0xd> jsr 0x0+c007 <tramp._far_bar>
|
||||
0+c01e <_start\+0x10> cpx \#0x0+1234 <stack\-0xe30>
|
||||
0+c021 <_start\+0x13> bne 0x0+c043 <fail>
|
||||
0+c023 <_start\+0x15> cpd \#0x0+5678 <__bank_size\+0x1678>
|
||||
0+c026 <_start\+0x18> bne 0x0+c043 <fail>
|
||||
0+c028 <_start\+0x1a> pulx
|
||||
0+c029 <_start\+0x1b> cpx \#0+abcd <__bank_start\+0x2bcd>
|
||||
0+c02c <_start\+0x1e> bne 0+c043 <fail>
|
||||
0+c02e <_start\+0x20> ldd \#0+c000 <tramp._far_foo>
|
||||
0+c029 <_start\+0x1b> cpx \#0x0+abcd <__bank_start\+0x2bcd>
|
||||
0+c02c <_start\+0x1e> bne 0x0+c043 <fail>
|
||||
0+c02e <_start\+0x20> ldd \#0x0+c000 <tramp._far_foo>
|
||||
0+c031 <_start\+0x23> xgdx
|
||||
0+c033 <_start\+0x25> jsr 0,X
|
||||
0+c035 <_start\+0x27> ldd \#0+c007 <tramp._far_bar>
|
||||
0+c033 <_start\+0x25> jsr 0x0,X
|
||||
0+c035 <_start\+0x27> ldd \#0x0+c007 <tramp._far_bar>
|
||||
0+c038 <_start\+0x2a> xgdy
|
||||
0+c03a <_start\+0x2c> jsr 0,Y
|
||||
0+c03c <_start\+0x2e> call 0+18000 <_far_no_tramp> \{0+8000 <__bank_start>, 2\}
|
||||
0+c03a <_start\+0x2c> jsr 0x0,Y
|
||||
0+c03c <_start\+0x2e> call 0x0+18000 <_far_no_tramp> \{0x0+8000 <__bank_start>, 0x2\}
|
||||
0+c040 <_start\+0x32> clra
|
||||
0+c041 <_start\+0x33> clrb
|
||||
0+c042 <_start\+0x34> wai
|
||||
0+c043 <fail> ldd \#0+1 <stack\-0x2063>
|
||||
0+c043 <fail> ldd \#0x0+1 <stack\-0x2063>
|
||||
0+c046 <fail\+0x3> wai
|
||||
0+c047 <fail\+0x4> bra 0+c00e <_start>
|
||||
0+c049 <__far_trampoline> movb 0,SP, 2,SP
|
||||
0+c04d <__far_trampoline\+0x4> leas 2,SP
|
||||
0+c04f <__far_trampoline\+0x6> jmp 0,Y
|
||||
0+c047 <fail\+0x4> bra 0x0+c00e <_start>
|
||||
0+c049 <__far_trampoline> movb 0x0,SP, 0x2,SP
|
||||
0+c04d <__far_trampoline\+0x4> leas 0x2,SP
|
||||
0+c04f <__far_trampoline\+0x6> jmp 0x0,Y
|
||||
Disassembly of section .bank1:
|
||||
0+10+ <_far_bar> jsr 0+10006 <local_bank1>
|
||||
0+10+ <_far_bar> jsr 0x0+10006 <local_bank1>
|
||||
0+10003 <_far_bar\+0x3> xgdx
|
||||
0+10005 <_far_bar\+0x5> rtc
|
||||
0+10006 <local_bank1> rts
|
||||
Disassembly of section .bank2:
|
||||
0+14000 <_far_foo> jsr 0+14004 <local_bank2>
|
||||
0+14000 <_far_foo> jsr 0x0+14004 <local_bank2>
|
||||
0+14003 <_far_foo\+0x3> rtc
|
||||
0+14004 <local_bank2> rts
|
||||
Disassembly of section .bank3:
|
||||
0+18000 <_far_no_tramp> jsr 0+18004 <local_bank3>
|
||||
0+18000 <_far_no_tramp> jsr 0x0+18004 <local_bank3>
|
||||
0+18003 <_far_no_tramp\+0x3> rtc
|
||||
0+18004 <local_bank3> rts
|
||||
|
|
|
@ -1,19 +1,19 @@
|
|||
#source: link-hcs12.s -m68hcs12
|
||||
#source: link-hc12.s -m68hc12
|
||||
#as: -mshort
|
||||
#ld: -m m68hc12elf
|
||||
#ld: -m m68hc12elf --script $srcdir/$subdir/far-hc12.ld
|
||||
#objdump: -p -d --prefix-addresses -r
|
||||
|
||||
.*: file format elf32\-m68hc12
|
||||
|
||||
Program Header:
|
||||
LOAD off 0x0+1000 vaddr 0x0+8000 paddr 0x0+8000 align 2\*\*12
|
||||
LOAD off 0x0+1000 vaddr 0x0+c000 paddr 0x0+c000 align 2\*\*12
|
||||
filesz 0x0+6 memsz 0x0+6 flags r-x
|
||||
private flags = 22:\[abi=16\-bit int, 64\-bit double, cpu=HCS12\] \[memory=flat\]
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> jsr 0+8005 <main>
|
||||
0+8003 <_start\+0x3> bra 0+8000 <_start>
|
||||
0+8005 <main> rts
|
||||
0+c000 <_start> jsr 0x0+c005 <main>
|
||||
0+c003 <_start\+0x3> bra 0x0+c000 <_start>
|
||||
0+c005 <main> rts
|
||||
|
||||
|
||||
|
|
|
@ -6,57 +6,57 @@
|
|||
.*: +file format elf32-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> lds \*0+28 <stack>
|
||||
0+8002 <_start\+0x2> ldd \*0+ <__bss_size>
|
||||
0+8004 <_start\+0x4> beq 0+800f <F1>
|
||||
0+8006 <_start\+0x6> bne 0+800b <_start\+0xb>
|
||||
0+8008 <_start\+0x8> jmp 0+8138 <F2>
|
||||
0+800b <_start\+0xb> std \*0+ <__bss_size>
|
||||
0+800d <_start\+0xd> jsr \*0+ <__bss_size>
|
||||
0+800f <F1> addd \*0+4 <_toto>
|
||||
0+8011 <F1\+0x2> bne 0+8000 <_start>
|
||||
0+8013 <F1\+0x4> addd \*0+cc <_table\+0x9a>
|
||||
0+8015 <F1\+0x6> addd 0+114 <_stack_top\+0x1a>
|
||||
0+8018 <F1\+0x9> adca \*0+34 <_table\+0x2>
|
||||
0+801a <F1\+0xb> adcb \*0+35 <_table\+0x3>
|
||||
0+801c <F1\+0xd> adda \*0+36 <_table\+0x4>
|
||||
0+801e <F1\+0xf> addb \*0+37 <_table\+0x5>
|
||||
0+8020 <F1\+0x11> addd \*0+38 <_table\+0x6>
|
||||
0+8022 <F1\+0x13> anda \*0+39 <_table\+0x7>
|
||||
0+8024 <F1\+0x15> andb \*0+3a <_table\+0x8>
|
||||
0+8026 <F1\+0x17> cmpa \*0+3b <_table\+0x9>
|
||||
0+8028 <F1\+0x19> cmpb \*0+3c <_table\+0xa>
|
||||
0+802a <F1\+0x1b> cpd \*0+3d <_table\+0xb>
|
||||
0+802d <F1\+0x1e> cpx \*0+3e <_table\+0xc>
|
||||
0+802f <F1\+0x20> cpy \*0+3f <_table\+0xd>
|
||||
0+8032 <F1\+0x23> eora \*0+40 <_table\+0xe>
|
||||
0+8034 <F1\+0x25> eorb \*0+41 <_table\+0xf>
|
||||
0+8036 <F1\+0x27> jsr \*0+42 <_table\+0x10>
|
||||
0+8038 <F1\+0x29> ldaa \*0+43 <_table\+0x11>
|
||||
0+803a <F1\+0x2b> ldab \*0+44 <_table\+0x12>
|
||||
0+803c <F1\+0x2d> ldd \*0+45 <_table\+0x13>
|
||||
0+803e <F1\+0x2f> lds \*0+46 <_table\+0x14>
|
||||
0+8040 <F1\+0x31> ldx \*0+47 <_table\+0x15>
|
||||
0+8042 <F1\+0x33> ldy \*0+48 <_table\+0x16>
|
||||
0+8045 <F1\+0x36> oraa \*0+49 <_table\+0x17>
|
||||
0+8047 <F1\+0x38> orab \*0+4a <_table\+0x18>
|
||||
0+8049 <F1\+0x3a> sbcb \*0+4b <_table\+0x19>
|
||||
0+804b <F1\+0x3c> sbca \*0+4c <_table\+0x1a>
|
||||
0+804d <F1\+0x3e> staa \*0+4d <_table\+0x1b>
|
||||
0+804f <F1\+0x40> stab \*0+4e <_table\+0x1c>
|
||||
0+8051 <F1\+0x42> std \*0+4f <_table\+0x1d>
|
||||
0+8053 <F1\+0x44> sts \*0+50 <_table\+0x1e>
|
||||
0+8055 <F1\+0x46> stx \*0+51 <_table\+0x1f>
|
||||
0+8057 <F1\+0x48> sty \*0+52 <_table\+0x20>
|
||||
0+805a <F1\+0x4b> suba \*0+53 <_table\+0x21>
|
||||
0+805c <F1\+0x4d> subb \*0+54 <_table\+0x22>
|
||||
0+805e <F1\+0x4f> subd \*0+55 <_table\+0x23>
|
||||
0+8060 <F1\+0x51> bne 0+8000 <_start>
|
||||
0+8062 <F1\+0x53> bra 0+800f <F1>
|
||||
0+8000 <_start> lds \*0x0+28 <stack>
|
||||
0+8002 <_start\+0x2> ldd \*0x0+ <__bss_size>
|
||||
0+8004 <_start\+0x4> beq 0x0+800f <F1>
|
||||
0+8006 <_start\+0x6> bne 0x0+800b <_start\+0xb>
|
||||
0+8008 <_start\+0x8> jmp 0x0+8138 <F2>
|
||||
0+800b <_start\+0xb> std \*0x0+ <__bss_size>
|
||||
0+800d <_start\+0xd> jsr \*0x0+ <__bss_size>
|
||||
0+800f <F1> addd \*0x0+4 <_toto>
|
||||
0+8011 <F1\+0x2> bne 0x0+8000 <_start>
|
||||
0+8013 <F1\+0x4> addd \*0x0+cc <_table\+0x9a>
|
||||
0+8015 <F1\+0x6> addd 0x0+114 <_stack_top\+0x1a>
|
||||
0+8018 <F1\+0x9> adca \*0x0+34 <_table\+0x2>
|
||||
0+801a <F1\+0xb> adcb \*0x0+35 <_table\+0x3>
|
||||
0+801c <F1\+0xd> adda \*0x0+36 <_table\+0x4>
|
||||
0+801e <F1\+0xf> addb \*0x0+37 <_table\+0x5>
|
||||
0+8020 <F1\+0x11> addd \*0x0+38 <_table\+0x6>
|
||||
0+8022 <F1\+0x13> anda \*0x0+39 <_table\+0x7>
|
||||
0+8024 <F1\+0x15> andb \*0x0+3a <_table\+0x8>
|
||||
0+8026 <F1\+0x17> cmpa \*0x0+3b <_table\+0x9>
|
||||
0+8028 <F1\+0x19> cmpb \*0x0+3c <_table\+0xa>
|
||||
0+802a <F1\+0x1b> cpd \*0x0+3d <_table\+0xb>
|
||||
0+802d <F1\+0x1e> cpx \*0x0+3e <_table\+0xc>
|
||||
0+802f <F1\+0x20> cpy \*0x0+3f <_table\+0xd>
|
||||
0+8032 <F1\+0x23> eora \*0x0+40 <_table\+0xe>
|
||||
0+8034 <F1\+0x25> eorb \*0x0+41 <_table\+0xf>
|
||||
0+8036 <F1\+0x27> jsr \*0x0+42 <_table\+0x10>
|
||||
0+8038 <F1\+0x29> ldaa \*0x0+43 <_table\+0x11>
|
||||
0+803a <F1\+0x2b> ldab \*0x0+44 <_table\+0x12>
|
||||
0+803c <F1\+0x2d> ldd \*0x0+45 <_table\+0x13>
|
||||
0+803e <F1\+0x2f> lds \*0x0+46 <_table\+0x14>
|
||||
0+8040 <F1\+0x31> ldx \*0x0+47 <_table\+0x15>
|
||||
0+8042 <F1\+0x33> ldy \*0x0+48 <_table\+0x16>
|
||||
0+8045 <F1\+0x36> oraa \*0x0+49 <_table\+0x17>
|
||||
0+8047 <F1\+0x38> orab \*0x0+4a <_table\+0x18>
|
||||
0+8049 <F1\+0x3a> sbcb \*0x0+4b <_table\+0x19>
|
||||
0+804b <F1\+0x3c> sbca \*0x0+4c <_table\+0x1a>
|
||||
0+804d <F1\+0x3e> staa \*0x0+4d <_table\+0x1b>
|
||||
0+804f <F1\+0x40> stab \*0x0+4e <_table\+0x1c>
|
||||
0+8051 <F1\+0x42> std \*0x0+4f <_table\+0x1d>
|
||||
0+8053 <F1\+0x44> sts \*0x0+50 <_table\+0x1e>
|
||||
0+8055 <F1\+0x46> stx \*0x0+51 <_table\+0x1f>
|
||||
0+8057 <F1\+0x48> sty \*0x0+52 <_table\+0x20>
|
||||
0+805a <F1\+0x4b> suba \*0x0+53 <_table\+0x21>
|
||||
0+805c <F1\+0x4d> subb \*0x0+54 <_table\+0x22>
|
||||
0+805e <F1\+0x4f> subd \*0x0+55 <_table\+0x23>
|
||||
0+8060 <F1\+0x51> bne 0x0+8000 <_start>
|
||||
0+8062 <F1\+0x53> bra 0x0+800f <F1>
|
||||
0+8064 <F1\+0x55> rts
|
||||
0+8065 <no_relax> addd 0+136 <_stack_top\+0x3c>
|
||||
0+8068 <no_relax\+0x3> std 0+122 <_stack_top\+0x28>
|
||||
0+806b <no_relax\+0x6> tst 0+5 <_toto\+0x1>
|
||||
0+806e <no_relax\+0x9> bne 0+8065 <no_relax>
|
||||
0+8065 <no_relax> addd 0x0+136 <_stack_top\+0x3c>
|
||||
0+8068 <no_relax\+0x3> std 0x0+122 <_stack_top\+0x28>
|
||||
0+806b <no_relax\+0x6> tst 0x0+5 <_toto\+0x1>
|
||||
0+806e <no_relax\+0x9> bne 0x0+8065 <no_relax>
|
||||
...
|
||||
0+8138 <F2> jmp 0+8000 <_start>
|
||||
0+8138 <F2> jmp 0x0+8000 <_start>
|
||||
|
|
|
@ -6,57 +6,57 @@
|
|||
.*: +file format elf32-m68hc11
|
||||
|
||||
Disassembly of section .text:
|
||||
0+8000 <_start> bset \*0+ <__bss_size> #\$04
|
||||
0+8003 <L1x> bset \*0+ <__bss_size> #\$04
|
||||
0+8006 <L1y> bset \*0+3 <__bss_size\+0x3> #\$04
|
||||
0+8009 <L1y\+0x3> bset \*0+4 <table4> #\$08
|
||||
0+800c <L2x> bset \*0+3 <__bss_size\+0x3> #\$04
|
||||
0+800f <L2x\+0x3> bset \*0+4 <table4> #\$08
|
||||
0+8012 <L2y> bset \*0+6 <table4\+0x2> #\$04
|
||||
0+8015 <L2y\+0x3> bset \*0+7 <table4\+0x3> #\$08
|
||||
0+8018 <L2y\+0x6> bset \*0+8 <table8> #\$0c
|
||||
0+801b <L2y\+0x9> bset \*0+9 <table8\+0x1> #\$0c
|
||||
0+801e <L2y\+0xc> bset \*0+a <table8\+0x2> #\$0c
|
||||
0+8021 <L2y\+0xf> bset \*0+b <table8\+0x3> #\$0c
|
||||
0+8024 <L3x> bset \*0+6 <table4\+0x2> #\$04
|
||||
0+8027 <L3x\+0x3> bset \*0+7 <table4\+0x3> #\$08
|
||||
0+802a <L3x\+0x6> bset \*0+8 <table8> #\$0c
|
||||
0+802d <L3x\+0x9> bset \*0+9 <table8\+0x1> #\$0c
|
||||
0+8030 <L3x\+0xc> bset \*0+a <table8\+0x2> #\$0c
|
||||
0+8033 <L3x\+0xf> bset \*0+b <table8\+0x3> #\$0c
|
||||
0+8036 <L3y> bra 0+8000 <_start>
|
||||
0+8038 <L3y\+0x2> ldx #0+fe <end_table\+0xe8>
|
||||
0+803b <L3y\+0x5> bset \*0+fe <end_table\+0xe8> #\$04
|
||||
0+803e <L3y\+0x8> bset \*0+ff <end_table\+0xe9> #\$08
|
||||
0+8041 <L3y\+0xb> bset 2,x #\$0c
|
||||
0+8044 <L3y\+0xe> bset 3,x #\$0c
|
||||
0+8047 <L3y\+0x11> bset 4,x #\$0c
|
||||
0+804a <L3y\+0x14> bset 5,x #\$0c
|
||||
0+804d <L4x> ldy #0+fe <end_table\+0xe8>
|
||||
0+8051 <L4x\+0x4> bset \*0+fe <end_table\+0xe8> #\$04
|
||||
0+8054 <L4x\+0x7> bset \*0+ff <end_table\+0xe9> #\$08
|
||||
0+8057 <L4x\+0xa> bset 2,y #\$0c
|
||||
0+805b <L4x\+0xe> bset 3,y #\$0c
|
||||
0+805f <L4x\+0x12> bset 4,y #\$0c
|
||||
0+8063 <L4x\+0x16> bset 5,y #\$0c
|
||||
0+8067 <L4y> bclr \*0+a <table8\+0x2> #\$04
|
||||
0+806a <L4y\+0x3> bclr \*0+b <table8\+0x3> #\$08
|
||||
0+806d <L5x> bclr \*0+1a <end_table\+0x4> #\$04
|
||||
0+8070 <L5x\+0x3> bclr \*0+1b <end_table\+0x5> #\$08
|
||||
0+8073 <L5y> brset \*0+8 <table8> #\$04 0+8073 <L5y>
|
||||
0+8077 <L6x> brset \*0+8 <table8> #\$04 0+8077 <L6x>
|
||||
0+807b <L7x> brset \*0+8 <table8> #\$04 0+8094 <brend>
|
||||
0+807f <L8x> brset \*0+8 <table8> #\$04 0+8094 <brend>
|
||||
0+8083 <L8y> brclr \*0+8 <table8> #\$04 0+8083 <L8y>
|
||||
0+8087 <L9x> brclr \*0+8 <table8> #\$04 0+8087 <L9x>
|
||||
0+808b <L9y> brclr \*0+8 <table8> #\$04 0+8094 <brend>
|
||||
0+808f <L10x> brclr \*0+8 <table8> #\$04 0+8094 <brend>
|
||||
0+8000 <_start> bset \*0x0+ <__bss_size>, #0x04
|
||||
0+8003 <L1x> bset \*0x0+ <__bss_size>, #0x04
|
||||
0+8006 <L1y> bset \*0x0+3 <__bss_size\+0x3>, #0x04
|
||||
0+8009 <L1y\+0x3> bset \*0x0+4 <table4>, #0x08
|
||||
0+800c <L2x> bset \*0x0+3 <__bss_size\+0x3>, #0x04
|
||||
0+800f <L2x\+0x3> bset \*0x0+4 <table4>, #0x08
|
||||
0+8012 <L2y> bset \*0x0+6 <table4\+0x2>, #0x04
|
||||
0+8015 <L2y\+0x3> bset \*0x0+7 <table4\+0x3>, #0x08
|
||||
0+8018 <L2y\+0x6> bset \*0x0+8 <table8>, #0x0c
|
||||
0+801b <L2y\+0x9> bset \*0x0+9 <table8\+0x1>, #0x0c
|
||||
0+801e <L2y\+0xc> bset \*0x0+a <table8\+0x2>, #0x0c
|
||||
0+8021 <L2y\+0xf> bset \*0x0+b <table8\+0x3>, #0x0c
|
||||
0+8024 <L3x> bset \*0x0+6 <table4\+0x2>, #0x04
|
||||
0+8027 <L3x\+0x3> bset \*0x0+7 <table4\+0x3>, #0x08
|
||||
0+802a <L3x\+0x6> bset \*0x0+8 <table8>, #0x0c
|
||||
0+802d <L3x\+0x9> bset \*0x0+9 <table8\+0x1>, #0x0c
|
||||
0+8030 <L3x\+0xc> bset \*0x0+a <table8\+0x2>, #0x0c
|
||||
0+8033 <L3x\+0xf> bset \*0x0+b <table8\+0x3>, #0x0c
|
||||
0+8036 <L3y> bra 0x0+8000 <_start>
|
||||
0+8038 <L3y\+0x2> ldx #0x0+fe <end_table\+0xe8>
|
||||
0+803b <L3y\+0x5> bset \*0x0+fe <end_table\+0xe8>, #0x04
|
||||
0+803e <L3y\+0x8> bset \*0x0+ff <end_table\+0xe9>, #0x08
|
||||
0+8041 <L3y\+0xb> bset 0x2,x, #0x0c
|
||||
0+8044 <L3y\+0xe> bset 0x3,x, #0x0c
|
||||
0+8047 <L3y\+0x11> bset 0x4,x, #0x0c
|
||||
0+804a <L3y\+0x14> bset 0x5,x, #0x0c
|
||||
0+804d <L4x> ldy #0x0+fe <end_table\+0xe8>
|
||||
0+8051 <L4x\+0x4> bset \*0x0+fe <end_table\+0xe8>, #0x04
|
||||
0+8054 <L4x\+0x7> bset \*0x0+ff <end_table\+0xe9>, #0x08
|
||||
0+8057 <L4x\+0xa> bset 0x2,y, #0x0c
|
||||
0+805b <L4x\+0xe> bset 0x3,y, #0x0c
|
||||
0+805f <L4x\+0x12> bset 0x4,y, #0x0c
|
||||
0+8063 <L4x\+0x16> bset 0x5,y, #0x0c
|
||||
0+8067 <L4y> bclr \*0x0+a <table8\+0x2>, #0x04
|
||||
0+806a <L4y\+0x3> bclr \*0x0+b <table8\+0x3>, #0x08
|
||||
0+806d <L5x> bclr \*0x0+1a <end_table\+0x4>, #0x04
|
||||
0+8070 <L5x\+0x3> bclr \*0x0+1b <end_table\+0x5>, #0x08
|
||||
0+8073 <L5y> brset \*0x0+8 <table8>, #0x04, 0x0+8073 <L5y>
|
||||
0+8077 <L6x> brset \*0x0+8 <table8>, #0x04, 0x0+8077 <L6x>
|
||||
0+807b <L7x> brset \*0x0+8 <table8>, #0x04, 0x0+8094 <brend>
|
||||
0+807f <L8x> brset \*0x0+8 <table8>, #0x04, 0x0+8094 <brend>
|
||||
0+8083 <L8y> brclr \*0x0+8 <table8>, #0x04, 0x0+8083 <L8y>
|
||||
0+8087 <L9x> brclr \*0x0+8 <table8>, #0x04, 0x0+8087 <L9x>
|
||||
0+808b <L9y> brclr \*0x0+8 <table8>, #0x04, 0x0+8094 <brend>
|
||||
0+808f <L10x> brclr \*0x0+8 <table8>, #0x04, 0x0+8094 <brend>
|
||||
0+8093 <L10y> nop
|
||||
0+8094 <brend> bset 0,x #\$04
|
||||
0+8097 <w2> ldx #0+ <__bss_size>
|
||||
0+809a <w3> ldy #0+8 <table8>
|
||||
0+8094 <brend> bset 0x0,x, #0x04
|
||||
0+8097 <w2> ldx #0x0+ <__bss_size>
|
||||
0+809a <w3> ldy #0x0+8 <table8>
|
||||
0+809e <w4> rts
|
||||
0+809f <w5> ldx #0+ <__bss_size>
|
||||
0+80a2 <w5\+0x3> bset 0,x #\$05
|
||||
0+80a5 <w5\+0x6> jmp 0+8000 <_start>
|
||||
0+809f <w5> ldx #0x0+ <__bss_size>
|
||||
0+80a2 <w5\+0x3> bset 0x0,x, #0x05
|
||||
0+80a5 <w5\+0x6> jmp 0x0+8000 <_start>
|
||||
0+80a8 <w5\+0x9> rts
|
||||
|
|
25
ld/testsuite/ld-m68hc11/xgate-link.d
Normal file
25
ld/testsuite/ld-m68hc11/xgate-link.d
Normal file
|
@ -0,0 +1,25 @@
|
|||
#as: -mm9s12xg
|
||||
#source: xgate-link.s
|
||||
#ld: --relax -mm68hc12elf -defsym var1=0xfeed -defsym var2=0xdeaf -defsym var3=0xa1b2 -defsym var4=0x3456 -defsym var5=0xfa -defsym var6=0x20fe
|
||||
#objdump: -d --prefix-addresses -r -mm9s12xg
|
||||
|
||||
tmpdir/dump: file format elf32-m68hc12
|
||||
|
||||
|
||||
Disassembly of section .text:
|
||||
00008000 <_start> ldl R1, #0xed
|
||||
00008002 <_start\+0x2> ldh R1, #0xfe
|
||||
00008004 <_start\+0x4> addl R5, #0xaf
|
||||
00008006 <_start\+0x6> addh R5, #0xde
|
||||
00008008 <_start\+0x8> ldl R2, #0x56
|
||||
0000800a <_start\+0xa> ldh R2, #0x34
|
||||
0000800c <_start\+0xc> ldl R3, #0x21
|
||||
0000800e <_start\+0xe> ldh R6, #0xfa
|
||||
00008010 <_start\+0x10> cmpl R1, #0xcd
|
||||
00008012 <_start\+0x12> cpch R1, #0xab
|
||||
00008014 <_start\+0x14> cmpl R2, #0xb2
|
||||
00008016 <_start\+0x16> cpch R2, #0xa1
|
||||
00008018 <_start\+0x18> ldl R1, #0xfe
|
||||
0000801a <_start\+0x1a> ldh R1, #0x20
|
||||
0000801c <_start\+0x1c> ldl R2, #0x02
|
||||
0000801e <_start\+0x1e> ldh R2, #0x22
|
16
ld/testsuite/ld-m68hc11/xgate-link.s
Normal file
16
ld/testsuite/ld-m68hc11/xgate-link.s
Normal file
|
@ -0,0 +1,16 @@
|
|||
;;; Test 16bit relocate with XGATE
|
||||
;;;
|
||||
.sect .text
|
||||
.globl _start
|
||||
_start:
|
||||
|
||||
ldw r1,#var1 ; expands to two IMM8 %hi,%lo relocate
|
||||
add r5,#var2 ; expands to two IMM8 %hi,%lo relocate
|
||||
ldl r2,#%lovar4 ; test explicit %lo
|
||||
ldh r2,#%hivar4 ; test explicit %hi
|
||||
ldl r3,#0x21 ; regular IMM8
|
||||
ldh r6,#var5 ; IMM8 with relocate
|
||||
cmp r1,#0xabcd ; expands to two IMM8 with constant
|
||||
cmp r2,#var3 ; expands to two IMM8 %hi,%lo relocate
|
||||
ldw r1,#var6
|
||||
ldw r2,#var6+0x104 ; check for correct carry
|
13
ld/testsuite/ld-m68hc11/xgate-offset.d
Normal file
13
ld/testsuite/ld-m68hc11/xgate-offset.d
Normal file
|
@ -0,0 +1,13 @@
|
|||
#as: -mm9s12xg --xgate-ramoffset
|
||||
#source: xgate-offset.s
|
||||
#ld: --relax -mm68hc12elf -defsym var=0x20fe
|
||||
#objdump: -d --prefix-addresses -r -mm9s12xg
|
||||
|
||||
tmpdir/dump: file format elf32-m68hc12
|
||||
|
||||
|
||||
Disassembly of section .text:
|
||||
00008000 <_start> ldl R1, #0xfe
|
||||
00008002 <_start\+0x2> ldh R1, #0xe0
|
||||
00008004 <_start\+0x4> ldl R2, #0x04
|
||||
00008006 <_start\+0x6> ldh R2, #0xe2
|
8
ld/testsuite/ld-m68hc11/xgate-offset.s
Normal file
8
ld/testsuite/ld-m68hc11/xgate-offset.s
Normal file
|
@ -0,0 +1,8 @@
|
|||
;;; Test 16bit relocate with --xgate-ramoffset
|
||||
;;;
|
||||
.sect .text
|
||||
.globl _start
|
||||
_start:
|
||||
|
||||
ldw r1,#var
|
||||
ldw r2,#var+0x106 ; check for correct carry too
|
24
ld/testsuite/ld-m68hc11/xgate1.d
Normal file
24
ld/testsuite/ld-m68hc11/xgate1.d
Normal file
|
@ -0,0 +1,24 @@
|
|||
#as: -mm9s12xg
|
||||
#source: xgate1.s
|
||||
#source: xgate2.s
|
||||
#ld: --relax -mm68hc12elf
|
||||
#objdump: -d --prefix-addresses -r -mm9s12xg
|
||||
|
||||
tmpdir/dump: file format elf32-m68hc12
|
||||
|
||||
|
||||
Disassembly of section .text:
|
||||
00008000 <_start> ldl R1, \#0x00
|
||||
00008002 <_start\+0x2> ldh R1, \#0x11
|
||||
00008004 <_start\+0x4> sub R0, R1, R0
|
||||
00008006 <_start\+0x6> beq 0x0+8010 <linked_ad1>
|
||||
00008008 <_start\+0x8> sub R0, R2, R0
|
||||
0000800a <_start\+0xa> beq 0x0+800e <the_end>
|
||||
0000800c <_start\+0xc> bra 0x0+8018 <linked_ad2>
|
||||
0000800e <the_end> rts
|
||||
00008010 <linked_ad1> cmpl R4, \#0x01
|
||||
00008012 <linked_ad1\+0x2> bne 0x0+8018 <linked_ad2>
|
||||
00008014 <label1> nop
|
||||
00008016 <label1\+0x2> par R5
|
||||
00008018 <linked_ad2> csem \#0x2
|
||||
0000801a <linked_ad2\+0x2> rts
|
18
ld/testsuite/ld-m68hc11/xgate1.s
Normal file
18
ld/testsuite/ld-m68hc11/xgate1.s
Normal file
|
@ -0,0 +1,18 @@
|
|||
;;; Test branches and branch relocate with XGATE
|
||||
;;;
|
||||
.sect .text
|
||||
.globl _start
|
||||
_start:
|
||||
|
||||
ldw r1,#var1 ; expands to two IMM8 %hi,%lo relocate
|
||||
tst r1
|
||||
beq linked_ad1
|
||||
tst r2
|
||||
beq the_end
|
||||
bra linked_ad2
|
||||
|
||||
the_end:
|
||||
rts
|
||||
|
||||
.sect .data
|
||||
var1: fdb 0x1234
|
16
ld/testsuite/ld-m68hc11/xgate2.s
Normal file
16
ld/testsuite/ld-m68hc11/xgate2.s
Normal file
|
@ -0,0 +1,16 @@
|
|||
;;; Part2 of branch test
|
||||
;;;
|
||||
.globl linked_ad1, linked_ad2
|
||||
.sect .text
|
||||
|
||||
linked_ad1:
|
||||
cmpl r4,#1
|
||||
bne linked_ad2
|
||||
|
||||
label1:
|
||||
nop
|
||||
par r5
|
||||
|
||||
linked_ad2:
|
||||
csem #2
|
||||
rts
|
|
@ -57,6 +57,10 @@ set regclm "-plugin-opt registerclaimfile"
|
|||
set regas "-plugin-opt registerallsymbolsread"
|
||||
set regcln "-plugin-opt registercleanup"
|
||||
|
||||
if { [istarget m681*-*-*] || [istarget m68hc1*-*-*] || [istarget m9s12x*-*-*] } {
|
||||
# otherwise get FAILS due to _.frame
|
||||
set CFLAGS "$CFLAGS -fomit-frame-pointer"
|
||||
}
|
||||
# In order to define symbols in plugin options in the list of tests below,
|
||||
# we need to know if the platform prepends an underscore to C symbols,
|
||||
# which we find out by compiling the test objects now. If there is any
|
||||
|
|
|
@ -276,6 +276,21 @@ proc run_srec_test { test objs } {
|
|||
setup_xfail "epiphany*-*-*"
|
||||
}
|
||||
|
||||
if [istarget m681*-*-*] {
|
||||
set flags "$flags --defsym _start=0xc000"
|
||||
setup_xfail "m681*-*-*"
|
||||
}
|
||||
|
||||
if [istarget m68hc1*-*-*] {
|
||||
set flags "$flags --defsym _start=0xc000"
|
||||
setup_xfail "m68hc1*-*-*"
|
||||
}
|
||||
|
||||
if [istarget m9s12x*-*-*] {
|
||||
set flags "$flags --defsym _start=0xc000"
|
||||
setup_xfail "m9s12x*-*-*"
|
||||
}
|
||||
|
||||
if { ![ld_simple_link $ld tmpdir/sr1 "$flags $objs"] \
|
||||
|| ![ld_simple_link $ld tmpdir/sr2.sr "$flags --oformat srec $objs"] } {
|
||||
fail $test
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue