changeset 44:ce720506491b

cleared out old, out-of-sync, design notes
author Me
date Sat, 11 Sep 2010 08:36:55 -0700
parents e3b78148e9de
children 5388f1c2da6f
files DESIGN_NOTES.txt DESIGN_NOTES__VMS.txt
diffstat 2 files changed, 2 insertions(+), 40 deletions(-) [+]
line diff
     1.1 --- a/DESIGN_NOTES.txt	Sat Sep 11 07:40:44 2010 -0700
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,40 +0,0 @@
     1.4 -
     1.5 -This project is for a paper -- the goal is to implement and measure the
     1.6 - performance of the Virtual Master-Slave system as an alternative to the
     1.7 - Thread model.
     1.8 -
     1.9 -Going to implement exactly one application -- a do-nothing benchmark kernel
    1.10 - that just measures scheduling overhead.
    1.11 -
    1.12 -Implement VMS this way:
    1.13 -
    1.14 -function to give to PThread that does the loop:
    1.15 -
    1.16 -get from queue, call function-ptr, passing it work-unit ptr (which contains a
    1.17 - pointer to data declared as void * in the application), then write the
    1.18 - "Done" flag and repeat.
    1.19 -
    1.20 -
    1.21 -In an application:
    1.22 -
    1.23 -divide work up into pieces self, just make it a busy-wait loop that writes
    1.24 - data, then reads it back, declared volatile.  At end of work, call fn that
    1.25 - makes a continuation and notifies the Master its there, then return.
    1.26 -
    1.27 -
    1.28 -Master:
    1.29 -
    1.30 -A loop that polls each virtual slave exactly once, processing each whose
    1.31 - Done flag is set, it forces work-units to be one-to-one with slaves, so
    1.32 - as soon as done polling slaves, it makes a continuation of itself, puts
    1.33 - half the scheduled slaves in, clears its own Done flag, puts its
    1.34 - continuation in, the other half of the scheduled slaves, then writes its
    1.35 - own Done flag.
    1.36 -
    1.37 -When continuation first runs, checks if own Done flag set -- if not, busy-
    1.38 - waits until set, then proceeds.  This ensures it doesn't overlap with
    1.39 - tail-end of previous -- IE, continuation may sneak through queue before
    1.40 - previous done putting second half of scheduled slaves in.  This is the only
    1.41 - race condition.
    1.42 -
    1.43 -
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/DESIGN_NOTES__VMS.txt	Sat Sep 11 08:36:55 2010 -0700
     2.3 @@ -0,0 +1,2 @@
     2.4 +
     2.5 +Implement VMS this way: