From: Robert Eachus <rieachus@comcast.net>
Subject: Re: Read-write mutex sometimes fails on deadlock
Date: Sat, 11 Nov 2017 20:33:35 -0800 (PST)
Date: 2017-11-11T20:33:35-08:00 [thread overview]
Message-ID: <1810768e-7846-43ca-9871-b2468a060c37@googlegroups.com> (raw)
In-Reply-To: <lyr2tbgsye.fsf@pushface.org>
On Monday, November 6, 2017 at 1:31:07 PM UTC-5, Simon Wright wrote:
> Robert Eachus <rieachus@comcast.net> writes:
>
> > entry Write (D: in Data) is
> > begin
> > The_Data := D;
> > Some_Data := True;
> > Print(D);
> > delay 0.1;
> > end Write;
>
> Is this not illegal? or at the very least wrong?
Don't get wrapped around the axle by random names in partial examples. Print might be a (non-blocking) routine that eventually calls an I/O routine like Ada.Text_IO.Put.
Having said that, the delay 0.1 is very naughty, but on most hardware it will be implemented as a counting loop. (Make it delay 0.0001 if that makes you happier. ;-) It is not illegal, and is only erroneous if it results in a scheduling action.
next prev parent reply other threads:[~2017-11-12 4:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-28 20:02 Read-write mutex sometimes fails on deadlock pascal.malaise
2017-11-06 18:24 ` Robert Eachus
2017-11-06 18:31 ` Simon Wright
2017-11-12 4:33 ` Robert Eachus [this message]
2017-11-12 5:21 ` J-P. Rosen
2017-11-15 22:57 ` Randy Brukardt
2017-11-15 23:05 ` Randy Brukardt
2017-11-06 21:01 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox