available ram for 32bit single app in 64 bit OS with huge amount of ram

Discussion in 'Windows 64 Bit' started by ZF, Jan 8, 2009.

  1. ZF

    ZF Guest

    <sorry for my bad english>

    I would like to know who does "manage" the memory amount in this scenario:

    Vista64 (business, pro ... ) with 20 GB of ram.

    four 32-bit applications that run simultaneously

    Will all these applications use all the memory amount that they can manage
    (about 3,5 gb if I know correctly) or will they see only the first 3,5 gb of
    ram even if we have much more?

    I imagine this:

    00:00:10 - free ram 19,5 on 20 GB
    00:00:15 - start 32bit app #1
    00:00:16 - will app#1 see 3,5 gb or 3,0? let's suppose: 3,5 ; I now use all
    the ram app#1 can use.
    00:00:30 - free ram is now 16,0 on 20 GB
    00:00:31 - start 32bit app #2
    00:00:32 - will app#2 see 3,5 gb or 0?
    and so on.

    I hope it was clear enough.
    Can you help me?

    </sorry for my bad english>
    ZF, Jan 8, 2009
    1. Advertisements

  2. Each 32 bit application gets 4 GB of _virtual memory address space_. That's
    not quite the same thing as RAM, though it's often confused with RAM. IAC,
    for your purposes, each application is treated separately.
    Charlie Russel - MVP, Jan 8, 2009
    1. Advertisements

  3. ZF

    DevilsPGD Guest

    In message <> "ZF"
    Each application gets 2GB of private virtual address space, or if
    compiled with the /LARGEADDRESSAWARE switch then 4GB of private virtual
    address space.

    Each and every 32-bit application gets this same 2GB of address space
    regardless of whether you have 1GB or 20GB of memory on the physical

    With four 32-bit applications (with /LARGEADDRESSAWARE) each can use a
    full 4GB and you wouldn't necessarily be paging if you have 20GB of
    total system RAM.
    DevilsPGD, Jan 8, 2009
  4. Actually, they get the full 4 GB of virtual memory address space, they just
    don't know what to do with it, so ignore it. But the OS assigns them the
    space, so far as I know.
    Charlie Russel - MVP, Jan 8, 2009
  5. I would like to know if several 32-bit applications running at the same time
    on a 64-bit version of Windows will be able to utilize the actual RAM
    In other words, is Windows Vista 64bit able to spread out each 32-bit
    process virtual memory to RAM if the 64-bit system has for example 16GB of

    Magnus Flysjö, Jan 8, 2009
  6. ZF

    Bo Persson Guest

    Yes, the virtual addresses are mapped to any part of the physical
    memory. The limitation on 32 bit programs is the SIZE of the memory it
    can access.

    Bo Persson
    Bo Persson, Jan 8, 2009
  7. ZF

    ZF Guest

    i see that DevilsPGD said "With four 32-bit applications (with
    /LARGEADDRESSAWARE) each can use a
    full 4GB and you wouldn't necessarily be paging if you have 20GB of
    total system RAM."

    ZF, Jan 8, 2009
  8. ZF

    ZF Guest

    Many many thanks, Charlie! :)
    ZF, Jan 8, 2009
  9. ZF

    ZF Guest

    DevilsPGD wrote:
    if i, as a user and not a programmer, have a standard 32 application like
    (for example) Photoshop (CS3), Some MS Office apps (ver 2003) ... i can't
    compile, am I right? So it's impossible to me to use that switch, isn't it?
    that's great.
    can you clarify to me if that /LARGEADDRESSAWARE is something I can use or
    is only a programmer's matter?

    thanks DevilsPGD!
    ZF, Jan 8, 2009
  10. ZF

    ZF Guest

    Supposing I have 4 gb of ram, what happens if i open 4 apps and try to make
    them eat all the memory they can use?
    We said each 32bit app sees 2 or 4 gb (let's say 2 for now)
    every app sees 2 gb of free "memory address space", so we have 2+2+2+2 = 8
    .... I think the OS can resize the response of what's the total and the free
    available "memory address space" , right?

    so if isn't used they see 2 gb, but when they reach *really* the maximum
    memory usage ... what happens? :)
    ZF, Jan 8, 2009
  11. Only programmers. A 32-bit application either does, or does not, support
    creates within the program, and what compile time switches he uses. The vast
    majority of programs do NOT support >2GB.


    Charlie Russel - MVP, Jan 8, 2009
  12. ZF

    Dave Warren Guest

    In message <> "ZF"
    Without the /largeaddressaware 32-bit applications have access to 2GB of
    address space rather then 4GB, but it's still entirely private virtual
    address space, so your 16GB of RAM will still comfortably run 7 32-bit
    apps all using 2GB each (with a bit of breathing room) without requiring

    In other words, the answer to your initial question is: Yes. On a x64
    system multiple 32-bit applications can benefit from all physical RAM
    installed in the system. The only limitation is that each individual
    application is limited to 2GB/4GB.

    This isn't a problem for most applications, Office apps (as an example)
    don't generally consume anything near 2GB anyway, and will benefit more
    from the RAM being available for disk caching.
    Dave Warren, Jan 9, 2009
  13. ZF

    Bo Persson Guest

    Nothing much happens. :)

    The address spaces are all *virtual*, with either 2 or 4 GB to each
    program. Each program will have its memory mapped to RAM or to disk
    (the swap file), individually an dynamically allocated by the OS.

    If you have 4 GB of RAM and 200 GB of free disk space, a 64 bit
    program can use 204 GB. No problem!

    The 32 bit programs are limited by the fact that 32 bits can only
    count to 4G, then they run out of bits!

    Bo Persson
    Bo Persson, Jan 9, 2009
  14. ZF

    Doug Forster Guest

    Hi ZF,

    Hmm Charlie's not quite right there. You can set the flag afterwards with a
    MS utility called EditBin. It might not work of course for the other reasons
    Charlie said but many compiler tools will actually make code that handles
    the flag OK without any special programmer intervention. The other problem
    is finding the utility. It generally only comes with the MS Visual Studio
    tools but I believe it is in the free VC++ express package. If you can find
    it play with it at your own risk and backup the exe's before trying it.

    Doug Forster

    Doug Forster, Jan 12, 2009
  15. Hello!
    It's not 4 GB, but 3 GB if compiled with /LARGEADDRESSAWARE. The kernel
    still needs a memory range, but it just uses 1 GB of the 2^32 Bytes (4 GB).

    Günter Prossliner, Jan 12, 2009
  16. ZF

    Dave Warren Guest

    In message <> "Günter Prossliner"
    4GB in x64 though, which is both the newsgroup we're in, and was
    mentioned explicitly by the previous poster.
    Dave Warren, Jan 12, 2009
  17. In x64, it is 4GB, not 3GB. Which is what we're talking about here, Gunter.
    Charlie Russel - MVP, Jan 12, 2009
  18. ZF

    jabloomf1230 Guest

    NTCore's CFF Explorer (freeware) also can be used to set the flag:


    jabloomf1230, Jan 12, 2009
  19. Hi ZF,
    I wouldn't change the flag after the fact (after something has been compiled
    and is shipping). You're really creating unsupported scenarios, so if you
    run into something unexpected *caused* by the change, you'll be wasting the
    developer's time. Odds are, it wouldn't occur to him to ask whether you've
    done that sort of thing to begin with, and the dev/QA team has probably NOT
    tested that particular scenario (or else the flag would probably be set
    already), so you're really on your own.
    Homer J. Simpson, Jan 14, 2009
  20. It's also worth noting that editbin will break any Authenicode digital

    The reason that Large Address Aware is an opt-in flag is precisely because
    not all 32-bt software can successfully run with it enabled. Even something
    as simple as the difference between two memory locations can overflow a
    32-bit signed value and cause a crash. Now software developers should be
    looking at supporting LAA since it is an easy way to get double the amount
    of memory address space on Windows x64, but that's really not something
    end-users should be hacking into applications and expecting them to be

    Contact the supplier of the software and tell them you want a Large Address
    Aware or x64 native version of it.
    Chuck Walbourn [MSFT], Jan 14, 2009
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.