LWJGL
June 18, 2013, 14:51:45 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: LWJGL is now using GitHub
 
   Home   Help Search Login Register  



Pages: [1]
  Print  
Author Topic: Garbage Collection  (Read 7403 times)
serge_christopher
Newbie
*
Posts: 1


« on: January 06, 2005, 07:33:01 »

Hi all

I am currently in the early stages of developing a game using java. I was wondering if anybody out there has had any performance issues with their games due to garbage collections being performed by the VM.

cheers
Logged
elias4444
Nerdus Imperius
*****
Posts: 636



WWW
« Reply #1 on: January 06, 2005, 07:57:42 »

None whatsoever. I do occasionally call System.gc() however after loading/reloading a large number of assets, just to make sure it's never a problem.
Logged

=-=-=-=-=-======-=-=-=-=-=-
http://www.tommytwisters.com
princec
Nerdus Imperius
*****
Posts: 1870



WWW
« Reply #2 on: January 06, 2005, 09:53:44 »

No.

Cas Smiley
Logged

Fool Running
Nerdus Imperius
*****
Posts: 758


« Reply #3 on: January 07, 2005, 06:13:59 »

You do have to make sure that your engine is designed so that garbage collection is reduced to a minimum. My first engine design created a lot of objects and let the GC collect them.  The performace was horrible.  :lol:
Logged

Programmers will, one day, rule the world... and the world won't notice until its too late.Just testing the marquee option Grin
princec
Nerdus Imperius
*****
Posts: 1870



WWW
« Reply #4 on: January 07, 2005, 06:59:47 »

Yeah. If you're creating more than 10kb of garbage per frame you'll likely start running into trouble.

Cas Smiley
Logged

Fool Running
Nerdus Imperius
*****
Posts: 758


« Reply #5 on: January 10, 2005, 06:32:23 »

Well, at the chance that I'll sound incompetent there was alot :oops: (and it produced a less steady framerate more than a lower framerate, which to me is just as bad :roll:)
Logged

Programmers will, one day, rule the world... and the world won't notice until its too late.Just testing the marquee option Grin
princec
Nerdus Imperius
*****
Posts: 1870



WWW
« Reply #6 on: January 10, 2005, 07:19:43 »

You can actually steady the framerate out fine even with that amount of garbage, just by carefully tuning the GC collection options. The only problem is that you a) can't do it under webstart and b) it's different for 1.4 and 1.5

Cas Smiley
Logged

Fool Running
Nerdus Imperius
*****
Posts: 758


« Reply #7 on: January 11, 2005, 06:20:43 »

I didn't think of that. :lol: That would have saved me alot of time  :wink:
Logged

Programmers will, one day, rule the world... and the world won't notice until its too late.Just testing the marquee option Grin
blah
Regular nerd
**
Posts: 68


« Reply #8 on: January 15, 2005, 04:11:01 »

Quote from: "princec"
You can actually steady the framerate out fine even with that amount of garbage, just by carefully tuning the GC collection options. The only problem is that you a) can't do it under webstart and b) it's different for 1.4 and 1.5

Cas Smiley


I only recently discovered this, whilst making an auto-jnlp-creator, but ... if webstart will honour the tuning settings, you can handle this: it has a built in feature of allowing you to specify multiple JVM's in parallel with *unique* JVM args to each.

Just kick your local Sun rep until they allow "ANY" JVM arg (anything you could type on the command line) as valid in webstart JNLP. There is no reason not to allow this, other than that sun thinks it isn't important. Off the top of myhead, 1.4 still only supports a tiny tiny subset (3 out of 300!) and 5 supports more, but still not the full 300?
Logged
princec
Nerdus Imperius
*****
Posts: 1870



WWW
« Reply #9 on: January 15, 2005, 04:37:22 »

I've given up asking Sun to do anything for Java.
If somebody would fund it I'd write my own Webstart that did everything correctly.

Cas Smiley
Logged

blah
Regular nerd
**
Posts: 68


« Reply #10 on: January 15, 2005, 04:49:44 »

Give me a quote, and if JGF ever makes that much money...

Perhaps some of the donation money could go towards it too.

Total income to date still hasn't broken the $2 barrier yet, LOL, but we'll wait and see what happens when the site goes live...
Logged
princec
Nerdus Imperius
*****
Posts: 1870



WWW
« Reply #11 on: January 15, 2005, 04:51:30 »

Well, you stand to make 50% as an affiliate for all 3 of our games. That should give you a bit of an incentive to hurry up, eh?

Cas Smiley
Logged

gregorypierce
Regular nerd
**
Posts: 73


WWW
« Reply #12 on: January 20, 2005, 17:28:55 »

Quote from: "princec"
I've given up asking Sun to do anything for Java.
If somebody would fund it I'd write my own Webstart that did everything correctly.

Cas Smiley


Smart move. I've given up on even discussing anything related to Java with them.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines
SMFAds for Free Forums
Valid XHTML 1.0! Valid CSS!