[all-commits] [llvm/llvm-project] 565a07: [flang][cuda][rt] Track asynchronous allocation st...
Valentin Clement (バレンタイン クレメン) via All-commits
all-commits at lists.llvm.org
Thu Apr 24 10:02:08 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 565a075909046f74c2fbb7713419518464599a4e
https://github.com/llvm/llvm-project/commit/565a075909046f74c2fbb7713419518464599a4e
Author: Valentin Clement (バレンタイン クレメン) <clementval at gmail.com>
Date: 2025-04-24 (Thu, 24 Apr 2025)
Changed paths:
M flang-rt/lib/cuda/allocator.cpp
M flang-rt/unittests/Runtime/CUDA/Allocatable.cpp
Log Message:
-----------
[flang][cuda][rt] Track asynchronous allocation stream for deallocation (#137073)
When an asynchronous allocation is made, we call `cudaMallocAsync` with
a stream. For deallocation, we need to call `cudaFreeAsync` with the
same stream. in order to achieve that, we need to track the allocation
and their respective stream.
This patch adds a simple sorted array of asynchronous allocations. A
binary search is performed to retrieve the allocation when deallocation
is needed.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list