Skip to main content

How to reduce the loading time of a midlet?

2 replies [Last post]
Joined: 2008-07-03

Hi fellows,
When I porting PhoneMe Feature,I find that it takes too much time to load a midlet.

I use slavemode and javacall layer to port.

I found that starting JVM itself does not take too much time.But when loading the midlet related classes and resources, it takes too many seconds.

If I don't load all components' png files in SkinResource.jpp's getImage,it saves some seconds(yes, after that ,the UI looks ugly :( ), but I hope it can be faster .

I guess it maybe because the time slice of the midlet is too small, and Scheduler::time_slice is called too frequently.If I add more millionseconds to one time_slice, It will faster nor not? I hope to have a try, but I cannot find where to change the value.

Is there anyone can tell me where to change the code ? Or some other ways to speed up the loading?

Thx very much.

Message was edited by: yaxch

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2004-03-04


phoneME Feature has gone through quite some optimization for improving start-up time. Have you had a look at the commercial SJWC documentation? There is a section on performance, you might want to check it out:

Furthermore, we have found that poor start-up performance is often related to the MIDlet itself. General best design practices indicate that you should do late initialization in the MIDlet start-up, spread out time-consuming tasks, and pre-process resources (such as images) during build time, if possible. Observing such guidelines can reduce the perceived start-up up a MIDlet dramatically without any VM tweaks.

-- Terrence

Joined: 2008-07-03

Thanks very much.
Yes, I know some Midlets maybe load too many resources.
But when it's very slowly (about 7~8 seconds) when I load Javabenchmark2.
I will read the document first.