Skip to content

Commit

Permalink
Code checks
Browse files Browse the repository at this point in the history
  • Loading branch information
AdrianoDee committed Feb 27, 2023
1 parent 1cbb29c commit 013581a
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,11 @@ class TrackingRecHitSoADevice : public cms::cuda::PortableDeviceCollection<Track
cms::cuda::host::unique_ptr<float[]> localCoordToHostAsync(cudaStream_t stream) const {
auto ret = cms::cuda::make_host_unique<float[]>(4 * nHits(), stream);
size_t rowSize = sizeof(float) * nHits();

size_t srcPitch = ptrdiff_t(view().yLocal()) - ptrdiff_t(view().xLocal());
cudaCheck(cudaMemcpy2DAsync(ret.get(), rowSize, view().xLocal(), srcPitch, rowSize, 4, cudaMemcpyDeviceToHost, stream));

cudaCheck(
cudaMemcpy2DAsync(ret.get(), rowSize, view().xLocal(), srcPitch, rowSize, 4, cudaMemcpyDeviceToHost, stream));

return ret;
} //move to utilities

Expand Down

0 comments on commit 013581a

Please sign in to comment.