qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] configure: Support system emulation with large memory on w32 hosts
@ 2012-07-18 16:37 Stefan Weil
  2012-07-20  3:53 ` Alexey Kardashevskiy
  0 siblings, 1 reply; 8+ messages in thread
From: Stefan Weil @ 2012-07-18 16:37 UTC (permalink / raw)
  To: Alexey Kardashevskiy; +Cc: Stefan Weil, qemu-devel

32-bit applications on Windows normally only get virtual memory in
the lower 2 GiB address space.

Because of memory fragmentation, VirtualAlloc() usually won't get 1 GiB
of contiguous virtual memory in that address space. Therefore running
system emulations with 1 GiB or more RAM will abort with a failure.

The linker flag --large-address-aware allows addresses in the upper 2 GiB.
With this flag, it is possible to run emulated machines with up to
2047 MiB RAM.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
---

I tested the executables with large address awareness on a 64 bit Windows
(works) and with Wine on Debian 32 bit Linux (no longer aborts, but hangs
when 1024 or more MiB are requested).

Maybe the support for large addresses is broken in my Wine version.
Please report any different test results.

Regards,

Stefan Weil


 configure |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/configure b/configure
index df5c99a..b681f9a 100755
--- a/configure
+++ b/configure
@@ -2937,9 +2937,9 @@ else
     POD2MAN="pod2man"
 fi
 
-# Use ASLR, no-SEH and DEP if available
+# Use ASLR, large addresses, no-SEH and DEP if available
 if test "$mingw32" = "yes" ; then
-    for flag in --dynamicbase --no-seh --nxcompat; do
+    for flag in --dynamicbase --large-address-aware --no-seh --nxcompat; do
         if $ld --help 2>/dev/null | grep ".$flag" >/dev/null 2>/dev/null ; then
             LDFLAGS="-Wl,$flag $LDFLAGS"
         fi
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-07-23 18:33 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-18 16:37 [Qemu-devel] [PATCH] configure: Support system emulation with large memory on w32 hosts Stefan Weil
2012-07-20  3:53 ` Alexey Kardashevskiy
2012-07-20  5:23   ` Stefan Weil
2012-07-20  5:37     ` Alexey Kardashevskiy
2012-07-20  6:05       ` Alexey Kardashevskiy
2012-07-20  6:38         ` Alexey Kardashevskiy
2012-07-20 17:19           ` Stefan Weil
2012-07-23 18:32             ` Blue Swirl

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).