Record Class VeilOpenCL.DeviceInfo

java.lang.Object
java.lang.Record
foundry.veil.api.opencl.VeilOpenCL.DeviceInfo
Record Components:
platform - The platform this device is on
id - The id of this device
capabilities - The capabilities of this device
type - The OpenCL device type
vendorId - A unique device vendor identifier
maxComputeUnits - The number of parallel compute units on the OpenCL device. A work-group executes on a single compute unit. The minimum value is 1
maxWorkItemDimensions - Maximum dimensions that specify the global and local work-item IDs used by the data parallel execution model. (Refer to clEnqueueNDRangeKernel)
maxWorkGroupSize - Maximum number of work-items in a work-group that a device is capable of executing on a single compute unit, for any given kernel-instance running on the device
maxMemAllocSize - Max size of memory object allocation in bytes
maxClockFrequency - Maximum configured clock frequency of the device in MHz
addressBits - The default compute device address space size of the global address space specified as an unsigned integer value in bits. Currently supported values are 32 or 64 bits
available - If this device is able to execute commands sent to it
compilerAvailable - If this device has a compiler available to compile program source
requireManualInteropSync - If this requires the user to manually sync data when using CL/GL interoperability
name - Device name string
vendor - Vendor name string
driverVersion - OpenCL software driver version string. Follows a vendor-specific format
profile - The profile name supported by the device
version - The OpenCL version supported by the device
openclCVersion - OpenCL C version string or null if not supported
Enclosing class:
VeilOpenCL

public static record VeilOpenCL.DeviceInfo(long platform, long id, org.lwjgl.opencl.CLCapabilities capabilities, long type, int vendorId, int maxComputeUnits, int maxWorkItemDimensions, long maxWorkGroupSize, long maxMemAllocSize, int maxClockFrequency, int addressBits, boolean available, boolean compilerAvailable, boolean requireManualInteropSync, String name, String vendor, String driverVersion, String profile, String version, @Nullable String openclCVersion) extends Record
Information about a device on an OpenCL platform.
  • Constructor Details

    • DeviceInfo

      public DeviceInfo(long platform, long id, org.lwjgl.opencl.CLCapabilities capabilities, long type, int vendorId, int maxComputeUnits, int maxWorkItemDimensions, long maxWorkGroupSize, long maxMemAllocSize, int maxClockFrequency, int addressBits, boolean available, boolean compilerAvailable, boolean requireManualInteropSync, String name, String vendor, String driverVersion, String profile, String version, @Nullable @Nullable String openclCVersion)
      Creates an instance of a DeviceInfo record class.
      Parameters:
      platform - the value for the platform record component
      id - the value for the id record component
      capabilities - the value for the capabilities record component
      type - the value for the type record component
      vendorId - the value for the vendorId record component
      maxComputeUnits - the value for the maxComputeUnits record component
      maxWorkItemDimensions - the value for the maxWorkItemDimensions record component
      maxWorkGroupSize - the value for the maxWorkGroupSize record component
      maxMemAllocSize - the value for the maxMemAllocSize record component
      maxClockFrequency - the value for the maxClockFrequency record component
      addressBits - the value for the addressBits record component
      available - the value for the available record component
      compilerAvailable - the value for the compilerAvailable record component
      requireManualInteropSync - the value for the requireManualInteropSync record component
      name - the value for the name record component
      vendor - the value for the vendor record component
      driverVersion - the value for the driverVersion record component
      profile - the value for the profile record component
      version - the value for the version record component
      openclCVersion - the value for the openclCVersion record component
  • Method Details

    • create

      public static VeilOpenCL.DeviceInfo create(long device, org.lwjgl.opencl.CLCapabilities platformCapabilities) throws CLException
      Throws:
      CLException
    • isCpu

      public boolean isCpu()
      An OpenCL device that is the host processor. The host processor runs the OpenCL implementations and is a single or multi-core CPU
    • isGpu

      public boolean isGpu()
      An OpenCL device that is a GPU. By this we mean that the device can also be used to accelerate a 3D API such as OpenGL or DirectX
    • isAccelerator

      public boolean isAccelerator()
      Dedicated OpenCL accelerators (for example the IBM CELL Blade). These devices communicate with the host processor using a peripheral interconnect such as PCIe.
    • isDefault

      public boolean isDefault()
      The default OpenCL device in the system. The default device cannot be a CL_DEVICE_TYPE_CUSTOM device.
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • platform

      public long platform()
      Returns the value of the platform record component.
      Returns:
      the value of the platform record component
    • id

      public long id()
      Returns the value of the id record component.
      Returns:
      the value of the id record component
    • capabilities

      public org.lwjgl.opencl.CLCapabilities capabilities()
      Returns the value of the capabilities record component.
      Returns:
      the value of the capabilities record component
    • type

      public long type()
      Returns the value of the type record component.
      Returns:
      the value of the type record component
    • vendorId

      public int vendorId()
      Returns the value of the vendorId record component.
      Returns:
      the value of the vendorId record component
    • maxComputeUnits

      public int maxComputeUnits()
      Returns the value of the maxComputeUnits record component.
      Returns:
      the value of the maxComputeUnits record component
    • maxWorkItemDimensions

      public int maxWorkItemDimensions()
      Returns the value of the maxWorkItemDimensions record component.
      Returns:
      the value of the maxWorkItemDimensions record component
    • maxWorkGroupSize

      public long maxWorkGroupSize()
      Returns the value of the maxWorkGroupSize record component.
      Returns:
      the value of the maxWorkGroupSize record component
    • maxMemAllocSize

      public long maxMemAllocSize()
      Returns the value of the maxMemAllocSize record component.
      Returns:
      the value of the maxMemAllocSize record component
    • maxClockFrequency

      public int maxClockFrequency()
      Returns the value of the maxClockFrequency record component.
      Returns:
      the value of the maxClockFrequency record component
    • addressBits

      public int addressBits()
      Returns the value of the addressBits record component.
      Returns:
      the value of the addressBits record component
    • available

      public boolean available()
      Returns the value of the available record component.
      Returns:
      the value of the available record component
    • compilerAvailable

      public boolean compilerAvailable()
      Returns the value of the compilerAvailable record component.
      Returns:
      the value of the compilerAvailable record component
    • requireManualInteropSync

      public boolean requireManualInteropSync()
      Returns the value of the requireManualInteropSync record component.
      Returns:
      the value of the requireManualInteropSync record component
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • vendor

      public String vendor()
      Returns the value of the vendor record component.
      Returns:
      the value of the vendor record component
    • driverVersion

      public String driverVersion()
      Returns the value of the driverVersion record component.
      Returns:
      the value of the driverVersion record component
    • profile

      public String profile()
      Returns the value of the profile record component.
      Returns:
      the value of the profile record component
    • version

      public String version()
      Returns the value of the version record component.
      Returns:
      the value of the version record component
    • openclCVersion

      @Nullable public @Nullable String openclCVersion()
      Returns the value of the openclCVersion record component.
      Returns:
      the value of the openclCVersion record component