Test is_sorted_until with thrust::seq in __device__ code.