public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug optimization/13965] New: [tree-ssa] fold takes into account branch target information at tree level
@ 2004-02-01 21:03 dann at godzilla dot ics dot uci dot edu
  2004-05-14  1:26 ` [Bug tree-optimization/13965] " pinskia at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: dann at godzilla dot ics dot uci dot edu @ 2004-02-01 21:03 UTC (permalink / raw)
  To: gcc-bugs

It seems that fold takes into account target branch cost. 


ssa-ccp-5.c is a copy testsuite/gcc.dg/tree-ssa/ssa-ccp-5.c

./cc1 -O2 -fdump-tree-optimized ssa-ccp-5.c

the .optimized dump for the second function in the file is:

test55 (x, y)
{
<bb 0>:
  return;

}

./cc1 -O2 -fdump-tree-optimized ssa-ccp-5.c -mtune=pentiumpro

test55 (x, y)
{
<bb 0>:
  if (x == 5 && y != 0) goto <L0>; else goto <L2>;

<L0>:;
  if (x + 22 != 27) goto <L1>; else goto <L2>;

<L1>:;
  link_error ();

<L2>:;
<L3>:;
  return;

}

Thanks to Andrew Pinski for diagnosing this. 

The effect of adding -mtune=pentiumpro to the testcase from PR8361 is:
without -mtune=pentiumpro  97575 assembly lines 
with -mtune=pentiumpro    103723 assembly lines 

This is probably an issue on the mainline too, but it's harder to show a
testcase there.

-- 
           Summary: [tree-ssa] fold takes into account branch target
                    information at tree level
           Product: gcc
           Version: tree-ssa
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dann at godzilla dot ics dot uci dot edu
                CC: gcc-bugs at gcc dot gnu dot org


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


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

end of thread, other threads:[~2013-11-09 20:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-13965-4@http.gcc.gnu.org/bugzilla/>
2013-11-09 20:40 ` [Bug tree-optimization/13965] [tree-ssa] fold takes into account branch target information at tree level pinskia at gcc dot gnu.org
2004-02-01 21:03 [Bug optimization/13965] New: " dann at godzilla dot ics dot uci dot edu
2004-05-14  1:26 ` [Bug tree-optimization/13965] " pinskia at gcc dot gnu dot org
2004-05-26 12:28 ` pinskia at gcc dot gnu dot org
2004-08-13 22:01 ` cvs-commit at gcc dot gnu dot org
2004-09-09  3:53 ` pinskia at gcc dot gnu dot 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).