occasionally get OutOfMemory
exceptions from a busy .NET
The answer to this is too complex to fit in an answer. See "Tuning .NET Application Performance" for a complete treatment of the subject.
Here's a vastly oversimplified (but still quite good) summary from Bruno Jouhier:
Furthermore, the .NET runtime does not let you go up to 2 GB. The garbage collector works by copying
live objects, so it needs a fair
amount of space to perform its copies.
Here's my attempt at an explanation...
If you're wondering what the maximum worker process memory size (as reported by Task Manager) is for an ASP.NET Worker Process on x86, the answer is "it depends".
In any kind of managed code such as Java or .NET, the programmer gives up fine-grained control of memory as a penance for not having to deal with pointers. As a program executes, the Heap and Stack will be periodically cleaned up by the Garbage Collector.
Specifically in regards to ASP.NET, the garbage collector runs inside the same worker process as the website. The GC consumes memory of its own. How much memory is entirely a function of how your application's code is written. One app may be able to use 1.8GB of memory while another may choke at 500MB. In order understand why, you need to profile your specific application.