(j3.2006) (SC22WG5.3612) N1752

John Reid John.Reid
Fri Oct 31 14:03:20 EDT 2008


WG5,

Bill has convinced me in private email that N1752 is flawed. He says:

"SpinLock[Q] was initially set to locked by image Q  (first LOCK statement). 
Then you try to execute an UNLOCK on that lock from image P.  This violates a 
basic rule for locks:

An error condition occurs if the value of the lock variable in an
UNLOCK statement is unlocked, or if the lock variable is currently
locked by a different image. The status can be used to distinguish
the two cases.

The point of a LOCK is for a particular image (Q) to claim ownership of the lock 
and associated data, and prevent interlopers (image P) from disturbing that 
situation until the original owner releases the lock.  You can't allow someone 
else to unlock a lock that you currently own.  It defeats the original purpose."


I do not see how to get out of this. If anyone else can, please tell me.

For the present, N1752 should be ignored.

Sorry!

John.



More information about the J3 mailing list