Mail Archives: djgpp/2001/06/30/09:41:50
> From: invalid AT erehwon DOT invalid (Graaagh the Mighty)
> Newsgroups: comp.os.msdos.djgpp
> Date: Sat, 30 Jun 2001 09:22:00 GMT
>
> On Fri, 29 Jun 2001 12:05:37 +0300, "Eli Zaretskii"
> <eliz AT is DOT elta DOT co DOT il> sat on a tribble, which squeaked:
>
> >> >When this happens, I recommend setting the stack space with stubedit
> >> >huge (like 1/2 your memory) and try again. Still crash?
> >> >Probably in some interrupt handler or something.
> >>
> >> I don't mess with interrupt handlers.
> >
> >Yes, you do: every DJGPP program installs a handler for the hardware
> >keyboard interrupt in the startup code. It also installs a handler
> >for Int 75h, the FPU interrupt.
>
> Library code, not my own code.
It doesn't matter: it could still crash inside the interrupt handler
if your code commits too many atrocities.
In any case, assigning blame is not a useful method of eradicating
bugs. The goal should be to get a working program, not to find who's
to blame for the crashes.
> I assume the library code that messes with interrupt handlers is
> near bulletproof after this many years, and can safely be ignored.
Wrong assumption. The library is quite stable, but no one in their
right minds will ever guarantee that it is bulletproof, let alone that
it could be ignored.
> >Yes, but since the stack is really just a part of the DS segment, and
> >SS is loaded with the same selector as DS, you can't have this signal
> >when the stack overflows, because the protection mechanism cannot
> >detect it.
>
> Seems like a serious oversight in the implementation to me.
No, it's a reasonable compromise between the benefits and the costs,
given the available resources.
> >Just use the EIP CWSDPMI prints; it's a starting point for debugging.
> >(I explained in another message how to get the function name and the
> >source line given the EIP value).
>
> Show me how to get RHGDB not to die on loading the image, and maybe
> I'll investigate that avenue...
If RHGDB crashes, use GDB instead.
- Raw text -