LLVM API Documentation
#include <Instruction.h>
Inheritance diagram for llvm::Instruction:
Definition at line 29 of file Instruction.h.
|
Definition at line 329 of file Instruction.h. |
|
Definition at line 492 of file Instruction.h. |
|
Definition at line 655 of file Instruction.h. |
|
Definition at line 166 of file Instruction.h. |
|
Definition at line 26 of file Instruction.cpp. References llvm::BasicBlock::getInstList(), getParent(), and llvm::cl::init(). |
|
Definition at line 39 of file Instruction.cpp. References llvm::BasicBlock::getInstList(), and llvm::cl::init(). |
|
Definition at line 53 of file Instruction.h. References Parent. |
|
Reimplemented from llvm::User. Reimplemented in llvm::TerminatorInst, llvm::BinaryOperator, llvm::AllocationInst, llvm::MallocInst, llvm::AllocaInst, llvm::FreeInst, llvm::LoadInst, llvm::StoreInst, llvm::GetElementPtrInst, llvm::SetCondInst, llvm::CastInst, llvm::CallInst, llvm::ShiftInst, llvm::SelectInst, llvm::VANextInst, llvm::VAArgInst, llvm::PHINode, llvm::ReturnInst, llvm::BranchInst, llvm::SwitchInst, llvm::InvokeInst, llvm::UnwindInst, llvm::UnreachableInst, llvm::DbgInfoIntrinsic, llvm::DbgStopPointInst, llvm::MemIntrinsic, llvm::MemCpyInst, llvm::MemMoveInst, llvm::MemSetInst, llvm::TmpInstruction, and llvm::ValueHandle. Definition at line 159 of file Instruction.h. References llvm::Value::getValueType(), and llvm::Value::InstructionVal. |
|
Methods for support type inquiry through isa, cast, and dyn_cast:.
Reimplemented in llvm::TerminatorInst, llvm::BinaryOperator, llvm::AllocationInst, llvm::MallocInst, llvm::AllocaInst, llvm::FreeInst, llvm::LoadInst, llvm::StoreInst, llvm::GetElementPtrInst, llvm::SetCondInst, llvm::CastInst, llvm::CallInst, llvm::ShiftInst, llvm::SelectInst, llvm::VANextInst, llvm::VAArgInst, llvm::PHINode, llvm::ReturnInst, llvm::BranchInst, llvm::SwitchInst, llvm::InvokeInst, llvm::UnwindInst, llvm::UnreachableInst, llvm::TmpInstruction, and llvm::ValueHandle. Definition at line 158 of file Instruction.h. |
|
clone() - Create a copy of 'this' instruction that is identical in all ways except the following: The instruction has no parent The instruction has no name Implemented in llvm::TerminatorInst, llvm::BinaryOperator, llvm::AllocationInst, llvm::MallocInst, llvm::AllocaInst, llvm::FreeInst, llvm::LoadInst, llvm::StoreInst, llvm::GetElementPtrInst, llvm::CastInst, llvm::CallInst, llvm::ShiftInst, llvm::SelectInst, llvm::VANextInst, llvm::VAArgInst, llvm::PHINode, llvm::ReturnInst, llvm::BranchInst, llvm::SwitchInst, llvm::InvokeInst, llvm::UnwindInst, llvm::UnreachableInst, llvm::TmpInstruction, and llvm::ValueHandle. Referenced by HoistThenElseCodeToIf(). |
|
eraseFromParent - This method unlinks 'this' from the containing basic block and deletes it. Definition at line 79 of file Instruction.cpp. References llvm::BasicBlock::getInstList(), and getParent(). Referenced by HoistThenElseCodeToIf(), OptimizeAwayTrappingUsesOfLoads(), and OptimizeGlobalAddressOfMalloc(). |
|
Definition at line 85 of file Instruction.h. References Next(). |
|
Definition at line 84 of file Instruction.h. References Next(). Referenced by llvm::DecomposeArrayRef(), llvm::SimplifyCFG(), and Cilkifier::visitCallInst(). |
|
|
Definition at line 83 of file Instruction.cpp. References Add(), Alloca, llvm::ISD::And, llvm::ISD::Br, Call, Cast, Load, Malloc, Mul(), llvm::ISD::Or, PHI, llvm::ISD::Ret, Select, llvm::ISD::SetEQ, llvm::ISD::SetGE, llvm::ISD::SetGT, llvm::ISD::SetLE, llvm::ISD::SetLT, llvm::ISD::SetNE, Shl, llvm::ISD::Store, llvm::ISD::Switch, VAArg, VANext, and llvm::ISD::Xor. |
|
Reimplemented in llvm::TmpInstruction, and llvm::ValueHandle. Definition at line 104 of file Instruction.h. References getOpcode(). Referenced by llvm::InstructionNode::dumpNode(), and llvm::ConstantExpr::getOpcodeName(). |
|
Definition at line 80 of file Instruction.h. References Parent. |
|
|
Definition at line 87 of file Instruction.h. |
|
Definition at line 86 of file Instruction.h. Referenced by llvm::Interpreter::visitCallSite(). |
|
isAssociative - Return true if the instruction is associative: Associative operators satisfy: x op (y op z) === (x op y) op z) In LLVM, the Add, Mul, And, Or, and Xor operators are associative, when not applied to floating point types. Definition at line 170 of file Instruction.cpp. References Add(), llvm::ISD::And, llvm::Type::isFloatingPoint(), Mul(), llvm::ISD::Or, and llvm::ISD::Xor. |
|
isAssociative - Return true if the instruction is associative: Associative operators satisfy: x op (y op z) === (x op y) op z In LLVM, the Add, Mul, And, Or, and Xor operators are associative, when not applied to floating point types. Definition at line 128 of file Instruction.h. References getOpcode(), and llvm::Value::getType(). |
|
Definition at line 117 of file Instruction.h. References getOpcode(). |
|
isCommutative - Return true if the instruction is commutative: Commutative operators satisfy: (x op y) === (y op x) In LLVM, these are the associative operators, plus SetEQ and SetNE, when applied to any type. Definition at line 186 of file Instruction.cpp. References Add(), llvm::ISD::And, Mul(), llvm::ISD::Or, llvm::ISD::SetEQ, llvm::ISD::SetNE, and llvm::ISD::Xor. |
|
isCommutative - Return true if the instruction is commutative: Commutative operators satisfy: (x op y) === (y op x) In LLVM, these are the associative operators, plus SetEQ and SetNE, when applied to any type. Definition at line 138 of file Instruction.h. References getOpcode(). Referenced by isIdenticalBinaryInst(), and llvm::BinaryOperator::swapOperands(). |
|
isIdenticalTo - Return true if the specified instruction is exactly identical to the current one. This means that all operands match and any extra information (e.g. load is volatile) agree. Definition at line 140 of file Instruction.cpp. References llvm::User::getNumOperands(), getOpcode(), llvm::User::getOperand(), and llvm::Value::getType(). Referenced by HoistThenElseCodeToIf(). |
|
isRelational - Return true if the instruction is a Set* instruction: Definition at line 203 of file Instruction.cpp. References llvm::ISD::SetEQ, llvm::ISD::SetGE, llvm::ISD::SetGT, llvm::ISD::SetLE, llvm::ISD::SetLT, and llvm::ISD::SetNE. |
|
isRelational - Return true if the instruction is a Set* instruction: Definition at line 143 of file Instruction.h. References getOpcode(). Referenced by llvm::ConstantFoldBinaryInstruction(), llvm::ConstantExpr::get(), and llvm::ConstantExpr::getTy(). |
|
Definition at line 113 of file Instruction.h. References getOpcode(). |
|
Definition at line 109 of file Instruction.h. |
|
isTrappingInstruction - Return true if the instruction may trap. Definition at line 220 of file Instruction.cpp. References Call, Load, and llvm::ISD::Store. |
|
isTrappingInstruction - Return true if the instruction may trap. Definition at line 149 of file Instruction.h. References getOpcode(). |
|
mayWriteToMemory - Return true if this instruction may modify memory. Reimplemented in llvm::FreeInst, llvm::LoadInst, llvm::StoreInst, llvm::CallInst, and llvm::InvokeInst. Definition at line 62 of file Instruction.h. Referenced by llvm::isInstructionTriviallyDead(). |
|
Definition at line 1214 of file AsmWriter.cpp. References llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), getParent(), and llvm::AssemblyWriter::write(). |
|
print - Implement operator<< on Value... Implements llvm::Value. Definition at line 154 of file Instruction.h. |
|
removeFromParent - This method unlinks 'this' from the containing basic block, but does not delete it. Definition at line 75 of file Instruction.cpp. References llvm::BasicBlock::getInstList(), and getParent(). |
|
Reimplemented from llvm::Value. Definition at line 64 of file Instruction.cpp. References llvm::BasicBlock::getParent(), getParent(), llvm::Function::getSymbolTable(), llvm::Value::hasName(), llvm::SymbolTable::insert(), llvm::SymbolTable::remove(), and llvm::Value::setName(). Referenced by llvm::CloneBasicBlock(), llvm::ConvertExpressionToType(), ConvertOperandToType(), HoistThenElseCodeToIf(), ReplaceCallWith(), and llvm::SimplifyCFG(). |
|
Definition at line 45 of file Instruction.h. |
|
Definition at line 37 of file Instruction.h. |