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

--- Comment #19 from Uros Bizjak <ubizjak at gmail dot com> 2012-02-06 21:36:01 
UTC ---
(In reply to comment #4)
> Another similar, but yet different case:

Yet another similar test:

int test (int a, int b)
{
  int lt = a + b < 0;
  int eq = a + b == 0;
  if (lt)
    return 1;
  return eq;
}

combine pass creates:

            (set (reg:CCZ 17 flags)
                (compare:CCZ (plus:SI (reg/v:SI 63 [ a ])
                        (reg/v:SI 64 [ b ]))
                    (const_int 0 [0])))
            (set (reg:SI 60 [ D.1710 ])
                (plus:SI (reg/v:SI 63 [ a ])
                    (reg/v:SI 64 [ b ])))

we have a discrepancy here, since compare elimination pass expects RTX in the
form of:

 [(operate)
  (set-cc)]

Reply via email to