Deutsch   English   Français   Italiano  
<2024Sep9.105514@mips.complang.tuwien.ac.at>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!3.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: anton@mips.complang.tuwien.ac.at (Anton Ertl)
Newsgroups: comp.lang.forth
Subject: Re: KISS 64-bit pseudo-random number generator
Date: Mon, 09 Sep 2024 08:55:14 GMT
Organization: Institut fuer Computersprachen, Technische Universitaet Wien
Lines: 32
Message-ID: <2024Sep9.105514@mips.complang.tuwien.ac.at>
References: <vblosf$292ru$1@dont-email.me> <7w7cblb9je.fsf@junk.nocrew.org> <0d6fd7afead1708921d74f60970bcf62@www.novabbs.com>
Injection-Date: Mon, 09 Sep 2024 11:03:50 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="bff24d76364ca7ea0d223f91191d43fd";
	logging-data="2463772"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1/YhpF+wbQzqzGhamQ9BsZP"
Cancel-Lock: sha1:ZmyD3229ao5dtojA9rx8/FrqyUs=
X-newsreader: xrn 10.11
Bytes: 2215

mhx@iae.nl (mhx) writes:
>On Mon, 9 Sep 2024 6:55:49 +0000, Lars Brinkhoff wrote:
>
>[..]
>> I would like to recommend Marsaglia's newer and better xorshift family
>> of PRNGs, and preferably the further development by Sebastiano Vigna
>> called xoroshiro.  The output (with suitable parameters) is very good*,
>> yet the implementation is very simple.
>>
>> *But not cryptography grade.
>
>Being "cryptography grade" is the point when you want to introduce
>something new for a PRNG :--)

Having better randomness at the same speed or better speed with
similar randomness is also relevant outside cryptographic
applications.

> 1320>> : RANDOM        seed  $107465 *  $234567 +  ( -- u )
> 1321:                  9 ROL DUP TO seed ;

So this is a linear congruential generator enhanded with the 9 ROL.
LCGs have known weaknesses that are relevant even for
non-cryptographic applications.  Maybe the ROL fixes those; have you
run it through ransomness testers?

- anton
-- 
M. Anton Ertl  http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
     New standard: https://forth-standard.org/
   EuroForth 2024: https://euro.theforth.net