Skip to main content

a strange problem for performance

1 reply [Last post]
Joined: 2007-02-07
Points: 0

I built two versions based on win32 platform (default flags):
1. CLDC for Sun's RI
2. CLDC for phoneME
I tested their performance and found phoneME has worse performance than Sun's RI. It took 125s on phoneME and took 71s on Sun's RI. I think there is something wrong with my building. Can somebody give me some suggestions?

The following is my testing source java file:

import java.util.Date;

public class LoopTest
public static void main(String[] args)
Date before = new Date();
double num = 0;
for (int i = 0; i < 65535; i++)
num += i;
Date after = new Date();
StringBuffer buf = new StringBuffer("loop run for ");
buf.append((after.getTime() - before.getTime()));
buf.append(" milliseconds!");

Reply viewing options

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


A similar question was just posted. See my reply at:

-- Terrence