本人 CUDA小白一枚,要是有什么不对,还望各位大佬指点。
本文及后面的几篇将分别从几个方面来大概阐述一下Thrust的一些接口。原来的网址在这里。
2.1 Host Containers
template> class thrust::host_vector; template void thrust::swap( host_vector< T, Alloc > & a, host_vector< T, Alloc > & b );
实现两个数字的交换
3. Containers3.1 Containers
template> class thrust::device_vector; template void thrust::swap( device_vector< T, Alloc > & a, device_vector< T, Alloc > & b );
device端的两元素交换。



