This patch introduces a new helper to compute the ranges of VFs with
matching decisions for all instructions up front. This will be used in a
follow-up patch to get rid of the VF range clamping during recipe
creation, enabling us to move to more granular VPlan construction.
The current version just adds the new helper and adds assertions to
ensure it gives the same result as the current clamping, in order to
catch any potential gaps.
This extra work is only needed temporarily and it appears to be
compile-time neutral:
http://llvm-compile-time-tracker.com/compare.php?from=7c7f4676cd421b1d64145eebfed11e5a3d8935d7&to=80d7088723fcfcd4ac80235bdbd57b70156b997f&stat=instructions
Note that this means the logic to apply the decisions is becoming a bit
more spread out initially. But in future patches, we can do the
decisions exclusively up-front (e.g. by creating a map which contains
whether to widen, scalarize or clone for each instruction in the loop).
This would allow us to untangle recipe creation from the cost-model
specifics as follow-up.
This cleanup is independent?