Skip to content
0:00 / 0:00

#dalvik#android#virtualmachine

Google I/O 2008 - Dalvik Virtual Machine Internals

Google for Developers

2.6M subscribers • 20 videos on Hallway

YouTube
  • Recommended by 1 person: 1 on Hacker News.
  • Presented by Dan Bornstein, Google
  • Made by the vendor. The company whose product it covers made or sponsored it.
  • May be out of date. Uploaded 18 years ago, in an area where tools change fast.

Advanced. Deep dive for people who know the field.

187K views18 years ago1 recommendation

Systems programmingMobile developmentOperating systemsCompilers and interpretersAndroid and Jetpack Compose

Dan Bornstein explains the design, internals, and bytecode format of the Dalvik virtual machine used in early Android versions.

Dalvik VM Internals Dan Bornstein (Google) Dalvik — the virtual machine with the unusual name — runs your code on Android. Join us to learn about the motivation for its design and get some details about how it works. You'll also walk away with a few tips for how to write code that works well with the platform. Be prepared for a deep dive into technical details. Questions encouraged!

Why it's here

1 person recommends this

What people say. Engineers recommend this talk for its classic explanation of register-based virtual machine design and the DEX format.

yonranon Hacker News • Recommends

On “Android Ported to C#”

Here's Dan Bornstein's talk at Google I/O 2008 about the dex format and the original Dalvik interpreter: link to this video I'm not sure how useful it is in comparing the Dalvik JIT to MonoTouch though.

ttuominenon Hacker News • Mentions

On “Ubuntu for phones”

…and now Ubuntu, your best bet can be to write the portable part in native C or C++, bypassing the Dalvik layer using JNI/NDK. This is apparently the common way to make cross-platform mobile games. On memory consumption: I haven't made any measurements, but the Android .dex bytecode format has been designed with low space requirements in mind. See link to this video . However, all apps run in their own VM process, with lots of common structures shared with them using an initial shared VM process and clever forking. I always thought one of the main original motivations to use Java was because it's so well spread among developers. Since in the early days before the JIT compiler, there must have been a re…

chuboton Hacker News • Mentions

On “Dismissing Python Garbage Collection at Instagram”

This is a great post. I like how they walked through all the steps and especially the "perf" tool. Ruby has a patch to do the same thing -- increase sharing by moving reference counts out of the object itself: Index here: link First post in a long series: link I think these patches or something similar may have made it into Ruby 2.0: link link The Dalvik VM (now replaced by ART) also did this to run on phones with 64 MiB of memory: link to this video I think PHP might do it too. It feels like Python should be doing this as well.

jashmatthewson Hacker News • Mentions

On “Profiling CPython at Instagram (2017)”

There's an experimental branch for Ruby: link Dalvik also uses a register-based bytecode. The early versions of Android needed a more efficient interpreter. Dan Bornstein's talk: link to this video A classic paper on Register vs Stack VMs: link