Recognize RISBG opportunities where the end result is narrower than the original input - where a truncate separates the shift/and operations.
The motivating case is some code in postgres which looks like:
srlg %r2, %r0, 11
nilh %r2, 255
Differential D21452
[SystemZ] Recognize RISBG opportunities involving a truncate RolandF on Jun 16 2016, 3:48 PM. Authored by
Details Recognize RISBG opportunities where the end result is narrower than the original input - where a truncate separates the shift/and operations. The motivating case is some code in postgres which looks like: srlg %r2, %r0, 11
Diff Detail
Event TimelineComment Actions Please also update the comment before "struct RxSBGOperands", where it explains: The output value has BitSize bits, although Input may be narrower (in which case the upper bits are don't care). to now also include the possibility that Input is wider than BitSize bits. Finally, please extend the test cases in test/CodeGen/SystemZ/r?sbg-*.ll to also cover this case (both good cases where a truncation can be eliminated, and bad cases where it cannot). Thanks for working on improving the SystemZ back end!
Comment Actions Added tests.
|