I just uploaded a fresh version because I forgot to give the
amode 64, rmode 64 options to pdld and it didn't default to
that based on the 64-bit CSECTs or the use of VD.
 

C:\z390_1.8.3>fc /b pdptest.xxx pdptest.exe
Comparing files pdptest.xxx and PDPTEST.EXE
00000189: 00 31


BFN. Paul.




On Sat, 16 Aug 2025 03:01:11 -0500, Paul Edwards <[email protected]> wrote:

>Hi Abe.
>
>Indeed, I have been using z390 for the last 2 days and it's
>going pretty well.
>
>Still waiting for my membership to be approved here:
>
>https://groups.google.com/g/z390
>
>I also couldn't find out how to link two object files together.
>
>But that's OK, because I will be using pdld for that anyway.
>
>
>As such, I have created what is hopefully a z/OS load module here:
>
>https://pdos.org/rm64test.zip
>
>There is a doit.bat that shows how it was created.
>
>It uses a freshly-built pdld.exe to create the pdptest.exe z/OS
>load module (in iebcopy + ftp rdw format).
>
>Hopefully this is a valid RMODE 64 load module, if someone
>would like to try it out.
>
>
>I also raised (at github) an unrelated issue I found on the way.
>
>Also I would like to know where the 390 executable format is documented,
>mainly the first 32 bytes:
>
>C:\z390_1.8.3\demo>hexdump hello.390
>000000  31303032 54463F3F 000000A0 00000000  1002TF??........
>000010  00000000 90ECD00C 45FF0068 00000000  ........E..h....
>000020  00000000 00000000 00000000 00000000  ................
>000030  00000000 00000000 00000000 00000000  ................
>000040  00000000 00000000 00000000 00000000  ................
>000050  00000000 00000000 00000000 00000000  ................
>000060  00000000 C4C5D4D6 40404040 F0F861F1  ........@@@@..a.
>000070  F661F2F5 F1F54BF5 F9404040 50FD0008  .a....K..@@@P...
>000080  50DF0004 18DFA715 000A000F 0000C8C5  P...............
>000090  D3D3D640 E6D6D9D3 C4F60A23 41F00000  ...@.......#A...
>0000A0  58D0D004 58E0D00C 982CD01C 07FEF6F6  X...X....,......
>0000B0  F6F6F6F6                             ....
>
>C:\z390_1.8.3\demo>
>
>
>Thanks. Paul.
>
>
>
>
>On Sat, 16 Aug 2025 07:19:16 +0200, Abe Kornelis <[email protected]> wrote:
>
>>Paul,
>>
>>z390 has already been mentioned in this thread.
>>There's a web site at www.z390.org - but it has not seen enough
>>maintenance for quite a while, unfortunately.
>>Current version can be obtained from github.com/z390development/z390
>>You can either clone the repo or download from the "Releases".
>>
>>Kind regards & Happy programming,
>>Abe Kornelis
>>==========
>>
>>
>>On 15/08/2025 05:38, Paul Edwards wrote:
>>> On Thu, 14 Aug 2025 20:26:14 -0400, Joseph Reichman <[email protected]> 
>>> wrote:
>>>
>>> Hi Joseph.
>>>
>>> I am interested in RMODE 64 on z/OS too. And have
>>> some questions too.
>>>
>>>
>>> Page 196 shows that RMODE 64 exists as a concept:
>>>
>>> https://publib.boulder.ibm.com/epubs/pdf/iea2b2b1.pdf
>>>
>>> On page 199 I can see V() references in the RLD.
>>>
>>> Where are VD() references documented?
>>>
>>>
>>>
>>>
>>>> It seems you can run a program that is rmode64
>>>> With synchx linkx  and attachx
>>> Does this mean that you can't go EXEC PGM=
>>> and have the program potentially go above 4 GiB?
>>>
>>>
>>> Page 291 shows that AMODE=64 exists, but not RMODE=64
>>> But perhaps if the RMODE is ANY, z/OS can further check
>>> the internals of the load module and decide to locate
>>> it above 4 GiB?
>>>
>>>
>>> I don't have direct access to z/OS. Would someone be
>>> able to assemble this (it may need corrections) and
>>> give me the object code for ONE and TWO, plus the
>>> resulting load module unloaded with IEBCOPY and
>>> transferred with ftp binary with locsite rdw
>>>
>>> Thanks. Paul.
>>>
>>>
>>>
>>> //PDPMVS   JOB CLASS=C,REGION=0K,TIME=1440
>>> //*
>>> //PDPASM   PROC LIST='NOLIST'
>>> //ASM      EXEC PGM=ASMA90,
>>> //   PARM='DECK,&LIST,TERM'
>>> //SYSLIB   DD DSN=SYS1.MACLIB,DISP=SHR,DCB=BLKSIZE=32720
>>> //         DD DSN=&&amp;amp;amp;MACLIB,DISP=(OLD,PASS)
>>> //         DD DSN=SYS1.MODGEN,DISP=SHR
>>> //SYSUT1   DD UNIT=SYSALLDA,SPACE=(CYL,(20,10))
>>> //SYSUT2   DD UNIT=SYSALLDA,SPACE=(CYL,(20,10))
>>> //SYSUT3   DD UNIT=SYSALLDA,SPACE=(CYL,(20,10))
>>> //SYSTERM  DD SYSOUT=*
>>> //SYSPRINT DD SYSOUT=*
>>> //SYSLIN   DD DUMMY
>>> //SYSGO    DD DUMMY
>>> //SYSPUNCH DD DSN=&&amp;amp;amp;OBJSET,UNIT=SYSALLDA,SPACE=(80,(9000,9000)),
>>> //            DISP=(MOD,PASS)
>>> //*
>>> //         PEND
>>> //CREATE   EXEC PGM=IEFBR14
>>> //DD13     DD DSN=&&amp;amp;amp;LOADLIB,DISP=(,PASS),
>>> // DCB=(RECFM=U,LRECL=0,BLKSIZE=6144),
>>> // SPACE=(CYL,(10,10,20)),UNIT=SYSALLDA
>>> //DD14     DD DSN=&&amp;amp;amp;MACLIB,DISP=(,PASS),
>>> // DCB=(RECFM=FB,LRECL=80,BLKSIZE=6160),
>>> // SPACE=(CYL,(10,10,20)),UNIT=SYSALLDA
>>> //*
>>> //ONE      EXEC PDPASM,LIST='LIST'
>>> //SYSIN  DD  *
>>> ***********************************************************************
>>> *                                                                     *
>>> *  This program written by Paul Edwards.                              *
>>> *  Released to the public domain                                      *
>>> *                                                                     *
>>> ***********************************************************************
>>> ***********************************************************************
>>> *                                                                     *
>>> *  ONE - call TWO to set R15                                          *
>>> *                                                                     *
>>> ***********************************************************************
>>> *
>>>          PRINT GEN
>>> * YREGS was not part of the SYS1.MACLIB shipped with MVS 3.8j
>>> * so may not be available, so do our own defines instead.
>>> *         YREGS
>>> R0       EQU   0
>>> R1       EQU   1
>>> R2       EQU   2
>>> R3       EQU   3
>>> R4       EQU   4
>>> R5       EQU   5
>>> R6       EQU   6
>>> R7       EQU   7
>>> R8       EQU   8
>>> R9       EQU   9
>>> R10      EQU   10
>>> R11      EQU   11
>>> R12      EQU   12
>>> R13      EQU   13
>>> R14      EQU   14
>>> R15      EQU   15
>>> SUBPOOL  EQU   0
>>>          CSECT
>>> *
>>>          ENTRY ONE
>>> ONE      DS    0H
>>>          SAVE  (14,12),,ONE
>>>          LR    R10,R15
>>>          USING ONE,R10
>>>          LR    R9,R13
>>>          LA    R13,SAVEAREA
>>>          LG    R15,=VD(TWO)
>>>          LGR   R0,R14
>>>          BALR  R14,R15
>>>          LGR   R14,R0
>>>          LR    R13,R9
>>> *         LA    R15,0
>>>          RETURN (14,12),RC=(15)
>>> SAVEAREA DS    19F
>>>          END
>>> /*
>>> //TWO    EXEC PDPASM,LIST='LIST'
>>> //SYSIN  DD  *
>>> ***********************************************************************
>>> *                                                                     *
>>> *  This program written by Paul Edwards.                              *
>>> *  Released to the public domain                                      *
>>> *                                                                     *
>>> ***********************************************************************
>>> ***********************************************************************
>>> *                                                                     *
>>> *  return 5 in R15                                                    *
>>> *                                                                     *
>>> ***********************************************************************
>>> *
>>>          PRINT GEN
>>> * YREGS was not part of the SYS1.MACLIB shipped with MVS 3.8j
>>> * so may not be available, so do our own defines instead.
>>> *         YREGS
>>> R0       EQU   0
>>> R1       EQU   1
>>> R2       EQU   2
>>> R3       EQU   3
>>> R4       EQU   4
>>> R5       EQU   5
>>> R6       EQU   6
>>> R7       EQU   7
>>> R8       EQU   8
>>> R9       EQU   9
>>> R10      EQU   10
>>> R11      EQU   11
>>> R12      EQU   12
>>> R13      EQU   13
>>> R14      EQU   14
>>> R15      EQU   15
>>> SUBPOOL  EQU   0
>>>          CSECT
>>> *
>>>          ENTRY TWO
>>> TWO      DS    0H
>>>          LA    R15,5
>>>          BR    R14
>>>          END
>>> /*
>>> //*
>>> //LKED     EXEC PGM=IEWL,PARM='MAP,LIST,AMODE=64,RMODE=ANY'
>>> //SYSLIN   DD DSN=&&amp;amp;amp;OBJSET,DISP=(OLD,DELETE)
>>> //*SYSLIB not needed
>>> //SYSLMOD  DD DSN=&&amp;amp;amp;LOADLIB(PDPTEST),DISP=(OLD,PASS)
>>> //SYSUT1   DD UNIT=SYSALLDA,SPACE=(CYL,(2,1))
>>> //SYSPRINT DD SYSOUT=*
>>> //SYSABEND DD SYSOUT=*
>>> //SYSIN DD *
>>> /*
>>> //*
>>> //PDPTEST  EXEC PGM=PDPTEST,PARM='',
>>> //         COND=(4,LT,LKED)
>>> //STEPLIB  DD  DSN=&&amp;amp;amp;LOADLIB,DISP=(OLD,PASS)
>>> //SYSPRINT DD  SYSOUT=*
>>> //SYSTERM  DD  SYSOUT=*
>>> //SYSABEND DD  SYSOUT=*
>>> //SYSIN    DD  DUMMY
>>> //*
>>> //
>>>
>>> ----------------------------------------------------------------------
>>> For IBM-MAIN subscribe / signoff / archive access instructions,
>>> send email to [email protected] with the message: INFO IBM-MAIN
>>
>>----------------------------------------------------------------------
>>For IBM-MAIN subscribe / signoff / archive access instructions,
>>send email to [email protected] with the message: INFO IBM-MAIN
>
>----------------------------------------------------------------------
>For IBM-MAIN subscribe / signoff / archive access instructions,
>send email to [email protected] with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to