logo
Main

Forums

Downloads

Unreal-Netiquette

Donate for Oldunreal:
Donate

borderline

Links to our wiki:
Wiki

Walkthrough

Links

Tutorials

Unreal Reference

Usermaps

borderline

Contact us:
Submit News
  Welcome, Guest. Please Login or Register
 
  HomeHelpSearchLoginRegister  
 
 
Large Address Aware (4GB) support (Read 2077 times)
Hyper
YaBB Administrator
******
Online


It's Unreal.

Posts: 2330
Large Address Aware (4GB) support
01/14/08 at 17:13:43
 
When looking for some info about 64-bit apps I came across the following: 64-bit programming for Game Developers

Here I read about an option called "LARGEADDRESSAWARE" which gives 32-bit apps to use a maximum of 4 GB memory, instead of the normal 2 GB:

Quote:
Differences in Addressable Memory

The first thing most developers notice is that 64-bit processors provide a huge leap in the amount of physical and virtual memory that can be addressed.

    * 32-bit applications on 32-bit platforms can address up to 2 GB
    * 32-bit applications built with the /LARGEADDRESSAWARE:YES linker flag on 32-bit Windows XP or Windows Server 2003 with the special /3gb boot option can address up to 3 GB. This constrains the kernel to only 1 GB which may cause some drivers and/or services to fail.
    *

     32-bit applications built with the /LARGEADDRESSAWARE:YES linker flag on 32-bit versions of Windows Vista, and on 32-bit versions of Windows Server Code Name "Longhorn" operating systems, can address memory up to the number specified by the boot configuration data (BCD) element IncreaseUserVa. IncreaseUserVa can have a value ranging from 2048, the default, to 3072 (which matches the amount of memory configured by the /3gb boot option on Windows XP). The remainder of 4 GB is allocated to the kernel and can result in failing driver and service configurations.

     For more information about BCD, see Boot Configuration Data on MSDN.
    * 32-bit applications on 64-bit platforms can address up to 2 GB, or up to 4 GB with the /LARGEADDRESSAWARE:YES linker flag.
    * 64-bit applications use 43 bits for addressing, which provides 8 TB of virtual address for applications and 8 TB reserved for the kernel.


Quote:
It is a good practice to specify large-address-aware when building 32-bit applications, by using the linker flag /LARGEADDRESSAWARE, even if the application is not intended for a 64-bit platform, because of the advantages that are gained at no cost. As explained earlier, enabling this flag for a build allows a 32-bit program to access more memory with special boot options on a 32-bit OS or on a 64-bit OS. However, developers must be careful that pointer assumptions are not made, such as assuming that the high-bit is never set in a 32-bit pointer. In general, enabling the /LARGEADDRESSAWARE flag is a good practice.


Since I already experienced a few server crashes caused by Unreal.exe running out of memory*, I like to ask if Unreal 227 (32-bit version) can be compiled with LARGEADDRESSAWARE enabled. This will allow Unreal to have twice as much operating space on 64-bit systems.


*This can occur on a (coop) server with a long uptime and with many additional content loaded. It can especially occur at coop because it saves the inventories of any player joined.
Back to top
« Last Edit: 01/14/08 at 21:00:36 by Hyper »  
WWW WWW  
IP Logged
 
[]KAOS[]Casey
Ex Member
******


nedm

Gender: male
Re: Large Address Aware (4GB) support
Reply #1 - 01/14/08 at 21:16:36
 
I havent had that error in years unless someone debug eatmems me, i did change my cachesizemegs though Tongue
Back to top
 
 
IP Logged
 
Hyper
YaBB Administrator
******
Online


It's Unreal.

Posts: 2330
Re: Large Address Aware (4GB) support
Reply #2 - 01/15/08 at 07:26:54
 
[]KAOS[]Casey wrote on 01/14/08 at 21:16:36:
I havent had that error in years unless someone debug eatmems me, i did change my cachesizemegs though Tongue


This has nothing to do with cachesizemegs. Cachesizemegs is an irrelevant setting for servers anyways.
Back to top
 
WWW WWW  
IP Logged
 
Smirftsch
YaBB Administrator
******
Online



Posts: 6005
at home
Gender: male
Re: Large Address Aware (4GB) support
Reply #3 - 01/15/08 at 08:53:46
 
I remember I read about this option. Not sure if the VC++ I have supports it. Need to check.
But I think a memleak is probably to be blamed that it eats that much memory over the time...
Back to top
 

Sometimes you have to lose a fight to win the war.
WWW WWW Smirftsch 52832995  
IP Logged
 
[]KAOS[]Casey
Ex Member
******


nedm

Gender: male
Re: Large Address Aware (4GB) support
Reply #4 - 01/15/08 at 09:36:23
 
hmm, never seen my servers crashing from lack of memory when they've been running 5 days, even with that ludcirous mod and hundreds of monsters an hour
Back to top
 
 
IP Logged
 
Hyper
YaBB Administrator
******
Online


It's Unreal.

Posts: 2330
Re: Large Address Aware (4GB) support
Reply #5 - 01/15/08 at 11:52:53
 
Smirftsch wrote on 01/15/08 at 08:53:46:
I remember I read about this option. Not sure if the VC++ I have supports it. Need to check.
But I think a memleak is probably to be blamed that it eats that much memory over the time...


Micosoft may have some info here about Visual C++ and LargeAddressAware.
http://msdn2.microsoft.com/en-us/library/wz223b1z.aspx

For me the out-of-memory errors begun gradually when my server became more and more stable. When the runtime of the unreal.exe server exceeds one or two weeks it may start to run out of memory at my system. (32-bit, 2 GB RAM, 4 GB pagefile) I'll soon switch to 64-bit to give the system more headroom. THe error became much more frequent after adding Nephthys 1.3 with http redirecting; for some reason the large file packages I use seem to have pushed it over the limit. Therefore I no longer use NPT 1.3 redirect. (According to Zora, Nephthys is not likely to have broken it)

But also for general future readiness I can recommend to allow 4 GB of mappable memory. Otherwise we may reach this hard-limit later on, for example with additional large texture packs. I don't know when we will hit the roof. But before that happens we can better increase the headroom now.

By the way:
Yesterday I read about an option to set LargeAddressAware manually as end-user. Appearantly it is only a flag (bit) in the .exe header, similar to the SMP support flags. (See DualCoreFix at my site) But I still would like to request it as a default setting, because not many users will like to fiddle with this and exe header modifications may not be compatible by u227 CRC checking.
Back to top
« Last Edit: 01/15/08 at 12:32:35 by Hyper »  
WWW WWW  
IP Logged
 
Zombie
YaBB Administrator
Developer Team
******
Offline


Living Dead

Posts: 321
Re: Large Address Aware (4GB) support
Reply #6 - 01/15/08 at 20:38:17
 
Quote:
Since I already experienced a few server crashes caused by Unreal.exe running out of memory*, I like to ask if Unreal 227 (32-bit version) can be compiled with LARGEADDRESSAWARE enabled.

Do you mean these crashes already happened in 227? Otherwise, I would figure this out-of-VM problem may already be fixed in 227.

I guess one can't be sure 227 is fine until Hyper runs an uptime of 14+ days. Smiley

Quote:
THe error became much more frequent after adding Nephthys 1.3 with http redirecting; for some reason the large file packages I use seem to have pushed it over the limit. Therefore I no longer use NPT 1.3 redirect. (According to Zora, Nephthys is not likely to have broken it)

I think that problem may be fixed for you if you ran v1.4. A change listed in v1.4 is to perform upload checksum calculations in smaller chunks (smaller mem allocations), and the calculation in v1.3 was the trigger before.


-Zombie
Back to top
 
 
IP Logged
 
Hyper
YaBB Administrator
******
Online


It's Unreal.

Posts: 2330
Re: Large Address Aware (4GB) support
Reply #7 - 01/15/08 at 21:09:59
 
Zombie wrote on 01/15/08 at 20:38:17:
Quote:
Since I already experienced a few server crashes caused by Unreal.exe running out of memory*, I like to ask if Unreal 227 (32-bit version) can be compiled with LARGEADDRESSAWARE enabled.

Do you mean these crashes already happened in 227? Otherwise, I would figure this out-of-VM problem may already be fixed in 227.


Nope, I haven't had much uptime at all with u227 beta testing. Usually only a few hours to a day before I got an unhandled application crash.

Quote:
I guess one can't be sure 227 is fine until Hyper runs an uptime of 14+ days. Smiley

Quote:
THe error became much more frequent after adding Nephthys 1.3 with http redirecting; for some reason the large file packages I use seem to have pushed it over the limit. Therefore I no longer use NPT 1.3 redirect. (According to Zora, Nephthys is not likely to have broken it)

I think that problem may be fixed for you if you ran v1.4. A change listed in v1.4 is to perform upload checksum calculations in smaller chunks (smaller mem allocations), and the calculation in v1.3 was the trigger before.


-Zombie


Interesting. But with I expect soon to update to the next u227 beta, so no npt 1.4 for me yet.
Back to top
 
WWW WWW  
IP Logged
 
(Moderators: Smirftsch, .:..:)