class DDGBuilder

Declaration

class DDGBuilder : public AbstractDependenceGraphBuilder { /* full declaration omitted */ };

Description

Concrete implementation of a pure data dependence graph builder. This class provides custom implementation for the pure-virtual functions used in the generic dependence graph build algorithm. For information about time complexity of the build algorithm see the comments near the declaration of AbstractDependenceGraphBuilder.

Declared at: llvm/include/llvm/Analysis/DDG.h:346

Inherits from: AbstractDependenceGraphBuilder

Method Overview

  • public DDGBuilder(llvm::DataDependenceGraph & G, llvm::DependenceInfo & D, const llvm::AbstractDependenceGraphBuilder<llvm::DataDependenceGraph>::BasicBlockListType & BBs)
  • public bool areNodesMergeable(const llvm::DDGNode & Src, const llvm::DDGNode & Tgt) const
  • public llvm::DDGEdge & createDefUseEdge(llvm::DDGNode & Src, llvm::DDGNode & Tgt)
  • public llvm::DDGNode & createFineGrainedNode(llvm::Instruction & I)
  • public llvm::DDGEdge & createMemoryEdge(llvm::DDGNode & Src, llvm::DDGNode & Tgt)
  • public llvm::DDGNode & createPiBlock(const llvm::AbstractDependenceGraphBuilder<llvm::DataDependenceGraph>::NodeListType & L)
  • public llvm::DDGNode & createRootNode()
  • public llvm::DDGEdge & createRootedEdge(llvm::DDGNode & Src, llvm::DDGNode & Tgt)
  • public const llvm::AbstractDependenceGraphBuilder<llvm::DataDependenceGraph>::NodeListType & getNodesInPiBlock(const llvm::DDGNode & N)
  • public void mergeNodes(llvm::DDGNode & Src, llvm::DDGNode & Tgt)
  • public bool shouldCreatePiBlocks() const
  • public bool shouldSimplify() const

Methods

DDGBuilder(
    llvm::DataDependenceGraph& G,
    llvm::DependenceInfo& D,
    const llvm::AbstractDependenceGraphBuilder<
        llvm::DataDependenceGraph>::
        BasicBlockListType& BBs)

Declared at: llvm/include/llvm/Analysis/DDG.h:348

Parameters

llvm::DataDependenceGraph& G
llvm::DependenceInfo& D
const llvm::AbstractDependenceGraphBuilder< llvm::DataDependenceGraph>:: BasicBlockListType& BBs

bool areNodesMergeable(
    const llvm::DDGNode& Src,
    const llvm::DDGNode& Tgt) const

Description

Return true if the two nodes \pSrcand \pTgtare both simple nodes and the consecutive instructions after merging belong to the same basic block.

Declared at: llvm/include/llvm/Analysis/DDG.h:397

Parameters

const llvm::DDGNode& Src
const llvm::DDGNode& Tgt

llvm::DDGEdge& createDefUseEdge(
    llvm::DDGNode& Src,
    llvm::DDGNode& Tgt)

Description

Create a def-use edge going from \p Src to \p Tgt.

Declared at: llvm/include/llvm/Analysis/DDG.h:369

Parameters

llvm::DDGNode& Src
llvm::DDGNode& Tgt

llvm::DDGNode& createFineGrainedNode(
    llvm::Instruction& I)

Description

Create an atomic node in the graph given a single instruction.

Declared at: llvm/include/llvm/Analysis/DDG.h:357

Parameters

llvm::Instruction& I

llvm::DDGEdge& createMemoryEdge(
    llvm::DDGNode& Src,
    llvm::DDGNode& Tgt)

Description

Create a memory dependence edge going from \p Src to \p Tgt.

Declared at: llvm/include/llvm/Analysis/DDG.h:375

Parameters

llvm::DDGNode& Src
llvm::DDGNode& Tgt

llvm::DDGNode& createPiBlock(
    const llvm::AbstractDependenceGraphBuilder<
        llvm::DataDependenceGraph>::NodeListType&
        L)

Description

Create a pi-block node in the graph representing a group of nodes in an SCC of the graph.

Declared at: llvm/include/llvm/Analysis/DDG.h:363

Parameters

const llvm::AbstractDependenceGraphBuilder< llvm::DataDependenceGraph>::NodeListType& L

llvm::DDGNode& createRootNode()

Description

Create the root node of the graph.

Declared at: llvm/include/llvm/Analysis/DDG.h:351

llvm::DDGEdge& createRootedEdge(
    llvm::DDGNode& Src,
    llvm::DDGNode& Tgt)

Description

Create a rooted edge going from \p Src to \p Tgt .

Declared at: llvm/include/llvm/Analysis/DDG.h:381

Parameters

llvm::DDGNode& Src
llvm::DDGNode& Tgt

const llvm::AbstractDependenceGraphBuilder<
    llvm::DataDependenceGraph>::NodeListType&
getNodesInPiBlock(const llvm::DDGNode& N)

Description

Given a pi-block node, return a vector of all the nodes contained within it.

Declared at: llvm/include/llvm/Analysis/DDG.h:389

Parameters

const llvm::DDGNode& N

void mergeNodes(llvm::DDGNode& Src,
                llvm::DDGNode& Tgt)

Description

Append the content of node \p B into node \p A and remove \p B and the edge between \p A and \p B from the graph.

Declared at: llvm/include/llvm/Analysis/DDG.h:398

Parameters

llvm::DDGNode& Src
llvm::DDGNode& Tgt

bool shouldCreatePiBlocks() const

Description

Return true if creation of pi-blocks are supported and desired, and false otherwise.

Declared at: llvm/include/llvm/Analysis/DDG.h:400

bool shouldSimplify() const

Description

Return true if graph simplification step is requested, and false otherwise.

Declared at: llvm/include/llvm/Analysis/DDG.h:399