# ParparVM Optimizations: Java on iOS now 2.8x Faster

DevFeed: [ParparVM Optimizations: Java on iOS now 2.8x Faster](<https://devfeed.tech/articles/parparvm-optimizations-java-on-ios-now-2-8x-faster-19425.md>)

Original publisher: [Read original article](<https://www.codenameone.com/blog/parparvm-optimizations-compiling-java-for-ios/>)

Author: Steve Hannah

Published: 2017-02-13T00:00:00Z

Content type: article

Language: en

Sources: [CodeName One](<https://devfeed.tech/sources/codename-one.md>)

Topics: [Java](<https://devfeed.tech/topics/java.md>), [Compiler](<https://devfeed.tech/topics/compiler.md>), [iOS](<https://devfeed.tech/topics/ios.md>), [Development](<https://devfeed.tech/topics/development.md>), [C](<https://devfeed.tech/topics/c.md>), [LLVM](<https://devfeed.tech/topics/llvm.md>)

Tags: [build](<https://devfeed.tech/tags/build.md>), [c](<https://devfeed.tech/tags/c.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [concurrent](<https://devfeed.tech/tags/concurrent.md>), [ios](<https://devfeed.tech/tags/ios.md>), [java](<https://devfeed.tech/tags/java.md>), [llvm](<https://devfeed.tech/tags/llvm.md>), [performance](<https://devfeed.tech/tags/performance.md>), [profiling](<https://devfeed.tech/tags/profiling.md>)

## AI overview

The article explains the history and optimization of ParparVM, Codename One's ahead-of-time compiler for building Java apps on iOS. It reports that recent improvements make ParparVM up to 2.8 times faster and produce binaries 15%-20% smaller, while describing its use of Apple's toolchain, generated Xcode projects, and a concurrent mark-sweep garbage collector.

## Source excerpt

TLDR: ParparVM is now up to 2.8x faster, and produces binaries that are 15%-20% smaller than before. If you build your app for iOS today, you may notice a performance boost due to some improvements to ParparVM - the AOT compiler we use to build Codename One apps for iOS. Read on for a short history of ParparVM, as well as some details about these improvements. A Brief History Of ParparVM In the beginning, Codename One used XMLVM to build apps for iOS. It worked by converting Java byte-codes into its own XML representation, and then converting that XML into C-code. Unfortunately XMLVM was an academic project, and was announced in 2014 that development on it would be discontinued. We were faced with a choice. Do we continue to use XMLVM and simply support it ourselves, or do we migrate to something else. At the time RoboVM was an exciting new technology that compiled Java to LLVM and could produce iOS apps. I had also created a proof of concept port using Avian, an AOT compiler for Java that could produce iOS binaries. A fourth option, which seemed overly ambitious at the time, was to create our own tool from scratch. Ultimately, that is the avenue that was chosen, and ParparVM was born.