ACM Home Page
Please provide us with feedback. Feedback
Analyzing the performance of code-copying virtual machines
Full text PdfPdf (987 KB)
Source
Conference on Object Oriented Programming Systems Languages and Applications archive
Proceedings of the 23rd ACM SIGPLAN conference on Object-oriented programming systems languages and applications table of contents
Nashville, TN, USA
SESSION: Performance table of contents
Pages 403-422  
Year of Publication: 2008
ISBN:978-1-60558-215-3
Also published in ...
Authors
Gregory B. Prokopski  McGill University, Sable Research Group, Montreal, PQ, Canada
Clark Verbrugge  McGill University, Sable Research Group, Montreal, PQ, Canada
Sponsors
SIGPLAN: ACM Special Interest Group on Programming Languages
ACM: Association for Computing Machinery
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 41,   Downloads (12 Months): 190,   Citation Count: 0
Additional Information:

abstract   references   index terms   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/1449764.1449796
What is a DOI?

ABSTRACT

Many popular programming languages use interpreter-based execution for portability, supporting dynamic or reflective properties, and ease of implementation. Code-copying is an optimization technique for interpreters that reduces the performance gap between interpretation and JIT compilation, offering significant speedups over direct-threading interpretation. Due to varying language features and virtual machine design, however, not all languages benefit from codecopying to the same extent. We consider here properties of interpreted languages, and in particular bytecode and virtual machine construction that enhance or reduce the impact of code-copying. We implemented code-copying and compared performance with the original direct-threading virtual machines for three languages, Java (SableVM), OCaml, and Ruby (Yarv), examining performance on three different architectures, ia32 (Pentium 4), x86_64 (AMD64) and PowerPC (G5). Best speedups are achieved on ia32 by OCaml (maximum 4.88 times, 2.81 times on average), where a small and simple bytecode design facilitates improvements to branch prediction brought by code-copying. Yarv only slightly improves over direct-threading; large working sizes of bytecodes, and a relatively small fraction of time spent in the actual interpreter loop both limit the application of codecopying and its overall net effect. We are able to show that simple ahead of time analysis of VM and execution properties can help determine the suitability of code-copying for a particular VM before an implementation of code-copying is even attempted.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
David Bélanger. SableJIT: A retargetable just-in-time compiler. Master's thesis, McGill University, August 2004.
 
2
3
 
4
 
5
 
6
Debian Shootout. http://shootout.alioth.debian.org/.
 
7
8
 
9
 
10
 
11
M. Anton Ertl, Christian Thalinger, and Andreas Krall. Superinstructions and replication in the Cacao JVM interpreter. Journal of .NET Technologies, 4:25--32, 2006. ISSN 1801-2108.
 
12
 
13
14
 
15
 
16
 
17
OCaml. http://caml.inria.fr.
 
18
OProfile. http://oprofile.sf.net/.
19
20
21
 
22
 
23
Gregory B. Prokopski and Clark Verbrugge. Towards GCC as a compiler for multiple VMs. In GCC Developers' Summit, 2007.
 
24
Gregory B. Prokopski and Clark Verbrugge. Compilerguaranteed safety in code-copying virtual machines. In Compiler Construction, 17th International Conference, LNCS. Springer, 2008. to appear.
 
25
Gregory B. Prokopski, Etienne M. Gagnon, and Christian Arcand. Bytecode testing framework for SableVM code-copying engine. Technical Report SABLETR-2007-9, Sable Research Group, School of Computer Science, McGill University, Montréal, Québec, Canada, September 2007.
 
26
Raw results used for this publication. http://www.sable.mcgill.ca/~gproko/gcc/multi-08-raw-results.pdf.
 
27
Markku Rossi and Kengatharan Sivalingam. A survey of instruction dispatch techniques for byte-code interpreters. Technical Report TKO-C79, Faculty of Information Technology, Helsinki Univeristy of Technology, May 1996.
28
 
29
Standard Performance Evaluation Corporation. SPEC JVM98 Benchmarks. http://www.spec.org/jvm98.
30
 
31
 
32
 
33
 
34
Benjamin Vitale and Mathew Zaleski. Alternative dispatch techniques for the tcl vm interpreter. In Proceedings of 12th Annual Tcl/Tk Conference, October 2005.
 
35

Collaborative Colleagues:
Gregory B. Prokopski: colleagues
Clark Verbrugge: colleagues