[PATCH] D54703: [TargetLowering] expandFP_TO_UINT - improve fp16 support

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 19 08:33:10 PST 2018


RKSimon created this revision.
RKSimon added reviewers: atanasyan, efriedma, uweigand, kpn.
Herald added subscribers: jrtc27, sdardis.

As discussed on https://reviews.llvm.org/D53794, for float types with ranges smaller than the destination integer type, then we should be able to just use a regular FP_TO_SINT opcode.

I thought we'd need to provide MSA test cases for very small integer types as well (fp16 -> i8 etc.), but it turns out that promotion will kick in so they're unnecessary.


Repository:
  rL LLVM

https://reviews.llvm.org/D54703

Files:
  lib/CodeGen/SelectionDAG/TargetLowering.cpp
  test/CodeGen/Mips/msa/f16-llvm-ir.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D54703.174622.patch
Type: text/x-patch
Size: 14900 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181119/53dc60db/attachment.bin>


More information about the llvm-commits mailing list