Jump to content

  • Log In with Google      Sign In   
  • Create Account


Java is fast?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
111 replies to this topic

#1 MasterQ   Members   -  Reputation: 100

Like
0Likes
Like

Posted 16 April 2006 - 12:09 PM

I read an article that said java is just as fast as C++ when it uses JIT compiling. It gave some tests and java actually outperformed C++. I've also noticed many video games like Runescape are being programmed in java. Will languages like java, C#, and VB.NET take over the game industry in the coming years? Now that the speed is just as fast as C++ there may no longer be any reason to use C++, just as there is no longer a need to write programs in assembly or machine language.

Sponsor:

#2 jfclavette   Members   -  Reputation: 1058

Like
0Likes
Like

Posted 16 April 2006 - 12:11 PM

Quote:
Original post by MasterQ
I read an article that said java is just as fast as C++ when it uses JIT compiling. It gave some tests and java actually outperformed C++.

I've also noticed many video games like Runescape are being programmed in java. Will languages like java, C#, and VB.NET take over the game industry in the coming years? Now that the speed is just as fast as C++ there may no longer be any reason to use C++, just as there is no longer a need to write programs in assembly or machine language.


I sure HOPE so. I wouldn't hold my breath tough. The games industry has an history of being late adopters and conservative in their choice of (software) technology.

[Edited by - jfclavette on April 16, 2006 6:11:47 PM]

#3 programwizard   Members   -  Reputation: 100

Like
0Likes
Like

Posted 16 April 2006 - 12:35 PM

Many companies have their existing code bases written entirely in C++. That's why companies are able to crank out sequels so fast; code reuse. I've worked with C++, C#, and Java, and I hope that the later two eventually replace the first one as a standard, but as jfclavette said, don't wait up on it.
------------------------------Support the Blue Skies in Games Campaign!A blog... of sorts.As a general rule, if you don't have a general rule in your signature, you aren't as awesome as someone who does. General rules roxor teh big one one ones.

#4 [deleted99599]   Banned   -  Reputation: 100

Like
0Likes
Like

Posted 16 April 2006 - 02:25 PM

Java is definitely fast for most modern desktop games. For example, here are some links to some great 3d games developed in Java:

http://www.runescape.com
http://www.bytonic.de/html/jake2.html
http://www.oddlabs.com/
http://www.megacorpsonline.com/
http://www.wurmonline.com/
http://www.flyingguns.com/

#5 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 16 April 2006 - 02:55 PM

What's more likely is that C/C++ will be here to stay, but will be supplemented by s'more useful libraries and some manner of scripting language (like perl/python/ruby). If you don't believe me, just look at all the current popular AAA game engines in use, like Unreal Engine or Half-Life's engine. The engine and "fast stuff" is written in C/C++ and a bit of assembly, and the gameplay and GUI code is in a scripting language. Pretty much everything but bottlenecks and deep engine stuff (graphics, physics, etc) can do without C/C++, and so we'll probably be seeing a steady rise in more abstract languages in the games world. Hey, if it worked for software outside the game industry, then it can work for us too. Increased productivity also means less unpaid overtime and fewer crunches!

#6 Deception666   Members   -  Reputation: 182

Like
0Likes
Like

Posted 16 April 2006 - 03:57 PM

Quote:
Original post by MasterQ
I read an article that said java is just as fast as C++ when it uses JIT compiling. It gave some tests and java actually outperformed C++.

I've also noticed many video games like Runescape are being programmed in java. Will languages like java, C#, and VB.NET take over the game industry in the coming years? Now that the speed is just as fast as C++ there may no longer be any reason to use C++, just as there is no longer a need to write programs in assembly or machine language.


Interesting. Could you please post the article link that discussed this JIT compilation? I wasn't aware that Java supported JIT compilation. Are you sure you were not thinking of J#? I know IBM has redesigned the VM to employ this technique and that there are many projects on the web doing the same thing. Now, it has been some time since I last touched the language. Maybe the current installment of the Java runtime environment does use JIT compilation.

#7 deadimp   Members   -  Reputation: 310

Like
0Likes
Like

Posted 16 April 2006 - 04:27 PM

I don't mean to be too presumptious, but if you set a C++ compiler to make optimizations like the JVM/JIT, I'm willing to bet you that Java will no longer be "faster than C++".
*Gets whacked*

#8 KaptainKomunist   Members   -  Reputation: 300

Like
0Likes
Like

Posted 16 April 2006 - 04:44 PM

Java was never meant to be... fast... It was meant to be a flexible platform where you could execute the same application in any environment. In this, it succeeds quite well. If you need something to run anywhere, you write it in Java.

To use Java for anything else is going to be a painfull experience except for the most rudimentary applications. It's good for networking tasks. Limewire is proof of that. But I still haven't seen anything written fast in it. Why is netbeans so slow?

#9 metal85   Members   -  Reputation: 106

Like
0Likes
Like

Posted 16 April 2006 - 04:51 PM

Java was designed to be a cross-platform "programming language" that didn't have to use platform specific compilers/optimizers or anything. Hence the Java VM - which in my eyes makes Java more of a scripting language than a programming language which in turn is why it'll never be as fast as c/c++ etc.

As for the future of game programming i think C# will be the next big thing. Hell, not only the next big thing in the game industry, it's likely the new C.

#10 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 16 April 2006 - 04:51 PM

Quote:
Original post by Deception666
Quote:
Original post by MasterQ
I read an article that said java is just as fast as C++ when it uses JIT compiling. It gave some tests and java actually outperformed C++.

I've also noticed many video games like Runescape are being programmed in java. Will languages like java, C#, and VB.NET take over the game industry in the coming years? Now that the speed is just as fast as C++ there may no longer be any reason to use C++, just as there is no longer a need to write programs in assembly or machine language.


Interesting. Could you please post the article link that discussed this JIT compilation? I wasn't aware that Java supported JIT compilation. Are you sure you were not thinking of J#? I know IBM has redesigned the VM to employ this technique and that there are many projects on the web doing the same thing. Now, it has been some time since I last touched the language. Maybe the current installment of the Java runtime environment does use JIT compilation.


Where have you been, man? Java has had JIT compilers for a long time.

#11 MasterQ   Members   -  Reputation: 100

Like
0Likes
Like

Posted 16 April 2006 - 04:52 PM

Quote:
Original post by Deception666
Could you please post the article link that discussed this JIT compilation?




http://java.sys-con.com/read/45250.htm?CFID=388847&CFTOKEN=9460D898-B6BB-AC8B-3C74121E272A4D92

#12 theycallhimSeeD   Members   -  Reputation: 122

Like
0Likes
Like

Posted 16 April 2006 - 04:59 PM

For array operations Java is slower since it checks for a program accessing an array out of bounds while c++ doesn't check. I think in the future graphics code will still be written in c++ because it allows you to have the control you need to get the speed. But for everything else c++ is slower, personally I think that python is going to become more and more used in game development as a scripting language.

I have even heard of a model for designing programs where the entire thing is made in python then the functions that are really time critical are rewritten in c++. This allows you to get the fast development time with python but still get the speed you need with c++.

#13 Lazy Foo   Members   -  Reputation: 1092

Like
0Likes
Like

Posted 16 April 2006 - 05:01 PM

Quote:
Original post by MasterQ
I read an article that said java is just as fast as C++ when it uses JIT compiling. It gave some tests and java actually outperformed C++.


You mean this garbage, that doesn't use any real world situations? Its common knowledge that C++ outperforms Java in real world situations. When you need speed use C++, when you need quick and dirty use Java.

Java isn't "slow", it's just slower than C++.

Quote:
Original post by MasterQ
I've also noticed many video games like Runescape are being programmed in java.


Notice Runescape is free. It's significantly harder to make a commercial game in Java.

Quote:
Original post by MasterQ
Will languages like java, C#, and VB.NET take over the game industry in the coming years?


Java: Never. Speed is Java's smallest problem as processors will someday be fast enough to where the difference in speed is minimal. Java is really easily reverse engineered.

C#: Doubt it. A proprietary language will never take over an entire industry so unless microsoft allows an open standard I don't see it happening.

VB: BASIC syntax makes a lot of people gag, that's why there's C#.

Quote:
Original post by MasterQ
just as there is no longer a need to write programs in assembly or machine language.


ASM is still widely used for optimizations. a 10% speed boost means more people will be able to user your app without having to upgrade.

C++ is here to stay. I doubt anybody is willing to make a bet that if C++ is still not the major language for commerical applications in the next few years they'll put a bullet in their head.
Learn to make games with my SDL Tutorials.
Transition from OpenGL 2 to modern OpenGL using my OpenGL Tutorial.

#14 jfclavette   Members   -  Reputation: 1058

Like
0Likes
Like

Posted 16 April 2006 - 05:13 PM

Quote:
Original post by Lazy Foo
C#: Doubt it. A proprietary language will never take over an entire industry so unless microsoft allows an open standard I don't see it happening.



You mean an open standard like this, supportedy an open framework like this ?

#15 joanusdmentia   Members   -  Reputation: 1060

Like
0Likes
Like

Posted 16 April 2006 - 05:13 PM

Quote:
Original post by Lazy Foo
C#: Doubt it. A proprietary language will never take over an entire industry so unless microsoft allows an open standard I don't see it happening.


Actually, C# is standardized, see here. And besides, since when has being an open standard had anything to do with success? Ever heard of DirectX?


"Voilà! In view, a humble vaudevillian veteran, cast vicariously as both victim and villain by the vicissitudes of Fate. This visage, no mere veneer of vanity, is a vestige of the vox populi, now vacant, vanished. However, this valorous visitation of a bygone vexation stands vivified, and has vowed to vanquish these venal and virulent vermin vanguarding vice and vouchsafing the violently vicious and voracious violation of volition. The only verdict is vengeance; a vendetta held as a votive, not in vain, for the value and veracity of such shall one day vindicate the vigilant and the virtuous. Verily, this vichyssoise of verbiage veers most verbose, so let me simply add that it's my very good honor to meet you and you may call me V.".....V

#16 Lazy Foo   Members   -  Reputation: 1092

Like
0Likes
Like

Posted 16 April 2006 - 05:43 PM

Ok an open standard that doesn't suck.

and by doesn't suck, I mean something where I can easily take a language's code and use it where ever I want.

Quote:
Original post by joanusdmentia
Ever heard of DirectX?


I've heard of marketing run amok.

DirectX depends on Window's success meaning if windows gets kicked off its current throne DirectX goes down with it. Where as non-proprietary technology like C++ can survive considering it doesn't depend on a company's success.
Learn to make games with my SDL Tutorials.
Transition from OpenGL 2 to modern OpenGL using my OpenGL Tutorial.

#17 jfclavette   Members   -  Reputation: 1058

Like
0Likes
Like

Posted 16 April 2006 - 05:53 PM

Quote:
Original post by Lazy Foo
Ok an open standard that doesn't suck.

and by doesn't suck, I mean something where I can easily take a language's code and use it where ever I want.


You mean like, on Linux, Solaris, Mac OS X, Windows, and Unix ?

A nice prop of .NET over C++ is that you don't even have to care about the hardware at all !

I assure you that writing cross-platform games in C# is as easy as it gets. (Much easier than in C++ as it turns out in my experience, since you aren't as tied to the hardware as you are in C++.)

#18 Lazy Foo   Members   -  Reputation: 1092

Like
0Likes
Like

Posted 16 April 2006 - 06:25 PM

Quote:
Original post by jfclavette
You mean like, on Linux, Solaris, Mac OS X, Windows, and Unix ?


Mono is in it's infancy, and needs much more support.
Learn to make games with my SDL Tutorials.
Transition from OpenGL 2 to modern OpenGL using my OpenGL Tutorial.

#19 jfclavette   Members   -  Reputation: 1058

Like
0Likes
Like

Posted 16 April 2006 - 06:26 PM

Quote:
Original post by Lazy Foo
Quote:
Original post by jfclavette
You mean like, on Linux, Solaris, Mac OS X, Windows, and Unix ?


Mono is in it's infancy, and needs much more support.


Says who ? Works pretty damn well for me. Especially for games, which are probably the simplest form of software from an infrastructure perspective (Multiplayer non-withstanding)

#20 Lazy Foo   Members   -  Reputation: 1092

Like
0Likes
Like

Posted 16 April 2006 - 06:34 PM

Quote:
Original post by jfclavette
Says who ? Works pretty damn well for me.


Says the industry. You can switch tools whenever you want, but companies can't afford to gamble.

DirectX, Java, you-name-it wheren't adopted overnight. A technology has to prove itself first.
Learn to make games with my SDL Tutorials.
Transition from OpenGL 2 to modern OpenGL using my OpenGL Tutorial.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS