Utility class for timing execution of a kernel.
More...
#include <Timer.h>
Utility class for timing execution of a kernel.
Definition at line 20 of file Timer.h.
faiss::gpu::KernelTimer::KernelTimer |
( |
cudaStream_t |
stream = 0 | ) |
|
Constructor starts the timer and adds an event into the current device stream
Definition at line 18 of file Timer.cpp.
float faiss::gpu::KernelTimer::elapsedMilliseconds |
( |
| ) |
|
Adds a stop event then synchronizes on the stop event to get the actual GPU-side kernel timings for any kernels launched in the current stream. Returns the number of milliseconds elapsed. Can only be called once.
Definition at line 35 of file Timer.cpp.
The documentation for this class was generated from the following files: