[all-commits] [llvm/llvm-project] ee959d: [TTI] Remove getOperationCost

Sam Parker via All-commits all-commits at lists.llvm.org
Tue Apr 21 01:16:07 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: ee959ddc5eee180f75851649d01260a4f0ba5198
      https://github.com/llvm/llvm-project/commit/ee959ddc5eee180f75851649d01260a4f0ba5198
  Author: Sam Parker <sam.parker at arm.com>
  Date:   2020-04-21 (Tue, 21 Apr 2020)

  Changed paths:
    M llvm/include/llvm/Analysis/TargetTransformInfo.h
    M llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
    M llvm/include/llvm/CodeGen/BasicTTIImpl.h
    M llvm/lib/Analysis/TargetTransformInfo.cpp

  Log Message:
  -----------
  [TTI] Remove getOperationCost

This API call has been used recently with, a very valid, expectation
that it would do something useful but it doesn't actually query any
backend information. So, remove this method and merge its
functionality into getUserCost. As well as that, also use
getCastInstrCost to get a proper cost from the backend for the
concerned instructions though we only currently return the answer if
it's considered free. The default implementation now also checks
int/ptr conversions too, as well as truncs and bitcasts.

Differential Revision: https://reviews.llvm.org/D76124




More information about the All-commits mailing list