not held. The second full word contains the value in the lock owner's register 12.
The third and fourth fullwords contain the total amount of time spent spinning on
this lock and the total number of spins respectively.
The VMBLOK lock is located in the VMBLOK at VMLOCK. When the VMBLOK lock is held, VMLOCK contains the logical processor address of the
owning processor.
The RDEVBLOK lock is located in the RDEVBLOK at RDEVIOBL. \Vhen the
lock is held, RDEVIOBL contains the logical processor address of the owning
processor. CP in Attached Processor and Multiprocessor Modes 221
DIAGNOSE Instruction in a Virtual Machine
The DIAGNOSE instruction cannot be used in a virtual machine for its normal
function. If a virtual machine attempts to execute a DIAGNOSE instruction, a
program interrupt returns control to CPo Since a DIAGNOSE instruction issued in
a virtual machine results only in returning control to CP and not in performing
normal DIAGNOSE functions, the instruction is used for communication between
a virtual machine and CPo The machine language format of DIAGNOSE is:
<--------------4-bytes-------------->
83 Rx Ry CODE where:
83 is X'83' and interpreted by the assembler as the DIAGNOSE instruc­
tion.
RX,Ry
CODE
Note: There is no mnemonic for DIAGNOSE. are general purpose registers that contain operand storage addresses or
return codes passed to the DIAGNOSE interface. If the registers con­
tain addresses, those addresses must be real to the virtual machine
issuing the DIAGNOSE. is a two-byte hexadecimal value that CP uses to determine what DIAGNOSE function to perform. The codes defined for the general VM/SP user are described in this section. The code must be a multi­
ple of four. Codes X'OO' through X'FC' are reserved for IBM use,
and codes X'lOO' through X'lFC' are reserved for users. The privi­
lege class for each code is indicated.
Because DIAGNOSE operates differently in a virtual machine than it does in a real
machine, a program should determine that it is operating in a virtual machine
before issuing a instruction, and prevent execution of a DIAGNOSE when in a real machine. The Store Processor ID (STIDP) instruction provides a
program with information about the processor in which it is executing, including
the processor version number. If STIDP is issued from a virtual machine, the ver­
sion number will be X'FF' in the first byte of the CPUID field.
A virtual machine issuing a diagnose instruction should run with interrupts disabled.
This prevents loss of status information pertaining to the diagnose operation such
as condition codes and sense data.
Note: A DIAGNOSE instruction with invalid parameters may in some cases result
in a specification exception or protection exception.
DIAGNOSE Code X'OO' --Store Extended-Identification Code
Privilege class G
Execution of DIAGNOSE code X'OO' allows a virtual machine to examine the VM/SP extended-identification code. For example, an OS/VS 1 virtual machine
issues a DIAGNOSE code X'OO' instruction to determine if the version of VM/SP 222 VM/SP System Programmer's Guide
Previous Page Next Page