summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/JumpThreading.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2017-08-05 01:45:17 +0000
committerCraig Topper <craig.topper@intel.com>2017-08-05 01:45:17 +0000
commitfc5283092b3a1e354a9be28ba68437aef7cfb076 (patch)
tree418360d89bc5a8931c6de925b6e35a46afef4812 /llvm/lib/Transforms/Scalar/JumpThreading.cpp
parent5fb82efebf66400f40f5e4745f64537ee7a66c74 (diff)
downloadbcm5719-llvm-fc5283092b3a1e354a9be28ba68437aef7cfb076.tar.gz
bcm5719-llvm-fc5283092b3a1e354a9be28ba68437aef7cfb076.zip
[InstCombine] In foldSelectICmpAnd, if we need to to truncate from the 'and' type to the 'select' type, do it after shifting right instead of just bailing.
Previously we were always trying to emit the zext or truncate before any shift. This meant if the 'and' mask was larger than the size of the truncate we would skip the transformation. Now we shift the result of the and right first leaving the bit within the range of the truncate. This matches what we are doing in foldSelectICmpAndOr for the same problem. llvm-svn: 310159
Diffstat (limited to 'llvm/lib/Transforms/Scalar/JumpThreading.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud