News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

Memory???

Started by daydreamer, April 23, 2021, 05:26:11 PM

Previous topic - Next topic

daydreamer

First what page does my. Com file endup in?
Drawing I use the usual A000, but what pages is best usable for backbuffer and other things, like draw a big image in advance, before showing little part on screen?
my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

LiaoMi

Hi daydreamer,

Duncan, Ray - Advanced MS-DOS programming - the Microsoft guide for assembly language and C programmers (1989, Microsoft Press)
https://archive.org/details/Advanced_MS-DOS_Programming_2nd_Edition_Ray_Duncan
https://archive.org/download/Advanced_MS-DOS_Programming_2nd_Edition_Ray_Duncan/Advanced_MS-DOS_Programming_2nd_Edition_Ray_Duncan.pdf
https://github.com/microsoft/MS-DOS
https://en.wikipedia.org/wiki/DOS_memory_management


daydreamer

thanks LiaoMi  :thumbsup:
I am after to switch DS to several 64k block and output big images without it crashes and final output to A000(ES)


my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

LiaoMi


Memory allocation table :arrow_right: https://www.hohmann-edv.de/betriebssysteme/dos.php

daydreamer

#4
thanks :thumbsup:
scrolling with a rossler attractor you can control with arrow keys,esc=quit





my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

hutch--

Somewhere back in the long distant past I used to extract some extra memory for a DOS app by using the VGA address at A000h and going up to B7FF which at the time I used it for some utilities that would struggle to fit into DOS range memory. I think you had to twiddle HIMEM.SYS but it could be done.

daydreamer

#6
Hutch I start simplest segment switching first before use vesa interrupts for vram
Want to finish it like it was meant to be:scrolling thru big racetrack = big memory buffer for map
updated: or waterways


my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

daydreamer

What's best,use [BP] that uses. Ss = cs in. Com file if not changed or cs: override to retrieve LUT data + other data from source file that ends up in cs=ds=Ss=es when loaded?
Mov ax,page
Mov ds,ax
Vs LDS?
reading DOS AoA

my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

FORTRANS

Hi,

Quote from: daydreamer on April 29, 2021, 05:46:14 PM
What's best,use [BP] that uses. Ss = cs in. Com file if not changed or cs: override to retrieve LUT data + other data from source file that ends up in cs=ds=Ss=es when loaded?
Mov ax,page
Mov ds,ax
Vs LDS?

   What is better or best between;
    MOV AX,Seg
    MOV DS,AX
...
    LDS Reg,Pointer ; Load DS and register with long pointer.


depends on your personal tastes.  The only time you need
to use the load segment instruction is when you load the
stack segment and stack pointer (LSS).  That needs to be
atomic to prevent {rare} interrupts between two moves
to do the same thing.  IIRC of course.  Loading DS is less
constrained.  Use whichever makes sense to you.

Cheers,

Steve N.


daydreamer

#9
thanks Steve N. :thumbsup:
LDS probably easier to use with already 32bit pointer (e)si register start of loop,but switching seg in outerloop maybe only need
inc ah
mov ds,ax
had annoying bug because still thinking in 32bit crashes,ret 8 and ret 12(thinking 4 * arguments)

so if I want as much continuious memory buffer,from original CS,SS,DS segment after the code and few variables upto B7ffh,any advice where to move SS:stack?
highest segment or any UMB? or going downward from 0B7ffh ?
seem I have to use a segment  between A000h and memory buffer I copy/scroll from



my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

daydreamer

More advanced, is it possible to copy everything loaded to uppermost segment and jump there?
my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

FORTRANS

Hi,

Quote from: daydreamer on May 07, 2021, 06:47:09 PM
More advanced, is it possible to copy everything loaded to uppermost segment and jump there?

   Should be.  You just end up with two copies in memory.  So I don't see
any advantage for a normal program.  (Not being a device driver, TSR or
some other strange case.)

Regards,

Steve N.

daydreamer

#12
try to get 16bit(word) colors vesa modes,but doesnt get bankswitching to work
fixed thanks Steve N. :thumbsup:


my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

FORTRANS

Hi,

   Set BH to zero to change banks.  BH set
to one is an inquiry of the current settings.

Steve N.

daydreamer

using more FS,GS segment registers help
my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding