8

I create quite a heavy app using Eclipse and deploy on 4.2.2 device. At the very first launch, it takes quite a long time (3~5 seconds) until UI is displayed completely. After that, even after app killing and restart, everything goes fast, take 0.5 second for launching. So is this normal phenomenon, and if yes, what's the essential root cause? I'm thinking of kind of byte code compile or caching, etc, that is executed only once. One more question, what should I do to optimize this launching time.

giang.asl.8
  • 313
  • 2
  • 11
  • Do you have some logs? Maybe there is something interesting in the Logcat while executing the app for the first time. – Tom Sabel Mar 30 '16 at 10:44

1 Answers1

0

By first start of app, it is not in ram and must be readed from storage.

By killing of app it is still in ram until garbage collector removes it by many free ram space or you make it manually from settings.

If you have database, than onCreate will be executed on first start, what takes a while

anatoli
  • 1,663
  • 1
  • 17
  • 43