LLVM  mainline
Classes | Namespaces | Enumerations | Functions | Variables
ObjCARC.h File Reference
#include "llvm/ADT/StringSwitch.h"
#include "llvm/ADT/Optional.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/Analysis/Passes.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/IR/CallSite.h"
#include "llvm/IR/InstIterator.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
#include "llvm/Transforms/ObjCARC.h"
#include "llvm/Transforms/Utils/Local.h"
#include "ARCInstKind.h"
Include dependency graph for lib/Transforms/ObjCARC/ObjCARC.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  llvm::objcarc::ARCMDKindCache
 A cache of MDKinds used by various ARC optimizations. More...

Namespaces

namespace  llvm
 

List of target independent CodeGen pass IDs.


namespace  llvm::objcarc

Enumerations

enum  llvm::objcarc::ARCMDKindID { llvm::objcarc::ImpreciseRelease, llvm::objcarc::CopyOnEscape, llvm::objcarc::NoObjCARCExceptions }

Functions

static bool llvm::objcarc::ModuleHasARC (const Module &M)
 Test if the given module looks interesting to run ARC optimization on.
static const Value * llvm::objcarc::GetUnderlyingObjCPtr (const Value *V, const DataLayout &DL)
 This is a wrapper around getUnderlyingObject which also knows how to look through objc_retain and objc_autorelease calls, which we know to return their argument verbatim.
static const Value * llvm::objcarc::GetRCIdentityRoot (const Value *V)
static Value * llvm::objcarc::GetRCIdentityRoot (Value *V)
static Value * llvm::objcarc::GetArgRCIdentityRoot (Value *Inst)
 Assuming the given instruction is one of the special calls such as objc_retain or objc_release, return the RCIdentity root of the argument of the call.
static bool llvm::objcarc::IsNullOrUndef (const Value *V)
static bool llvm::objcarc::IsNoopInstruction (const Instruction *I)
static void llvm::objcarc::EraseInstruction (Instruction *CI)
 Erase the given instruction.
static bool llvm::objcarc::IsPotentialRetainableObjPtr (const Value *Op)
 Test whether the given value is possible a retainable object pointer.
static bool llvm::objcarc::IsPotentialRetainableObjPtr (const Value *Op, AliasAnalysis &AA)
static ARCInstKind llvm::objcarc::GetCallSiteClass (ImmutableCallSite CS)
 Helper for GetARCInstKind. Determines what kind of construct CS is.
static bool llvm::objcarc::IsObjCIdentifiedObject (const Value *V)
 Return true if this value refers to a distinct and identifiable object.

Variables

bool llvm::objcarc::EnableARCOpts
 A handy option to enable/disable all ARC Optimizations.

Detailed Description

This file defines common definitions/declarations used by the ObjC ARC Optimizer. ARC stands for Automatic Reference Counting and is a system for managing reference counts for objects in Objective C.

WARNING: This file knows about certain library functions. It recognizes them by name, and hardwires knowledge of their semantics.

WARNING: This file knows about how certain Objective-C library functions are used. Naive LLVM IR transformations which would otherwise be behavior-preserving may break these assumptions.

Definition in file lib/Transforms/ObjCARC/ObjCARC.h.