public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/93006] Better code with a-- == 0 rather than --a == -1
[not found] <bug-93006-4@http.gcc.gnu.org/bugzilla/>
@ 2023-09-05 4:34 ` pinskia at gcc dot gnu.org
0 siblings, 0 replies; only message in thread
From: pinskia at gcc dot gnu.org @ 2023-09-05 4:34 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93006
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=96702
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
Last reconfirmed| |2023-09-05
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed, the problem is the single_use usage in:
/* For equality, this is also true with wrapping overflow. */
(for op (eq ne)
(simplify
(op:c (nop_convert?@3 (plus:c@2 @0 (convert1? @1))) (convert2? @1))
(if (ANY_INTEGRAL_TYPE_P (TREE_TYPE (@0))
&& (TYPE_OVERFLOW_UNDEFINED (TREE_TYPE (@0))
|| TYPE_OVERFLOW_WRAPS (TREE_TYPE (@0)))
&& (CONSTANT_CLASS_P (@0) || (single_use (@2) && single_use (@3)))
&& tree_nop_conversion_p (TREE_TYPE (@3), TREE_TYPE (@2))
&& tree_nop_conversion_p (TREE_TYPE (@3), TREE_TYPE (@1)))
(op @0 { build_zero_cst (TREE_TYPE (@0)); })))
Similar as for the minus case, see PR 96702 for that ...
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-09-05 4:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-93006-4@http.gcc.gnu.org/bugzilla/>
2023-09-05 4:34 ` [Bug target/93006] Better code with a-- == 0 rather than --a == -1 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).