* elf32-arm.c (elf32_arm_nacl_plt0_entry, elf32_arm_nacl_plt_entry):
authorNick Clifton <nickc@redhat.com>
Thu, 12 Apr 2012 13:01:15 +0000 (13:01 +0000)
committerNick Clifton <nickc@redhat.com>
Thu, 12 Apr 2012 13:01:15 +0000 (13:01 +0000)
commitb38cadfb70dbcbe3f1b31f53e96f0ab9a72e394b
treee2e35eabac046b7d547d736256c15076ea8d1875
parentc9a1864ab2c53c0a4b7454a67db515631610fd72
* elf32-arm.c (elf32_arm_nacl_plt0_entry, elf32_arm_nacl_plt_entry):
New variables.
(struct elf32_arm_link_hash_table): New member `nacl_p'.
(elf32_arm_link_hash_table_create): Initialize it.
(elf32_arm_nacl_link_hash_table_create): New function.
(arm_movw_immediate, arm_movt_immediate): New functions.
(elf32_arm_populate_plt_entry): Test HTAB->nacl_p.
(elf32_arm_finish_dynamic_sections): Likewise.
(elf32_arm_output_plt_map_1): Likewise.
(bfd_elf32_littlearm_nacl_vec, bfd_elf32_bigarm_nacl_vec):
New backend vector stanza.
(elf32_arm_nacl_modify_segment_map): New function.
* config.bfd: Handle arm-*-nacl*, armeb-*-nacl*.
* targets.c: Support bfd_elf32_{big,little}_nacl_vec.
* configure.in: Likewise.
(bfd_elf32_bigarm_nacl_vec): Add elf-nacl.lo here.
(bfd_elf32_littlearm_nacl_vec): Likewise.
(bfd_elf32_bigarm_vec, bfd_elf32_littlearm_vec): Likewise.
(bfd_elf32_bigarm_symbian_vec): Likewise.
(bfd_elf32_littlearm_symbian_vec): Likewise.
(bfd_elf32_bigarm_vxworks_vec): Likewise.
(bfd_elf32_littlearm_vxworks_vec): Likewise.
* configure: Regenerated.

* configure.tgt (arm-*-nacl*): Match it.
* config/te-nacl.h (FPU_DEFAULT, EABI_DEFAULT): Define.
(LOCAL_LABELS_DOLLAR): Define.
* config/tc-arm.c (elf32_arm_target_format) [TE_NACL]:
Use nacl format variants.

* gas/elf/elf.exp (run_elf_list_test): Treat arm-*-nacl* targets
as -armeabi.

* gas/arm/any-idiv.d: Match *-*-nacl* targets too.
* gas/arm/arch4t.d: Likewise.
* gas/arm/arch4t-eabi.d: Likewise.
* gas/arm/attr-any-armv4t.d: Likewise.
* gas/arm/attr-any-thumbv6.d: Likewise.
* gas/arm/attr-cpu-directive.d: Likewise.
* gas/arm/attr-default.d: Likewise.
* gas/arm/attr-march-all.d: Likewise.
* gas/arm/attr-march-armv1.d: Likewise.
* gas/arm/attr-march-armv2a.d: Likewise.
* gas/arm/attr-march-armv2.d: Likewise.
* gas/arm/attr-march-armv2s.d: Likewise.
* gas/arm/attr-march-armv3.d: Likewise.
* gas/arm/attr-march-armv3m.d: Likewise.
* gas/arm/attr-march-armv4.d: Likewise.
* gas/arm/attr-march-armv4t.d: Likewise.
* gas/arm/attr-march-armv4txm.d: Likewise.
* gas/arm/attr-march-armv4xm.d: Likewise.
* gas/arm/attr-march-armv5.d: Likewise.
* gas/arm/attr-march-armv5t.d: Likewise.
* gas/arm/attr-march-armv5te.d: Likewise.
* gas/arm/attr-march-armv5tej.d: Likewise.
* gas/arm/attr-march-armv5texp.d: Likewise.
* gas/arm/attr-march-armv5txm.d: Likewise.
* gas/arm/attr-march-armv6.d: Likewise.
* gas/arm/attr-march-armv6j.d: Likewise.
* gas/arm/attr-march-armv6k.d: Likewise.
* gas/arm/attr-march-armv6k+sec.d: Likewise.
* gas/arm/attr-march-armv6kt2.d: Likewise.
* gas/arm/attr-march-armv6-m.d: Likewise.
* gas/arm/attr-march-armv6-m+os.d: Likewise.
* gas/arm/attr-march-armv6s-m.d: Likewise.
* gas/arm/attr-march-armv6t2.d: Likewise.
* gas/arm/attr-march-armv6z.d: Likewise.
* gas/arm/attr-march-armv6zk.d: Likewise.
* gas/arm/attr-march-armv6zkt2.d: Likewise.
* gas/arm/attr-march-armv6zt2.d: Likewise.
* gas/arm/attr-march-armv7-a.d: Likewise.
* gas/arm/attr-march-armv7a.d: Likewise.
* gas/arm/attr-march-armv7-a+idiv.d: Likewise.
* gas/arm/attr-march-armv7-a+mp.d: Likewise.
* gas/arm/attr-march-armv7-a+sec.d: Likewise.
* gas/arm/attr-march-armv7-a+sec+virt.d: Likewise.
* gas/arm/attr-march-armv7-a+virt.d: Likewise.
* gas/arm/attr-march-armv7.d: Likewise.
* gas/arm/attr-march-armv7em.d: Likewise.
* gas/arm/attr-march-armv7-m.d: Likewise.
* gas/arm/attr-march-armv7m.d: Likewise.
* gas/arm/attr-march-armv7-r.d: Likewise.
* gas/arm/attr-march-armv7r.d: Likewise.
* gas/arm/attr-march-armv7-r+mp.d: Likewise.
* gas/arm/attr-march-iwmmxt2.d: Likewise.
* gas/arm/attr-march-iwmmxt.d: Likewise.
* gas/arm/attr-march-xscale.d: Likewise.
* gas/arm/attr-mcpu.d: Likewise.
* gas/arm/attr-mfpu-arm1020e.d: Likewise.
* gas/arm/attr-mfpu-arm1020t.d: Likewise.
* gas/arm/attr-mfpu-arm1136jf-s.d: Likewise.
* gas/arm/attr-mfpu-arm1136jfs.d: Likewise.
* gas/arm/attr-mfpu-arm7500fe.d: Likewise.
* gas/arm/attr-mfpu-fpa10.d: Likewise.
* gas/arm/attr-mfpu-fpa11.d: Likewise.
* gas/arm/attr-mfpu-fpa.d: Likewise.
* gas/arm/attr-mfpu-fpe2.d: Likewise.
* gas/arm/attr-mfpu-fpe3.d: Likewise.
* gas/arm/attr-mfpu-fpe.d: Likewise.
* gas/arm/attr-mfpu-maverick.d: Likewise.
* gas/arm/attr-mfpu-neon.d: Likewise.
* gas/arm/attr-mfpu-neon-fp16.d: Likewise.
* gas/arm/attr-mfpu-softfpa.d: Likewise.
* gas/arm/attr-mfpu-softvfp.d: Likewise.
* gas/arm/attr-mfpu-softvfp+vfp.d: Likewise.
* gas/arm/attr-mfpu-vfp10.d: Likewise.
* gas/arm/attr-mfpu-vfp10-r0.d: Likewise.
* gas/arm/attr-mfpu-vfp3.d: Likewise.
* gas/arm/attr-mfpu-vfp9.d: Likewise.
* gas/arm/attr-mfpu-vfp.d: Likewise.
* gas/arm/attr-mfpu-vfpv2.d: Likewise.
* gas/arm/attr-mfpu-vfpv3-d16.d: Likewise.
* gas/arm/attr-mfpu-vfpv3.d: Likewise.
* gas/arm/attr-mfpu-vfpv4-d16.d: Likewise.
* gas/arm/attr-mfpu-vfpv4.d: Likewise.
* gas/arm/attr-mfpu-vfpxd.d: Likewise.
* gas/arm/attr-names.d: Likewise.
* gas/arm/attr-order.d: Likewise.
* gas/arm/attr-override-cpu-directive.d: Likewise.
* gas/arm/attr-override-mcpu.d: Likewise.
* gas/arm/got_prel.d: Likewise.
* gas/arm/mapdir.d: Likewise.
* gas/arm/mapmisc.d: Likewise.
* gas/arm/mapsecs.d: Likewise.
* gas/arm/mapshort-eabi.d: Likewise.
* gas/arm/mapshort-elf.d: Likewise.
* gas/arm/mov-highregs-any.d: Likewise.
* gas/arm/mov-lowregs-any.d: Likewise.
* gas/arm/pr12198-1.d: Likewise.
* gas/arm/pr12198-2.d: Likewise.
* gas/arm/thumb.d: Likewise.
* gas/arm/thumb-eabi.d: Likewise.
* gas/arm/thumbrel.d: Likewise.

* configure.tgt (arm*-*-nacl*, arm*b-*-nacl*): Handle them.
* emulparams/armelf_nacl.sh: New file.
* emulparams/armelfb_nacl.sh: New file.
* Makefile.am (ALL_EMULATION_SOURCES): Add earmelf_nacl.c
and earmelfb_nacl.c here.
(earmelf_nacl.c, earmelfb_nacl.c): New targets.
* Makefile.in: Regenerated.

* ld-arm/arm-elf.exp (armelftests): Split out into ...
(armelftests_common, armelftests_nonacl): ... these two.
(armeabitests): Split out into ...
(armeabitests_common, armeabitests_nonacl): ... these two.
Omit _nonacl sets for arm*-*-nacl* targets.

* ld-arm/farcall-mix.d: Don't match exact addresses, only symbolic ones.
* ld-arm/farcall-mix2.d: Likewise.
* ld-arm/farcall-group.d: Likewise.

* ld-arm/tls-gdesc-got.d: Match variant file formats too.
Accept some variation in exact addresses.

* ld-arm/thumb2-b-interwork.d: Match variant file formats too.
Fix regexps not to care about exact addresses where not relevant.

* ld-arm/thumb2-bl-undefweak.d: Match any hex strings, not any
strings of particular exact lengths.
* ld-arm/thumb2-bl-undefweak1.d: Likewise.

* ld-arm/arm-app.r: Match variant file formats too.
* ld-arm/arm-app-abs32.r: Likewise.
* ld-arm/arm-lib.d: Likewise.
* ld-arm/arm-lib.r: Likewise.
* ld-arm/arm-static-app.r: Likewise.
* ld-arm/armv4-bx.d: Likewise.
* ld-arm/data-only-map.d: Likewise.
* ld-arm/group-relocs.d: Likewise.
* ld-arm/jump19.d: Likewise.
* ld-arm/reloc-boundaries.d: Likewise.
* ld-arm/thumb1-bl.d: Likewise.
* ld-arm/thumb2-bl.d: Likewise.
* ld-arm/tls-app.d: Likewise.
* ld-arm/tls-app.r: Likewise.
* ld-arm/tls-gdierelax.d: Likewise.
* ld-arm/tls-gdierelax2.d: Likewise.
* ld-arm/tls-gdlerelax.d: Likewise.
* ld-arm/tls-lib.d: Likewise.
* ld-arm/tls-lib.r: Likewise.
* ld-arm/tls-mixed.r: Likewise.
* ld-arm/vfp11-fix-none.d: Likewise.
* ld-arm/vfp11-fix-scalar.d: Likewise.
* ld-arm/vfp11-fix-vector.d: Likewise.
* ld-arm/arm-static-app.d: Likewise.
Fix regexps not to care about exact number of leading spaces.
* ld-arm/arm-app-abs32.d: Likewise.
* ld-arm/fix-arm1176-off.d: Likewise.
* ld-arm/fix-arm1176-on.d: Likewise.

* ld-arm/arm-elf.exp: Treat nacl targets like eabi targets.
154 files changed:
bfd/ChangeLog
bfd/config.bfd
bfd/configure
bfd/configure.in
bfd/elf32-arm.c
bfd/targets.c
gas/ChangeLog
gas/config/tc-arm.c
gas/config/te-nacl.h
gas/configure.tgt
gas/testsuite/ChangeLog
gas/testsuite/gas/arm/any-idiv.d
gas/testsuite/gas/arm/arch4t-eabi.d
gas/testsuite/gas/arm/arch4t.d
gas/testsuite/gas/arm/attr-any-armv4t.d
gas/testsuite/gas/arm/attr-any-thumbv6.d
gas/testsuite/gas/arm/attr-cpu-directive.d
gas/testsuite/gas/arm/attr-default.d
gas/testsuite/gas/arm/attr-march-all.d
gas/testsuite/gas/arm/attr-march-armv1.d
gas/testsuite/gas/arm/attr-march-armv2.d
gas/testsuite/gas/arm/attr-march-armv2a.d
gas/testsuite/gas/arm/attr-march-armv2s.d
gas/testsuite/gas/arm/attr-march-armv3.d
gas/testsuite/gas/arm/attr-march-armv3m.d
gas/testsuite/gas/arm/attr-march-armv4.d
gas/testsuite/gas/arm/attr-march-armv4t.d
gas/testsuite/gas/arm/attr-march-armv4txm.d
gas/testsuite/gas/arm/attr-march-armv4xm.d
gas/testsuite/gas/arm/attr-march-armv5.d
gas/testsuite/gas/arm/attr-march-armv5t.d
gas/testsuite/gas/arm/attr-march-armv5te.d
gas/testsuite/gas/arm/attr-march-armv5tej.d
gas/testsuite/gas/arm/attr-march-armv5texp.d
gas/testsuite/gas/arm/attr-march-armv5txm.d
gas/testsuite/gas/arm/attr-march-armv6-m+os.d
gas/testsuite/gas/arm/attr-march-armv6-m.d
gas/testsuite/gas/arm/attr-march-armv6.d
gas/testsuite/gas/arm/attr-march-armv6j.d
gas/testsuite/gas/arm/attr-march-armv6k+sec.d
gas/testsuite/gas/arm/attr-march-armv6k.d
gas/testsuite/gas/arm/attr-march-armv6kt2.d
gas/testsuite/gas/arm/attr-march-armv6s-m.d
gas/testsuite/gas/arm/attr-march-armv6t2.d
gas/testsuite/gas/arm/attr-march-armv6z.d
gas/testsuite/gas/arm/attr-march-armv6zk.d
gas/testsuite/gas/arm/attr-march-armv6zkt2.d
gas/testsuite/gas/arm/attr-march-armv6zt2.d
gas/testsuite/gas/arm/attr-march-armv7-a+idiv.d
gas/testsuite/gas/arm/attr-march-armv7-a+mp.d
gas/testsuite/gas/arm/attr-march-armv7-a+sec+virt.d
gas/testsuite/gas/arm/attr-march-armv7-a+sec.d
gas/testsuite/gas/arm/attr-march-armv7-a+virt.d
gas/testsuite/gas/arm/attr-march-armv7-a.d
gas/testsuite/gas/arm/attr-march-armv7-m.d
gas/testsuite/gas/arm/attr-march-armv7-r+mp.d
gas/testsuite/gas/arm/attr-march-armv7-r.d
gas/testsuite/gas/arm/attr-march-armv7.d
gas/testsuite/gas/arm/attr-march-armv7a.d
gas/testsuite/gas/arm/attr-march-armv7em.d
gas/testsuite/gas/arm/attr-march-armv7m.d
gas/testsuite/gas/arm/attr-march-armv7r.d
gas/testsuite/gas/arm/attr-march-iwmmxt.d
gas/testsuite/gas/arm/attr-march-iwmmxt2.d
gas/testsuite/gas/arm/attr-march-xscale.d
gas/testsuite/gas/arm/attr-mcpu.d
gas/testsuite/gas/arm/attr-mfpu-arm1020e.d
gas/testsuite/gas/arm/attr-mfpu-arm1020t.d
gas/testsuite/gas/arm/attr-mfpu-arm1136jf-s.d
gas/testsuite/gas/arm/attr-mfpu-arm1136jfs.d
gas/testsuite/gas/arm/attr-mfpu-arm7500fe.d
gas/testsuite/gas/arm/attr-mfpu-fpa.d
gas/testsuite/gas/arm/attr-mfpu-fpa10.d
gas/testsuite/gas/arm/attr-mfpu-fpa11.d
gas/testsuite/gas/arm/attr-mfpu-fpe.d
gas/testsuite/gas/arm/attr-mfpu-fpe2.d
gas/testsuite/gas/arm/attr-mfpu-fpe3.d
gas/testsuite/gas/arm/attr-mfpu-maverick.d
gas/testsuite/gas/arm/attr-mfpu-neon-fp16.d
gas/testsuite/gas/arm/attr-mfpu-neon.d
gas/testsuite/gas/arm/attr-mfpu-softfpa.d
gas/testsuite/gas/arm/attr-mfpu-softvfp+vfp.d
gas/testsuite/gas/arm/attr-mfpu-softvfp.d
gas/testsuite/gas/arm/attr-mfpu-vfp.d
gas/testsuite/gas/arm/attr-mfpu-vfp10-r0.d
gas/testsuite/gas/arm/attr-mfpu-vfp10.d
gas/testsuite/gas/arm/attr-mfpu-vfp3.d
gas/testsuite/gas/arm/attr-mfpu-vfp9.d
gas/testsuite/gas/arm/attr-mfpu-vfpv2.d
gas/testsuite/gas/arm/attr-mfpu-vfpv3-d16.d
gas/testsuite/gas/arm/attr-mfpu-vfpv3.d
gas/testsuite/gas/arm/attr-mfpu-vfpv4-d16.d
gas/testsuite/gas/arm/attr-mfpu-vfpv4.d
gas/testsuite/gas/arm/attr-mfpu-vfpxd.d
gas/testsuite/gas/arm/attr-names.d
gas/testsuite/gas/arm/attr-order.d
gas/testsuite/gas/arm/attr-override-cpu-directive.d
gas/testsuite/gas/arm/attr-override-mcpu.d
gas/testsuite/gas/arm/got_prel.d
gas/testsuite/gas/arm/mapdir.d
gas/testsuite/gas/arm/mapmisc.d
gas/testsuite/gas/arm/mapsecs.d
gas/testsuite/gas/arm/mapshort-eabi.d
gas/testsuite/gas/arm/mapshort-elf.d
gas/testsuite/gas/arm/mov-highregs-any.d
gas/testsuite/gas/arm/mov-lowregs-any.d
gas/testsuite/gas/arm/pr12198-1.d
gas/testsuite/gas/arm/pr12198-2.d
gas/testsuite/gas/arm/thumb-eabi.d
gas/testsuite/gas/arm/thumb.d
gas/testsuite/gas/arm/thumbrel.d
gas/testsuite/gas/elf/elf.exp
ld/ChangeLog
ld/Makefile.am
ld/Makefile.in
ld/configure.tgt
ld/emulparams/armelf_nacl.sh [new file with mode: 0644]
ld/emulparams/armelfb_nacl.sh [new file with mode: 0644]
ld/testsuite/ChangeLog
ld/testsuite/ld-arm/arm-app-abs32.d
ld/testsuite/ld-arm/arm-app-abs32.r
ld/testsuite/ld-arm/arm-app.r
ld/testsuite/ld-arm/arm-elf.exp
ld/testsuite/ld-arm/arm-lib.d
ld/testsuite/ld-arm/arm-lib.r
ld/testsuite/ld-arm/arm-static-app.d
ld/testsuite/ld-arm/arm-static-app.r
ld/testsuite/ld-arm/armv4-bx.d
ld/testsuite/ld-arm/data-only-map.d
ld/testsuite/ld-arm/farcall-group.d
ld/testsuite/ld-arm/farcall-mix.d
ld/testsuite/ld-arm/farcall-mix2.d
ld/testsuite/ld-arm/fix-arm1176-off.d
ld/testsuite/ld-arm/fix-arm1176-on.d
ld/testsuite/ld-arm/group-relocs.d
ld/testsuite/ld-arm/jump19.d
ld/testsuite/ld-arm/reloc-boundaries.d
ld/testsuite/ld-arm/thumb1-bl.d
ld/testsuite/ld-arm/thumb2-b-interwork.d
ld/testsuite/ld-arm/thumb2-bl-undefweak.d
ld/testsuite/ld-arm/thumb2-bl-undefweak1.d
ld/testsuite/ld-arm/thumb2-bl.d
ld/testsuite/ld-arm/tls-app.d
ld/testsuite/ld-arm/tls-app.r
ld/testsuite/ld-arm/tls-gdesc-got.d
ld/testsuite/ld-arm/tls-gdierelax.d
ld/testsuite/ld-arm/tls-gdierelax2.d
ld/testsuite/ld-arm/tls-gdlerelax.d
ld/testsuite/ld-arm/tls-lib.d
ld/testsuite/ld-arm/tls-lib.r
ld/testsuite/ld-arm/tls-mixed.r
ld/testsuite/ld-arm/vfp11-fix-none.d
ld/testsuite/ld-arm/vfp11-fix-scalar.d
ld/testsuite/ld-arm/vfp11-fix-vector.d