[Bug tree-optimization/87186] Does not inline constant to simplify bitwise expression

mcccs at gmx dot com gcc-bugzilla@gcc.gnu.org
Sun Sep 2 06:29:00 GMT 2018


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87186

--- Comment #1 from MCCCS <mcccs at gmx dot com> ---
It can simplify

~(~(x|s)|x)|~(~(x|s)|s)

to

s^x

but it can't simplify

const int t = x|s;
~(~t|x)|~(~t|s)

or

const int t = ~(x|s);
~(t|x)|~(t|s)

or

const int t = ~x&~s;
~(t|x)|~(t|s)


More information about the Gcc-bugs mailing list