Newsgroups: comp.sys.amiga.tech
Path: utzoo!utgpu!jarvis.csri.toronto.edu!jazz.db!fche
From: fche@db.toronto.edu (Frank Ch. Eigler)
Subject: Trackdisk optimization - possible?
Message-ID: <1989Jun14.144745.18393@jarvis.csri.toronto.edu>
Keywords: intertask disk grind, trackdisk.device
Organization: University of Toronto, CSRI


How difficult would it be to write a program that intercepts
trackdisk.device's BeginIO() vector and selectively feeds it
previous requests.

Why?  I recall some discussion here a few months ago.  This idea was
brought up at one time but noone seemed to take much notice.  The problem
is that of multiple tasks accessing different areas of a disk simultenously,
causing the familar grind-grind-gronk sequence.

This could perhaps be solved, or at least reduced, by the interception
program by having it maintain the request queue and try to keep it 
ordered in a sorted fashion, inserting newly incoming requests into its
list wherever it belongs.  It would keep feeding trackdisk.device an
I/O request whenever it's finished with the last one.

How should it decide how to order incoming requests?  Maybe as simply as
sorting by the block number requested.  If the algorithm is that simple,
though, it may lock out all but one of all tasks that may want to access
the disk at a time.

It could also divide the list of incoming requests into approximate areas
of the disk (say, covering 20 cylinders each on a floppy), and do some
round-robin scheduling among sets of requests for the same area.

On a floppy system where multi-task access doesn't happen all that often,
such a utility may not be very useful.  But, if it can be made to work with
hard disk drivers, it may enhance performance quite a bit.

OFS doesn't, but does FFS do some sort of postprocessing of its own
requests on its assigned disk devices?


It doesn't seem like a very tough project.

--Frank
__________________________________________________________________

  Frank Ch. Eigler                The Hack BBS  (416)-265-3984  //
fche@db.toronto.edu                                            //
