Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Jukka Lahtinen Newsgroups: comp.lang.java.programmer Subject: Re: Controlling the Garbage Collector Date: Mon, 25 Jun 2012 15:28:31 +0300 Organization: A noiseless patient Spider Lines: 15 Message-ID: References: <6KSdnTwztJvtR0bSnZ2dnUVZ_t-dnZ2d@giganews.com> <_JmdnUu_Z-scJEHSnZ2dnUVZ_t6dnZ2d@giganews.com> <4fe27687$0$281$14726298@news.sunsite.dk> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 8bit Injection-Info: ipa.eternal-september.org; posting-host="paPmXfJqRejvVuAyXZaB8g"; logging-data="8562"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+0ymEworzd1q+/CD2c625q" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.97 (gnu/linux) Cancel-Lock: sha1:fk1M7bN9sSGsaeY1RVcV353fDo4= sha1:2X4gHSWWPlkui1gtWK3oT+boE6Q= X-no-archive: yes Xref: csiph.com comp.lang.java.programmer:15576 Robert Klemme writes: > Long lived objects which live shorter than the application (i.e. not > classes) are actually the Achilles heel of GC because it is very hard to > tune the collector in a way that it does not visit those long living > objects too often and yet run often enough to ensure enough free memory is It might be good to have a method to gell the GC that a certain long-lived object is no longer needed. For example, something like System.gc(Object old) where old is the object that has just been needed the last time. -- Jukka Lahtinen