Dataflow Software Stack  032db78
Master Thesis of Mathijs Saey at the VUB
 All Classes Namespaces Files Functions Variables Pages
Functions | Variables
backEnd.DVM.literals Namespace Reference

IGR Literal removal. More...

Functions

def isLit
 See if a node only contains literals. More...
 
def getInputs
 Get all the literal inputs of a node. More...
 
def createOpStr
 Create a DIS program to execute a single operation. More...
 
def createCallStr
 Create a DIS program to execute a single function call. More...
 
def transformNode
 Add the result of executing a node to all it's outputs. More...
 
def propagateLit
 Calculate the value of a literal and propagate it to the next nodes. More...
 
def checkCall
 See if a call can be reduced to a constant. More...
 
def checkNode
 See if a node can be removed, do so if possible. More...
 
def checkFunctionGraph
 See if we can remove a graph from the program. More...
 
def checkCompoundGraphs
 See if we need to convert a subgraph to a constant. More...
 
def removeLiterals
 Remove all operations that have predefined inputs. More...
 

Variables

tuple log = logging.getLogger(__name__)
 

Detailed Description

IGR Literal removal.

This module defines a few traversals that remove literals from the IGR where possible.

Function Documentation

def backEnd.DVM.literals.isLit (   node)

See if a node only contains literals.

def backEnd.DVM.literals.getInputs (   node)

Get all the literal inputs of a node.

def backEnd.DVM.literals.createOpStr (   node)

Create a DIS program to execute a single operation.

def backEnd.DVM.literals.createCallStr (   node)

Create a DIS program to execute a single function call.

def backEnd.DVM.literals.transformNode (   node,
  value 
)

Add the result of executing a node to all it's outputs.

def backEnd.DVM.literals.propagateLit (   node)

Calculate the value of a literal and propagate it to the next nodes.

def backEnd.DVM.literals.checkCall (   node)

See if a call can be reduced to a constant.

If possible, propagate.

def backEnd.DVM.literals.checkNode (   node)

See if a node can be removed, do so if possible.

def backEnd.DVM.literals.checkFunctionGraph (   subGraph)

See if we can remove a graph from the program.

def backEnd.DVM.literals.checkCompoundGraphs (   node)

See if we need to convert a subgraph to a constant.

def backEnd.DVM.literals.removeLiterals ( )

Remove all operations that have predefined inputs.

Variable Documentation

tuple backEnd.DVM.literals.log = logging.getLogger(__name__)