public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/30104]  New: missed code motion optimization (invariant control structures)
@ 2006-12-07  6:12 dann at godzilla dot ics dot uci dot edu
  2006-12-07 14:17 ` [Bug tree-optimization/30104] " rguenth at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: dann at godzilla dot ics dot uci dot edu @ 2006-12-07  6:12 UTC (permalink / raw)
  To: gcc-bugs

The following 2 functions should be compiled to the same assembly. 
This is one of Briggs' compiler benchmarks.

void motion_test10(int *data)
{
  int j;
  int p = data[1];
  int i = data[0];
  do {
    if (p)
      j = 1;
    else
      j = 2;
    i = i + j;
    data[data[2]] = 2;
  } while (i < data[3]);
}
void motion_result10(int *data)
{
  int j;
  int p = data[1];
  int i = data[0];
  if (p)
    j = 1;
  else
    j = 2;
  do {
    i = i + j;
    data[data[2]] = 2;
  } while (i < data[3]);
}


-- 
           Summary: missed code motion optimization (invariant control
                    structures)
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dann at godzilla dot ics dot uci dot edu


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


^ permalink raw reply	[flat|nested] 6+ messages in thread
[parent not found: <bug-30104-4@http.gcc.gnu.org/bugzilla/>]

end of thread, other threads:[~2012-02-08 23:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-12-07  6:12 [Bug tree-optimization/30104] New: missed code motion optimization (invariant control structures) dann at godzilla dot ics dot uci dot edu
2006-12-07 14:17 ` [Bug tree-optimization/30104] " rguenth at gcc dot gnu dot org
2006-12-07 16:46 ` pinskia at gcc dot gnu dot org
2006-12-07 16:49 ` rguenth at gcc dot gnu dot org
2006-12-07 18:24 ` dann at godzilla dot ics dot uci dot edu
     [not found] <bug-30104-4@http.gcc.gnu.org/bugzilla/>
2012-02-08 23:18 ` 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).