Explicitly freeing memory in c#

Private bytes reflect the process’ memory usage. When objects are collected the associated memory segment may or may not be freed to the OS. The CLR manages memory at the OS level and since allocating and freeing memory isn’t free there’s no reason to free each piece of memory immediately as chances are that the application will probably request more memory later.

Leave a Comment