[comp.lang.ada] Tasking and delays, Robert Dewar's response

flynn@ACF2.NYU.EDU (Susan Flynn) (02/20/88)

From: dewar@acf2.nyu.edu (Robert Dewar)
Date: 17-Feb-88 23:25 EST
Subject: Re: Tasking and delays, again...

An interesting question in the Feldman delay test is whether it is valid
for two tasks to "simultaneously" [i.e. without intermediate synchronization]
write to the standard output file. It could be argued that the file object
accessed is a shared variable, and that thus 9.11 makes such a program
erroneous. 

In the case of FLOAT_IO, the variables DEFAULT_FORE etc are clearly shared
variables, so you CERTAINLY cannot change one of these defaults and then
use the package from some other task.

If some kind of sharing is permitted, what is the rule concerning 
indivisibility. As far as Ada is concerned, putting a string is just as
much an atomic action as putting a character, so there seems no reason
to expect interruption on a character by character basis (if this seems
permissible, why not interrupt after an individual vector or pixel is
drawn on the output screen?)