public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/96701] New: Failure to optimize self right-shift to 0
@ 2020-08-19 9:59 gabravier at gmail dot com
2020-08-24 22:50 ` [Bug tree-optimization/96701] " pinskia at gcc dot gnu.org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: gabravier at gmail dot com @ 2020-08-19 9:59 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96701
Bug ID: 96701
Summary: Failure to optimize self right-shift to 0
Product: gcc
Version: 11.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: gabravier at gmail dot com
Target Milestone: ---
int f(int x)
{
return x >> x;
}
This can be optimized to `return 0;`. This transformation is done by LLVM, but
not by GCC.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/96701] Failure to optimize self right-shift to 0
2020-08-19 9:59 [Bug tree-optimization/96701] New: Failure to optimize self right-shift to 0 gabravier at gmail dot com
@ 2020-08-24 22:50 ` pinskia at gcc dot gnu.org
2020-10-31 5:20 ` erozen at microsoft dot com
2020-11-06 3:37 ` law at redhat dot com
2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-08-24 22:50 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96701
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |easyhack
Status|UNCONFIRMED |NEW
Ever confirmed|0 |1
Severity|normal |enhancement
Last reconfirmed| |2020-08-24
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/96701] Failure to optimize self right-shift to 0
2020-08-19 9:59 [Bug tree-optimization/96701] New: Failure to optimize self right-shift to 0 gabravier at gmail dot com
2020-08-24 22:50 ` [Bug tree-optimization/96701] " pinskia at gcc dot gnu.org
@ 2020-10-31 5:20 ` erozen at microsoft dot com
2020-11-06 3:37 ` law at redhat dot com
2 siblings, 0 replies; 4+ messages in thread
From: erozen at microsoft dot com @ 2020-10-31 5:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96701
Eugene Rozenfeld <erozen at microsoft dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |erozen at microsoft dot com
--- Comment #2 from Eugene Rozenfeld <erozen at microsoft dot com> ---
Created attachment 49476
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49476&action=edit
Proposed patch.
The patch was approved by Richard Biener:
https://gcc.gnu.org/pipermail/gcc-patches/2020-October/557586.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/96701] Failure to optimize self right-shift to 0
2020-08-19 9:59 [Bug tree-optimization/96701] New: Failure to optimize self right-shift to 0 gabravier at gmail dot com
2020-08-24 22:50 ` [Bug tree-optimization/96701] " pinskia at gcc dot gnu.org
2020-10-31 5:20 ` erozen at microsoft dot com
@ 2020-11-06 3:37 ` law at redhat dot com
2 siblings, 0 replies; 4+ messages in thread
From: law at redhat dot com @ 2020-11-06 3:37 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96701
Jeffrey A. Law <law at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |law at redhat dot com
Resolution|--- |FIXED
Status|NEW |RESOLVED
--- Comment #3 from Jeffrey A. Law <law at redhat dot com> ---
Fixed by Eugene's patch on the trunk.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-11-06 3:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-19 9:59 [Bug tree-optimization/96701] New: Failure to optimize self right-shift to 0 gabravier at gmail dot com
2020-08-24 22:50 ` [Bug tree-optimization/96701] " pinskia at gcc dot gnu.org
2020-10-31 5:20 ` erozen at microsoft dot com
2020-11-06 3:37 ` law at redhat dot com
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).