Reply
Thread Tools
Posts: 1,418 | Thanked: 1,541 times | Joined on Feb 2008
#61
Originally Posted by Bratag View Post
The C version runs in 2 seconds on a selected image, the Java version takes 20 and on top of that half the time it craps out because the jvm runs out of memory.
...and this returns us to the importance of correct memory allocation Like someone said good five+ years ago, "if Java is the answer, then what the hell was the question?"
 

The Following User Says Thank You to fms For This Useful Post:
javispedro's Avatar
Posts: 2,355 | Thanked: 5,249 times | Joined on Jan 2009 @ Barcelona
#62
Originally Posted by fms View Post
then what the hell was the question?
Easy: look a few posts above for someone who hates C memory allocation. You get what you ask for
 
allnameswereout's Avatar
Posts: 3,397 | Thanked: 1,212 times | Joined on Jul 2008 @ Netherlands
#63
Originally Posted by fms View Post
2. JavaME also known as MIDP, also known as J2ME, also known as PhoneME is a somewhat lobotomized version of Java supported by most mobile phones. Most mobile games and some mobile apps running on dumb phones are written using this version of Java.
If SUN wants JavaFX run on Nokia N900 they're gonna need either Java ME or Java SE on Nokia N900. For now, SUN is merely providing an early access version of JavaFX for Windows Mobile though.

Once JavaFX is ported to Linux/x86-32 it shouldn't be too hard to port to Linux/ARM because it already is ported to WM6/ARM. Shouldn't be too hard for SUN if proprietary or official port, for community if open source, or both.

It is nice to have backwards compatibility. I've taken advantage of this before. Sometimes, it is beyond your control because you have no power over it because your employer or business partner decides the software to be used. For example, in past I had to use Java for .nl ccTLD administration. Some custom software we run is proprietary and requires Java, they cannot be rewritten (would cost too much), and it'd be nice if I wouldn't need to use a seperate device than N900 to run these. Some corporations also require usage of Java applet, with their only alternative (if there is one!) being a bad interface. For a long time my bank required Java! I need Java to get remote desktop over HTTP, too.

We all have different needs. I don't need any of the game emulators yet they're popular. LUA was useful on Diablo for me but I doubt it was much used. Regarding Java, we're not necessarily talking about out of the box which is also both related to chicken/egg, as well as legacy from non-opensource Java.

Although you said no Java ME on S60 phone I have Opera Mini 5 as my backup browser. I like to use it when roaming. I've even used Opera Mini 4.2 on S40 phones in an emergency. I don't yet how I'm going to fix this on my N900...
__________________
Goosfraba! All text written by allnameswereout is public domain unless stated otherwise. Thank you for sharing your output!
 
Posts: 1,418 | Thanked: 1,541 times | Joined on Feb 2008
#64
Originally Posted by allnameswereout View Post
If SUN wants JavaFX run on Nokia N900 they're gonna need either Java ME or Java SE on Nokia N900. For now, SUN is merely providing an early access version of JavaFX for Windows Mobile though.
Who, other then SUN, even needs JavaFX? Are there any useful JavaFX applications? Will there ever be any? As far as I can tell, the world seems to have standardized on Flash for these purposes.

Although you said no Java ME on S60 phone I have Opera Mini 5 as my backup browser. I like to use it when roaming. I've even used Opera Mini 4.2 on S40 phones in an emergency. I don't yet how I'm going to fix this on my N900...
I have not said "no" to JavaME. In fact, I continue insisting that we absolutely need JavaME on Maemo, because there are so many applications written in JavaME on the market.
 

The Following 3 Users Say Thank You to fms For This Useful Post:
qgil's Avatar
Posts: 3,105 | Thanked: 11,088 times | Joined on Jul 2007 @ Mountain View (CA, USA)
#65
I was wondering whether http://maemo.org/community/brainstorm would help consolidating this interesting discussion in one proposal with potential solutions listed.
 

The Following 5 Users Say Thank You to qgil For This Useful Post:
Posts: 2 | Thanked: 5 times | Joined on Oct 2009
#66
Originally Posted by Bratag View Post
So you want speed and java. Yeah thats not going to happen. As an android coder who also codes in C I can tell you there is no comparison in performance. The reason java coders hate to code in C is because it forces you to think about memory allocation and freeing and that goes against the " throw everything into memory and let garbage collection sort it out " mentality that most Java coders have.

Trust me the surest way to take something fast and hobble it is chuck Java into the mix. Here is an example.

I have a pixel by pixel filter I compiled on my G1 in C and also the same filter in Java. The C version runs in 2 seconds on a selected image, the Java version takes 20 and on top of that half the time it craps out because the jvm runs out of memory.

Take from that what you will I guess
Unfortunately a lot of people, like you, think that there is a jvm in the Android platform. The vm used in Android is called Dalvik and it is not a jvm. The only thing Java about Android is the syntax and the syntax has little to do with performance. Thus your example has no relevance in the Java discussion.

The most important thing lacking in the Dalvik VM is a JIT. The difference in speed has been measured to 5-10 times faster with the JIT. The actual speed naturally depends on what you do but a better figure to use is that Java runs at about 80% of the speed of native programs.

If you had read all of my post you would have noticed that I see the need for some programs and parts of programs that run on the native platform.

However most applications are not image filtering and why would you want to to manage the memory of simple data lookup and entering app?

I think we have all see all those great C developers that "know" how handle memory of apps the leak memory, forcing us to restart the app regularly. A large number of security holes are due to developer that cannot handle a simple buffer overflow. I guess we have to expect a huge increase in mobile worms in the future.
 

The Following 2 Users Say Thank You to bcaroll For This Useful Post:
Posts: 51 | Thanked: 16 times | Joined on Jan 2008 @ Sweden
#67
Originally Posted by qgil View Post
I was wondering whether http://maemo.org/community/brainstorm would help consolidating this interesting discussion in one proposal with potential solutions listed.
I have not used it before so don't know how it works. But I like the idea to consolidating this interesting discussion in one proposal with potential solutions listed
 

The Following User Says Thank You to ovjo12 For This Useful Post:
qgil's Avatar
Posts: 3,105 | Thanked: 11,088 times | Joined on Jul 2007 @ Mountain View (CA, USA)
#68
Originally Posted by ovjo12 View Post
I have not used it before so don't know how it works. But I like the idea to consolidating this interesting discussion in one proposal with potential solutions listed
http://static.maemo.org/static/m/mae...troduction.swf
 
Posts: 51 | Thanked: 16 times | Joined on Jan 2008 @ Sweden
#69
I think also it would be very interesting to be able to run eRCP applications. It is a solution from a Eclipse project called eRCP. eRCP is installed on top of JavaME/CDC1.1/FP1.1 and using eSWT instead of AGUI or LCDUI(MIDP). This is something I also think Nokia would like to support because they are supporting this technology since many years in the eRCP project. eSWT support is already added in Nokias's S60 Java runtime from S60 v3.2 because eSWT don't need JavaME/CDC support, it runs also on top of JavaME/CLDC/MIDP.
 

The Following User Says Thank You to ovjo12 For This Useful Post:
Posts: 1,418 | Thanked: 1,541 times | Joined on Feb 2008
#70
Originally Posted by ovjo12 View Post
I think also it would be very interesting to be able to run eRCP applications. It is a solution from a Eclipse project called eRCP. eRCP is installed on top of JavaME/CDC1.1/FP1.1 and using eSWT instead of AGUI or LCDUI(MIDP). This is something I also think Nokia would like to support because they are supporting this technology since many years in the eRCP project. eSWT support is already added in Nokias's S60 Java runtime from S60 v3.2 because eSWT don't need JavaME/CDC support, it runs also on top of JavaME/CLDC/MIDP.
Ok. How many applications use eRCP/eSWT at the moment?
 
Reply


 
Forum Jump


All times are GMT. The time now is 18:05.