40 #define DEBUG_TYPE "objc-arc-expand" 53 bool doInitialization(
Module &M)
override;
69 "objc-arc-expand",
"ObjC ARC expansion",
false,
false)
72 return new ObjCARCExpand();
75 void ObjCARCExpand::getAnalysisUsage(
AnalysisUsage &AU)
const {
79 bool ObjCARCExpand::doInitialization(
Module &M) {
100 LLVM_DEBUG(
dbgs() <<
"ObjCARCExpand: Visiting: " << *Inst <<
"\n");
114 Value *
Value = cast<CallInst>(Inst)->getArgOperand(0);
Pass interface - Implemented by all 'passes'.
static PassRegistry * getPassRegistry()
getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...
This class represents lattice values for constants.
A Module instance is used to store all the information related to an LLVM module. ...
objc_autoreleaseReturnValue
inst_iterator inst_begin(Function *F)
objc_retainAutoreleasedReturnValue
bool EnableARCOpts
A handy option to enable/disable all ARC Optimizations.
void replaceAllUsesWith(Value *V)
Change all uses of this to point to a new Value.
bool ModuleHasARC(const Module &M)
Test if the given module looks interesting to run ARC optimization on.
static bool runOnFunction(Function &F, bool PostInlining)
Pass * createObjCARCExpandPass()
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
Represent the analysis usage information of a pass.
FunctionPass class - This class is used to implement most global optimizations.
ARCInstKind GetBasicARCInstKind(const Value *V)
Determine which objc runtime call instruction class V belongs to.
INITIALIZE_PASS(ObjCARCExpand, "objc-arc-expand", "ObjC ARC expansion", false, false) Pass *llvm
void setPreservesCFG()
This function should be called by the pass, iff they do not:
raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
StringRef getName() const
Return a constant reference to the value's name.
objc_retainAutoreleaseReturnValue
LLVM Value Representation.
inst_iterator inst_end(Function *F)
void initializeObjCARCExpandPass(PassRegistry &)