The Semantic Layers of Timber

  • Magnus Carlsson
  • Johan Nordlander
  • Dick Kieburtz
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 2895)


We present a three-layered semantics of Timber, a language designed for programming real-time systems in a reactive, object-oriented style. The innermost layer amounts to a traditional deterministic, pure, functional language, around which we formulate a middle layer of concurrent objects, in terms of a monadic transition semantics. The outermost layer, where the language is married to deadline-driven scheduling theory, is where we define message ordering and CPU allocation to actions. Our main contributions are a formalized notion of a time-constrained reaction, and a demonstration of how scheduling theory, process calculii, and the lambda calculus can be jointly applied to obtain a direct and succinct semantics of a complex, real-world programming language with well-defined real-time behavior.


Reactive Layer Functional Layer Lambda Calculus Reaction Rule Process Calculus 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Armstrong, J., Virding, R., Wikström, C., Williams, M.: Concurrent Programming in Erlang. Prentice Hall, Englewood Cliffs (1996)Google Scholar
  2. 2.
    Benveniste, A., Caspi, P., Edwards, S.A., Halbwachs, N., Le Guernic, P., de Simone, R.: The synchronous languages 12 years later. Proceedings of the IEEE 91(1) (January 2003)Google Scholar
  3. 3.
    Dertouzos, M.: Control Robotics: the Procedural Control of Physical Processes. Information Processing 74 (1974)Google Scholar
  4. 4.
    Erkök, L., Launchbury, J.: Recursive monadic bindings. In: Proceedings of the Fifth ACM SIGPLAN International Conference on Functional Programming, ICFP 2000, pp. 174–185. ACM Press, New York (2000)CrossRefGoogle Scholar
  5. 5.
    Henzinger, T.A., Kirsch, C.M.: The embedded machine: Predictable, portable real-time code. In: Proceedings of the ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI (2002)Google Scholar
  6. 6.
    Hughes, J., Pareto, L.: Recursion and dynamic data-structures in bounded space: Towards embedded ML programming. In: International Conference on Functional Programming, pp. 70–81 (1999)Google Scholar
  7. 7.
    Jones, M.P., Carlsson, M., Nordlander, J.: Composed, and in control: Programming the Timber robot (2002),
  8. 8.
    Jones, S.L.P., Reid, A., Henderson, F., Hoare, C.A.R., Marlow, S.: A semantics for imprecise exceptions. In: SIGPLAN Conference on Programming Language Design and Implementation, pp. 25–36 (1999)Google Scholar
  9. 9.
    Kieburtz, R.: Real-time reactive programming for embedded controllers (2001),
  10. 10.
    Milner, R., Tofte, M., Harper, R.: The Definition of Standard ML. MIT Press, Cambridge (1990)Google Scholar
  11. 11.
    Moggi, E., Sabry, A.: An abstract monadic semantics for value recursion. In: Workshop on Fixed Points in Computer Science (2003)Google Scholar
  12. 12.
    Nordlander, J.: Reactive Objects and Functional Programming. Phd thesis, Department of Computer Science, Chalmers University of Technology, Gothenburg (1999)Google Scholar
  13. 13.
    Nordlander, J.: Polymorphic subtyping in O’Haskell. Science of Computer Programming 43(2–3) (2002)Google Scholar
  14. 14.
    Nordlander, J., Carlsson, M.: Reactive Objects in a Functional Language – An escape from the evil “I”. In: Proceedings of the Haskell Workshop, Amsterdam, Holland (1997)Google Scholar
  15. 15.
    Nordlander, J., Jones, M., Carlsson, M., Kieburtz, D., Black, A.: Reactive objects. In: The Fifth IEEE International Symposium on Object-Oriented Real-Time Distributed Computing, ISORC 2002 (2002)Google Scholar
  16. 16.
    Peyton Jones, S., Gordon, A., Finne, S.: Concurrent Haskell. In: ACM Principles of Programming Languages, St Petersburg, FL, pp. 295–308. ACM Press, New York (1996)Google Scholar
  17. 17.
    Peyton Jones, S., et al.: Report on the programming language Haskell 98, a nonstrict, purely functional language (February 1999),
  18. 18.
    Portillo, A.J.R., Hammond, K., Loidl, H.-W., Vasconcelos, P.: Granularity analysis using automatic size and time cost inference. In: Proceedings of IFL 2002 Implementation of Functional Languages, Springer, Heidelberg (2002)Google Scholar
  19. 19.
    Sabry, A.: What is a Purely Functional Language? Journal of Functional Programming 8(1), 1–22 (1998)zbMATHCrossRefMathSciNetGoogle Scholar
  20. 20.
    Serjantov, A., Sewell, P., Wansbrough, K.: The UDP Calculus: Rigorous Semantics for Real Networking. In: Kobayashi, N., Pierce, B.C. (eds.) TACS 2001. LNCS, vol. 2215, p. 535. Springer, Heidelberg (2001)CrossRefGoogle Scholar
  21. 21.
    Stankovich, J. (ed.): Deadline Scheduling for Real-time Systems, EDF and Related Algorithms. Kluwer, Dordrecht (1998)Google Scholar
  22. 22.
    Truv, S.: A new H for real-time programming,
  23. 23.
    Wallace, M., Runciman, C.: Lambdas in the liftshaft - functional programming and an embedded architecture. In: Functional Programming Languages and Computer Architecture, pp. 249–258 (1995)Google Scholar
  24. 24.
    Wan, Z., Taha, W., Hudak, P.: Real-time FRP. In: International Conference on Functional Programming (ICFP 2001), Florence, Italy (September 2001)Google Scholar
  25. 25.
    Wansbrough, K., Norrish, M., Sewell, P., Serjantov, A.: Timing UDP: mechanized semantics for sockets, threads and failures. In: Le Métayer, D. (ed.) ESOP 2002. LNCS, vol. 2305, pp. 278–294. Springer, Heidelberg (2002)CrossRefGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2003

Authors and Affiliations

  • Magnus Carlsson
    • 1
  • Johan Nordlander
    • 2
  • Dick Kieburtz
    • 1
  1. 1.Oregon Health & Science University 
  2. 2.Luleå University of Technology 

Personalised recommendations