Mila
Deep Neural Network Library
Loading...
Searching...
No Matches
Mila::Dnn::Compute::VulkanDevice Class Referenceexport

Class representing a Vulkan compute device instance. More...

Inheritance diagram for Mila::Dnn::Compute::VulkanDevice:

Public Member Functions

 VulkanDevice (int device_index)
 Constructs a VulkanDevice with specified device index.
constexpr int getDeviceId () const override
 Gets the Vulkan device index.
size_t getDeviceMemorySize () const noexcept
 Returns an approximate available device memory in bytes.
std::string getDeviceName () const override
 Gets the name of this Vulkan device.
constexpr DeviceType getDeviceType () const override
 Gets the type of this compute device.
size_t getMaxWorkGroupSize () const noexcept
 Returns an approximate maximum workgroup size.
void * getNativeHandle () const noexcept
 Returns an opaque native handle placeholder.
bool isDiscreteGpu () const noexcept
 Queries whether device is likely discrete.

Detailed Description

Class representing a Vulkan compute device instance.

This class is a minimal, type-safe representation of a Vulkan device that can be used by higher-level device registration and execution context code before full Vulkan runtime integration is implemented.

Constructor & Destructor Documentation

◆ VulkanDevice()

Mila::Dnn::Compute::VulkanDevice::VulkanDevice ( int device_index)
inlineexplicit

Constructs a VulkanDevice with specified device index.

Parameters
device_indexThe Vulkan device index to initialize (0-based).
Exceptions
std::invalid_argumentIf device_index is negative.

Member Function Documentation

◆ getDeviceId()

int Mila::Dnn::Compute::VulkanDevice::getDeviceId ( ) const
inlineconstexproverride

Gets the Vulkan device index.

Returns
int The device index for this Vulkan device (0-based).

◆ getDeviceMemorySize()

size_t Mila::Dnn::Compute::VulkanDevice::getDeviceMemorySize ( ) const
inlinenoexcept

Returns an approximate available device memory in bytes.

Placeholder: returns 0 until integrated with Vulkan memory queries.

◆ getDeviceName()

std::string Mila::Dnn::Compute::VulkanDevice::getDeviceName ( ) const
inlineoverride

Gets the name of this Vulkan device.

Returns
std::string The device name (e.g., "Vulkan:0").

◆ getDeviceType()

DeviceType Mila::Dnn::Compute::VulkanDevice::getDeviceType ( ) const
inlineconstexproverride

Gets the type of this compute device.

Returns
DeviceType The device type (Vulkan).

◆ getMaxWorkGroupSize()

size_t Mila::Dnn::Compute::VulkanDevice::getMaxWorkGroupSize ( ) const
inlinenoexcept

Returns an approximate maximum workgroup size.

Placeholder value; real value should come from physical device limits.

◆ getNativeHandle()

void * Mila::Dnn::Compute::VulkanDevice::getNativeHandle ( ) const
inlinenoexcept

Returns an opaque native handle placeholder.

In a full implementation this would return a pointer to the underlying VkPhysicalDevice or a small wrapper. Returns nullptr until Vulkan integration is added.

◆ isDiscreteGpu()

bool Mila::Dnn::Compute::VulkanDevice::isDiscreteGpu ( ) const
inlinenoexcept

Queries whether device is likely discrete.

Placeholder: returns false until real discovery is implemented.


The documentation for this class was generated from the following file: