• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-13-stable/contrib/llvm-project/llvm/lib/Transforms/Scalar/

Lines Matching refs:Base

331   /// Base offset for complex addressing.
1862 IVChain(const IVInc &Head, const SCEV *Base)
1863 : Incs(1, Head), ExprBase(Base) {}
1983 void GenerateReassociations(LSRUse &LU, unsigned LUIdx, Formula Base,
1987 const Formula &Base, unsigned Depth,
1989 void GenerateCombinations(LSRUse &LU, unsigned LUIdx, Formula Base);
1991 const Formula &Base, size_t Idx,
1993 void GenerateSymbolicOffsets(LSRUse &LU, unsigned LUIdx, Formula Base);
1995 const Formula &Base,
1998 void GenerateConstantOffsets(LSRUse &LU, unsigned LUIdx, Formula Base);
1999 void GenerateICmpZeroScales(LSRUse &LU, unsigned LUIdx, Formula Base);
2000 void GenerateScales(LSRUse &LU, unsigned LUIdx, Formula Base);
2001 void GenerateTruncates(LSRUse &LU, unsigned LUIdx, Formula Base);
3569 const Formula &Base,
3572 const SCEV *BaseReg = IsScaledReg ? Base.ScaledReg : Base.BaseRegs[Idx];
3598 LU.AccessTy, *J, Base.getNumRegs() > 1))
3611 LU.AccessTy, InnerAddOps[0], Base.getNumRegs() > 1))
3617 Formula F = Base;
3662 Formula Base, unsigned Depth) {
3663 assert(Base.isCanonical(*L) && "Input must be in the canonical form");
3668 for (size_t i = 0, e = Base.BaseRegs.size(); i != e; ++i)
3669 GenerateReassociationsImpl(LU, LUIdx, Base, Depth, i);
3671 if (Base.Scale == 1)
3672 GenerateReassociationsImpl(LU, LUIdx, Base, Depth,
3679 Formula Base) {
3681 if (Base.BaseRegs.size() + (Base.Scale == 1) +
3682 (Base.UnfoldedOffset != 0) <= 1)
3687 Base.unscale();
3689 Formula NewBase = Base;
3692 for (const SCEV *BaseReg : Base.BaseRegs) {
3742 const Formula &Base, size_t Idx,
3744 const SCEV *G = IsScaledReg ? Base.ScaledReg : Base.BaseRegs[Idx];
3748 Formula F = Base;
3761 Formula Base) {
3763 if (Base.BaseGV) return;
3765 for (size_t i = 0, e = Base.BaseRegs.size(); i != e; ++i)
3766 GenerateSymbolicOffsetsImpl(LU, LUIdx, Base, i);
3767 if (Base.Scale == 1)
3768 GenerateSymbolicOffsetsImpl(LU, LUIdx, Base, /* Idx */ -1,
3774 LSRUse &LU, unsigned LUIdx, const Formula &Base,
3778 Formula F = Base;
3779 F.BaseOffset = (uint64_t)Base.BaseOffset - Offset;
3802 const SCEV *G = IsScaledReg ? Base.ScaledReg : Base.BaseRegs[Idx];
3833 Formula F = Base;
3846 Formula Base) {
3854 for (size_t i = 0, e = Base.BaseRegs.size(); i != e; ++i)
3855 GenerateConstantOffsetsImpl(LU, LUIdx, Base, Worklist, i);
3856 if (Base.Scale == 1)
3857 GenerateConstantOffsetsImpl(LU, LUIdx, Base, Worklist, /* Idx */ -1,
3864 Formula Base) {
3868 Type *IntTy = Base.getType();
3876 if (Base.ScaledReg && Base.ScaledReg->getType()->isPointerTy())
3878 for (const SCEV *BaseReg : Base.BaseRegs)
3881 assert(!Base.BaseGV && "ICmpZero use is not legal!");
3886 if (Base.BaseOffset == std::numeric_limits<int64_t>::min() && Factor == -1)
3888 int64_t NewBaseOffset = (uint64_t)Base.BaseOffset * Factor;
3889 if (NewBaseOffset / Factor != Base.BaseOffset)
3908 Formula F = Base;
3923 if (getExactSDiv(F.BaseRegs[i], FactorS, SE) != Base.BaseRegs[i])
3930 if (getExactSDiv(F.ScaledReg, FactorS, SE) != Base.ScaledReg)
3940 if (F.UnfoldedOffset / Factor != Base.UnfoldedOffset)
3956 void LSRInstance::GenerateScales(LSRUse &LU, unsigned LUIdx, Formula Base) {
3958 Type *IntTy = Base.getType();
3963 if (Base.Scale != 0 && !Base.unscale())
3966 assert(Base.Scale == 0 && "unscale did not did its job!");
3970 Base.Scale = Factor;
3971 Base.HasBaseReg = Base.BaseRegs.size() > 1;
3974 Base)) {
3979 LU.AccessTy, Base) &&
3988 !Base.HasBaseReg && Base.BaseOffset == 0 && !Base.BaseGV)
3991 for (size_t i = 0, e = Base.BaseRegs.size(); i != e; ++i) {
3992 const SCEVAddRecExpr *AR = dyn_cast<SCEVAddRecExpr>(Base.BaseRegs[i]);
4001 Formula F = Base;
4005 // Base. In that case, do not try to insert the formula, it will be
4022 void LSRInstance::GenerateTruncates(LSRUse &LU, unsigned LUIdx, Formula Base) {
4024 if (Base.BaseGV) return;
4027 Type *DstTy = Base.getType();
4033 Formula F = Base;