Author Topic: Why cannot you run standard Java bytecode on Android?  (Read 155 times)

Offline mechanic

  • Engineer
  • Hero Engineer
  • *****
  • Posts: 2594
    • View Profile
    • Engineering Forum
Question: Why cannot you run standard Java bytecode on Android?

Answer:
Android uses Dalvik Virtual Machine (DVM) which requires a special bytecode. We need to convert Java class files into Dalvik Executable files using an Android tool called "dx". In normal circumstances, developers will not be using this tool directly and build tools will care for the generation of DVM compatible files.