From c7ab463b43a2dc82a6c36c2891ce90143fc24d0b Mon Sep 17 00:00:00 2001 From: Bram Veenboer Date: Tue, 12 Aug 2025 17:02:51 +0200 Subject: [PATCH] Bugfix gpu output data copy --- src/gpu.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gpu.cpp b/src/gpu.cpp index b1a4175..b6be96f 100644 --- a/src/gpu.cpp +++ b/src/gpu.cpp @@ -66,6 +66,8 @@ struct GPUBackend::Impl { launch_sincosf_kernel(d_x, d_s, d_c, n); cudaMemcpy(h_s, d_s, bytes, cudaMemcpyDeviceToHost); cudaMemcpy(h_c, d_c, bytes, cudaMemcpyDeviceToHost); + std::memcpy(s, h_s, bytes); + std::memcpy(c, h_c, bytes); } float *h_x = nullptr;