java virtual machine

DVM vs. JVM

Objectives :

  • What is DVM?
  • What is Dalvik Virtual Machine?
  • What is JVM?
  • What is Java Virtual Machine?
  • What are the differences between DVM & JVM?
  • What are the differences between Dalvik Virtual Machine & Java Virtual Machine?

 

DVM (Dalvik Virtual Machine)

JVM (Java Virtual Machine)

It is Register based which is designed to run on low memory.

It is Stack based.

DVM uses its own byte code and runs “.Dex” file. From Android 2.2 SDK Dalvik has got a Just in Time compiler

JVM uses java byte code and runs “.class” file having JIT (Just In Time).

DVM has been designed so that a device can run multiple instances of the VM efficiently. Applications are given their own instance.

Single instance of JVM is shared with multiple applications.

DVM supports Android operating system only.

JVM supports multiple operating systems.

For DVM very few Re-tools are available.

For JVM many Re-tools are available.

There is constant pool for every application.

It has constant pool for every class.

Here the executable is APK.

Here the executable is JAR.

 

What is Android?

Android Logo

Android Logo

Basically, Android is an Operating System (OS) for mobile devices such as Mobile phones, tablet computers, PDAs, E-Book readers, TVs, Set-Top Boxes, etc. But, it is not yet another OS, but a component based OS.

In Android, it has an integrated Java Virtual Machine (JVM) called as Dalvik Virtual Machine (DVM). In Android, System interfaces are exposed only through Java libraries. Since Android supports Java, anybody who knows at least basics of Java can learn Android application development very easily provided the object oriented programming (OOPs) concept must be cleared.

Android is based on the 2.6 Linux Kernel.

The Android logo represents the stylized robot.

An Android SDK is provided to let developers build applications on top of the OS but not extend the OS itself.

Image Source : Wikipedia.org