[PATCH] D124357: [AArch64] Cost modelling for fptoi_sat

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Apr 24 23:12:30 PDT 2022


dmgreen created this revision.
dmgreen added reviewers: samtebbs, fhahn, jaykang10, momchil.velikov, SjoerdMeijer.
Herald added subscribers: hiraditya, kristof.beyls.
Herald added a project: All.
dmgreen requested review of this revision.
Herald added a project: LLVM.

This builds on top of the target-independent cost model added in D124269 <https://reviews.llvm.org/D124269> to add aarch64 specific costs for fptoui_sat and fptosi_sat intrinsics. For many common types they will be legal instructions as the AArch64 instructions will saturate naturally. For unsupported pairs of integer and floating point types, an additional min/max clamp is needed.


https://reviews.llvm.org/D124357

Files:
  llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
  llvm/test/Analysis/CostModel/AArch64/fptoi_sat.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D124357.424820.patch
Type: text/x-patch
Size: 40850 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220425/6cb85355/attachment.bin>


More information about the llvm-commits mailing list