Thanks for all for the excellent responses on this one! -----Original Message----- From: IBM Mainframe Assembler List [mailto:[email protected]] On Behalf Of Peter Relson Sent: Sunday, November 28, 2021 9:19 AM To: [email protected] Subject: Re: FPR usage question
Caution! This message was sent from outside your organization. Gil wrote <snip> Do you save and restore them? </snip> The information pertinent to the question is here: https://www.ibm.com/docs/en/zos/2.5.0?topic=registers-linkage-convention-floating-point There is no need to save/restore FPRs 0-7 (as opposed to 8-15). Further info is here: https://www.ibm.com/docs/en/zos/2.5.0?topic=conventions-saving-calling-programs-registers such as: Saving the calling program's registers Unless otherwise defined by the individual interface, the calling program expects upon return: ... FPRs 8 - 15 are unchanged; The Floating Point Control (FPC) Register is unchanged except for two fields: the IEEE exception flags and the data exception code (DXC). Vector registers (VRs) 8 - 15, bytes 0 - 7, and the entirety of VRs 16 - 23 are unchanged. Anything that is expected to be unchanged across a call according to the linkage conventions must be preserved by a user (whether by not using or by save/restore). Gil wrote <snip> I remember being asked, "Do you use FPRs? If not, we can bypass saving/restoring them for performance when we gen your dedicated VSE system." </snip> For z/OS, this question relates to each work unit and the question is "does the work unit use FPRs 8-15 or VRs?". If the answer is no, then that work unit does not save/restore those regs upon undispatch/redispatch and thus saves some cycles. Peter Relson z/OS Core Technology Design
