Skip to main content

2020 | OriginalPaper | Buchkapitel

RTMLton: An SML Runtime for Real-Time Systems

verfasst von : Bhargav Shivkumar, Jeffrey Murphy, Lukasz Ziarek

Erschienen in: Practical Aspects of Declarative Languages

Verlag: Springer International Publishing

Aktivieren Sie unsere intelligente Suche, um passende Fachinhalte oder Patente zu finden.

search-config
loading …

Abstract

There is a growing interest in leveraging functional programming languages in real-time and embedded contexts. Functional languages are appealing as many are strictly typed, amenable to formal methods, have limited mutation, and have simple, but powerful concurrency control mechanisms. Although there have been many recent proposals for specialized domain specific languages for embedded and real-time systems, there has been relatively little progress on adapting more general purpose functional languages for programming embedded and real-time systems. In this paper we present our current work on leveraging Standard ML in the embedded and real-time domains. Specifically we detail our experiences in modifying MLton, a whole program, optimizing compiler for Standard ML, for use in such contexts. We focus primarily on the language runtime, re-working the threading subsystem and garbage collector. We provide preliminary results over a radar-based aircraft collision detector ported to SML.

Sie haben noch keine Lizenz? Dann Informieren Sie sich jetzt über unsere Produkte:

Springer Professional "Wirtschaft+Technik"

Online-Abonnement

Mit Springer Professional "Wirtschaft+Technik" erhalten Sie Zugriff auf:

  • über 102.000 Bücher
  • über 537 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Maschinenbau + Werkstoffe
  • Versicherung + Risiko

Jetzt Wissensvorsprung sichern!

Springer Professional "Technik"

Online-Abonnement

Mit Springer Professional "Technik" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 390 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Maschinenbau + Werkstoffe




 

Jetzt Wissensvorsprung sichern!

Springer Professional "Wirtschaft"

Online-Abonnement

Mit Springer Professional "Wirtschaft" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 340 Zeitschriften

aus folgenden Fachgebieten:

  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Versicherung + Risiko




Jetzt Wissensvorsprung sichern!

Fußnoten
1
Most real-time systems have a specific set of priorities they support.
 
2
Almost all dynamically allocated arrays are small and fit into one chunk making them O(1) access and large arrays are statically allocated and their size known up front so the O(log(n)) access time can be taken into consideration when validating the system.
 
Literatur
1.
Zurück zum Zitat Arts, T., Benac Earle, C., Derrick, J.: Development of a verified erlang program for resource locking. Int. J. Softw. Tools Technol. Transf. 5(2), 205–220 (2004)CrossRef Arts, T., Benac Earle, C., Derrick, J.: Development of a verified erlang program for resource locking. Int. J. Softw. Tools Technol. Transf. 5(2), 205–220 (2004)CrossRef
2.
Zurück zum Zitat Audebaud, P., Paulin-Mohring, C.: Proofs of randomized algorithms in Coq. Sci. Comput. Program. 74(8), 568–589 (2009). Special Issue on Mathematics of Program Construction (MPC 2006)MathSciNetCrossRef Audebaud, P., Paulin-Mohring, C.: Proofs of randomized algorithms in Coq. Sci. Comput. Program. 74(8), 568–589 (2009). Special Issue on Mathematics of Program Construction (MPC 2006)MathSciNetCrossRef
3.
Zurück zum Zitat Bacon, D.F., Cheng, P., Rajan, V.T.: Controlling fragmentation and space consumption in the metronome, a real-time garbage collector for Java. In: Proceedings of the 2003 ACM SIGPLAN Conference on Language, Compiler, and Tool for Embedded Systems, LCTES 2003, pp. 81–92. ACM, New York (2003) Bacon, D.F., Cheng, P., Rajan, V.T.: Controlling fragmentation and space consumption in the metronome, a real-time garbage collector for Java. In: Proceedings of the 2003 ACM SIGPLAN Conference on Language, Compiler, and Tool for Embedded Systems, LCTES 2003, pp. 81–92. ACM, New York (2003)
4.
Zurück zum Zitat Cheney, C.J.: A nonrecursive list compacting algorithm. Commun. ACM 13(11), 677–678 (1970)CrossRef Cheney, C.J.: A nonrecursive list compacting algorithm. Commun. ACM 13(11), 677–678 (1970)CrossRef
5.
Zurück zum Zitat Deters, M., Cytron, R.K.: Automated discovery of scoped memory regions for real-time Java. In: Proceedings of the 3rd International Symposium on Memory Management, ISMM 2002, pp. 132–142. ACM, New York (2002) Deters, M., Cytron, R.K.: Automated discovery of scoped memory regions for real-time Java. In: Proceedings of the 3rd International Symposium on Memory Management, ISMM 2002, pp. 132–142. ACM, New York (2002)
6.
Zurück zum Zitat Dijkstra, E.W., Lamport, L., Martin, A.J., Scholten, C.S., Steffens, E.F.M.: On-the-fly garbage collection: An exercise in cooperation. Commun. ACM 21(11), 966–975 (1978)CrossRef Dijkstra, E.W., Lamport, L., Martin, A.J., Scholten, C.S., Steffens, E.F.M.: On-the-fly garbage collection: An exercise in cooperation. Commun. ACM 21(11), 966–975 (1978)CrossRef
7.
Zurück zum Zitat Gosling, J., Bollella, G.: The Real-Time Specification for Java. Addison-Wesley Longman Publishing Co., Inc., Boston (2000) Gosling, J., Bollella, G.: The Real-Time Specification for Java. Addison-Wesley Longman Publishing Co., Inc., Boston (2000)
9.
Zurück zum Zitat Hammond, K.: Is it time for real-time functional programming? In: Gilmore, S. (ed.) Revised Selected Papers from the Fourth Symposium on Trends in Functional Programming, TFP 2003, Edinburgh, United Kingdom, 11–12 September 2003. Trends in Functional Programming, vol. 4, pp. 1–18. Intellect (2003) Hammond, K.: Is it time for real-time functional programming? In: Gilmore, S. (ed.) Revised Selected Papers from the Fourth Symposium on Trends in Functional Programming, TFP 2003, Edinburgh, United Kingdom, 11–12 September 2003. Trends in Functional Programming, vol. 4, pp. 1–18. Intellect (2003)
10.
Zurück zum Zitat Hamza, H., Counsell, S.: Region-based RTSJ memory management: State of the art. Sci. Comput. Program. 77(5), 644–659 (2012)CrossRef Hamza, H., Counsell, S.: Region-based RTSJ memory management: State of the art. Sci. Comput. Program. 77(5), 644–659 (2012)CrossRef
11.
Zurück zum Zitat Hughes, J.: Why functional programming matters. Comput. J. 32(2), 98–107 (1989)CrossRef Hughes, J.: Why functional programming matters. Comput. J. 32(2), 98–107 (1989)CrossRef
12.
Zurück zum Zitat JSR 302: Safety Critical Java Technology (2007) JSR 302: Safety Critical Java Technology (2007)
13.
Zurück zum Zitat Kalibera, T., Hagelberg, J., Pizlo, F., Plsek, A., Titzer, B., Vitek, J.: CDX: A family of real-time Java benchmarks. In: Proceedings of the 7th International Workshop on Java Technologies for Real-Time and Embedded Systems, JTRES 2009, pp. 41–50. ACM, New York (2009) Kalibera, T., Hagelberg, J., Pizlo, F., Plsek, A., Titzer, B., Vitek, J.: CDX: A family of real-time Java benchmarks. In: Proceedings of the 7th International Workshop on Java Technologies for Real-Time and Embedded Systems, JTRES 2009, pp. 41–50. ACM, New York (2009)
14.
Zurück zum Zitat Kumar, R., Myreen, M.O., Norrish, M., Owens, S.: CakeML: A verified implementation of ML. In: Proceedings of the 41st ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2014, pp. 179–191. ACM, New York (2014) Kumar, R., Myreen, M.O., Norrish, M., Owens, S.: CakeML: A verified implementation of ML. In: Proceedings of the 41st ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2014, pp. 179–191. ACM, New York (2014)
15.
Zurück zum Zitat Li, M., McArdle, D.E., Murphy, J.C., Shivkumar, B., Ziarek, L.: Adding real-time capabilities to a SML compiler. SIGBED Rev. 13(2), 8–13 (2016)CrossRef Li, M., McArdle, D.E., Murphy, J.C., Shivkumar, B., Ziarek, L.: Adding real-time capabilities to a SML compiler. SIGBED Rev. 13(2), 8–13 (2016)CrossRef
17.
Zurück zum Zitat Milner, R., Tofte, M., Macqueen, D.: The Definition of Standard ML. MIT Press, Cambridge (1997)CrossRef Milner, R., Tofte, M., Macqueen, D.: The Definition of Standard ML. MIT Press, Cambridge (1997)CrossRef
19.
Zurück zum Zitat Murphy, J.C., et al.: A survey of real-time capabilities in functional languages and compilers. Concurr. Comput.: Pract. Exp. 31(4), e4902 (2019)CrossRef Murphy, J.C., et al.: A survey of real-time capabilities in functional languages and compilers. Concurr. Comput.: Pract. Exp. 31(4), e4902 (2019)CrossRef
20.
Zurück zum Zitat Nettles, S., O’Toole, J.: Real-time replication garbage collection. In: Proceedings of the ACM SIGPLAN 1993 Conference on Programming Language Design and Implementation, PLDI 1993, pp. 217–226. ACM, New York (1993) Nettles, S., O’Toole, J.: Real-time replication garbage collection. In: Proceedings of the ACM SIGPLAN 1993 Conference on Programming Language Design and Implementation, PLDI 1993, pp. 217–226. ACM, New York (1993)
21.
Zurück zum Zitat Pizlo, F., Ziarek, L., Blanton, E., Maj, P., Vitek, J.: High-level programming of embedded hard real-time devices. In: Proceedings of the 5th European Conference on Computer Systems, EuroSys 2010, pp. 69–82. , ACM, New York (2010) Pizlo, F., Ziarek, L., Blanton, E., Maj, P., Vitek, J.: High-level programming of embedded hard real-time devices. In: Proceedings of the 5th European Conference on Computer Systems, EuroSys 2010, pp. 69–82. , ACM, New York (2010)
22.
Zurück zum Zitat Pizlo, F., Ziarek, L., Maj, P., Hosking, A.L., Blanton, E., Vitek, J.: Schism: fragmentation-tolerant real-time garbage collection. In: Proceedings of the 2010 ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2010, pp. 146–159. ACM, New York (2010) Pizlo, F., Ziarek, L., Maj, P., Hosking, A.L., Blanton, E., Vitek, J.: Schism: fragmentation-tolerant real-time garbage collection. In: Proceedings of the 2010 ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2010, pp. 146–159. ACM, New York (2010)
23.
Zurück zum Zitat Siebert, F.: Realtime garbage collection in the JamaicaVM 3.0. In: Proceedings of the 5th International Workshop on Java Technologies for Real-Time and Embedded Systems, JTRES 2007, pp. 94–103. ACM, New York (2007) Siebert, F.: Realtime garbage collection in the JamaicaVM 3.0. In: Proceedings of the 5th International Workshop on Java Technologies for Real-Time and Embedded Systems, JTRES 2007, pp. 94–103. ACM, New York (2007)
24.
Zurück zum Zitat Sivaramakrishnan, K.C., Ziarek, L., Jagannathan, S.: MultiMLton: A multicore-aware runtime for standard ML. J. Funct. Program. 24, 613–674 (2014)CrossRef Sivaramakrishnan, K.C., Ziarek, L., Jagannathan, S.: MultiMLton: A multicore-aware runtime for standard ML. J. Funct. Program. 24, 613–674 (2014)CrossRef
27.
Zurück zum Zitat Wan, Z., Taha, W., Hudak, P.: Real-time FRP. In: Proceedings of the Sixth ACM SIGPLAN International Conference on Functional Programming, ICFP 2001, pp. 146–156. ACM, New York (2001) Wan, Z., Taha, W., Hudak, P.: Real-time FRP. In: Proceedings of the Sixth ACM SIGPLAN International Conference on Functional Programming, ICFP 2001, pp. 146–156. ACM, New York (2001)
Metadaten
Titel
RTMLton: An SML Runtime for Real-Time Systems
verfasst von
Bhargav Shivkumar
Jeffrey Murphy
Lukasz Ziarek
Copyright-Jahr
2020
DOI
https://doi.org/10.1007/978-3-030-39197-3_8