nvidia-aftermath-rs

Crates.ionvidia-aftermath-rs
lib.rsnvidia-aftermath-rs
version0.0.3
sourcesrc
created_at2022-06-18 03:45:32.191882
updated_at2024-07-16 17:52:43.221097
descriptionRust bindings for the Nvidia Aftermath SDK
homepage
repository
max_upload_size
id608309
size12,099,329
Austin Shafer (amshafer)

documentation

README

nvidia-aftermath-rs

Rust bindings for obtaining GPU crashdumps with the Nvidia Aftermath SDK

This rust crate contains bindgen bindings for the Aftermath SDK downloadable from Nvidia's website. To use this crate, you'll simply create an Aftermath instance. This instance enables aftermath in the current program, and disables it when dropped.

// Calls GFSDK_Aftermath_EnableGpuCrashDumps
let aftermath = Aftermath::initialize();

...
if (error_from_vulkan_code == VK_ERROR_DEVICE_LOST) {
  // Calls GFSDK_Aftermath_GetCrashDumpStatus
  aftermath.wait_for_dump();
  // exit here, or handle the error...
}

// GFSDK_Aftermath_DisableGpuCrashDumps is called when aftermath is dropped

Please refer to the aftermath SDK's readme for more. This crate does not provide the API initialization bits of enabling aftermath. You need to use something like VkDeviceDiagnosticsConfigFlagBitsNV to tell Vulkan to enable event interest.

Installation

Add this crate to your Cargo.toml, and place the libGFSDK_Aftermath_Lib.x64.so from the aftermath download somewhere in your system path.

Commit count: 0

cargo fmt