[SVE][CodeGen] Replace uses of TypeSize comparison operators
authorDavid Sherwood <david.sherwood@arm.com>
Tue, 29 Sep 2020 07:03:13 +0000 (08:03 +0100)
committerDavid Sherwood <david.sherwood@arm.com>
Mon, 19 Oct 2020 07:08:41 +0000 (08:08 +0100)
commitf693f915a07eca94a3faeadc3b5dad59fc0eb1de
tree500763ec55c893b7b1f681ae83c2de198c5d2b52
parentd67d8f879027ef401d22cc71b07a77b882d53376
[SVE][CodeGen] Replace uses of TypeSize comparison operators

In certain places in the code we can never end up in a situation where
we're mixing fixed width and scalable vector types. For example,
we can't have truncations and extends that change the lane count. Also,
in other places such as GenWidenVectorStores and GenWidenVectorLoads we
know from the behaviour of FindMemType that we can never choose a vector
type with a different scalable property.

In various places I have used EVT::bitsXY functions instead of
TypeSize::isKnownXY, where it probably makes sense to keep an assert
that scalable properties match.

Differential Revision: https://reviews.llvm.org/D88654
llvm/include/llvm/CodeGen/BasicTTIImpl.h
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp