Keyboard Shortcuts
Likes
- H390-Vm
- Messages
Search
This group is for all folks running the original IBM VM/370 Release 6 operating system (or later (e.g. VMTCE (Community Edition)) on Hercules. Like the other early IBM operating systems this version has always been in the public domain and so can be freely distributed. The base version as supplied by IBM is lacking in many facilities. IBM solved this by providing additional extension products which were licensed and so are not available. There are however many user enhancements available which can be installed. In addition, in order to get users up and running quickly updated "releases" of VM/370 included the most popular updates are available for download, so novices can start to learn VM without having to delve into the system internals. It is intended that this wiki will provide information on the base release and these updates.
The available versions are here :-
?
?
Re: How Big/Long is a CMS Module
Mark W.,
You are correct to point out the Transient Area as critical to understanding this issue. Mark S., some thoughts in case they are helpful. It's important to remember that?modules are imager of memory after the link loader has been run. This means that all address constants (external or internal, ACONS and VCONS, as we used to call them) have been resolved into absolute addresses, preventing relocation of the code. It's possible to have fully relocatable 370 code, but it is more than a bit painful, and?I'd be surprised if the whole assembler is relocatable. The lack of relocation is why the transient area is handy. The different load areas means that even without relocation, transient modules can call non-transient modules, and nontransient modules can call transient modules. XEDIT and REXX used various forms of voodoo to load essentially all their code except for an initial boot module into high memory (or they lived on a DCSS at an address above the usual user area).?They could run arbitrary modules (as long as there was enough main memory in play). We do have the CMS dynamic loader, but it did not exist at the time that asmg was ported. I believe it's also possible to have a small transient module that can serve as an overlay manager, capable of loading and calling multiple heavyweight non-transient modules that do most of the work. The alternative is to rely on SVC 202, and ensure that the entry point of any module you via SVC will be at the same address as the return address from SVC. While that is theoretically possible, I don't think it's really maintainabl, especially since you have two different memory areas into which you can load modules without conflict. I have not ported stuff from MVS, and indeed I know relatively little about OS variants, but especially the compilers tended to have complicated overlay structures. These were replicated when proting to CMS by using multiple Modules (one for each overlay), and loading and branching to them directly. That's why PLI on CMS consists of so many different modules. Building this up from scratch could be pretty painful at this remove. If you are trying to get ASMG running (even if you only have the MVS version, as it seems), and given that ASMG started as a patched version of Assembler F, I'd start first by looking at the source and build structure for? Assembler F in CMS, as you might be able to use that build structure (and it's execs) as a starting point for the task. With luck you might even be able to replace the existing F Modules with thjeir equivalent G modules. At Brown where I was an undergrad, and where I did most of my hacking on VM, they did have ASMG running in VM, but I'm afraid that I never looked at the implementation. |
Re: How Big/Long is a CMS Module
On Mon, Feb 5, 2024 at 02:50 AM, Dave Wade wrote:
Are you building a compiler for VM?Still struggling with U of Waterloo Assembler G. I need the OS to VM conversion program, RUNPARM/XRUNPARM/WMSASM/... but am struggling with figuring out how/where to load that module, and the ASMG* MODULES, that is, their load/entry address. I also don't get to spend a lot of time thinking about it, as I have a grandson (2 1/2 years old) running around the house 4 days per week. My wife has Parkinson's Disease, so I am picking up more of her duties as time goes along. No tears. It's life. I am learning a H*** of a lot along the way. ?... Mark S. |
Re: How Big/Long is a CMS Module
¿ªÔÆÌåÓýMark, Are you building a compiler for VM? If so you might want to look at the two assembler routines on the Fortran 191 disk which provide the interface between CMS and the OS Fortran compiler. Dave ? From: [email protected] <[email protected]> On Behalf Of Mark Waterbury
Sent: Monday, February 5, 2024 12:35 AM To: [email protected] Subject: Re: [h390-vm] How Big/Long is a CMS Module ? Hi, Bernd, |
Re: How Big/Long is a CMS Module
For future reference.
From GC20-1809-7_VM370_OLTSEP_and_Error_Reporting_Guide_Rel_6_PLC_1_Mar79.pdf Transient Program Area (X'0E000' to X'10000') Since it is not essential to keep all nucleus functions resident in storage all the time, some of them are made "transient." This means that when they are needed, they are loaded from the disk into the transient program area.? Such programs may not be longer than two pages, because that is the size of the transient area.? (A page is 4096 bytes of virtual storage.) All transient routines must be serially reusable since they are not read in each time they are needed. User Program Area (X'20000' to Loader Tables) User programs are loaded into this area? by the LOAD command.? Storage allocated by means of the GETMAIN macro instruction is taken from this area, starting from the high address of the user program.? In addition, this storage area can be allocated from the top down by DMSFREE, if there is not enough storage available in the low DMSFREE storage area. Thus, the usable size of the user program area is reduced by the amount of free storage that has been allocated from it by DMSFREE. Free Storage Management Free storage can be allocated by issuing the GETMAIN or DMSFREE macros. Storage allocated by the GETMAIN macro is taken from the user program area, beginning after the high address of the user program. ... Mark S. |
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 06:32 PM, Mark Waterbury wrote:
RUNPARMS and XRUNPARM are very small, so no reason they could not be compiled and loaded with "(ORIGIN TRANS" to run in the CMS transient area (only 8K), then that way they can load and run any normal VM/CMS module that has the default origin address of x'20000' ... :-)Had not considered that, since I don't know off hand how big the transient area is. I'm sure it's in a manual someplace :-D So, I'll add that to my list.? Thanks! However, since RUNPARM issues a GETMAIN, I need to learn what it does when running from the transient area, as compared to the user area. More to learn. ?... Mark S. |
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 05:57 PM, Bernd Oppolzer wrote:
I have written XRUNPARM some years ago (2016), based on a routine called RUNPARM,I wondered where XRUNPARM came from, and now I know! Thank you!! I do know where the source is, and have assembled it. The TEXT and LISTING files are somewhere around here. I had been looking at LOAD MAPs for both XRUNPARM and RUNPARM, and could not determine where the end/length of/size of the MODULEs were. Something I read steered me to look at DMSMOD, where I found the information cited above. I *think* I'm using it correctly. ?... Mark S. |
Re: How Big/Long is a CMS Module
Hi, Bernd,
See my reply to Mark Stevens regarding RUNPARMS and XRUNPARM... :-) Also, for VM/SP and above, you should be able to use the OSRUN command that is built-in to VM/SP and above to invoke your compiler with an OS style parameter list. All the best, Mark S. Waterbury |
Re: How Big/Long is a CMS Module
Hi, Mark,
RUNPARMS and XRUNPARM are very small, so no reason they could not be compiled and loaded with "(ORIGIN TRANS" to run in the CMS transient area (only 8K), then that way they can load and run any normal VM/CMS module that has the default origin address of x'20000' ... :-) All the best, Mark S. Waterbury |
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 05:54 PM, Ren¨¦ Ferland wrote:
Have you check the assembler code of RUNPARM? I can't say for sure but, looking at it, I feel RUNPARM does make a call to GETMAIN to obtain storage for the module beyond the end of itself.Rene, Yes, I have, and it has a call to GETMAIN and FREEMAIN. ?... Mark S. |
Re: How Big/Long is a CMS Module
¿ªÔÆÌåÓýOne more remark, BTW: when I tested my Pascal compiler - including XRUNPARM - on modern
z/VM, So XRUNPARM on modern VM constantly failed with this error
message: BADSIZE? DS??? 0H which gives (for example): MODULE XXXXXXXX REQUIRES 192K MORE STORAGE no matter how many storage you allocated to your VM/CMS session.
I found a way to overcome this error message, but don't recall
what it was; I'm sorry to say that MVS 3.8 and current z/OS are no problem in
this respect, Sorry, kind regards Bernd
Am 05.02.2024 um 00:57 schrieb Bernd
Oppolzer via groups.io:
|
Re: How Big/Long is a CMS Module
¿ªÔÆÌåÓýI have written XRUNPARM some years ago (2016), based on a routine
called RUNPARM, IIRC, I created XRUNPARM to start my Pascal programs Because XRUNPARM changed its size several times, the origin where
the Pascal programs start is now 20700. You can look at the PASRUN EXEC (which should be on the S or Y
drive of the VM CE edition); ... At the moment, the code generated by the Pascal compiler is the
same for MVS and CMS, and this is fine If you want to know more about the reasons, why I had to write an
own version of RUNPARM HTH, kind regards Bernd
Am 05.02.2024 um 00:06 schrieb Mark A.
Stevens via groups.io:
On Sun, Feb 4, 2024 at 04:42 PM, Dave Wade wrote: |
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 03:06 PM, Mark A. Stevens wrote:
Where MYPROG is a MODULE. So I am attempting to set the load address for MYPROG to be beyond the end of RUNPARM.Have you check the assembler code of RUNPARM? I can't say for sure but, looking at it, I feel RUNPARM does make a call to GETMAIN to obtain storage for the module beyond the end of itself. Cheers, Rene FERLAND, Montreal |
Re: How Big/Long is a CMS Module
Hello, When I was in college (Ohio University), I developed a technique to run multiple commands from one program. Basically, I created a dynamic loader to load the control program.? Once the control program work? was complete, it would call the dynamic loader in unload mode. The dynamic loader would obtain free storage at the highest available area (enough to run the control program). It would load the control program in this area and the transfer control to it.? ?This is the gist of it.? This method allows for a multi-tasking CMS using interrupts. While at Cray Research, I used it to allow customers to run the various Cray CMS commands while also running one normal command (e.g. editor, compiler, etc.) The thing is, customers came back wanting me to allow them to use multiple CMS commands at the?same time. This was beyond the scope of the Cray VM Station.? ?Running our commands at the same time and one normal CMS command was the directive. Could one create an OS that looks like CMS and allows you to run both foreground and multiple backgrounds tasks.? Yeah!? Figured most of it out years ago, but who would fund it?? I can't.? IBM?? Maybe, if they even thought of it. I talked to an IBMer about it while working for Cray.? He was speechless. I told him I developed the idea in college. He could use it, as the idea and technique were from my college days.? Obviously, the IBM VM team never pursued multitasking CMS. Note:? It isn't meant to have a massive overhead for CP. It is meant to give users the ability to do things in parallel, not one command at a time. The key would be in setting the requirements.? Thanks. On Sun, Feb 4, 2024, 16:42 Dave Wade <dave.g4ugm@...> wrote:
|
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 04:42 PM, Dave Wade wrote:
Not sure what you are planning, but if your program has issued any storage requests, the space at the end of the program will have been used to satisfy those requests so not available to load a second program.There is a modules called RUNPARM and XRUNPARM, which is on the Y-Disk. There is also WMSASM from the CBT. All three are supposed to be a 'front end' for programs that are by nature MVS code. They take command line parameters and fix up the PLIST to be something the MVS program will be able to understand. My few examples show something like: RUNPARM MYPROG ... Where MYPROG is a MODULE. So I am attempting to set the load address for MYPROG to be beyond the end of RUNPARM. Do I really know what I am doing. Nope. Just trying to figure it all out. ?... Mark S. |
Re: How Big/Long is a CMS Module
On Sun, Feb 4, 2024 at 03:20 PM, Mark A. Stevens wrote:
The following is wrong. If I could only count. HEX??? RECORD: 000001? RECORDLENGTH: 000080???????????????????????????????????????????????????? ?I think this should be: ... HEX??? RECORD: 000001? RECORDLENGTH: 000080???????????????????????????????????????????????????? ? ?????? ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---|----+----| 000000 .... .... .... .... ...O .... .... .... .... .... .... .... .... .... .... Z... .... .... .... ....???????? ? ZONE?? 0000 0000 0000 0000 002D 0000 0000 0001 4800 0000 0000 0000 0000 0000 0000 E000 0000 0000 0000 0006???????? ? NUMBR? 0200 0200 0258 0258 0156 0000 0000 001F 4003 0000 0300 0000 0000 0000 0000 9000 0000 0000 0000 00E9???????? ? ?????? |STRT|FRST|LAST|LOCC|LDRA|LDRR|PSW????? |LDRF|PRHO| ??????? ADDR LOC? LOC? NT?? DDR? TCD??????????? LAGS LD ?????? STRTADDR? FRSTLOC?? LASTLOC?? LOCCNT??? LDRADDR?? LDRRTCD?? PSW??????????????? LDRFLAGS? PRHOLD ?????? 00020000? 00020000? 00020508? 00020508? 000145D6? 00000000? 00000000 0000011F? 44800300? 00000000 ? ... If I map NUCON variables to those fields, then I end up with LOCCNT having a value of 0000000000020508. Therefor the length of the module is X'0508' or 1288? decimal bytes. Am I close, or just totally lost in the woods? |
Re: How Big/Long is a CMS Module
¿ªÔÆÌåÓýMark, Not sure what you are planning, but if your program has issued any storage requests, the space at the end of the program will have been used to satisfy those requests so not available to load a second program. ? From what I remember there are two ways to load another program and not have it overlay your program. ? One is to use the transient program area. The other is to use an auxiliary directory as used by the assembler. ? In VM/CE we added the RESLIB & NUCXTXT commands which allow TEXT files to be loaded in high memory and called as commands. REXX is installed in this manner. ? Dave ? ? ? From: [email protected] <[email protected]> On Behalf Of Mark A. Stevens via groups.io
Sent: Sunday, February 4, 2024 9:20 PM To: [email protected] Subject: [h390-vm] How Big/Long is a CMS Module ? I've been trying find/figure this out. A CMS module is of a certain length/size. How do I find out what that size is? Why? because I want to call another module, and have it load above the first one, rather than on top of the first. |
How Big/Long is a CMS Module
I've been trying find/figure this out. A CMS module is of a certain length/size. How do I find out what that size is? Why? because I want to call another module, and have it load above the first one, rather than on top of the first.
A related question is: Do I need to specify a full word, or double word, or 4K page boundary as the starting address for the second module? I understand the first one loads at X'020000'. What I have found so far is DMSMOD which GENMOD and LOADMOD come from. It seems there is an 80 byte record at the beginning of the MODULE which contains a number of values, which are stored in NUCON areas, and then written out to the disk file being created. FSVIEW: DMSMOD ASSEMBLE H1?????????? Lines 112-150/725 F80[1-79]? FSVIEW V1.2.5 *? OPERATION??????????????????????????????????????????????????????????? 00112000 *?????????????????????????????????????????????????????????????????????? 00113000 *???????? GENMOD-?????????????????????????????????????????????????????? 00114000 *?????????????????????????????????????????????????????????????????????? 00115000 *???????? GENMOD ISSUES THE START (NO) COMMAND TO FINISH LOADING OF???? 00116000 *???????? OBJECT PROGRAMS. NEXT ERASE THE OLD MODULE IF IT EXISTS.????? 00117000 *???????? THE START AND ENDING LOCATIONS ARE DETERMINED FROM THE??????? 00118000 *???????? USER OPTIONS 'TO' AND 'FROM' OR BY DEFAULT. THE DEFAULT?????? 00119000 *???????? START IS THE ADDRESS OF THE FIRST LOADER TABLE NAME, THE????? 00120000 *???????? DEFAULT END IS THE CURRENT SETTING OF LOCCNT IN NUCON.??????? 00121000 *???????? AN EIGHTY BYTE RECORD IS WRITTEN AS THE FIRST RECORD OF THE?? 00122000 *???????? THE MODULE. THIS RECORD CONSISTS OF THE NUCON LOADER INFORMA- 00123000 *???????? TION. NEXT THE TEXT INFORMATION IS WRITTEN TO THE MODULE????? 00124000 *???????? FILE IN VARIABLE SIZE RECORDS UP TO 65535 BYTES. IF THE?????? 00125000 *???????? MODULE IS NOT FOR A TRANSIENT ROUTINE AND NOMAP WAS NOT?????? 00126000 *???????? SPECIFIED THE LOADER TABLE IS WRITTEN AS THE LAST MODULE????? 00127000 *???????? FILE RECORD. CLOSE THE NEW MODULE FILE AND RETURN TO THE????? 00128000 *???????? CALLER.?????????????????????????????????????????????????????? 00129000 *?????????????????????????????????????????????????????????????????????? 00130000 *???????? LOADMOD-????????????????????????????????????????????????????? 00131000 *?????????????????????????????????????????????????????????????????????? 00132000 *???????? LOADMOD CHECKS FOR THE EXISTENCE OF THE REQUESTED MODULE????? 00133000 *???????? THEN READS THE TEXT INFORMATION INTO THE LOCATIONS SET??????? 00134000 *???????? UP WHEN THE MODULE WAS CREATED. THE MODULE NAME IS??????????? 00135000 *???????? STORED IN THE APPROPRIATE NUCON LOCATION. IF THERE IS???????? 00136000 *???????? A LOADER TABLE RECORD IN THE MODULE IT IS READ INTO?????????? 00137000 *???????? THE LOADER TABLE LOCATION IN STORAGE. SELECTED LOADER???????? 00138000 *???????? INFORMATION IS STORED IN NUCON. RETURN TO CALLER????????????? 00139000 *.????????????????????????????????????????????????????????????????????? 00140000 ... FSVIEW: DMSMOD ASSEMBLE H1?????????? Lines 289-327/725 F80[1-79]? FSVIEW V1.2.5 STBUFF?? LA??? R0,10????????? GET BUFFER FOR FIRST RECORD?????????????? 00289000 ???????? DMSFREE DWORDS=(0),TYPCALL=BALR??????????????????????????????? 00290000 ???????? LR??? R9,R1????????? R9 IS BUFFER ADDRESS????????????????????? 00291000 ???????? ST??? R9,DSKLIN+28?? PUT IN PLIST????????????????????????????? 00292000 ???????? MVC?? 0(80,R9),STRTADDR?? MOVE LOADER INFORMATION TO BUFFER??? 00293000 ???????? STH?? R8,TBENT-STRTADDR(R9)??? SAVE LDR TABLE COUNT??????????? 00294000 ???????? MVC?? DSKLIN+32(4),=XL4'50' SET TO WRITE 80 BYTES????????????? 00295000 ???????? LA??? R1,DSKLIN????? ADDR. OF WRITE PLIST????????????????????? 00296000 ???????? L???? R15,AWRBUF???? ADDR. OF WRBUF??????????????????????????? 00297000 ???????? BALR? R14,R15??????? WRITE FIRST RECORD OF MODULE????????????? 00298000 ... NUCON ... FSVIEW: CMSHRC MACLIB F1????????? Lines 1285-1323/3391 F80[1-79]? FSVIEW V1.2.5 STRTADDR DC??? 1F'0'????????? MODULE STARTING ADDRESS?????????????????? 00252100 FRSTLOC? DC??? 1F'0'????????? MODULE BEGINNING ADDRESS????????????????? 00252200 LASTLOC? DC??? 1F'0'????????? MODULE ENDING ADDRESS???????????????????? 00252300 LOCCNT?? DC??? 1F'0'????????? LOADER LOCATION COUNTER?????????????????? 00252400 LDRADDR? DC??? 1F'0'????????? LOADER RETURN ADDRESS???????????????????? 00252500 LDRRTCD? DC??? 1F'0'????????? LOADER RETURN CODE??????????????????????? 00252600 PSW????? DC??? 1D'0'????????? USER'S STARTING PSW?????????????????????? 00252700 LDRFLAGS DC??? 1F'0'????????? LOADER FLAGS????????????????????????????? 00252800 PRHOLD?? DC??? 1F'0'????????? PSEUDO REGISTER COUNTER?????????????????? 00252900 TBENT??? DC??? H'0'?????????? INITIALIZE TABLE ENTRIES TO?????????????? 00262000 *???????????????????????????? ZEROES??????????????????????????????????? 00262100 ... So when I hexdump, sorry HEXPRINT the file, I get the following which I edited, inserting spaces between each fullword. HEX??? RECORD: 000001? RECORDLENGTH: 000080???????????????????????????????????????????????????? ? ?????? ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---| ---- +--- -|-- --+- ---|----+----| 000000 .... .... .... .... ...O .... .... .... .... .... .... .... .... .... .... Z... .... .... .... ....???????? ? ZONE?? 0000 0000 0000 0000 002D 0000 0000 0001 4800 0000 0000 0000 0000 0000 0000 E000 0000 0000 0000 0006???????? ? NUMBR? 0200 0200 0258 0258 0156 0000 0000 001F 4003 0000 0300 0000 0000 0000 0000 9000 0000 0000 0000 00E9???????? ? ???? ? |STRTADDR |FRSTLOC? |LASTLOC? |LOCCNT?? |LDRADDR? |LDRRTCD? |PSW??????????????? |LDRFLAGS |PRHOLD?? | ?????? 00020000? 00020508? 000125D6? 00000000? 44800003? 00030000? 00000000 00000000?? 00000000? 00000000 ? ?????? 00020000? 00020508? 00000000? 0000011F? 00000000? 00000000? 00000000 E9000000?? 00000000? 00000E69 ... If I map NUCON variables to those fields, then I end up with LOCCNT having a value of 000000000000011F. Therefor the length of the module is X'011F' or 287 decimal bytes. Am I close, or just totally lost in the woods, and I should send up a flare? ?... Mark S. |
MONITOR Files
Hi Peter,
it took me some time, but eventually I found the MONSTATS program from the 1985 Waterloo Tape at this website: It takes it's input directly from the reader and prints a nice report of the data collected by the MONITOR command. Thanks again for pointing me to Waterloo Tapes. Regards Ralf? |