On Sat, 18 Jul 2026 19:09:01 -0500, Paul Gilmartin <[email protected]> wrote:

>On Sat, 18 Jul 2026 18:03:38 -0500, Charles Mills  wrote:
>
>>On Sat, 18 Jul 2026 15:59:06 -0500, Paul Gilmartin  wrote:
>>    ...    
>>>TRY  fetch CVTLSO
>>>     STCK
>>>    compare fetched value to CVTLSO
>>>    BNE TRY
>>
>>I did that sort of thing on a CMS system IIRC where I needed millisecond 
>>resolution. I had one API that gave me TOD and one that gave me STCK. I 
>>called TOD, then STCk, then TOD to see if it had changed. Seemed to work well.
>>
>If they disagreed, did you do another STCK?

Beating a dead horse to death here. Let me try to recall. How's this?

TRY: 
  GET ms   (a)
  GET HMS  (b)
  GET ms   (c)
  C   (c) to (a)
  JL  TRY   

If (c) is lower than (a) then the ms wrapped. We don't know if they wrapped 
before or after (b), so we go back and do it all again. If the ms did not wrap, 
then either value is "pretty good" relative to the HMS. Assumes we have 
sufficient dispatching priority that  we can get through the loop in less than 
a real-time second. (If not, then ms are pretty irrelevant.) And yeah, we could 
move the first GET ms outside the loop and replace it with a copy of (c) to 
(a). 

How's that?
CM

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to