This reapplies r272987 with a fix for infinitely looping
when the truncated value is another shift of a constant.
Details
- Reviewers
majnemer
Diff Detail
Event Timeline
Fix unnecessary test change, comment
| test/Transforms/InstCombine/cast.ll | ||
|---|---|---|
| 990 ↗ | (On Diff #63562) | This is leftover junk, the test change isn't necessary |
| lib/Transforms/InstCombine/InstCombineCasts.cpp | ||
|---|---|---|
| 536–537 | This comment seems duplicated. | |
| 550 | Can we replace "isn't non-native" with "is native"? | |
| 551 | Consider using m_APInt here, it handles vector splats. | |
| 555 | I think it'd be nice to use getScalarSizeInBits so that the code is more vector ready. | |
| test/Transforms/InstCombine/2011-05-28-swapmulsub.ll | ||
| 36 | What happens with this i16? | |
| lib/Transforms/InstCombine/InstCombineCasts.cpp | ||
|---|---|---|
| 551 | This just adds more clutter without changing the other code before this since it's re-using Cst and the whole block is already skipped for !isa<IntegerType> | |
| lib/Transforms/InstCombine/InstCombineCasts.cpp | ||
|---|---|---|
| 543 | This would also require an additional variable since Cst is ConstantInt | |
This comment seems duplicated.