Quick fixing ATL transformations with speculative analysis


Model transformations are central components of most model-based software projects. While ensuring their correctness is vital to guarantee the quality of the solution, current transformation tools provide limited support to statically detect and fix errors. In this way, the identification of errors and their correction are nowadays mostly manual activities which incur in high costs. The aim of this work is to improve this situation. Recently, we developed a static analyser that combines program analysis and constraint solving to identify errors in ATL model transformations. In this paper, we present a novel method and system that uses our analyser to propose suitable quick fixes for ATL transformation errors, notably some non-trivial, transformation-specific ones. Our approach supports speculative analysis to help developers select the most appropriate fix by creating a dynamic ranking of fixes, reporting on the consequences of applying a quick fix, and providing a pre-visualization of each quick fix application. The approach integrates seamlessly with the ATL editor. Moreover, we provide an evaluation based on existing faulty transformations built by a third party, and on automatically generated transformation mutants, which are then corrected with the quick fixes of our catalogue.

This is a preview of subscription content, access via your institution.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12


  1. 1.


  2. 2.

    http://www.eclipse.org/atl/usecases/, some of these transformations originated from industrial projects.

  3. 3.

    In ATL, a helper is an auxiliary query operation.

  4. 4.


  5. 5.

    We have fixed Listing 1 for this figure.

  6. 6.

    In practice, it is more natural to consider lazy/called rules as operations.

  7. 7.

    The transformation does define two attribute helpers in the context of Activity and ActivityPartition, but not a one-parameter helper at the module level.

  8. 8.


  9. 9.

    We are not yet able to precisely determine in which circumstances the solver behaves correctly and in which not. Thus, we notify the user that the analysis is not completely reliable.


  1. 1.

    Abraham, R., Erwig, M.: GoalDebug: a spreadsheet debugger for end users. In: ICSE, pp. 251–260. IEEE Computer Society (2007)

  2. 2.

    Arendt, T., Biermann, E., Jurack, S., Krause, C., Taentzer, G.: Henshin: advanced concepts and tools for in-place EMF model transformations. In: MoDELS, vol. 6394 of LNCS, pp. 121–135. Springer, Berlin (2010)

  3. 3.

    Brun, Y, Holmes, R, Ernst, M.D., Notkin ,D.: Speculative analysis: exploring future development states of software. In: FoSER, pp. 59–64. ACM (2010)

  4. 4.

    Cabot, J., Clarisó, R., Guerra, E., de Lara, J.: Synthesis of OCL pre-conditions for graph transformation rules. In: ICMT, vol. 6142 of LNCS, pp. 45–60. Springer, Berlin (2010)

  5. 5.

    Cibran, M.A.: Translating BPMN models into UML activities. In: Business Process Management Workshops, pp. 236–247. Springer, Berlin (2009)

  6. 6.

    Cohen, W., Ravikumar, P., Fienberg, S.: A comparison of string metrics for matching names and records. In: KDD Workshop on Data Cleaning and Object Consolidation vol. 3, pp. 73–78 (2003)

  7. 7.

    Deckwerth, F., Varró, G.: Attribute handling for generating preconditions from graph constraints. In: ICGT, vol. 8571 of LNCS, pp. 81–96. Springer, Berlin (2014)

  8. 8.

    Demarco, F., Xuan, J, Berre, D.L., Monperrus, M.: Automatic repair of buggy if conditions and missing preconditions with SMT. In: CSTVA, pp. 30–39. ACM (2014)

  9. 9.

    Ferrante, J., Ottenstein, K.J., Warren, J.D.: The program dependence graph and its use in optimization. ACM Trans. Program. Lang. Syst. 9(3), 319–349 (1987)

    Article  MATH  Google Scholar 

  10. 10.

    Guerra, E., de Lara, J., Wimmer, M., Kappel, G., Kusel, A., Retschitzegger, W., Schönböck, J., Schwinger, W.: Automated verification of model transformations based on visual contracts. Autom. Softw. Eng. 20(1), 5–46 (2013)

    Article  Google Scholar 

  11. 11.

    Guerra, E., Soeken, M.: Specification-driven model transformation testing. Softw. Syst. Model. 14(2), 623–644 (2015)

    Article  Google Scholar 

  12. 12.

    Hegedüs, Á., Horváth, Á., Ráth, I., Branco, M. C., Varró, D.: Quick fix generation for DSMLs. In: VL/HCC, pp. 17–24. IEEE (2011)

  13. 13.

    Jeffrey, D., Feng, M., Gupta, N., Gupta, R.: BugFix: a learning-based tool to assist developers in fixing bugs. In: ICPC, pp. 70–79. IEEE Computer Society (2009)

  14. 14.

    Jézéquel, J.-M., Barais, O., Fleurey, F.: Model driven language engineering with kermeta. In GTTSE’09, vol. 6491 of LNCS, pp. 201–221. Springer, Berlin (2011)

  15. 15.

    Jouault, F., Allilaire, F., Bézivin, J., Kurtev, I.: ATL: a model transformation tool. Sci. Comput. Program. 72(1), 31–39 (2008)

    MathSciNet  Article  MATH  Google Scholar 

  16. 16.

    Kaleeswaran, S., Tulsian, V., Kanade, A., Orso, A.: MintHint: automated synthesis of repair hints. In: ICSE, pp. 266–276. ACM (2014)

  17. 17.

    Köhler, C., Lewin, H., Taentzer, G.: Ensuring containment constraints in graph-based model transformation approaches. In: ECEASST vol. 6 (2007)

  18. 18.

    Kolovos, D.S., Paige, R.F., Polack, F.: The epsilon transformation language. In: ICMT, vol. 5063 of LNCS, pp. 46–60. Springer, Berlin (2008)

  19. 19.

    Kuhlmann, M., Hamann, L., Gogolla, M.: Extensive validation of OCL models by integrating SAT solving into USE. In: TOOLS (49), vol. 6705 of LNCS, pp. 290–306. Springer, Berlin (2011)

  20. 20.

    Kusel, A., Schwinger, W., Wimmer, M., Retschitzegger, W.: Common pitfalls of using QVT relations - graphical debugging as remedy. In: ICECCS, pp. 329–334. IEEE (2009)

  21. 21.

    Le Goues, C., Dewey-Vogt, M., Forrest, S., Weimer, W.: A systematic study of automated program repair: fixing 55 out of 105 bugs for $8 each. In: ICSE, pp. 3–13. IEEE (2012)

  22. 22.

    Le Goues, C., Forrest, S., Weimer, W.: Current challenges in automatic software repair. Softw. Qual. J. 21(3), 421–443 (2013)

    Article  Google Scholar 

  23. 23.

    Le Goues, C., Nguyen, T., Forrest, S., Weimer, W.: Genprog: a generic method for automatic software repair. IEEE TSE 38(1), 54–72 (2012)

    Google Scholar 

  24. 24.

    Logozzo, F., Ball, T.: Modular and verified automatic program repair. In: OOPSLA, pp. 133–146. ACM (2012)

  25. 25.

    Martinez, M., Monperrus, M.: Mining software repair models for reasoning on the search space of automated program fixing. Empir. Softw. Eng. 20(1), 176–205 (2015)

    Article  Google Scholar 

  26. 26.

    Martinez, M., Weimer, W., Monperrus, M.: Do the fix ingredients already exist? An empirical inquiry into the redundancy assumptions of program repair approaches. In: ICSE, pp. 492–495. ACM (2014)

  27. 27.

    Muntean, P., Kommanapalli, V., Ibing, A., Eckert, C.: Automated generation of buffer overflow quick fixes using symbolic execution and SMT. In: SAFECOMP, vol. 9337 of LNCS, pp. 441–456. Springer, Berlin (2015)

  28. 28.

    Muslu, K., Brun, Y., Holmes, R., Ernst, M.D., Notkin, D.: Speculative analysis of integrated development environment recommendations. In: OOPSLA, pp. 669–682. ACM (2012)

  29. 29.

    Pei, Y., Furia, C.A., Nordio, M., Wei, Y., Meyer, B., Zeller, A.: Automated fixing of programs with contracts. IEEE TSE 40(5), 427–449 (2014)

    Google Scholar 

  30. 30.

    Perkins, J.H., Kim, S., Larsen, S., Amarasinghe, S.P., Bachrach, J., Carbin, M., Pacheco, C., Sherwood, F., Sidiroglou, S., Sullivan, G., Wong, W., Zibin, Y., Ernst, M.D., Rinard, M.C.: Automatically patching errors in deployed software. In: SOSP, pp. 87–102. ACM (2009)

  31. 31.

    Proksch, S., Amann, S., Mezini, M.: Towards standardized evaluation of developer-assistance tools. In: RSSE, pp. 14–18. ACM (2014)

  32. 32.

    QVT. http://www.omg.org/spec/QVT/

  33. 33.

    Rahim, L.A., Whittle, J.: A survey of approaches for verifying model transformations. Softw. Syst. Model. 14(2), 1003–1028 (2015)

    Article  Google Scholar 

  34. 34.

    Robillard, M.P., Walker, R.J., Zimmermann, T.: Recommendation systems for software engineering. IEEE Softw. 27(4), 80–86 (2010)

    Article  Google Scholar 

  35. 35.

    Sánchez Cuadrado, J., Guerra, E., de Lara, J.: Uncovering errors in ATL model transformations using static analysis and constraint solving. In: ISSRE, pp. 34–44. IEEE (2014)

  36. 36.

    Sánchez Cuadrado, J., Guerra, E.,  de Lara, J.: Quick fixing ATL model transformations. In: MoDELS, pp. 146–155. IEEE (2015)

  37. 37.

    Varró, D., Balogh, A.: The model transformation language of the viatra2 framework. Sci. Comput. Program. 68(3), 214–234 (2007)

    MathSciNet  Article  MATH  Google Scholar 

  38. 38.

    Weimer, W., Nguyen, T., Le Goues, C., Forrest, S.: Automatically finding patches using genetic programming. In: ICSE, pp. 364–374. IEEE (2009)

  39. 39.

    Wimmer, M., Kappel, G., Kusel, A., Retschitzegger, W., Schönböck, J., Schwinger, W.: Right or wrong?—verification of model transformations using colored petri nets. In: DSM (2009)

  40. 40.

    Wimmer, M., Perez, S., Jouault, F., Cabot, J.: A catalogue of refactorings for model-to-model transformations. JOT 11(2), 1–40 (2012)

    Google Scholar 

Download references


Work supported by the Spanish Ministry of Economy and Competitivity (TIN2014-52129-R), the R&D programme of the Madrid Region (S2013/ICE-3006), and the EU commission (FP7-ICT-2013-10, #611125).

Author information



Corresponding author

Correspondence to Jesús Sánchez Cuadrado.

Additional information

Communicated by Dr. Jordi Cabot and Alexander Egyed.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Cuadrado, J.S., Guerra, E. & de Lara, J. Quick fixing ATL transformations with speculative analysis. Softw Syst Model 17, 779–813 (2018). https://doi.org/10.1007/s10270-016-0541-1

Download citation


  • Model transformation
  • ATL
  • Transformation static analysis
  • Quick fixes
  • Speculative analysis