Skip to content

Commit e976e7b

Browse files
authored
Fix native RNG window calculation. (#1575)
1 parent aacfc36 commit e976e7b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/random.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ function Random.rand!(rng::RNG, A::AnyCuArray)
4545

4646
# grid-stride loop
4747
threadId = threadIdx().x
48-
window = (blockDim().x - 1i32) * gridDim().x
48+
window = blockDim().x * gridDim().x
4949
offset = (blockIdx().x - 1i32) * blockDim().x
5050
while offset < length(A)
5151
i = threadId + offset

0 commit comments

Comments
 (0)