device_delete#

template<typename T>
inline void thrust::device_delete(
thrust::device_ptr<T> ptr,
const size_t n = 1,
)#

device_delete deletes a device_ptr allocated with device_new.

See also

device_ptr

See also

device_new

Parameters:
  • ptr – The device_ptr to delete, assumed to have been allocated with device_new.

  • n – The number of objects to destroy at ptr. Defaults to 1 similar to device_new.