[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Memory size and allocation
- To: email@example.com
- Subject: Re: Memory size and allocation
- From: Francesco Orsenigo <firstname.lastname@example.org>
- Date: Thu, 2 May 2002 17:11:21 +0200
- Delivered-To: email@example.com
- Delivered-To: mailing list firstname.lastname@example.org
- Delivery-Date: Thu, 02 May 2002 11:12:05 -0400
- In-Reply-To: <email@example.com>
- Mailing-List: contact firstname.lastname@example.org; run by ezmlm
- Organization: Xarvh Project
- References: <email@example.com>
- Reply-To: firstname.lastname@example.org
> When a program(process) terminates, the operating system
> automatically frees all memory that was allocated by the program. You
> don't have to care about anything.
This this interesting.
> You may still want to free any unused memory as soon as possible.
> Then you should free the blocks using the program's data structures.
I do that.
I free memory blocks as soon as the program recognizes they have not been
used in the last.. say 10 seconds, paying no attention to their sizes.
Mads Bondo Dydensborg:
>Actually it may have effects, from what kind of optimizations the compiler
>can make, to cache coherency effects. Doing what you sugggest will most
>likely improve the resulting binary AFAIK.