DPCT1105#

Message#

The mcg59 random number generator is used. The subsequence argument <expression> is ignored. You need to verify the migration.

Detailed Help#

The mcg59 random number generator does not support the subsequence parameter. If you want to use the subsequence parameter, you can use the philox4x32x10 random number generator instead.

Suggestions to Fix#

For example, this original CUDA* code:

1__global__ void kernel() {
2  unsigned int u;
3  curandStateXORWOW_t rng1;
4  curand_init(1, 2, 3, &rng1);
5  u = curand(&rng1);
6}

results in the following migrated SYCL code:

 1void kernel() {
 2  /*
 3  DPCT1032:0: A different random number generator is used. You may need to adjust the code.
 4  */
 5  dpct::rng::device::rng_generator<oneapi::mkl::rng::device::mcg59<1>> rng1;
 6  /*
 7  DPCT1105:1: The mcg59 random number generator is used. The subsequence argument "2" is ignored. You need to verify the    migration.
 8  */
 9  rng1 = dpct::rng::device::rng_generator<oneapi::mkl::rng::device::mcg59<1>>(1, 3);
10  u = rng1.generate<oneapi::mkl::rng::device::uniform_bits<std::uint32_t>, 1>();
11}

which is rewritten to:

1void kernel() {
2  dpct::rng::device::rng_generator<oneapi::mkl::rng::device::mcg59<1>> rng1;
3  rng1 = dpct::rng::device::rng_generator<oneapi::mkl::rng::device::mcg59<1>>(1, 3);
4  u = rng1.generate<oneapi::mkl::rng::device::uniform_bits<std::uint32_t>, 1>();
5}