Abstract
DynSem is a domain-specific language for concise specification of the dynamic semantics of programming languages, aimed at rapid experimentation and evolution of language designs. To maintain a short definition-to-execution cycle, DynSem specifications are meta-interpreted. Meta-interpretation introduces runtime overhead that is difficult to remove by using interpreter optimization frameworks such as the Truffle/Graal Java tools; previous work has shown order-of-magnitude improvements from applying Truffle/Graal to a meta-interpreter, but this is still far slower than what can be achieved with a language-specific interpreter. In this paper, we show how specifying the meta-interpreter using scope graphs, which encapsulate static name binding and resolution information, produces much better optimization results from Truffle/Graal. Furthermore, we identify that JIT compilation is hindered by large numbers of calls between small polymorphic rules and we introduce rule cloning to derive larger monomorphic rules at run time as a countermeasure. Our contributions improve the performance of DynSem-derived interpreters to within an order of magnitude of a handwritten language-specific interpreter.
Original language | English |
---|---|
Title of host publication | 33rd European Conference on Object-Oriented Programming, ECOOP 2019 |
Editors | Alastair F. Donaldson |
Publisher | Schloss Dagstuhl- Leibniz-Zentrum fur Informatik GmbH, Dagstuhl Publishing |
Pages | 4:1-4:30 |
Number of pages | 30 |
Volume | 134 |
ISBN (Electronic) | 9783959771115 |
DOIs | |
Publication status | Published - 1 Jul 2019 |
Event | 33rd European Conference on Object-Oriented Programming, ECOOP 2019 - London, United Kingdom Duration: 15 Jul 2019 → 19 Jul 2019 |
Conference
Conference | 33rd European Conference on Object-Oriented Programming, ECOOP 2019 |
---|---|
Country/Territory | United Kingdom |
City | London |
Period | 15/07/19 → 19/07/19 |
Keywords
- Definitional interpreters
- Partial evaluation