Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

sorting in cuda Thrust

Tags:

cuda

thrust

I am trying to use radix sort in the cuda. During research I found that thrust has the sorting feature in it.

which sorting algorithm does thrust library use for sorting?? 
Is it  Radix Sort???
like image 903
Laxmi Kadariya Avatar asked Feb 19 '26 01:02

Laxmi Kadariya


1 Answers

You can find some details here:

http://sbel.wisc.edu/Courses/ME964/Literature/thrustGPUgems2011.pdf http://www.greatlakesconsortium.org/events/manycore/files/TStaff-CUDA_Libraries.pdf

From the second link:

thrust::sort will select right algorithm

  • radix sort for built-in types(int, float, etc.)
  • merge sort where radix sort cannot be used

For an even deeper understanding of the thrust implementation of the sort function you should read this technical paper: http://back40computing.googlecode.com/svn-history/r272/wiki/documents/RadixSortTR.pdf

like image 136
Nicola Pezzotti Avatar answered Feb 20 '26 15:02

Nicola Pezzotti



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!