Skip to main content

CASM-IR: Uniform ASM-Based Intermediate Representation for Model Specification, Execution, and Transformation

  • Conference paper
  • First Online:
Abstract State Machines, Alloy, B, TLA, VDM, and Z (ABZ 2018)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 10817))

Abstract

The Abstract State Machine (ASM) theory is a well-known formal method, which can be used to specify arbitrary algorithms, applications or even whole systems. Over the past years, there have been many approaches to implement concrete ASM-based modeling and specification languages. All of those approaches define their type systems and operator semantics differently in their internal representation, which leads to undesired or unexpected behavior during the modeling, the execution, and code generation of such ASM specifications. In this paper, we present CASM-IR, an Intermediate Representation (IR), designed to aid ASM-based language engineering which is based on a well-formed ASM-based specification format. Moreover, CASM-IR is conceptualized from the ground up to ease the formalization of ASM-based analysis and transformation passes. The feasibility of CASM-IR solving the uniform ASM representation problem is depicted. Based on our CASM-IR implementation, we were able to integrate a front-end of our statically inferred Corinthian Abstract State Machine (CASM) modeling language.

E. Pescosta—Member of CASM organization.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Subscribe and save

Springer+ Basic
$34.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Similar content being viewed by others

Notes

  1. 1.

    For ASM applications of various domains, see: http://web.eecs.umich.edu/gasm.

  2. 2.

    For CASM project website, see: http://casm-lang.org.

  3. 3.

    For CASM concrete syntax description, see: http://casm-lang.org/syntax.

  4. 4.

    For CASM-IR type specification, see: http://casm-lang.org/ir/types.

  5. 5.

    For CASM-IR built-in specification, see: http://casm-lang.org/ir/builtins.

  6. 6.

    For CASM-IR constant specification, see: http://casm-lang.org/ir/constants.

  7. 7.

    For CASM-IR function specification, see: http://casm-lang.org/ir/functions.

  8. 8.

    For CASM-IR instr. specification, see: http://casm-lang.org/ir/instructions.

  9. 9.

    For Asmeta project, see: http://asmeta.sourceforge.net.

  10. 10.

    For EMF project, see: http://eclipse.org/modeling/emf.

  11. 11.

    For CoreASM open-source project, see: http://github.com/coreasm.

  12. 12.

    For AsmL documentation and project, see: http://asml.codeplex.com.

  13. 13.

    For XASM documentation, see http://sourceforge.net/projects/xasm.

  14. 14.

    For CASM open-source project, see: http://github.com/casm-lang.

References

  1. Gurevich, Y.: Evolving Algebras 1993: Lipari Guide - Specification and Validation Methods, pp. 9–36. Oxford University Press Inc., New York (1995)

    Google Scholar 

  2. Gurevich, Y.: Sequential abstract-state machines capture sequential algorithms. ACM Trans. Comput. Logic (TOCL) 1(1), 77–111 (2000)

    Article  MathSciNet  Google Scholar 

  3. Börger, E.: The origins and the development of the ASM method for high level system design and analysis. J. Univ. Comput. Sci. 8(1), 2–74 (2002)

    Google Scholar 

  4. Stärk, R.F., Schmid, J., Börger, E.: Java and the Java Virtual Machine: Definition, Verification, Validation. Springer, Heidelberg (2001). https://doi.org/10.1007/978-3-642-59495-3

    Book  MATH  Google Scholar 

  5. Sasaki, H.: A formal semantics for Verilog-VHDL simulation interoperability by abstract state machine. In: Proceedings of the Conference on Design, Automation and Test in Europe, DATE 1999. ACM, New York (1999)

    Google Scholar 

  6. Lezuo, R.: Scalable translation validation; tools, techniques and framework. Ph.D. thesis, Wien Technische Universität Dissertation (2014)

    Google Scholar 

  7. Barnett, M., Schulte, W.: Spying on components: a runtime verification technique. In: Proceedings of the Workshop on Specification and Verification of Component-Based Systems, SAVCBS 2001, pp. 7–13 (2001)

    Google Scholar 

  8. Glässer, U., Veanes, M.: Universal plug and play machine models. In: Kleinjohann, B., Kim, K.H., Kleinjohann, L., Rettberg, A. (eds.) Design and Analysis of Distributed Embedded Systems. ITIFIP, vol. 91, pp. 21–30. Springer, Boston, MA (2002). https://doi.org/10.1007/978-0-387-35599-3_3

    Chapter  Google Scholar 

  9. Huggins, J.K., Campenhout, D.V.: Specification and verification of pipelining in the ARM2 RISC microprocessor. ACM Trans. Des. Autom. Electron. Syst. (TODAES) 3(4), 563–580 (1998)

    Article  Google Scholar 

  10. Kleppe, A.G.: Software Language Engineering: Creating Domain-Specific Languages using Metamodels. Addisson-Wesley, Boston (2009)

    Google Scholar 

  11. Völter, M.: Generic tools, specific languages. Ph.D. thesis, Delft University of Technology, June 2014

    Google Scholar 

  12. Lezuo, R., Paulweber, P., Krall, A.: CASM - optimized compilation of abstract state machines. In: SIGPLAN/SIGBED Conference on Languages, Compilers and Tools for Embedded Systems (LCTES), pp. 13–22. ACM (2014)

    Google Scholar 

  13. Paulweber, P., Zdun, U.: A model-based transformation approach to reuse and retarget CASM specifications. In: Butler, M., Schewe, K.-D., Mashkoor, A., Biro, M. (eds.) ABZ 2016. LNCS, vol. 9675, pp. 250–255. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-33600-8_17

    Chapter  Google Scholar 

  14. Gurevich, Y., Rossman, B., Schulte, W.: Semantic essence of AsmL: extended abstract. In: de Boer, F.S., Bonsangue, M.M., Graf, S., de Roever, W.-P. (eds.) FMCO 2003. LNCS, vol. 3188, pp. 240–259. Springer, Heidelberg (2004). https://doi.org/10.1007/978-3-540-30101-1_11

    Chapter  Google Scholar 

  15. Farahbod, R., Gervasi, V., Glässer, U.: CoreASM: an extensible ASM execution engine. Fundam. Inf. 77(1–2), 71–104 (2007)

    MathSciNet  MATH  Google Scholar 

  16. Gargantini, A., Riccobene, E., Scandurra, P.: A metamodel-based language and a simulation engine for abstract state machines. J. Univ. Comput. Sci. 14(12), 1949–1983 (2008)

    Google Scholar 

  17. Börger, E., Stärk, R.: Abstract State Machines: A Method for High-Level System Design and Analysis. Springer, Heidelberg (2003). https://doi.org/10.1007/978-3-642-18216-7

    Book  MATH  Google Scholar 

  18. Lattner, C., Adve, V.: LLVM: a compilation framework for lifelong program analysis & transformation. In: Code Generation and Optimization, pp. 75–86. IEEE (2004)

    Google Scholar 

  19. Arcaini, P., Bonfanti, S., Dausend, M., Gargantini, A., Mashkoor, A., Raschke, A., Riccobene, E., Scandurra, P., Stegmaier, M.: Unified Syntax for abstract state machines. In: Butler, M., Schewe, K.-D., Mashkoor, A., Biro, M. (eds.) ABZ 2016. LNCS, vol. 9675, pp. 231–236. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-33600-8_14

    Chapter  Google Scholar 

  20. Anlauff, M.: XASM- an extensible, component-based abstract state machines language. In: Gurevich, Y., Kutter, P.W., Odersky, M., Thiele, L. (eds.) ASM 2000. LNCS, vol. 1912, pp. 69–90. Springer, Heidelberg (2000). https://doi.org/10.1007/3-540-44518-8_6

    Chapter  MATH  Google Scholar 

  21. Lezuo, R., Krall, A.: Using the CASM language for simulator synthesis and model verification. In: Proceedings of the 2013 Workshop on Rapid Simulation and Performance Evaluation: Methods and Tools, p. 6. ACM (2013)

    Google Scholar 

  22. Lezuo, R., Barany, G., Krall, A.: CASM: implementing an abstract state machine based programming language. In: Software Engineering (Workshops), pp. 75–90 (2013)

    Google Scholar 

  23. Schmid, J.: Introduction to AsmGofer. http://www.tydo.de/AsmGofer (2001)

  24. Del Castillo, G.: The ASM workbench: a tool environment for computer-aided analysis and validation of abstract state machine models. In: Margaria, T., Yi, W. (eds.) TACAS 2001. LNCS, vol. 2031, pp. 578–581. Springer, Heidelberg (2001). https://doi.org/10.1007/3-540-45319-9_40

    Chapter  Google Scholar 

  25. Schmid, J.: Compiling abstract state machines to C++. J. Univ. Comput. Sci. 7(11), 1068–1087 (2001)

    Google Scholar 

  26. Bonfanti, S., Carissoni, M., Gargantini, A., Mashkoor, A.: Asm2C++: a tool for code generation from abstract state machines to arduino. In: Barrett, C., Davies, M., Kahsai, T. (eds.) NFM 2017. LNCS, vol. 10227, pp. 295–301. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-57288-8_21

    Chapter  Google Scholar 

  27. Merrill, J.: GENERIC and GIMPLE: a new tree representation for entire functions. In: Proceedings of the 2003 GCC Developers’ Summit, pp. 171–179 (2003)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Philipp Paulweber .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer International Publishing AG, part of Springer Nature

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Paulweber, P., Pescosta, E., Zdun, U. (2018). CASM-IR: Uniform ASM-Based Intermediate Representation for Model Specification, Execution, and Transformation. In: Butler, M., Raschke, A., Hoang, T., Reichl, K. (eds) Abstract State Machines, Alloy, B, TLA, VDM, and Z. ABZ 2018. Lecture Notes in Computer Science(), vol 10817. Springer, Cham. https://doi.org/10.1007/978-3-319-91271-4_4

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-91271-4_4

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-91270-7

  • Online ISBN: 978-3-319-91271-4

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics