LLVM API Documentation


Public Member Functions | |
| void | MarkBlockExecutable (BasicBlock *BB) |
| void | TrackValueOfGlobalVariable (GlobalVariable *GV) |
| void | AddTrackedFunction (Function *F) |
| void | Solve () |
| bool | ResolvedUndefsIn (Function &F) |
| bool | isBlockExecutable (BasicBlock *BB) const |
| std::map< Value *, LatticeVal > & | getValueMapping () |
| const DenseMap< Function *, LatticeVal > & | getTrackedRetVals () |
| const DenseMap< GlobalVariable *, LatticeVal > & | getTrackedGlobals () |
| void | markOverdefined (Value *V) |
Friends | |
| class | InstVisitor<SCCPSolver> |
Definition at line 140 of file SCCP.cpp.
|
|
AddTrackedFunction - If the SCCP solver is supposed to track calls into and out of the specified function (which cannot have its address taken), this method must be called. Definition at line 205 of file SCCP.cpp. References llvm::StructType::getNumElements(), llvm::Function::getReturnType(), llvm::GlobalValue::hasInternalLinkage(), and LatticeVal. Referenced by IPSCCP::runOnModule(). |
|
|
getTrackedGlobals - Get and return the set of inferred initializers for global variables. Definition at line 245 of file SCCP.cpp. Referenced by IPSCCP::runOnModule(). |
|
|
getTrackedRetVals - Get the inferred return value map. Definition at line 239 of file SCCP.cpp. Referenced by IPSCCP::runOnModule(). |
|
|
getValueMapping - Once we have solved for constants, return the mapping of LLVM values to LatticeVals. Definition at line 233 of file SCCP.cpp. Referenced by SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
Definition at line 227 of file SCCP.cpp. Referenced by SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
MarkBlockExecutable - This method can be used by clients to mark all of the blocks that are known to be intrinsically live in the processed unit. Definition at line 183 of file SCCP.cpp. References DOUT, and llvm::Value::getNameStart(). Referenced by SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
Definition at line 249 of file SCCP.cpp. Referenced by ResolvedUndefsIn(), SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
ResolvedUndefsIn - While solving the dataflow for a function, we assume that branches on undef values cannot reach any of their successors. However, this is not a safe assumption. After we solve dataflow, this method should be use to handle this. If this returns true, the solver should be rerun. Definition at line 1335 of file SCCP.cpp. References llvm::Function::begin(), llvm::DenseSet< ValueT, ValueInfoT >::count(), llvm::Function::end(), llvm::SwitchInst::getCaseValue(), llvm::SwitchInst::getCondition(), llvm::BranchInst::getCondition(), llvm::SwitchInst::getNumSuccessors(), llvm::TerminatorInst::getSuccessor(), llvm::BranchInst::isConditional(), LatticeVal, markOverdefined(), llvm::SwitchInst::setCondition(), and llvm::BranchInst::setCondition(). Referenced by SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
Solve - Solve for constants and executable blocks. Definition at line 1261 of file SCCP.cpp. References llvm::SmallVectorImpl< T >::back(), DOUT, llvm::SmallVectorImpl< T >::empty(), llvm::SmallVectorImpl< T >::pop_back(), llvm::Value::use_iterator, and llvm::InstVisitor< SCCPSolver >::visit(). Referenced by SCCP::runOnFunction(), and IPSCCP::runOnModule(). |
|
|
TrackValueOfGlobalVariable - Clients can use this method to inform the SCCPSolver that it should track loads and stores to the specified global variable if it can. This is only legal to call if performing Interprocedural SCCP. Definition at line 193 of file SCCP.cpp. References llvm::SequentialType::getElementType(), llvm::GlobalVariable::getInitializer(), llvm::GlobalValue::getType(), llvm::Type::isFirstClassType(), and LatticeVal. Referenced by IPSCCP::runOnModule(). |
|
|
|