www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Large Address Aware W/ OptLink

reply dsimcha <dsimcha yahoo.com> writes:
Is there a way to make optlink link D programs in large address aware mode so
that I can at least use 4 GB of address space instead of 2 on Win64 until DMD
is ported to 64-bit?
May 06 2010
next sibling parent reply torhu <no spam.invalid> writes:
On 07.05.2010 04:45, dsimcha wrote:
 Is there a way to make optlink link D programs in large address aware mode so
 that I can at least use 4 GB of address space instead of 2 on Win64 until DMD
 is ported to 64-bit?
You can supposedly use the editbin tool that comes with msvc to enable large address aware mode. http://msdn.microsoft.com/en-us/library/203797te.aspx
May 06 2010
parent dsimcha <dsimcha yahoo.com> writes:
== Quote from torhu (no spam.invalid)'s article
 You can supposedly use the editbin tool that comes with msvc to enable
 large address aware mode.
 http://msdn.microsoft.com/en-us/library/203797te.aspx
Thanks. I haven't tested this extensively in terms of whether there are any runtime bugs w.r.t. it, but it does at least allow me to allocate 4 GB of address space. Any bugs would have to be platform specific because on 64-bit Linux, 32-bit executables can use all 4 GB of address space by default.
May 07 2010
prev sibling parent reply Lionello Lunesu <lio lunesu.remove.com> writes:
On 7-5-2010 10:45, dsimcha wrote:
 Is there a way to make optlink link D programs in large address aware mode so
 that I can at least use 4 GB of address space instead of 2 on Win64 until DMD
 is ported to 64-bit?
Are you sure DMC's clib and phobos are large address aware? IIRC, there are quite some places where pointers are being compared. L.
May 06 2010
parent Walter Bright <newshound1 digitalmars.com> writes:
Lionello Lunesu wrote:
 On 7-5-2010 10:45, dsimcha wrote:
 Is there a way to make optlink link D programs in large address aware mode so
 that I can at least use 4 GB of address space instead of 2 on Win64 until DMD
 is ported to 64-bit?
Are you sure DMC's clib and phobos are large address aware? IIRC, there are quite some places where pointers are being compared.
Pointers are always compared using unsigned comparisons. I'm not aware of any problems in the code gen or libraries in this regard.
May 06 2010