public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/107097] Implement floating point excess precision in C++
Date: Tue, 04 Oct 2022 17:30:57 +0000	[thread overview]
Message-ID: <bug-107097-4-HkhBiFrEsS@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-107097-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107097

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
The code is different though.  C has that
    case EQ_EXPR:
    case NE_EXPR:
    case LE_EXPR:
    case GE_EXPR:
    case LT_EXPR:
    case GT_EXPR:
      /* Excess precision for implicit conversions of integers to
         floating point in C11 and later.  */
      may_need_excess_precision = (flag_isoc11
                                   && (ANY_INTEGRAL_TYPE_P (type0)
                                       || ANY_INTEGRAL_TYPE_P (type1)));
      break;
part in which is from PR82071 and I can't find in the C++ standard a similar
change to what has changed from C99 to C11.
If you mean to share just
    case PLUS_EXPR:
    case MINUS_EXPR:
    case MULT_EXPR:
    case TRUNC_DIV_EXPR:
    case CEIL_DIV_EXPR:
    case FLOOR_DIV_EXPR:
    case ROUND_DIV_EXPR:
    case EXACT_DIV_EXPR:
then that sounds something not worth sharing to me.

  parent reply	other threads:[~2022-10-04 17:30 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-30 13:32 [Bug c++/107097] New: " jason at gcc dot gnu.org
2022-09-30 13:33 ` [Bug c++/107097] " jason at gcc dot gnu.org
2022-10-04 17:20 ` jakub at gcc dot gnu.org
2022-10-04 17:27 ` mpolacek at gcc dot gnu.org
2022-10-04 17:30 ` jakub at gcc dot gnu.org [this message]
2022-10-05 16:33 ` jakub at gcc dot gnu.org
2022-10-05 16:47 ` jakub at gcc dot gnu.org
2022-10-05 17:29 ` jakub at gcc dot gnu.org
2022-10-14  7:32 ` cvs-commit at gcc dot gnu.org
2022-10-14  7:34 ` cvs-commit at gcc dot gnu.org
2022-10-14  7:38 ` jakub at gcc dot gnu.org

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=bug-107097-4-HkhBiFrEsS@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@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).