LLVM API Documentation
This class provides information about the result of a visit. More...
#include <PtrUseVisitor.h>
Public Member Functions | |
PtrInfo () | |
void | reset () |
Reset the pointer info, clearing all state. | |
bool | isAborted () const |
Did we abort the visit early? | |
bool | isEscaped () const |
Is the pointer escaped at some point? | |
Instruction * | getAbortingInst () const |
Get the instruction causing the visit to abort. | |
Instruction * | getEscapingInst () const |
Get the instruction causing the pointer to escape. | |
void | setAborted (Instruction *I=nullptr) |
Mark the visit as aborted. Intended for use in a void return. | |
void | setEscaped (Instruction *I=nullptr) |
Mark the pointer as escaped. Intended for use in a void return. | |
void | setEscapedAndAborted (Instruction *I=nullptr) |
Mark the pointer as escaped, and the visit as aborted. Intended for use in a void return. |
This class provides information about the result of a visit.
After walking all the users (recursively) of a pointer, the basic infrastructure records some commonly useful information such as escape analysis and whether the visit completed or aborted early.
Definition at line 49 of file PtrUseVisitor.h.
llvm::detail::PtrUseVisitorBase::PtrInfo::PtrInfo | ( | ) | [inline] |
Definition at line 51 of file PtrUseVisitor.h.
Instruction* llvm::detail::PtrUseVisitorBase::PtrInfo::getAbortingInst | ( | ) | const [inline] |
Get the instruction causing the visit to abort.
Definition at line 70 of file PtrUseVisitor.h.
References llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::getPointer().
Instruction* llvm::detail::PtrUseVisitorBase::PtrInfo::getEscapingInst | ( | ) | const [inline] |
Get the instruction causing the pointer to escape.
Definition at line 75 of file PtrUseVisitor.h.
References llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::getPointer().
bool llvm::detail::PtrUseVisitorBase::PtrInfo::isAborted | ( | ) | const [inline] |
Did we abort the visit early?
Definition at line 62 of file PtrUseVisitor.h.
References llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::getInt().
Referenced by llvm::PtrUseVisitor< SliceBuilder >::visitPtr().
bool llvm::detail::PtrUseVisitorBase::PtrInfo::isEscaped | ( | ) | const [inline] |
Is the pointer escaped at some point?
Definition at line 65 of file PtrUseVisitor.h.
References llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::getInt().
void llvm::detail::PtrUseVisitorBase::PtrInfo::reset | ( | ) | [inline] |
Reset the pointer info, clearing all state.
Definition at line 54 of file PtrUseVisitor.h.
References llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setInt(), and llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setPointer().
Referenced by llvm::PtrUseVisitor< SliceBuilder >::visitPtr().
void llvm::detail::PtrUseVisitorBase::PtrInfo::setAborted | ( | Instruction * | I = nullptr | ) | [inline] |
Mark the visit as aborted. Intended for use in a void return.
I | The instruction which caused the visit to abort, if available. |
Definition at line 79 of file PtrUseVisitor.h.
References I, llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setInt(), and llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setPointer().
Referenced by setEscapedAndAborted().
void llvm::detail::PtrUseVisitorBase::PtrInfo::setEscaped | ( | Instruction * | I = nullptr | ) | [inline] |
Mark the pointer as escaped. Intended for use in a void return.
I | The instruction which escapes the pointer, if available. |
Definition at line 86 of file PtrUseVisitor.h.
References I, llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setInt(), and llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::setPointer().
Referenced by setEscapedAndAborted(), llvm::PtrUseVisitor< SliceBuilder >::visitCallSite(), llvm::PtrUseVisitor< SliceBuilder >::visitPtrToIntInst(), and llvm::PtrUseVisitor< SliceBuilder >::visitStoreInst().
void llvm::detail::PtrUseVisitorBase::PtrInfo::setEscapedAndAborted | ( | Instruction * | I = nullptr | ) | [inline] |
Mark the pointer as escaped, and the visit as aborted. Intended for use in a void return.
I | The instruction which both escapes the pointer and aborts the visit, if available. |
Definition at line 95 of file PtrUseVisitor.h.
References I, setAborted(), and setEscaped().