20#define DEBUG_TYPE "loongarchtti"
43 case LoongArchRegisterClass::GPRRC:
46 case LoongArchRegisterClass::FPRRC:
47 return ST->hasBasicF() ? 32 : 0;
48 case LoongArchRegisterClass::VRRC:
49 return ST->hasExtLSX() ? 32 : 0;
57 return LoongArchRegisterClass::VRRC;
59 return LoongArchRegisterClass::GPRRC;
62 if ((ScalarTy->
isFloatTy() && ST->hasBasicF()) ||
64 return LoongArchRegisterClass::FPRRC;
67 return LoongArchRegisterClass::GPRRC;
71 return ST->getMaxInterleaveFactor();
76 case LoongArchRegisterClass::GPRRC:
77 return "LoongArch::GPRRC";
78 case LoongArchRegisterClass::FPRRC:
79 return "LoongArch::FPRRC";
80 case LoongArchRegisterClass::VRRC:
81 return "LoongArch::VRRC";
99 switch (
II->getIntrinsicID()) {
102 case Intrinsic::vector_reduce_add:
103 case Intrinsic::vector_reduce_and:
104 case Intrinsic::vector_reduce_or:
105 case Intrinsic::vector_reduce_smax:
106 case Intrinsic::vector_reduce_smin:
107 case Intrinsic::vector_reduce_umax:
108 case Intrinsic::vector_reduce_umin:
109 case Intrinsic::vector_reduce_xor:
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
uint64_t IntrinsicInst * II
A wrapper class for inspecting calls to intrinsic functions.
TTI::PopcntSupportKind getPopcntSupport(unsigned TyWidth) const override
unsigned getCacheLineSize() const override
bool shouldExpandReduction(const IntrinsicInst *II) const override
unsigned getRegisterClassForType(bool Vector, Type *Ty=nullptr) const override
unsigned getMaxInterleaveFactor(ElementCount VF) const override
const char * getRegisterClassName(unsigned ClassID) const override
unsigned getNumberOfRegisters(unsigned ClassID) const override
unsigned getPrefetchDistance() const override
bool enableWritePrefetching() const override
TypeSize getRegisterBitWidth(TargetTransformInfo::RegisterKind K) const override
static constexpr TypeSize getFixed(ScalarTy ExactSize)
The instances of the Type class are immutable: once they are created, they are never changed.
bool isFloatTy() const
Return true if this is 'float', a 32-bit IEEE fp type.
Type * getScalarType() const
If this is a vector type, return the element type, otherwise return 'this'.
bool isDoubleTy() const
Return true if this is 'double', a 64-bit IEEE fp type.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
This is an optimization pass for GlobalISel generic memory operations.
constexpr bool isPowerOf2_32(uint32_t Value)
Return true if the argument is a power of two > 0.