MatthewMartin
MatthewMartin

Reputation: 33193

What is the most memory Visual Studio can use on a 32bit Windows Server 2003 OS?

It is well known that on XP Pro the whole OS can only use 3GB. On 32 Bit Windows Server 2003 the limits are higher. How much can visual studio address and use if the OS isn't imposing artificial constraints?

Background. I have 4GB, use Resharper, get lots of out of memory errors and I'm wondering if throwing more hardware at the problem would help.

Upvotes: 3

Views: 2636

Answers (7)

Matthew Vines
Matthew Vines

Reputation: 27581

2 Gigabytes on x86 by default

Steven Harman put out a very useful blog post in 2008 about extending the memory available to Visual Studio to 3 Gigabytes.

The problem is with Visual Studio. Being a 32-bit application it's limited to just 2GB of virtual memory, even if it's running in a 64-bit OS. At least, it's limited to 2GB by default... but we can change that.

So the trick to extending it is increasing the amount of user-mode memory, and then making Visual Studio Large address aware.

I have successfully done this to 3GB. I do not know if there is an upper bound before hitting the OS limit.

Upvotes: 3

Remus Rusanu
Remus Rusanu

Reputation: 294487

devenv.exe is large address aware, so it can use 3GB if the system is booted with /3gb in the boot.ini. XP supports the /3gb flag.

Don't know where you gets your facts for 'well known' stories, but the XP 3GB OS limit, not true.

BTW, even if devenv.exe is large address aware, that does not guarantee that add ons will use the space above 0x7FFFFFFF so Resharper may still hit out of memory exceptions.

Upvotes: 0

Frozenskys
Frozenskys

Reputation: 4410

There are no artificial constraints on memory, if you are using a 32Bit OS then you are limited to 3GB of addressable memory space. If you use 64Bit then addressable memory space is much bigger.

The only way to get more memory for Visual Studio would be to enable AWE (if Visual Studio is AWE aware) or using the /3GB switch when booting windows.

Use a 64Bit processor (e.g. Core2) with a 64Bit OS to get the best performance as you can then access as much memory as you can stuff into your development box. ;)

Upvotes: 0

Jimmy
Jimmy

Reputation: 28456

The restraints per process should remain unchanged for any 32-bit OS. The default is 4GB of address space per process, with 2GB of that reserved for the OS itself. There is a flag for Windows which you can use to change it to 1GB of reserved memory and 3GB of userspace memory.

Upvotes: 0

waqasahmed
waqasahmed

Reputation: 3855

4GB - 256 GB depending on the version of Windows Server 2003 you have.

Here is the link: http://msdn.microsoft.com/en-us/library/aa366778(VS.85).aspx

Upvotes: -1

The Matt
The Matt

Reputation: 6620

2 Gigabytes on x86

Upvotes: 2

kemiller2002
kemiller2002

Reputation: 115548

Here is a link to the memory limits to windows

http://msdn.microsoft.com/en-us/library/aa366778(VS.85).aspx

Upvotes: 1

Related Questions