Explain how a basic block is represented using dag?
Answers
Answered by
0
THE DAG REPRESENTATION FOR BASIC BLOCKS
• A DAG for a basic block is a directed acyclic graph with the following labels on nodes:
1. Leaves are labeled by unique identifiers, either variable names or constants.
2. Interior nodes are labeled by an operator symbol.
3. Nodes are also optionally given a sequence of identifiers for labels to store the computed values.
• DAGs are useful data structures for implementing transformations on basic blocks.
• It gives a picture of how the value computed by a statement is used in subsequent statements.
• It provides a good way of determining common sub - expressions.
• A DAG for a basic block is a directed acyclic graph with the following labels on nodes:
1. Leaves are labeled by unique identifiers, either variable names or constants.
2. Interior nodes are labeled by an operator symbol.
3. Nodes are also optionally given a sequence of identifiers for labels to store the computed values.
• DAGs are useful data structures for implementing transformations on basic blocks.
• It gives a picture of how the value computed by a statement is used in subsequent statements.
• It provides a good way of determining common sub - expressions.
Similar questions
Math,
8 months ago
Science,
8 months ago
Math,
8 months ago
Hindi,
1 year ago
Psychology,
1 year ago