This is the mail archive of the binutils@sources.redhat.com 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: Fix some of the ARM GAS failures


On Tue, 2005-05-24 at 21:17, Zack Weinberg wrote:
> This patch should improve the ARM-GAS situation somewhat.  md_apply_fix3
> needs to truncate the relocation to 32 signed bits manually; if the host
> is 64-bit, fx_addnumber and fx_offset are 64-bit, and may generate
> spurious overflows.  Also, we need a double cast on both sides of the
> hack to pass an integer around in tc_fix_data.
> 

AFAICT tc_fix_data is a private type to the ARM-specific parts of the
assembler.  Since storing the thumbness is the only use, and the type of
tc_fix_data is defined in tc-arm.h (TC_FIX_TYPE), it would make much
more sense to just change TC_FIX_TYPE to 'int' and get rid of all those
nasty casts.

Otherwise OK.

R.
> zw
> 	* config/tc-arm.c (fix_new_arm): Cast thumb_mode to size_t
> 	before casting it to PTR.
> 	(md_apply_fix3): Truncate value, *valP, fixP->fx_addnumber,
> 	and fixP->fx_offset to 32 signed bits.


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