public class CfgSwitchSequenceBackend extends CfgEmptyVisitor
The HDL parser backend that optimises sequences
of control flow graph CfgModel
model
CfgSwitchStatement
switch nodes. A sequence can be treated as nested switch statements
and as sequential switch statements. Switch nodes must contain conditions of the following form:
x == const_1 || ... || x == const_n
, and only the x
must be used
in every node of the sequences to be transformed.
ModelVisitor.Status
Constructor and Description |
---|
CfgSwitchSequenceBackend()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
onProcessBegin(ModuleProcess process)
Starts visiting
ModuleProcess node. |
void |
onProcessEnd(ModuleProcess process)
Finishes visiting
ModuleProcess node. |
void |
onSwitchBegin(CfgSwitchStatement switchNode)
Starts visiting
CfgSwitchStatement node. |
onAssertBegin, onAssertEnd, onBlockBegin, onBlockEnd, onCaseBegin, onCaseEnd, onLoopBegin, onLoopEnd, onSwitchEnd, onWaitBegin, onWaitEnd
getStatus, onModelBegin, onModelEnd, onModuleBegin, onModuleEnd, onRootBegin, onRootEnd, onStatementBegin, onStatementEnd
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getStatus, onModelBegin, onModelEnd, onModuleBegin, onModuleEnd, onRootBegin, onRootEnd, onStatementBegin, onStatementEnd
public void onProcessBegin(ModuleProcess process)
ModelVisitor
ModuleProcess
node.onProcessBegin
in interface ModelVisitor
onProcessBegin
in class ModelEmptyVisitor
process
- Process node to be visited.public void onProcessEnd(ModuleProcess process)
ModelVisitor
ModuleProcess
node.onProcessEnd
in interface ModelVisitor
onProcessEnd
in class ModelEmptyVisitor
process
- Process node to be visited.public void onSwitchBegin(CfgSwitchStatement switchNode)
CfgVisitor
CfgSwitchStatement
node.onSwitchBegin
in interface CfgVisitor
onSwitchBegin
in class CfgEmptyVisitor
switchNode
- Switch statement to be visited.