diff options
author | Jing Yu <jingyu@google.com> | 2011-12-20 10:27:58 -0800 |
---|---|---|
committer | Jing Yu <jingyu@google.com> | 2011-12-20 10:27:58 -0800 |
commit | cf3cdbf8b3cda61a619299e7966a83df66244036 (patch) | |
tree | 201e2bcfc955f16802d3257112d29736cb3a3ce8 /binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s | |
parent | e4df3e0a5bb640ccfa2f30ee67fe9b3146b152d6 (diff) | |
download | toolchain_binutils-cf3cdbf8b3cda61a619299e7966a83df66244036.zip toolchain_binutils-cf3cdbf8b3cda61a619299e7966a83df66244036.tar.gz toolchain_binutils-cf3cdbf8b3cda61a619299e7966a83df66244036.tar.bz2 |
Add binutils-2.21.
Use --enable-gold=default for dual linker support.
Change-Id: Id1a744c7db58a0b5e7a3be174cdfa875f2f86e49
Diffstat (limited to 'binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s')
-rw-r--r-- | binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s b/binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s new file mode 100644 index 0000000..1aaff41 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-m68hc11/adj-brset.s @@ -0,0 +1,51 @@ +;;; Test 68HC11 linker relaxation and fixup of brclr/brset branches +;;; + .sect .text + .globl _start +_start: +start: + brclr 140,x#200,L8 ; Branch adjustment covers the whole test +;;; The 'addd' is relaxed and we win 1 byte. The next brclr/brset +;;; branch must be fixed and reduced by 1. We check for different +;;; addressing modes because the instruction has different opcode and +;;; different lengths. +L1: + addd _toto + brclr 20,x,#3,L1 + brclr 90,x,#99,L3 ; Likewise with forward branch +L2: + addd _toto + brclr 19,y,#4,L2 + brclr 91,y,#98,L4 +L3: + addd _toto + brset 18,x,#5,L3 + brset 92,x,#97,L5 +L4: + addd _toto + brset 17,y,#6,L4 + brset 93,y,#96,L5 +L5: + addd _toto + brset *_table,#7,L5 + brset *_table+10,#95,L7 +L6: + addd _toto + brclr *_table+1,#8,L6 + brset *_table+11,#94,L8 +L7: + addd _toto + brclr *_table+1,#8,L6 +L8: + brclr 140,x#200,_start ; Branch adjustment covers the whole test + rts + + .sect .page0 +_bar: + .long 0 +_toto: + .long 0 + .skip 32 +stack: + .skip 10 +_table: |