Decreasing your Coffee Consumption by Incremental Code (Re)generation

Touluse, France, June 25, 2015     Dr. Ráth István Zoltán, Dr. Horváth Ákos, Dr. Hegedüs Ábel     Share

As a result, code generation could be completed in seconds instead of hours or minutes after user edits.

Nowadays, model sizes (in UML, AUTOSAR, etc.) are easily getting into the range of millions of EObjects in an embedded system development process as reported by many partners of the PolarSys open source initiative. As a result, executing simple tasks like source code regeneration after small user changes may consume significant time. Scaling up code generation to such an extent requires to divert from traditional batch execution strategies to incremental processing.

Incrementality means that model processing reacts to changes in the model and executes actions only on the “dirty” target model elements using explicit traceability links between the target and the source models. As a result, code generation could be completed in seconds instead of hours or minutes after user edits. Unfortunately, incremental support varies significantly in existing open source model processing technologies like Xtend, ATL, QVT or EMF-IncQuery. 

Our talk is built around a live demo on a sample transformation scenario taken from an ongoing project with Ericsson aiming to support code generation for executable UML.

The highlights of the talk are the following:

  • Incremental regeneration. We demonstrate how different levels of incrementality can be supported for defining model translation starting from a traditional batch transformation (e.g., in Xtend) to a fine-grained model-to-model (one-way) synchronization (e.g., on top of EMF-IncQuery).
  • Fine-grained traceability. We highlight how fine-grained traceability can be easily defined between the source and target languages to drive the specification of the transformation rules.
  • Impact analysis. We show how change impact analysis can be provided on the target language to support activities like incremental regression/unit testing or incremental validation.
  • Pros/Cons of different implementations. We evaluate several model query and transformation technologies such as Xtend, EMF-IncQuery, etc. and discuss how their advantages can be combined to support incremental code generation. We also compare runtime performance and memory consumption characteristics of different incremental model transformation variants from an end-user’s viewpoint.

The technology presented in this talk is the result of a collaboration between IncQuery Labs Ltd., Ericsson and the Fault Tolerant Systems Research Group of the Budapest University of Technology and Economics.

Open in Youtube

    Presentation     EMF-IncQuery     EclipseCon     Eclipse     AUTOSAR