[PATCH] D79111: [CostModel][X86][ARM] Teach default implementation of getCastInstrCost to not add a split/join cost if source type and the destination type both have a SplitVector action

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 29 12:22:27 PDT 2020


craig.topper created this revision.
craig.topper added reviewers: RKSimon, spatel.
Herald added subscribers: danielkiss, kristof.beyls.
Herald added a project: LLVM.

If both the source and the destination need to be split then the two halves of the split operation are completely independent and don't need to be split or joined. So we don't need to assess a cost for the split or join.


https://reviews.llvm.org/D79111

Files:
  llvm/include/llvm/CodeGen/BasicTTIImpl.h
  llvm/test/Analysis/CostModel/ARM/cast.ll
  llvm/test/Analysis/CostModel/X86/arith-fix.ll
  llvm/test/Analysis/CostModel/X86/arith-overflow.ll
  llvm/test/Analysis/CostModel/X86/cast.ll
  llvm/test/Analysis/CostModel/X86/extend.ll
  llvm/test/Analysis/CostModel/X86/fptosi.ll
  llvm/test/Analysis/CostModel/X86/fptoui.ll
  llvm/test/Analysis/CostModel/X86/masked-intrinsic-cost.ll
  llvm/test/Analysis/CostModel/X86/min-legal-vector-width.ll
  llvm/test/Analysis/CostModel/X86/sitofp.ll
  llvm/test/Analysis/CostModel/X86/trunc.ll
  llvm/test/Analysis/CostModel/X86/uitofp.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D79111.260979.patch
Type: text/x-patch
Size: 348355 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200429/218c57b8/attachment-0001.bin>


More information about the llvm-commits mailing list