LLVM  14.0.0git
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Attributes | List of all members
llvm::InstCombiner Class Referenceabstract

The core instruction combiner logic. More...

#include "llvm/Transforms/InstCombine/InstCombiner.h"

Inheritance diagram for llvm::InstCombiner:
Inheritance graph
[legend]
Collaboration diagram for llvm::InstCombiner:
Collaboration graph
[legend]

Public Types

using BuilderTy = IRBuilder< TargetFolder, IRBuilderCallbackInserter >
 An IRBuilder that automatically inserts new instructions into the worklist. More...
 

Public Member Functions

 InstCombiner (InstCombineWorklist &Worklist, BuilderTy &Builder, bool MinimizeSize, AAResults *AA, AssumptionCache &AC, TargetLibraryInfo &TLI, TargetTransformInfo &TTI, DominatorTree &DT, OptimizationRemarkEmitter &ORE, BlockFrequencyInfo *BFI, ProfileSummaryInfo *PSI, const DataLayout &DL, LoopInfo *LI)
 
virtual ~InstCombiner ()
 
void addToWorklist (Instruction *I)
 
AssumptionCachegetAssumptionCache () const
 
TargetLibraryInfogetTargetLibraryInfo () const
 
DominatorTreegetDominatorTree () const
 
const DataLayoutgetDataLayout () const
 
const SimplifyQuerygetSimplifyQuery () const
 
OptimizationRemarkEmittergetOptimizationRemarkEmitter () const
 
BlockFrequencyInfogetBlockFrequencyInfo () const
 
ProfileSummaryInfogetProfileSummaryInfo () const
 
LoopInfogetLoopInfo () const
 
Optional< Instruction * > targetInstCombineIntrinsic (IntrinsicInst &II)
 
Optional< Value * > targetSimplifyDemandedUseBitsIntrinsic (IntrinsicInst &II, APInt DemandedMask, KnownBits &Known, bool &KnownBitsComputed)
 
Optional< Value * > targetSimplifyDemandedVectorEltsIntrinsic (IntrinsicInst &II, APInt DemandedElts, APInt &UndefElts, APInt &UndefElts2, APInt &UndefElts3, std::function< void(Instruction *, unsigned, APInt, APInt &)> SimplifyAndSetOp)
 
InstructionInsertNewInstBefore (Instruction *New, Instruction &Old)
 Inserts an instruction New before instruction Old. More...
 
InstructionInsertNewInstWith (Instruction *New, Instruction &Old)
 Same as InsertNewInstBefore, but also sets the debug loc. More...
 
InstructionreplaceInstUsesWith (Instruction &I, Value *V)
 A combiner-aware RAUW-like routine. More...
 
InstructionreplaceOperand (Instruction &I, unsigned OpNum, Value *V)
 Replace operand of instruction and add old operand to the worklist. More...
 
void replaceUse (Use &U, Value *NewValue)
 Replace use and add the previously used value to the worklist. More...
 
virtual InstructioneraseInstFromFunction (Instruction &I)=0
 Combiner aware instruction erasure. More...
 
void computeKnownBits (const Value *V, KnownBits &Known, unsigned Depth, const Instruction *CxtI) const
 
KnownBits computeKnownBits (const Value *V, unsigned Depth, const Instruction *CxtI) const
 
bool isKnownToBeAPowerOfTwo (const Value *V, bool OrZero=false, unsigned Depth=0, const Instruction *CxtI=nullptr)
 
bool MaskedValueIsZero (const Value *V, const APInt &Mask, unsigned Depth=0, const Instruction *CxtI=nullptr) const
 
unsigned ComputeNumSignBits (const Value *Op, unsigned Depth=0, const Instruction *CxtI=nullptr) const
 
OverflowResult computeOverflowForUnsignedMul (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
OverflowResult computeOverflowForSignedMul (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
OverflowResult computeOverflowForUnsignedAdd (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
OverflowResult computeOverflowForSignedAdd (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
OverflowResult computeOverflowForUnsignedSub (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
OverflowResult computeOverflowForSignedSub (const Value *LHS, const Value *RHS, const Instruction *CxtI) const
 
virtual bool SimplifyDemandedBits (Instruction *I, unsigned OpNo, const APInt &DemandedMask, KnownBits &Known, unsigned Depth=0)=0
 
virtual ValueSimplifyDemandedVectorElts (Value *V, APInt DemandedElts, APInt &UndefElts, unsigned Depth=0, bool AllowMultipleUsers=false)=0
 

Static Public Member Functions

static ValuepeekThroughBitcast (Value *V, bool OneUseOnly=false)
 Return the source operand of a potentially bitcasted value while optionally checking if it has one use. More...
 
static unsigned getComplexity (Value *V)
 Assign a complexity or rank value to LLVM Values. More...
 
static bool isCanonicalPredicate (CmpInst::Predicate Pred)
 Predicate canonicalization reduces the number of patterns that need to be matched by other transforms. More...
 
static bool isSignBitCheck (ICmpInst::Predicate Pred, const APInt &RHS, bool &TrueIfSigned)
 Given an exploded icmp instruction, return true if the comparison only checks the sign bit. More...
 
static ConstantAddOne (Constant *C)
 Add one to a Constant. More...
 
static ConstantSubOne (Constant *C)
 Subtract one from a Constant. More...
 
static llvm::Optional< std::pair< CmpInst::Predicate, Constant * > > getFlippedStrictnessPredicateAndConstant (CmpInst::Predicate Pred, Constant *C)
 
static bool shouldAvoidAbsorbingNotIntoSelect (const SelectInst &SI)
 
static bool isFreeToInvert (Value *V, bool WillInvertAllUses)
 Return true if the specified value is free to invert (apply ~ to). More...
 
static bool canFreelyInvertAllUsersOf (Value *V, Value *IgnoredUser)
 Given i1 V, can every user of V be freely adapted if V is changed to !V ? InstCombine's freelyInvertAllUsersOf() must be kept in sync with this fn. More...
 
static ConstantgetSafeVectorConstantForBinop (BinaryOperator::BinaryOps Opcode, Constant *In, bool IsRHSConstant)
 Some binary operators require special handling to avoid poison and undefined behavior. More...
 
static void CreateNonTerminatorUnreachable (Instruction *InsertAt)
 Create and insert the idiom we use to indicate a block is unreachable without having to rewrite the CFG from within InstCombine. More...
 

Public Attributes

uint64_t MaxArraySizeForCombine = 0
 Maximum size of array considered when transforming. More...
 
BuilderTyBuilder
 

Protected Attributes

InstCombineWorklistWorklist
 A worklist of the instructions that need to be simplified. More...
 
const bool MinimizeSize
 
AAResultsAA
 
AssumptionCacheAC
 
TargetLibraryInfoTLI
 
DominatorTreeDT
 
const DataLayoutDL
 
const SimplifyQuery SQ
 
OptimizationRemarkEmitterORE
 
BlockFrequencyInfoBFI
 
ProfileSummaryInfoPSI
 
LoopInfoLI
 
bool MadeIRChange = false
 

Detailed Description

The core instruction combiner logic.

This class provides both the logic to recursively visit instructions and combine them.

Definition at line 45 of file InstCombiner.h.

Member Typedef Documentation

◆ BuilderTy

An IRBuilder that automatically inserts new instructions into the worklist.

Definition at line 55 of file InstCombiner.h.

Constructor & Destructor Documentation

◆ InstCombiner()

llvm::InstCombiner::InstCombiner ( InstCombineWorklist Worklist,
BuilderTy Builder,
bool  MinimizeSize,
AAResults AA,
AssumptionCache AC,
TargetLibraryInfo TLI,
TargetTransformInfo TTI,
DominatorTree DT,
OptimizationRemarkEmitter ORE,
BlockFrequencyInfo BFI,
ProfileSummaryInfo PSI,
const DataLayout DL,
LoopInfo LI 
)
inline

Definition at line 84 of file InstCombiner.h.

◆ ~InstCombiner()

virtual llvm::InstCombiner::~InstCombiner ( )
inlinevirtual

Definition at line 94 of file InstCombiner.h.

Member Function Documentation

◆ AddOne()

static Constant* llvm::InstCombiner::AddOne ( Constant C)
inlinestatic

◆ addToWorklist()

void llvm::InstCombiner::addToWorklist ( Instruction I)
inline

◆ canFreelyInvertAllUsersOf()

static bool llvm::InstCombiner::canFreelyInvertAllUsersOf ( Value V,
Value IgnoredUser 
)
inlinestatic

Given i1 V, can every user of V be freely adapted if V is changed to !V ? InstCombine's freelyInvertAllUsersOf() must be kept in sync with this fn.

See also: isFreeToInvert()

Definition at line 269 of file InstCombiner.h.

References assert(), I, llvm::MIPatternMatch::m_Not(), llvm::PatternMatch::m_Value(), llvm::PatternMatch::match(), llvm::MCID::Select, and llvm::Value::uses().

Referenced by llvm::InstCombinerImpl::canonicalizeICmpPredicate(), and llvm::InstCombinerImpl::sinkNotIntoOtherHandOfAndOrOr().

◆ computeKnownBits() [1/2]

void llvm::InstCombiner::computeKnownBits ( const Value V,
KnownBits Known,
unsigned  Depth,
const Instruction CxtI 
) const
inline

Definition at line 456 of file InstCombiner.h.

References llvm::computeKnownBits(), llvm::Depth, and DL.

◆ computeKnownBits() [2/2]

KnownBits llvm::InstCombiner::computeKnownBits ( const Value V,
unsigned  Depth,
const Instruction CxtI 
) const
inline

Definition at line 461 of file InstCombiner.h.

References llvm::computeKnownBits(), llvm::Depth, and DL.

◆ ComputeNumSignBits()

unsigned llvm::InstCombiner::ComputeNumSignBits ( const Value Op,
unsigned  Depth = 0,
const Instruction CxtI = nullptr 
) const
inline

Definition at line 477 of file InstCombiner.h.

References llvm::ComputeNumSignBits(), llvm::Depth, and DL.

◆ computeOverflowForSignedAdd()

OverflowResult llvm::InstCombiner::computeOverflowForSignedAdd ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 499 of file InstCombiner.h.

References llvm::computeOverflowForSignedAdd(), and DL.

◆ computeOverflowForSignedMul()

OverflowResult llvm::InstCombiner::computeOverflowForSignedMul ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 488 of file InstCombiner.h.

References llvm::computeOverflowForSignedMul(), and DL.

◆ computeOverflowForSignedSub()

OverflowResult llvm::InstCombiner::computeOverflowForSignedSub ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 510 of file InstCombiner.h.

References llvm::computeOverflowForSignedSub(), and DL.

◆ computeOverflowForUnsignedAdd()

OverflowResult llvm::InstCombiner::computeOverflowForUnsignedAdd ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 493 of file InstCombiner.h.

References llvm::computeOverflowForUnsignedAdd(), and DL.

◆ computeOverflowForUnsignedMul()

OverflowResult llvm::InstCombiner::computeOverflowForUnsignedMul ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 482 of file InstCombiner.h.

References llvm::computeOverflowForUnsignedMul(), and DL.

◆ computeOverflowForUnsignedSub()

OverflowResult llvm::InstCombiner::computeOverflowForUnsignedSub ( const Value LHS,
const Value RHS,
const Instruction CxtI 
) const
inline

Definition at line 504 of file InstCombiner.h.

References llvm::computeOverflowForUnsignedSub(), and DL.

◆ CreateNonTerminatorUnreachable()

static void llvm::InstCombiner::CreateNonTerminatorUnreachable ( Instruction InsertAt)
inlinestatic

Create and insert the idiom we use to indicate a block is unreachable without having to rewrite the CFG from within InstCombine.

Definition at line 359 of file InstCombiner.h.

References llvm::UndefValue::get(), llvm::Value::getContext(), llvm::Type::getInt1PtrTy(), and llvm::ConstantInt::getTrue().

◆ eraseInstFromFunction()

virtual Instruction* llvm::InstCombiner::eraseInstFromFunction ( Instruction I)
pure virtual

Combiner aware instruction erasure.

When dealing with an instruction that has side effects or produces a void value, we can't rely on DCE to delete the instruction. Instead, visit methods should return the value returned by this function.

Implemented in llvm::InstCombinerImpl.

Referenced by llvm::ARMTTIImpl::instCombineIntrinsic(), llvm::GCNTTIImpl::instCombineIntrinsic(), and simplifyX86MaskedStore().

◆ getAssumptionCache()

AssumptionCache& llvm::InstCombiner::getAssumptionCache ( ) const
inline

◆ getBlockFrequencyInfo()

BlockFrequencyInfo* llvm::InstCombiner::getBlockFrequencyInfo ( ) const
inline

Definition at line 375 of file InstCombiner.h.

References llvm::AMDGPUISD::BFI.

◆ getComplexity()

static unsigned llvm::InstCombiner::getComplexity ( Value V)
inlinestatic

Assign a complexity or rank value to LLVM Values.

This is used to reduce the amount of pattern matching needed for compares and commutative instructions. For example, if we have: icmp ugt X, Constant or xor (add X, Constant), cast Z

We do not have to consider the commuted variants of these patterns because canonicalization based on complexity guarantees the above ordering.

This routine maps IR values to various complexity ranks: 0 -> undef 1 -> Constants 2 -> Other non-instructions 3 -> Arguments 4 -> Cast and (f)neg/not instructions 5 -> Other instructions

Definition at line 125 of file InstCombiner.h.

References llvm::PatternMatch::m_FNeg(), llvm::MIPatternMatch::m_Neg(), llvm::MIPatternMatch::m_Not(), llvm::PatternMatch::m_Value(), and llvm::PatternMatch::match().

◆ getDataLayout()

const DataLayout& llvm::InstCombiner::getDataLayout ( ) const
inline

◆ getDominatorTree()

DominatorTree& llvm::InstCombiner::getDominatorTree ( ) const
inline

◆ getFlippedStrictnessPredicateAndConstant()

llvm::Optional< std::pair< CmpInst::Predicate, Constant * > > InstCombiner::getFlippedStrictnessPredicateAndConstant ( CmpInst::Predicate  Pred,
Constant C 
)
static

◆ getLoopInfo()

LoopInfo* llvm::InstCombiner::getLoopInfo ( ) const
inline

Definition at line 377 of file InstCombiner.h.

◆ getOptimizationRemarkEmitter()

OptimizationRemarkEmitter& llvm::InstCombiner::getOptimizationRemarkEmitter ( ) const
inline

Definition at line 372 of file InstCombiner.h.

◆ getProfileSummaryInfo()

ProfileSummaryInfo* llvm::InstCombiner::getProfileSummaryInfo ( ) const
inline

Definition at line 376 of file InstCombiner.h.

◆ getSafeVectorConstantForBinop()

static Constant* llvm::InstCombiner::getSafeVectorConstantForBinop ( BinaryOperator::BinaryOps  Opcode,
Constant In,
bool  IsRHSConstant 
)
inlinestatic

Some binary operators require special handling to avoid poison and undefined behavior.

If a constant vector has undef elements, replace those undefs with identity constants if possible because those are always safe to execute. If no identity constant exists, replace undef with some other safe constant.

Definition at line 305 of file InstCombiner.h.

References assert(), llvm::ConstantInt::get(), llvm::ConstantFP::get(), llvm::ConstantVector::get(), llvm::ConstantExpr::getBinOpIdentity(), llvm::Constant::getNullValue(), i, llvm::tgtok::In, and llvm_unreachable.

Referenced by foldSelectShuffle(), and foldSelectShuffleWith1Binop().

◆ getSimplifyQuery()

const SimplifyQuery& llvm::InstCombiner::getSimplifyQuery ( ) const
inline

Definition at line 371 of file InstCombiner.h.

◆ getTargetLibraryInfo()

TargetLibraryInfo& llvm::InstCombiner::getTargetLibraryInfo ( ) const
inline

◆ InsertNewInstBefore()

Instruction* llvm::InstCombiner::InsertNewInstBefore ( Instruction New,
Instruction Old 
)
inline

Inserts an instruction New before instruction Old.

Also adds the new instruction to the worklist and returns New so that it is suitable for use as the return from the visitation patterns.

Definition at line 395 of file InstCombiner.h.

References assert(), BB, llvm::ilist_node_impl< OptionsT >::getIterator(), llvm::Instruction::getParent(), and llvm::InstCombineWorklist::push().

◆ InsertNewInstWith()

Instruction* llvm::InstCombiner::InsertNewInstWith ( Instruction New,
Instruction Old 
)
inline

Same as InsertNewInstBefore, but also sets the debug loc.

Definition at line 405 of file InstCombiner.h.

References llvm::Instruction::getDebugLoc().

◆ isCanonicalPredicate()

static bool llvm::InstCombiner::isCanonicalPredicate ( CmpInst::Predicate  Pred)
inlinestatic

Predicate canonicalization reduces the number of patterns that need to be matched by other transforms.

For example, we may swap the operands of a conditional branch or select to create a compare with a canonical (inverted) predicate which is then more likely to be matched with other values.

Definition at line 143 of file InstCombiner.h.

References llvm::CmpInst::FCMP_OGE, llvm::CmpInst::FCMP_OLE, llvm::CmpInst::FCMP_ONE, llvm::CmpInst::ICMP_NE, llvm::CmpInst::ICMP_SGE, llvm::CmpInst::ICMP_SLE, llvm::CmpInst::ICMP_UGE, and llvm::CmpInst::ICMP_ULE.

Referenced by canonicalizeCmpWithConstant(), and llvm::InstCombinerImpl::canonicalizeICmpPredicate().

◆ isFreeToInvert()

static bool llvm::InstCombiner::isFreeToInvert ( Value V,
bool  WillInvertAllUses 
)
inlinestatic

Return true if the specified value is free to invert (apply ~ to).

This happens in cases where the ~ can be eliminated. If WillInvertAllUses is true, work under the assumption that the caller intends to remove all uses of V and only keep uses of ~V.

See also: canFreelyInvertAllUsersOf()

Definition at line 233 of file InstCombiner.h.

References llvm::MCID::Add, llvm::PatternMatch::m_AnyIntegralConstant(), llvm::PatternMatch::m_c_BinOp(), llvm::PatternMatch::m_ImmConstant(), llvm::MIPatternMatch::m_Not(), llvm::PatternMatch::m_Select(), llvm::PatternMatch::m_Value(), and llvm::PatternMatch::match().

Referenced by matchDeMorgansLaws(), llvm::InstCombinerImpl::sinkNotIntoOtherHandOfAndOrOr(), and sinkNotIntoXor().

◆ isKnownToBeAPowerOfTwo()

bool llvm::InstCombiner::isKnownToBeAPowerOfTwo ( const Value V,
bool  OrZero = false,
unsigned  Depth = 0,
const Instruction CxtI = nullptr 
)
inline

Definition at line 466 of file InstCombiner.h.

References llvm::Depth, DL, and llvm::isKnownToBeAPowerOfTwo().

◆ isSignBitCheck()

static bool llvm::InstCombiner::isSignBitCheck ( ICmpInst::Predicate  Pred,
const APInt RHS,
bool &  TrueIfSigned 
)
inlinestatic

Given an exploded icmp instruction, return true if the comparison only checks the sign bit.

If it only checks the sign bit, set TrueIfSigned if the result of the comparison is true when the input value is signed.

Definition at line 163 of file InstCombiner.h.

References llvm::CmpInst::ICMP_SGE, llvm::CmpInst::ICMP_SGT, llvm::CmpInst::ICMP_SLE, llvm::CmpInst::ICMP_SLT, llvm::CmpInst::ICMP_UGE, llvm::CmpInst::ICMP_UGT, llvm::CmpInst::ICMP_ULE, llvm::CmpInst::ICMP_ULT, llvm::APInt::isAllOnesValue(), llvm::APInt::isMaxSignedValue(), llvm::APInt::isMinSignedValue(), and llvm::APInt::isNullValue().

Referenced by llvm::InstCombinerImpl::foldICmpBitCast(), and getDemandedBitsLHSMask().

◆ MaskedValueIsZero()

bool llvm::InstCombiner::MaskedValueIsZero ( const Value V,
const APInt Mask,
unsigned  Depth = 0,
const Instruction CxtI = nullptr 
) const
inline

◆ peekThroughBitcast()

static Value* llvm::InstCombiner::peekThroughBitcast ( Value V,
bool  OneUseOnly = false 
)
inlinestatic

Return the source operand of a potentially bitcasted value while optionally checking if it has one use.

If there is no bitcast or the one use check is not met, return the input value itself.

Definition at line 99 of file InstCombiner.h.

Referenced by llvm::X86TTIImpl::instCombineIntrinsic(), and isMinMaxWithLoads().

◆ replaceInstUsesWith()

Instruction* llvm::InstCombiner::replaceInstUsesWith ( Instruction I,
Value V 
)
inline

A combiner-aware RAUW-like routine.

This method is to be used when an instruction is found to be dead, replaceable with another preexisting expression. Here we add all uses of I to the worklist, replace all uses of I with the new value, then return I, so that the inst combiner will know that I was modified.

Definition at line 416 of file InstCombiner.h.

References llvm::dbgs(), llvm::UndefValue::get(), I, LLVM_DEBUG, and llvm::InstCombineWorklist::pushUsersToWorkList().

Referenced by instCombineConvertFromSVBool(), llvm::ARMTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), llvm::GCNTTIImpl::instCombineIntrinsic(), instCombineRDFFR(), instCombineSVECmpNE(), instCombineSVECntElts(), instCombineSVEDup(), instCombineSVELast(), instCombineSVEPTest(), instCombineSVETBL(), instCombineSVEVectorMul(), processPhiNode(), simplifyAMDGCNImageIntrinsic(), and simplifyX86MaskedLoad().

◆ replaceOperand()

Instruction* llvm::InstCombiner::replaceOperand ( Instruction I,
unsigned  OpNum,
Value V 
)
inline

Replace operand of instruction and add old operand to the worklist.

Definition at line 437 of file InstCombiner.h.

References llvm::InstCombineWorklist::addValue(), and I.

Referenced by llvm::ARMTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), and llvm::GCNTTIImpl::instCombineIntrinsic().

◆ replaceUse()

void llvm::InstCombiner::replaceUse ( Use U,
Value NewValue 
)
inline

Replace use and add the previously used value to the worklist.

Definition at line 444 of file InstCombiner.h.

References llvm::InstCombineWorklist::addValue().

◆ shouldAvoidAbsorbingNotIntoSelect()

static bool llvm::InstCombiner::shouldAvoidAbsorbingNotIntoSelect ( const SelectInst SI)
inlinestatic

◆ SimplifyDemandedBits()

virtual bool llvm::InstCombiner::SimplifyDemandedBits ( Instruction I,
unsigned  OpNo,
const APInt DemandedMask,
KnownBits Known,
unsigned  Depth = 0 
)
pure virtual

◆ SimplifyDemandedVectorElts()

virtual Value* llvm::InstCombiner::SimplifyDemandedVectorElts ( Value V,
APInt  DemandedElts,
APInt UndefElts,
unsigned  Depth = 0,
bool  AllowMultipleUsers = false 
)
pure virtual

◆ SubOne()

static Constant* llvm::InstCombiner::SubOne ( Constant C)
inlinestatic

◆ targetInstCombineIntrinsic()

Optional< Instruction * > InstCombiner::targetInstCombineIntrinsic ( IntrinsicInst II)

◆ targetSimplifyDemandedUseBitsIntrinsic()

Optional< Value * > InstCombiner::targetSimplifyDemandedUseBitsIntrinsic ( IntrinsicInst II,
APInt  DemandedMask,
KnownBits Known,
bool &  KnownBitsComputed 
)

◆ targetSimplifyDemandedVectorEltsIntrinsic()

Optional< Value * > InstCombiner::targetSimplifyDemandedVectorEltsIntrinsic ( IntrinsicInst II,
APInt  DemandedElts,
APInt UndefElts,
APInt UndefElts2,
APInt UndefElts3,
std::function< void(Instruction *, unsigned, APInt, APInt &)>  SimplifyAndSetOp 
)

Member Data Documentation

◆ AA

AAResults* llvm::InstCombiner::AA
protected

Definition at line 65 of file InstCombiner.h.

◆ AC

AssumptionCache& llvm::InstCombiner::AC
protected

Definition at line 68 of file InstCombiner.h.

◆ BFI

BlockFrequencyInfo* llvm::InstCombiner::BFI
protected

Definition at line 74 of file InstCombiner.h.

◆ Builder

BuilderTy& llvm::InstCombiner::Builder

◆ DL

const DataLayout& llvm::InstCombiner::DL
protected

Definition at line 71 of file InstCombiner.h.

Referenced by llvm::InstCombinerImpl::visitAtomicRMWInst().

◆ DT

DominatorTree& llvm::InstCombiner::DT
protected

Definition at line 70 of file InstCombiner.h.

◆ LI

LoopInfo* llvm::InstCombiner::LI
protected

Definition at line 79 of file InstCombiner.h.

◆ MadeIRChange

bool llvm::InstCombiner::MadeIRChange = false
protected

Definition at line 81 of file InstCombiner.h.

◆ MaxArraySizeForCombine

uint64_t llvm::InstCombiner::MaxArraySizeForCombine = 0

Maximum size of array considered when transforming.

Definition at line 51 of file InstCombiner.h.

Referenced by combineInstructionsOverFunction(), unpackLoadToAggregate(), and unpackStoreToAggregate().

◆ MinimizeSize

const bool llvm::InstCombiner::MinimizeSize
protected

Definition at line 63 of file InstCombiner.h.

◆ ORE

OptimizationRemarkEmitter& llvm::InstCombiner::ORE
protected

Definition at line 73 of file InstCombiner.h.

◆ PSI

ProfileSummaryInfo* llvm::InstCombiner::PSI
protected

Definition at line 75 of file InstCombiner.h.

◆ SQ

const SimplifyQuery llvm::InstCombiner::SQ
protected

Definition at line 72 of file InstCombiner.h.

◆ TLI

TargetLibraryInfo& llvm::InstCombiner::TLI
protected

Definition at line 69 of file InstCombiner.h.

◆ Worklist

InstCombineWorklist& llvm::InstCombiner::Worklist
protected

A worklist of the instructions that need to be simplified.

Definition at line 60 of file InstCombiner.h.


The documentation for this class was generated from the following files: