mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-27 04:52:05 +08:00
40fc1451c6
The MIPS assembly idiom 'move' now maps to the 'or' machine instruction. This change affects microMIPS, MIPS32, MIPS64. 2015-08-12 Simon Dardis <simon.dardis@imgtec.com> opcodes/ * micromips-opc.c (micromips_opcodes): Re-order table so that move based on 'or' is first. * mips-opc.c (mips_builtin_opcodes): Ditto. bfd/ * elfxx-mips.c (STUB_MOVE): Change to use 'or' only. (mips_o32_exec_plt0_entry, mips_n32_exec_plt0_entry, mips_n64_exec_plt0_entry, micromips_insn32_o32_exec_plt0_entry): Update to use 'or' instead of 'addu/daddu'. (_bfd_mips_elf_finish_dynamic_symbol): Update usage of STUB_MOVE. (move_insns_32): Reorder table. gas/ * config/tc-mips.c (move_register): Change to use 'or' only. (s_cpload, s_cpsetup, s_cprestore, s_cpreturn): Update to use or for move. gas/testsuite/ * gas/mips/elf-rel23.d: Update test. * gas/mips/elf-rel23.d: Ditto. * gas/mips/elf-rel23a.d: Ditto. * gas/mips/elf-rel23b.d: Ditto. * gas/mips/elf_e_flags1.d: Ditto. * gas/mips/elf_e_flags2.d: Ditto. * gas/mips/elf_e_flags3.d: Ditto. * gas/mips/elf_e_flags4.d: Ditto. * gas/mips/loc-swap-dis.d: Ditto. * gas/mips/micromips-insn32.d: Ditto. * gas/mips/micromips-noinsn32.d: Ditto. * gas/mips/micromips-trap.d: Ditto. * gas/mips/micromips.d: Ditto. * gas/mips/mips-abi32-pic.d: Ditto. * gas/mips/mips-abi32.d: Ditto. * gas/mips/mips-gp32-fp32-pic.d: Ditto. * gas/mips/mips-gp32-fp32.d: Ditto. * gas/mips/mips-gp32-fp64-pic.d: Ditto. * gas/mips/mips-gp32-fp64.d: Ditto. * gas/mips/mips-gp64-fp32-pic.d: Ditto. * gas/mips/mips-gp64-fp32.d: Ditto. * gas/mips/mips-gp64-fp64-pic.d: Ditto. * gas/mips/mips-gp64-fp64.d: Ditto. * gas/mips/mipsr6@loc-swap-dis.d: Ditto. * gas/mips/tls-o32.d: Ditto. * gas/mips/uld2-eb.d: Ditto. * gas/mips/uld2-el.d: Ditto. * gas/mips/ulw2-eb-ilocks.d: Ditto. * gas/mips/ulw2-eb.d: Ditto. * gas/mips/ulw2-el-ilocks.d: Ditto. * gas/mips/ulw2-el.d: Ditto. * gas/mips/move.d: New test. * gas/mips/move.s: Ditto. * gas/mips/micromips32-move.d: Ditto. * gas/mips/micromips32-move.s: Ditto. * gas/mips/mips.exp: Run the new tests. gold/ * mips.cc (plt0_entry_o32, plt0_entry_n32, plt0_entry_n64, lazy_stub_normal_1, lazy_stub_normal_1_n64, lazy_stub_normal_2, lazy_stub_normal_2_n64, lazy_stub_big, lazy_stub_big_n64, lazy_stub_micromips32_normal_1_n64, lazy_stub_micromips32_normal_2_n64, lazy_stub_micromips32_big, lazy_stub_micromips32_big_n64): Update to use 'or' for move instead of 'addu/daddu'. ld/testsuite/ * ld-mips-elf/compressed-plt-1-n32-mips16.od: Update test. * ld-mips-elf/compressed-plt-1-n32-umips.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-mips16-got.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-mips16-only.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-mips16-word.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-mips16.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-se.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-umips-got.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-umips-word.od: Ditto. * ld-mips-elf/compressed-plt-1-o32-umips.od: Ditto. * ld-mips-elf/jalx-2.dd: Ditto. * ld-mips-elf/mips16-pic-3.dd: Ditto. * ld-mips-elf/pic-and-nonpic-3a.dd: Ditto. * ld-mips-elf/pic-and-nonpic-3b.dd: Ditto. * ld-mips-elf/pic-and-nonpic-5b.dd: Ditto. * ld-mips-elf/pic-and-nonpic-6-n32.dd: Ditto. * ld-mips-elf/pic-and-nonpic-6-o32.dd: Ditto. * ld-mips-elf/stub-dynsym-1-10000.d: Ditto. * ld-mips-elf/stub-dynsym-1-2fe80.d: Ditto. * ld-mips-elf/stub-dynsym-1-7fff.d: Ditto. * ld-mips-elf/stub-dynsym-1-8000.d: Ditto. * ld-mips-elf/stub-dynsym-1-fff0.d: Ditto. * ld-mips-elf/tlsbin-o32.d: Ditto. * ld-mips-elf/tlsdyn-o32-1.d: Ditto. * ld-mips-elf/tlsdyn-o32-2.d: Ditto. * ld-mips-elf/tlsdyn-o32-3.d: Ditto. * ld-mips-elf/tlsdyn-o32.d: Ditto. * ld-mips-elf/tlslib-o32.d: Ditto.
103 lines
2.5 KiB
Plaintext
103 lines
2.5 KiB
Plaintext
# GOT layout:
|
|
#
|
|
# -32752: lazy resolution function
|
|
# -32748: reserved for module pointer
|
|
# -32744: extd2's local GOT entry (copy reloc)
|
|
# -32740: extf3's local GOT entry (PLT entry)
|
|
# -32736: extf4's local GOT entry (PLT entry)
|
|
# -32732: extf2's global GOT entry (undefined 0)
|
|
# -32728: extf1's global GOT entry (.MIPS.stubs entry)
|
|
# -32724: extd1's global GOT entry (undefined 0)
|
|
# -32720: extd4's global GOT entry (undefined 0, reloc only)
|
|
|
|
.*
|
|
|
|
Disassembly of section \.plt:
|
|
|
|
00043040 <.*>:
|
|
.*: 3c0e0008 lui t2,0x8
|
|
.*: 8dd91000 lw t9,4096\(t2\)
|
|
.*: 25ce1000 addiu t2,t2,4096
|
|
.*: 030ec023 subu t8,t8,t2
|
|
.*: 03e07825 move t3,ra
|
|
.*: 0018c082 srl t8,t8,0x2
|
|
.*: 0320f809 jalr t9
|
|
.*: 2718fffe addiu t8,t8,-2
|
|
|
|
00043060 <extf4@plt>:
|
|
.*: 3c0f0008 lui t3,0x8
|
|
.*: 8df91008 lw t9,4104\(t3\)
|
|
.*: 03200008 jr t9
|
|
.*: 25f81008 addiu t8,t3,4104
|
|
|
|
00043070 <extf5@plt>:
|
|
.*: 3c0f0008 lui t3,0x8
|
|
.*: 8df9100c lw t9,4108\(t3\)
|
|
.*: 03200008 jr t9
|
|
.*: 25f8100c addiu t8,t3,4108
|
|
|
|
00043080 <extf3@plt>:
|
|
.*: 3c0f0008 lui t3,0x8
|
|
.*: 8df91010 lw t9,4112\(t3\)
|
|
.*: 03200008 jr t9
|
|
.*: 25f81010 addiu t8,t3,4112
|
|
|
|
Disassembly of section \.text:
|
|
|
|
00044000 <.*>:
|
|
\.\.\.
|
|
|
|
00044008 <\.pic\.f1>:
|
|
44008: 3c190004 lui t9,0x4
|
|
4400c: 27394010 addiu t9,t9,16400
|
|
|
|
00044010 <f1>:
|
|
44010: 0c011013 jal 4404c <f3>
|
|
44014: 3c020004 lui v0,0x4
|
|
44018: 03e00008 jr ra
|
|
4401c: 24424020 addiu v0,v0,16416
|
|
|
|
00044020 <f2>:
|
|
44020: 3c1c0006 lui gp,0x6
|
|
44024: 0399e021 addu gp,gp,t9
|
|
44028: 279c3fd0 addiu gp,gp,16336
|
|
4402c: 8f998028 lw t9,-32728\(gp\)
|
|
44030: 8f848024 lw a0,-32732\(gp\)
|
|
44034: 8f85802c lw a1,-32724\(gp\)
|
|
44038: 0320f809 jalr t9
|
|
4403c: 8f868018 lw a2,-32744\(gp\)
|
|
44040: 8f99801c lw t9,-32740\(gp\)
|
|
44044: 03200008 jr t9
|
|
44048: 8f848020 lw a0,-32736\(gp\)
|
|
|
|
0004404c <f3>:
|
|
4404c: 03e00008 jr ra
|
|
44050: 00000000 nop
|
|
\.\.\.
|
|
|
|
00044060 <__start>:
|
|
44060: 0c011002 jal 44008 <\.pic\.f1>
|
|
44064: 00000000 nop
|
|
44068: 3c020004 lui v0,0x4
|
|
4406c: 24424020 addiu v0,v0,16416
|
|
44070: 0c010c20 jal 43080 <extf3@plt>
|
|
44074: 00000000 nop
|
|
44078: 0c010c18 jal 43060 <extf4@plt>
|
|
4407c: 00000000 nop
|
|
44080: 0c010c1c jal 43070 <extf5@plt>
|
|
44084: 00000000 nop
|
|
44088: 3c02000a lui v0,0xa
|
|
4408c: 24422000 addiu v0,v0,8192
|
|
44090: 3c02000a lui v0,0xa
|
|
44094: 24422018 addiu v0,v0,8216
|
|
\.\.\.
|
|
|
|
Disassembly of section \.MIPS\.stubs:
|
|
|
|
000440a0 <_MIPS_STUBS_>:
|
|
440a0: 8f998010 lw t9,-32752\(gp\)
|
|
440a4: 03e07825 move t3,ra
|
|
440a8: 0320f809 jalr t9
|
|
440ac: 24180009 li t8,9
|
|
\.\.\.
|