Re: [hercules-os380] New Stanford Pascal compiler for MVS ready for download

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [hercules-os380] New Stanford Pascal compiler for MVS ready for download

Hercules390 - Mvs mailing list
Hello all,

there has been some discussion recently on H390-MVS about DSQRT
(the Fortran SQRT subroutine in SYS1.FORTLIB). This is used in
Stanford Pascal, too. When I tested this on MVS, I realized that the
JCL procedures provided with the compiler didn't work with respect
to SYS1.FORTLIB, because there was a mix of RECFM=U and RECFM=FB
datasets in the SYSLIB concatenation.

Another issue: if you download the ZIP file from the website
http://bernd-oppolzer.de/job9.htm
and upload the members contained there to MVS or z/OS,
the compiler will not run out of the box, because in the JCL procedures
a LOADLIB called PASCALN.COMPILER.LOAD is referenced, but it is
not there ... you have to build it first from the TEXT files present
in the ZIP file.

I fixed both issues now:

there is an INSTALL job in PASCALN.COMPILER.CNTL, which builds
two LOADLIBs (PASCALN.COMPILER.LOAD and PASCALN.RUNTIME.LOAD)
and LINKs the needed LOAD objects there.

Now the TESTSQRT program, which prints the square roots from 1 to 20,
works on MVS, too.

I will replace the ZIP file in the next few days. If you want to start
with the
existing file already, here is the INSTALL JCL:


//PASCALN3 JOB (PASCAL),'LINK COMPILER',CLASS=A,MSGCLASS=X,
//             TIME=1440,REGION=9000K,MSGLEVEL=(1,1)
//*
//*
//DEFINE EXEC  PGM=IEFBR14
//*
//DATEI1   DD  UNIT=DISK,DSN=PASCALN.COMPILER.LOAD,
//             SPACE=(CYL,(1,1,100),RLSE),DISP=(NEW,CATLG),
//             DCB=(RECFM=U,LRECL=0,BLKSIZE=19069)
//*
//DATEI2   DD  UNIT=DISK,DSN=PASCALN.RUNTIME.LOAD,
//             SPACE=(CYL,(1,1,100),RLSE),DISP=(NEW,CATLG),
//             DCB=(RECFM=U,LRECL=0,BLKSIZE=19069)
//*
//*
//LKEDA  EXEC  PGM=IEWLF880
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.TEXT
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   INCLUDE SYSLIB(PASMONN)
   NAME PASMONN(R)
//*
//*
//LKEDB  EXEC  PGM=IEWLF880
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.TEXT
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   INCLUDE SYSLIB(PASLIBX)
   NAME PASLIBX(R)
//*
//*
//LKEDC  EXEC  PGM=IEWLF880
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.TEXT
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   INCLUDE SYSLIB(PASSNAP)
   NAME PASSNAP(R)
//*
//*
//LKEDD  EXEC  PGM=IEWLF880
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.TEXT
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   INCLUDE SYSLIB(PASUTILS)
   NAME PASUTILS(R)
//*
//*
//LKED1  EXEC  PGM=IEWLF880
//SYSOBJ   DD  DISP=SHR,DSN=PASCALN.COMPILER.TEXT
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//         DD  DISP=SHR,DSN=SYS1.FORTLIB
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.COMPILER.LOAD(PASCAL1)
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   ENTRY $PASENT
   INCLUDE SYSLIB(PASMONN)
   INCLUDE SYSOBJ(PASCAL1)
   INCLUDE SYSLIB(PASLIBX)
   INCLUDE SYSLIB(PASSNAP)
//*
//*
//LKED2  EXEC  PGM=IEWLF880
//SYSOBJ   DD  DISP=SHR,DSN=PASCALN.COMPILER.TEXT
//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//         DD  DISP=SHR,DSN=SYS1.FORTLIB
//SYSLMOD  DD  DISP=SHR,DSN=PASCALN.COMPILER.LOAD(PASCAL2)
//SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(10,10))
//SYSLIN   DD  DDNAME=SYSIN
//SYSIN    DD  *
   ENTRY $PASENT
   INCLUDE SYSLIB(PASMONN)
   INCLUDE SYSOBJ(PASCAL2)
   INCLUDE SYSLIB(PASLIBX)
   INCLUDE SYSLIB(PASSNAP)
//*


and:

you will have to replace the SYSLIB concatenations in the LINK steps
of the compile JCL; it should now look like this:

//SYSLIB   DD  DISP=SHR,DSN=PASCALN.RUNTIME.LOAD
//         DD  DISP=SHR,DSN=SYS1.FORTLIB

... looks simple ...

BTW: I still don't know if the compiler will run on today's z/OS,
but I would like to know, so if someone could test it, I would be
VERY HAPPY (of course, AMODE 24, at the moment).

Kind regards,
have a nice day

Bernd


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [hercules-os380] New Stanford Pascal compiler for MVS ready for download

Hercules390 - Mvs mailing list
On 5/23/17 7:07 PM, Bernd Oppolzer [hidden email] [H390-MVS] wrote:

I have one nasty comment:

> //SYSPRINT DD  SYSOUT=A,DCB=BLKSIZE=605
SYSOUT=A is so early sixties. On my system it's the garbage queue
(unwanted start jobs, dumps, etc.). If you made it SYSOUT=* (not even
quotes needed nowadays) the user could control it with one change on the
JOB card MSGCLASS.

Also none of the linkage-editor DDs requires a block size. The size you
specify in the IEFBR14 step is ignored, unless you also have a DCBS
PARM. The actual block size used will be the largest fitting multiple of
2KiB that fits. For the GCC, and my distribution libraries, we use 6144
for load modules, and 6160 for source, as they will restore to anything
used with Hercules (other than 2311 and 2325).

Gerhard Postpischil
Bradford, VT

---
This email has been checked for viruses by AVG.
http://www.avg.com

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [hercules-os380] New Stanford Pascal compiler for MVS ready for download

Hercules390 - Mvs mailing list
Ok, thank you,

and: sorry, I copied much of the JCL stuff
from the old Pascal's JCL, without much understanding
of the details.

BTW: I recently improved (I hope so) the error handling routine
in the Pascal runtime PASMONN, and while doing this, I changed
the interface from the first level interrupt handler (SPIE exit) to this
routine. And this in turn has the effect that the routine PASSNAP,
which prints the Pascal variables in Pascal notation in case of an error,
will work no more (PASSNAP is WXTRN; if it is present, it will be called,
if not, the "simple" error handling inside PASMONN is used ... but PASSNAP
can also be called without an error using the SNAPSHOT builtin function -
there are runtime options NOSNAP and NOSPIE, too; NOSNAP disables
PASSNAP, and NOSPIE disables all Pascal specific error handling).

I will repair this in the next few weeks; maybe I can change PASSNAP to
use the new interface, or I will have to fall back to the old interface ...
we will see.

At the moment you should be warned not to use PASSNAP.
Maybe the NOSNAP runtime option is the best choice at the moment.

Kind regards

Bernd



Am 24.05.2017 um 03:34 schrieb Gerhard Postpischil [hidden email]
[H390-MVS]:

>
> On 5/23/17 7:07 PM, Bernd Oppolzer [hidden email] [H390-MVS]
> wrote:
>
> I have one nasty comment:
>
> > //SYSPRINT DD SYSOUT=A,DCB=BLKSIZE=605
> SYSOUT=A is so early sixties. On my system it's the garbage queue
> (unwanted start jobs, dumps, etc.). If you made it SYSOUT=* (not even
> quotes needed nowadays) the user could control it with one change on the
> JOB card MSGCLASS.
>
> Also none of the linkage-editor DDs requires a block size. The size you
> specify in the IEFBR14 step is ignored, unless you also have a DCBS
> PARM. The actual block size used will be the largest fitting multiple of
> 2KiB that fits. For the GCC, and my distribution libraries, we use 6144
> for load modules, and 6160 for source, as they will restore to anything
> used with Hercules (other than 2311 and 2325).
>
> Gerhard Postpischil
> Bradford, VT
>
>

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [hercules-os380] New Stanford Pascal compiler for MVS ready for download

Hercules390 - Mvs mailing list
Many thanks again to Gerhard for his remarks on the JCL
problems. I fixed this, not only on the INSTALL job, but also
on the JCL procs which are located in PASCALN.COMPILER.PROCLIB
and supposed to be copied at installation time to SYS2.PROCLIB
(SYSOUT=*; no BLKSIZE on the load library definition; I get 32760).

I added some DCB information to all the OUTPUT DD statements:

//OUTPUT   DD  SYSOUT=&SOUT,DCB=(RECFM=V,LRECL=133)

and now the job output from the Pascal compile jobs look much nicer :-)

The changes are all included in the MVS related ZIP file on the website
http://bernd-oppolzer.de/job9.htm

furthermore, there are more detailed instructions how the installation on
MVS (or z/OS) should be done.

BTW: René Jansen will test the compiler on z/OS in the next few days.
He already tried the non-mainframe version on Linux and Mac OS, which
was successful (with the exception of a known bug with integer terminal
I/O,
which is present since 03.2017 - I will take care of that). So now Mac
OS is
another supported (and tested) target platform :-)

The external file names on the non-mainframe platforms are controlled by
environment variables; I chose

set DD:pasfile = external_file_including_path  (Windows)

to do this, but, as René found out, the colon is problematic with several
shells, so we will change that to

set DD_pasfile = external_file_including_path  (all systems)

of course, the syntax to set environment variables is different, depending
on the platform.

Many thanks to René and Gerhard and all the others who are interested
and contribute.

Kind regards

Bernd



Am 24.05.2017 um 19:41 schrieb Bernd Oppolzer [hidden email]
[H390-MVS]:

>
> Ok, thank you,
>
> and: sorry, I copied much of the JCL stuff
> from the old Pascal's JCL, without much understanding
> of the details.
>
> BTW: I recently improved (I hope so) the error handling routine
> in the Pascal runtime PASMONN, and while doing this, I changed
> the interface from the first level interrupt handler (SPIE exit) to this
> routine. And this in turn has the effect that the routine PASSNAP,
> which prints the Pascal variables in Pascal notation in case of an error,
> will work no more (PASSNAP is WXTRN; if it is present, it will be called,
> if not, the "simple" error handling inside PASMONN is used ... but PASSNAP
> can also be called without an error using the SNAPSHOT builtin function -
> there are runtime options NOSNAP and NOSPIE, too; NOSNAP disables
> PASSNAP, and NOSPIE disables all Pascal specific error handling).
>
> I will repair this in the next few weeks; maybe I can change PASSNAP to
> use the new interface, or I will have to fall back to the old
> interface ...
> we will see.
>
> At the moment you should be warned not to use PASSNAP.
> Maybe the NOSNAP runtime option is the best choice at the moment.
>
> Kind regards
>
> Bernd
>
>
>
> Am 24.05.2017 um 03:34 schrieb Gerhard Postpischil
> [hidden email] [H390-MVS]:
>>
>> On 5/23/17 7:07 PM, Bernd Oppolzer [hidden email] [H390-MVS]
>> wrote:
>>
>> I have one nasty comment:
>>
>> > //SYSPRINT DD SYSOUT=A,DCB=BLKSIZE=605
>> SYSOUT=A is so early sixties. On my system it's the garbage queue
>> (unwanted start jobs, dumps, etc.). If you made it SYSOUT=* (not even
>> quotes needed nowadays) the user could control it with one change on the
>> JOB card MSGCLASS.
>>
>> Also none of the linkage-editor DDs requires a block size. The size you
>> specify in the IEFBR14 step is ignored, unless you also have a DCBS
>> PARM. The actual block size used will be the largest fitting multiple of
>> 2KiB that fits. For the GCC, and my distribution libraries, we use 6144
>> for load modules, and 6160 for source, as they will restore to anything
>> used with Hercules (other than 2311 and 2325).
>>
>> Gerhard Postpischil
>> Bradford, VT
>>
>>
>

Loading...