alpaka
Abstraction Library for Parallel Kernel Acceleration
Loading...
Searching...
No Matches
alpaka::rand Namespace Reference

Namespaces

namespace  distribution
 The random number generator distribution specifics.
 
namespace  engine
 The random number generator engine specifics.
 

Classes

struct  ConceptRand
 
struct  EngineCallHostAccProxy
 
class  MersenneTwister
 The standard library mersenne twister implementation. More...
 
class  Philox4x32x10
 
class  Philox4x32x10Vector
 
class  PhiloxStateless4x32x10Vector
 
class  RandDefault
 
class  RandomDevice
 The standard library rand device implementation. More...
 
class  RandUniformCudaHipRand
 The CUDA/HIP rand implementation. More...
 
class  TinyMersenneTwister
 "Tiny" state mersenne twister implementation More...
 
class  UniformReal
 TEMP: Distributions to be decided on later. The generator should be compatible with STL as of now. More...
 

Typedefs

using RandStdLib = TinyMersenneTwister
 

Functions

ALPAKA_FN_HOST_ACC constexpr auto high32Bits (std::uint64_t const x) -> std::uint32_t
 Get high 32 bits of a 64-bit number.
 
ALPAKA_FN_HOST_ACC constexpr auto low32Bits (std::uint64_t const x) -> std::uint32_t
 Get low 32 bits of a 64-bit number.
 
ALPAKA_FN_HOST_ACC constexpr void multiplyAndSplit64to32 (std::uint64_t const a, std::uint64_t const b, std::uint32_t &resultHigh, std::uint32_t &resultLow)
 

Typedef Documentation

◆ RandStdLib

Definition at line 23 of file RandStdLib.hpp.

Function Documentation

◆ high32Bits()

ALPAKA_FN_HOST_ACC constexpr auto alpaka::rand::high32Bits ( std::uint64_t const  x) -> std::uint32_t
inlineconstexpr

Get high 32 bits of a 64-bit number.

Definition at line 14 of file MultiplyAndSplit64to32.hpp.

◆ low32Bits()

ALPAKA_FN_HOST_ACC constexpr auto alpaka::rand::low32Bits ( std::uint64_t const  x) -> std::uint32_t
inlineconstexpr

Get low 32 bits of a 64-bit number.

Definition at line 20 of file MultiplyAndSplit64to32.hpp.

◆ multiplyAndSplit64to32()

ALPAKA_FN_HOST_ACC constexpr void alpaka::rand::multiplyAndSplit64to32 ( std::uint64_t const  a,
std::uint64_t const  b,
std::uint32_t &  resultHigh,
std::uint32_t &  resultLow 
)
inlineconstexpr

Multiply two 64-bit numbers and split the result into high and low 32 bits, also known as "mulhilo32"

Parameters
afirst 64-bit multiplier
bsecond 64-bit multiplier
resultHighhigh 32 bits of the product a*b
resultLowlow 32 bits of the product a*b

Definition at line 33 of file MultiplyAndSplit64to32.hpp.