http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55814
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization Status|UNCONFIRMED |NEW Last reconfirmed| |2012-12-26 Summary|Missed optimization with |Missed optimization with |short-circuit evaluation |short-circuit evaluation of | |always evaluated | |comparisons/loads Ever Confirmed|0 |1 --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> 2012-12-26 21:46:40 UTC --- This is a sinking issue. Sinking of loads. If the code was written as: _Bool foo(int *a, int *b) { return (a[0] > b[0]) || (a[1] > b[1]) || (a[2] > b[2]) || (a[3] > b[3]); } Instead then it would short-circuit correctly.