Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8186945
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T02:23:47+00:00 2026-06-07T02:23:47+00:00

My understanding is that Google didn’t like Oracle’s licensing policy for using the JRE

  • 0

My understanding is that Google didn’t like Oracle’s licensing policy for using the JRE in Java ME so it just rewrote
it using its own JVM specification that mimics the JRE but behaves a little bit differently, especially when it comes
to making things more efficient and more secure.

So, if my understanding is correct, it means that when javac is ran on some Java source code and compiled into “binary”
byetcode, a compliant JVM will interpret that bytecode different than Dalvik will (in some cases). This is the inherent
difference between Dalvik and other (compliant) JVMs.

If anything I have said so far is incorrect, please begin by correcting me!

Now, if Android came with its own compiler (which it might), and compiled Java source in a different (Dalvik-compliant)
manner than javac, then I could understand how some code (not compiled with the Android SDK) would not run on an
Android device:

MySource.java --> javac --> MySource.class (JRE-compliant) --> JVM --> running Java app
MySource.java --> android-compiler --> MySource.class (Dalvik-compliant) --> Dalvik JVM --> running Android app

However, it looks like you use javac to compile Android apps!?!? So it looks like we have this:

MySource.java --> javac --> MySource.class (JRE-compliant) --> JVM --> running Java app
MySource.java --> javac --> MySource.class (JRE-compliant) --> Dalvik JVM --> running Android app (???)

If javac is used to compile all sources into bytecode, then why is it that Dalvik can’t run some types
of Java code?

I asked a very similar question yesterday and although it was technically answered (after re-reading my question
I see I was simply not specific enough) no one was able to explain what it is that’s inherent to Dalvik that
makes it impossible to run Java code from projects like Google Guice or Apache Camel. I was told that in order to get Camel to run on Dalvik, that I would have to get Camel’s source and then it would have to be “built with the Android SDK”, but I couldn’t get clarity on what that meant or implied.

With Camel, for instance, you have this (simplified):

RouteBuilder.java --> javac --> RouteBuilder.class --> jartool --> camel-context-2.9.jar --> JVM --> running Camel ESB
RouteBuilder.java --> javac --> RouteBuilder.class --> jartool --> camel-context-2.9.jar --> Dalvik JVM --> doesn't work !!! (???)

Clearly, something is happening inside the Dalvik JVM that prevents it from running certain types of Java code.
I’m trying to understand what types of Java code will not run when “fed” into the Dalvik JVM.

Edit: In before “but Camel 3.0 will run on Android!” I know – not my question!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T02:23:49+00:00Added an answer on June 7, 2026 at 2:23 am

    I’m trying to understand what types of Java code will not run when "fed" into the Dalvik JVM.

    Dalvik JVM differs from other JVMs in following aspects:

    • It uses special DEX format for storing applications binaries vs. JAR
      and Pack200 formats used by standard Java virtual machines. Google
      claims that DEX results in smaller binaries than JAR. I think they
      could use Pack200 with the same success, but they decided to go their
      own way in this aspect

    • Dalvik JVM was optimized for running multiple JVM processes
      simultaneously

    • Dalvik JVM uses register-based architecture vs. stack based
      architecture of other JVMs with intent to speed up execution and
      to reduce binary sizes

    • It uses its own instructions set (not a standard JVM bytecode)

    • One can run (if needed) several independent Android applications
      within a single JVM process

    • Application execution can span across several Dalvik JVM processes
      “naturally”. To support this it
      adds:

    • Special object serialization mechanism based on Parcel and Parcelable
      classes. Functionally it serves the same purpose as standard Java
      Serializable, but results in smaller data footprint and is potentially more lenient towards differences in versions of classes

    • Special Android way to execute inter process calls (IPC) based on
      Android Interface Definition Language (AIDL)

    • Until Android 2.2 Dalvik JVM did not support JIT compilation which
      adversely impacted Android application performance. Adding it in 2.2
      improves markedly execution speed for often used applications

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Understanding that I should probably just dig into the source to come up with
EDIT: java equivalent to php's hmac-SHA1 (well hopefully, trying a.t.m.) My understanding is that
My understanding is that Google Analytics (the tool I'd normally use for website analytics)
It's my understanding that Google App Engine with Google Web Toolkit has a client
It is my understanding that two unequal objects can have the same hashcode. How
It's my understanding that in Spring, all objects are treated by default as singletons.
It's my understanding that all three of these lines below should return an ARRAY
It is my understanding that a texture atlas is basically a single texture that
So it's my understanding that on a ReaderWriterLock (or ReaderWriterLockSlim more specifically), both the
It is my understanding that although Mercurial has support from branches, the community generally

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.