![]() |
2011-02-09
, 19:07
|
|
Posts: 3,524 |
Thanked: 2,958 times |
Joined on Oct 2007
@ Delta Quadrant
|
#132
|
![]() |
2011-02-09
, 23:35
|
Posts: 303 |
Thanked: 146 times |
Joined on Aug 2009
|
#133
|
@Radu,
Here's an Quake 2 Java port example to counter your C# port example:
http://www.bytonic.de/html/benchmarks.html
What does this show? That the Windows JVM version (and only JRE 1.5) is actually faster than the HIGHLY tuned C version (remember, this is Carmack's software we're talking about) with the Windows JVM intepreter. Full-screen and the linux JVM are slower, but not by much.
![]() |
2011-02-10
, 07:19
|
Posts: 2,829 |
Thanked: 1,459 times |
Joined on Dec 2009
@ Finland
|
#134
|
Also, as a personal opinion, speed is not everything. Better provide more that provide less and make them faster. You can only compare two existing products for speed. Not one that exists and it is slow and one that doesn't exist and it would be faster if it was ever written. Android already has a ton of apps and mobile phone manufacturers can instantly take advantage of them. No manufacturer (or human) currently cares if the apps in android's app store are slow.
![]() |
2011-02-10
, 08:34
|
|
Posts: 1,637 |
Thanked: 4,424 times |
Joined on Apr 2009
@ Germany
|
#135
|
Anyway, the main reason why I don't believe VMs/JIT will ever catch native code in terms of speed is because it's a bit like the telephone game.
In a C program, you more or less tell the CPU what to do, step by step (assuming the compiler is smart enough not to do really stupid things). You can even use custom ASM in C, you can use registers for variables, and so on.
For Java, the compiler will translate stuff to virtual code (one step) then the JIT will translate that code in native code (another step). The more steps you have in a process the least likely it is for the final code to do things the way you want it to be done
The Following 2 Users Say Thank You to nicolai For This Useful Post: | ||
![]() |
2011-02-10
, 11:25
|
Posts: 1,341 |
Thanked: 708 times |
Joined on Feb 2010
|
#136
|
Java
performance can exceed that of C++ because
dynamic compilation gives the Java compiler
access to runtime information not available to a
C++ compiler.
The Following User Says Thank You to zimon For This Useful Post: | ||
![]() |
2011-02-10
, 12:16
|
|
Posts: 2,427 |
Thanked: 2,986 times |
Joined on Dec 2007
|
#137
|
One of the reasons why Firefox slows down and "leaks" memory, which you notice after several days heavy use, is because it has been coded with C++ and it cannot use this extra running time information for optimization.
![]() |
2011-02-10
, 12:35
|
Posts: 1,341 |
Thanked: 708 times |
Joined on Feb 2010
|
#138
|
You don't know what you're talking about, and if you think you do, prove it.
![]() |
2011-02-10
, 12:50
|
|
Posts: 1,637 |
Thanked: 4,424 times |
Joined on Apr 2009
@ Germany
|
#139
|
The problem is obvious for me, but I know I should prove it with memory prints comparing the same session and tabs and pages after fresh start and after few days of surfing
but after Firefox re-start and resuming the same session with all the tabs, the situation is good again
![]() |
2011-02-10
, 12:53
|
Posts: 3,319 |
Thanked: 5,610 times |
Joined on Aug 2008
@ Finland
|
#140
|
What you are saying is not wrong, but you are not looking the big picture. There is extra information available in running time. Only VM-type of solutions can use this running-time profiling information for optimizations. The efficiency gain in OOP-type of programs can easily be more than the loss which come from the JIT and having a code in a bytecode form in the beginning.
One of the reasons why Firefox slows down and "leaks" memory, which you notice after several days heavy use, is because it has been coded with C++
The Following User Says Thank You to attila77 For This Useful Post: | ||
![]() |
Tags |
bada rox, dalvik, future, java haters, meego, meego?fail, nokia, sandbox sucks |
Thread Tools | |
|
It seems that culture determines largely what developers use more so than ease, flexibility, portability, or speed.
Last edited by Capt'n Corrupt; 2011-02-09 at 11:50.