Thanks I am using it to set a value for ECVTXTSW where I want to suspend
execution for 90 seconds  

-----Original Message-----
From: IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> On Behalf Of
Farley, Peter x23353
Sent: Monday, December 24, 2018 12:02 PM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Adding 90 seconds to 8 byte TOD FIELD

Joe,

One second in clock units is X'F4240000'.  See the z/Architecture Principles
of Operation for the format and contents of the CPU clock, figure 4-12 on
page 4-47.  The value for one second is in the chart under item 9 on page
4-52 here:

http://publibfi.boulder.ibm.com/epubs/pdf/dz9zr011.pdf

So right after you do STCK TIME then do this to get a time 90 seconds later
(SEC90 is an 8 byte field, the same size as your TIME field):

LLGF   R14,=X'F4240000'
M      R14,=F'90'
ST     R14,SEC90
ST     R15,SEC90+4
LG     R14,TIME
AG     R14,SEC90
STG    R14,TIME

Then you can convert the binary TIME field using STCKCONV.

HTH

Peter

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Joseph Reichman
Sent: Monday, December 24, 2018 10:58 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Adding 90 seconds to 8 byte TOD FIELD

Hi

Would anyone have a example of how to add 90 seconds to 8 byte TOD FIELD

I am not sure of the format of the TOD though I do know it had the actual
date but just by guessing I did the following which didn't seem to product
the right results

           LR    R8,R15                ESTABLISH ADDRESSABILITY           
          USING TESTPRGA,R8                                              
          LR    R14,R13                                                  
          LA    R13,SAVEAREA                                             
          ST    R14,SAVEAREA+4                                           
          STCK  TIME                                                     
          STCKCONV STCKVAL=TIME,CONVVAL=TIMECONV,TIMETYPE=DEC,          X
                DATETYPE=DDMMYYYY                                        
          XR    R2,R2                                                    
          ICM   R2,B'1111',TIME+4                                        
          A     R2,=F'90'                                                
          STCM  R2,B'1111',TIME+4                                        
          STCKCONV STCKVAL=TIME,CONVVAL=TIMECONV,TIMETYPE=DEC,          X
                DATETYPE=DDMMYYYY                                        
          L     R13,4(,R13)                                              
          LM    R14,R12,12(R13)                                          
          BR    R14                                                      
TIME     DS    XL8                                                      
TIMECONV DS    CL16                                                     
--


This message and any attachments are intended only for the use of the
addressee and may contain information that is privileged and confidential.
If the reader of the message is not the intended recipient or an authorized
representative of the intended recipient, you are hereby notified that any
dissemination of this communication is strictly prohibited. If you have
received this communication in error, please notify us immediately by e-mail
and delete the message and any attachments from your system.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email
to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to