11#ifndef LLVM_DIRECTX_DIRECTXTARGETTRANSFORMINFO_H
12#define LLVM_DIRECTX_DIRECTXTARGETTRANSFORMINFO_H
33 const bool HasNativeLowPrecision;
38 static bool readNativeLowPrecisionFlag(
const Function &
F) {
40 F.getParent()->getModuleFlag(
"dx.nativelowprec")))
41 return Flag->getValue().getBoolValue();
48 TLI(ST->getTargetLowering()),
49 HasNativeLowPrecision(readNativeLowPrecisionFlag(
F)) {}
52 unsigned ScalarOpdIdx)
const override;
54 int OpdIdx)
const override;
58 unsigned Opcode,
Type *InputTypeA,
Type *InputTypeB,
Type *AccumType,
62 std::optional<FastMathFlags> FMF)
const override {
This file provides a helper that implements much of the TTI interface in terms of the target-independ...
This file contains the declarations for the subclasses of Constant, which represent the different fla...
static cl::opt< OutputCostKind > CostKind("cost-kind", cl::desc("Target cost kind"), cl::init(OutputCostKind::RecipThroughput), cl::values(clEnumValN(OutputCostKind::RecipThroughput, "throughput", "Reciprocal throughput"), clEnumValN(OutputCostKind::Latency, "latency", "Instruction latency"), clEnumValN(OutputCostKind::CodeSize, "code-size", "Code size"), clEnumValN(OutputCostKind::SizeAndLatency, "size-latency", "Code size and latency"), clEnumValN(OutputCostKind::All, "all", "Print all cost kinds")))
Module.h This file contains the declarations for the Module class.
BasicTTIImplBase(const TargetMachine *TM, const DataLayout &DL)
InstructionCost getPartialReductionCost(unsigned Opcode, Type *InputTypeA, Type *InputTypeB, Type *AccumType, ElementCount VF, TTI::PartialReductionExtendKind OpAExtend, TTI::PartialReductionExtendKind OpBExtend, std::optional< unsigned > BinOp, TTI::TargetCostKind CostKind, std::optional< FastMathFlags > FMF) const override
unsigned getMinimumLookupTableEntryBitWidth() const override
bool isTargetIntrinsicWithScalarOpAtArg(Intrinsic::ID ID, unsigned ScalarOpdIdx) const override
DirectXTTIImpl(const DirectXTargetMachine *TM, const Function &F)
unsigned getMinVectorRegisterBitWidth() const override
bool isTargetIntrinsicWithOverloadTypeAtArg(Intrinsic::ID ID, int OpdIdx) const override
static InstructionCost getInvalid(CostType Val=0)
The instances of the Type class are immutable: once they are created, they are never changed.
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
std::enable_if_t< detail::IsValidPointer< X, Y >::value, X * > extract_or_null(Y &&MD)
Extract a Value from Metadata, allowing null.
This is an optimization pass for GlobalISel generic memory operations.