Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

New version DRDOS 7.01.7 & 7.01.8 (Announce)

posted by boeckmann, Aachen, Germany, 14.12.2023, 18:00

> You can convert the code below for Int64 to Int32 and replace the 32-bit
> registers with 16-bit registers to skip the 32-time loop.

Thanks for the code. I can not convert it one by one, because the DRSYS div32 procedure also returns the remainder, but I get the idea...

However, for now I decided to leave the shifting algorithm as it is, mainly because it is a code path not often taken, and i want to fix more things than I break :-D

The div32 procedure is mainly called with 512 as the divisor (to calculate sectors and offsets into the FAT). So 99% of the time, the optimized 16-bit shortcut is used, I guess.

The current version is here:
https://github.com/SvarDOS/edrdos/blob/8fa1acd6576...9fd7f283a9119e3494036ce7/drdos/bdevio.a86#L2029

It should yield correct results (kernel behaves as expected). But perhaps someone with more assembly experience might double-check (from div32_full on it is the original code).

 

Complete thread:

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