GithubHelp home page GithubHelp logo

bkmgit / shishua Goto Github PK

View Code? Open in Web Editor NEW

This project forked from espadrine/shishua

0.0 0.0 0.0 198 KB

SHISHUA – The fastest PRNG in the world

License: Creative Commons Zero v1.0 Universal

Makefile 5.21% C 89.47% Shell 5.32%

shishua's Introduction

SHISHUA – The Fastest PRNG In The World

The announcement and explanation blog post is here.

Note: please do not use this for cryptographic purposes. If you need security, a recommended option is ChaCha20.

Implementations:

Comparison

Name Intel Performance ARM Performance Quality Seed correlation
SHISHUA 52.93 GB/s 8.78 GB/s >32 TiB >32 TiB
xoshiro256+x8 40.18 GB/s 3.69 GB/s 1 KiB 0 KiB
RomuTrio 8.62 GB/s 4.76 GB/s >32 TiB 1 KiB
xoshiro256+ 7.88 GB/s 4.31 GB/s 512 MiB 1 KiB
wyrand 7.00 GB/s 2.53 GB/s >32 TiB 32 KiB
Lehmer128 6.14 GB/s 1.83 GB/s >32 TiB 1 KiB
ChaCha8 6.28 GB/s 1.72 GB/s >32 TiB? >32 TiB?
RC4 0.35 GB/s 0.15 GB/s 1 TiB 1 KiB
  1. Performance: in number of CPU cycles spent per byte generated, on N2 GCP instances. On N2D (AMD), the order is the same.
  2. Quality: level at which it fails PractRand. We show a > if it did not fail. We put a question mark if we have not proved it.
  3. Seed correlation: PractRand on interleaving of bytes from eight streams with seeds 1, 2, 4, 8, 16, 32, 64, 128. We use PractRand with folding 2 and expanded tests.

On the subject of seed correlations, the ./bin/sample-seed-fingerprints.sh program highlights additional anomalies:

  • RC4 has weak seeds with heavy artefacts visible in the fingerprints.
  • RomuTrio's fingerprints start with the same first character for all seeds.

Commands

  • make: build ./shishua.
  • make test: run performance tests, PractRand, and BigCrush on SHISHUA.
  • make test/benchmark-seed: run seed correlation test.
  • make test/benchmark-perf: run performance comparison locally.
  • make benchmark-intel: run performance comparison on a GCP Intel chip.
  • make benchmark-amd: run performance comparison on a GCP AMD chip.
  • make benchmark-arm: run performance comparison on an AWS Graviton ARM chip.

The SHISHUA and SHISHUA-half are under the CC0 license.

shishua's People

Contributors

easyaspi314 avatar espadrine avatar gelma avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.