DGUnreal Home

Site

Home


 

Unreal Tournament III Tips
This information is provided by DGUnreal.  Please do not copy this and post it elsewhere.


32-bit and 64-bit OS's and 4GB RAM Memory


Windows Vista

The Unreal Engine and Editor run equally well under Windows XP and Windows Vista.

4GB RAM

If you have 4GB of physical RAM installed on 32-bit XP or Vista, you usually have somewhere around 3.25GB of actual "usable" physical RAM.  This is because approximately 0.75GB of the total 4GB physical space is reserved for hardware addresses.   This reserved amount varies depending on a number of factors including what hardware is installed and the design of the motherboard chipset.  Some older motherboards will only ever see lesser values such as 2GB or 2.5GB, so always check your motherboard documentation before adding RAM to see if the chipset has limitations.
You can get past the 3.25GB limit on newer motherboards by using a 64-bit OS instead.   With 4GB of RAM installed you will get all 4GB usable.  Many common consumer motherboards currently support 8GB of RAM with 64-bit OS's.  Commercial/server motherboards may support up to 128GB of physical RAM.

Paging File

A properly configured system will have the Virtual Memory Paging File set to Initial = 1.5x the physical RAM and Maximum = 3x the Initial value.  The paging file should also be located on a second physical hard drive other than the OS drive if there is one available in the system, and preferably in its own dedicated partition so that it cannot become fragmented.  Note that most systems are not set correctly and are usually less than the recommended values, which limits the performance of the computer since the total available virtual space is less than what it should be.

Virtual Memory

The installed physical RAM and the paging file make up the total virtual memory that the system has for allocating to applications etc.
For example a system with 2GB of installed physical RAM should have the Paging File set at: Initial = 3072, Maximum = 9216.  This has a total virtual memory space of 11GB for all applications to share (total virtual = 2GB physical + 9GB paging).
A system with 4GB (and 3.25 usable) should have the Paging File set at: Initial = 4992, Maximum = 14976.  Note that this set of values may vary a bit depending on the exact RAM amount available shown on your computer.
A system with a 64-bit OS and 8GB of RAM should have the the Paging File set at: Initial = 12288, Maximum = 36864.  The total virtual memory available in this case would be 44GB (8GB+36GB).

When 32-bit applications are ran, they have a 2GB User memory and 2GB Kernel memory pool setup.  The Kernel is actually shared among all running applications.  The allocated User memory for each application running can be located anywhere in the virtual memory space, it is not limited to the physical RAM, this is why attempting to run too many individual applications or one large application with insufficient physical RAM starts to get real slow since allocation calls are now being made to the paging file area of the virtual memory that is located on the hard drive which is way slower than the physical RAM.  Keep in mind that every 32-bit application running has its own 4GB virtual memory space.  Most people don't correctly understand this.  The application can be located anywhere in the virtual space which is the combined physical RAM and the paging file.  The installed physical memory simply makes up the faster portion of the full virtual memory area that is allocated to running applications.   The OS manages where the allocation calls are given from, prioritized to faster virtual memory blocks which are usually the installed physical RAM.  When the system runs out of available faster physical memory blocks, it starts giving out slower paging memory space.

The /3GB Switch

Some people believe that the "fix" for this if they have 4GB physical RAM installed is to add the /3GB switch to the boot.ini.  This changes the memory setup for 32-bit applications compiled with /LARGEADDRESSAWARE to 3GB User and 1GB Kernel.   So they think that the extra 1GB available to the application User area will benefit them.  However, this method shrinks the Kernel memory to 1GB which usually causes performance loss or crashing.

There are some instances where the /3GB switch can be used, such as on dedicated servers running specific software and limited to that role only.  But on standard consumer setups it should not be used as a workaround to try to get "more" user memory for an application.  Anyone using the /3GB switch to try to get more User memory for applications like 3DS Max and UnrealEd should remove the option.  The best method is to simply upgrade to a 64-bit OS.

Large Address Aware

UnrealEd for UE3 was compiled with the /LARGEADDRESSAWARE option, so even though it is a 32-bit application, on 64-bit OS's you should get 4GB User memory with it.  I haven't verified this though.

References

MSKB Paging File size.  Note that there are a number of MSKB articles on this topic.
MSDN 64-bit Programming for Games
MS Technet: 32-bit memory management
MS Technet: memory management 101
MS Technet: the /3GB switch
MSKB 4GB RAM Tuning
MSDN blog: the /3GB switch
MSDN blog: /3GB Kernel consequences
Brian Madden blog: 4GB Limit


0807.14 · 6962 page accesses · Copyright ©2008 David R. Green · All Rights Reserved.