You are probably using gcc to link the application. If so, add

-Wl,--large-address-aware

to gcc flags when building it and the exe would be able to use 3GB of
memory instead of 2.

That option worked for my gcc-compiled app on Windows 7 64 bit.



2014-12-16 1:37 GMT+02:00 Rashad M <mohammedrasha...@gmail.com>:

> Hello,
>
> On Tue, Oct 28, 2014 at 3:54 AM, Rashad M <mohammedrasha...@gmail.com>
> wrote:
>>
>>
>>
>> On Tue, Oct 28, 2014 at 12:51 AM, Kai Tietz <ktiet...@googlemail.com>
>> wrote:
>>
>>> Hi Rashad,
>>>
>>> 2014-10-27 20:13 GMT+01:00 Pavel <pa...@pamsoft.cz>:
>>> > Hi Rashad,
>>> >
>>> > I believe this is given by the 32 bit implementation of Win32 API
>>> > (surprisingly, the API on 64bit systems is also called Win32, but is
>>> > implemented as 64bit). The system simply does not allow you to allocate
>>> > more memory. It even looks like the 3GB option (4GT) is maybe not
>>> > supported on Windows Vista/7/8 at all.
>>> >
>>> > Some interesting info can be found in this thread:
>>> >
>>> http://www.sevenforums.com/general-discussion/114715-4-gigabyte-tunning-windows-7-ultimate-32-bit.html
>>> >
>>> > some other info related to pre-Vista systems is here:
>>> > http://technet.microsoft.com/en-us/library/cc786709(v=WS.10).aspx
>>> >
>>> > Well, clearly - the answer is: if you want to allocate more than 2GB of
>>> > memory, use 64bit application.
>>> >
>>> > Pavel
>>>
>>> That's not quite true ;) Even if it sounds easy
>>>
>>> Hi Kai,
>>
>> Thanks for reply.
>>
>> On 32-bit OSes --large-address-aware has an effect of enabling up to 3
>>> GB of memory for a process, if all used DLL having this flag set too,
>>>
>>
>> all used DLL means from binuilts or gcc ?
>>
>
> sorry to bother again, but I am stick stuck on this part. how to add this
> option? I knew its a linker flag but from where do I start adding this?
> ld.exe,gcc.exe or just my application ?
>
>>
>>
>>> and the boot-options of the OS have special option.  Not recalling its
>>> exact name, but IIRC it was /4GB or something like that.  Google will
>>> tell you by searching for large address aware ...
>>>
>>
> I tried that too but didn't work
>
>>
>>
>>>
>>> On 64-bit the picture is different, as here this flag has indeed an
>>> effect even without addng boot-option.  Here a 32-bit process can get
>>> up to 4GB of usable process-space.
>>>
>>
>> On 64bit even without any special flags and less RAM 3GB my code is
>> working.
>>
>>>
>>> >>
>>> >> The page says that supported OS are XP and 2003 Server.
>>> >>
>>> >>
>>> >> why --large-address-aware linker option is not helpful. Can anyone
>>> >> explain this?
>>>
>>> See for more details on msdn links like
>>>
>>> http://msdn.microsoft.com/en-us/library/windows/desktop/bb613473%28v=vs.85%29.aspx
>>>
>>> Regards,
>>>
>>> Kai
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> _______________________________________________
>>> Mingw-w64-public mailing list
>>> Mingw-w64-public@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
>>>
>>
>>
>>
>> --
>> Regards,
>>    Rashad
>>
>
>
> --
> Regards,
>    Rashad
>
>
> ------------------------------------------------------------------------------
> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
> with Interactivity, Sharing, Native Excel Exports, App Integration & more
> Get technology previously reserved for billion-dollar corporations, FREE
>
> http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
> _______________________________________________
> Mingw-w64-public mailing list
> Mingw-w64-public@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
>
>
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to