Skip to content

DOS and disk operations refactoring; faster loads#36

Open
avolkov76 wants to merge 35 commits intodatajerk:masterfrom
avolkov76:dos-hack-2
Open

DOS and disk operations refactoring; faster loads#36
avolkov76 wants to merge 35 commits intodatajerk:masterfrom
avolkov76:dos-hack-2

Conversation

@avolkov76
Copy link

  1. DOS 3.3 stripped down to just RWTS (user commands and FileMan removed); smaller code, faster loads;
  2. Disk II controller (or compatible) slot auto-detection using the IIe firmware protocol (detects the ROM); customizable slot scan order, currently set to 6,5,4;
  3. Format tracks while writing data at the same time; removes ~24 seconds from the "format" option diskload process;

Includes all fixes along the way.

avolkov76 and others added 30 commits March 22, 2025 09:39
…: symbolic consts, structs, routine names, extra DOS init;

* asm object size warnings (there shall be overruns);

Both FileMan and RWTS disk format currently work (on my testbeds), controlled by USE_RWTS_FORMAT symbol in diskload2.s
…8000 where the loaded checksum byte is the last byte on a page (endload=$xx00, checksum at $xxFF), and the checksum algo incorrectly consumes an extra byte ($xx00) from the next page.
…s needs "b" fopen() mode for binary files read and write; POSIX will ignore "b".
…nes converted from .inc files; makes relocating the objects easier.
* High-level DOS code removed entirely; no FileMan;
* Direct RWTS format(4) call;
* ~9 seconds removed from the process.
… firmware protocol;

* For safety of established user base, following the Principle of Least Surprise, the scan for controller starts with slot 6; slot 7 is skipped (unlike the IIe). Starting slot is easily adjustable.
…ifted by 1 page; add a warning for the future.

(Interestingly, by the time diskload2 calls inflate for the very first time, the first page of diskload2 has served its purpose and never executes again. Inflate destroys the first page, but it is no longer needed, so this never surfaced in testing. It is possible to document the behavior as a "feature" instead and save 1 page of RAM.)
* conservatively set to 6,5,4 here, but can be any order, like 6,7,5,4,2.
…xists that start_table (infdata) in diskload2 will cross page boundary, and padding to end of page should account for that.
…e time (formriting). Removes ~24 seconds from the "format" option diskload process. This is a fast variant, using self-modifying code, faithfully reproducing DOS timing.
…m). The bug would probably never surface because we cannot write to I/O pages.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants