64-bit MemToLeave

Question:  On 64-bit SQL Server, which tends to be larger:  the Buffer Pool or the MemToLeave region?  Because it usually dominates the user mode portion of 32-bit SQL Server's process address space, it might make sense to assume that the BPool is usually larger, but that's not the case.  64-bit processes have an 8TB user mode address space.  Of this, a small portion is usually set aside for the BPool; the rest is left to MemToLeave.  Why is that?  As with 32-bit SQL Server, 64-bit SQL Server sizes the BPool according to the physical memory on the machine.  This is done in an attempt to keep SQL Server from being paged out.  We'd never want to commit more physical memory than exists on the box or we might cause Windows to page us out.  Given that even high-end 64-bit system still measure RAM in gigabytes, not terabytes, the maximum BPool size ends up being quite small compared to the MemToLeave region.  Take a high-end 64-bit system with 128GB of RAM, for example.  On this system, 64-bit SQL Server would set the max BPool size to 128GB, and leave the remaining 7 and 7/8ths of the 8TB user mode address space to MemToLeave.

What does this mean to you?  Well, for one thing, if you're seeing some extreme pressure in the MemToLeave region on your 32-bit system, and there's nothing from a software standpoint that you can do about it, moving to 64-bit SQL Server might be a good option for you.  Your MemToLeave consumers will at least have a much larger sandbox in which to play.