April 1, 1981
with a subcode ofX'OC', it can verify that a loadable copy of the
discontiguous shared segment exists on aCP-owned volume. This DIAGNOSE code is called the FINDSYS function. FINDSYS returns the starting
address of the segment. The virtual machine should compare the starting
address of the segment to its own ending address; if the segment does
notoveclay existing storage, it can be loaded.
ALOADSYS function is provided by the CP DIAGNOSE code X'64' and
subcodesX'OO' and X'04'. The section "Diagnose Instruction in a Virtual Machine" contains a complete description of the Diagnose codes
used in the discontiguous saved segment interface. If you wantCMS to
load the named segment in nonshared mode, you may do-so by issuing the CMS command: SET NONSHARE segment name
beforeeMS attaches the named segment. If the segment is loaded in
nonshared mode you can test and debug it usinq theCP TRACE, STORE, and ADSTOP commands and the CMS DEBUG subcommands BREAK and STORE. When eMS loads a named segment in shared mode, it issues the CP DIAGNOSE code X'64' with subcode X'OO'. CMS also issues the same code
with subcodeX'04' to load the named segment in nonshared mode. When a discontiguous saved segment is loaded (or attached) to a
virtual machine,CP expands its segment table entries for that virtual
machine to reflect the highest address of the virtual machine.When a named segment is successfully loaded, all of its storage is
addressable by the virtual machine. For example, whenCMS attaches a
named segment, it can execute the routines contained in that segment.
All of the commands that are executable forCMS are also executable for
the attached named segment, with the following exceptions:• The response for the CP QUERY VIRTUAL STORAGE command does not
reflect the storage occupied by the named segment.• If you execute a command that alters storage (such as STORE), you are
given a nonshared copy of the named segment.When the named segment is no longer needed, it can be detached. The CP DIAGNOSE code X'64' subcode X'08', is called the PURGESYS function;
it detaches named segments.When a named segment is detached, its
storage is no longer addressable by the virtual machine andCP updates
its segment tables. The entries for segments beyond the original
virtual machine size are deleted and the associated real storage is
released.Shared Segment Protection
Installations may optionally protect or not protect shared segments.When segments are protected, CP ensures that a virtual machine does not
access a shared segment that another virtual machine has modified.When segments are not protected, CP does not provide this capability.
If avictual machine modifies an unprotected shared segment, other
virtual machines sharing the segment may be affected by the
modification. Therefore, before running without shared segmentpcotection, ensure that none of the virtual machines modify shared
segments.140 IBM VM/370 System Programmer's Guida
with a subcode of
discontiguous shared segment exists on a
address of the segment. The virtual machine should compare the starting
address of the segment to its own ending address; if the segment does
not
A
subcodes
used in the discontiguous saved segment interface. If you want
load the named segment in nonshared mode, you may do
before
nonshared mode you can test and debug it usinq the
with subcode
virtual machine,
machine to reflect the highest address of the virtual machine.
addressable by the virtual machine. For example, when
named segment, it can execute the routines contained in that segment.
All of the commands that are executable for
the attached named segment, with the following exceptions:
reflect the storage occupied by the named segment.
given a nonshared copy of the named segment.
it detaches named segments.
storage is no longer addressable by the virtual machine and
its segment tables. The entries for segments beyond the original
virtual machine size are deleted and the associated real storage is
released.
Installations may optionally protect or not protect shared segments.
access a shared segment that another virtual machine has modified.
If a
virtual machines sharing the segment may be affected by the
modification. Therefore, before running without shared segment
segments.