Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:117966 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 23792 invoked from network); 16 Jun 2022 11:49:46 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 16 Jun 2022 11:49:46 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 835BC180543 for ; Thu, 16 Jun 2022 06:37:46 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS24940 176.9.0.0/16 X-Spam-Virus: No X-Envelope-From: Received: from chrono.xqk7.com (chrono.xqk7.com [176.9.45.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 16 Jun 2022 06:37:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bastelstu.be; s=mail20171119; t=1655386664; bh=f6EZ9Rdlh9j0aFy2M+ASVPoJAMVKAnLx3t8OwgpY7Ew=; h=Date:Subject:From:To:References:In-Reply-To:From; b=ey1qm2MpqUgM+xNHfZ+7XucR8piybDdHdqAWR8T3nDwgxt8RZDjYHhDWEsl58M3Mp vkfJUecCl2naK+gEatqmqYiUgsZvEjV7JfjCdsJpnvZwq8oi+xxWqDrhry4oDZwvvp GE1AJZ6GylS6eowa7kPYgDguvStCHRRjNTTWgOJMXvhh8v2rq1h2VCgW8EQmaoXVlV D2mjaHNQSSJw52F8w3K6USecLVUXeVAYT29mWsRjGqTQkBGNHKxFcUmjKHc4MJZuOz 7UyGdn8AcygoSjbYakEQS49y3ThwibUL/xp/p6VjbZ8jNYMFYK3esOo9kZBPJ+6GuJ 80jrzWPLE/+Fg== Message-ID: <1717d744-b7df-b39d-f280-83283c11ec7b@bastelstu.be> Date: Thu, 16 Jun 2022 15:37:44 +0200 MIME-Version: 1.0 Content-Language: en-US To: Go Kudo , internals@lists.php.net References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: [PHP-DEV] Re: [RFC] [VOTE] Random Extension 5.x From: tim@bastelstu.be (=?UTF-8?Q?Tim_D=c3=bcsterhus?=) Hi On 6/16/22 14:52, Tim Düsterhus wrote: > (3) Naming of PCG64: > > I must admit that the fact that PCG is a full family of similar, but not > identical generators is one thing that made me (and still makes me) > prefer the xoshiro family which has clearer names for its variants. > > It was also pretty hard to find the PCG definitions on the PCG website, > but I believe that it refers to this: > > https://www.pcg-random.org/using-pcg-c.html#low-level-api? > > In that case PCG64S would be consistent with the upstream high level API > name. I am not sure if Pcg64s would be more readable, though. > > It would definitely need a good explanation in the documentation which > exact variant it is, though. I've now had a look at the Paper [1], because I wanted to find out what the various bits and pieces within the full oneseq-128-xsl-rr-64 name mean and in the paper I came across section "6.3 Specific Implementations" which notes: > The library provides named generators based on > their properties, not their underlying implementations (e.g., pcg32_unique for a > general-purpose 32-bit generator with a unique stream). That way, when future family > members that perform even better are discovered and added (hopefully due to the > discoveries of others), users can switch seamlessly over to them. This implies that the official Pcg64s name might refer to a different implementation in the future. This makes it hard for PHP to keep the compatibility guarantee that a specific engine will always refer to a specific well-defined RNG. This implies that the engine needs to be named "PcgOneseq128XslRr64" to accurately describe the implementation. This - of course - is absolutely unwieldy. Note sure what the best course of action is here. [1] https://www.pcg-random.org/pdf/hmc-cs-2014-0905.pdf Best regards Tim Düsterhus