:tai: I won't discuss linux memory management with you because 1.) I'm not familiar with that and 2.) it isn't the topic of the thread.
But I do know a bit about Windows and it clearly does not allocate all free memory to already running processes.
Also it does make sense to stop/kill all unnecessary processes if you are short on free memory und want to start a complex game, like it was described in the earlier posts. Although I would rather use the task manager or Process Explorer (by Sysinternals) to do that than a homemade solution (@bp103: sorry, pal.

)