From ed26cf7a2d88ecd5af18e78095f6f1f46f5978ca Mon Sep 17 00:00:00 2001 From: pca006132 Date: Sun, 7 Jul 2024 20:28:40 +0800 Subject: [PATCH] avoid thrust copy with strided range --- src/collider/src/collider.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/collider/src/collider.cpp b/src/collider/src/collider.cpp index 02c1c35bb..4561cd84e 100644 --- a/src/collider/src/collider.cpp +++ b/src/collider/src/collider.cpp @@ -349,7 +349,8 @@ void Collider::UpdateBoxes(const VecView& leafBB) { // copy in leaf node Boxes auto leaves = StridedRange(nodeBBox_.begin(), nodeBBox_.end(), 2); auto policy = autoPolicy(NumInternal()); - copy(policy, leafBB.cbegin(), leafBB.cend(), leaves.begin()); + // FIXME: use normal copy after we get rid of thrust + std::copy(leafBB.cbegin(), leafBB.cend(), leaves.begin()); // create global counters Vec counter(NumInternal(), 0); // kernel over leaves to save internal Boxes