3 ms·
So much bad advice, in general run Flight Recorder or Censum. > With a default memory limit of 1GB (1000 MB) and working memory of about 200 MB Java has to mak
by needusername 12y ago
So much bad advice, in general run Flight Recorder or Censum.
> With a default memory limit of 1GB (1000 MB) and working memory of about 200 MB Java has to make a full garbage collection every 4 seconds otherwise it would run out of memory.
Only if all of the 200 MB make it to old gen.
> Why not use incremental garbage collection?
Nobody should be using -XX:+CMSIncrementalMode it exists for platforms with only one hardware thread.
> the real memory usage is almost double the memory visible in Java
Huh? Yes, Java uses more memory than heap and a copy-collector means half the memory of the heap is unused but I have trouble understanding this.
I was in a JavaOne presentation 2013 when the presenter mentioned that Minecraft runs System.gc() in a thread all 500ms and decided I'll never touch this.