This commit is contained in:
rcxpony 2025-03-15 19:54:15 +05:00
parent e6c4f9ceb5
commit 4f5a8129ae

View File

@ -59,10 +59,12 @@ __device__ __forceinline__ unsigned char getZeros(const unsigned char* v) noexce
}
return leadZeros;
}
__global__ void initRandSeed(curandState* states, unsigned long seed) {
/*
__global__ void initRandSeed(curandState* states, const unsigned long seed) {
int idx = blockIdx.x * blockDim.x + threadIdx.x;
curand_init(seed, idx, 0, &states[idx]);
}
*/
__global__ void initRand(curandState* rs) {
int id = blockIdx.x * blockDim.x + threadIdx.x;
curand_init(clock64() + id * 7919ULL, id, 0, &rs[id]);