The requirements for the caller are:
Environmental factor | Requirement |
---|---|
Minimum authorization: | Supervisor state or PKM 0-7 |
Dispatchable unit mode: | Task |
Cross memory mode: | PASN=HASN=SASN |
AMODE: | 31- or 64-bit |
ASC mode: | Primary or access register (AR) |
Interrupt status: | Enabled for I/O and external interrupts |
Locks: | The caller must not be holding any locks. |
Control parameters: | Control parameters must be in the primary address
space or, for AR-mode callers, must be in an address/data space that
is addressable through a public entry on the caller's dispatchable
unit access list (DU-AL). The user-provided answer area (via the ANSAREA parameter) has the same requirements and restrictions as the control parameters. The user-provided CPU or core bitmask (via the CPUMASK parameter) has the same requirements and restrictions as the control parameters. |
The caller should include the HISYSERV macro to get equate symbols for the return and reason codes.
The caller must include the HISYSERV macro to get a mapping of the output area provided via the ANSAREA parameter for REQUEST=QUERY.
The caller must include the HISYEXIT macro to get a mapping of the parameter area passed to the exit routine specified by the EXITRTN parameter for REQUEST=PROFILE,ACTION=START requests.
The caller must include the HISYSMPX macro to get a mapping of the parameter area passed to the exit routine specified by the EXITRTN parameter for REQUEST=PROFILE,ACTION=START requests, when the profiler requests sampling data (SAMPLE=YES).
The caller must not have functional recovery routines (FRRs) established.
Before issuing the HISSERV macro, the caller does not have to place any information into any general purpose register (GPR) unless using it in register notation for a particular parameter, or using it as a base register.
Before issuing the HISSERV macro, the caller does not have to place any information into any access register (AR) unless using it in register notation for a particular parameter, or using it as a base register.
Some callers depend on register contents remaining the same before and after issuing a service. If the system changes the contents of registers on which the caller depends, the caller must save them before issuing the service, and restore them after the system returns control.
None.
The HISSERV macro is written as follows:
Syntax | Description |
---|---|
name | name: symbol. Begin name in column 1. |
␣ | One or more blanks must precede HISSERV. |
HISSERV | |
␣ | One or more blanks must follow HISSERV. |
REQUEST=PROFILE | |
REQUEST=QUERY | |
,ACTION=START | |
,ACTION=STOP | |
,OUTPROFILETKN=outprofiletkn | outprofiletkn: RS-type address or address in register (2) - (12) |
,EVENT=event | event: RS-type address or address in register (2) - (12) |
,EVENT=NO_EVENT | Default: EVENT=NO_EVENT |
,SAMPLE=NO | Default: SAMPLE=NO |
,SAMPLE=YES | |
,NAME=name | name: RS-type address or address in register (2) - (12) |
,EXITRTN=exitrtn | exitrtn: RS-type address or address in register (2) - (12) |
,PROFILETKN=profiletkn | profiletkn: RS-type address or address in register (2) - (12) |
,ANSAREA=ansarea | ansarea: RS-type address or address in register (2) - (12) |
,ANSLEN=anslen | anslen: RS-type address or address in register (2) - (12) |
,TYPE=EVENTDATA | |
,TYPE=EVENT | |
,TYPE=SAMPLE | |
,TYPE=PROFILERS | |
,PROFILETKN=profiletkn | profiletkn: RS-type address or address in register (2) - (12) |
,CPUMASK=cpumask | cpumask: RS-type address or address in register (2) - (12) |
,CPUMASK=ALL | Default: CPUMASK=ALL |
,RETCODE=retcode | retcode: RS-type address or register (2) - (12) or (15), (GPR15), |
,RSNCODE=rsncode | rsncode: RS-type address or register (0) or (2) - (12), (00), (GPR |
,PLISTVER=IMPLIED_VERSION | Default: PLISTVER=IMPLIED_VERSION |
,PLISTVER=MAX | |
,PLISTVER=0 | |
,MF=S | Default: MF=S |
,MF=(L,list addr) | list addr: RS-type address or register (1) - (12) |
,MF=(L,list addr,attr) | |
,MF=(L,list addr,0D) | |
,MF=(E,list addr) | |
,MF=(E,list addr,COMPLETE) |
|
The parameters are explained as follows:
To code: Specify the RS-type address, or address in register (2)-(12), of a 16-character field.
To code: Specify the RS-type address, or address in register (2)-(12), of a 32 bit field.
To code: Specify the RS-type address, or address in register (2)-(12), of an 8-character field.
To code: Specify the RS-type address, or address in register (2)-(12), of an 8-character field.
To code: Specify the RS-type address, or address in register (2)-(12), of a 16-character field.
To code: Specify the RS-type address, or address in register (2)-(12), of a character field.
To code: Specify the RS-type address, or address in register (2)-(12), of a doubleword field, or specify a literal decimal value.
To code: Specify the RS-type address, or address in register (2)-(12), of a 16-character field.
To code: Specify the RS-type address, or address in register (2)-(12), of a character field.
To code: Specify the RS-type address of a fullword field, or register (2)-(12) or (15), (GPR15), (REG15), or (R15).
To code: Specify the RS-type address of a fullword field, or register (0) or (2)-(12), (00), (GPR0), (GPR00), REG0), (REG00), or (R0).
If you can tolerate the size change, IBM recommends that you always specify PLISTVER=MAX on the list form of the macro. Specifying MAX ensures that the list-form parameter list is always long enough to hold all the parameters you might specify on the execute form, when both are assembled with the same level of the system. In this way, MAX ensures that the parameter list does not overwrite nearby storage.
Use MF=S to specify the standard form of the macro, which builds an inline parameter list and generates the macro invocation to transfer control to the service. MF=S is the default.
Use MF=L to specify the list form of the macro. Use the list form together with the execute form of the macro for applications that require reentrant code. The list form defines an area of storage that the execute form uses to store the parameters. Only the PLISTVER parameter may be coded with the list form of the macro.
Use MF=E to specify the execute form of the macro. Use the execute form together with the list form of the macro for applications that require reentrant code. The execute form of the macro stores the parameters into the storage area defined by the list form, and generates the macro invocation to transfer control to the service.
None.
Macro HISYSERV provides equate symbols for the return and reason codes. Note carefully that bits 0-15 of the reason code may contain component-diagnostic data and must not be assumed to be 0.
The following table identifies the hexadecimal return and reason codes and the equate symbol associated with each reason code. IBM support personnel may request the entire reason code, including the xxxx value.
Return Code | Reason Code | Equate Symbol Meaning and Action |
---|---|---|
0 | — | Equate Symbol: Hisserv_kRetOk Meaning: HISSERV request successful. Action: Processing continues. |
4 | — | Equate Symbol: Hisserv_kRetWarn Meaning: Warning Action: Refer to the action provided with the specific reason code. |
4 | xxxx0401 | Equate Symbol: Hisserv_kRsnWarn_AnsAreaSmall Meaning: For REQUEST=QUERY, the answer area provided was large enough to hold the minimum amount of data required for the request, but not large enough to hold all of the data requested. Action: Obtain a larger answer area using the HisAns_LengthRequire field returned in the request's ANSAREA. |
8 | — | Equate Symbol: Hisserv_kRetUser Meaning: HISSERV request failed due to a user error. Action: Refer to the action provided with the specific reason code |
8 | xxxx0801 | Equate Symbol: Hisserv_kRsnUser_BadParmArea Meaning: Unable to access parameter area. Action: Check for possible storage overlay. |
8 | xxxx0802 | Equate Symbol: Hisserv_kRsnUser_BadParmAreaALET Meaning: Bad parameter area ALET. Action: Make sure that the ALET associated with the parameter area is valid. The access register might not have been set up correctly. |
8 | xxxx0803 | Equate Symbol: Hisserv_kRsnUser_BadVersion Meaning: Bad version for the parameter list was specified. Action: Check for possible storage overlay. |
8 | xxxx0804 | Equate Symbol: Hisserv_kRsnUser_SrbMode Meaning: This function is only available in task mode. Action: Use function in task mode. |
8 | xxxx0805 | Equate Symbol: Hisserv_kRsnUser_NotEnabled Meaning: This function is only available to enabled programs. Action: Use function while enabled. |
8 | xxxx0806 | Equate Symbol: Hisserv_kRsnUser_LocksHeld Meaning: This function is only available to unlocked programs. Action: Use function while unlocked. |
8 | xxxx0807 | Equate Symbol: Hisserv_kRsnUser_CallerFRR Meaning: This function is only available to programs that have not established an FRR. Action: Retry the request without an FRR established. |
8 | xxxx0808 | Equate Symbol: Hisserv_kRsnUser_BadRequest Meaning: A Bad request was made to the service. Action: Check for possible storage overlay. |
8 | xxxx0809 | Equate Symbol: Hisserv_kRsnUser_BadProfTkn Meaning: Token specified was not a valid token. Action: Use a valid token provided by the REQUEST=PROFILE,ACTION=START request. |
8 | xxxx080A | Equate Symbol: Hisserv_kRsnUser_NameInUse Meaning: The name requested is already in use. Action: Provide a NAME that is unique to the service. |
8 | xxxx080B | Equate Symbol: Hisserv_kRsnUser_InvName Meaning: The name requested is invalid. Action: Provide a valid NAME, it cannot begin with HIS. |
8 | xxxx080C | Equate Symbol: Hisserv_kRsnUser_ExitRtnNotFound Meaning: The exit routine specified wasn't found. Action: Ensure the exit routine specified exists in LPA, the LNKLS concatenation, or the nucleus. |
8 | xxxx080D | Equate Symbol: Hisserv_kRsnUser_ExitRtnInUse Meaning: The exit routine specified is already in use. Action: A different exit routine must be provided. |
8 | xxxx080E | Equate Symbol: Hisserv_kRsnUser_BadEvnTyp Meaning: For REQUEST=PROFILE,ACTION=START requests, one or more event types specified could not be properly configured for because it is not allowed. Only event types returned in the HisEvn_ValidEvnTyp field of a REQUEST=QUERY,TYPE=EVENT request can be requested. Action: Ensure the event types being requested are a subset of the event types returned in the HisEvn_ValidEvnTyp field of a REQUEST=QUERY,TYPE=EVENT request. |
8 | xxxx080F | Equate Symbol: Hisserv_kRsnUser_BadProfReq Meaning: A bad PROFILE request was made to the service. Action: Check for possible storage overlay. |
8 | xxxx0810 | Equate Symbol: Hisserv_kRsnUser_BadProfStart Meaning: For REQUEST=PROFILE,ACTION=START, a bad request was made. At least one event type or sampling should be requested when starting to profile the system. Action: Request at least one event type or sampling. |
8 | xxxx0811 | Equate Symbol: Hisserv_kRsnUser_BadQuery Meaning: For REQUEST=QUERY, a bad query was requested. Action: Check for possible storage overlay. |
8 | xxxx0812 | Equate Symbol: Hisserv_kRsnUser_BadAnsArea Meaning: For REQUEST=QUERY, unable to access answer area. Action: Provide a valid answer area. |
8 | xxxx0813 | Equate Symbol: Hisserv_kRsnUser_BadAnsAreaALET Meaning: Bad answer area ALET. Action: Make sure that the ALET associated with the answer area is valid. The access register might not have been set up correctly. |
8 | xxxx0814 | Equate Symbol: Hisserv_kRsnUser_AnsLenTooSmall Meaning: For REQUEST=QUERY, the answer area length is incorrect. Action: Ensure the answer area length and the storage provided as the answer area is at least HisAns_kLength bytes long. |
8 | xxxx0815 | Equate Symbol: Hisserv_kRsnUser_BadCpuMask Meaning: For REQUEST=QUERY,TYPE=EVENTDATA requests, unable to access the CPU mask. Action: Provide a valid CPU mask. |
8 | xxxx0816 | Equate Symbol: Hisserv_kRsnUser_BadCpuMaskALET Meaning: Bad CPU mask ALET. Action: Make sure that the ALET associated with the CPU mask is valid. The access register might not have been set up correctly. |
8 | xxxx0817 | Equate Symbol: Hisserv_kRsnUser_NoEvnTyp Meaning: For REQUEST=QUERY,TYPE=EVENTDATA requests, the profiler making the request is not profiling events. Action: When registering with the system to profile, indicate the intention to profile events using the EVENT= parameter. |
8 | xxxx0818 | Equate Symbol: Hisserv_kRsnUser_InvProfChange Meaning: A REQUEST=PROFILE request was made from a profiler's exit routine. Action: A REQUEST=PROFILE request cannot be made from a profiler's exit routine. |
C | — | Equate Symbol: Hisserv_kRetEnv Meaning: Environmental error Action: Refer to the action provided with the specific reason code. |
C | xxxx0C01 | Equate Symbol: Hisserv_kRsnEnv_NotAvailable Meaning: Function is not available. Action: This function is only available when the HIS address space is running. |
C | xxxx0C02 | Equate Symbol: Hisserv_kRsnEnv_NotReady Meaning: Function is available but is not currently ready to accept requests. Action: Retry the request. |
C | xxxx0C03 | Equate Symbol: Hisserv_kRsnEnv_NoStorage Meaning: There was not enough storage in HIS private storage to complete the request. Action: Contact your system programmer. |
10 | — | Equate Symbol: Hisserv_kRetUnk Meaning: Unexpected failure. Action: Refer to the action provided with the specific reason code. |
10 | xxxx1001 | Equate Symbol: Hisserv_kRsnUnk_Unk Meaning: Unexpected failure. The state of the request is unpredictable. Action: Contact your system programmer. |
10 | xxxx1002 | Equate Symbol: Hisserv_kRsnUnk_QueryCpu Meaning: For REQUEST=QUERY,TYPE=EVENTDATA, while attempting to query a CPU's event data an unknown error occurred. Action: Contact your system programmer. |
*************************************************************
* Query Events to determine what can be enabled. *
*************************************************************
HISSERV MF=(E,serviceList),REQUEST=QUERY, *
ANSAREA=EvnAnsArea,ANSLEN=EvnAnsLen, *
TYPE=EVENT,RETCODE=LRetCode, *
RSNCODE=LRsnCode
ICM R5,B'1111',LRetCode
JZ EVNAREA_GOOD
LA R4,Hisserv_kRetWarn
CLR R5,R4
JE EVNAREA_WARN
EVNAREA_BAD DS 0H
*
* Place code to check bad return/reason codes here
*
EVNAREA_WARN DS 0H
L R5,LRsnCode
NILH R5,0
CHI R5,Hisserv_kRsnWarn_AnsAreaSmall
JNE EVNAREA_BAD
*
* Place code to handle obtaining more storage for the
* ANSAREA, and repeat the request if necessary.
*
EVNAREA_GOOD DS 0H
LA R8,EvnAnsArea
Using HisEvn,R8
*************************************************************
* Start profiling the system. Output from the previous *
* query is used as input to this query, specifically we *
* want to profile all valid event types. *
*************************************************************
HISSERV MF=(E,serviceList),REQUEST=PROFILE, *
ACTION=START,OUTPROFILETKN=ProfToken, *
NAME=ProfName,EXITRTN=ExitMod,SAMPLE=YES, *
EVENT=HisEvn_ValidEvnTyp,RETCODE=LRetCode, *
RSNCODE=LRsnCode
*
* Place code to check return/reason codes here
*
* Place code to obtain storage of length HisEvnData_kLength,
* save address in R8, length in EvnDataAnsLen
*
EVN_LOOP DS 0H
*************************************************************
* Query the current state of the events *
*************************************************************
Using HisEvnData,R8
HISSERV MF=(E,serviceList),REQUEST=QUERY, *
TYPE=EVENTDATA,PROFILETKN=ProfToken, *
CPUMASK=ALL,ANSAREA=HisEvnData, *
ANSLEN=EvnDataAnsLen,RETCODE=LRetCode, *
RSNCODE=LRsnCode
ICM R5,B'1111',LRetCode
JZ EVNDATAAREA_GOOD
LA R4,Hisserv_kRetWarn
CLR R5,R4
JE EVNDATAAREA_WARN
EVNDATAAREA_BAD DS 0H
*
* Place code to check bad return/reason codes here
*
EVNDATAAREA_WARN DS 0H
L R5,LRsnCode
NILH R5,0
CHI R5,Hisserv_kRsnWarn_AnsAreaSmall
JNE EVNAREA_BAD
*
* Place code to free storage of length EvnDataAnsLen, then
* obtain new storage of length HisEvnData_Length, save address
* in R8, length in EvnDataAnsLen
*
J EVN_LOOP
EVNDATAAREA_GOOD DS 0H
*
* Place code to process the returned events here.
*
L R5,EvnQueryVal
BCT R5,EVNDONE
ST R5,EvnQueryVal
STIMER WAIT,BINTVL=EvnIntv
J EVN_LOOP
EVNDONE DS 0H
*************************************************************
* Stop profiling the system *
*************************************************************
HISSERV MF=(E,serviceList),REQUEST=PROFILE, *
ACTION=STOP,PROFILETKN=ProfToken, *
RETCODE=LRetCode,RSNCODE=LRsnCode
*
* Place code to check return/reason codes here
*
EvnIntv DC F'6000' One minute interval between *
event queries
ProfName DC CL8'SAMPLE01' External name for profiler
ExitMod DC CL8'SAMPEXRT' EXITRTN Name
HISYSERV Return code information and *
ANSAREA mappings.
DynArea DSECT
LRetCode DS F
LRsnCode DS F
ProfToken DC CL16'0'
EvnQueryVal DC F'60' Query events 60 times
EvnAnsArea DS XL(HisEvn_Len+HisEvnCtr_Len)
EvnAnsLen DS AD(HisEvn_Len+HisEvnCtr_Len)
EvnDataAnsLen DS D
HISSERV MF=(L,serviceList)
*
*
* HISEXRTN CSECT, the EXITRTN located in LPA,LNKLIST or the
* nucleus.
*
HISEXRTN CSECT
Using HisExitParm,R1
CLI HisExitParm_Func,HisExitParmFunc_kStat
JNE CHECK_SMP
PUSH USING
USING HisStatParm,R1
*
* Place code to process any service actions
*
J DONE
POP USING
CHECK_SMP DS 0H
CLI HisExitParm_Func,HisExitParmFunc_kSmp
JNE DONE
PUSH USING
USING HisSmpParm,R1
*
* Place code to process the full SDBs
*
POP USING
DONE DS 0H
HISYEXIT
HISYSMPX