This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2] BFD vector for elf32-i386-nacl


On Thu, Jul 28, 2011 at 1:08 PM, Roland McGrath <mcgrathr@google.com> wrote:
> [Reworked on top of cleanups and parameterization already committed.]
>
> This patch adds the BFD target vector for the new target elf32-i386-nacl.
> This is to support Native Client (http://code.google.com/p/nativeclient/),
> which is a new pseudo-operating system that uses vanilla ELF but has a
> significantly nonstandard ABI. ?(It is already known to config.sub as 'nacl'.)
>
> This is far from being complete support for this target, but it should
> be everything that will be needed in BFD proper. ?It's gotten only the
> lightest testing, and of course the target-specific details are subject
> to potential fixes or changes later.
>
> I have tested that the i686-linux target still passes check-binutils and
> check-ld. ?I'm not sure that tests much about correct PLT generation,
> which is the only area of the shared code really touched here. ?If there
> are other good ways to test that (short of rebuilding a whole OS with
> this linker), please let me know.
>
> Ok for trunk?
>
>
> Thanks,
> Roland
>
>
> bfd/
> ? ? ? ?* elf32-i386.c (NACL_PLT_ENTRY_SIZE, NACLMASK): New macros.
> ? ? ? ?(elf_i386_nacl_plt0_entry): New variable.
> ? ? ? ?(elf_i386_plt_entry): New variable.
> ? ? ? ?(elf_i386_nacl_pic_plt0_entry): New variable.
> ? ? ? ?(elf_i386_nacl_pic_plt_entry): New variable.
> ? ? ? ?(elf_i386_nacl_plt, elf_i386_nacl_arch_bed): New variables.
> ? ? ? ?(elf_backend_arch_data): New macro setting for elf_i386_nacl_vec stanza.
> ? ? ? ?(elf_backend_plt_alignment): Likewise.
>
> ? ? ? ?* config.bfd: Handle i[3-7]86-*-nacl*.
> ? ? ? ?* elf32-i386.c (bfd_elf32_i386_nacl_vec): New backend vector stanza.
> ? ? ? ?* targets.c: Support bfd_elf32_i386_nacl_vec.
> ? ? ? ?* configure.in: Likewise.
> ? ? ? ?* configure: Regenerated.
>
> diff --git a/bfd/config.bfd b/bfd/config.bfd
> index 3f5b9a1..4cb689d 100644
> --- a/bfd/config.bfd
> +++ b/bfd/config.bfd
> @@ -566,6 +566,11 @@ case "${targ}" in
> ? ? targ_selvecs="i386linux_vec i386pei_vec"
> ? ? targ64_selvecs="bfd_elf64_x86_64_vec bfd_elf32_x86_64_vec bfd_elf64_l1om_vec bfd_elf64_k1om_vec"
> ? ? ;;
> + ?i[3-7]86-*-nacl*)
> + ? ?targ_defvec=bfd_elf32_i386_nacl_vec
> + ? ?targ_selvecs="bfd_elf32_i386_vec"
> + ? ?#XXX targ64_selvecs="bfd_elf64_x86_64_nacl_vec bfd_elf32_x86_64_nacl_vec bfd_elf64_x86_64_vec bfd_elf32_x86_64_vec"

Please remove #XXX targ64_selvecs.  You can add it when 64bit is ready.
OK with this change.

Thanks.

-- 
H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]