public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/101237] New: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t)
@ 2021-06-28  9:52 pinskia at gcc dot gnu.org
  2021-06-28  9:57 ` [Bug middle-end/101237] " pinskia at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-06-28  9:52 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 101237
           Summary: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved
                    to just HONOR_SIGNED_ZEROS (t)
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: pinskia at gcc dot gnu.org
  Target Milestone: ---

This was found really because I copied the code from fold-const.c to match.pd
and there was a requested change as HONOR_SIGNED_ZEROS now handles tree types
too.
See https://gcc.gnu.org/pipermail/gcc-patches/2021-June/573811.html

from a quick grep I find:
fold-const.c:     || HONOR_SIGNED_ZEROS (element_mode (type))
fold-const.c:        && !HONOR_SIGNED_ZEROS (element_mode (type))
fold-const.c:     && !HONOR_SIGNED_ZEROS (element_mode (type)))
fold-const.c:     && !HONOR_SIGNED_ZEROS (element_mode (type)))
fold-const.c:  if (!HONOR_SIGNED_ZEROS (element_mode (type))
fold-const.c:  if (!HONOR_SIGNED_ZEROS (element_mode (type))
fold-const.c:  if (!HONOR_SIGNED_ZEROS (element_mode (type))
fold-const.c:              && !HONOR_SIGNED_ZEROS (element_mode (arg0))
fold-const.c:     && !HONOR_SIGNED_ZEROS (element_mode (arg0))
fold-const.c:              && !HONOR_SIGNED_ZEROS (element_mode (arg0))
fold-const.c:     && !HONOR_SIGNED_ZEROS (element_mode (op1)))
fold-const.c:     && !HONOR_SIGNED_ZEROS (element_mode (op2)))
fold-const.c:      if (!HONOR_SIGNED_ZEROS (element_mode (type)))

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/101237] HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t)
  2021-06-28  9:52 [Bug middle-end/101237] New: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t) pinskia at gcc dot gnu.org
@ 2021-06-28  9:57 ` pinskia at gcc dot gnu.org
  2021-07-05 20:41 ` cvs-commit at gcc dot gnu.org
  2021-07-05 20:42 ` pinskia at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-06-28  9:57 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|unassigned at gcc dot gnu.org      |pinskia at gcc dot gnu.org
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2021-06-28

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Looks like when HONOR_SIGNED_ZEROS of tree was added in r5-5768, a grep was
done on HONOR_SIGNED_ZEROS but for TYPE_MODE and had missed the grep on
element_mode .

Mine.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/101237] HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t)
  2021-06-28  9:52 [Bug middle-end/101237] New: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t) pinskia at gcc dot gnu.org
  2021-06-28  9:57 ` [Bug middle-end/101237] " pinskia at gcc dot gnu.org
@ 2021-07-05 20:41 ` cvs-commit at gcc dot gnu.org
  2021-07-05 20:42 ` pinskia at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-07-05 20:41 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Andrew Pinski <pinskia@gcc.gnu.org>:

https://gcc.gnu.org/g:3c44b412fec8d5ab7fc064065414314a8ae05c87

commit r12-2038-g3c44b412fec8d5ab7fc064065414314a8ae05c87
Author: Andrew Pinski <apinski@marvell.com>
Date:   Mon Jun 28 20:48:44 2021 -0700

    Fix PR 101237: Remove element_type call when used with the functions from
real

    HONOR_SIGNED_ZEROS, HONOR_SIGN_DEPENDENT_ROUNDING, and HONOR_SNANS all
    have an overload for taking a tree type now, so we should do that instead.

    OK?  Bootstrapped and tested on x86_64-linux-gnu.

    gcc/ChangeLog:

            PR middle-end/101237
            * fold-const.c (negate_expr_p): Remove call to element_mode
            and TREE_MODE/TREE_TYPE when calling HONOR_SIGNED_ZEROS,
            HONOR_SIGN_DEPENDENT_ROUNDING, and HONOR_SNANS.
            (fold_negate_expr_1): Likewise.
            (const_unop): Likewise.
            (fold_cond_expr_with_comparison): Likewise.
            (fold_binary_loc): Likewise.
            (fold_ternary_loc): Likewise.
            (tree_call_nonnegative_warnv_p): Likewise.
            * match.pd (-(A + B) -> (-B) - A): Likewise.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/101237] HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t)
  2021-06-28  9:52 [Bug middle-end/101237] New: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t) pinskia at gcc dot gnu.org
  2021-06-28  9:57 ` [Bug middle-end/101237] " pinskia at gcc dot gnu.org
  2021-07-05 20:41 ` cvs-commit at gcc dot gnu.org
@ 2021-07-05 20:42 ` pinskia at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-07-05 20:42 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED
   Target Milestone|---                         |12.0

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Fixed.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-07-05 20:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-28  9:52 [Bug middle-end/101237] New: HONOR_SIGNED_ZEROS (element_mode (t)) should be moved to just HONOR_SIGNED_ZEROS (t) pinskia at gcc dot gnu.org
2021-06-28  9:57 ` [Bug middle-end/101237] " pinskia at gcc dot gnu.org
2021-07-05 20:41 ` cvs-commit at gcc dot gnu.org
2021-07-05 20:42 ` pinskia at gcc dot gnu.org

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).