Path: utzoo!attcan!uunet!lll-winken!lll-lcc!ames!mailrus!purdue!bu-cs!dartvax!eleazar.dartmouth.edu!earleh From: earleh@eleazar.dartmouth.edu (Earle R. Horton) Newsgroups: comp.sys.mac.programmer Subject: Apple HD SC 80 does not support Asynch i/o. Keywords: Hall of Shame entry? Message-ID: <11605@dartvax.Dartmouth.EDU> Date: 3 Jan 89 06:51:40 GMT Sender: news@dartvax.Dartmouth.EDU Reply-To: earleh@eleazar.dartmouth.edu (Earle R. Horton) Organization: Thayer School of Engineering Lines: 49 The following is an excerpt from David Phillip Oster's Asynch IO test, posted to info-mac: > I want to get Macintosh programmers up in arms about the shameful state >of 3rd party Macintosh hard disk driver software. The Mac operating system >supports a wonderful feature that could let our programs run much faster, >but the developers of disk driver software have cheated us out of it. > > I am referring to asynchronous disk i/o. According to Inside Mac, >if you do a PBRead(&ioBlock, TRUE), or, a PBWrite(&ioBlock, TRUE), the >call should schedule the i/o, and return almost immediately, and when >the i/o is actually done, the system will set some fields in the >ioBlock, and call the completion routine associated with the ioBlock. The posting comes with a small test program to show whether your disk driver manufacturer supports asynchronous IO. I tried it on a Mac II with an Apple HD SC 80 running the driver from Apple HD SC Setup version 2.0 and System 6.0.1. The hard disk driver failed the test. The read call did not return until the IO was complete. I stepped through the program using a debugger, just to make sure. A trace command over the asynchronous read call in the example program did not complete until the disk IO was finished, and this was more than a second! The Apple hard drive and driver do not support asynchronous reads. For shame! The Nova 30 from MicroTech does not support asynchronous reads, either. I find this less remarkable than what I found about the Apple drive. Mr. Oster also says: >Let us create a hall of shame. Does your hard disk support asynchronous i/o? >if not, please post their name here, so we can complain. So we can get some >action, so we can get disk based programs that run at all-RAM speeds! I don't think this will do much good if Apple drives do not support asynchronous IO. Does anyone know of drives that do? What's the story here? It looks like Apple belongs in first place in the Hall of Shame unless somebody comes up with a good excuse for the behavior of the Apple driver. By the way, it is not necessary to have an ioCompletion routine in order to make use of asynchronous IO. Polling the ioResult field of your Parameter Block will do nicely. IoBlock.ioResult will be positive until the request has been satisfied, and will turn negative on failure, zero on success. Earle R. Horton. 23 Fletcher Circle, Hanover, NH 03755 (603) 643-4109 Graduate student.