Test merge_by_key with thrust::device in __device__ code.