public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/19516] New: missed optimization
@ 2005-01-18 22:29 rguenth at tat dot physik dot uni-tuebingen dot de
  2005-01-18 23:48 ` [Bug tree-optimization/19516] missed optimization (bool) pinskia at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2005-01-18 22:29 UTC (permalink / raw)
  To: gcc-bugs

Actually a side-bug of 19507.  The testcase

void bar(void);

void foo(const _Bool *flag)
{
        if (*flag)
                bar();
        if (*flag)
                bar();
}

Should be transformed to (at the tree level):

if (!*flag)
   return;
bar();
if (*flag)
   bar();

this is only done at the RTL level at the moment.

Andrew Pinski reports this works, if we exchange _Bool
for int/short/char.

-- 
           Summary: missed optimization
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at tat dot physik dot uni-tuebingen dot de
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19516


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

end of thread, other threads:[~2005-04-25  5:05 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-18 22:29 [Bug tree-optimization/19516] New: missed optimization rguenth at tat dot physik dot uni-tuebingen dot de
2005-01-18 23:48 ` [Bug tree-optimization/19516] missed optimization (bool) pinskia at gcc dot gnu dot org
2005-01-22 18:34 ` kazu at cs dot umass dot edu
2005-01-23 11:13 ` rguenth at tat dot physik dot uni-tuebingen dot de
2005-02-06 17:41 ` kazu@cs.umass.edu
2005-02-07 20:13 ` kazu at cs dot umass dot edu
2005-02-15  1:46 ` law at redhat dot com
2005-04-23  1:11 ` law at redhat dot com
2005-04-23 13:49 ` rguenth at gcc dot gnu dot org
2005-04-25  5:05 ` law at redhat dot com
2005-04-25  5:05 ` 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).