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: pc-relative relocs on alpha


On Thu, Sep 19, 2002 at 11:48:06PM +0930, Alan Modra wrote:
> 	* write.h (struct fix): Add fx_dot_value.
> 	(dot_value): Declare.
> 	* write.c (dot_value): New var.
> 	(fix_new_internal): Save dot_value as fx_dot_value.
> 	* expr.c (expr): Update dot_value.
> 
> I'll apply this in the morning if everything pans out OK.

No new regressions.  My subconscious must have been working on it
overnight though, because I knew I'd forgotten something when I woke
up.

>  	      add_number -= S_GET_VALUE (fixP->fx_subsy);
> -	      fixP->fx_offset = add_number;
> +	      fixP->fx_offset = add_number + fixP->fx_dot_value;

Needs to be
	      fixP->fx_offset = (add_number + fixP->fx_dot_value
				 + fixP->fx_frag->fr_address);

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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