[PATCH] D110242: [Target][CodeGen] Remove default CostKind arguments on inner/impl TTI overrides

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 22 06:18:00 PDT 2021


RKSimon created this revision.
RKSimon added reviewers: fhahn, samparker, dfukalov, marels.
Herald added subscribers: foad, kerbowa, pengfei, kbarton, hiraditya, jgravelle-google, sbc100, nhaehnle, jvesely, nemanjai, dschuff, arsenm, jholewinski.
RKSimon requested review of this revision.
Herald added a subscriber: aheejin.
Herald added a project: LLVM.

Based off a discussion on D110100 <https://reviews.llvm.org/D110100>, we should be avoiding default CostKinds whenever possible.

This initial patch removes them from the 'inner' target implementation callbacks - these should only be used by the main TTI calls, so this should guarantee that we don't cause changes in CostKind by missing it in an inner call. This exposed a few missing arguments in getGEPCost and reduction cost calls that I've cleaned up.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D110242

Files:
  llvm/include/llvm/Analysis/TargetTransformInfo.h
  llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
  llvm/include/llvm/CodeGen/BasicTTIImpl.h
  llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h
  llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h
  llvm/lib/Target/ARM/ARMTargetTransformInfo.h
  llvm/lib/Target/BPF/BPFTargetTransformInfo.h
  llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
  llvm/lib/Target/Lanai/LanaiTargetTransformInfo.h
  llvm/lib/Target/NVPTX/NVPTXTargetTransformInfo.h
  llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h
  llvm/lib/Target/SystemZ/SystemZTargetTransformInfo.h
  llvm/lib/Target/WebAssembly/WebAssemblyTargetTransformInfo.h
  llvm/lib/Target/X86/X86TargetTransformInfo.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D110242.374199.patch
Type: text/x-patch
Size: 22707 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210922/0acb96f6/attachment.bin>


More information about the llvm-commits mailing list