z/OS MVS Programming: Extended Addressability Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Example of fixing pages of a private memory object

z/OS MVS Programming: Extended Addressability Guide
SA23-1394-00

Using the memory object created earlier, the following example in an AMODE 31 program, fixes 5 pages of the memory object, then unfixes them:
         SYSSTATE ARCHLVL=2
         .
         .
         . 
         XC    R_LIST(100),R_LIST      Clear the range list
         LG    12,VIRT64_ADDR          Get starting address to pagefix
         STG   12,R_START              Save it in range list
         LGHI  4,5                     Load number of pages to fix
         STG   4,R_PAGES               Save it in range list
         SLR   12,12                   Generate primary-space alet
         ST    12,R_ALET               Save it in range list
         LA    4,R_LIST                Get address of rangelist
         LLGTR 4,4                     Make it a 64-bit pointer
         STG   4,RLISTPTR              Save it
* Now pagefix the 5 pages
         IARV64 REQUEST=PAGEFIX,                                       +
               RANGLIST=RLISTPTR,                                      +
               LONG=NO
* Using the same rangelist, unfix the pages
         LA    12,R_LIST               Get address of range list
         LLGTR 12,12                   Make it a 64-bit pointer
         STG   12,RLISTPTR             Save it
         IARV64 REQUEST=PAGEUNFIX,                                     +
               RANGLIST=RLISTPTR
*
*   Declares for example
R_LIST   DS    CL100
         ORG   R_LIST
R_START  DS    ADL8
R_PAGES  DS    ADL8
R_ALET   DS    AL4
RLISTPTR DS    AD
VIRT64_ADDR DS AD

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014