diff options
Diffstat (limited to 'binutils-2.21/ld/testsuite/ld-frv')
74 files changed, 4617 insertions, 0 deletions
diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-1.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-1.d new file mode 100644 index 0000000..0e37324 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-1.d @@ -0,0 +1,57 @@ +#name: FRV uClinux PIC relocs to local symbols, pie linking +#source: fdpic1.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+ <F1>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <\.F0> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf+ff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff ec addi gr15,-20,gr0 +[0-9a-f ]+: 80 fc ff ec setlos 0xf+fec,gr0 +[0-9a-f ]+: 80 f4 ff ec setlo 0xffec,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.data: + +[0-9a-f ]+<D1>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-2.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-2.d new file mode 100644 index 0000000..3583a3b --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-2.d @@ -0,0 +1,71 @@ +#name: FRV uClinux PIC relocs to global symbols, pie linking +#source: fdpic2.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F2>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <GF0> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff e8 setlo 0xffe8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff dc addi gr15,-36,gr0 +[0-9a-f ]+: 80 fc ff dc setlos 0xf+fdc,gr0 +[0-9a-f ]+: 80 f4 ff dc setlo 0xffdc,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D2>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x18>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-5.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-5.d new file mode 100644 index 0000000..8565024 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-5.d @@ -0,0 +1,5 @@ +#name: FRV uClinux PIC relocs to undefined symbols, pie linking +#source: fdpic5.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie +#error: undefined reference diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6-fail.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6-fail.d new file mode 100644 index 0000000..b7e93ae --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6-fail.d @@ -0,0 +1,5 @@ +#name: FRV uClinux PIC relocs to undefined symbols, pie linking +#source: fdpic6.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie +#error: different segment diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6.d new file mode 100644 index 0000000..7bdda5d --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-6.d @@ -0,0 +1,73 @@ +#name: FRV uClinux PIC relocs to weak undefined symbols, pie linking +#source: fdpic6.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie --defsym WD1=D6 + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: c0 1a 00 06 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: c0 1a 00 04 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: c0 1a 00 02 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: 88 08 f1 40 ldd @\(gr15,gr0\),gr4 +[0-9a-f ]+: 80 30 40 00 jmpl @\(gr4,gr0\) +[0-9a-f ]+: 9c cc ff f0 lddi @\(gr15,-16\),gr14 +[0-9a-f ]+: 80 30 e0 00 jmpl @\(gr14,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<F6>: +[0-9a-f ]+: fe 3f ff fe call [0-9a-f]+ <F6-0x8> +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff e8 setlos 0xf*ffffffe8,gr0 +[0-9a-f ]+: 80 f4 ff e0 setlo 0xffe0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 ff d0 setlo 0xffd0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D6>: + \.\.\. +[0-9a-f ]+: R_FRV_32 WD0 +[0-9a-f ]+: R_FRV_FUNCDESC WFb +[0-9a-f ]+: R_FRV_32 WFb +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x20>: +[0-9a-f ]+: 00 00 04 b8 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF9 +[0-9a-f ]+: 00 00 00 02 .* +[0-9a-f ]+: 00 00 04 b0 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF8 +[0-9a-f ]+: 00 00 00 02 .* +[0-9a-f ]+: 00 00 04 a8 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF0 +[0-9a-f ]+: 00 00 00 02 .* +[0-9a-f ]+: 00 00 04 a0 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF7 +[0-9a-f ]+: 00 00 00 02 .* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: R_FRV_32 WF1 +[0-9a-f ]+: R_FRV_FUNCDESC WF4 +[0-9a-f ]+: R_FRV_32 WD2 +[0-9a-f ]+: R_FRV_FUNCDESC WF5 +[0-9a-f ]+: R_FRV_FUNCDESC WF6 +[0-9a-f ]+: R_FRV_32 WF3 +[0-9a-f ]+: R_FRV_32 WF2 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-7.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-7.d new file mode 100644 index 0000000..7ebd0b7 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-7.d @@ -0,0 +1,57 @@ +#name: FRV uClinux PIC relocs to local symbols with addends, pie linking +#source: fdpic7.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F7>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <\.F0\+0x4> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf*fffffff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff f0 addi gr15,-16,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff f0 setlo 0xfff0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D7>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-8.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-8.d new file mode 100644 index 0000000..0de4a81 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-pie-8.d @@ -0,0 +1,71 @@ +#name: FRV uClinux PIC relocs to global symbols with addends, pie linking +#source: fdpic8.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -pie + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F8>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <GF0\+0x4> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 14 setlos 0x14,gr0 +[0-9a-f ]+: 80 f4 00 24 setlo 0x24,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 1c setlos 0x1c,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff e8 setlo 0xffe8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff e0 addi gr15,-32,gr0 +[0-9a-f ]+: 80 fc ff e0 setlos 0xf+fe0,gr0 +[0-9a-f ]+: 80 f4 ff e0 setlo 0xffe0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D8>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x18>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-1.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-1.d new file mode 100644 index 0000000..7f88e18 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-1.d @@ -0,0 +1,57 @@ +#name: FRV uClinux PIC relocs to local symbols, shared linking +#source: fdpic1.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F1>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <\.F0> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf+ff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff ec addi gr15,-20,gr0 +[0-9a-f ]+: 80 fc ff ec setlos 0xf+fec,gr0 +[0-9a-f ]+: 80 f4 ff ec setlo 0xffec,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D1>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2-fail.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2-fail.d new file mode 100644 index 0000000..0cec4f6 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2-fail.d @@ -0,0 +1,4 @@ +#name: FRV uClinux PIC relocs to global symbols, failing shared linking +#source: fdpic2.s +#ld: -shared +#error: different segment diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2.d new file mode 100644 index 0000000..cb4b68d --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-2.d @@ -0,0 +1,80 @@ +#name: FRV uClinux PIC relocs to (mostly) global symbols, shared linking +#source: fdpic2.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared --version-script fdpic2min.ldv + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+ <\.plt>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: c0 1a 00 06 bra [0-9a-f]+ <F2-0x10> +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: c0 1a 00 04 bra [0-9a-f]+ <F2-0x10> +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: c0 1a 00 02 bra [0-9a-f]+ <F2-0x10> +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: 88 08 f1 40 ldd @\(gr15,gr0\),gr4 +[0-9a-f ]+: 80 30 40 00 jmpl @\(gr4,gr0\) +[0-9a-f ]+: 9c cc ff f8 lddi @\(gr15,-8\),gr14 +[0-9a-f ]+: 80 30 e0 00 jmpl @\(gr14,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<F2>: +[0-9a-f ]+: fe 3f ff fe call [0-9a-f]+ <F2-0x8> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f0 addi gr15,-16,gr0 +[0-9a-f ]+: 80 fc ff e8 setlos 0xf*ffffffe8,gr0 +[0-9a-f ]+: 80 f4 ff e0 setlo 0xffe0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff d8 addi gr15,-40,gr0 +[0-9a-f ]+: 80 fc ff d8 setlos 0xf+fd8,gr0 +[0-9a-f ]+: 80 f4 ff d8 setlo 0xffd8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D2>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 GD0 + +[0-9a-f ]+<GD0>: + \.\.\. +[0-9a-f ]+: R_FRV_FUNCDESC GFb +[0-9a-f ]+: R_FRV_32 GFb +[0-9A-F ]+isassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x20>: +[0-9a-f ]+: 00 00 04 a4 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE GF9 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 9c .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE GF8 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 ac .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE GF7 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 94 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE GF0 +[0-9a-f ]+: 00 00 00 00 .* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: R_FRV_FUNCDESC GF4 +[0-9a-f ]+: R_FRV_32 GF1 +[0-9a-f ]+: R_FRV_FUNCDESC GF6 +[0-9a-f ]+: R_FRV_FUNCDESC GF5 +[0-9a-f ]+: R_FRV_32 GD4 +[0-9a-f ]+: R_FRV_32 GF3 +[0-9a-f ]+: R_FRV_32 GF2 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-3.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-3.d new file mode 100644 index 0000000..fceb16a --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-3.d @@ -0,0 +1,83 @@ +#name: FRV uClinux PIC relocs to hidden symbols, shared linking +#source: fdpic3.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +[0-9A-F ]+isassembly of section \.text: + +[0-9a-f ]+<F3>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <HF0> + +[0-9a-f ]+<HF0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 20 setlos 0x20,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff e8 setlos 0xf*ffffffe8,gr0 +[0-9a-f ]+: 80 f4 ff d8 setlo 0xffd8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff bc addi gr15,-68,gr0 +[0-9a-f ]+: 80 fc ff bc setlos 0xf+fbc,gr0 +[0-9a-f ]+: 80 f4 ff bc setlo 0xffbc,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 24 setlo 0x24,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D3>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<HD0>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 28 add\.p gr0,gr40,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-4.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-4.d new file mode 100644 index 0000000..4045562 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-4.d @@ -0,0 +1,71 @@ +#name: FRV uClinux PIC relocs to protected symbols, shared linking +#source: fdpic4.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F4>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <PF0> + +[0-9a-f ]+<PF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 20 setlos 0x20,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff e8 setlo 0xffe8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff dc addi gr15,-36,gr0 +[0-9a-f ]+: 80 fc ff dc setlos 0xf+fdc,gr0 +[0-9a-f ]+: 80 f4 ff dc setlo 0xffdc,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D4>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<PD0>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x18>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC \.text diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-5.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-5.d new file mode 100644 index 0000000..009c62c --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-5.d @@ -0,0 +1,82 @@ +#name: FRV uClinux PIC relocs to undefined symbols, shared linking +#source: fdpic5.s +#objdump: -DRz -j .text -j .data -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: c0 1a 00 06 bra [0-9a-f]+ <F5-0x10> +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: c0 1a 00 04 bra [0-9a-f]+ <F5-0x10> +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: c0 1a 00 02 bra [0-9a-f]+ <F5-0x10> +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: 88 08 f1 40 ldd @\(gr15,gr0\),gr4 +[0-9a-f ]+: 80 30 40 00 jmpl @\(gr4,gr0\) +[0-9a-f ]+: 9c cc ff f0 lddi @\(gr15,-16\),gr14 +[0-9a-f ]+: 80 30 e0 00 jmpl @\(gr14,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<F5>: +[0-9a-f ]+: fe 3f ff fe call [0-9a-f]+ <F5-0x8> +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 1c setlos 0x1c,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff e8 setlos 0xf*ffffffe8,gr0 +[0-9a-f ]+: 80 f4 ff e0 setlo 0xffe0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D5>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 UD0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC UFb +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 UFb +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x20>: +[0-9a-f ]+: 00 00 04 7c .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE UF9 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 64 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE UF8 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 74 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE UF0 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 04 6c .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE UF7 +[0-9a-f ]+: 00 00 00 00 .* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_32 UF1 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_FUNCDESC UF4 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_32 UD1 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_FUNCDESC UF6 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_FUNCDESC UF5 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_32 UF3 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_32 UF2 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6-fail.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6-fail.d new file mode 100644 index 0000000..23a245b --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6-fail.d @@ -0,0 +1,5 @@ +#name: FRV uClinux PIC relocs to undefined symbols, shared linking +#source: fdpic6.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared +#error: different segment diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6.d new file mode 100644 index 0000000..06a335f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-6.d @@ -0,0 +1,73 @@ +#name: FRV uClinux PIC relocs to weak undefined symbols, shared linking +#source: fdpic6.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared --defsym WD1=D6 --version-script fdpic6.ldv + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: c0 1a 00 06 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: c0 1a 00 04 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: c0 1a 00 02 bra [0-9a-f]+ <F6-0x10> +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: 88 08 f1 40 ldd @\(gr15,gr0\),gr4 +[0-9a-f ]+: 80 30 40 00 jmpl @\(gr4,gr0\) +[0-9a-f ]+: 9c cc ff f0 lddi @\(gr15,-16\),gr14 +[0-9a-f ]+: 80 30 e0 00 jmpl @\(gr14,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<F6>: +[0-9a-f ]+: fe 3f ff fe call [0-9a-f]+ <F6-0x8> +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff e8 setlos 0xf*ffffffe8,gr0 +[0-9a-f ]+: 80 f4 ff e0 setlo 0xffe0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 ff d0 setlo 0xffd0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D6>: + \.\.\. +[0-9a-f ]+: R_FRV_32 WD0 +[0-9a-f ]+: R_FRV_FUNCDESC WFb +[0-9a-f ]+: R_FRV_32 WFb +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x20>: +[0-9a-f ]+: 00 00 03 60 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF9 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 03 58 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF8 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 03 50 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF0 +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: 00 00 03 48 .* +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE WF7 +[0-9a-f ]+: 00 00 00 00 .* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: R_FRV_32 WF1 +[0-9a-f ]+: R_FRV_FUNCDESC WF4 +[0-9a-f ]+: R_FRV_32 WD2 +[0-9a-f ]+: R_FRV_FUNCDESC WF5 +[0-9a-f ]+: R_FRV_FUNCDESC WF6 +[0-9a-f ]+: R_FRV_32 WF3 +[0-9a-f ]+: R_FRV_32 WF2 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-7.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-7.d new file mode 100644 index 0000000..2004a84 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-7.d @@ -0,0 +1,57 @@ +#name: FRV uClinux PIC relocs to local symbols with addends, shared linking +#source: fdpic7.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F7>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <\.F0\+0x4> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf*fffffff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff f0 addi gr15,-16,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff f0 setlo 0xfff0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D7>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8-fail.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8-fail.d new file mode 100644 index 0000000..5634040 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8-fail.d @@ -0,0 +1,5 @@ +#name: FRV uClinux PIC relocs to (mostly) global symbols with addends, failing shared linking +#source: fdpic8.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared +#error: (nonzero addend|may have caused) diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8.d new file mode 100644 index 0000000..543d313 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-8.d @@ -0,0 +1,83 @@ +#name: FRV uClinux PIC relocs to (mostly) global symbols with addends, shared linking +#source: fdpic8.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared --version-script fdpic8min.ldv + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F8>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <GF1\+0x4> + +[0-9a-f ]+<GF1>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 14 setlos 0x14,gr0 +[0-9a-f ]+: 80 f4 00 24 setlo 0x24,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 1c setlos 0x1c,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff c8 setlo 0xffc8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff c0 addi gr15,-64,gr0 +[0-9a-f ]+: 80 fc ff c0 setlos 0xf+fc0,gr0 +[0-9a-f ]+: 80 f4 ff c0 setlo 0xffc0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9A-F ]+isassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D8>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 GD0 + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 GF1 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 GF2 +[0-9a-f ]+: 00 00 00 20 add\.p gr0,gr32,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 GD4 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 GF3 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-2.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-2.d new file mode 100644 index 0000000..51ca126 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-2.d @@ -0,0 +1,83 @@ +#name: FRV uClinux PIC relocs to forced-local symbols, shared linking +#source: fdpic2.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared --version-script fdpic2.ldv + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F2>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <GF0> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff d0 setlos 0xf+fd0,gr0 +[0-9a-f ]+: 80 f4 ff c8 setlo 0xffc8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff c0 addi gr15,-64,gr0 +[0-9a-f ]+: 80 fc ff c0 setlos 0xf+fc0,gr0 +[0-9a-f ]+: 80 f4 ff c0 setlo 0xffc0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D2>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 28 add\.p gr0,gr40,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 20 add\.p gr0,gr32,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.data +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 04 add\.p gr0,gr4,gr0 +[0-9a-f ]+: R_FRV_32 \.text diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-8.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-8.d new file mode 100644 index 0000000..8d2c67e --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-shared-local-8.d @@ -0,0 +1,83 @@ +#name: FRV uClinux PIC relocs to forced-local symbols with addends, shared linking +#source: fdpic8.s +#objdump: -DR -j .text -j .data -j .got -j .plt +#ld: -shared --version-script fdpic8.ldv + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F8>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <GF0\+0x4> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 14 setlos 0x14,gr0 +[0-9a-f ]+: 80 f4 00 24 setlo 0x24,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 1c setlos 0x1c,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf+ff0,gr0 +[0-9a-f ]+: 80 f4 ff c8 setlo 0xffc8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff c4 addi gr15,-60,gr0 +[0-9a-f ]+: 80 fc ff c4 setlos 0xf+fc4,gr0 +[0-9a-f ]+: 80 f4 ff c4 setlo 0xffc4,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D8>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_FUNCDESC_VALUE \.text +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text +[0-9a-f ]+: 00 00 00 20 add\.p gr0,gr32,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 18 add\.p gr0,gr24,gr0 +[0-9a-f ]+: R_FRV_32 \.got +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.data +[0-9a-f ]+: 00 00 00 08 add\.p gr0,gr8,gr0 +[0-9a-f ]+: R_FRV_32 \.text diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-1.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-1.d new file mode 100644 index 0000000..1c4dce1 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-1.d @@ -0,0 +1,62 @@ +#name: FRV uClinux PIC relocs to local symbols, static linking +#source: fdpic1.s +#objdump: -D +#ld: -static + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F1>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <\.F0> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf*fffffff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff f0 addi gr15,-16,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf*fffffff0,gr0 +[0-9a-f ]+: 80 f4 ff f0 setlo 0xfff0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.rofixup: + +[0-9a-f ]+<__ROFIXUP_LIST__>: +[0-9a-f ]+: 00 01 41 24 sub\.p gr20,gr36,gr0 +[0-9a-f ]+: 00 01 41 28 sub\.p gr20,gr40,gr0 +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 41 14 sub\.p gr20,gr20,gr0 +[0-9a-f ]+: 00 01 41 2c sub\.p gr20,gr44,gr0 +[0-9a-f ]+: 00 01 41 04 sub\.p gr20,gr4,gr0 +[0-9a-f ]+: 00 01 41 08 sub\.p gr20,gr8,gr0 +[0-9a-f ]+: 00 01 41 0c sub\.p gr20,gr12,gr0 +[0-9a-f ]+: 00 01 41 18 sub\.p gr20,gr24,gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D1>: +[0-9a-f ]+: 00 01 41 08 sub\.p gr20,gr8,gr0 + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 18 sub\.p gr20,gr24,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 41 08 sub\.p gr20,gr8,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-2.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-2.d new file mode 100644 index 0000000..d2b794f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-2.d @@ -0,0 +1,94 @@ +#name: FRV uClinux PIC relocs to global symbols, static linking +#source: fdpic2.s +#objdump: -D +#ld: -static + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F2>: +[0-9a-f ]+: 80 3c 00 01 call [0-9a-f]+ <GF0> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff d0 setlos 0xf*ffffffd0,gr0 +[0-9a-f ]+: 80 f4 ff c8 setlo 0xffc8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff c0 addi gr15,-64,gr0 +[0-9a-f ]+: 80 fc ff c0 setlos 0xf*ffffffc0,gr0 +[0-9a-f ]+: 80 f4 ff c0 setlo 0xffc0,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.rofixup: + +[0-9a-f ]+<__ROFIXUP_LIST__>: +[0-9a-f ]+: 00 01 41 98 subx\.p gr20,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 ac subx\.p gr20,gr44,gr0,icc0 +[0-9a-f ]+: 00 01 41 a8 subx\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 41 94 subx\.p gr20,gr20,gr0,icc0 +[0-9a-f ]+: 00 01 41 60 subcc\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 41 64 subcc\.p gr20,gr36,gr0,icc0 +[0-9a-f ]+: 00 01 41 a0 subx\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 41 70 subcc\.p gr20,gr48,gr0,icc0 +[0-9a-f ]+: 00 01 41 74 subcc\.p gr20,gr52,gr0,icc0 +[0-9a-f ]+: 00 01 41 9c subx\.p gr20,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 78 subcc\.p gr20,gr56,gr0,icc0 +[0-9a-f ]+: 00 01 41 7c subcc\.p gr20,gr60,gr0,icc0 +[0-9a-f ]+: 00 01 41 80 subx\.p gr20,gr0,gr0,icc0 +[0-9a-f ]+: 00 01 41 84 subx\.p gr20,gr4,gr0,icc0 +[0-9a-f ]+: 00 01 41 58 subcc\.p gr20,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 5c subcc\.p gr20,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 50 subcc\.p gr20,gr16,gr0,icc0 +[0-9a-f ]+: 00 01 41 54 subcc\.p gr20,gr20,gr0,icc0 +[0-9a-f ]+: 00 01 41 a4 subx\.p gr20,gr36,gr0,icc0 +[0-9a-f ]+: 00 01 41 44 subcc\.p gr20,gr4,gr0,icc0 +[0-9a-f ]+: 00 01 41 68 subcc\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 41 6c subcc\.p gr20,gr44,gr0,icc0 +[0-9a-f ]+: 00 01 41 48 subcc\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 41 4c subcc\.p gr20,gr12,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D2>: +[0-9a-f ]+: 00 01 41 48 subcc\.p gr20,gr8,gr0,icc0 + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 01 41 68 subcc\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 01 41 60 subcc\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 78 subcc\.p gr20,gr56,gr0,icc0 +[0-9a-f ]+: 00 01 41 70 subcc\.p gr20,gr48,gr0,icc0 +[0-9a-f ]+: 00 01 41 48 subcc\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 00 98 addx\.p gr16,gr24,gr0,icc0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-5.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-5.d new file mode 100644 index 0000000..ce687b8 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-5.d @@ -0,0 +1,5 @@ +#name: FRV uClinux PIC relocs to undefined symbols, static linking +#source: fdpic5.s +#objdump: -D +#ld: -static +#error: undefined reference diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-6.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-6.d new file mode 100644 index 0000000..491b7c7 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-6.d @@ -0,0 +1,43 @@ +#name: FRV uClinux PIC relocs to weak undefined symbols, static linking +#source: fdpic6.s +#objdump: -D +#ld: -static +#warning: different segment + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F6>: +[0-9a-f ]+: fe 3f bf db call 0 <_gp-0xf8d8> +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 24 setlos 0x24,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 18 setlos 0x18,gr0 +[0-9a-f ]+: 80 f4 00 1c setlo 0x1c,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf*fffffff0,gr0 +[0-9a-f ]+: 80 f4 ff e8 setlo 0xffe8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 be e0 setlo 0xbee0,gr0 +[0-9a-f ]+: 80 f8 ff fe sethi 0xfffe,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.rofixup: + +[0-9a-f ]+<__ROFIXUP_LIST__>: +[0-9a-f ]+: 00 01 41 20 sub\.p gr20,gr32,gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D6>: + \.\.\. +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: + \.\.\. + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-7.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-7.d new file mode 100644 index 0000000..6f8313c --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-7.d @@ -0,0 +1,62 @@ +#name: FRV uClinux PIC relocs to local symbols with addends, static linking +#source: fdpic7.s +#objdump: -D +#ld: -static + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F7>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <\.F0\+0x4> + +[0-9a-f ]+<\.F0>: +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 0c setlos 0xc,gr0 +[0-9a-f ]+: 80 f4 00 0c setlo 0xc,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 10 setlos 0x10,gr0 +[0-9a-f ]+: 80 f4 00 10 setlo 0x10,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f8 setlos 0xf*fffffff8,gr0 +[0-9a-f ]+: 80 f4 ff f8 setlo 0xfff8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff f4 addi gr15,-12,gr0 +[0-9a-f ]+: 80 fc ff f4 setlos 0xf*fffffff4,gr0 +[0-9a-f ]+: 80 f4 ff f4 setlo 0xfff4,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 14 setlo 0x14,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.rofixup: + +[0-9a-f ]+<__ROFIXUP_LIST__>: +[0-9a-f ]+: 00 01 41 24 sub\.p gr20,gr36,gr0 +[0-9a-f ]+: 00 01 41 28 sub\.p gr20,gr40,gr0 +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 41 14 sub\.p gr20,gr20,gr0 +[0-9a-f ]+: 00 01 41 2c sub\.p gr20,gr44,gr0 +[0-9a-f ]+: 00 01 41 04 sub\.p gr20,gr4,gr0 +[0-9a-f ]+: 00 01 41 08 sub\.p gr20,gr8,gr0 +[0-9a-f ]+: 00 01 41 0c sub\.p gr20,gr12,gr0 +[0-9a-f ]+: 00 01 41 18 sub\.p gr20,gr24,gr0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D7>: +[0-9a-f ]+: 00 01 41 0c sub\.p gr20,gr12,gr0 + +[0-9a-f ]+<\.D0>: +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x8>: +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 18 sub\.p gr20,gr24,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 10 sub\.p gr20,gr16,gr0 +[0-9a-f ]+: 00 01 41 0c sub\.p gr20,gr12,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-8.d b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-8.d new file mode 100644 index 0000000..c0cc732 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic-static-8.d @@ -0,0 +1,94 @@ +#name: FRV uClinux PIC relocs to global symbols with addends, static linking +#source: fdpic8.s +#objdump: -D +#ld: -static + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<F8>: +[0-9a-f ]+: 80 3c 00 02 call [0-9a-f]+ <GF0\+0x4> + +[0-9a-f ]+<GF0>: +[0-9a-f ]+: 80 40 f0 10 addi gr15,16,gr0 +[0-9a-f ]+: 80 fc 00 14 setlos 0x14,gr0 +[0-9a-f ]+: 80 f4 00 24 setlo 0x24,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 f0 0c addi gr15,12,gr0 +[0-9a-f ]+: 80 fc 00 1c setlos 0x1c,gr0 +[0-9a-f ]+: 80 f4 00 18 setlo 0x18,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +[0-9a-f ]+: 80 40 ff f8 addi gr15,-8,gr0 +[0-9a-f ]+: 80 fc ff f0 setlos 0xf*fffffff0,gr0 +[0-9a-f ]+: 80 f4 ff c8 setlo 0xffc8,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 40 ff c4 addi gr15,-60,gr0 +[0-9a-f ]+: 80 fc ff c4 setlos 0xf*ffffffc4,gr0 +[0-9a-f ]+: 80 f4 ff c4 setlo 0xffc4,gr0 +[0-9a-f ]+: 80 f8 ff ff sethi 0xffff,gr0 +[0-9a-f ]+: 80 f4 00 20 setlo 0x20,gr0 +[0-9a-f ]+: 80 f8 00 00 sethi hi\(0x0\),gr0 +Disassembly of section \.rofixup: + +[0-9a-f ]+<__ROFIXUP_LIST__>: +[0-9a-f ]+: 00 01 41 98 subx\.p gr20,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 9c subx\.p gr20,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 ac subx\.p gr20,gr44,gr0,icc0 +[0-9a-f ]+: 00 01 41 94 subx\.p gr20,gr20,gr0,icc0 +[0-9a-f ]+: 00 01 41 58 subcc\.p gr20,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 41 5c subcc\.p gr20,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 a4 subx\.p gr20,gr36,gr0,icc0 +[0-9a-f ]+: 00 01 41 68 subcc\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 41 6c subcc\.p gr20,gr44,gr0,icc0 +[0-9a-f ]+: 00 01 41 a0 subx\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 41 70 subcc\.p gr20,gr48,gr0,icc0 +[0-9a-f ]+: 00 01 41 74 subcc\.p gr20,gr52,gr0,icc0 +[0-9a-f ]+: 00 01 41 80 subx\.p gr20,gr0,gr0,icc0 +[0-9a-f ]+: 00 01 41 84 subx\.p gr20,gr4,gr0,icc0 +[0-9a-f ]+: 00 01 41 78 subcc\.p gr20,gr56,gr0,icc0 +[0-9a-f ]+: 00 01 41 7c subcc\.p gr20,gr60,gr0,icc0 +[0-9a-f ]+: 00 01 41 50 subcc\.p gr20,gr16,gr0,icc0 +[0-9a-f ]+: 00 01 41 54 subcc\.p gr20,gr20,gr0,icc0 +[0-9a-f ]+: 00 01 41 a8 subx\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 41 44 subcc\.p gr20,gr4,gr0,icc0 +[0-9a-f ]+: 00 01 41 60 subcc\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 41 64 subcc\.p gr20,gr36,gr0,icc0 +[0-9a-f ]+: 00 01 41 48 subcc\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 41 4c subcc\.p gr20,gr12,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +Disassembly of section \.dat[0-9a-f ]+: + +[0-9a-f ]+<D8>: +[0-9a-f ]+: 00 01 41 4c subcc\.p gr20,gr12,gr0,icc0 + +[0-9a-f ]+<GD0>: +[0-9a-f ]+: 00 01 41 60 subcc\.p gr20,gr32,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +Disassembly of section \.got: + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_-0x38>: +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 88 subx\.p gr20,gr8,gr0,icc0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 01 41 58 subcc\.p gr20,gr24,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 +[0-9a-f ]+: 00 01 41 70 subcc\.p gr20,gr48,gr0,icc0 +[0-9a-f ]+: 00 01 41 68 subcc\.p gr20,gr40,gr0,icc0 +[0-9a-f ]+: 00 01 41 4c subcc\.p gr20,gr12,gr0,icc0 +[0-9a-f ]+: 00 01 00 9c addx\.p gr16,gr28,gr0,icc0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic.exp b/binutils-2.21/ld/testsuite/ld-frv/fdpic.exp new file mode 100644 index 0000000..90da0d3 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic.exp @@ -0,0 +1,69 @@ +# Expect script for FRV FDPIC linker tests +# Copyright 2003, 2004, 2005, 2007 Free Software Foundation, Inc. +# +# This file is part of the GNU Binutils. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, +# MA 02110-1301, USA. +# + +if {![istarget frv*-*-*] || ![is_elf_format]} { + return +} + +global ASFLAGS +set saved_ASFLAGS "$ASFLAGS" +set ASFLAGS "$ASFLAGS -mfdpic" + +global LDFLAGS +set saved_LDFLAGS "$LDFLAGS" +set LDFLAGS "$LDFLAGS -melf32frvfd" + +run_dump_test "fdpic-static-1" +run_dump_test "fdpic-pie-1" +run_dump_test "fdpic-shared-1" + +run_dump_test "fdpic-static-2" +run_dump_test "fdpic-pie-2" +run_dump_test "fdpic-shared-2-fail" +run_dump_test "fdpic-shared-2" +run_dump_test "fdpic-shared-local-2" + +run_dump_test "fdpic-shared-3" + +run_dump_test "fdpic-shared-4" + +run_dump_test "fdpic-static-5" +run_dump_test "fdpic-pie-5" +run_dump_test "fdpic-shared-5" + +run_dump_test "fdpic-static-6" +run_dump_test "fdpic-pie-6-fail" +run_dump_test "fdpic-pie-6" +run_dump_test "fdpic-shared-6-fail" +run_dump_test "fdpic-shared-6" + +run_dump_test "fdpic-static-7" +run_dump_test "fdpic-pie-7" +run_dump_test "fdpic-shared-7" + +run_dump_test "fdpic-static-8" +run_dump_test "fdpic-pie-8" +run_dump_test "fdpic-shared-8-fail" +run_dump_test "fdpic-shared-8" +run_dump_test "fdpic-shared-local-8" + +set LDFLAGS "$saved_LDFLAGS" +set ASFLAGS "$saved_ASFLAGS" diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic1.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic1.s new file mode 100644 index 0000000..29f7fff --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic1.s @@ -0,0 +1,64 @@ + .text + .weak _start +_start: + .global F1 + .type F1,@function +F1: + call .F0 + +.F0: +.F1: +.F2: +.F3: +.F4: +.F5: +.F6: +.F7: +.F8: +.F9: +.Fa: +.Fb: +.Fc: + addi gr15, #got12(.F1), gr0 + + setlos #gotlo(.F2), gr0 + + setlo #gotlo(.F3), gr0 + sethi #gothi(.F3), gr0 + + addi gr15, #gotfuncdesc12(.F4), gr0 + + setlos #gotfuncdesclo(.F5), gr0 + + setlo #gotfuncdesclo(.F6), gr0 + sethi #gotfuncdeschi(.F6), gr0 + + addi gr15, #gotofffuncdesc12(.F7), gr0 + + setlos #gotofffuncdesclo(.F8), gr0 + + setlo #gotofffuncdesclo(.F9), gr0 + sethi #gotofffuncdeschi(.F9), gr0 + + addi gr15, #gotoff12(.D1), gr0 + + setlos #gotofflo(.D2), gr0 + + setlo #gotofflo(.D3), gr0 + sethi #gotoffhi(.D3), gr0 + + setlo #gotlo(.D4), gr0 + sethi #gothi(.D4), gr0 + + .data + .global D1 +D1: + .word .D0 + .section .data.rel.local +.D0: +.D1: +.D2: +.D3: +.D4: + .picptr funcdesc(.Fb) + .word .Fb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic2.ldv b/binutils-2.21/ld/testsuite/ld-frv/fdpic2.ldv new file mode 100644 index 0000000..b5aad4f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic2.ldv @@ -0,0 +1 @@ +{ global: _start; F2; D2; local: *; }; diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic2.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic2.s new file mode 100644 index 0000000..2987643 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic2.s @@ -0,0 +1,81 @@ + .text + .weak _start +_start: + .global F2 + .type F2,@function +F2: + call GF0 + .global GF0 + .global GF1 + .global GF2 + .global GF3 + .global GF4 + .global GF5 + .global GF6 + .global GF7 + .global GF8 + .global GF9 + .global GFa + .global GFb + .global GFc +GF0: +GF1: +GF2: +GF3: +GF4: +GF5: +GF6: +GF7: +GF8: +GF9: +GFa: +GFb: +GFc: + addi gr15, #got12(GF1), gr0 + + setlos #gotlo(GF2), gr0 + + setlo #gotlo(GF3), gr0 + sethi #gothi(GF3), gr0 + + addi gr15, #gotfuncdesc12(GF4), gr0 + + setlos #gotfuncdesclo(GF5), gr0 + + setlo #gotfuncdesclo(GF6), gr0 + sethi #gotfuncdeschi(GF6), gr0 + + addi gr15, #gotofffuncdesc12(GF7), gr0 + + setlos #gotofffuncdesclo(GF8), gr0 + + setlo #gotofffuncdesclo(GF9), gr0 + sethi #gotofffuncdeschi(GF9), gr0 + + addi gr15, #gotoff12(GD1), gr0 + + setlos #gotofflo(GD2), gr0 + + setlo #gotofflo(GD3), gr0 + sethi #gotoffhi(GD3), gr0 + + setlo #gotlo(GD4), gr0 + sethi #gothi(GD4), gr0 + + .data + .global D2 +D2: + .word GD0 + + .global GD0 + .global GD1 + .global GD2 + .global GD3 + .global GD4 +GD0: +GD1: +GD2: +GD3: +GD4: + .picptr funcdesc(GFb) + .word GFb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic2min.ldv b/binutils-2.21/ld/testsuite/ld-frv/fdpic2min.ldv new file mode 100644 index 0000000..2804526 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic2min.ldv @@ -0,0 +1 @@ +{ global: _start; F*; GF*; D2; GD0; GD4; local: GD1; GD2; GD3; }; diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic3.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic3.s new file mode 100644 index 0000000..f867b93 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic3.s @@ -0,0 +1,99 @@ + .text + .weak _start +_start: + .global F3 + .type F3,@function +F3: + call HF0 + .global HF0 + .hidden HF0 + .global HF1 + .hidden HF1 + .global HF2 + .hidden HF2 + .global HF3 + .hidden HF3 + .global HF4 + .hidden HF4 + .global HF5 + .hidden HF5 + .global HF6 + .hidden HF6 + .global HF7 + .hidden HF7 + .global HF8 + .hidden HF8 + .global HF9 + .hidden HF9 + .global HFa + .hidden HFa + .global HFb + .hidden HFb + .global HFc + .hidden HFc +HF0: +HF1: +HF2: +HF3: +HF4: +HF5: +HF6: +HF7: +HF8: +HF9: +HFa: +HFb: +HFc: + addi gr15, #got12(HF1), gr0 + + setlos #gotlo(HF2), gr0 + + setlo #gotlo(HF3), gr0 + sethi #gothi(HF3), gr0 + + addi gr15, #gotfuncdesc12(HF4), gr0 + + setlos #gotfuncdesclo(HF5), gr0 + + setlo #gotfuncdesclo(HF6), gr0 + sethi #gotfuncdeschi(HF6), gr0 + + addi gr15, #gotofffuncdesc12(HF7), gr0 + + setlos #gotofffuncdesclo(HF8), gr0 + + setlo #gotofffuncdesclo(HF9), gr0 + sethi #gotofffuncdeschi(HF9), gr0 + + addi gr15, #gotoff12(HD1), gr0 + + setlos #gotofflo(HD2), gr0 + + setlo #gotofflo(HD3), gr0 + sethi #gotoffhi(HD3), gr0 + + setlo #gotlo(HD4), gr0 + sethi #gothi(HD4), gr0 + + .data + .global D3 +D3: + .word HD0 + + .global HD0 + .hidden HD0 + .global HD1 + .hidden HD1 + .global HD2 + .hidden HD2 + .global HD3 + .hidden HD3 + .global HD4 + .hidden HD4 +HD0: +HD1: +HD2: +HD3: +HD4: + .picptr funcdesc(HFb) + .word HFb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic4.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic4.s new file mode 100644 index 0000000..795ae45 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic4.s @@ -0,0 +1,99 @@ + .text + .weak _start +_start: + .global F4 + .type F4,@function +F4: + call PF0 + .global PF0 + .protected PF0 + .global PF1 + .protected PF1 + .global PF2 + .protected PF2 + .global PF3 + .protected PF3 + .global PF4 + .protected PF4 + .global PF5 + .protected PF5 + .global PF6 + .protected PF6 + .global PF7 + .protected PF7 + .global PF8 + .protected PF8 + .global PF9 + .protected PF9 + .global PFa + .protected PFa + .global PFb + .protected PFb + .global PFc + .protected PFc +PF0: +PF1: +PF2: +PF3: +PF4: +PF5: +PF6: +PF7: +PF8: +PF9: +PFa: +PFb: +PFc: + addi gr15, #got12(PF1), gr0 + + setlos #gotlo(PF2), gr0 + + setlo #gotlo(PF3), gr0 + sethi #gothi(PF3), gr0 + + addi gr15, #gotfuncdesc12(PF4), gr0 + + setlos #gotfuncdesclo(PF5), gr0 + + setlo #gotfuncdesclo(PF6), gr0 + sethi #gotfuncdeschi(PF6), gr0 + + addi gr15, #gotofffuncdesc12(PF7), gr0 + + setlos #gotofffuncdesclo(PF8), gr0 + + setlo #gotofffuncdesclo(PF9), gr0 + sethi #gotofffuncdeschi(PF9), gr0 + + addi gr15, #gotoff12(PD1), gr0 + + setlos #gotofflo(PD2), gr0 + + setlo #gotofflo(PD3), gr0 + sethi #gotoffhi(PD3), gr0 + + setlo #gotlo(PD4), gr0 + sethi #gothi(PD4), gr0 + + .data + .global D4 +D4: + .word PD0 + + .global PD0 + .protected PD0 + .global PD1 + .protected PD1 + .global PD2 + .protected PD2 + .global PD3 + .protected PD3 + .global PD4 + .protected PD4 +PD0: +PD1: +PD2: +PD3: +PD4: + .picptr funcdesc(PFb) + .word PFb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic5.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic5.s new file mode 100644 index 0000000..f4d466a --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic5.s @@ -0,0 +1,38 @@ + .text + .weak _start +_start: + .global F5 + .type F5,@function +F5: + call UF0 + addi gr15, #got12(UF1), gr0 + + setlos #gotlo(UF2), gr0 + + setlo #gotlo(UF3), gr0 + sethi #gothi(UF3), gr0 + + addi gr15, #gotfuncdesc12(UF4), gr0 + + setlos #gotfuncdesclo(UF5), gr0 + + setlo #gotfuncdesclo(UF6), gr0 + sethi #gotfuncdeschi(UF6), gr0 + + addi gr15, #gotofffuncdesc12(UF7), gr0 + + setlos #gotofffuncdesclo(UF8), gr0 + + setlo #gotofffuncdesclo(UF9), gr0 + sethi #gotofffuncdeschi(UF9), gr0 + + setlo #gotlo(UD1), gr0 + sethi #gothi(UD1), gr0 + + .data + .global D5 +D5: + .word UD0 + + .picptr funcdesc(UFb) + .word UFb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic6.ldv b/binutils-2.21/ld/testsuite/ld-frv/fdpic6.ldv new file mode 100644 index 0000000..5e46c03 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic6.ldv @@ -0,0 +1 @@ +{ global: _start; F6; D6; WF*; local: *; }; diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic6.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic6.s new file mode 100644 index 0000000..cd8e1d0 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic6.s @@ -0,0 +1,55 @@ + .text + .weak _start +_start: + .weak WF0 + .weak WF1 + .weak WF2 + .weak WF3 + .weak WF4 + .weak WF5 + .weak WF6 + .weak WF7 + .weak WF8 + .weak WF9 + .weak WFb + .weak WD0 + .weak WD1 + .weak WD2 + .global F6 + .type F6,@function +F6: + call WF0 + addi gr15, #got12(WF1), gr0 + + setlos #gotlo(WF2), gr0 + + setlo #gotlo(WF3), gr0 + sethi #gothi(WF3), gr0 + + addi gr15, #gotfuncdesc12(WF4), gr0 + + setlos #gotfuncdesclo(WF5), gr0 + + setlo #gotfuncdesclo(WF6), gr0 + sethi #gotfuncdeschi(WF6), gr0 + + addi gr15, #gotofffuncdesc12(WF7), gr0 + + setlos #gotofffuncdesclo(WF8), gr0 + + setlo #gotofffuncdesclo(WF9), gr0 + sethi #gotofffuncdeschi(WF9), gr0 + + setlo #gotofflo(WD1), gr0 + sethi #gotoffhi(WD1), gr0 + + setlo #gotlo(WD2), gr0 + sethi #gothi(WD2), gr0 + + .data + .global D6 +D6: + .word WD0 + + .picptr funcdesc(WFb) + .word WFb diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic7.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic7.s new file mode 100644 index 0000000..ceac5fc --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic7.s @@ -0,0 +1,63 @@ + .text + .weak _start +_start: + .global F7 + .type F7,@function +F7: + call .F0+4 + +.F0: +.F1: +.F2: +.F3: +.F4: +.F5: +.F6: +.F7: +.F8: +.F9: +.Fa: +.Fb: +.Fc: + addi gr15, #got12(.F1+4), gr0 + + setlos #gotlo(.F2+4), gr0 + + setlo #gotlo(.F3+4), gr0 + sethi #gothi(.F3+4), gr0 + + addi gr15, #gotfuncdesc12(.F4+4), gr0 + + setlos #gotfuncdesclo(.F5+4), gr0 + + setlo #gotfuncdesclo(.F6+4), gr0 + sethi #gotfuncdeschi(.F6+4), gr0 + + addi gr15, #gotofffuncdesc12(.F7+4), gr0 + + setlos #gotofffuncdesclo(.F8+4), gr0 + + setlo #gotofffuncdesclo(.F9+4), gr0 + sethi #gotofffuncdeschi(.F9+4), gr0 + + addi gr15, #gotoff12(.D1+4), gr0 + + setlos #gotofflo(.D2+4), gr0 + + setlo #gotofflo(.D3+4), gr0 + sethi #gotoffhi(.D3+4), gr0 + + setlo #gotlo(.D4+4), gr0 + sethi #gothi(.D4+4), gr0 + + .data + .global D7 +D7: + .word .D0+4 +.D0: +.D1: +.D2: +.D3: +.D4: + .picptr funcdesc(.Fb+4) + .word .Fb+4 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic8.ldv b/binutils-2.21/ld/testsuite/ld-frv/fdpic8.ldv new file mode 100644 index 0000000..d258f96 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic8.ldv @@ -0,0 +1 @@ +{ global: _start; F8; D8; local: *; }; diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic8.s b/binutils-2.21/ld/testsuite/ld-frv/fdpic8.s new file mode 100644 index 0000000..037250f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic8.s @@ -0,0 +1,81 @@ + .text + .weak _start +_start: + .global F8 + .type F8,@function +F8: + call GF0+4 + .global GF0 + .global GF1 + .global GF2 + .global GF3 + .global GF4 + .global GF5 + .global GF6 + .global GF7 + .global GF8 + .global GF9 + .global GFa + .global GFb + .global GFc +GF0: +GF1: +GF2: +GF3: +GF4: +GF5: +GF6: +GF7: +GF8: +GF9: +GFa: +GFb: +GFc: + addi gr15, #got12(GF1+4), gr0 + + setlos #gotlo(GF2+4), gr0 + + setlo #gotlo(GF3+4), gr0 + sethi #gothi(GF3+4), gr0 + + addi gr15, #gotfuncdesc12(GF4+4), gr0 + + setlos #gotfuncdesclo(GF5+4), gr0 + + setlo #gotfuncdesclo(GF6+4), gr0 + sethi #gotfuncdeschi(GF6+4), gr0 + + addi gr15, #gotofffuncdesc12(GF7+4), gr0 + + setlos #gotofffuncdesclo(GF8+4), gr0 + + setlo #gotofffuncdesclo(GF9+4), gr0 + sethi #gotofffuncdeschi(GF9+4), gr0 + + addi gr15, #gotoff12(GD1+4), gr0 + + setlos #gotofflo(GD2+4), gr0 + + setlo #gotofflo(GD3+4), gr0 + sethi #gotoffhi(GD3+4), gr0 + + setlo #gotlo(GD4+4), gr0 + sethi #gothi(GD4+4), gr0 + + .data + .global D8 +D8: + .word GD0+4 + + .global GD0 + .global GD1 + .global GD2 + .global GD3 + .global GD4 +GD0: +GD1: +GD2: +GD3: +GD4: + .picptr funcdesc(GFb+4) + .word GFb+4 diff --git a/binutils-2.21/ld/testsuite/ld-frv/fdpic8min.ldv b/binutils-2.21/ld/testsuite/ld-frv/fdpic8min.ldv new file mode 100644 index 0000000..aeadb79 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fdpic8min.ldv @@ -0,0 +1 @@ +{ global: _start; F8; GF1; GF2; GF3; D8; GD0; GD4; local: GF0; GF4; GF5; GF6; GF7; GF8; GF9; GFb; GD1; GD2; GD3; }; diff --git a/binutils-2.21/ld/testsuite/ld-frv/fr450-link.d b/binutils-2.21/ld/testsuite/ld-frv/fr450-link.d new file mode 100644 index 0000000..1ab80b0 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fr450-link.d @@ -0,0 +1,11 @@ +#source: fr450-linka.s -mcpu=fr400 +#source: fr450-linkb.s -mcpu=fr405 +#source: fr450-linkc.s -mcpu=fr450 +#source: fr450-linkb.s -mcpu=fr405 +#source: fr450-linka.s -mcpu=fr400 +#ld: -r +#objdump: -p + +.*: file format elf32-frv(|fdpic) +private flags = 0x800[08]000: -mcpu=fr450(| -mfdpic) + diff --git a/binutils-2.21/ld/testsuite/ld-frv/fr450-linka.s b/binutils-2.21/ld/testsuite/ld-frv/fr450-linka.s new file mode 100644 index 0000000..4e7fe2f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fr450-linka.s @@ -0,0 +1 @@ + nop diff --git a/binutils-2.21/ld/testsuite/ld-frv/fr450-linkb.s b/binutils-2.21/ld/testsuite/ld-frv/fr450-linkb.s new file mode 100644 index 0000000..4e7fe2f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fr450-linkb.s @@ -0,0 +1 @@ + nop diff --git a/binutils-2.21/ld/testsuite/ld-frv/fr450-linkc.s b/binutils-2.21/ld/testsuite/ld-frv/fr450-linkc.s new file mode 100644 index 0000000..4e7fe2f --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/fr450-linkc.s @@ -0,0 +1 @@ + nop diff --git a/binutils-2.21/ld/testsuite/ld-frv/frv-elf.exp b/binutils-2.21/ld/testsuite/ld-frv/frv-elf.exp new file mode 100644 index 0000000..961e0de --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/frv-elf.exp @@ -0,0 +1,23 @@ +# Expect script for FRV specific linker tests +# Copyright (C) 2007 Free Software Foundation +# +# This file is part of the GNU Binutils. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, +# MA 02110-1301, USA. + +if [istarget frv*-*-*] { + run_dump_test "fr450-link" +} diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-1-dep.s b/binutils-2.21/ld/testsuite/ld-frv/tls-1-dep.s new file mode 100644 index 0000000..75daab7 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-1-dep.s @@ -0,0 +1,7 @@ + .section .tbss,"awT",@nobits + .align 4 + .globl x + .type x, @tls_object + .size x, 4 +x: + .zero 4 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-1-shared.lds b/binutils-2.21/ld/testsuite/ld-frv/tls-1-shared.lds new file mode 100644 index 0000000..3769e01 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-1-shared.lds @@ -0,0 +1,3 @@ +{ + local: x; i; +}; diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-1.s b/binutils-2.21/ld/testsuite/ld-frv/tls-1.s new file mode 100644 index 0000000..a13c91b --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-1.s @@ -0,0 +1,85 @@ + .section .tbss,"awT",@nobits + .align 4 + .globl i + .type i, @object + .size i, 4 +i: + .zero 4 + .align 4 + .type l, @object + .size l, 4 +l: + .zero 4 + .text + .globl _start +_start: + call #gettlsoff(x) + + sethi.p #gottlsdeschi(x), gr14 + setlo #gottlsdesclo(x), gr14 + ldd #tlsdesc(x)@(gr15, gr14), gr8 + calll #gettlsoff(x)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(x)), gr8 + setlos #gottlsdesclo(x), gr14 + calll #gettlsoff(x)@(gr8, gr0) + + call #gettlsoff(i) + + sethi.p #gottlsdeschi(i), gr14 + setlo #gottlsdesclo(i), gr14 + ldd #tlsdesc(i)@(gr15, gr14), gr8 + calll #gettlsoff(i)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(i)), gr8 + setlos #gottlsdesclo(i), gr14 + calll #gettlsoff(i)@(gr8, gr0) + + call #gettlsoff(l) + + sethi.p #gottlsdeschi(l), gr14 + setlo #gottlsdesclo(l), gr14 + ldd #tlsdesc(l)@(gr15, gr14), gr8 + calll #gettlsoff(l)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(l)), gr8 + setlos #gottlsdesclo(l), gr14 + calll #gettlsoff(l)@(gr8, gr0) + + call #gettlsoff(0) + + sethi.p #gottlsdeschi(0), gr14 + setlo #gottlsdesclo(0), gr14 + ldd #tlsdesc(0)@(gr15, gr14), gr8 + calll #gettlsoff(0)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(0)), gr8 + setlos #gottlsdesclo(0), gr14 + calll #gettlsoff(0)@(gr8, gr0) + + sethi.p #tlsmoffhi(l), gr8 + setlo #tlsmofflo(l), gr8 + + sethi.p #tlsmoffhi(i), gr9 + setlo #tlsmofflo(i), gr9 + + ldi @(gr15, #gottlsoff12(x)), gr9 + ldi @(gr15, #gottlsoff12(i)), gr9 + ldi @(gr15, #gottlsoff12(l)), gr9 + ldi @(gr15, #gottlsoff12(0)), gr9 + + sethi.p #gottlsoffhi(x), gr14 + setlo #gottlsofflo(x), gr14 + ld #tlsoff(x)@(gr15, gr14), gr9 + + sethi.p #gottlsoffhi(i), gr14 + setlo #gottlsofflo(i), gr14 + ld #tlsoff(i)@(gr15, gr14), gr9 + + sethi.p #gottlsoffhi(l), gr14 + setlo #gottlsofflo(l), gr14 + ld #tlsoff(l)@(gr15, gr14), gr9 + + sethi.p #gottlsoffhi(0), gr14 + setlo #gottlsofflo(0), gr14 + ld #tlsoff(0)@(gr15, gr14), gr9 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-2.s b/binutils-2.21/ld/testsuite/ld-frv/tls-2.s new file mode 100644 index 0000000..f0712e3 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-2.s @@ -0,0 +1,183 @@ + .section .tbss,"awT",@nobits + .align 4 + .type l, @object + .size l, 4 +l: + .zero 4 + .align 4 + .globl i + .type i, @object + .size i, 4 +i: + .zero 4 + .text + .globl _start +_start: + call #gettlsoff(l+1) + call #gettlsoff(l+1+4096) + call #gettlsoff(l+1+65536) + + sethi.p #gottlsdeschi(l+2), gr14 + setlo #gottlsdesclo(l+2), gr14 + ldd #tlsdesc(l+2)@(gr15, gr14), gr8 + calll #gettlsoff(l+2)@(gr8, gr0) + + sethi.p #gottlsdeschi(l+2+4096), gr14 + setlo #gottlsdesclo(l+2+4096), gr14 + ldd #tlsdesc(l+2+4096)@(gr15, gr14), gr8 + calll #gettlsoff(l+2+4096)@(gr8, gr0) + + sethi.p #gottlsdeschi(l+2+65536), gr14 + setlo #gottlsdesclo(l+2+65536), gr14 + ldd #tlsdesc(l+2+65536)@(gr15, gr14), gr8 + calll #gettlsoff(l+2+65536)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(l+3)), gr8 + setlos #gottlsdesclo(l+3), gr14 + calll #gettlsoff(l+3)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(l+3+4096)), gr8 + setlos #gottlsdesclo(l+3+4096), gr14 + calll #gettlsoff(l+3+4096)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(l+3+65536)), gr8 + setlos #gottlsdesclo(l+3+65536), gr14 + calll #gettlsoff(l+3+65536)@(gr8, gr0) + + sethi #tlsmoffhi(l+4), gr9 + setlo #tlsmofflo(l+4), gr9 + + sethi #tlsmoffhi(l+4+4096), gr9 + setlo #tlsmofflo(l+4+4096), gr9 + + sethi #tlsmoffhi(l+4+65536), gr9 + setlo #tlsmofflo(l+4+65536), gr9 + + call #gettlsoff(i+1) + call #gettlsoff(i+1+4096) + call #gettlsoff(i+1+65536) + + sethi.p #gottlsdeschi(i+2), gr14 + setlo #gottlsdesclo(i+2), gr14 + ldd #tlsdesc(i+2)@(gr15, gr14), gr8 + calll #gettlsoff(i+2)@(gr8, gr0) + + sethi.p #gottlsdeschi(i+2+4096), gr14 + setlo #gottlsdesclo(i+2+4096), gr14 + ldd #tlsdesc(i+2+4096)@(gr15, gr14), gr8 + calll #gettlsoff(i+2+4096)@(gr8, gr0) + + sethi.p #gottlsdeschi(i+2+65536), gr14 + setlo #gottlsdesclo(i+2+65536), gr14 + ldd #tlsdesc(i+2+65536)@(gr15, gr14), gr8 + calll #gettlsoff(i+2+65536)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(i+3)), gr8 + setlos #gottlsdesclo(i+3), gr14 + calll #gettlsoff(i+3)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(i+3+4096)), gr8 + setlos #gottlsdesclo(i+3+4096), gr14 + calll #gettlsoff(i+3+4096)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(i+3+65536)), gr8 + setlos #gottlsdesclo(i+3+65536), gr14 + calll #gettlsoff(i+3+65536)@(gr8, gr0) + + sethi #tlsmoffhi(i+4), gr9 + setlo #tlsmofflo(i+4), gr9 + + sethi #tlsmoffhi(i+4+4096), gr9 + setlo #tlsmofflo(i+4+4096), gr9 + + sethi #tlsmoffhi(i+4+65536), gr9 + setlo #tlsmofflo(i+4+65536), gr9 + + call #gettlsoff(0+1) + call #gettlsoff(0+1+4096) + call #gettlsoff(0+1+65536) + + sethi.p #gottlsdeschi(0+2), gr14 + setlo #gottlsdesclo(0+2), gr14 + ldd #tlsdesc(0+2)@(gr15, gr14), gr8 + calll #gettlsoff(0+2)@(gr8, gr0) + + sethi.p #gottlsdeschi(0+2+4096), gr14 + setlo #gottlsdesclo(0+2+4096), gr14 + ldd #tlsdesc(0+2+4096)@(gr15, gr14), gr8 + calll #gettlsoff(0+2+4096)@(gr8, gr0) + + sethi.p #gottlsdeschi(0+2+65536), gr14 + setlo #gottlsdesclo(0+2+65536), gr14 + ldd #tlsdesc(0+2+65536)@(gr15, gr14), gr8 + calll #gettlsoff(0+2+65536)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(0+3)), gr8 + setlos #gottlsdesclo(0+3), gr14 + calll #gettlsoff(0+3)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(0+3+4096)), gr8 + setlos #gottlsdesclo(0+3+4096), gr14 + calll #gettlsoff(0+3+4096)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(0+3+65536)), gr8 + setlos #gottlsdesclo(0+3+65536), gr14 + calll #gettlsoff(0+3+65536)@(gr8, gr0) + + sethi #tlsmoffhi(0+4), gr9 + setlo #tlsmofflo(0+4), gr9 + + sethi #tlsmoffhi(0+4+4096), gr9 + setlo #tlsmofflo(0+4+4096), gr9 + + sethi #tlsmoffhi(0+4+65536), gr9 + setlo #tlsmofflo(0+4+65536), gr9 + + call #gettlsoff(x+1) + call #gettlsoff(x+1+4096) + call #gettlsoff(x+1+65536) + + sethi.p #gottlsdeschi(x+2), gr14 + setlo #gottlsdesclo(x+2), gr14 + ldd #tlsdesc(x+2)@(gr15, gr14), gr8 + calll #gettlsoff(x+2)@(gr8, gr0) + + sethi.p #gottlsdeschi(x+2+4096), gr14 + setlo #gottlsdesclo(x+2+4096), gr14 + ldd #tlsdesc(x+2+4096)@(gr15, gr14), gr8 + calll #gettlsoff(x+2+4096)@(gr8, gr0) + + sethi.p #gottlsdeschi(x+2+65536), gr14 + setlo #gottlsdesclo(x+2+65536), gr14 + ldd #tlsdesc(x+2+65536)@(gr15, gr14), gr8 + calll #gettlsoff(x+2+65536)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(x+3)), gr8 + setlos #gottlsdesclo(x+3), gr14 + calll #gettlsoff(x+3)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(x+3+4096)), gr8 + setlos #gottlsdesclo(x+3+4096), gr14 + calll #gettlsoff(x+3+4096)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(x+3+65536)), gr8 + setlos #gottlsdesclo(x+3+65536), gr14 + calll #gettlsoff(x+3+65536)@(gr8, gr0) + +.ifdef static_tls + ldi @(gr15, #gottlsoff12(l+1)), gr9 + ldi @(gr15, #gottlsoff12(l+1+65536)), gr9 + ldi @(gr15, #gottlsoff12(i+1)), gr9 + ldi @(gr15, #gottlsoff12(i+1+65536)), gr9 + ldi @(gr15, #gottlsoff12(0+1)), gr9 + ldi @(gr15, #gottlsoff12(0+1+65536)), gr9 + ldi @(gr15, #gottlsoff12(x+1)), gr9 + ldi @(gr15, #gottlsoff12(x+1+65536)), gr9 + + setlos #gottlsofflo(l+1+4096), gr8 + ld #tlsoff(l+1+4096)@(gr15, gr8), gr9 + + sethi #gottlsoffhi(i+1+4096), gr8 + setlo #gottlsofflo(i+1+4096), gr8 + ld #tlsoff(i+1+4096)@(gr15, gr8), gr9 +.endif diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-3.s b/binutils-2.21/ld/testsuite/ld-frv/tls-3.s new file mode 100644 index 0000000..6dd7972 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-3.s @@ -0,0 +1,20 @@ + .text + .weak u + .globl _start +_start: + call #gettlsoff(u) + + sethi.p #gottlsdeschi(u), gr14 + setlo #gottlsdesclo(u), gr14 + ldd #tlsdesc(u)@(gr15, gr14), gr8 + calll #gettlsoff(u)@(gr8, gr0) + + lddi.p @(gr15, #gottlsdesc12(u)), gr8 + setlos #gottlsdesclo(u), gr14 + calll #gettlsoff(u)@(gr8, gr0) + + ldi @(gr15, #gottlsoff12(u)), gr9 + + sethi.p #gottlsoffhi(u), gr14 + setlo #gottlsofflo(u), gr14 + ld #tlsoff(u)@(gr15, gr14), gr9 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-1.d new file mode 100644 index 0000000..b95505e --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-1.d @@ -0,0 +1,71 @@ +#name: FRV TLS relocs, dynamic linking +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: ff ff f8 20 cop2 -32,cpr63,cpr32,cpr63 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: ff ff f8 10 cop2 -32,cpr63,cpr16,cpr63 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-2.d new file mode 100644 index 0000000..07bf332 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-2.d @@ -0,0 +1,200 @@ +#name: FRV TLS relocs with addends, dynamic linking +#source: tls-2.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc 08 21 setlos 0x821,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 21 setlo 0xf821,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc 00 01 setlos 0x1,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 c8 ff bc ldi @\(gr15,-68\),gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc f8 11 setlos 0xf*fffff811,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc 10 01 setlos 0x1001,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 c8 ff d4 ldi @\(gr15,-44\),gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc 08 11 setlos 0x811,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 12 f8 00 01 sethi\.p 0x1,gr9 +[0-9a-f ]+: 92 f4 00 01 setlo 0x1,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 c8 ff ec ldi @\(gr15,-20\),gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 11 setlo 0xf811,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 92 fc f8 21 setlos 0xf*fffff821,gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 fc f8 11 setlos 0xf*fffff811,gr9 +[0-9a-f ]+: 92 fc 08 11 setlos 0x811,gr9 +[0-9a-f ]+: 92 c8 ff f4 ldi @\(gr15,-12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 12 setlos 0xf*fffff812,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 12 setlos 0x812,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 12 setlo 0xf812,gr9 +[0-9a-f ]+: 12 fc f8 13 setlos\.p 0xf*fffff813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 08 13 setlos\.p 0x813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 f8 13 setlo 0xf813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: 92 fc f8 21 setlos 0xf*fffff821,gr9 +[0-9a-f ]+: 92 fc 08 21 setlos 0x821,gr9 +[0-9a-f ]+: 92 c8 ff ac ldi @\(gr15,-84\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 22 setlos 0xf*fffff822,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 22 setlos 0x822,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 22 setlo 0xf822,gr9 +[0-9a-f ]+: 12 fc f8 23 setlos\.p 0xf*fffff823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 08 23 setlos\.p 0x823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 f8 23 setlo 0xf823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: 92 fc 00 01 setlos 0x1,gr9 +[0-9a-f ]+: 92 fc 10 01 setlos 0x1001,gr9 +[0-9a-f ]+: 92 c8 ff e4 ldi @\(gr15,-28\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 02 setlos 0x2,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 02 setlos 0x1002,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 02 setlo 0x2,gr9 +[0-9a-f ]+: 12 fc 00 03 setlos\.p 0x3,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 10 03 setlos\.p 0x1003,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 01 sethi\.p 0x1,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 00 03 setlo 0x3,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: 92 c8 ff bc ldi @\(gr15,-68\),gr9 +[0-9a-f ]+: 92 c8 ff d4 ldi @\(gr15,-44\),gr9 +[0-9a-f ]+: 92 c8 ff ec ldi @\(gr15,-20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 20 ldi @\(gr15,32\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 1c ldi @\(gr15,28\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 14 ldi\.p @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_-0x60)>: +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 08 21 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 f8 21 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 00 01 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 01 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: ff ff f8 11 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 10 01 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 01 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 08 11 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 01 00 01 .* +[0-9a-f ]+: 00 00 00 00 .* +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 01 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: 00 00 f8 11 .* +[0-9a-f ]+: 00 01 02 c0 .* +[0-9a-f ]+: ff ff f8 21 .* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 00 03 .* +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 03 .* +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 03 .* +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 02 .* +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 02 .* +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 02 .* +[0-9a-f ]+: R_FRV_TLSOFF x diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-3.d new file mode 100644 index 0000000..c9750d2 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-dynamic-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, dynamic linking +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-initial-shared-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-initial-shared-2.d new file mode 100644 index 0000000..e4ea6a1 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-initial-shared-2.d @@ -0,0 +1,235 @@ +#name: FRV TLS relocs with addends, shared linking with static TLS +#source: tls-2.s +#as: --defsym static_tls=1 +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 92 c8 f0 5c ldi @\(gr15,92\),gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 90 cc ff e8 lddi @\(gr15,-24\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 92 c8 f0 78 ldi @\(gr15,120\),gr9 +[0-9a-f ]+: c0 3a 40 00 bralr +[0-9a-f ]+: 90 cc ff f8 lddi @\(gr15,-8\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 30 ldi @\(gr15,48\),gr9 +[0-9a-f ]+: 92 c8 f0 78 ldi @\(gr15,120\),gr9 +[0-9a-f ]+: 92 c8 f0 4c ldi @\(gr15,76\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 70 ldi @\(gr15,112\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 7c ldi @\(gr15,124\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 8c ldi @\(gr15,140\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 34 ldi\.p @\(gr15,52\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 3c ldi\.p @\(gr15,60\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 50 ldi\.p @\(gr15,80\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: 92 c8 f0 54 ldi @\(gr15,84\),gr9 +[0-9a-f ]+: 92 c8 f0 5c ldi @\(gr15,92\),gr9 +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 90 ldi @\(gr15,144\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 60 ldi @\(gr15,96\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 64 ldi @\(gr15,100\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 58 ldi\.p @\(gr15,88\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 1c ldi\.p @\(gr15,28\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: 92 c8 f0 24 ldi @\(gr15,36\),gr9 +[0-9a-f ]+: fe 3f ff c1 call .* +[0-9a-f ]+: 92 c8 f0 40 ldi @\(gr15,64\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 68 ldi @\(gr15,104\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 80 ldi @\(gr15,128\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 84 ldi @\(gr15,132\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 28 ldi\.p @\(gr15,40\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 38 ldi\.p @\(gr15,56\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 44 ldi\.p @\(gr15,68\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: 92 c8 f0 2c ldi @\(gr15,44\),gr9 +[0-9a-f ]+: fe 3f ff 9f call .* +[0-9a-f ]+: 92 c8 f0 48 ldi @\(gr15,72\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 6c ldi @\(gr15,108\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 74 ldi @\(gr15,116\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 88 ldi @\(gr15,136\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 14 ldi\.p @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 20 ldi\.p @\(gr15,32\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 30 ldi @\(gr15,48\),gr9 +[0-9a-f ]+: 92 c8 f0 4c ldi @\(gr15,76\),gr9 +[0-9a-f ]+: 92 c8 f0 54 ldi @\(gr15,84\),gr9 +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 92 c8 f0 24 ldi @\(gr15,36\),gr9 +[0-9a-f ]+: 92 c8 f0 40 ldi @\(gr15,64\),gr9 +[0-9a-f ]+: 92 c8 f0 2c ldi @\(gr15,44\),gr9 +[0-9a-f ]+: 92 c8 f0 48 ldi @\(gr15,72\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 78 ldi @\(gr15,120\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 5c ldi @\(gr15,92\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_-0x20)>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 11 add\.p sp,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f1 \*unknown\* + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: 00 00 10 13 add\.p sp,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 11 add\.p gr16,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 13 add\.p gr16,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 07 f1 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 17 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f1 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 11 add\.p gr0,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 13 add\.p gr0,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 11 add\.p sp,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 12 add\.p sp,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 12 add\.p gr16,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 17 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 12 add\.p gr0,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-pie-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-pie-1.d new file mode 100644 index 0000000..0ced90a --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-pie-1.d @@ -0,0 +1,71 @@ +#name: FRV TLS relocs, pie linking +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -pie tmpdir/tls-1-dep.so + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: ff ff f8 20 cop2 -32,cpr63,cpr32,cpr63 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: ff ff f8 10 cop2 -32,cpr63,cpr16,cpr63 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-pie-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-pie-3.d new file mode 100644 index 0000000..4dc3469 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-pie-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, pie linking +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -pie + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-1.d new file mode 100644 index 0000000..3d7ec36 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-1.d @@ -0,0 +1,67 @@ +#name: FRV TLS relocs, dynamic linking with relaxation +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF x diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-2.d new file mode 100644 index 0000000..59577d3 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-2.d @@ -0,0 +1,149 @@ +#name: FRV TLS relocs with addends, dynamic linking, relaxing +#source: tls-2.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 fc f8 11 setlos 0xf*fffff811,gr9 +[0-9a-f ]+: 92 fc 08 11 setlos 0x811,gr9 +[0-9a-f ]+: 92 c8 f0 2c ldi @\(gr15,44\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 12 setlos 0xf*fffff812,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 12 setlos 0x812,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 12 setlo 0xf812,gr9 +[0-9a-f ]+: 12 fc f8 13 setlos\.p 0xf*fffff813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 08 13 setlos\.p 0x813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 f8 13 setlo 0xf813,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: 92 fc f8 21 setlos 0xf*fffff821,gr9 +[0-9a-f ]+: 92 fc 08 21 setlos 0x821,gr9 +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 22 setlos 0xf*fffff822,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 22 setlos 0x822,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 22 setlo 0xf822,gr9 +[0-9a-f ]+: 12 fc f8 23 setlos\.p 0xf*fffff823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 08 23 setlos\.p 0x823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 00 sethi\.p hi\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 f8 23 setlo 0xf823,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: 92 fc 00 01 setlos 0x1,gr9 +[0-9a-f ]+: 92 fc 10 01 setlos 0x1001,gr9 +[0-9a-f ]+: 92 c8 f0 24 ldi @\(gr15,36\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 02 setlos 0x2,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 02 setlos 0x1002,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 02 setlo 0x2,gr9 +[0-9a-f ]+: 12 fc 00 03 setlos\.p 0x3,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 10 03 setlos\.p 0x1003,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 f8 00 01 sethi\.p 0x1,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 f4 00 03 setlo 0x3,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 92 c8 f0 1c ldi @\(gr15,28\),gr9 +[0-9a-f ]+: 92 c8 f0 28 ldi @\(gr15,40\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 38 ldi @\(gr15,56\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 34 ldi @\(gr15,52\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 30 ldi @\(gr15,48\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 20 ldi\.p @\(gr15,32\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 f8 21 \*unknown\* +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 f8 11 \*unknown\* +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-3.d new file mode 100644 index 0000000..43cbdc7 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-dynamic-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, dynamic linking with relaxation +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: tmpdir/tls-1-dep.so --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-initial-shared-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-initial-shared-2.d new file mode 100644 index 0000000..824cf65 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-initial-shared-2.d @@ -0,0 +1,214 @@ +#name: FRV TLS relocs with addends, shared linking with static TLS, relaxing +#source: tls-2.s +#as: --defsym static_tls=1 +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 34 ldi @\(gr15,52\),gr9 +[0-9a-f ]+: 92 c8 f0 44 ldi @\(gr15,68\),gr9 +[0-9a-f ]+: 92 c8 f0 5c ldi @\(gr15,92\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 7c ldi @\(gr15,124\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 84 ldi @\(gr15,132\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 94 ldi @\(gr15,148\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 38 ldi\.p @\(gr15,56\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 48 ldi\.p @\(gr15,72\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 60 ldi\.p @\(gr15,96\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: 92 c8 f0 64 ldi @\(gr15,100\),gr9 +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 92 c8 f0 1c ldi @\(gr15,28\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 98 ldi @\(gr15,152\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 6c ldi @\(gr15,108\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 70 ldi @\(gr15,112\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 68 ldi\.p @\(gr15,104\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 20 ldi\.p @\(gr15,32\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: 92 c8 f0 28 ldi @\(gr15,40\),gr9 +[0-9a-f ]+: 92 c8 f0 4c ldi @\(gr15,76\),gr9 +[0-9a-f ]+: 92 c8 f0 50 ldi @\(gr15,80\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 74 ldi @\(gr15,116\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 88 ldi @\(gr15,136\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 8c ldi @\(gr15,140\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 2c ldi\.p @\(gr15,44\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 3c ldi\.p @\(gr15,60\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 54 ldi\.p @\(gr15,84\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: 92 c8 f0 30 ldi @\(gr15,48\),gr9 +[0-9a-f ]+: 92 c8 f0 40 ldi @\(gr15,64\),gr9 +[0-9a-f ]+: 92 c8 f0 58 ldi @\(gr15,88\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 78 ldi @\(gr15,120\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 80 ldi @\(gr15,128\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 90 ldi @\(gr15,144\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 14 ldi\.p @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 18 ldi\.p @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 24 ldi\.p @\(gr15,36\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 34 ldi @\(gr15,52\),gr9 +[0-9a-f ]+: 92 c8 f0 5c ldi @\(gr15,92\),gr9 +[0-9a-f ]+: 92 c8 f0 64 ldi @\(gr15,100\),gr9 +[0-9a-f ]+: 92 c8 f0 1c ldi @\(gr15,28\),gr9 +[0-9a-f ]+: 92 c8 f0 28 ldi @\(gr15,40\),gr9 +[0-9a-f ]+: 92 c8 f0 50 ldi @\(gr15,80\),gr9 +[0-9a-f ]+: 92 c8 f0 30 ldi @\(gr15,48\),gr9 +[0-9a-f ]+: 92 c8 f0 58 ldi @\(gr15,88\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 44 ldi @\(gr15,68\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: 00 00 10 11 add\.p sp,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 13 add\.p sp,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 11 add\.p gr16,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 13 add\.p gr16,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 07 f1 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 17 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 17 f1 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f1 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f3 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 11 add\.p gr0,gr17,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 13 add\.p gr0,gr19,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 12 add\.p sp,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 12 add\.p gr16,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 17 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 07 f2 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 00 12 add\.p gr0,gr18,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-1.d new file mode 100644 index 0000000..579047e --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-1.d @@ -0,0 +1,67 @@ +#name: FRV TLS relocs, pie linking with relaxation +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -pie tmpdir/tls-1-dep.so --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF x diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-3.d new file mode 100644 index 0000000..da26ca0 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-pie-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, pie linking with relaxation +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -pie --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-1.d new file mode 100644 index 0000000..ba3b532 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-1.d @@ -0,0 +1,73 @@ +#name: FRV TLS relocs, shared linking with relaxation +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 14 ldi\.p @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 18 ldi\.p @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f0 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-2.d new file mode 100644 index 0000000..c07bb35 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-2.d @@ -0,0 +1,264 @@ +#name: FRV TLS relocs with addends, shared linking, relaxing +#source: tls-2.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds --relax + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 90 cc f0 10 lddi @\(gr15,16\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 30 lddi @\(gr15,48\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 40 lddi @\(gr15,64\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 50 lddi @\(gr15,80\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 58 lddi @\(gr15,88\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 68 lddi @\(gr15,104\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff a8 lddi @\(gr15,-88\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff b0 lddi @\(gr15,-80\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff c8 lddi @\(gr15,-56\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff d8 lddi @\(gr15,-40\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff e0 lddi @\(gr15,-32\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff f0 lddi @\(gr15,-16\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: fe 3f ff f0 call .* +[0-9a-f ]+: fe 3f ff f5 call .* +[0-9a-f ]+: fe 3f ff fa call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 98 setlo 0x98,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 a8 setlo 0xa8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 c0 setlo 0xc0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 60 lddi\.p @\(gr15,96\),gr8 +[0-9a-f ]+: 9c fc 00 60 setlos 0x60,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff b8 lddi\.p @\(gr15,-72\),gr8 +[0-9a-f ]+: 9c fc ff b8 setlos 0xf*ffffffb8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff e8 lddi\.p @\(gr15,-24\),gr8 +[0-9a-f ]+: 9c fc ff e8 setlos 0xf*ffffffe8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: fe 3f ff e0 call .* +[0-9a-f ]+: fe 3f ff c9 call .* +[0-9a-f ]+: fe 3f ff ca call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 c8 setlo 0xc8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 78 setlo 0x78,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 88 setlo 0x88,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff f8 lddi\.p @\(gr15,-8\),gr8 +[0-9a-f ]+: 9c fc ff f8 setlos 0xf*fffffff8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 18 lddi\.p @\(gr15,24\),gr8 +[0-9a-f ]+: 9c fc 00 18 setlos 0x18,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 38 lddi\.p @\(gr15,56\),gr8 +[0-9a-f ]+: 9c fc 00 38 setlos 0x38,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: fe 3f ff b0 call .* +[0-9a-f ]+: fe 3f ff b5 call .* +[0-9a-f ]+: fe 3f ff ba call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 90 setlo 0x90,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 a0 setlo 0xa0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 b8 setlo 0xb8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 48 lddi\.p @\(gr15,72\),gr8 +[0-9a-f ]+: 9c fc 00 48 setlos 0x48,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff a0 lddi\.p @\(gr15,-96\),gr8 +[0-9a-f ]+: 9c fc ff a0 setlos 0xf*ffffffa0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff d0 lddi\.p @\(gr15,-48\),gr8 +[0-9a-f ]+: 9c fc ff d0 setlos 0xf*ffffffd0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: fe 3f ff 94 call .* +[0-9a-f ]+: fe 3f ff 99 call .* +[0-9a-f ]+: fe 3f ff 9e call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 b0 setlo 0xb0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 80 setlo 0x80,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 70 setlo 0x70,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 20 lddi\.p @\(gr15,32\),gr8 +[0-9a-f ]+: 9c fc 00 20 setlos 0x20,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 28 lddi\.p @\(gr15,40\),gr8 +[0-9a-f ]+: 9c fc 00 28 setlos 0x28,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff c0 lddi\.p @\(gr15,-64\),gr8 +[0-9a-f ]+: 9c fc ff c0 setlos 0xf*ffffffc0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_-0x60)>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 11 add\.p gr0,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 13 add\.p gr0,gr19,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 11 add\.p sp,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 13 add\.p sp,gr19,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 11 add\.p gr16,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 13 add\.p gr16,gr19,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 12 add\.p sp,gr18,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 12 add\.p gr16,gr18,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 12 add\.p gr0,gr18,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-3.d new file mode 100644 index 0000000..b766a00 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-shared-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, shared linking with relaxation +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-1.d new file mode 100644 index 0000000..d87d22c --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-1.d @@ -0,0 +1,62 @@ +#name: FRV TLS relocs, static linking with relaxation +#source: tls-1.s +#objdump: -D -j .text -j .got -j .plt +#ld: -static tmpdir/tls-1-dep.o --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 30 setlos\.p 0xf*fffff830,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 30 setlos 0xf*fffff830,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-3.d new file mode 100644 index 0000000..ed3c07a --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-relax-static-3.d @@ -0,0 +1,26 @@ +#name: FRV TLS undefweak relocs, static linking with relaxation +#source: tls-3.s +#objdump: -D -j .text -j .got -j .plt +#ld: -static --relax + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +00010094 <_start>: + 10094: 92 fc 00 00 setlos lo\(0x0\),gr9 + 10098: 00 88 00 00 nop\.p + 1009c: 80 88 00 00 nop + 100a0: 92 fc 00 00 setlos lo\(0x0\),gr9 + 100a4: 80 88 00 00 nop + 100a8: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 + 100ac: 80 88 00 00 nop + 100b0: 80 88 00 00 nop + 100b4: 92 fc 00 00 setlos lo\(0x0\),gr9 + 100b8: 00 88 00 00 nop\.p + 100bc: 80 88 00 00 nop + 100c0: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +000140c8 <(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1-fail.d b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1-fail.d new file mode 100644 index 0000000..8cb220d --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1-fail.d @@ -0,0 +1,4 @@ +#name: FRV TLS relocs, shared linking +#source: tls-1.s +#ld: -shared tmpdir/tls-1-dep.so +#error: different segment diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1.d new file mode 100644 index 0000000..2a29ba5 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-1.d @@ -0,0 +1,73 @@ +#name: FRV TLS relocs, shared linking with local binding +#source: tls-1.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 10 ldi\.p @\(gr15,16\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 14 ldi\.p @\(gr15,20\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 18 ldi\.p @\(gr15,24\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 20 setlos 0xf*fffff820,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 10 ldi @\(gr15,16\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 14 ldi @\(gr15,20\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 18 ldi @\(gr15,24\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: 00 00 00 10 add\.p gr0,gr16,gr0 +[0-9a-f ]+: R_FRV_TLSOFF \.tbss + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF x +[0-9a-f ]+: R_FRV_TLSOFF \.tbss +[0-9a-f ]+: 00 00 07 f0 \*unknown\* +[0-9a-f ]+: R_FRV_TLSOFF \.tbss diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-shared-2.d b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-2.d new file mode 100644 index 0000000..bd92cdb --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-2.d @@ -0,0 +1,264 @@ +#name: FRV TLS relocs with addends, shared linking +#source: tls-2.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared tmpdir/tls-1-dep.so --version-script tls-1-shared.lds + +.*: file format elf.*frv.* + +Disassembly of section \.plt: + +[0-9a-f ]+<\.plt>: +[0-9a-f ]+: 90 cc f0 10 lddi @\(gr15,16\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 30 lddi @\(gr15,48\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 40 lddi @\(gr15,64\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 50 lddi @\(gr15,80\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 58 lddi @\(gr15,88\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc f0 68 lddi @\(gr15,104\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff a8 lddi @\(gr15,-88\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff b0 lddi @\(gr15,-80\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff c8 lddi @\(gr15,-56\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff d8 lddi @\(gr15,-40\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff e0 lddi @\(gr15,-32\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +[0-9a-f ]+: 90 cc ff f0 lddi @\(gr15,-16\),gr8 +[0-9a-f ]+: 80 30 80 00 jmpl @\(gr8,gr0\) +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: fe 3f ff f0 call .* +[0-9a-f ]+: fe 3f ff f5 call .* +[0-9a-f ]+: fe 3f ff fa call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 98 setlo 0x98,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 a8 setlo 0xa8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 c0 setlo 0xc0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 60 lddi\.p @\(gr15,96\),gr8 +[0-9a-f ]+: 9c fc 00 60 setlos 0x60,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff b8 lddi\.p @\(gr15,-72\),gr8 +[0-9a-f ]+: 9c fc ff b8 setlos 0xf*ffffffb8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff e8 lddi\.p @\(gr15,-24\),gr8 +[0-9a-f ]+: 9c fc ff e8 setlos 0xf*ffffffe8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 14 setlos 0xf*fffff814,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 14 setlos 0x814,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 14 setlo 0xf814,gr9 +[0-9a-f ]+: fe 3f ff e0 call .* +[0-9a-f ]+: fe 3f ff c9 call .* +[0-9a-f ]+: fe 3f ff ca call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 c8 setlo 0xc8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 78 setlo 0x78,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 88 setlo 0x88,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff f8 lddi\.p @\(gr15,-8\),gr8 +[0-9a-f ]+: 9c fc ff f8 setlos 0xf*fffffff8,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 18 lddi\.p @\(gr15,24\),gr8 +[0-9a-f ]+: 9c fc 00 18 setlos 0x18,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 38 lddi\.p @\(gr15,56\),gr8 +[0-9a-f ]+: 9c fc 00 38 setlos 0x38,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 24 setlos 0xf*fffff824,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 08 24 setlos 0x824,gr9 +[0-9a-f ]+: 92 f8 00 00 sethi hi\(0x0\),gr9 +[0-9a-f ]+: 92 f4 f8 24 setlo 0xf824,gr9 +[0-9a-f ]+: fe 3f ff b0 call .* +[0-9a-f ]+: fe 3f ff b5 call .* +[0-9a-f ]+: fe 3f ff ba call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 90 setlo 0x90,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 a0 setlo 0xa0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 b8 setlo 0xb8,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 48 lddi\.p @\(gr15,72\),gr8 +[0-9a-f ]+: 9c fc 00 48 setlos 0x48,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff a0 lddi\.p @\(gr15,-96\),gr8 +[0-9a-f ]+: 9c fc ff a0 setlos 0xf*ffffffa0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff d0 lddi\.p @\(gr15,-48\),gr8 +[0-9a-f ]+: 9c fc ff d0 setlos 0xf*ffffffd0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 04 setlos 0x4,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 10 04 setlos 0x1004,gr9 +[0-9a-f ]+: 92 f8 00 01 sethi 0x1,gr9 +[0-9a-f ]+: 92 f4 00 04 setlo 0x4,gr9 +[0-9a-f ]+: fe 3f ff 94 call .* +[0-9a-f ]+: fe 3f ff 99 call .* +[0-9a-f ]+: fe 3f ff 9e call .* +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 b0 setlo 0xb0,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 80 setlo 0x80,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 1c f8 00 00 sethi\.p hi\(0x0\),gr14 +[0-9a-f ]+: 9c f4 00 70 setlo 0x70,gr14 +[0-9a-f ]+: 90 08 f1 4e ldd @\(gr15,gr14\),gr8 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 20 lddi\.p @\(gr15,32\),gr8 +[0-9a-f ]+: 9c fc 00 20 setlos 0x20,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc f0 28 lddi\.p @\(gr15,40\),gr8 +[0-9a-f ]+: 9c fc 00 28 setlos 0x28,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +[0-9a-f ]+: 10 cc ff c0 lddi\.p @\(gr15,-64\),gr8 +[0-9a-f ]+: 9c fc ff c0 setlos 0xf*ffffffc0,gr14 +[0-9a-f ]+: 82 30 80 00 calll @\(gr8,gr0\) +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_-0x60)>: +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 01 add\.p sp,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 01 add\.p gr16,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 03 add\.p gr16,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 11 add\.p gr0,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 13 add\.p gr0,gr19,gr0 + +[0-9a-f ]+<_GLOBAL_OFFSET_TABLE_>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 11 add\.p sp,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 13 add\.p sp,gr19,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 03 add\.p sp,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 11 add\.p gr16,gr17,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 13 add\.p gr16,gr19,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f3 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 01 add\.p gr0,sp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 03 add\.p gr0,gr3,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f1 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 12 add\.p sp,gr18,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 12 add\.p gr16,gr18,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 07 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 17 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 10 02 add\.p sp,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE x +[0-9a-f ]+: 00 00 00 02 add\.p gr0,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 07 f2 \*unknown\* +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 01 00 02 add\.p gr16,fp,gr0 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 +[0-9a-f ]+: R_FRV_TLSDESC_VALUE \.tbss +[0-9a-f ]+: 00 00 00 12 add\.p gr0,gr18,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-shared-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-3.d new file mode 100644 index 0000000..c4eed38 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-shared-3.d @@ -0,0 +1,27 @@ +#name: FRV TLS undefweak relocs, shared linking +#source: tls-3.s +#objdump: -DR -j .text -j .got -j .plt +#ld: -shared + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 c8 f0 0c ldi\.p @\(gr15,12\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 c8 f0 0c ldi @\(gr15,12\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: R_FRV_TLSOFF u diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-static-1.d b/binutils-2.21/ld/testsuite/ld-frv/tls-static-1.d new file mode 100644 index 0000000..d33d8cf --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-static-1.d @@ -0,0 +1,70 @@ +#name: FRV TLS relocs, static linking +#source: tls-1.s +#objdump: -D -j .text -j .got -j .plt +#ld: -static tmpdir/tls-1-dep.o + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 10 setlos\.p 0xf*fffff810,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 20 setlos\.p 0xf*fffff820,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc f8 30 setlos\.p 0xf*fffff830,gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 90 fc f8 30 setlos 0xf*fffff830,gr8 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 10 setlos 0xf*fffff810,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 20 setlos 0xf*fffff820,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc f8 30 setlos 0xf*fffff830,gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. +[0-9a-f ]+: ff ff f8 30 cop2 -32,cpr63,cpr48,cpr63 +[0-9a-f ]+: ff ff f8 10 cop2 -32,cpr63,cpr16,cpr63 +[0-9a-f ]+: ff ff f8 20 cop2 -32,cpr63,cpr32,cpr63 +[0-9a-f ]+: 00 00 00 00 add\.p gr0,gr0,gr0 diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls-static-3.d b/binutils-2.21/ld/testsuite/ld-frv/tls-static-3.d new file mode 100644 index 0000000..e761cc8 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls-static-3.d @@ -0,0 +1,26 @@ +#name: FRV TLS undefweak relocs, static linking +#source: tls-3.s +#objdump: -D -j .text -j .got -j .plt +#ld: -static + +.*: file format elf.*frv.* + +Disassembly of section \.text: + +[0-9a-f ]+<_start>: +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 12 fc 00 00 setlos\.p lo\(0x0\),gr9 +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +[0-9a-f ]+: 00 88 00 00 nop\.p +[0-9a-f ]+: 80 88 00 00 nop +[0-9a-f ]+: 92 fc 00 00 setlos lo\(0x0\),gr9 +Disassembly of section \.got: + +[0-9a-f ]+<(__data_start|_GLOBAL_OFFSET_TABLE_)>: + \.\.\. diff --git a/binutils-2.21/ld/testsuite/ld-frv/tls.exp b/binutils-2.21/ld/testsuite/ld-frv/tls.exp new file mode 100644 index 0000000..bb3d6a3 --- /dev/null +++ b/binutils-2.21/ld/testsuite/ld-frv/tls.exp @@ -0,0 +1,65 @@ +# Expect script for FRV FDPIC TLS linker tests +# Copyright 2003, 2004, 2005, 2007 Free Software Foundation, Inc. +# +# This file is part of the GNU Binutils. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, +# MA 02110-1301, USA. +# + +if {![istarget frv*-*-*] || ![is_elf_format]} { + return +} + +global ASFLAGS +set saved_ASFLAGS "$ASFLAGS" +set ASFLAGS "$ASFLAGS -mfdpic" + +global LDFLAGS +set saved_LDFLAGS "$LDFLAGS" +set LDFLAGS "$LDFLAGS -melf32frvfd" + +run_ld_link_tests [list [list "tls-1-dep" "$LDFLAGS -shared" "" "tls-1-dep.s" [list] "tls-1-dep.so" ""]] +run_dump_test "tls-static-1" +run_dump_test "tls-dynamic-1" +run_dump_test "tls-pie-1" +run_dump_test "tls-shared-1-fail" +run_dump_test "tls-shared-1" + +run_dump_test "tls-relax-static-1" +run_dump_test "tls-relax-dynamic-1" +run_dump_test "tls-relax-pie-1" +run_dump_test "tls-relax-shared-1" + +run_dump_test "tls-dynamic-2" +run_dump_test "tls-shared-2" +run_dump_test "tls-initial-shared-2" + +run_dump_test "tls-relax-dynamic-2" +run_dump_test "tls-relax-shared-2" +run_dump_test "tls-relax-initial-shared-2" + +run_dump_test "tls-static-3" +run_dump_test "tls-dynamic-3" +run_dump_test "tls-pie-3" +run_dump_test "tls-shared-3" + +run_dump_test "tls-relax-static-3" +run_dump_test "tls-relax-dynamic-3" +run_dump_test "tls-relax-pie-3" +run_dump_test "tls-relax-shared-3" + +set LDFLAGS "$saved_LDFLAGS" +set ASFLAGS "$saved_ASFLAGS" |