How to make `odex` file to userdataimage

133 views
Skip to first unread message

Peng Cao

unread,
Nov 2, 2015, 9:38:33 PM11/2/15
to android-platform

Hi everyone:


background:

Qualcomm platform,optimizing the first booting time

in order to reduce the time fo first booting,below action have done!

  • remove some un-useful resources,such as language,etc.

  • remove some un-useful APKS, such as Galery2/DeskClock ,etc.

  • to optimize preload class/resources

However, The result is not satisfactory(total save ~50s for first booting);

as we konw,Android system will dex2oat APKS during android first booting,like below LOG

I/dex2oat ( 2188): /system/bin/dex2oat --zip-fd=6 --zip-location=/system/app/BluetoothExt/BluetoothExt.apk --oat-fd=7 --oat-location=/data/dalvik-cache/arm/system@app@Blueto...@BluetoothExt.apk@classes.dex --instruction-set=arm --instruction-set-features=div --runtime-arg -Xms64m --runtime-arg -Xmx512m --compiler-filter=interpret-only --swap-fd=10

Qestion:

  1. Could we dex2oat APKS during MAKE android image(system.img/userdata.img)?

  2. Could we pack the .dex(such as system@app@Blueto...@BluetoothExt.apk@classes.dex ) file to userdata.img directory during MAKE Android image?


details please refer

http://stackoverflow.com/questions/33490409/how-to-make-odex-file-to-userdataimage

joez

unread,
Nov 5, 2015, 10:09:16 AM11/5/15
to android-platform
try WITH_DEXPREOPT := true in BoardConfig.mk
and for Android M you can try WITH_DEXPREOPT_PIC := true too


On Tuesday, November 3, 2015 at 10:38:33 AM UTC+8, Peng Cao wrote:

Hi everyone:


background:

Qualcomm platform,optimizing the first booting time

in order to reduce the time fo first booting,below action have done!

  • remove some un-useful resources,such as language,etc.

  • remove some un-useful APKS, such as Galery2/DeskClock ,etc.

  • to optimize preload class/resources

However, The result is not satisfactory(total save ~50s for first booting);

as we konw,Android system will dex2oat APKS during android first booting,like below LOG

I/dex2oat ( 2188): /system/bin/dex2oat --zip-fd=6 --zip-location=/system/app/BluetoothExt/BluetoothExt.apk --oat-fd=7 --oat-location=/data/dalvik-cache/arm/system@app@Blueto...@BluetoothExt.apk@classes.dex --instruction-set=arm --instruction-set-features=div --runtime-arg -Xms64m --runtime-arg -Xmx512m --compiler-filter=interpret-only --swap-fd=10

Qestion:

  1. Could we dex2oat APKS during MAKE android image(system.img/userdata.img)?

  1. Could we pack the .dex(such as system@app@BluetoothExt@Bluetoot...@classes.dex ) file to userdata.img directory during MAKE Android image?

Reply all
Reply to author
Forward
0 new messages