Robustness due to careful testing and application across many customers

Many of these facilities come as a consistent consequence of the front end being built to top of
DMS.

Parsing

We provide here an example of parsing an extremely difficult bit of code: one of the many dreaded C++ most vexing parses. Here is an example; what is difficult at parse time is determining whether the line in the main program is declaration or an expression.

Classic C++ parsers tangle parsing and symbol table building to try to resolve this during parsing, which is why this is vexing. DMS's C++ front end isolates name resolution from parsing. It instead produces the following parse DAG, which represents the multiple syntactic interpretations of that line as shared subtrees (see lower right corner with crossed arcs). The C++ name resolver later
builds symbol tables
by walking the DAG, propagating constraints across the DAG and deleting the incorrectly-typed subtree, producing the final correct AST.

Control and Data Flow Analysis

Reasoning about C++ programs realistically requires control and data flow anlaysis of the code.
The DMS C++ Front End builds fine-grain control and data flow graphs and makes them available
to a tool builder. The control flow graphs include all semantic primitives of the C++ program, broken out as seperate elements, including (nested) constructor/destructor calls, and the traditional flow through statements and exceptions. It is easy to navigate back and forth from the AST to the control flow graph. The data flow tracks values from point of definition to used, and is attached as additional arcs to the (semantic) control flow nodes produce or consume them.

Orange nodes are the control flow nodes,
orange arcs are control flow arcs,
dashed brown arcs are expression value flows,
and blue arcs are data flow arcs. The altenating regions (tan and white) are regions.

Side effects analysis

The C++ front end provides deep analysis capabilities that can be used to support custom tools.
Knowing the side effects of a method is extremely useful when reasoning about a program.
The following code sample shows the kind of complexity possible in such an analysis:
The side effects are computed by the C++ front end and stored
as inspectable data structures associated with the various semantic elements of the control flow graph.
A debugging utility can dump them.
The side effects reported for foo are:

Your organization may use DMS with the C++ front end to implement and deploy your own custom tools.
The sample tools can be obtained in source form as part of the C++ front end for customization.
Semantic Designs is also willing to build custom tools under contract.

Topics

Semantic Designs- Our Goal

To enable our customers to produce and maintain timely, robust and economical software by providing world-class Software Engineering tools using deep language and problem knowledge with high degrees of automation.