User Tools

Site Tools


cdc:nos2.source:nam5871:np_cmit

NP$CMIT

Table Of Contents

  • [00004] NP$CMIT- FIP/COMMON MEMORY MANAGER INTERFACE.
  • [00023] NP$CMAR - CMM.AGR INTERFACE (ASSIGN GROUP IDENTIFIER).
  • [00048] NP$CMAF - CMM.ALF INTERFACE (ALLOCATE FIXED MEMORY).
  • [00082] NP$CMFR - CMM.FGR INTERFACE (FREE GROUP IDENTIFIER).
  • [00106] NP$CMFF - CMM.FRF INTERFACE (FREE FIXED MEMORY).
  • [00130] NP$CMSF - CMM.SFF INTERFACE (SHRINK FIXED MEMORY)

Source Code

NP$CMIT.txt
  1. *DECK NP$CMIT
  2. *IF DEF,XFR
  3. IDENT NP$CMIT
  4. TITLE NP$CMIT- FIP/COMMON MEMORY MANAGER INTERFACE.
  5. SYSCOM B1
  6. ENTRY NP$CMAR ASSIGN GROUP NAME
  7. ENTRY NP$CMAF ALLOCATE FIXED MEMORY
  8. ENTRY NP$CMFR FREE GROUP NAME
  9. ENTRY NP$CMFF FREE FIXED MEMORY
  10. ENTRY NP$CMSF SHRINK THE FIXED MEMORY
  11. SPACE 4,10
  12. ** NP$CMIT- COMMON MEMORY MANAGER INTERFACE FOR FTN AND SYMPL.
  13. * L.T.NGUYEN 83/03/21
  14. *
  15. * THESE ROUTINES ALLOW COMMUNICATION BETWEEN FORTRAN OR SYMPL
  16. * PROGRAMS AND THE COMMON MEMORY MANAGER.
  17. *
  18. * NP$CMAR (FUNCTION) ASSIGN GROUP NAME.
  19. * NP$CMAF (FUNCTION) ALLOCATE FIXED MEMORY.
  20. * NP$CMFR (SUBROUTINE/PROCEDURE) FREE GROUP NAME.
  21. * NP$CMFF (SUBROUTINE/PROCEDURE) FREE FIXED MEMORY.
  22. NP$CMAR TITLE NP$CMAR - CMM.AGR INTERFACE.
  23. ** NP$CMAR - CMM.AGR INTERFACE (ASSIGN GROUP IDENTIFIER).
  24. *
  25. * GPID = NP$CMAR(GPTYPE) FUNCTION CALL.
  26. * GPID = GROUP IDENTIFER.
  27. * GPTYPE = TYPE, TEMPORARY OR PERMANENT.
  28. *
  29. * ENTRY A1 = ADDRESS OF PARAMETER LIST.
  30. * X1 = ADDRESS OF 1ST PARAMETER (GPTYPE).
  31. *
  32. * EXIT X6 = GROUP IDENTIFER (GPID) RETURNED BY CMM.AGR.
  33. *
  34. * USES A - 1.
  35. * B - 1.
  36. * X - 1 6.
  37. *
  38. * CALLS CMM.AGR.
  39.  
  40.  
  41. NP$CMAR SUBR
  42. SB1 1 CONSTANT 1
  43. SA1 X1 FETCH 1ST PARAMETER (GROUP TYPE)
  44. RJ =XCMM.AGR ASSIGN GROUP NAME
  45. BX6 X2 RETURN GROUP NAME
  46. EQ NP$CMARX RETURN
  47. NP$CMAF TITLE NP$CMAF- CMM.ALF INTERFACE.
  48. ** NP$CMAF - CMM.ALF INTERFACE (ALLOCATE FIXED MEMORY).
  49. *
  50. * FWA = NP$CMAF(SIZE,SIZECODE,GPID) FUNCTION CALL.
  51. * FWA = FWA OF BLOCK.
  52. * SIZE = SIZE OF BLOCK.
  53. * SIZECODE = ALLOCATION CODE.
  54. * GPID = GROUP IDENTIFER.
  55. *
  56. * ENTRY A1 = ADDRESS OF PARAMETER LIST.
  57. * X1 = ADDRESS OF 1ST PARAMETER (SIZE).
  58. *
  59. * EXIT X6 = FWA OF ALLOCATED BLOCK (RETURNED BY CMM.ALF).
  60. *
  61. * USES A - 2 3 4.
  62. * B - 1.
  63. * X - 2 3 4 6.
  64. *
  65. * CALLS CMM.ALF.
  66.  
  67.  
  68. NP$CMAF SUBR
  69. SB1 1 CONSTANT 1
  70. SA3 A1+B1 GET 2D PARAMETER
  71. SA4 A3+B1 GET 3D PARAMETER
  72. SA2 X1 GET 1ST PARAMETER (SIZE)
  73. SA3 X3 GET 2D PARAMETER (SIZECODE)
  74. SA4 X4 GET 3D PARAMETER (GPID)
  75. LX3 6 POSITION SIZE CODE
  76. LX4 12 POSITION GROUP IDENTIFIER
  77. IX3 X3+X4 COMBINE SIZE CODE AND GROUP ID
  78. RJ =XCMM.ALF ALLOCATE FIXED STORAGE
  79. BX6 X1 RETURN FWA
  80. EQ NP$CMAFX RETURN
  81. NP$CMFR TITLE NP$CMFR - CMM.FGR INTERFACE.
  82. ** NP$CMFR - CMM.FGR INTERFACE (FREE GROUP IDENTIFIER).
  83. *
  84. * CALL NP$CMFR(GPID) FORTRAN SUBROUTINE CALL.
  85. * NP$CMFR(GPID); SYMPL PROCEDURE CALL.
  86. * GPID = GROUP IDENTIFIER.
  87. *
  88. * ENTRY A1 = ADDRESS OF PARAMETER LIST.
  89. * X1 = ADDRESS OF 1ST PARAMETER (GPID).
  90. *
  91. * EXIT NONE.
  92. *
  93. * USES A - 1.
  94. * B - 1.
  95. * X - 1.
  96. *
  97. * CALLS CMM.FGR.
  98.  
  99.  
  100. NP$CMFR SUBR
  101. SB1 1 CONSTANT 1
  102. SA1 X1 GET 1ST PARAMETER (GPID)
  103. RJ =XCMM.FGR FREE GROUP IDENTIFIER
  104. EQ NP$CMFRX RETURN
  105. NP$CMFF TITLE NP$CMFF - CMM.FRF INTERFACE.
  106. ** NP$CMFF - CMM.FRF INTERFACE (FREE FIXED MEMORY).
  107. *
  108. * CALL NP$CMFF(FWA) FORTRAN SUBROUTINE CALL.
  109. * NP$CMFF(FWA); SYMPL PROCEDURE CALL.
  110. * FWA = FWA OF BLOCK.
  111. *
  112. * ENTRY A1 = ADDRESS OF PARAMETER LIST.
  113. * X1 = ADDRESS OF 1ST PARAMETER (FWA).
  114. *
  115. * EXIT NONE.
  116. *
  117. * USES A - 1.
  118. * B - 1.
  119. * X - 1.
  120. *
  121. * CALLS CMM.FRF.
  122.  
  123.  
  124. NP$CMFF SUBR
  125. SB1 1 CONSTANT 1
  126. SA1 X1 FETCH 1ST PARAMETER (FWA)
  127. RJ =XCMM.FRF
  128. EQ NP$CMFFX RETURN
  129.  
  130. ** NP$CMSF - CMM.SFF INTERFACE (SHRINK FIXED MEMORY)
  131. *
  132. * CALL BP$CMSF(FWA,NUM)
  133. * FWA - FIRST WORD ADDRESS OF BUFFER TO BE
  134. * SHRINKED.
  135. * NUM - NUMBER OF WORD TO BE SHRINKED
  136. * COUNTED FROM THE BOTTOM.
  137. * ENTRY A1 = ADDRESS OF PARAMTER LIST.
  138. * X1 = ADDRESS OF FWA.
  139. *
  140. * EXIT NONE.
  141. *
  142. * USE A - 1.
  143. * B - 1.
  144. * X - 1.
  145. * A - 2.
  146. * X - 2.
  147. * CALLS CMM.SFF.
  148.  
  149.  
  150. NP$CMSF SUBR
  151. SB1 1
  152. SA1 X1
  153. SA2 A1+1 NUMBER OF WORD TO BE SHRINKED
  154. RJ =XCMM.SFF
  155. EQ NP$CMSFX
  156.  
  157.  
  158. NP$CMNE TITLE NP$CMNE - DEBUG CODE.
  159.  
  160.  
  161. END END OF NP$CMIT
  162. *ENDIF
cdc/nos2.source/nam5871/np_cmit.txt ยท Last modified: 2023/08/05 17:22 by Site Administrator