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: MIPS patch to correct the size of %neg() fixups


Richard Sandiford wrote:
> Thiemo Seufer <ica2_ts@csv.ica.uni-stuttgart.de> writes:
> > Another thing: At least the FIXME about RSS_* values should be retained,
> 
> Well, the fixme says:
> 
> 		  /* FIXME: This symbol can be one of
> 		     RSS_UNDEF, RSS_GP, RSS_GP0, RSS_LOC.  */
> 
> but why is that relevant in this context (append_insn)?

Because this is the place to add the proper RSS_* symbol if there
will ever be a relocation triple with a non-null symbol for the
second reloc.

> macro_build() only adds one fixup at a time.  If a macro like
> .cpsetup needs to create a compound relocation, it adds the other
> fixups separately using fix_new().

Sure, but there is no macro I know of which would need something
different than RSS_UNDEF.

> So I think the code we're talking about is only needed for processing
> explicit relocation operators (%hi, etc).  And as far as I'm aware,
> the syntax doesn't allow r_ssym to be anything other than RSS_UNDEF.

AFAICS this has to depend on the reloc type (e.g. for gprel/pcrel
relocs), otherwise the RSS_* defines would be completely useless.

> I didn't really see what kind of change the FIXME was anticipating.
> 
> > so I prefer a patch like the one below.
> 
> Butbutbut... why you do want to keep the reloc_type[2] code cut-&-paste
> from the reloc_type[1] code? ;) I thought using a loop was an
> improvement. ;)

I assume RSS_GP, RSS_GP0 and RSS_LOC are defined for a reason, and
and these apply only to the second relocation in the triple.


Thiemo


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