Android Virtual Machine Davlik

Source: Internet
Author: User

The Dalvik virtual machine is a major part of Google's Android platform for mobile devices. Virtual machines can run Java platform applications that are converted into a compact Dalvik executable format (. dex), which is suitable for systems with memory and processor speed limitations.

The author of the Dalvik virtual machine is Dambernstein (Dan Bornstein).

Unlike most virtual machines and real Java virtual machines, the former is a stack machine, and the Dalvik VM is a register-based architecture. Like the argument between CISC and RISC, the relative merits of these two approaches are a topic of constant debate, and sometimes the technical boundaries become blurred. In addition, the relative advantages of the two methods depend on the interpretation/compilation strategy chosen. However, in general, stack-based machines must use instructions to load data on the stack or manipulate the data using instructions, so more instructions are required than register-based machines. However, the instructions in the Register must encode the source and destination registers, so often the instructions are larger.

A tool called DX, which converts a Java. class file into the. dex format. Multiple class files can be included in a single. dex file. Duplicate strings that can be used for multiple classes and other constants are output to reserved space when converted to. dex format. Java bytecode can also be converted to an optional, Delvik VM-used instruction set. An uncompressed. dex file is often smaller in file size than a. jar file that is compressed from the same. class file.

When the Dalvik executable is installed on a mobile device, they can be modified. For further optimizations, the byte order in some data, simple data structures, and inline libraries can be interchanged, such as empty objects being shorted.

To optimize for low memory requirements, Dalvik virtual machines have unique features that are distinct from other standard virtual machines:

(1) Virtual machine is small, the use of space is small;
(2) Dalvik no JIT compiler;
(3) The constant pool has been modified to use only 32-bit indexes to simplify the interpreter;
(4) It uses its own byte code, not Java bytecode.

In addition, Dalvik is designed to meet the many virtual machine instances that can be run efficiently.

Dalvik the location of the virtual machine in the Android architecture

Android Virtual Machine Davlik

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.