• Sam Parker's avatar
    [CostModel] Unify Intrinsic Costs. · 871556a4
    Sam Parker authored
    Recommitting most of the remaining changes from
    259eb619, but excluding the call to
    getUserCost from getInstructionThroughput. Though there's still no
    test changes, I doubt that this is an NFC...
    With the two getIntrinsicInstrCosts folded into one, now fold in the
    scalar/code-size orientated getIntrinsicCost. The remaining scalar
    intrinsics were memcpy, cttz and ctlz which now have special handling
    in the BasicTTI implementation.
    This had required a change in the AMDGPU backend for fabs as it
    should always be 'free'. I've also changed the X86 backend to return
    the BaseT implementation when the CostKind isn't RecipThroughput.
    Differential Revision: https://reviews.llvm.org/D80012