Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

DarkDebugger (Users)

posted by Japheth Homepage, Germany (South), 23.06.2022, 17:05

I'm currently checking an old graphics app in a vga 16-color mode. This app used to work, but on newer cards the output is "scattered" ( or perhaps it's not the "newer cards", but the "newer cpus").

As it has turned out, I had to make this change:


;    mov     al,ah
;    xchg    al,[bx]
    mov al,[bx]
    mov [bx],ah


Using XCHG with memory operands is usually a bad idea, but even more so in the vga "plane" modes. Better do a clean read to fill the "latch" register, then the write. I guess it's also "significantly" faster.

---
MS-DOS forever!

 

Complete thread:

Back to the forum
Board view  Mix view
22049 Postings in 2034 Threads, 396 registered users, 117 users online (0 registered, 117 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum