This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

problem with heap, win32 error 487


Hi,

I am trying to run a simulation in C on my Win2K-machine (the simulation

runs perfectly on a Linux-PC)
The problem seems to be with the memory rquirements.
With certain parameters, I get some huge
3-dimensional arrays that require like 20-40MB RAM.
When I have a size of about 22MB the simulation works fine, when I
increase the array size by a factor of ~1.33 (should then still be below

but close to 32MB) it doesn't start with the error message
C:\cygwin\home\clevorn\wlan15\Main.exe: *** Couldn't reserve space for
cygwin's heap (0x20030000) in child, cygheap, Win32 error 487

I tried two solutions posted in the mailing list for similiar problems:

first:
the "gcc -Wl,--heap,50000000,--stack,--50000000 ..." solution
here the simulation fails at small array sizes too.

second:
the "gcc -mno-cygwin ..." solution
here the program does start, but the only thing that happens is, if you
look in the task manager, the process slowly "collects" memory for about

90 seconds until it recaches 32MB (33xxxkB) and than the process crashes

with the windows message " the exception unknown software exception
(0xc00000fd) occured in the application at location 0x6104b9ef". During
that time the VM Size increases with the same rate, only it start at
values like 4xxMB or 6xxMB, depending on the array size (I have 1 GB RAM

so the pure size of these value isn't the real problem).

I think that the size of slightly below or even above 32MB is the cause
of the problem. Is there a general problem with cygwin and running
programs that require this amount of memory. Is there a way around this
problem.

Thanks for your help!

Regards,

Thorsten

$ cygcheck -s -v -r

Cygnus Win95/NT Configuration Diagnostics
Current System Time: Thu Jul 12 15:56:20 2001

WinNT Ver 5.0 build 2195 Service Pack 1, RC 1.1

Path:   /usr/local/bin
        /usr/bin
        /bin
        /cygdrive/c/WINNT/system32
        /cygdrive/c/WINNT
        /cygdrive/c/WINNT/System32/Wbem
        /cygdrive/c/Program Files/Dazel/Output Envoy/bin
        /cygdrive/c/Program Files/Microsoft Visual
Studio/Common/Tools/WinNT
        /cygdrive/c/Program Files/Microsoft Visual
Studio/Common/MSDev98/Bin
        /cygdrive/c/Program Files/Microsoft Visual Studio/Common/Tools
        /cygdrive/c/Program Files/Microsoft Visual Studio/VC98/bin

SysDir: C:\WINNT\System32
WinDir: C:\WINNT

PWD = `/home/clevorn/wlan15'
USER = `Administrator'
MAKE_MODE = `unix'
HOME = `/home/Administrator'

NUMBER_OF_PROCESSORS = `2'
PROMPT = `$P$G'
LOGONSERVER = `\\PAI820ADDCAG01'
OS2LIBPATH = `C:\WINNT\system32\os2\dll;'
COMSPEC = `C:\WINNT\system32\cmd.exe'
!C: = `C:\cygwin\bin'
SYSTEMDRIVE = `C:'
HOSTNAME = `NJ9620TCLEVORN2'
INCLUDE = `C:\Program Files\Microsoft Visual
Studio\VC98\atl\include;C:\Program Files\Microsoft Visual
Studio\VC98\mfc\include;C:\Program Files\Microsoft Visual
Studio\VC98\include'
PROCESSOR_REVISION = `0806'
MSDEVDIR = `C:\Program Files\Microsoft Visual Studio\Common\MSDev98'
PATHEXT = `.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
COMPUTERNAME = `NJ9620TCLEVORN2'
WINDIR = `C:\WINNT'
USERPROFILE = `C:\Documents and Settings\clevorn.AGS'
PS1 = `\[\033]0;\w\007
\033[32m\]\u@\h \[\033[33m\w\033[0m\]
$ '
PROGRAMFILES = `C:\Program Files'
!:: = `::\'
MACHTYPE = `i686-pc-cygwin'
PROCESSOR_IDENTIFIER = `x86 Family 6 Model 8 Stepping 6, GenuineIntel'
OS = `Windows_NT'
OLDPWD = `/home/Administrator'
PROCESSOR_ARCHITECTURE = `x86'
TEMP = `/cygdrive/c/DOCUME~1/clevorn.AGS/LOCALS~1/Temp'
PROCESSOR_LEVEL = `6'
SYSTEMROOT = `C:\WINNT'
HOMEDRIVE = `C:'
LIB = `C:\Program Files\Microsoft Visual Studio\VC98\mfc\lib;C:\Program
Files\Microsoft Visual Studio\VC98\lib'
ALLUSERSPROFILE = `C:\Documents and Settings\All Users'
SHLVL = `1'
APPDATA = `C:\Documents and Settings\clevorn.AGS\Application Data'
COMMONPROGRAMFILES = `C:\Program Files\Common Files'
HOMEPATH = `\'
USERDOMAIN = `AGS'
USERNAME = `clevorn'
SHELL = `/bin/bash'
HOSTTYPE = `i686'
OSTYPE = `cygwin'
TERM = `cygwin'
SMS_LOCAL_DIR = `C:\WINNT'
_ = `/usr/bin/cygcheck'
TZ = `EST5EDT4,M4.1.0/2,M10.5.0/2'

HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2
  (default) = `/cygdrive'
  cygdrive flags = 0x00000022
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/
  (default) = `C:/cygwin'
  flags = 0x00000002
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/usr/bin
  (default) = `C:/cygwin/bin'
  flags = 0x00000002
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/usr/lib
  (default) = `C:/cygwin/lib'
  flags = 0x00000002
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\Program Options
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Start

Menu\Programs\Cygnus Solutions
  (default) = (unsupported type)
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\Program Options

a:  fd           N/A    N/A
c:  hd  NTFS   17351Mb  36% CP CS UN PA FC
d:  cd           N/A    N/A

C:\cygwin\bin  /usr/bin  user    binmode
C:\cygwin\lib  /usr/lib  user    binmode
C:\cygwin  /        user    binmode
c:    /cygdrive/c  user    binmode,noumount

Found: C:\cygwin\bin\bash.exe
Found: C:\cygwin\bin\cat.exe
Found: C:\cygwin\bin\cpp.exe
Found: C:\cygwin\bin\find.exe
Found: C:\cygwin\bin\gcc.exe
Found: C:\cygwin\bin\gdb.exe
Found: C:\cygwin\bin\ld.exe
Found: C:\cygwin\bin\ls.exe
Found: C:\cygwin\bin\make.exe
Found: C:\cygwin\bin\sh.exe

   56k 2000/12/03 C:\cygwin\bin\cygbz21.0.dll - os=4.0 img=1.0 sys=4.0
                  "cygbz21.0.dll" v0.0 ts=2000/11/20 18:53
   45k 2001/04/25 C:\cygwin\bin\cygform5.dll - os=4.0 img=1.0 sys=4.0
                  "cygform5.dll" v0.0 ts=2001/4/25 1:28
   18k 2000/10/23 C:\cygwin\bin\cyggdbm.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm.dll" v0.0 ts=2000/10/22 22:26
   17k 2001/06/28 C:\cygwin\bin\cyghistory4.dll - os=4.0 img=1.0 sys=4.0

                  "cyghistory4.dll" v0.0 ts=2001/1/6 23:34
   21k 2001/06/28 C:\cygwin\bin\cyghistory5.dll - os=4.0 img=1.0 sys=4.0

                  "cyghistory5.dll" v0.0 ts=2001/6/27 22:27
   21k 2001/06/20 C:\cygwin\bin\cygintl.dll - os=4.0 img=1.0 sys=4.0
                  "cygintl.dll" v0.0 ts=2001/6/20 13:09
   81k 2000/12/05 C:\cygwin\bin\cygitcl30.dll - os=4.0 img=1.0 sys=4.0
                  "cygitcl30.dll" v0.0 ts=2000/11/25 20:43
   35k 2000/12/05 C:\cygwin\bin\cygitk30.dll - os=4.0 img=1.0 sys=4.0
                  "cygitk30.dll" v0.0 ts=2000/11/25 20:43
   45k 2001/07/04 C:\cygwin\bin\cygjbig1.dll - os=4.0 img=1.0 sys=4.0
                  "cygjbig1.dll" v0.0 ts=2001/7/3 23:25
  119k 2001/06/06 C:\cygwin\bin\cygjpeg6b.dll - os=4.0 img=1.0 sys=4.0
                  "cygjpeg6b.dll" v0.0 ts=2001/6/6 0:27
   26k 2001/04/25 C:\cygwin\bin\cygmenu5.dll - os=4.0 img=1.0 sys=4.0
                  "cygmenu5.dll" v0.0 ts=2001/4/25 1:27
  156k 2001/04/25 C:\cygwin\bin\cygncurses++5.dll - os=4.0 img=1.0
sys=4.0
                  "cygncurses++5.dll" v0.0 ts=2001/4/25 1:29
  226k 2001/04/25 C:\cygwin\bin\cygncurses5.dll - os=4.0 img=1.0 sys=4.0

                  "cygncurses5.dll" v0.0 ts=2001/4/25 1:17
   15k 2001/04/25 C:\cygwin\bin\cygpanel5.dll - os=4.0 img=1.0 sys=4.0
                  "cygpanel5.dll" v0.0 ts=2001/4/25 1:27
  163k 2001/05/06 C:\cygwin\bin\cygpng2.dll - os=4.0 img=1.0 sys=4.0
                  "cygpng2.dll" v0.0 ts=2001/5/6 0:05
  108k 2001/06/28 C:\cygwin\bin\cygreadline4.dll - os=4.0 img=1.0
sys=4.0
                  "cygreadline4.dll" v0.0 ts=2001/1/6 23:34
  135k 2001/06/28 C:\cygwin\bin\cygreadline5.dll - os=4.0 img=1.0
sys=4.0
                  "cygreadline5.dll" v0.0 ts=2001/6/27 22:27
  390k 2000/12/05 C:\cygwin\bin\cygtcl80.dll - os=4.0 img=1.0 sys=4.0
                  "cygtcl80.dll" v0.0 ts=2000/11/25 20:39
    5k 2000/12/05 C:\cygwin\bin\cygtclpip80.dll - os=4.0 img=1.0 sys=4.0

   10k 2000/12/05 C:\cygwin\bin\cygtclreg80.dll - os=4.0 img=1.0 sys=4.0

                  "cygtclreg80.dll" v0.0 ts=2000/11/25 20:39
  245k 2001/06/12 C:\cygwin\bin\cygtiff3.dll - os=4.0 img=1.0 sys=4.0
                  "cygtiff3.dll" v0.0 ts=2001/6/12 13:25
  623k 2000/12/05 C:\cygwin\bin\cygtk80.dll - os=4.0 img=1.0 sys=4.0
                  "cygtk80.dll" v0.0 ts=2000/11/25 20:43
   41k 2001/07/04 C:\cygwin\bin\cygXpm-noX4.dll - os=4.0 img=1.0 sys=4.0

                  "cygXpm-noX4.dll" v0.0 ts=2001/7/3 21:21
   45k 2001/07/04 C:\cygwin\bin\cygXpm-X4.dll - os=4.0 img=1.0 sys=4.0
                  "cygXpm-X4.dll" v0.0 ts=2000/11/19 21:45
   49k 2001/02/03 C:\cygwin\bin\cygz.dll - os=4.0 img=1.0 sys=4.0
                  "cygz.dll" v0.0 ts=2001/2/3 15:35
  678k 2001/05/21 C:\cygwin\bin\cygwin1.dll - os=4.0 img=1.0 sys=4.0
                  "cygwin1.dll" v0.0 ts=2001/5/20 23:28
    Cygwin DLL version info:
        dll major: 1003
        dll minor: 2
        dll epoch: 19
        dll bad signal mask: 19005
        dll old termios: 5
        dll malloc env: 28
        api major: 0
        api minor: 39
        shared data: 3
        dll identifier: cygwin1
        mount registry: 2
        cygnus registry name: Cygnus Solutions
        cygwin registry name: Cygwin
        program options name: Program Options
        cygwin mount registry name: mounts v2
        cygdrive flags: cygdrive flags
        cygdrive prefix: cygdrive prefix
        cygdrive default prefix:
        build date: Sun May 20 23:28:17 EDT 2001
        shared id: cygwin1S3

--
----------------------------------------------------------
Thorsten Clevorn                  mailto:clevorn@agere.com
----------------------------------------------------------




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]