ah yes, the latches and reads and what-not... yes, it's all coming back
to me.... ah dos, it's been too long.... how i miss thee....

Gfunk

http://www.gfunk007.com/
----- Original Message -----
From: "Bart Oldeman" <[EMAIL PROTECTED]>
To: "plex86" <[EMAIL PROTECTED]>
Sent: Thursday, December 14, 2000 12:46 PM
Subject: Re: [plex86] Progress, turning off prescanning for user code


> On Thu, 14 Dec 2000, Josh G wrote:
>
> > I have a question- does plex cache prescanned pages? perhaps cache
> > them after converting some things? I mean 90% of all graphics port
> > code will be something like:
> >
> > mov al,3c0h
> > out al,ah
>
> would be
> mov dx,3c0h
> out dx,al
> on i386.
>
> Anyway, the problem with planar modes is the memory.
> VGA planar memory is quite complicated and you usually need to read from
> the address before you want to write to it, in order to load the latches
> which can preserve the bits you don't want to change: like this
>
> mov ax,0a000h
> mov es,ax
> mov cx,640*480/8
> xor di,di
> mov al,bit pattern
> cld
> label:  mov ah,es:[di]   ;load 32-bit latch register which contains all
>   bytes at the four planes under es:[di].
>   ah is just dummy.
> stosb ;what ends up in memory is a function of al,
>   the latch and values in I/O registers. I've
>   optimized this specific function.
> loop label
>
> You _have_ to cache this or do cpu-emulation to make this fast, but
> _cannot_ execute this natively, because VGA memory is basically one large
> piece of MMIO (this comment about MMIO is in the plex86 white paper
> somewhere). I'm just not familiar enough (not at all) to know how it works
> right now.
>
> Bart
>
>


Reply via email to