From: IVANOVIC%VAXR@CIRCUS.LLNL.GOV ("Vladimir Ivanovic, x3-7786")
Subject: Pragma SHARED, tasks and shared variables
Date: 28 Jul 88 01:03:00 GMT [thread overview]
Message-ID: <8807280055.AA27279@ajpo.sei.cmu.edu> (raw)
Can anyone answer the following question:
If I specify that every read or update to an variable whose type is an
access type is a synchronization point for that variable by using the
pragma SHARED and naming that variable [LRM 9.11(7)], can I be assured
that the object designated by that variable will never be a local
copy of that object?
My intent is to get around the restrictions imposed by LRM 9.11(3)
and 9.11(8) by having shared data structures whose types are not
restricted to scalar and access types.
My motivation is performance. I cannot afford the CPU strokes that
encapsulating the data structures in a task and performing rendezvous
with that task to access the data would cost. (And I cannot afford a
faster CPU...)
I realize that my particular implementation (VAX Ada v1.4) allows
the use of pragma VOLATILE which is the same as pragma SHARED without
the words "and whose type is a scalar or access type", essentially
giving me what I want, but pragma VOLATILE is not portable across
implementations.
next reply other threads:[~1988-07-28 1:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
1988-07-28 1:03 "Vladimir Ivanovic, x3-7786" [this message]
1988-07-28 16:33 ` Pragma SHARED, tasks and shared variables Jonathan P. Biggar
-- strict thread matches above, loose matches on Subject: below --
1988-07-28 14:12 Norman Cohen
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox