www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/01/29/14:10:51

Xref: news2.mv.net comp.os.msdos.djgpp:628
From: fenric AT clark DOT net (Andrew McCaffrey)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Issues with nearptr's.
Date: 27 Jan 1996 05:15:33 GMT
Organization: the beginning of all beginnings
Lines: 29
Message-ID: <4eccdl$90b@clarknet.clark.net>
References: <JTSILLA DOT 96Jan26100052 AT atlas DOT ccs DOT neu DOT edu> <31096ecf DOT sandmann AT clio DOT rice DOT edu>
NNTP-Posting-Host: explorer.clark.net
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Charles Sandmann (sandmann AT clio DOT rice DOT edu) wrote:
> > I'd like to use nearptr's to access physical memory currently occupied
> > by video hardware. SOunds pretty simple, no? Well, I've read rumours
> > that there are dangers involved in setting the NEARPTR flag in my crt0 flags.
> 
> The only known dangers are that a stray pointer can destroy the interrupt
> table, DOS, driver data, Windows, or anything else in memory.  If you always
> program without bugs, you have nothing to worry about :-)
> 
> > One problem I have noticed is that when running under gdb, gdb
> > crashes when I use this flag and try to print out large data structures.
> > Are there any other possible issues? What's really going on in there?
> 
> This really shouldn't be related, and I don't know why this would make
> a difference.  With nearptrs you could overwrite GDB's memory, but this
> might actually be seen with the default non-move sbrk anyway, since the
> debugger and program could end up with their memory laid out ABABAB.

I've written a couple of graphic routines with nearptrs and they run fine 
under dos and cwsdpmi, but when I try to run them under gdb, I get a 
segmentation violation signal.  

-- 
+------------------------Andrew McCaffrey+[fenric AT clark DOT net]------------+
|Doctor: But I don't exist in your world!|"Anybody remotely interesting |
|Brigade-Leader: Then you won't feel the |is mad in one way or another."|
|bullets when we shoot you.              |    - The Seventh Doctor      | 
|       Doctor Who - Inferno (1970)      |                              |
+----------------------------------------+------------------------------+

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019