Michael B. Parker, MIT '89
|
East Campus - Mun. 303
3 Ames Street
Cambridge, MA 02139
(617) 225-6303


1 March 1987

Mr. Ken Sheldon
BYTE Senior Technical Editor
|
Byte Magazine
70 Main Street
Peterborough, NH 03458
(603) 924-9281, ext. 115



Dear Mr. Sheldon,


Here is the outline I promised you. It details the content of my article, Build A Portable Multitasking Environment in ``C''.

The article addresses the problems of multitasking understanding and portability within the small systems world. Through both discussion and construction, the article will teach the reader about the major terms, concepts, and applications of multitasking. Included with the manuscript will be a complete portable multitasking environment which the reader may include in his or her own programs.

With regards to the outline, Build A Portable Multitasking Environment in ``C'' will have introductory and concluding paragraphs, as well as two body sections (addressing the multitasking understanding and portability needs respectively). The first section, ``The Dimensions of Concurrent Processing'' will concisely introduce the major concepts & terms of concurrent processing. Though brief, this first section will insure that even the non-programmer will be able to understand and appreciate the second section. The second section, ``The Mailbox Multitasker'', will systematically introduce the portable multitasker I have written in ``C''. The section takes a bottom-up approach to `Mailbox', from its lowest level of portability (and functionality) to its highest.

With the manuscript, I will also include roughly 8 illustrations. For each of the 3 portability layers (see outline), I will include one specifying the function call interface to the layer (similar to the ``MAN'' page I included in the last letter), and another illustrating the data structures the layer manages. I will also add a couple of illustrations for the concepts introduced in the ``Dimensions of Concurrent Processing''.

Finally, I will include the disk of source- and compiled-code for the multitasker described in the article, so you may distribute it on BIX. It will run on the IBM PC and UNIX machines, and, with little modification, on almost any other machine with a ``C'' compiler. This is a valuable piece of software. Commercial packages without the source code and which are not portable sell for several hundred dollars (for example, the LIFEBOAT TimeSlicer lists at $295, or $1000 with source code). When you distribute this package on BIX, I would like it to treated as a ``shareware'' product.1

As far as length of the article goes, I am aiming for a concise 12 pages2. Roughly, the first 1/4th of the article will be spent illuminating the ``Dimensions of Concurrent Processing'', while the remaining 3/4ths will focus on ``The Mailbox Multitasker'' (1/4th for each of the 3 portability layers).

As far as time goes, I will finish the article over the MIT spring break, March 21-25. This is the only time I will have to really work on the article before the semester ends, so it is important we get to confirm arrangements before then.

What follows is the outline for your review. Thank you for your time and interest in my article. I look forward to working with you.


Sincerely,


Michael B. Parker

BYTE Article Outline: Build A Portable Multitasking Environment in ``C''

Goals of this Article
(introduction - 1 paragraph)

The Dimensions of Concurrent Processing
(1/4th article)
Addressing the Understanding Need

Goals
-

  • Efficient Resource Management (via Multiplexing)

  • Conceptual Simplicity (via Modules of Data AND Control)

    Both Sequential and Parallel Flow

Tasks, Processors, and Context Switching
-

  • Fine & Course Concurrent Processing

Internal & External Synchronization
-

  • Semaphores and Monitors
  • Interrupts, Critical Regions, Pre-emptive Code

Internal & External Communication
-

  • Shared Memory
  • Pipes
  • Message Passing (Ports & Mailboxes)
  • Side-Effects

Resource Management
-

  • Deadlock & Livelock
  • Memory
  • Processors (Scheduling)
  • Local Devices
  • Networks

The Mailbox Multitasker
(3/4ths)

(Addressing the Portability Need)

Mailbox vrs. The Typical Multitasker
-

(Sacrificing Efficiency for Simplicity: Portability and Understandability)

Mailbox's Layers of Portability
-

(Adding layers to match the desired functionality & portability)

The Context Switching Layer
(1/4th)

  • Threads
  • Creating & Destroying Threads
  • Switching Between Threads
  • Other Nifty Functions

The Task Organization Layer
(1/4th)

  • Tasks, Messages, and Mailboxes
  • Passing Messages & Scheduling Tasks (and visa versa)
  • Prioritizing Tasks

The Resource Management Layer
(1/4th)

  • Democratic or Monarchic Management?
  • Apparent or Transparent Management?


  • Dynamic Memory
  • Timer (Pre-emptive Multitasking!)
  • Keyboard and Printer
  • Disks
  • Communications
  • Screen and Mouse

Application Ideas & Examples

Multitasking and You
(conclusions - 1 paragraph)