<div dir="ltr">SimplifyDemandedUseBits in part because of the following comment:<div><br></div><div>// FIXME: for XOR, we prefer to force bits to 1 if they will make a -1.<br></div><div><br></div><div>will transform<br><div>
<br></div><div style>%neg = xor i32 %V, -1</div><div style>%and = and i32 %not, 4096</div><div style><br></div><div style>into</div><div style><br></div><div style>%and = and i32 %V, 4096</div><div style>%xor = xor i32 %and, 4096</div>
</div><div style><br></div><div style>which would generate worse code for platforms that have a negate instruction vs. encoding the immediate in the xor.</div><div style><br></div><div style>What should happen to the code to address the FIXME?</div>
<div style><br></div><div style>Thanks</div><div style>-- </div><div style>David Majnemer</div></div>