public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Shiqi Zhang <shiqi@isrc.iscas.ac.cn>
To: Andreas Schwab <schwab@linux-m68k.org>
Cc: Richard Henderson <richard.henderson@linaro.org>,
	libc-alpha@sourceware.org
Subject: Re: [PATCH v2] riscv: Add macros for FPUCW/fcsr in fpu_control.h
Date: Mon, 13 Feb 2023 18:17:14 +0800	[thread overview]
Message-ID: <101fcfa2-0ddf-99a5-1f2e-1a3b7fe0d73c@isrc.iscas.ac.cn> (raw)
In-Reply-To: <mvm4jrqufge.fsf@linux-m68k.org>

The fenv macro FE_TONEARESTFROMZERO doesn't exist yet and seems to
belong to a newer version of C standard draft. Maybe I should implement
that along with the macros in fpu_control.h?

I'm defining these macros here primarily because in most cases glibc is
the lowest layer of user programs. So I think it's the best place to
define these macros for directly interacting with arch-specific things
like FPU control, like other architectures have done.

At 2023/2/13 16:39, Andreas Schwab wrote:
> On Feb 13 2023, Shiqi Zhang wrote:
>
>> The rounding mode RMM (Round to Nearest, ties to Max Magnitude) of
>> RISC-V isn't part of the C standard.
> Doesn't that match FE_TONEARESTFROMZERO?  In any case, an implementation
> may add additional FE_ macros.
>


  reply	other threads:[~2023-02-13 10:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-12  6:52 Shiqi Zhang
2023-02-12 19:36 ` Richard Henderson
2023-02-13  6:16   ` Shiqi Zhang
2023-02-13  8:39     ` Andreas Schwab
2023-02-13 10:17       ` Shiqi Zhang [this message]
2023-02-13 22:00         ` Joseph Myers
2023-02-13 18:17     ` Richard Henderson
2023-02-13 19:31       ` Shiqi Zhang

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=101fcfa2-0ddf-99a5-1f2e-1a3b7fe0d73c@isrc.iscas.ac.cn \
    --to=shiqi@isrc.iscas.ac.cn \
    --cc=libc-alpha@sourceware.org \
    --cc=richard.henderson@linaro.org \
    --cc=schwab@linux-m68k.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).