As discussed on PR33744, this patch replaces ShuffleKind::SK_Alternate which requires shuffle masks to only match an alternating pattern from its 2 sources:
e.g. v4f32: <0,5,2,7> or <4,1,6,3>
This seems far too restrictive as most SIMD hardware which will implement it using a general blend/bit-select instruction (permitting elements from either source as long as they are inline):
e.g. v4f32: <0,5,2,7>, <4,1,6,3>, <0,1,6,7>, <4,1,2,3> etc.
This initial patch just updates the name and cost model shuffle mask analysis, later patch reviews will update SLP to better utilise this - it still limits itself to SK_Alternate patterns.
It also raised an interesting issue in that Identity shuffles are being matched by analysis to a mixture of SK_PermuteSingleSrc/SK_Alternate - shouldn't we just return cost = 0 for these cases?
A bit more description would be good here. Something like:
Selects elements from the corresponding lane of one source operand or the other. This is equivalent to a vector select with a constant condition operand.