Skip to content

Commit

Permalink
Intentionally leak static CUDA resources
Browse files Browse the repository at this point in the history
  • Loading branch information
kingcrimsontianyu committed Sep 10, 2024
1 parent 59edda0 commit ccaa81f
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions cpp/include/kvikio/posix_io.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,7 @@ class StreamsByThread {

public:
StreamsByThread() = default;
~StreamsByThread() noexcept
{
for (auto& [_, stream] : _streams) {
try {
CUDA_DRIVER_TRY(cudaAPI::instance().StreamDestroy(stream));
} catch (const CUfileException& e) {
std::cerr << e.what() << std::endl;
}
}
}
~StreamsByThread() = default;

static CUstream get(CUcontext ctx, std::thread::id thd_id)
{
Expand Down

0 comments on commit ccaa81f

Please sign in to comment.