Test is_sorted_until with thrust::device in __device__ code.