Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reimplementation of Random using an LXM pseudo-random number generator #10742

Merged
merged 6 commits into from
Jan 17, 2022

Commits on Jan 14, 2022

  1. Remove tests/lib-random/full_int.ml

    The implementation in stdlib/random.ml is going to change.
    xavierleroy committed Jan 14, 2022
    Configuration menu
    Copy the full SHA
    5ca278b View commit details
    Browse the repository at this point in the history
  2. Reimplementation of Random stdlib module based on L64X128 from the LX…

    …M family
    
    As described in the paper [LXM: Better Splittable Pseudorandom Number
    Generators (and Almost as Fast)](https://doi.org/10.1145/3485525) by
    Guy L. Steele Jr. and Sebastiano Vigna, proceedings of OOPSLA 2021.
    
    This provides a fast, state-of-the-art PRNG with full support for splitting.
    
    Initialization from a seed (an array of integers) proceeds by
    serializing the array to a byte sequence (each seed element occupies 8
    bytes in little-endian representation) then hashing twice using the
    MD5 hash function and two different suffixes, obtaining 256 bits of
    initialization data.
    
    More tests were added in testsuite/tests/lib-random, and the lone test
    testsuite/tests/basic-more/testrandom.ml was moved there.
    xavierleroy committed Jan 14, 2022
    Configuration menu
    Copy the full SHA
    1e9ec33 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    bfb2659 View commit details
    Browse the repository at this point in the history

Commits on Jan 16, 2022

  1. Address review comments

    xavierleroy committed Jan 16, 2022
    Configuration menu
    Copy the full SHA
    f2ebc04 View commit details
    Browse the repository at this point in the history
  2. Update documentation of module Random

    `@since` tags, etc.
    xavierleroy committed Jan 16, 2022
    Configuration menu
    Copy the full SHA
    82547ea View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    b3dc20c View commit details
    Browse the repository at this point in the history