TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy

TEAM-ADA@LISTSERV.ACM.ORG

Options: Use Forum View

Use Proportional Font
Show HTML Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Matthew Heaney <[log in to unmask]>
Reply To:
Matthew Heaney <[log in to unmask]>
Date:
Sat, 24 Apr 1999 15:00:19 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (32 lines)
Blue Herring <[log in to unmask]> writes:

> One issue I had, was that I read somewhere that protected procedures
> and so forth, when executed, will run until completed, and not be
> interrupted by time slicing and so forth.

This statement is incorrect.  A protected operation gives you exclusive
access to a resource, that's all.


> This certainly does the job, but as a learned friend of mine pointed
> out, Ada protected types are meant to passively guard critical section
> data, but time slicing in the middle of execution would be fine, as
> long as mutual exclusion was maintained.

Yes.


> Is there a specific way this happens in the 95 standard, or is it
> implementation dependent?

Read the Ada95 Rationale for the gory details about "bounded priority
inversion" and spin-locks.


> I'm also curious if there is a compiler out there which does enforce
> consistant time slicing, since Gnat supposedly doesn't.

Forget time-slicing.  Forget round-robin scheduling.

Don't confuse "concurrency" with "parallelism."

ATOM RSS1 RSS2