How to use more than 2GB memory on Windows XP?

How to make GiD use more than 2GB on Windows XP?

Two steps must be followed to achieve this: configure Windows so that it lets a process use more than 2GB and enable the application to use more than 2GB.

  1. Configuring MS Windows XP: add the flag /3GB to the Boot.ini file. To do this just open the Control panel , click on the System icon, on the Advanced options panel, then press the Configuration button of the Start and recuperation section. In this window click on the Edit button inside the System start section and the Notepad will pop-up with the Boot.ini file opened. In this file there should be a line like this:

    multi(0)disk(0)rdisk(0)partition(1)/WINDOWS="Microsoft Windows XP Professional" /fastdetect

    just add the /3GB flag at the end, like:

    multi(0)disk(0)rdisk(0)partition(1)/WINDOWS="Microsoft Windows XP Professional" /fastdetect /3GB
    

    Now the file must be saved, and MS Windows restarted

  2. Enabling the application: set the IMAGE_FILE_LARGE_ADDRESS_AWARE in the .exe file of the application. This can be accomplished in two ways:

    • linking the program with the flag /LARGEADDRESSAWARE - go to the Properties of your MS VisualStudio 2003 application project and look for the Linker section and the System branch. In the combo-box menu with label name Enable Large Addresses select the entry Support Addresses Larger Than 2Gigabytes (/LARGEADDRESSAWARE) .

    • setting this bit directly in the executable - using the program editbin.exe located in C:/Program files/Microsoft Visual Studio .NET/Vc7/bin like this:

      c:/(...)/Vc7/bin> editbin.exe /LARGEADDRESSAWARE /Path/To/The/Program.exe
      Afterwards this bit can be checked with the dumpbin.exe utility:
      c:/(...)/Vc7/bin> dumpbin.exe /headers /Path/To/The/Program.exe
      Among other things a line like this one should appear:

         Application can handle large (>2GB) addresses

Note 1: The /3GB flag only works on MS Windows XP. Although MS Windows 2000 also accepts this flag, it only lets the application use 2GB.

Note 2: If a 32bit application with the bit IMAGE_FILE_LARGE_ADDRESS_AWARE set is run on MS Windows XP 64bits edition , it can address 4GB of memory instead of 3GB.

Note 3: Avoid signed comparisons with pointers, pointers casting to integers (instead of unsigned integers) and hard-wired addresses.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值