This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [AArch64][4/4] Define TC_ADDRESS_BYTES for GAS
- From: Andreas Schwab <schwab at suse dot de>
- To: Yury Norov <ynorov at caviumnetworks dot com>
- Cc: Jiong Wang <jiong dot wang at foss dot arm dot com>, Binutils <binutils at sourceware dot org>, Steve Ellcey <Steve dot Ellcey at cavium dot com>
- Date: Wed, 07 Dec 2016 17:17:21 +0100
- Subject: Re: [AArch64][4/4] Define TC_ADDRESS_BYTES for GAS
- Authentication-results: sourceware.org; auth=none
- References: <2217462f-42bd-83e0-6141-acd62e8becb8@foss.arm.com> <4a2dc012-d289-319a-3557-14266fe3510b@foss.arm.com> <2eaf8fdb-6e7d-1f9b-8ef3-fe0c1d5577c9@foss.arm.com> <06d11737-ef5a-05e7-24d1-8541bfc94e09@foss.arm.com> <mvmh96hjpqm.fsf@hawking.suse.de> <f99784e6-d576-a530-556d-663a5497ab43@foss.arm.com> <20161206142658.GA27706@yury-N73SV> <20161207161044.GA16699@yury-N73SV>
On Dez 07 2016, Yury Norov <ynorov@caviumnetworks.com> wrote:
>> This is my version of the change. The same idea, but I also set
>> bits_per_word to 32:
>>
>> diff --git a/bfd/cpu-aarch64.c b/bfd/cpu-aarch64.c
>> index 596d241..cc98e2e 100644
>> --- a/bfd/cpu-aarch64.c
>> +++ b/bfd/cpu-aarch64.c
>> @@ -105,8 +105,13 @@ scan (const struct bfd_arch_info *info, const char *string)
>> "aarch64", PRINT, 4, DEFAULT, compatible, scan, \
>> bfd_arch_default_fill, NEXT }
>>
>> +#define N32(NUMBER, PRINT, DEFAULT, NEXT) \
>> + { 32, 32, 8, bfd_arch_aarch64, NUMBER, \
>> + "aarch64", PRINT, 4, DEFAULT, compatible, scan, \
>> + bfd_arch_default_fill, NEXT }
>> +
>> static const bfd_arch_info_type bfd_aarch64_arch_ilp32 =
>> - N (bfd_mach_aarch64_ilp32, "aarch64:ilp32", FALSE, NULL);
>> + N32 (bfd_mach_aarch64_ilp32, "aarch64:ilp32", FALSE, NULL);
It doesn't make much sense to define another macro and use it only once.
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."