Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion onnxruntime/core/framework/plugin_data_transfer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Status DataTransfer::CopyTensors(const std::vector<SrcDstPair>& src_dst_pairs) c
for (size_t i = 0; i < src_dst_pairs.size(); ++i) {
src_values.push_back(&values[i * 2]);
dst_values.push_back(&values[i * 2 + 1]);
streams.push_back(nullptr); // static_cast<OrtSyncStream*>(src_dst_pairs[i].src_stream));
streams.push_back(reinterpret_cast<OrtSyncStream*>(src_dst_pairs[i].src_stream));
}

auto* status = impl_.CopyTensors(&impl_, src_values.data(), dst_values.data(), streams.data(),
Expand Down
6 changes: 3 additions & 3 deletions onnxruntime/core/providers/cuda/cuda_provider_factory.cc
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ struct CudaSyncNotificationImpl : OrtSyncNotificationImpl {
Release = ReleaseImpl;
}

cudaStream_t& stream_;
cudaStream_t stream_;
cudaEvent_t event_;

const OrtApi& ort_api;
Expand Down Expand Up @@ -632,9 +632,9 @@ struct CudaSyncStreamImpl : OrtSyncStreamImpl {
*notification_impl = nullptr;

std::unique_ptr<CudaSyncNotificationImpl> notification;
cudaStream_t* cuda_stream = static_cast<cudaStream_t*>(impl.stream_.GetHandle());
cudaStream_t cuda_stream = static_cast<cudaStream_t>(impl.stream_.GetHandle());

RETURN_IF_ERROR(CudaSyncNotificationImpl::Create(*cuda_stream, impl.ort_api, notification));
RETURN_IF_ERROR(CudaSyncNotificationImpl::Create(cuda_stream, impl.ort_api, notification));
*notification_impl = notification.release();

return nullptr;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ struct NvTrtRtxSyncNotificationImpl : OrtSyncNotificationImpl {
Release = ReleaseImpl;
}

cudaStream_t& stream_;
cudaStream_t stream_;
cudaEvent_t event_;

const OrtApi& ort_api;
Expand Down Expand Up @@ -477,9 +477,9 @@ struct NvTrtRtxSyncStreamImpl : OrtSyncStreamImpl {
*notification_impl = nullptr;

std::unique_ptr<NvTrtRtxSyncNotificationImpl> notification;
cudaStream_t* cuda_stream = static_cast<cudaStream_t*>(impl.stream_.GetHandle());
cudaStream_t cuda_stream = static_cast<cudaStream_t>(impl.stream_.GetHandle());

RETURN_IF_ERROR(NvTrtRtxSyncNotificationImpl::Create(*cuda_stream, impl.ort_api, notification));
RETURN_IF_ERROR(NvTrtRtxSyncNotificationImpl::Create(cuda_stream, impl.ort_api, notification));
*notification_impl = notification.release();

return nullptr;
Expand Down
Loading