 <p>The JVM is a stack-based virtual machine. <a href="http://vmkit.llvm.org" rel="nofollow">VMKit</a> was an open-source project of LLVM which implemented a JVM with a LLVM backend. The idea of VMKit was to create a toolkit for building virtual machines (or managed runtime environments) such as JVM, CLI/CLR, R's runtime etc. To find out more, see <a href="http://vmkit.llvm.org/publications/thesis.html" rel="nofollow">Nicolas Geoffray's PhD thesis</a>. While the project is retired, <a href="http://llvm.org/viewvc/llvm-project/vmkit/trunk/" rel="nofollow">the source code is still available</a>.</p> <p>Also, Microsoft have released <a href="https://github.com/dotnet/llilc/" rel="nofollow">llilc</a> which is a LLVM JIT compiler for IL/MSIL/CIL (which could be argued is a stack machine). The JIT code <a href="https://github.com/dotnet/llilc/tree/master/lib/Jit" rel="nofollow">can be found here</a>.</p>