http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58564
--- Comment #4 from Mikael Pettersson <mikpelinux at gmail dot com> --- (In reply to John Regehr from comment #3) > Kai, this is a real bug, please reopen it. > > Here is what I get out of -fdump-tree-original: > > b = (int) (d == &c && a != 1); > > This is wrong. > > One way to illustrate the problem is to remove the useless comma operator > from the test case, which now looks like this (I've also added parens around > the ^): I can confirm this observation. Adding parentheses around the "a ^ 1" makes no difference, but removing the comma operator and its left operand "0, " makes 4.7 to trunk compute the same result as 4.6 and older did.