summaryrefslogtreecommitdiff
path: root/gcc/ada/s-tpoben.ads
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-09-27 09:33:30 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-09-27 09:33:30 +0000
commitc5bd783914e5754e51e35348838500f5e85f30c7 (patch)
treeeedc8f468a523f0beb2b503bbe92a69881b03282 /gcc/ada/s-tpoben.ads
parentd8e0897657312c7d0ff112d72297ed98a45a9229 (diff)
downloadgcc-c5bd783914e5754e51e35348838500f5e85f30c7.tar.gz
2011-09-27 Pascal Obry <obry@adacore.com>
* s-taprop.ads (Initialize_Lock)[RW_Lock]: New spec for r/w lock. (Finalize_Lock)[RW_Lock]: Likewise. (Write_Lock)[RW_Lock]: Likewise. (Unlock)[RW_Lock]: Likewise. (Read_Lock): Define L as RW_Lock (instead of Lock). * s-taprop-linux.adb (Initialize_Lock)[RW_Lock]: New routine for r/w lock. (Finalize_Lock)[RW_Lock]: Likewise. (Write_Lock)[RW_Lock]: Likewise. (Unlock)[RW_Lock]: Likewise. (Read_Lock): Define L as RW_Lock (instead of Lock). * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb, s-taprop-mingw.adb, s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb (Initialize_Lock)[RW_Lock]: Same implementation as corresponding routine for standard lock. (Finalize_Lock)[RW_Lock]: Likewise. (Write_Lock)[RW_Lock]: Likewise. (Unlock)[RW_Lock]: Likewise. (Read_Lock): Define L as RW_Lock (instead of Lock). * s-taprob.ads, s-tpoben.ads (Protection): Add RWL (RW_Lock) in the record definition. * s-taprob.adb, s-taproben.adb (Finalize_Protection): Use r/w lock for 'R' locking policy. (Initialize_Protection): Likewise. (Lock): Likewise. (Lock_Read_Only): Likewise. (Unlock): Likewise. * s-taspri-posix.ads (RW_Lock): New type defined as OS_Interface.pthread_rwlock_t. * s-taspri-vxworks.ads, s-taspri-posix-noaltstack.ads, s-taspri-mingw.ads, s-taspri-solaris.ads, s-taspri-dummy.ads, s-taspri-posix.ads, s-taspri-vms.ads, s-taspri-hpux-dce.ads, s-taspri-tru64.ads (RW_Lock): New type defined as alias to Lock. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@179251 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/s-tpoben.ads')
-rw-r--r--gcc/ada/s-tpoben.ads3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ada/s-tpoben.ads b/gcc/ada/s-tpoben.ads
index ce7045cf56e..f0684113f20 100644
--- a/gcc/ada/s-tpoben.ads
+++ b/gcc/ada/s-tpoben.ads
@@ -76,7 +76,8 @@ package System.Tasking.Protected_Objects.Entries is
type Protection_Entries (Num_Entries : Protected_Entry_Index) is new
Ada.Finalization.Limited_Controlled
with record
- L : aliased Task_Primitives.Lock;
+ L : aliased Task_Primitives.Lock;
+ RWL : aliased Task_Primitives.RW_Lock;
-- The underlying lock associated with a Protection_Entries.
-- Note that you should never (un)lock Object.L directly, but instead
-- use Lock_Entries/Unlock_Entries.