I implemented an algorithm which used sorting. I tried Thrust::sort_by_key that took around 0.4s to sort an array with 10^7 elements.
I thought bitonic sorting network should be faster than Thrust::sort_by_key. However, bitonic sorting took about 2.5s to sort the same array mentioned above. I used the bitonic sorting network provided by SDK. I just modified the original bitonic sort a little bit.
Could you tell me why? or give me some advice?
Thanks,
Yik
Aug, 15, 2011