I will post random crap here! Mainly random crap that I find intriguing.
Published on February 7, 2008 By Servius In Technical
I don't know how many of you are playing this on vista 32 bit version, but if you are after a few hours or so your game might crash for no apparent reason. Reason: The game runs out of address space. Vista 32 bit is limtied to 2048mb of it and after a while it gets used up and your game gets pwned. However you can fix this-

1. Open the Command prompt as Administrator in Vista: (Start > All Programs > Accessories > right click Command Prompt > Choose run as Administrator)

2. Enter BCDEDIT /set IncreaseUserVa 2600 into the prompt, You can set it higher as I have mine at 3048 and haven't received a random crash due to memory error since.

3. Once you have done the above step, restart PC and run sins. After your done playing you should set the number back to 2048 and restart again.

4. Additionally you should install this update from microsoft:


940105 Update
Comments
on Feb 07, 2008
The Vista patch update is definitely a great recommendation for all gamers.

Although I would love to back you up with this kind of post, their is one issue, Sins of a Solar Empire.exe is NOT large address aware. Meaning the application will not pass the 2GB virtual address space barrier, regardless if you set the OS to.

So that is kind of strange that you changing the UserVirtAddrs space of the OS helped you.
I'll be interested to hear if people actually run into this issue more. I use Xp and have no issues but that could just be because it definitely uses a smaller address space footprint than Vista even after that patch.
on Feb 07, 2008
A better fix is to just use the 64-bit version of Vista. If your computer is incapable of running Vista x64, then Windows XP is better suited for you as an operating system.

Vista x64 runs 32-bit programs natively and with no emulation or performance loss. Any reputable hardware vendor is going to have 64-bit drivers. Any competent software vendor is going to provide programs that at a minimum run in an x64 environment without compatibility issues.

There is no reason to run 32-bit Vista at all. Vista takes up more memory and only serves to further constrain an already limited address space. All Vista licenses (with the exception of Home Basic) are good for both the 32-bit and 64-bit editions; your key will work in either. Frankly, Microsoft should have never released a 32-bit version of Vista because 32-bit operating environments are rapidly becoming unsuitable for the latest and greatest programs due to address space limitations and it only delays the transition to 64-bit.

Regarding your BCDEdit tweak, it's not advisable. There is a reason why 2 gigabytes of address space is reserved for the kernel and it has nothing to do with that hotfix (which deals with memory usage in the usermode half). By reducing the amount of address space available to the kernel, you can cause the kernel to run out of memory which will lead to stability problems with your computer. Even if it works right now, a software or hardware change could break the configuration down the line.

See : http://blogs.msdn.com/oldnewthing/archive/2004/08/22/218527.aspx
on Feb 07, 2008
Well, I kept getting the error for other games as well and found this fix for it. Since I have enabled it sins hasn't crashed on me for no reason. So I just assumed this was the problem. But, yes the update is a must if you play most other games on vista.

Edit* You are right dcatz thats why I set it back after playing my games. Its recommended to set it back most definitely.
on Feb 07, 2008


3. Once you have done the above step, restart PC and run sins. After your done playing you should set the number back to 2048 and restart again.



why should i set the pc back to 2048 mb? what would happen to the comp if it is left at 3048?
on Feb 07, 2008
A lot of what dcatz said about Vista is not very good advice (however his advice against using BCEdit is right on the money). Far more programs (both gaming and productivity) have incompatibility problems with Vista 64-bit than do Vista 32-bit. Additionally, Vista 64-bit will not allow loading of unsigned drivers. A large portion of peripheral manufacturers are not providing 64-bit driver support for Vista "b/c the demand isn't there" or "never had intentions of supporting Vista 64-bit in the first place". In theory 64-bit Vista is better than 32-bit, but its mired by support issues from 3rd party vendors (not really the fault of Vista or MS).

With the appropriate patches applied, Vista 32-bit is mostly fine (see that KB940105 patch linked in the first post for a critical gaming fix). Many other patches have come out over the past 11 months that fix other memory and compatibility issues and have put Vista in good place (better than XP was 1 year out from its release. Everyone seems to forget the cries back then of "XP is crap. Stick with 98SE forever!". They're the same cries we see now, just swap Vista for XP and XP SP2 for 98SE.) The reason Vista uses more memory is because it keeps portions of your most used files and programs in memory most of the time for faster loading. If something you're using needs to kick them out, it will. Just because you used to sit there at 10% memory used while idle in XP doesn't mean that's necessarily the optimal state to be at in Vista. People need to compare apples to apples, but in this case it's really more like apples and pears.

All that said, I would not recommend running Vista w/o at least 2GB of memory installed. And there's really no reason not to be running 2GB of RAM when that much only costs $35-$50 these days.
on Feb 07, 2008
Far more programs (both gaming and productivity) have incompatibility problems with Vista 64-bit than do Vista 32-bit.

This needs some clarification because, for the most part it is misleading. 32-bit Vista has fewer compatability problems with very old software titles, to be specific, those that use 16-bit 'code' (vague, but it's complicated and boring) as the 64-bit version (XP and/or Vista) can not run any 16-bit application or any application that uses any 16-bit code such as older libraries, etc. The majority of Vista compatability issues with games are Vista related and not specific to 64-bit. I ran 64-bit XP for two years before changing to 64-bit Vista a couple of weeks ago and have run into very few compatability problems (ok, one to be more precise, with Civ4 multiplayer) and none that were solely cause by 64-bit compatability. There are quite a few viruses and worms that won't run at all on 64-bit Windows (XP or Vista) if you want to include them with the compatability issues

Additionally, Vista 64-bit will not allow loading of unsigned drivers. A large portion of peripheral manufacturers are not providing 64-bit driver support for Vista "b/c the demand isn't there" or "never had intentions of supporting Vista 64-bit in the first place". In theory 64-bit Vista is better than 32-bit, but its mired by support issues from 3rd party vendors (not really the fault of Vista or MS).

You can use unsigned drivers, the 64-bit version hides the option to disable it because very few people understand that they MUST use a 64-bit driver on a 64-bit OS without exception even for something as simple as a mouse driver and at the same time not all companies include 64-bit drivers on the media distributed with the product. I'm curious about who falls into the 'large portion of peripheral manufacturers' though, the only hardware I had to replace due to the lack of a 64-bit driver was an OLD HP printer that I had since the late '90s and I made my transition to 64-bit before Vista was unleashed on the masses. XP 64-bit was generally considered an unsupported OS by just about everybody.

on Feb 07, 2008
Look, nobody here is going to go out and drop over 100$ on an OS just because you say so, if you don't have anything more constructive than "Install Lunix/XP, problem solved" then please, go to HardOCP or Anandtech or somewhere else that cares.
on Feb 07, 2008
A better fix is to just use the 64-bit version of Vista. If your computer is incapable of running Vista x64, then Windows XP is better suited for you as an operating system.


For one thing that isn't a quick fix. Secondly, the 64 bit OS still runs 32 bit apps with a limit of 2GB application address space 'each' (one benefit is 'each' since the pool from the OS is much larger). 32 bit "large address aware" apps (which Sins isn't) on a 64 bit OS have 4GB address space available to them. while native 64 bit apps into the TB. Do the research, that is 100% accurate.

Regarding your BCDEdit tweak, it's not advisable. There is a reason why 2 gigabytes of address space is reserved for the kernel and it has nothing to do with that hotfix (which deals with memory usage in the usermode half). By reducing the amount of address space available to the kernel, you can cause the kernel to run out of memory which will lead to stability problems with your computer. Even if it works right now, a software or hardware change could break the configuration down the line.


5-10 years ago that was sound logic. Today if people have properly coded drivers(98%) I can recommend they change application address space on 32 bit OS's "if" they have applications that require or benefit. If you don't have the applications that benefit (Sins is one that "cannot" use above 2GB regardless) you shouldn't change it. So I am curious why that helped the OP as Sins is still hard limited <2GB virt addr space. People should know what they are doing and why, most people lack scope on how memory management works in Windows, especially grasping virtual address space. Personally I use Photoshop , Google Earth (modified), as well as several other games(SupCom, COH, etc) and apps that enjoy having >2GB application address space available too them on XP which I run /3GB consistently. Their is no deleterious performance or stability issues arising from lowering the kernel space if done wisely, or maybe even unwisely for that matter, although many cry wolf without proof, there is some proof to the contrary that performance is unaffected. The lack of ability to see what all addresses are mapped to, outside of the windows debugger, makes proving this difficult, as well as each machine mapping things uniquely dependant on it's unique devices. 100% of PC's cannot run with the application space changed and a couple percent will crash on bootup so someone better know how to recover from that with Vista . The OP raising it to 3048 isn't necessary at all (more is not better). MS usually suggests 2800 because it allows some leeway. Also I would actually make a seperate boot option than changing the only existing one. /3GB and /userva options are valid and beneficial for those stuck with 32 bit OS's, not having migrated to 64 bit yet, with the apps that need more resources. I know people can find opinions to the contrary, I have read them all. It's another case of people fearing what they don't understand, but in honesty people shouldn't be faulted for playing it safe either.

To discuss the merits of this subject is usually far beyond the scope of a gaming environment like this although gaming is where the 2GB barrier is most infamous lately. Some of these specific memory issues people have experienced may be due to other issues too (bad sticks with certain addresses, DEP, etc.). Someone needs to actually track the real address space usage (cannot be found in task manager) to know if this is the "real" problem.

Anyone without the Vista hotfix, as well as a videocard with large local memory, is bound to run into the 2GB address space limit at some point. Make sure you all have the hotfix.

The reason Vista uses more memory is because it keeps portions of your most used files and programs in memory most of the time for faster loading.


Your talking about RAM usage with superfetch. None of that has anything to do with the real issue of this thread of usermode app address space usage (which also has nothing to do with how much RAM someone has or virtual memory assigned as a paging file). It can be confusing if people don't delineate, just clarifying.
EDIT: I can see now you were replying to dcatz on memory usage in Vista. But seriously Vista does have quite a bit larger memory footprint than XP (180MB at install), superfetch or no superfetch.

Also, as an FYI it is now a fact that Vista uses larger amounts of virtual application address space than XP in the same games. So Vista will hit the 2GB userva limit before XP, even after the much needed Vista hotfix.

Only reason I can speak with some authority on the subject is because I did my research in the subject far beyond reading articles on it, which I also have done thoroughly. But who am I kidding, the value of an opinion on the internet is about zilch. Take it for what it's worth.

Anyone that would like to learn more about this as it pertains to gaming can see the 3 part series at Anandtech:
part 1]
part 2
part 3

on Feb 08, 2008
No one is telling anyone to buy an OS. The same Vista license that you use for 32-bit Vista is good for the 64-bit edition.

1.Driver signing IS NOT the same thing as WHQL. Don't believe everything you read on the internet. (Especially anything Peter Gutman has said)

Anyone can buy a code signing certificate from a CA like Verisign and sign away to their hearts content without ever having to go through Microsoft.

Code signing merely ensures two things :

A.The driver is from who it claims to be
B.The driver hasn't been altered since it was packaged (such as by a virus)

2.The majority of 32-bit applications work fine in a 64-bit environment. The AMD64 extensions were designed specifically to make the transition to 64-bits as easy as possible.

3.The only 16-bit programs that a home user is likely to run into are 16-bit installers. Which work fine under 64-bit Windows because Microsoft hard-coded in support for them.

4.95% of the time, when an application has an incompatibility with Vista or 64-bit Windows in general, it can be chalked up to either laziness or sloppy programming. The 5% exception are those that do low-level system stuff. The biggest cause of compatibility issues are programs written by developers who still haven't figured out that Windows is no longer a single-user environment and try to store settings in Program Files and/or HKLM.

5.Any recent hardware that is released with 64-bit drivers should be avoided like the plague.

6.I maintain that the /3GB switch is a bad idea. If it causes something to break, it causes unneeded headaches, is difficult to track down and wastes time with tech support.

Microsoft themselves have stated that the /3GB switch is not advisable. That blog link I posted was written by Raymond Chen, one of the developers who works on Windows. If you need more than 2 gigabytes of user-mode address space, you should be using a 64-bit operating system.
on Feb 08, 2008
6.I maintain that the /3GB switch is a bad idea. If it causes something to break, it causes unneeded headaches, is difficult to track down and wastes time with tech support.

Microsoft themselves have stated that the /3GB switch is not advisable. That blog link I posted was written by Raymond Chen, one of the developers who works on Windows. If you need more than 2 gigabytes of user-mode address space, you should be using a 64-bit operating system.


Fine you can maintain that idea that the 3GB switch is bad, it's your right, but instead you are recommending a 64 bit OS as a solution that does nothing to solve this particular problem. The Application is still limited to 2GB address space. So while you maintain caution (which is not a bad thing like driving in the fog) your advice misses the mark as a solution. The binary just isn't qualified to use above 2GB, otherwise the devs would have enabled it to be.

I read all those blogs, some several times over in the past. He and Ask Dan, the other articles anti-3GB switch people like to quote, take a somewhat aggressive approach against it because it is misused due to people's ignorance. To the general public that don't "need" a 3GB switch, of course it's not to be recommended. People who should know better in their position misuse it all the time, it aggravates me too at times. It's like I don't recommend plastic bags be given to children, it doesn't mean the bags aren't useful when used for the purpose they are designed for and responsibly. System administrators and SQL administrators have used it for a decade. XP and Vista 32 both support it(by Microsoft's intent), and I for one am very thankful because I use it with purpose constantly without issue.
on Feb 08, 2008
Wait, so, Raymond Chen doesn't know the operating system he helped program?

I said that if you needed more than 2 gigabytes of usermode address space, that you should be using a 64-bit operating system. Moving to a 64-bit operating system provides the same result (actually greater since all 4 gigabytes of a 32-bit address space are available to LAA executables) as the /3gb switch except that it's not a hack and it's not using 20 year old technology.

I might also add that, regarding largeaddressaware; with a copy of bintools you can make any *properly written* 32-bit executable (one that doesn't make hardcoded assumptions about the address space size) take advantage of the extra address space. It's not something a layman should do but it works fine 90% of the time and I've used bintools many times in the past to deal with stubborn 32-bit programs that run out of address space (such as Supreme Commander).
on Feb 08, 2008
Wait, so, Raymond Chen doesn't know the operating system he helped program?


Don't be silly. He didn't say it's evil. He worked on the OS, yet it's included in the OS, how do you resolve that one?
I'm really not interested in arguing with you. I make my points to educate, not play know it all or see who can out do the other with links or tech jive, etc. You've obviously got your mind made up. The point I am making there are times it works just fine and it can be beneficial, a point you fail to appreciate.

Well considering I wrote the /3gb public stickied workaround for SupCom, I have used editbin too, so there.
So you have used the poison you preach against.

Moving to a 64-bit operating system provides the same result


What same result? The 32 bit process is still limited to the 2GB user address space, so that is the "same result", the 64 bit OS does nothing to this specific issue in this specific thread which is what is being discussed (if this game 'really' suffers from that cause). The /3gb works fine for many regardless if you want to call it a hack.

The reason /3GB isn't used automatically and by default in a 32 bit OS is the same reason a 32 bit OS still exists and that MS haven't left it behind entirely to move on to 64 bit exclusively. Because programmers are still not ready to write 64 bit safe code above 80000000. Otherwise /3gb would be fine by default in a 32 bit OS, which for many current mainstream drivers (not made in some remote closet) it is. The kernel isn't starving.

It can work well if used responsibly regardless if you, or anyone else, disapproves. Thanks for your input but I've said all I needed to on the subject for people willing to learn, feel free to preach the ills of /3Gb. Each case is unique.
on Feb 08, 2008
Holy hell guys, this was just a help thread not a debate thread on xp vs vista or 32bit versus 64bit operating systems. And the reason my game was crashing wasn't because of the original post, though I still have to use to play other games.
on Feb 10, 2008


3. Once you have done the above step, restart PC and run sins. After your done playing you should set the number back to 2048 and restart again.



why should i set the pc back to 2048 mb? what would happen to the comp if it is left at 3048?


... well?