[InstCombine] add helper for "is desirable int type"; NFC
This splits out the logic from shouldChangeType() that currently allows 8/16/32-bit transforms even if those types are not listed as legal in the data layout. This could be useful as a predicate for vector insert/extract transforms. Note that this leaves the subsequent checks in shouldChangeType() unchanged. We may want to merge the checks for i1 and/or "ToLegal" into "isDesirable", but that may alter existing transforms.
Loading
Please sign in to comment