[InstCombine] FoldShiftByConstant - consistently use ConstantExpr in logicalshift...
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 6 Oct 2020 12:44:17 +0000 (13:44 +0100)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 6 Oct 2020 13:48:34 +0000 (14:48 +0100)
commit75d33a3a97c6f6e65ef5139a4a12508716842601
tree059030bb1d6c9cd8254bdf4fb075cecc5800b83f
parent8a3cbb1535a92dcc0ac3bd8fc64216a465b8506a
[InstCombine] FoldShiftByConstant - consistently use ConstantExpr in logicalshift(trunc(shift(x,c1)),c2) fold. NFCI.

This still only gets used for scalar types but now always uses ConstantExpr in preparation for vector support - it was using APInt methods in some places.
llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp