[Float2Int] Avoid unnecessary lamdbas (NFC)
authorNikita Popov <npopov@redhat.com>
Thu, 31 Mar 2022 14:09:34 +0000 (16:09 +0200)
committerNikita Popov <npopov@redhat.com>
Thu, 31 Mar 2022 14:13:13 +0000 (16:13 +0200)
commit33ac23e7cf8fa8422550f83ff1734f941f19dc6c
tree8f9883274316c00c968a83dabd50b80eb25dc76a
parentf66975555fec57e55f3d72d06d8bc83472cd2c1e
[Float2Int] Avoid unnecessary lamdbas (NFC)

Instead of first creating a lambda for calculating the range,
then collecting the ranges for the operands, and then calling the
lambda on those ranges, we can first calculate the operand ranges
and then calculate the result directly in the switch.
llvm/lib/Transforms/Scalar/Float2Int.cpp