Comparison of application virtualization software: Difference between revisions

Content deleted Content added
Details for Icon programming language
(29 intermediate revisions by 21 users not shown)
Line 1:
{{short description|None}}
{{refimprove|date=October 2011}}
 
{{refimprovemore citations needed|date=October 2011}}
'''Application virtualization software''' refers to both application [[virtual machine]]s and software responsible for implementing them. Application virtual machines are typically used to allow application [[bytecode]] to run portably on many different computer architectures and operating systems. The application is usually run on the computer using an [[Interpreter (computing)|interpreter]] or [[just-in-time compilation]] (JIT). There are often several implementations of a given virtual machine, each covering a different set of functions.
 
==Comparison of virtual machines==
{{Hatnote|[[JavaScript]] machines not included. See [[List of ECMAScript engines]] to find them.}}
 
The table here summarizes elements for which the virtual machine designs are intended to be efficient, not the list of abilities present in any implementation.
 
Line 22 ⟶ 26:
| automatic
| {{yes}}
| {{noyes}}
| {{noyes}}
| {{yes}}
| {{dunno}}
| {{noyes}}
| {{noyes}}
|-
! [[Common Language Runtime]] (CLR)
Line 48 ⟶ 52:
| {{yes}}
| {{yes}}
| {{noyes}}
| {{noyes}}
|-
! [[DotGNU]] [[Portable.NET]]
| [[Stack machine|stack]]
| automatic or manual
| {{noyes}}
| {{noyes}}
| {{yes}}
| {{yes}}
Line 62 ⟶ 66:
| {{no}}
|-
! [[JavaHotSpot (virtual machine)|HotSpot]] ([[Java virtual machine|JVM)]]
| [[Stack machine|stack]]
| automatic
Line 76 ⟶ 80:
| [[Stack machine|stack]]
| automatic
| {{no}}
| {{no}}
| {{yes}}
| {{noyes}}
| {{yes}}
| {{yes}}
| {{dunno}}
| {{noyes}}
| {{noyes}}
|-
! [[LLVM]]
Line 139 ⟶ 143:
| {{yes}}
|-
! [[ErlangBEAM (programmingErlang languagevirtual machine)|BEAM]] ([[Erlang (programming language)|Erlang]])
| [[Register machine|register]]
| automatic
| {{dunno}}
| {{yes}}
| {{yes}}
| {{yes}}
| {{yes}}
| {{yes}}
| {{yes}}
|-
! [[MoarVM]]
| [[Register machine|register]]
| automatic
Line 161 ⟶ 176:
''[[Just-in-time compilation]]'' (JIT), refers to a method of compiling to native instructions at the latest possible time, usually immediately before or during the running of the program. The challenge of JIT is more one of implementation than of virtual machine design, however, modern designs have begun to make considerations to help efficiency. The simplest JIT methods simply compile to a code fragment similar to an offline compiler. However, more complex methods are often employed, which specialize compiled code fragments to parameters known only at runtime (see [[Adaptive optimization]]).
 
''[[Ahead-of-time compilation]]'' (AOT) refers to the more classic method of using ana precompiler to generate a set of native instructions which do not change during the runtime of the program. Because aggressive compiling and optimizing can take time, a precompiled program may launch faster than one which relies on JIT alone for execution. JVM implementations have mitigated this startup cost by initial interpreting to speed launch times, until native code fragments can be generated by JIT.
 
''[[Shared library|Shared libraries]]'' are a facility to reuse segments of native code across multiple running programs. In modern operating systems, this generally means using [[virtual memory]] to share the memory pages containing a shared library across different processes which are protected from each other via [[memory protection]]. It is interesting that aggressive JIT methods such as adaptive optimization often produce code fragments unsuitable for sharing across processes or successive runs of the program, requiring a tradeoff be made between the efficiencies of precompiled and shared code and the advantages of adaptively specialized code. For example, several design provisions of CIL are present to allow for efficient shared libraries, possibly at the cost of more specialized JIT code. The JVM implementation on [[OS X]] uses a Java Shared Archive<ref>[httphttps://developer.apple.com/mac/library/documentation/Java/Conceptual/Java14Development/00-Intro/JavaDevelopment.html Apple docs on OS X use of Java Shared Archive]</ref> to provide some of the benefits of shared libraries.
 
==Comparison of application virtual machine implementations==
Line 172 ⟶ 187:
|-
! [[Virtual machine]]
! [[Programming language|Languages]] executed
! Comments
! [[Interpreter (computing)|Interpreter]]
Line 178 ⟶ 193:
! Implementation language
! [[Source lines of code|SLoC]]
|-
! [[JavaBEAM (Erlang virtual machine)|JVMBEAM]]
| [[JavaErlang (programming language)|JavaErlang]], [[Jython]], [[GroovyElixir (programming language)|GroovyElixir]], [[JRuby]], [[CGleam (programming language)|CGleam]], [[C++]],Cuneiform [[Clojure(programming language)|Cuneiform]], [[ScalaLFE (programming language)|ScalaLFE]], andClojerl, [http://www.is-research.de/info/vmlanguages/ several others]Luerl
| {{yes}}<ref>https://www.erlang.org/blog/a-closer-look-at-the-interpreter/</ref>
| {{yes}}<ref>https://www.erlang.org/blog/a-first-look-at-the-jit/</ref>
|Erlang, C, C++
|1561k including [[Open Telecom Platform|OTP]]
|-
! [[Common Language Runtime]] (CLR)
| [[C Sharp (programming language)|C#]], [[C++/CLI]], [[F Sharp (programming language)|F#]], [[Visual Basic (.NET)|VB.NET]]
| bytecode is [[Common Intermediate Language|CIL]]; [https://github.com/dotnet/coreclr [.NET]] Core Runtime on GitHub]
| {{no}}
| {{yes}}
Line 187 ⟶ 210:
|
|-
! [[Adobe Flash Player]] (aka [[Tamarin (JavaScript enginesoftware)|Tamarin]])
| [[ActionScript]], [[SWF]] (file format)
| interactive web authoring tool.; bytecode is named "''ActionScript Byte Code (.abc)"''
| {{yes}}
| {{yes}}
Line 197 ⟶ 220:
! [[Dis virtual machine|Dis]] ([[Inferno (operating system)|Inferno]])
| [[Limbo (programming language)|Limbo]]
| [http://doc.cat-v.org/inferno/4th_edition/dis_VM_specification Dis Virtual Machine Specification]
| {{yes}}
| {{yes}}
Line 203 ⟶ 226:
| 15k + 2850 per JIT arch + 500 per host OS
|-
! [[DotGNU]]-[[Portable.NET]]
| [[List of CLI languages|CLI languages]] including: [[C Sharp (programming language)|C#]]
| Common Language Runtime clone
Line 211 ⟶ 234:
|
|-
! [[Forth virtual(programming machinelanguage)|Forth]]
| [[Forth (programming language)|Forth]]
| Features are simplified, usually include assembler, compiler, text-level and binary-level interpreters, sometimes editor, debugger and OS.; Compilingcompile speedsspeed areis >20 SKLOC/S, and behavebehaves much like JIT.
| {{yes}}
| {{no}}
Line 235 ⟶ 258:
| C++, OCaml
|
|-
! [[HotSpot (virtual machine)|HotSpot]]
| [[Java (programming language)|Java]], [[Kotlin (programming language)|Kotlin]], [[Jython]], [[Groovy (programming language)|Groovy]], [[JRuby]], [[C (programming language)|C]], [[C++]], [[Clojure]], [[Scala (programming language)|Scala]] and several others
| [http://java.sun.com/javase/[Java Referencevirtual implementationmachine|JVM]] reference implementation by Sun ; [[OpenJDK]]: code under [[GPL]] ; [[IcedTea]]: code and tools under [[GPL]]
| {{yes}}
| {{yes}}
| [[JDK]], [[OpenJDK]] & [[IcedTea]] with regular JIT : Java, C, C++, ASM ; [[IcedTea]] with the "Zero" JIT : Java, C, C++
| JVMHotSpot is around 6500k lines; [[Technology Compatibility Kit|TCK]] is 80k tests and around 1000k lines
|-
! [[Icon (programming language)|Icon]]
| Icon
| Base source code provides both the interpreter as well as an unsupported compile-to-C version. The runtime code, that is shared between the compiler and the interpreter, is written in a variant of C called RTT.
|{{yes}}
|{{no}}
|C, RTT (a custom front-end to C, provided with the base source for Icon).
| ~180k total. (source to bytecode: ~11k, bytecode interpreter: ~46k, iconc: ~23k, common/headers: ~13k, rtt: ~15k)
|-
! [[Java virtual machine|JVM]]
| [[Java (programming language)|Java]], [[Jython]], [[Groovy (programming language)|Groovy]], [[JRuby]], [[C (programming language)|C]], [[C++]], [[Clojure]], [[Scala (programming language)|Scala]] and [http://www.is-research.de/info/vmlanguages/ several others]
| [http://java.sun.com/javase/ Reference implementation] by Sun ; [[OpenJDK]]: code under [[GPL]] ; [[IcedTea]]: code and tools under [[GPL]]
| {{yes}}
| {{yes}}
| [[JDK]], [[OpenJDK]] & [[IcedTea]] with regular JIT : Java, C, ASM ; [[IcedTea]] with the "Zero" JIT : Java, C
| JVM is around 6500k lines; [[Technology Compatibility Kit|TCK]] is 80k tests and around 1000k lines
|-
! [[LLVM]]
| [[C (programming language)|C]], [[C++]], [[Kotlin (programming language)|Kotlin]], [[Objective-C]], [[Swift (programming language)|Swift]], [[Ada (programming language)|Ada]], [[Fortran]], and [[Rust (programming language)|Rust]]
| MSIL, C and C++ output are supported. ActionScript Byte Code output is supported by Adobe Alchemy. bytecode is named "LLVM Bytecode (.bc)". assembly is named "LLVM Assembly Language (*.ll)".
| {{yes}}
| {{yes}}
| C++
| 811k <ref name="ohloh-llvm">[http://www.ohloh.net/p/llvm The LLVM Compiler Infrastructure] {{Webarchive|url=https://web.archive.org/web/20120731043158/http://www.ohloh.net/p/llvm |date=2012-07-31}}, ohloh.net, 2011 NovNovember 30</ref>
|-
! [[Lua (programming language)|Lua]]
Line 264 ⟶ 287:
|
| {{yes}}
| [http://luajit.org/ LuaJIT]
| C
| 13k + 7k LuaJIT
Line 277 ⟶ 300:
|-
! [[Mono (software)|Mono]]
| [[List of CLI languages|CLI languages]] including: [[C Sharp (programming language)|C#]], [[Visual Basic (.NET)|VB.NET]], [[IronPython]], [[IronRuby]], and others
| Common Language Runtime clone
| {{yes}}
Line 283 ⟶ 306:
| C#, C
| 2332k
|-
! [[Oz (programming language)|Oz]]
| Oz, [[Alice (programming language)|Alice]]
|-
! [[NekoVM]]
Line 299 ⟶ 314:
| C
| 46k
|-
! [[Oz (programming language)|Oz]]
| Oz, [[Alice (programming language)|Alice]]
|-
! [[O-code machine]]
Line 311 ⟶ 334:
| [[Pascal (programming language)|Pascal]]
| UCSD Pascal, widespread in late 70s including Apple II
|{{yes}}
| {{no}}
|assembly, Pascal
|
|-
! [[Parrot virtual machine|Parrot]]
| Perl ([[Perl#2000–present|Perl 6|65]] &, [[Perl#2000–presentRaku (programming language)|5Raku]]), NQP-rx, [[Parrot intermediary language|PIR]], [[Parrot assembly language|PASM]], [[bytecode|PBC]], [[BASIC]], [[bc (programming language)|bc]], [[C99]], [[ECMAScript]], [[Lisp (programming language)|Lisp]], [[Lua (programming language)|Lua]], [[GNU m4|m4]], [[Tcl]], [[WMLScript]], [[Simple API for XML#XML processing with SAX|XML]], and others
|
| {{yes}}
Line 336 ⟶ 359:
|
| {{yes}}
| {{ubl|[[Psyco]]|[[Unladen Swallow]]}}
| C
| 387k&nbsp;C, 368k&nbsp;Python, 10k&nbsp;ASM, 31k&nbsp;Psyco
Line 342 ⟶ 365:
! [[PyPy]]
| [[Python (programming language)|Python]]
| [[Self-hosting (compilers)|Self-hosting]] implementation of Python, next generation of [[Psyco]]
| {{yes}}
| {{yes}}
Line 357 ⟶ 380:
|-
! [[Silverlight]]
| [[C Sharp (programming language)|C#]], [[Visual Basic (.NET)|VB.NET]]
| A Micro-version of Microsoft [[.NET Framework]] to let applications run sandboxed inside browser
| {{yes}}
| {{yes}}
| C++
| 7MB (initiallyfirst releasedrelease)
|-
! [[ScummVM]]
Line 406 ⟶ 429:
! [[Squeak]]
| Squeak [[Smalltalk]]
| [[Self-hosting (compilers)|Self hosting]] implementation of Squeak virtual machine. Rich multi-media support.
| {{yes}}
| {{yes|Cog [http://www.mirandabanda.org/cog/] & Exupery}}
| Smalltalk/[http://wiki.squeak.org/squeak/2267 Slang]
| 110k Smalltalk, ~300K C
|-
![[SWI-Prolog]]
|Prolog: [[SWI-Prolog]], [[YAP (Prolog)|YAP]]
| {{yes}}
| {{no}}
| C, SWI-Prolog
|-
! [[TraceMonkey]]
| JavaScript
| Based on [[Tamarin (JavaScript enginesoftware)|Tamarin]]
| {{no}}
| {{yes}}
Line 486 ⟶ 517:
 
==See also==
{{div col}}
* [[Application virtualization]]
* [[Language binding]]
Line 494 ⟶ 526:
* [[Application binary interface]] (ABI)
* [[Comparison of platform virtualization software]]
* [[Comparison of Java virtual machines]]
* [[List of Java virtual machines]]
* [[List of ECMAScript engines]]
* [[List of application servers]]
* [[WebAssembly]]
{{div col end}}
 
==References==
{{Reflist}}
 
==External links==
*[http://lists.gnu.org/archive/html/dotgnu-libjit/2004-05/index.html "libJIT vs LLVM discussion" Rhys Weatherley (libJIT) and Chris Lattner (LLVM)]
*[http://java-virtual-machine.net/other.html List of Java virtual machines (JVMs), Java Development Kits (JDKs), Java Runtime Environments (JREs)]
 
[[Category:Software comparisons|application virtualization software]]