Yeah, you’re right. I was looking at the documentation http://thrust.googlecode.com/svn/tags/1.2…p__extrema.html which uses an int * directly and so obviously returns an int *. But even then I was wrong, because subtracting the two pointers directly will you give the correct offset, you’ll only get the offset in bytes if you cast the pointers to size_t first.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
CUDA reduction | 10 | 51427 | June 7, 2009 | |
Finding max in array | 15 | 42248 | November 26, 2017 | |
GTX460 Max of 1 Block? | 8 | 7171 | July 3, 2011 | |
problem with array offset | 28 | 3228 | February 3, 2011 | |
Efficient use of shared memory | 29 | 4509 | December 2, 2019 | |
How to use all 16KB shared memory | 39 | 19314 | April 1, 2010 | |
Memory problem? ...incredible slowdown | 29 | 16307 | January 30, 2011 | |
Urgent help with threads please! | 21 | 10787 | March 6, 2008 | |
Fiding an elegant solution for an On^4 problem | 43 | 25684 | June 1, 2011 | |
limit of computation | 44 | 32905 | April 8, 2008 |