SOM: Simple Object Machine, logo
A minimal Smalltalk for teaching of and research on Virtual Machines.

SOM Language Example

Try SOM in a REPL Fibonacci = ( "defines a subclass of Object" fib: n = ( "defines the fib method with the argument n" ^ n <= 1 ifTrue: 1 ifFalse: [ self fib: (n - 1) + (self fib: (n - 2)) ] ) )
A simple class implementing #fib: to compute the fibonacci numbers.
For more, see the standard library

JsSOM Read-Eval-Print Loop

SOM Shell.
--->
Note, this REPL does accepts only simple expressions and does not allow to define classes or methods.
However, the complete standard library is available.

Key Characteristics

  • 9 main implementations
  • clarity of implementation over absolute performance
  • support for common language features such as objects, classes, closures, non-local returns, and primitives
  • support for classic benchmarks: DeltaBlue, Richards, Benchmark Game, ...
  • implementation variations include:
    • abstract-syntax-tree-based or bytecode-based
    • classic interpreter optimizations
    • green and native threading
    • reference counting, mark/sweep, and generational garbage collectors
  • implementations ranging from 2.5k LOC to 8k LOC

Performance

Boxplot, performance comparison of SOM implementations.
Performance of some of the SOM implementations compared to Java.
Based on data from May 2014, using DeltaBlue, Fannkuch, Mandelbrot, and Richards as benchmarks.

Use in Teaching and Research: A Brief Chronology

A brief and incomplete list of papers and universities where SOM has been used in the past.

Facultad de Ciencias Exactas y Naturales - Universidad de Buenos Aires, logo

TruffleMATE, a SOM variant with the Mate Metaobject protocol, which enables fully reflective execution environments.

Publication

Building Efficient and Highly Run-time Adaptable Virtual Machines.
Chari, Guido; Garbervetsky, Diego; and Marr, Stefan.
Proceedings of the 12th Symposium on Dynamic Languages (2016), PDF.

Publication

Cross-Language Compiler Benchmarking: Are We Fast Yet?
Marr, Stefan; Daloze, Benoit; and Mössenböck, Hanspeter.
Proceedings of the 12th Symposium on Dynamic Languages (2016), PDF, HTML.

IBM logo

In 2016, the J9 team used their new JitBuilder to speed up SOM++ by 3x-4x. JitBuilder is an API for the J9 just-in-time compiler, which is going to be open sourced as part of the Eclipse OMR project.

IBM logo

In 2015, the J9 team announced the plans to open source the platform underlying their JVM implementation. As part of their JavaOne talk “What's in an Object? Java Garbage Collection for the Polygot”, they used CSOM as a case study to show how their garbage collector can be integrated into an existing VM.

Johannes Kepler University Linz, logo

SOMNS, a Newspeak variant with full support for actor concurrency was developed as a platform for research on the interaction of concurrency models.

Publication

Tracing vs. Partial Evaluation: Comparing Meta-Compilation Approaches for Self-Optimizing Interpreters.
Marr, Stefan; and Ducasse, Stéphane.
Proceedings of the 2015 ACM International Conference on Object Oriented Programming Systems Languages & Applications, ACM, (2015), PDF, HTML.

Publication

Zero-Overhead Metaprogramming: Reflection and Metaobject Protocols Fast and without Compromises.
Marr, Stefan; Seaton, Chris; and Ducasse, Stéphane.
Proceedings of the 36th ACM SIGPLAN Conference on Programming Language Design and Implementation, ACM, (2015), doi: 10.1145/2737924.2737963, PDF, HTML.

Publication

Are We There Yet? Simple Language-Implementation Techniques for the 21st Century.
Marr, Stefan; Pape, Tobias; and De Meuter, Wolfgang.
IEEE Software 31, no. 5 (2014): 60-67, doi: 10.1109/MS.2014.98, PDF, HTML.

Software Languages Lab, Vrije Universiteit Brussel, logo

The SOM variants were used for a number of experiments such as ActorSOM, a SOM with a event-loop concurrency model similar to AmbientTalk.

Heinrich Heine Universität Düsseldorf, logo

SOM++ was optimized and extended with a generational garbage collector as part of a master's thesis.

Publication

CSOM/PL: A Virtual Machine Product Line.
Haupt, Michael; Marr, Stefan and Hirschfeld, Robert.
Journal of Object Technology 10, no. 12 (2011): 1-30, doi: 10.5381/jot.2011.10.1.a12, PDF.

Publication

Type Harvesting: A Practical Approach to Obtaining Typing Information in Dynamic Programming Languages.
Haupt, Michael; Perscheid, Michael and Hirschfeld, Robert.
Proceedings of the 2011 ACM Symposium on Applied Computing, 2011, doi: 10.1145/1982185.1982464, URL.

Publication

Virtual Machine Support for Many-Core Architectures: Decoupling Abstract From Concrete Concurrency Models.
Marr, Stefan; Haupt, Michael; Timbermont, Stijn; Adams, Bram; D'Hondt, Theo; Costanza, Pascal and De Meuter, Wolfgang.
Second International Workshop on Programming Languages Approaches to Concurrency and Communication-cEntric Software, York, UK, 2010, doi: 10.4204/EPTCS.17.6, URL.

Publication

The SOM Family: Virtual Machines for Teaching and Research.
Haupt, Michael; Hirschfeld, Robert; Pape, Tobias; Gabrysiak, Gregor; Marr, Stefan; Bergmann, Arne; Heise, Arvid; Kleine, Matthias and Krahn, Robert. Proceedings of the 15th Annual Conference on Innovation and Technology in Computer Science Education (ITiCSE), 2010, doi: 10.1145/1822090.1822098, PDF.

Technische Universität Darmstadt, logo

In 2010, SOM was used by Michael Haupt to teach one graduate course at Technische Universität Darmstadt (Germany).

Publication

NXTalk: Dynamic Object-oriented Programming in a Constrained Environment.
Beck, Martin; Haupt, Michael and Hirschfeld, Robert. Proceedings of the International Workshop on Smalltalk Technologies, 2009, doi: 10.1145/1735935.1735942, PDF.

Hasso Plattner Institute, logo

SOM was used by Michael Haupt between 2007–2009 to teach a course on Virtual Machines at the Hasso Plattner Institute in Potsdam. Many of the feature variants of CSOM for instance support for Smalltalk images, threads, and garbage collection have been developed as part of course work. (more)

Lancaster University logo

In 2006, SOM was used by Michael Haupt to teach one undergraduate course at Lancaster University (UK).

Publication

Related to SOM, at least in syntax and spirit:
Design, implementation, and evaluation of the Resilient Smalltalk embedded platform.
Andersen, Jakob R.; Bak, Lars; Grarup, Steffen; Lund, Kasper V.; Eskildsen, Toke; Hansen, Klaus Marius and Torgersen, Mads.
Computer Languages, Systems & Structures 31, no. 3–4 (2005): 127–141, doi: 10.1016/j.cl.2005.02.003.

Aarhus University (logo)

SOM was originally implemented at the University of Århus in Denmark by Jakob Roland Andersen, Kasper Verdich Lund, Lars Bak, Mads Torgersen, and Ulrik Pagh Schultz in 2001/2002. It was used for teaching object-oriented VMs and came with the original version of the SOM Smalltalk libraries, test suites, and benchmarks.