hoshi-lang dev
Yet another programming language
Loading...
Searching...
No Matches
CallGraph Struct Reference

#include <IROptimizer.hpp>

Public Types

using FuncIdentifier = std::pair< indexT, indexT >
 

Public Member Functions

 CallGraph ()=default
 
void addCall (FuncIdentifier caller, FuncIdentifier callee)
 
void traverseGraph ()
 

Public Attributes

yoi::indexT entryModuleIndex {}
 
std::map< FuncIdentifier, std::set< FuncIdentifier > > callGraph
 
std::map< FuncIdentifier, std::set< FuncIdentifier > > callerGraph
 
std::set< FuncIdentifierentryPoints
 
std::set< FuncIdentifierunreachableFunctions
 
std::set< FuncIdentifierfunctions
 

Detailed Description

Definition at line 21 of file IROptimizer.hpp.

Member Typedef Documentation

◆ FuncIdentifier

using FuncIdentifier = std::pair<indexT, indexT>

Definition at line 22 of file IROptimizer.hpp.

Constructor & Destructor Documentation

◆ CallGraph()

CallGraph ( )
default

Member Function Documentation

◆ addCall()

void addCall ( FuncIdentifier  caller,
FuncIdentifier  callee 
)

Definition at line 4326 of file IROptimizer.cpp.

References CallGraph::callerGraph, and CallGraph::callGraph.

Referenced by IROptimizer::buildCallGraph().

Here is the caller graph for this function:

◆ traverseGraph()

void traverseGraph ( )

Definition at line 4388 of file IROptimizer.cpp.

Referenced by IROptimizer::buildCallGraph().

Here is the caller graph for this function:

Member Data Documentation

◆ callerGraph

std::map<FuncIdentifier, std::set<FuncIdentifier> > callerGraph

Definition at line 27 of file IROptimizer.hpp.

Referenced by CallGraph::addCall(), and IROptimizer::performBaseOptimization().

◆ callGraph

std::map<FuncIdentifier, std::set<FuncIdentifier> > callGraph

Definition at line 26 of file IROptimizer.hpp.

Referenced by CallGraph::addCall().

◆ entryModuleIndex

yoi::indexT entryModuleIndex {}

Definition at line 24 of file IROptimizer.hpp.

Referenced by IROptimizer::buildCallGraph().

◆ entryPoints

std::set<FuncIdentifier> entryPoints

Definition at line 28 of file IROptimizer.hpp.

◆ functions

std::set<FuncIdentifier> functions

◆ unreachableFunctions

std::set<FuncIdentifier> unreachableFunctions

Definition at line 29 of file IROptimizer.hpp.

Referenced by IROptimizer::performBaseOptimization().


The documentation for this struct was generated from the following files: