public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Thiemo Seufer <ths@networkno.de>
To: Paul Koning <pkoning@equallogic.com>,
	joseph@codesourcery.com, 	binutils@sourceware.org,
	rsandifo@nildram.co.uk
Subject: Re: [PATCH] MIPS: Add a GNU attribute for -mips32 -mfp64 objects
Date: Thu, 15 Nov 2007 23:12:00 -0000	[thread overview]
Message-ID: <20071115231202.GW8363@networkno.de> (raw)
In-Reply-To: <87fxz7kzl7.fsf@firetop.home>

Richard Sandiford wrote:
> Paul Koning <pkoning@equallogic.com> writes:
> >>>>>> "Richard" == Richard Sandiford <rsandifo@nildram.co.uk> writes:
> >
> >  Richard> I agree with Joseph here.  Although it's redundant to
> >  Richard> specify -mfp64 with -msoft-float, it isn't actively wrong.
> >  Richard> The options have traditionally been orthogonal.  I don't
> >  Richard> think the assembler should assume that -mfp64 implies
> >  Richard> -mhard-float.
> >
> > It seems strange, since -msoft-float means no float registers, while
> > -mfp64 says there are float registers and they are 64 bits wide.
> 
> Well, -mhard-float and -msoft-float are ABI options.  -mfp64 is
> an architectural configuration option, and only affects calling
> conventions when combined with -mhard-float.

But "-mhard-float -mfp64" constitutes a new ABI variant. This is
the case I want to cover. The "-msoft-float -mfp64" should stay
tagged as soft float object.

> It is perfectly
> possible to write code that conforms to the soft-float ABI while
> still using FPU instructions within a function.

I wonder how relevant this possibility is in practice. To me it
sounds too subtle to be of much use.

> (Strictly speaking,
> the use of FPU instructions is also part of the ABI.  But it isn't
> what this attribute specifies; this attribute is about the calling
> conventions.)
> The practical example of the difference is MIPS16.  -mhard-float
> -mips16 doesn't say "use the FPU from MIPS16 code"; you can't.
> It says instead that the hard-float ABI is in effect, and that
> we need to use special stubs to interface with non-MIPS16 code.

And, for completeness, we have "-mips32r2 -mips16 -mhard-float -mfp64",
which tells the compiler to generate different stubs than the ones
needed for the standard hard float.


Thiemo

  reply	other threads:[~2007-11-15 23:12 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-14 20:24 Thiemo Seufer
2007-11-15  0:03 ` Joseph S. Myers
2007-11-15  0:45   ` Thiemo Seufer
2007-11-15  0:55     ` Joseph S. Myers
2007-11-15 20:25     ` Richard Sandiford
2007-11-15 20:32       ` Paul Koning
2007-11-15 20:45         ` Richard Sandiford
2007-11-15 23:12           ` Thiemo Seufer [this message]
2007-11-16  9:31             ` Richard Sandiford
2007-11-15  0:04 ` Joseph S. Myers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071115231202.GW8363@networkno.de \
    --to=ths@networkno.de \
    --cc=binutils@sourceware.org \
    --cc=joseph@codesourcery.com \
    --cc=pkoning@equallogic.com \
    --cc=rsandifo@nildram.co.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).