Monday, July 23, 2007

Do I need /3GB switch on 64Bit Platform?

On 64-bit versions of Windows Server 2003, the system automatically expands the virtual address space available to 32-bit user-mode programs linked with the /LARGEADDRESSAWARE option as needed without the /3GB boot parameter. On Windows Server 2003 RTM (without Service Pack 1), these 32-bit programs can access up to 3 GB of virtual address space. On Windows Server 2003 with Service Pack 1, they can access up to 4 GB of virtual address space. Native 64-bit user-mode programs can access up to 8 TB of virtual address space

Let's refresh our memories about performance tuning switches in 32 Bits Platforms. Below information is directly taken from MSDN.


On 32-bit versions of Windows, the /3GB parameter enables 4 GT RAM Tuning, a feature that enlarges the user-mode virtual address space to 3 GB and restricts the kernel-mode components to the remaining 1 GB.


Specifies an alternate amount of user-mode virtual address space for operating systems booted with the /3GB parameter.


Specifies the amount of memory, in megabytes, for user-mode virtual address space. This variable can have any value between 2048 (2 GB) and 3072 (3 GB) megabytes in decimal notation. Windows uses the remaining address space (4 GB minus the specified amount) as its kernel-mode address space.


The /3GB parameter is supported on Windows Server 2003, Windows XP, Windows 2000, and Windows NT. On Windows Vista and later versions of Windows, use the IncreaseUserVA element in BCDEdit.

On Windows, by default, the lower 2 GB are reserved for user-mode programs and the upper 2 GB are reserved for kernel-mode programs. You can use this parameter to test the performance of your driver when it is running in a 1 GB kernel.The 4 GT RAM Tuning feature is fully functional on Microsoft Windows NT Server 4.0, Enterprise Edition with Service Pack 3, Microsoft Windows 2000 Advanced Server, Microsoft Windows 2000 Datacenter Server, and all editions of Windows XP, Windows Server 2003, Windows Vista, and later versions of Windows.

On other versions of Windows NT and Windows 2000, this feature restricts the kernel to addresses above the 3 GB boundary. However, user-mode applications cannot access more than 2 GB of address space.

The /userva subparameter is designed for computers that need more than 2 GB but less than 3 GB of user-mode address space, particularly those that are running memory-intensive user-mode programs. When used without the /3GB parameter, /userva is ignored.

The /3GB and /userva parameters are valid only on boot entries for 32-bit versions of Windows on computers with x86 or x64-based processors.

To take advantage of the 3 GB available to user-mode programs, the program must be linked with the /LARGEADDRESSAWARE option


Oz Ozugurlu

No comments: