Function flamegpu::util::cleanup

Function Documentation

void flamegpu::util::cleanup()

Method to cleanup / finalise use of FLAMEGPU. For CUDA implementations, this resets all CUDA devices in the current system, to ensure that CUDA tools such as cuda-memcheck, compute-sanitizer and Nsight Compute.

This method should ideally be called as the final method prior to an exit or the return of the main method, as it is costly and can invalidate device memory allocations, potentially breaking application state.