class InstructionPrecedenceTracking

Declaration

class InstructionPrecedenceTracking { /* full declaration omitted */ };

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:28

Method Overview

Methods

InstructionPrecedenceTracking(
    llvm::DominatorTree* DT)

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:52

Parameters

llvm::DominatorTree* DT

void clear()

Description

Invalidates all information from this tracking.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:87

const llvm::Instruction*
getFirstSpecialInstruction(
    const llvm::BasicBlock* BB)

Description

Returns the topmost special instruction from the block \p BB. Returns nullptr if there is no special instructions in the block.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:57

Parameters

const llvm::BasicBlock* BB

bool hasSpecialInstructions(
    const llvm::BasicBlock* BB)

Description

Returns true iff at least one instruction from the basic block \p BB is special.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:61

Parameters

const llvm::BasicBlock* BB

void insertInstructionTo(
    const llvm::Instruction* Inst,
    const llvm::BasicBlock* BB)

Description

Notifies this tracking that we are going to insert a new instruction \p Inst to the basic block \p BB. It makes all necessary updates to internal caches to keep them consistent.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:80

Parameters

const llvm::Instruction* Inst
const llvm::BasicBlock* BB

bool isPreceededBySpecialInstruction(
    const llvm::Instruction* Insn)

Description

Returns true iff the first special instruction of \p Insn's block exists and dominates \p Insn.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:65

Parameters

const llvm::Instruction* Insn

virtual bool isSpecialInstruction(
    const llvm::Instruction* Insn) const

Description

A predicate that defines whether or not the instruction \p Insn is considered special and needs to be tracked. Implementing this method in children classes allows to implement tracking of implicit control flow, memory writing instructions or any other kinds of instructions we might be interested in.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:72

Parameters

const llvm::Instruction* Insn

void removeInstruction(
    const llvm::Instruction* Inst)

Description

Notifies this tracking that we are going to remove the instruction \p Inst It makes all necessary updates to internal caches to keep them consistent.

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:84

Parameters

const llvm::Instruction* Inst

virtual ~InstructionPrecedenceTracking()

Declared at: llvm/include/llvm/Analysis/InstructionPrecedenceTracking.h:74