[PATCH] D105042: [SLP][COST][X86]Improve cost model for masked gather.

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 7 06:05:44 PDT 2021


RKSimon added inline comments.


================
Comment at: llvm/lib/Target/X86/X86TargetTransformInfo.cpp:4780
+    if (ST->hasAVX512() && (NumElts == 2 || (NumElts == 4 && !ST->hasVLX())))
+      return false;
   }
----------------
I'm really not sure about this - by moving this into isLegalMaskedGather we're affecting codegen as well as IR.

While we agreed that we'd avoid this on AVX2 targets (where legal gathers are actually REALLY bad), more minor cost differences on AVX512 targets its not so clear.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105042/new/

https://reviews.llvm.org/D105042



More information about the llvm-commits mailing list