Вопрос

I want to check the free memory on the device while executing a CUDA kernel. cuMemGetInfo(&free, &total) is a host (CPU) based command which gives free memory on the Device.

But is there any way to check free memory inside a CUDA kernel code during execution ?

Это было полезно?

Решение

Use profiler - The NVIDIA Visual Profiler is a cross-platform performance profiling tool that delivers developers vital feedback for optimizing CUDA C/C++ applications.

First introduced in 2008, Visual Profiler supports all 350 million+ CUDA capable NVIDIA GPUs shipped since 2006 on Linux, Mac OS X, and Windows.

The NVIDIA Visual Profiler is available as part of the CUDA Toolkit.

See User's Guide Here

enter image description here

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top