Share via


The 3GB-not-4GB RAM problem

Problem statement:
I just bought a system with 4GB of physical RAM in it. The BIOS posts 4GB, but Windows tells me that I have anywhere from 2.75 - 3.5GB of RAM. Where is the rest of my RAM?

Summary:
If you are running 32-bit Windows, you must live with it. You will not ever see all 4GB of RAM you've paid for.

If you are running 64-bit Windows, you may have to live with it. Depending on your motherboard's chipset, your system may support memory remapping. If so, you will be able to use all 4GB of RAM.

Detailed:
Due to an architectural decision made long ago, if you have 4GB of physical RAM installed, Windows is only able to report a portion of the physical 4GB of RAM (ranges from ~2.75GB to 3.5GB depending on the devices installed, motherboard's chipset & BIOS).

This behavior is due to "memory mapped IO reservations". Those reservations overlay the physical address space and mask out those physical addresses so that they cannot be used for working memory. This is independent of the OS running on the machine.

Significant chunks of address space below 4GB (the highest address accessible via 32-bit) get reserved for use by system hardware:

• BIOS – including ACPI and legacy video support

• PCI bus including bridges etc.

• PCI Express support will reserve at least 256MB, up to 768MB depending on graphics card installed memory

What this means is a typical system may see between ~256MB and 1GB of address space below 4GB reserved for hardware use that the OS cannot access. Intel chipset specs are pretty good at explaining what address ranges gets reserved by default and in some cases call out that 1.5GB is always reserved and thus inaccessible to Windows.

When looking at memory in systems (be it desktop or notebook) there are three questions to ask that will tell you the maximum amount of memory your O/S will be able to use:

1. What O/S Edition have you installed?

a. 32-bit Windows is limited to a maximum of 4GB and cannot see any pages above 4GB.

b. 64-bit Windows can use between 8GB and 128GB depending on SKU.

2. What address range can your processor actually access?

a. Typically that’ll be 40-bit addressing today for x64 (Intel EM64T/AMD64), but older processors may be limited to 36-bit or even 32-bit

3. Can your system’s chipset map memory above 4GB?

a. Mobile chipsets on sale today cannot (but that may change with time)

b. Newer workstations (which use chipsets developed for single or multi-proc servers) usually can.

Windows can remap memory from below 4GB to above 4GB and use it there, however, that relies on the three points above:

1. Can Windows access memory above 4GB?

a. 32-bit – NO

b. 64-bit – Maybe (due to chipset limitations)

2. Can your processor access memory above 4GB?

a. If it’s recent then it might, and if it’s either AMD64 or EM64T it’s almost certain

3. Does your chipset allow pages to be remapped above 4GB?

a. Probably not – and that’s what’s catching people who install 64-bit Vista to work around point 1 – they find they still cannot see above 4GB

In some cases, OEMs may be able to tweak their BIOS to reserve less memory for platform use, but we’re not talking a huge difference (ie, 100’s of MBs).

In the end a 32-bit OS and/or application can only, ever, handle 4GB of memory at a time, the AWE stuff just swaps chunks of memory in and out of that 4GB space, thus fooling the application and OS into using more space than it can “see”.

Physical Address Extension (PAE), extends the physical address space to 36-bits if your HW supports this. For most operations, the processor execution units will only see 32-bit addresses, the MMU will take care of the translation to 36bit addresses. No swapping here, only page translations (which are used regardless of PAE being on or not), this is a fundamental feature of any virtual memory operating system.

The OS and apps only see 32-bit addresses because the registers are limited to 32-bits (hence the “32-bit” architecture nomenclature). These are linear addresses which are extended to 36-bits in the translation to physical addresses, but they never show up in registers since there’s no room. It’s all internal until the address lines coming out of the chip are toggled. Thus my comment above about “if your H/W supports this (PAE)". I’m not going into how that works…

So, the OS can happily handle up to 64 GB of memory for 32-bit PAE-able systems.

Hope this helps explain the whole, ‘Why can’t I see 4 Gig of RAM in my system?” thing…

BTW – This does not change for Vista either…

references:
https://support.microsoft.com/kb/929605/en-us

HWJunkie DL (MSFT internal)

Bob Heath (original author of this summary material)

Comments

  • Anonymous
    April 13, 2007
    Windows doesn't see 4GB. If you have a 32bit OS with 4GB of RAM, Windows can't see it all.I saw this...

  • Anonymous
    April 14, 2007
    The comment has been removed

  • Anonymous
    April 15, 2007
    In some cases, you can regain some memory (make it visible to  Windows) by placing some switch in boot.ini. I don't remember the exact switch name, but in my particular system this changed the value shown by windows from 3GB to 4GB. On another system, however, it changed the value from 3GB to 3.5GB only.

  • Anonymous
    April 15, 2007
    The comment has been removed

  • Anonymous
    April 15, 2007
    You can give more memory to the application using /3GB switch in boot.ini, that will give more memory to the application and less to the OS, we use it for almost every 32-bit SQLserver. I am not sure how that works on Vista/Longhorn - Vista apparently does not have boot.ini at all.

  • Anonymous
    April 15, 2007
    I believe the /3GB switch is only useful for applications that are specifically coded to take advantage of it, like SQL Server. Vista does not have boot.ini, but most of the same options can be set through the new boot configuration editor.

  • Anonymous
    April 16, 2007
    I’ve seen several asking about how much memory Windows Vista will use. MSDN has a great blog explaining

  • Anonymous
    January 03, 2008
    The best explanation of this I have yet found is here ; with this article as a supplement. This explanation