When a comparison is extended and it would be free to extend the
arguments to that comparison, we can propagate the extend into those arguments.
This prevents extra instructions being generated to extend the result of the
comparison, which is not free to extend.
This is a resubmission of D116812 with fixes that need another review.
Changed since the previous commit:
The transform is now restricted to VLS to avoid issues with i1 vectors being
illegal there but legal on VLA.
Zero extends are used when the comparison is unsigned.
Perhaps I'm being pedantic but do you mean "cheap" or do you mean "zero cost"?