MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / state_write

Function state_write

src/backend/cuda/kernel/random_engine_mersenne.hpp:71–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71static inline __device__ void state_write(uint *const gState,
72 const uint *const state) {
73 uint *const g = gState + (blockIdx.x * N);
74 g[threadIdx.x] = state[STATE_SIZE - N + threadIdx.x];
75 if (threadIdx.x < N - blockDim.x) {
76 g[blockDim.x + threadIdx.x] =
77 state[STATE_SIZE - N + blockDim.x + threadIdx.x];
78 }
79}
80
81static inline __device__ uint recursion(const uint *const recursion_table,
82 const uint mask, const uint sh1,

Callers 2

uniformMersenneFunction · 0.70
normalMersenneFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected