Mail Archives: djgpp/1996/07/24/00:10:15
Thinking furiously, John Joseph Newbigin wrote:
>
> Firstly, I wrote a program to see how much memory I could allocate by looping
> and allocating blocks of memory. When I use large blocks like 1meg, everything
> seems to work fine but when I use smaller blocks, the program has a sigsev
> thingy and dies (under DOS and CWSDPMI, but not WIndows). This is not realy a
> problem as it would be quite unlikly to reach this limit in a normal program. I
> would be greatful if anyone could tell me what causes this and how to overcome it.
This is, so I'm told, a bug in CWSDPMI (or maybe it's a feature ;-), where
a large number of relatively small allocations causesit to run out of heap
and die an ungraceful death. Based on your description, it's a bug that
the DPMI provider in Windows does not share.
> My second problem is about gdb. I thought I would find out what was causing the
> problems described above so I read up the FAQ and was soon debuging my program
> but when I tried to single step, I got a message that the program had not been
> started. When I start the program, it runs till the end, or has an error. Could
> someone tell me hot to start a program so that I can step through it?
You need to set a breakpoint near (or at) the beginning of your program
before you start it, then you 'run' the program which will halt at that
breakpoint, then you can single-step from there.
Fred
--
-------------------------------------------------------------------------------
.---- Fred Smith / Office: fred AT computrition DOT com
( /__ ,__. __ __ / __ : / 508-663-2524
/ / / /__) / / /__) .+' Home: fredex AT fcshome DOT stoneham DOT ma DOT us
/ / (__ (___ (__(_ (___ / :__ 617-438-5471
-------------------------------- Jude 1:24,25 ---------------------------------
- Raw text -