LLVM API Documentation
#include <Instructions.h>


Public Member Functions | |
| const Value * | getCondition () const |
| const Value * | getTrueValue () const |
| const Value * | getFalseValue () const |
| Value * | getCondition () |
| Value * | getTrueValue () |
| Value * | getFalseValue () |
| DECLARE_TRANSPARENT_OPERAND_ACCESSORS (Value) | |
| Transparently provide more efficient getOperand methods. | |
| OtherOps | getOpcode () const |
| getOpcode() returns a member of one of the enums like Instruction::Add. | |
Static Public Member Functions | |
| static SelectInst * | Create (Value *C, Value *S1, Value *S2, const Twine &NameStr="", Instruction *InsertBefore=nullptr) |
| static SelectInst * | Create (Value *C, Value *S1, Value *S2, const Twine &NameStr, BasicBlock *InsertAtEnd) |
| static const char * | areInvalidOperands (Value *Cond, Value *True, Value *False) |
| static bool | classof (const Instruction *I) |
| static bool | classof (const Value *V) |
| Methods for support type inquiry through isa, cast, and dyn_cast: | |
Protected Member Functions | |
| SelectInst * | clone_impl () const override |
SelectInst - This class represents the LLVM 'select' instruction.
Definition at line 1542 of file Instructions.h.
| const char * SelectInst::areInvalidOperands | ( | Value * | Op0, |
| Value * | Op1, | ||
| Value * | Op2 | ||
| ) | [static] |
areInvalidOperands - Return a string if the specified operands are invalid for a select operation, otherwise return null.
Definition at line 62 of file Instructions.cpp.
References llvm::dyn_cast(), llvm::Value::getContext(), llvm::Type::getInt1Ty(), llvm::VectorType::getNumElements(), and llvm::Value::getType().
Referenced by llvm::ConstantExpr::getSelect().
| static bool llvm::SelectInst::classof | ( | const Instruction * | I | ) | [inline, static] |
Definition at line 1597 of file Instructions.h.
References llvm::Instruction::getOpcode(), and llvm::MCID::Select.
| static bool llvm::SelectInst::classof | ( | const Value * | V | ) | [inline, static] |
Methods for support type inquiry through isa, cast, and dyn_cast:
Reimplemented from llvm::Instruction.
Definition at line 1600 of file Instructions.h.
| SelectInst * SelectInst::clone_impl | ( | ) | const [override, protected, virtual] |
Implements llvm::Instruction.
Definition at line 3733 of file Instructions.cpp.
References Create(), and llvm::User::getOperand().
| static SelectInst* llvm::SelectInst::Create | ( | Value * | C, |
| Value * | S1, | ||
| Value * | S2, | ||
| const Twine & | NameStr = "", |
||
| Instruction * | InsertBefore = nullptr |
||
| ) | [inline, static] |
Definition at line 1567 of file Instructions.h.
Referenced by clone_impl(), llvm::InstCombiner::commonIDivTransforms(), llvm::NoFolder::CreateSelect(), llvm::IRBuilder< true, TargetFolder >::CreateSelect(), foldUDivNegCst(), llvm::ConstantExpr::getAsInstruction(), MatchSelectFromAndOr(), TryToShrinkGlobalToBoolean(), llvm::InstCombiner::visitAdd(), llvm::InstCombiner::visitAnd(), llvm::InstCombiner::visitCallInst(), llvm::InstCombiner::visitExtractElementInst(), llvm::InstCombiner::visitFAdd(), llvm::InstCombiner::visitFPTrunc(), llvm::InstCombiner::visitICmpInst(), llvm::InstCombiner::visitLoadInst(), llvm::InstCombiner::visitOr(), and llvm::InstCombiner::visitUDiv().
| static SelectInst* llvm::SelectInst::Create | ( | Value * | C, |
| Value * | S1, | ||
| Value * | S2, | ||
| const Twine & | NameStr, | ||
| BasicBlock * | InsertAtEnd | ||
| ) | [inline, static] |
Definition at line 1572 of file Instructions.h.
Transparently provide more efficient getOperand methods.
| const Value* llvm::SelectInst::getCondition | ( | ) | const [inline] |
Definition at line 1578 of file Instructions.h.
Referenced by AddReachableCodeToWorklist(), CanSelectOperandBeMappingIntoPredBlock(), ExtractEquivalentCondition(), foldSelectICmpAnd(), foldSelectICmpAndOr(), foldSelectInst(), llvm::InstCombiner::FoldSelectIntoOp(), llvm::InstCombiner::FoldSelectOpOp(), llvm::InstCombiner::FoldSPFofSPF(), isFormingBranchFromSelectProfitable(), llvm::PatternMatch::MaxMin_match< CmpInst_t, LHS_t, RHS_t, Pred_t >::match(), MatchSelectPattern(), SimplifyIndirectBrOnSelect(), SimplifySwitchOnSelect(), speculateSelectInstLoads(), ThreadCmpOverSelect(), llvm::InstCombiner::visitAdd(), llvm::InstCombiner::visitSelectInst(), and llvm::ObjectSizeOffsetEvaluator::visitSelectInst().
| Value* llvm::SelectInst::getCondition | ( | ) | [inline] |
Definition at line 1581 of file Instructions.h.
| const Value* llvm::SelectInst::getFalseValue | ( | ) | const [inline] |
Definition at line 1580 of file Instructions.h.
Referenced by CanEvaluateShifted(), CanEvaluateTruncated(), llvm::InstCombiner::FoldSPFofSPF(), isSafeSelectToSpeculate(), llvm::PatternMatch::MaxMin_match< CmpInst_t, LHS_t, RHS_t, Pred_t >::match(), MatchSelectPattern(), SimplifyIndirectBrOnSelect(), SimplifySwitchOnSelect(), speculateSelectInstLoads(), ThreadBinOpOverSelect(), ThreadCmpOverSelect(), llvm::InstCombiner::visitAdd(), llvm::ObjectSizeOffsetVisitor::visitSelectInst(), llvm::InstCombiner::visitSelectInst(), llvm::ObjectSizeOffsetEvaluator::visitSelectInst(), and llvm::InstCombiner::visitSelectInstWithICmp().
| Value* llvm::SelectInst::getFalseValue | ( | ) | [inline] |
Definition at line 1583 of file Instructions.h.
| OtherOps llvm::SelectInst::getOpcode | ( | ) | const [inline] |
getOpcode() returns a member of one of the enums like Instruction::Add.
Reimplemented from llvm::Instruction.
Definition at line 1592 of file Instructions.h.
References llvm::Instruction::getOpcode().
| const Value* llvm::SelectInst::getTrueValue | ( | ) | const [inline] |
Definition at line 1579 of file Instructions.h.
Referenced by CanEvaluateShifted(), CanEvaluateTruncated(), llvm::InstCombiner::FoldSPFofSPF(), isSafeSelectToSpeculate(), llvm::PatternMatch::MaxMin_match< CmpInst_t, LHS_t, RHS_t, Pred_t >::match(), MatchSelectPattern(), SimplifyIndirectBrOnSelect(), SimplifySwitchOnSelect(), speculateSelectInstLoads(), ThreadBinOpOverSelect(), ThreadCmpOverSelect(), llvm::InstCombiner::visitAdd(), llvm::ObjectSizeOffsetVisitor::visitSelectInst(), llvm::InstCombiner::visitSelectInst(), llvm::ObjectSizeOffsetEvaluator::visitSelectInst(), and llvm::InstCombiner::visitSelectInstWithICmp().
| Value* llvm::SelectInst::getTrueValue | ( | ) | [inline] |
Definition at line 1582 of file Instructions.h.