🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: sci.crypt.random-numbers
Article #4

Re: Gathering entropy for PRNGs on MVS

#4
From: Michael Amling
Date: Tue, 11 Mar 2003 04:30
36 lines
3056 bytes
Bob wrote:
> Hi Duke,
> 
> I haven't  played with IBM mainframes for quite some time, but I had a
> similar problem many years ago.  The entity I settled on was derived from
> the 8 byte TOD clock - but I reversed the BYTES not the bits.  As you know,
> the high order byte of the TOD clock changes least quickly, while the low
> order byte of the TOD clock changes most quickly.  From (dim) memory, the
> (32 bit) code went something like
> 
> ; get TOD into my memory
>       SVC ???,TODF
>       ICM R4,1,TODF
>       ICM R4,2,TODF+1
>       ICM R4,4,TODF+2
>       ICM R4,8,TODF+3
>       ICM R5,1,TODF+4      ; note adjacent register
>       ICM R5,2,TODF+5
>       ICM R5,4,TODF+6
>       ICM R5,8,TODF+7
>       STM R4,R5,TODR
> 
> TODF DS 1D    ; TOD Forwards
> TODR DS 1D    ;TOD Reverse
> 
> I can't remember the exact format of the ICM instruction (does the mask come
> first?).  I can't remember the exact SVC call to get the eight byte TOD
> either.  What I do remember is that the results were more accurate than the
> documentation described.

   Your ICMs are OK. The register is first (as with L and ST). The 
8-byte TOD clock is available from the unprivileged STCK instruction 
(although it's also one of the formats you can ask for from the TIMER SVC).
   What's the advantage of reversing the order?

--Mike Amling
Technical Details
Message-ID: <3E6D5932.2050701@nospam.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!c03.atl99!rip!news.webusenet.com!prodigy.com!newsmst01.news.prodigy.com!prodigy.com!postmaster.news.prodigy.com!newssrv26.news.prodigy.com.POSTED!not-for-mail
References: <b4ieak$2qn$1@slb9.atl.mindspring.net> <b4j0cr$1vn15u$1@ID-180637.news.dfncis.de>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fd4af,4336d2c2bccbde14
X-Google-Attributes: gidfd4af,public
X-Google-Thread: fb57f,4336d2c2bccbde14
X-Google-Attributes: gidfb57f,public
X-Google-Thread: fed83,4336d2c2bccbde14
X-Google-Attributes: gidfed83,public
X-Google-ArrivalTime: 2003-03-10 19:35:08 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!c03.atl99!rip!news.webusenet.com!prodigy.com!newsmst01.news.prodigy.com!prodigy.com!postmaster.news.prodigy.com!newssrv26.news.prodigy.com.POSTED!not-for-mail
Message-ID: <3E6D5932.2050701@nospam.com>
From: Michael Amling <nospam@nospam.com>
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-US; rv:1.0.2) Gecko/20021120 Netscape/7.01
X-Accept-Language: en, en-us, en-gb, de, de-de
MIME-Version: 1.0
Newsgroups: sci.crypt.random-numbers,bit.listserv.ibm-main,sci.crypt
Subject: Re: Gathering entropy for PRNGs on MVS
References: <b4ieak$2qn$1@slb9.atl.mindspring.net> <b4j0cr$1vn15u$1@ID-180637.news.dfncis.de>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 37
NNTP-Posting-Host: 68.23.41.46
X-Complaints-To: abuse@prodigy.net
X-Trace: newssrv26.news.prodigy.com 1047357053 ST000 68.23.41.46 (Mon, 10 Mar 2003 22:30:53 CST)
NNTP-Posting-Date: Mon, 10 Mar 2003 22:30:53 CST
Organization: Prodigy Internet http://www.prodigy.com
X-UserInfo1: F[OIR^SDYJTORUH]]RKB_UDAZZ\DPCPDLXUNNHPIMASJETAANVW[AKWZE\]^XQWIGNE_[EBL@^_\^JOCQ^RSNVLGTFTKHTXHHP[NB\_C@\SD@EP_[KCXX__AGDDEKGFNB\ZOKLRNCY_CGG[RHT_UN@C_BSY\G__IJIX_PLSA[CCFAULEY\FL\VLGANTQQ]FN
Date: Tue, 11 Mar 2003 04:30:53 GMT