public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Hongtao Liu <crazylht@gmail.com>
To: "H.J. Lu" <hjl.tools@gmail.com>
Cc: Florian Weimer <fweimer@redhat.com>,
	liuhongt via Libc-alpha <libc-alpha@sourceware.org>,
	 x86-64-abi <x86-64-abi@googlegroups.com>,
	liuhongt <hongtao.liu@intel.com>,
	 LLVM Dev <llvm-dev@lists.llvm.org>,
	GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Add optional __Bfloat16 support
Date: Mon, 13 Jun 2022 14:29:10 +0800	[thread overview]
Message-ID: <CAMZc-bxN+jXV=aXvafSfKyb=TMEQEg6aQiPnTvbVe=Jyw9QhyA@mail.gmail.com> (raw)
In-Reply-To: <CAMe9rOrvrZRbksjQ+Y8caC=Yo==oFY5+muOGf9UZRh6L7pUQjw@mail.gmail.com>

On Sat, Jun 11, 2022 at 1:46 AM H.J. Lu <hjl.tools@gmail.com> wrote:
>
> On Fri, Jun 10, 2022 at 7:44 AM H.J. Lu <hjl.tools@gmail.com> wrote:
> >
> > On Fri, Jun 10, 2022 at 2:38 AM Florian Weimer <fweimer@redhat.com> wrote:
> > >
> > > * liuhongt via Libc-alpha:
> > >
> > > > +\subsubsection{Special Types}
> > > > +
> > > > +The \code{__Bfloat16} type uses a 8-bit exponent and 7-bit mantissa.
> > > > +It is used for \code{BF16} related intrinsics, it cannot be
> >
> > Please mention that this is an alternate encoding format for 16-bit floating
> > point.  It has the same size and alignment as _Float16.
>
> It also follows the same rules as _Float16 for parameter passing and function
> return.

How about
+\subsubsection{Special Types}
+
+The \code{__Bfloat16} type has an alternate encoding format for 16-bit
+floating point with 8-bit exponent and 7-bit mantissa. It has the same size,
+alignment, parameter passing and return rules as _Float16.
+It is used for \code{BF16} related intrinsics, it cannot be used with standard
+C operators.
+
>
> > > > +used with standard C operators.
> > >
> > > I think it's not necessary to specify whether the type supports certain
> > > C operators (surely assignment will work?).  If they are added later,
> > > the ABI won't need changing.
> > >
> >
> > If _Bfloat16 becomes a fundamental type, the ABI should be changed to
> > move it together with other scalar types.
> >
> > --
> > H.J.
>
>
>
> --
> H.J.
>
> --
> You received this message because you are subscribed to the Google Groups "X86-64 System V Application Binary Interface" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to x86-64-abi+unsubscribe@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/x86-64-abi/CAMe9rOrvrZRbksjQ%2BY8caC%3DYo%3D%3DoFY5%2BmuOGf9UZRh6L7pUQjw%40mail.gmail.com.



-- 
BR,
Hongtao

      reply	other threads:[~2022-06-13  6:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-10  7:47 liuhongt
2022-06-10  7:50 ` Hongtao Liu
2022-06-10  9:38 ` Florian Weimer
2022-06-10 14:44   ` H.J. Lu
2022-06-10 17:45     ` H.J. Lu
2022-06-13  6:29       ` Hongtao Liu [this message]

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='CAMZc-bxN+jXV=aXvafSfKyb=TMEQEg6aQiPnTvbVe=Jyw9QhyA@mail.gmail.com' \
    --to=crazylht@gmail.com \
    --cc=fweimer@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=hjl.tools@gmail.com \
    --cc=hongtao.liu@intel.com \
    --cc=libc-alpha@sourceware.org \
    --cc=llvm-dev@lists.llvm.org \
    --cc=x86-64-abi@googlegroups.com \
    /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).