We know that Dalvik uses APK, DEX, and ODEX files. And we know this abbreviation means via AOSP source or Developers site.
(like this - https://source.android.com/devices/tech/dalvik/dex-format.html)
- DEX means Dalvik EXcutable file.
- ODEX means Optimized Dalvik EXcutable file.
- APK means Android PacKage.
ART (Android RunTime) uses OAT and ART, but they do not explain the meaning anywhere.
Does anyone know the meaning of these shortened words?
It’s Of Ahead Time, a silly reordering of Ahead Of Time. We went with that because then we say that process of converting .dex
files to .oat
files would be called quakerizing and that would be really funny.
OAT is a file format produced by compiling a DEX file with ahead-of-time compilation (AOT).
Before AOT came to Android, dexopt
was used to optimize DEX to ODEX (optimized DEX) which contains the optimized bytecode.
With AOT, dex2oat
is used to optimize and compile DEX into an OAT file which may contain machine code in the ELF format.
Reference: https://stackoverflow.com/a/26263071/2872712
Some searching found this page, which says:
The OAT file extension is associated with applications developed for Google Android operating system that is used on various portable devices. The *.oat file stores native C++ code of application designed for new Android RunTime (ART) available in Android 4.4 and higher.
Android RunTime is successor of Dalvik process virtual machine used by older versions of Android.
Even those file formats are available for a while, there is still no off doc with an explanation about meaning (at least I didn't find). So for myself, I figured out the next meaning:
.art - stands for AndroidRunTime (here on page 12 it's pointed that the format is proprietary, and used by "only one file" in ART, so that's why I think in this way)
.oat - found at least three explanation where the best imho is "Optimized Android file Type" (and the idea came from here).
Other possible variants of .oat I had is: "Optimized Application file Type" or just easy AOT->OAT (as .oat produced from ahead-of-time compilation process).
As dexopt
produces ODEX - Optimized Dalvik EXecutable, which contains the optimized bytecode, dex2oat
produces OAT, and my guess that it should stand for Optimized Ahead of Time.
Reading some comparison between ART and Dalvik, i found that AOT refers to Ahead Of Time, you can read more about it Here
来源:https://stackoverflow.com/questions/28435860/what-does-oat-mean