delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/06/19/14:37:08

Message-Id: <m0wegP5-000S1jC@ciati.edu.ar>
Comments: Authenticated sender is <salvador AT natacha DOT inti DOT edu DOT ar>
From: "Salvador Eduardo Tropea (SET)" <salvador AT inti DOT edu DOT ar>
Organization: INTI
To: sar AT maties DOT sun DOT ac DOT za, djgpp AT delorie DOT com
Date: Thu, 19 Jun 1997 15:52:38 +0000
MIME-Version: 1.0
Subject: Re: NASM - How to access vid ram inside DJ

sar AT maties DOT sun DOT ac DOT za wrote:
> Gil Myers wrote:
> > 
> > acebear AT pukopn1 DOT puk DOT ac DOT za wrote in article
> > <33A083D9 DOT 11AC AT pukopn1 DOT puk DOT ac DOT za>...
> > > How would you write a NASM generated COFF .o that will make it possible
> > > to directly access VGA memory (320x200) under DJGPP directly from an
> > > external, NASM coded asm prog without the usual slew of segment
> > > violation errors?
> 
> >> Workaround one is to  turn off protection.  This is described in the FAQ,
> > and the
> > actual functions to do so are in the file SYS/NEARPTR.H.  This is very
> > dangerous.
> 
> Why is it dangerous? I checked the FAQ & docs you refer to, they also
> discourage it, but it looks like THE fastest method. Since memory
> protection is there to prevent different programs in the same physical
> memory of stepping on each other, and DJGPP always runs as the only
> program in its memory space, what is the problem?
Eli explained why that isn't true. In addition I can add that that isn't THE 
fastest method. In many cases is just as fast as far ptrs (where you don't 
loose protection), of course that depends on your program.

I have a test that shows a simple situation (is a particular one but isn't so 
crazy because is the common situation) where you can see that nearptrs aren't 
faster than farptrs.

SET
------------------------------------ 0 --------------------------------
Visit my home page: http://www.geocities.com/SiliconValley/Vista/6552/
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013

- Raw text -


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