Linking in a new memory segment
The programs which loads the memory segments are NODAL_FUN &
NODAL_FUN2 & NODAL_INIT.
Then the env NODAL_INIT has to be update in the .cshrc file. These
files should only be modified by the controls group.
An example on writing a global nodal function in a already
created memory segment.
If you plan to do this contact Daffyd or John before you try.
"eablock" is special and cannot be changed in this way.
"zfuns" is the normally used for testings.
a) Login as spsea ( the bash shell is best setup at the moment).
b) Change to the /vol2/u1/spsea/noda dir. This is a local
for each computer.
c) Set the env NODAL_INIT to null.
- bash export NODAL_INIT=""
- tcsh/csh setenv NODAL_INIT
d) Then start the nodal. You will get "NON existent name"
for login this is normal.
- >C NODAL version 1.1 Mar 24 1995 (CERN SL)
- >
- >
- >NON existent name
- >login
- > ^
How lets load in the HFUNS
- >ldef HFUNS
- >lisd
- AFCDAT 1032 array integer(1024,1) (16 bits short)
- ASADD 168 Define-Call (R-a,V-s)
- ..
- XWCDF5 1728 Define-Call (R-event,V-nword,V-nxwcd,R-ns,R-profd,R-profs)
- defined functions, using 28744 words out of 32736
Then open the XWCDF5 function.
- >open XWCDF5
- >li 99
- 99.10 $s nodlin(99.2)='% Last modification 'date'. DAFYDD'
- 99.20 % Last modification 1995-04-24-12:33:50. DAFYDD
- 99.30 def-c xwcdf5(r-event,v-nword,v-nxwcd,r-ns,r-profd,r-profs)
- 99.40 sdef(slsrv1)/user/spsea/nodal/HFUNS
- 99.50 erase 99
The function is saved on the slsrv1 not the local computer(Though
this may change to eanorth). The file is then transfered on the
wreboot of nodal to the local computer.
- >ed 99.3
- 99.30 def-c samuel(v-x,r-y,s-s)
- >
- >erase 10 12 13 14 15 98
- >li
- 99.10 $s nodlin(99.2)='% Last modification 'date'. DAFYDD'
- 99.20 % Last modification 1995-04-24-12:33:50. DAFYDD
- 99.30 def-c samuel(v-x,r-y,s-s)
- 99.40 sdef(slsrv1)/user/spsea/nodal/HFUNS
- 99.50 erase 99
Enter in the new code.
- >10.9 end
- >10.1 t!x
- >10.2 se y=5;t!y
- >10.3 t!s
- >98.1 Arguments
- >98.2 X Input value
- >98.3 Y Input or output array or output variable
- >98.4 S string
- >li
- 10.10 t!x
- 10.20 se y=5;t!y
- 10.30 t!s
- 10.90 end
- 98.10 Arguments
- 98.20 X Input value
- 98.30 Y Input or output array or output variable
- 98.40 S string
- 99.10 $s nodlin(99.2)='% Last modification 'date'. DAFYDD'
- 99.20 % Last modification 1995-04-24-14:38:46. DAFYDD
- 99.30 def-c samuel(v-x,r-y,s-s)
- 99.40 sdef(slsrv1)/user/spsea/nodal/HFUNS
- 99.50 erase 99
- >do 99
Reason for the erase is you can only do one save pre open.
Then exit from nodal, and do a wreboot of nodal and nodals.
- >wreboot -N nodal
- wreboot: wait up to 15 secs for su spsea -c "unsetenv
NODAL_INIT;./nodal run
- /user/spsea/nodal/NODAL_FUNC" /usr/tmp/FUNC.log
2>
- wreboot: nodal pid wreboot: nodal started with root root permissions
- wreboot: su spsea -c "unsetenv NODAL_INIT;./nodal run
/user/spsea/nodal/NODAL_FUNC"
- /usr/tmp/FUNC.log 2> started
- >wreboot -N nodals
- wreboot: process "nodals" killed
- wreboot: process "nodals" killed
- wreboot: ./nodals -s /user/spsea/nodal/NODAL_INIT started
Now startup nodal again
- C NODAL version 1.1 Mar 24 1995 (CERN SL)
- >
- >NON existent name
- login
Because the NODAL_INIT is set to "", all the define
function have not being loaded.
- >ldef HFUNS
- >samuel
- argument list error
- samuel
- ^
- >set y=1;$set ss="hello"
- >samuel(6,y,ss)
- 6
- 5
- hello
J. Fullerton