Discussion:
[1099] Error creating CUDPPPlan after changing data structure
Jilang Miao
2014-07-31 20:36:22 UTC
Permalink
Hi,

My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf;
ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea;
rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating
CUDPPPlan".

Even in this case, "Error creating CUDPPPlan" doesn't come out every time.
Sometimes the program runs normally, sometimes it gives the error. And if I
make dimBlock and dimGrid very small, the error still occurs.

Any idea?

Thanks!
Jilang
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
John Owens
2014-07-31 20:44:50 UTC
Permalink
What CUDPP primitive are you actually running?

JDO
Post by Jilang Miao
Hi,
My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf; ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea; rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating CUDPPPlan".
Even in this case, "Error creating CUDPPPlan" doesn't come out every time. Sometimes the program runs normally, sometimes it gives the error. And if I make dimBlock and dimGrid very small, the error still occurs.
Any idea?
Thanks!
Jilang
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
Jilang Miao
2014-07-31 20:53:54 UTC
Permalink
Radix sort
Post by John Owens
What CUDPP primitive are you actually running?
JDO
Post by Jilang Miao
Hi,
My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf;
ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea;
rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating
CUDPPPlan".
Post by Jilang Miao
Even in this case, "Error creating CUDPPPlan" doesn't come out every
time. Sometimes the program runs normally, sometimes it gives the error.
And if I make dimBlock and dimGrid very small, the error still occurs.
Post by Jilang Miao
Any idea?
Thanks!
Jilang
--
You received this message because you are subscribed to the Google
Groups "CUDPP" group.
Post by Jilang Miao
To unsubscribe from this group and stop receiving emails from it, send
<javascript:>.
Post by Jilang Miao
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
John Owens
2014-07-31 20:58:09 UTC
Permalink
We don't support sorts of arbitrary datatypes. CUDPP currently just calls thrust sort anyway; you might just want to call it directly (I think it supports a wider range of datatypes than CUDPP allows).

JDO
Post by Jilang Miao
Radix sort
What CUDPP primitive are you actually running?
JDO
Post by Jilang Miao
Hi,
My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf; ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea; rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating CUDPPPlan".
Even in this case, "Error creating CUDPPPlan" doesn't come out every time. Sometimes the program runs normally, sometimes it gives the error. And if I make dimBlock and dimGrid very small, the error still occurs.
Any idea?
Thanks!
Jilang
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
Jilang Miao
2014-07-31 21:15:22 UTC
Permalink
CUDPPHandle theCudpp;
cudppCreate(&theCudpp);
CUDPPConfiguration config;
config.datatype = CUDPP_DOUBLE;

config.algorithm = CUDPP_SORT_RADIX;


CUDPPHandle sortplan = 0;
CUDPPResult res = cudppPlan(theCudpp, &sortplan, config, gridsize, 1, 0
);


if (CUDPP_SUCCESS != res)
{
printf("Error creating CUDPPPlan\n");
exit(-1);
}


res = cudppRadixSort(sortplan, DeviceMem.nInfo.energy, DeviceMem.nInfo.
id, gridsize);
//double keys
//unsigned int values
if (CUDPP_SUCCESS != res)
{
printf("Error in cudppSort()\n");
exit(-1);
}


res = cudppDestroyPlan(sortplan);
if (CUDPP_SUCCESS != res)
{
printf("Error destroying CUDPPPlan\n");
exit(-1);
}
cudppDestroy(theCudpp);

I sort double keys, that are supported by CUDPP2.1.
My problem is for the same program accepting same input cudppsort() runs
sometimes normally sometimes fails at cudppPlan().
I'm asking for your ideas what could happen in cudppPlan() that causes the
error.

Thanks!
We don’t support sorts of arbitrary datatypes. CUDPP currently just calls
thrust sort anyway; you might just want to call it directly (I think it
supports a wider range of datatypes than CUDPP allows).
JDO
Post by Jilang Miao
Radix sort
What CUDPP primitive are you actually running?
JDO
Post by Jilang Miao
Hi,
My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf;
ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea;
rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating
CUDPPPlan".
Post by Jilang Miao
Post by Jilang Miao
Even in this case, "Error creating CUDPPPlan" doesn't come out every
time. Sometimes the program runs normally, sometimes it gives the error.
And if I make dimBlock and dimGrid very small, the error still occurs.
Post by Jilang Miao
Post by Jilang Miao
Any idea?
Thanks!
Jilang
--
You received this message because you are subscribed to the Google
Groups "CUDPP" group.
Post by Jilang Miao
Post by Jilang Miao
To unsubscribe from this group and stop receiving emails from it, send
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google
Groups "CUDPP" group.
Post by Jilang Miao
To unsubscribe from this group and stop receiving emails from it, send
<javascript:>.
Post by Jilang Miao
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
John Owens
2014-07-31 21:22:32 UTC
Permalink
It would help a lot if you could get a stack trace of where it's having the error ...

Alternatively, if you could add a test (say, a radix sort of doubles of the size that's calling the error) to the tests in app/cudpp_testrig/test_radixsort.cpp, that would be equally helpful.

JDO
Post by Jilang Miao
CUDPPHandle theCudpp;
cudppCreate(&theCudpp);
CUDPPConfiguration config;
config.datatype = CUDPP_DOUBLE;
config.algorithm = CUDPP_SORT_RADIX;
CUDPPHandle sortplan = 0;
CUDPPResult res = cudppPlan(theCudpp, &sortplan, config, gridsize, 1, 0);
if (CUDPP_SUCCESS != res)
{
printf("Error creating CUDPPPlan\n");
exit(-1);
}
res = cudppRadixSort(sortplan, DeviceMem.nInfo.energy, DeviceMem.nInfo.id, gridsize);
//double keys //unsigned int values
if (CUDPP_SUCCESS != res)
{
printf("Error in cudppSort()\n");
exit(-1);
}
res = cudppDestroyPlan(sortplan);
if (CUDPP_SUCCESS != res)
{
printf("Error destroying CUDPPPlan\n");
exit(-1);
}
cudppDestroy(theCudpp);
I sort double keys, that are supported by CUDPP2.1.
My problem is for the same program accepting same input cudppsort() runs sometimes normally sometimes fails at cudppPlan().
I'm asking for your ideas what could happen in cudppPlan() that causes the error.
Thanks!
We don't support sorts of arbitrary datatypes. CUDPP currently just calls thrust sort anyway; you might just want to call it directly (I think it supports a wider range of datatypes than CUDPP allows).
JDO
Post by Jilang Miao
Radix sort
What CUDPP primitive are you actually running?
JDO
Post by Jilang Miao
Hi,
My program could run normally and correctly.
But after I change an array from array of structure (ea,rt,ra,rf; ea,rt,ra,rf; ea,rt,ra,rf; .....) to structure of array (ea,ea,......ea; rt,rt,....rt; ra,ra,ra,...ra; rf,rf,rf....rf), I got error "Error creating CUDPPPlan".
Even in this case, "Error creating CUDPPPlan" doesn't come out every time. Sometimes the program runs normally, sometimes it gives the error. And if I make dimBlock and dimGrid very small, the error still occurs.
Any idea?
Thanks!
Jilang
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "CUDPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cudpp+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/cudpp.
For more options, visit https://groups.google.com/d/optout.
Loading...