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] gold: Add boiler-plate code for ARM target.


2009/5/28 Ian Lance Taylor <iant@google.com>:
> "Doug Kwan (Ãö®¶¼w)" <dougkwan@google.com> writes:
>
>> 009-05-28  Doug Kwan  <dougkwan@google.com>
>>
>> ChangeLog
>>         * configure.ac: Support gold for target arm*-*-eabi.
>>         * configure: Regenerate.
>>
>> gold/ChangeLog
>>         * Makefile.am (TARGETSOURCES): Add arm.cc.
>>         (ALL_TARGETOBJECTS): Add arm.$(OBJEXT)
>>         * Makefile.in: Regenerate.
>>         * arm.cc: New file.
>>         * configure.tgt: Add arm*-*-eabi target.
>
> That should be 2009 in the first line of the ChangeLog entry.

Yes, that was a copy-and-paste error of mine.

>
>>      case "${target}" in
>> -      i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-*)
>> +      i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-eabi)
>>          configdirs="`echo " ${configdirs} " | sed -e 's/ ld / gold /'`"
>
> You should match "arm*-*-*" here, as the other processors do.  Otherwise
> you won't match arm-linux-gnu, or arm-ecos-elf, etc.  I know that you
> don't support all the ARM bits yet, but that's OK.

Yes, that was the reason.  Will change as suggested.

>> +  // Return whether SYM is defined by the ABI.
>> +  bool
>> +  do_is_defined_by_abi(Symbol* sym) const
>> +  { return strcmp(sym->name(), "___tls_get_addr") == 0; }
>
> I think that should be __tls_get_addr (two underscores, not three).  The
> x86 does use ___tls_get_addr for weird compatibility reasons, but I
> think the ARM always uses __tls_get_addr.
>
>> Index: gold/configure.tgt
>> ===================================================================
>> RCS file: /cvs/src/src/gold/configure.tgt,v
>> retrieving revision 1.6
>> diff -u -u -p -r1.6 configure.tgt
>> --- gold/configure.tgt        24 Mar 2009 00:31:28 -0000      1.6
>> +++ gold/configure.tgt        28 May 2009 21:43:39 -0000
>> @@ -104,6 +104,13 @@ powerpc64-*)
>>    targ_big_endian=true
>>    targ_extra_big_endian=false
>>    ;;
>> +arm*-*-eabi)
>> + targ_obj=arm
>> + targ_machine=EM_ARM
>> + targ_size=32
>> + targ_big_endian=false
>> + targ_extra_big_endian=true
>> + ;;

> Just match arm* here too.  Also match armel*.  Also add a separate case
> for armeb* which sets targ_big_endian to true.

That's a good sugestion. Will change as suggested.

Thanks for reviewing.  Still more patches to come :-)

-Doug


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