Skip to content
Commit 4d4b5d95 authored by Craig Topper's avatar Craig Topper
Browse files

[X86] Don't turn (and (shl X, C1), C2) into (shl (and X, (C1 >> C2), C2) if...

[X86] Don't turn (and (shl X, C1), C2) into (shl (and X, (C1 >> C2), C2) if the original AND can represented by MOVZX.

The MOVZX doesn't require an immediate to be encoded at all. Though it does use
a 2 byte opcode so its the same size as a 1 byte immediate. But it has a
separate source and dest register so can help avoid copies.

llvm-svn: 358805
parent 8b826482
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment