public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Toon Moene <toon@moene.org>
To: gcc@gcc.gnu.org
Subject: Re: Complex numbers support: discussions summary
Date: Tue, 26 Sep 2023 20:40:20 +0200	[thread overview]
Message-ID: <87d8389c-3ff5-45ed-bc5e-19463564d703@moene.org> (raw)
In-Reply-To: <CAFiYyc1WeP-0SCQgNv3rO0+cPSrW7ne9M8iJqd_=wEqO+0-Qdw@mail.gmail.com>

On 9/26/23 09:30, Richard Biener via Gcc wrote:

> On Mon, Sep 25, 2023 at 5:17 PM Sylvain Noiry via Gcc <gcc@gcc.gnu.org> wrote:

>> As I said at the end of the presentation, we have written a paper which
>> explains
>> our implementation in details. You can find it on the wiki page of the
>> Cauldron
>> (https://gcc.gnu.org/wiki/cauldron2023talks?action=AttachFile&do=view&target=Exposing+Complex+Numbers+to+Target+Back-ends+%28paper%29.pdf).
> 
> Thanks for the detailed presentation at the Cauldron.
> 
> My personal summary is that I'm less convinced delaying lowering is
> the way to go.

Thanks Sylvain for the quick summary of the discussion - it helps a 
great deal now that the discussion is still fresh in our memory.

Some thought I came up with (of course, only after the end of the 
conference):

In what way is the handling of the complex type different from that of 
the 128 bit real (i.e., float) type ?

Both are not implemented on most architectures; on most they require two 
registers (or possibly two memory location that do not necessarily have 
to be adjacent) to be implemented.

Yet both are supported by the middle end - consider the clear 
equivalence of the handling of variables a and b when looking at the 
result of -fdump-tree-ssa (on x86_64) for:

cat 128.f90
parameter (iq=kind(1q0))
real(kind=iq) :: a, b
read*, a, b
print*, a / b
end

and:

cat complex.f90
complex a,b
read*,a,b
print*,a/b
end

Hope this helps for a continuing fruitful discussion.

Kind regards,

-- 
Toon Moene - e-mail: toon@moene.org - phone: +31 346 214290
Saturnushof 14, 3738 XG  Maartensdijk, The Netherlands


  parent reply	other threads:[~2023-09-26 18:40 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-25 15:15 Sylvain Noiry
2023-09-26  7:30 ` Richard Biener
2023-09-26  8:29   ` Tamar Christina
2023-09-26 10:19     ` Paul Iannetta
2023-09-26  8:53   ` Paul Iannetta
2023-09-26  9:28     ` Tamar Christina
2023-09-26  9:40       ` Paul Iannetta
2023-09-26 18:40   ` Toon Moene [this message]
2023-10-05 14:45     ` Toon Moene
2023-09-26 15:46 ` Joseph Myers
  -- strict thread matches above, loose matches on Subject: below --
2023-10-16  9:14 Sylvain Noiry
2023-10-17 20:37 ` Toon Moene
2023-10-18  7:24   ` Sylvain Noiry
2023-10-09 13:29 Sylvain Noiry
2023-09-25 14:56 Sylvain Noiry

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=87d8389c-3ff5-45ed-bc5e-19463564d703@moene.org \
    --to=toon@moene.org \
    --cc=gcc@gcc.gnu.org \
    /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).