23 #ifndef LLVM_LIB_TRANSFORMS_OBJCARC_OBJCARC_H
24 #define LLVM_LIB_TRANSFORMS_OBJCARC_OBJCARC_H
53 Value *OldArg = cast<CallInst>(CI)->getArgOperand(0);
61 isa<ConstantPointerNull>(OldArg))) &&
62 "Can't delete non-forwarding instruction with users!");
80 if (
const auto *
C = dyn_cast<CallInst>(Opnd))
SymbolTableList< Instruction >::iterator eraseFromParent()
This method unlinks 'this' from the containing basic block and deletes it.
const Value * stripPointerCasts() const
Strip off pointer casts, all-zero GEPs, and aliases.
bool IsNoopOnNull(ARCInstKind Class)
Test if the given class represents instructions which do nothing if passed a null pointer...
bool IsForwarding(ARCInstKind Class)
Test if the given class represents instructions which return their argument verbatim.
objc_retainAutoreleasedReturnValue
void replaceAllUsesWith(Value *V)
Change all uses of this to point to a new Value.
Value * getOperand(unsigned i) const
bool RecursivelyDeleteTriviallyDeadInstructions(Value *V, const TargetLibraryInfo *TLI=nullptr)
If the specified value is a trivially dead instruction, delete it.
This file defines common analysis utilities used by the ObjC ARC Optimizer.
ARCInstKind GetBasicARCInstKind(const Value *V)
Determine which objc runtime call instruction class V belongs to.
static void EraseInstruction(Instruction *CI)
Erase the given instruction.
static const Instruction * getreturnRVOperand(const Instruction &Inst, ARCInstKind Class)
If Inst is a ReturnRV and its operand is a call or invoke, return the operand.
ARCInstKind
Equivalence classes of instructions in the ARC Model.
Module.h This file contains the declarations for the Module class.
LLVM_NODISCARD std::enable_if<!is_simple_type< Y >::value, typename cast_retty< X, const Y >::ret_type >::type dyn_cast(const Y &Val)
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
LLVM Value Representation.