home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / lang / ada / 2381 < prev    next >
Encoding:
Text File  |  1992-08-18  |  2.2 KB  |  58 lines

  1. Newsgroups: comp.lang.ada
  2. Path: sparky!uunet!seas.gwu.edu!lodhi
  3. From: lodhi@seas.gwu.edu (Fakhar Lodhi)
  4. Subject: Some Questions about protected records
  5. Message-ID: <1992Aug18.214029.13746@seas.gwu.edu>
  6. Originator: lodhi@seas.gwu.edu
  7. Sender: news@seas.gwu.edu
  8. Organization: George Washington University
  9. Date: Tue, 18 Aug 1992 21:40:29 GMT
  10. Lines: 46
  11.  
  12. I have some questions about protected records and would greatly 
  13. appreciate if some one could provide the answers. Thanks.
  14.  
  15. Section 9.7 (Ada 9X Mapping Vol. II, Ver. 4.0, 24 Dec. 1991) gives the
  16. semantics of the execution of the protected operation as follows:
  17. (paragraphs 9-12)
  18.  
  19. The actual execution of a protected operation is synchronized with other
  20. protected operations on the same protected record object, as follows:
  21.  
  22. No two protected operations on the same protected record object
  23. may proceed concurrently, unless both ar functions.
  24.  
  25. As the first step for an operation that is an entry call, the
  26. barrier condition is evaluated. If it yields FALSE, the call is queued,
  27. and does not proceed further until the barrier is reevluated and no longer
  28. yeilds FALSE.
  29.  
  30. As the final step of a protected operation that is not a function,
  31. if any calls are queued, the barrier conditions are reevaluated. If the 
  32. barrier of an entry with a queued call no longer evalutes to FALSE,
  33. one call on such a queue is selected as the next protected operation to be
  34. performed on the protected record. If more than one call is 
  35. eligible, an implementation defined rule is used to select among them.
  36.  
  37.  
  38. Now I have the following questions.
  39.  
  40. 1. What will happen to the procedure and function calls
  41. that cannot be executed immediately?  Will they be queued or what?
  42. I think it is not mentioned anywhere in this document, or have I missed
  43. some thing?
  44.  
  45. 2. Will the barriers for all entries be evaluated before making a selection
  46. (just like in the select statement), or is it left to the implementation?
  47.  
  48. 3. As I understand, functions are provided in a protected record to allow
  49. concurrent read. Now assuming this is true, should they have a lower priority
  50. than procedure and entry operations when it comes to selecting a protected
  51. operation?
  52.  
  53. Once again, I would really appreciate any one clearing this thing out for me.
  54. Thanks.
  55.  
  56. Fakhar Lodhi
  57. lodhi@gwusun.gwu.edu
  58.