Top "Garbage-collection" questions

Garbage collection (GC) is a form of automatic memory management which attempts to reclaim garbage, or memory occupied by objects that are no longer in use by the program.

What is the garbage collector in Java?

I am new to Java and confused about the garbage collector in Java. What does it actually do and when …

java garbage-collection
What is JavaScript garbage collection?

What is JavaScript garbage collection? What's important for a web programmer to understand about JavaScript garbage collection, in order to …

javascript garbage-collection
Why is it bad practice to call System.gc()?

After answering a question about how to force-free objects in Java (the guy was clearing a 1.5GB HashMap) with System.…

java garbage-collection
How to redirect verbose garbage collection output to a file?

How do I redirect verbose garbage collection output to a file? Sun’s website shows an example for Unix but …

garbage-collection java jdk1.5
Implementing IDisposable correctly

In my classes I implement IDisposable as follows: public class User : IDisposable { public int id { get; protected set; } public string …

c# .net memory-management memory-leaks garbage-collection
Garbage collector in Android

I have seen many Android answers that suggest calling the garbage collector in some situations. Is it a good practice …

java android garbage-collection
When should I use GC.SuppressFinalize()?

In .NET, under which circumstances should I use GC.SuppressFinalize()? What advantage(s) does using this method give me?

c# .net garbage-collection idisposable suppressfinalize
How to force deletion of a python object?

I am curious about the details of __del__ in python, when and why it should be used and what it …

python constructor garbage-collection destructor reference-counting
When is it acceptable to call GC.Collect?

The general advise is that you should not call GC.Collect from your code, but what are the exceptions to …

c# .net garbage-collection
How to check heap usage of a running JVM from the command line?

Can I check heap usage of a running JVM from the commandline, I mean the actual usage rather than the …

java memory-management garbage-collection jetty jvisualvm