Random123
Index
Random123.Random123
Random123.R123_USE_AESNI
Random123.AESNI1x
Random123.AESNI4x
Random123.AESNIKey
Random123.ARS1x
Random123.ARS4x
Random123.AbstractR123
Random123.Philox2x
Random123.Philox4x
Random123.R123Generator1x
Random123.R123Generator2x
Random123.R123Generator4x
Random123.Threefry2x
Random123.Threefry4x
Random123.random123_r
Random123.set_counter!
Public
#
Random123.Random123
— Module.
The module for Random123 Family.
Provide 8 RNG types:
#
Random123.R123_USE_AESNI
— Constant.
True when AES-NI library has been compiled.
#
Random123.AESNI1x
— Type.
AESNI1x <: R123Generator1x{UInt128} AESNI1x([seed])
AESNI1x is one kind of AESNI Counter-Based RNGs. It generates one UInt128
number at a time.
seed
is an Integer
which will be automatically converted to UInt128
.
Only available when R123_USE_AESNI
.
#
Random123.AESNI4x
— Type.
AESNI4x <: R123Generator4x{UInt32} AESNI4x([seed])
AESNI4x is one kind of AESNI Counter-Based RNGs. It generates four UInt32
numbers at a time.
seed
is a Tuple
of four Integer
s which will all be automatically converted to UInt32
.
Only available when R123_USE_AESNI
.
#
Random123.ARS1x
— Type.
ARS1x{R} <: R123Generator1x{UInt128} ARS1x([seed, R=7])
ARS1x is one kind of ARS Counter-Based RNGs. It generates one UInt128
number at a time.
seed
is an Integer
which will be automatically converted to UInt128
.
R
denotes to the Rounds which should be at least 1 and no more than 10. With 7 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
Only available when R123_USE_AESNI
.
#
Random123.ARS4x
— Type.
ARS4x{R} <: R123Generator4x{UInt32} ARS4x([seed, R=7])
ARS4x is one kind of ARS Counter-Based RNGs. It generates four UInt32
numbers at a time.
seed
is a Tuple
of four Integer
s which will all be automatically converted to UInt32
.
R
denotes to the Rounds which must be at least 1 and no more than 10. With 7 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
Only available when R123_USE_AESNI
.
#
Random123.Philox2x
— Type.
Philox2x{T, R} <: R123Generator2x{T} Philox2x([seed, R]) Philox2x(T[, seed, R])
Philox2x is one kind of Philox Counter-Based RNGs. It generates two numbers at a time.
T
is UInt32
or UInt64
(default).
seed
is an Integer
which will be automatically converted to T
.
R
denotes to the Rounds which must be at least 1 and no more than 16. With 10 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
#
Random123.Philox4x
— Type.
Philox4x{T, R} <: R123Generator4x{T} Philox4x([seed, R]) Philox4x(T[, seed, R])
Philox4x is one kind of Philox Counter-Based RNGs. It generates four numbers at a time.
T
is UInt32
or UInt64
(default).
seed
is a Tuple
of two Integer
s which will both be automatically converted to T
.
R
denotes to the Rounds which must be at least 1 and no more than 16. With 10 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
#
Random123.Threefry2x
— Type.
Threefry2x{T, R} <: R123Generator2x{T} Threefry2x([seed, R]) Threefry2x(T[, seed, R])
Threefry2x is one kind of Threefry Counter-Based RNGs. It generates two numbers at a time.
T
is UInt32
or UInt64
(default).
seed
is a Tuple
of two Integer
s which will both be automatically converted to T
.
R
denotes to the Rounds which must be at least 1 and no more than 32. With 20 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
#
Random123.Threefry4x
— Type.
Threefry4x{T, R} <: R123Generator4x{T} Threefry4x([seed, R]) Threefry4x(T[, seed, R])
Threefry2x is one kind of Threefry Counter-Based RNGs. It generates four numbers at a time.
T
is UInt32
or UInt64
(default).
seed
is a Tuple
of four Integer
s which will all be automatically converted to T
.
R
denotes to the Rounds which must be at least 1 and no more than 32. With 20 rounds (by default), it has a considerable safety margin over the minimum number of rounds with no known statistical flaws, but still has excellent performance.
#
Random123.set_counter!
— Method.
Set the counter of a Random123 RNG.
Internal
#
Random123.AESNIKey
— Type.
The key for AESNI.
#
Random123.AbstractR123
— Type.
The base abstract type for RNGs in Random123 Family.
#
Random123.R123Generator1x
— Type.
RNG that generates one number at a time.
#
Random123.R123Generator2x
— Type.
RNG that generates two numbers at a time.
#
Random123.R123Generator4x
— Type.
RNG that generates four numbers at a time.
#
Random123.random123_r
— Function.
Do one iteration and return the a tuple of a Random123 RNG object.