LLVM API Documentation
#include <BitcodeReader.h>
Public Member Functions | |
| BitcodeReaderValueList () | |
| ~BitcodeReaderValueList () | |
| DECLARE_TRANSPARENT_OPERAND_ACCESSORS (Value) | |
| Provide fast operand accessors. | |
| unsigned | size () const |
| void | resize (unsigned) |
| void | push_back (Value *V) |
| void | clear () |
| Value * | operator[] (unsigned i) const |
| Value * | back () const |
| void | pop_back () |
| bool | empty () const |
| void | shrinkTo (unsigned N) |
| virtual void | print (std::ostream &) const |
| Constant * | getConstantFwdRef (unsigned Idx, const Type *Ty) |
| Value * | getValueFwdRef (unsigned Idx, const Type *Ty) |
| void | AssignValue (Value *V, unsigned Idx) |
| void | ResolveConstantForwardRefs () |
Definition at line 33 of file BitcodeReader.h.
| llvm::BitcodeReaderValueList::BitcodeReaderValueList | ( | ) | [inline] |
Definition at line 46 of file BitcodeReader.h.
| llvm::BitcodeReaderValueList::~BitcodeReaderValueList | ( | ) | [inline] |
Definition at line 48 of file BitcodeReader.h.
| llvm::BitcodeReaderValueList::DECLARE_TRANSPARENT_OPERAND_ACCESSORS | ( | Value | ) |
Provide fast operand accessors.
| unsigned llvm::BitcodeReaderValueList::size | ( | ) | const [inline] |
Definition at line 56 of file BitcodeReader.h.
References llvm::User::getNumOperands().
Referenced by AssignValue(), back(), getConstantFwdRef(), getValueFwdRef(), and pop_back().
| void BitcodeReaderValueList::resize | ( | unsigned | Desired | ) |
Definition at line 160 of file BitcodeReader.cpp.
References llvm::User::allocHungoffUses(), llvm::User::getNumOperands(), llvm::User::OperandList, and llvm::Use::zap().
Referenced by getConstantFwdRef(), getValueFwdRef(), and push_back().
| void llvm::BitcodeReaderValueList::push_back | ( | Value * | V | ) | [inline] |
Definition at line 58 of file BitcodeReader.h.
References llvm::User::NumOperands, llvm::User::OperandList, and resize().
Referenced by AssignValue().
| void llvm::BitcodeReaderValueList::clear | ( | ) | [inline] |
Definition at line 65 of file BitcodeReader.h.
References llvm::User::dropHungoffUses(), and llvm::User::OperandList.
Referenced by llvm::BitcodeReader::FreeState().
| Value* llvm::BitcodeReaderValueList::back | ( | ) | const [inline] |
| void llvm::BitcodeReaderValueList::pop_back | ( | ) | [inline] |
Definition at line 74 of file BitcodeReader.h.
References llvm::User::NumOperands, llvm::User::setOperand(), and size().
Referenced by shrinkTo().
| bool llvm::BitcodeReaderValueList::empty | ( | ) | const [inline] |
| void llvm::BitcodeReaderValueList::shrinkTo | ( | unsigned | N | ) | [inline] |
| virtual void llvm::BitcodeReaderValueList::print | ( | std::ostream & | ) | const [inline, virtual] |
Definition at line 81 of file BitcodeReader.h.
Definition at line 178 of file BitcodeReader.cpp.
References llvm::CallingConv::C, llvm::User::NumOperands, llvm::User::OperandList, resize(), size(), and V.
Definition at line 197 of file BitcodeReader.cpp.
References llvm::User::NumOperands, llvm::User::OperandList, resize(), size(), and V.
Definition at line 86 of file BitcodeReader.h.
References llvm::User::getOperand(), push_back(), llvm::User::setOperand(), and size().
| void BitcodeReaderValueList::ResolveConstantForwardRefs | ( | ) |
ResolveConstantForwardRefs - Once all constants are read, this method bulk resolves any forward references.
ResolveConstantForwardRefs - Once all constants are read, this method bulk resolves any forward references. The idea behind this is that we sometimes get constants (such as large arrays) which reference *many* forward ref constants. Replacing each of these causes a lot of thrashing when building/reuniquing the constant. Instead of doing this, we look at all the uses and rewrite all the place holders at once for any constant that uses a placeholder.
Definition at line 225 of file BitcodeReader.cpp.
References llvm::Constant::destroyConstant(), E, llvm::ConstantVector::get(), llvm::ConstantStruct::get(), llvm::ConstantArray::get(), llvm::User::getOperand(), llvm::value_use_iterator< UserTy >::getUse(), llvm::User::op_begin(), llvm::User::op_end(), llvm::Value::replaceAllUsesWith(), and llvm::Use::set().