This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: a couple of gas MIPS ABI issues.
ica2_ts@csv.ica.uni-stuttgart.de ("Thiemo Seufer") writes:
> > * I'm concerned that ".set mipsN" changes the ABI at all. i
> > mean, the sizes of addresse in your GOT, etc., aren't going
> > to change for the binary as a whole just because you said
> > ".set mipsN" right?
>
> Please understand that .set mipsX is for experienced programmers
> only. It makes no guarantees about the validity of the resulting
> code. It can't be replaced by a differently compiled file because
> the linker might complain about it.
So, I guess the point is, these do this so that HAVE_..BIT_.PRS will
evaluate to the "right" thing despite the prevailing file ABI?
> > What's the _benefit_ of setting mips_abi = NO_ABI in the
> > mips3-mips5,mips64 case?
>
> It allows assembly beyond the ABI's restrictions.
... because HAVE_??BIT_?PRS checks the ABI, i suppose.
> > (It also looks to me like the setting of mips_fp32 and mips_gp32 in
> > the .set mipsN code is entirely reduntant. The code that checks those
> > flags also checks the ISA reg size, since since .set mipsN also sets
> > the ISA...
>
> Why should it be redundant? .set mips3 should allow access to
> 64bit registers, even if the assembler was invoked with -mgp32.
Not should be; is.
Every place you check mips_fp32 and mips_gp32, you also check the ISA.
AFAICT, there's no reason you need to set _both_ in the code which
implements ".set mipsN", since only setting the ISA does have the
correct effect, does it not?
cgd