This is found during code review for https://reviews.llvm.org/D80907
See comment https://reviews.llvm.org/D80907#2068594
Peephole pass will convert following pattern:
%1:gprc = LI 100 %2:gprc = RLWINM %1:gprc, 1, 3, 2
to
%2:gprc = LI 0
The wrap mask is not handled well in convertToImmediateForm
Can we fix this in the wrap?It does nothing now if lo == hi. But as it is [lo,hi), if lo == hi, we expect it to be all ones if it is with wrap.