Top Description Fields Constructors Methods
org.lwjgl.vulkan

public Class KHRCooperativeMatrix

extends Object
Class Inheritance
Imports
javax.annotation.*, java.nio.*, org.lwjgl.system.*

This extension adds support for using cooperative matrix types in SPIR-V. Cooperative matrix types are medium-sized matrices that are primarily supported in compute shaders, where the storage for the matrix is spread across all invocations in some scope (usually a subgroup) and those invocations cooperate to efficiently perform matrix multiplies.

Cooperative matrix types are defined by the SPV_KHR_cooperative_matrix SPIR-V extension and can be used with the GL_KHR_cooperative_matrix GLSL extension.

This extension includes support for enumerating the matrix types and dimensions that are supported by the implementation.

VK_KHR_cooperative_matrix
Name String
VK_KHR_cooperative_matrix
Extension Type
Device extension
Registered Extension Number
507
Revision
2
Extension and Version Dependencies
VK_KHR_get_physical_device_properties2
Contact
Other Extension Metadata
Last Modified Date
2023-05-03
Interactions and External Dependencies
Contributors
  • Jeff Bolz, NVIDIA
  • Markus Tavenrath, NVIDIA
  • Daniel Koch, NVIDIA
  • Kevin Petit, Arm Ltd.
  • Boris Zanin, AMD

Field Summary

Modifier and TypeField and Description
public static final int
VK_COMPONENT_TYPE_FLOAT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_FLOAT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_FLOAT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_SINT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_SINT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_SINT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_SINT8_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_UINT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_UINT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_UINT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final int
VK_COMPONENT_TYPE_UINT8_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type Description

public static final String
public static final int
VK_KHR_COOPERATIVE_MATRIX_SPEC_VERSION

The extension specification version.

public static final int
VK_SCOPE_DEVICE_KHR

VkScopeKHR - Specify SPIR-V scope Description

public static final int
VK_SCOPE_QUEUE_FAMILY_KHR

VkScopeKHR - Specify SPIR-V scope Description

public static final int
VK_SCOPE_SUBGROUP_KHR

VkScopeKHR - Specify SPIR-V scope Description

public static final int
VK_SCOPE_WORKGROUP_KHR

VkScopeKHR - Specify SPIR-V scope Description

public static final int
public static final int
public static final int

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static int
nvkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(VkPhysicalDevice physicalDevice, long
a pointer to an integer related to the number of cooperative matrix properties available or queried.
pPropertyCount
,
long pProperties)

Unsafe version of: GetPhysicalDeviceCooperativeMatrixPropertiesKHR

public static int
vkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(VkPhysicalDevice
the physical device.
physicalDevice
,
IntBuffer
a pointer to an integer related to the number of cooperative matrix properties available or queried.
pPropertyCount
,
VkCooperativeMatrixPropertiesKHR.Buffer
either NULL or a pointer to an array of VkCooperativeMatrixPropertiesKHR structures.
pProperties
)

Returns properties describing what cooperative matrix types are supported.

public static int
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

VK_COMPONENT_TYPE_FLOAT16_KHRback to summary
public static final int VK_COMPONENT_TYPE_FLOAT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_FLOAT32_KHRback to summary
public static final int VK_COMPONENT_TYPE_FLOAT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_FLOAT64_KHRback to summary
public static final int VK_COMPONENT_TYPE_FLOAT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_SINT16_KHRback to summary
public static final int VK_COMPONENT_TYPE_SINT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_SINT32_KHRback to summary
public static final int VK_COMPONENT_TYPE_SINT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_SINT64_KHRback to summary
public static final int VK_COMPONENT_TYPE_SINT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_SINT8_KHRback to summary
public static final int VK_COMPONENT_TYPE_SINT8_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_UINT16_KHRback to summary
public static final int VK_COMPONENT_TYPE_UINT16_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_UINT32_KHRback to summary
public static final int VK_COMPONENT_TYPE_UINT32_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_UINT64_KHRback to summary
public static final int VK_COMPONENT_TYPE_UINT64_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_COMPONENT_TYPE_UINT8_KHRback to summary
public static final int VK_COMPONENT_TYPE_UINT8_KHR

VkComponentTypeKHR - Specify SPIR-V cooperative matrix component type

Description
See Also

VkCooperativeMatrixPropertiesKHR

VK_KHR_COOPERATIVE_MATRIX_EXTENSION_NAMEback to summary
public static final String VK_KHR_COOPERATIVE_MATRIX_EXTENSION_NAME

The extension name.

VK_KHR_COOPERATIVE_MATRIX_SPEC_VERSIONback to summary
public static final int VK_KHR_COOPERATIVE_MATRIX_SPEC_VERSION

The extension specification version.

VK_SCOPE_DEVICE_KHRback to summary
public static final int VK_SCOPE_DEVICE_KHR

VkScopeKHR - Specify SPIR-V scope

Description

All enum values match the corresponding SPIR-V value.

See Also

VkCooperativeMatrixPropertiesKHR

VK_SCOPE_QUEUE_FAMILY_KHRback to summary
public static final int VK_SCOPE_QUEUE_FAMILY_KHR

VkScopeKHR - Specify SPIR-V scope

Description

All enum values match the corresponding SPIR-V value.

See Also

VkCooperativeMatrixPropertiesKHR

VK_SCOPE_SUBGROUP_KHRback to summary
public static final int VK_SCOPE_SUBGROUP_KHR

VkScopeKHR - Specify SPIR-V scope

Description

All enum values match the corresponding SPIR-V value.

See Also

VkCooperativeMatrixPropertiesKHR

VK_SCOPE_WORKGROUP_KHRback to summary
public static final int VK_SCOPE_WORKGROUP_KHR

VkScopeKHR - Specify SPIR-V scope

Description

All enum values match the corresponding SPIR-V value.

See Also

VkCooperativeMatrixPropertiesKHR

VK_STRUCTURE_TYPE_COOPERATIVE_MATRIX_PROPERTIES_KHRback to summary
public static final int VK_STRUCTURE_TYPE_COOPERATIVE_MATRIX_PROPERTIES_KHR

Extends VkStructureType.

Enum values:
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_FEATURES_KHRback to summary
public static final int VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_FEATURES_KHR

Extends VkStructureType.

Enum values:
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_PROPERTIES_KHRback to summary
public static final int VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_PROPERTIES_KHR

Extends VkStructureType.

Enum values:

Constructor Detail

KHRCooperativeMatrixback to summary
protected KHRCooperativeMatrix()

Method Detail

nvkGetPhysicalDeviceCooperativeMatrixPropertiesKHRback to summary
public static int nvkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(VkPhysicalDevice physicalDevice, long pPropertyCount, long pProperties)

Unsafe version of: GetPhysicalDeviceCooperativeMatrixPropertiesKHR

Parameters
pPropertyCount:long

a pointer to an integer related to the number of cooperative matrix properties available or queried.

vkGetPhysicalDeviceCooperativeMatrixPropertiesKHRback to summary
public static int vkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(VkPhysicalDevice physicalDevice, IntBuffer pPropertyCount, VkCooperativeMatrixPropertiesKHR.Buffer pProperties)

Returns properties describing what cooperative matrix types are supported.

C Specification

To enumerate the supported cooperative matrix types and operations, call:


VkResult vkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(
    VkPhysicalDevice                            physicalDevice,
    uint32_t*                                   pPropertyCount,
    VkCooperativeMatrixPropertiesKHR*           pProperties);
Description

If pProperties is NULL, then the number of cooperative matrix properties available is returned in pPropertyCount. Otherwise, pPropertyCount must point to a variable set by the user to the number of elements in the pProperties array, and on return the variable is overwritten with the number of structures actually written to pProperties. If pPropertyCount is less than the number of cooperative matrix properties available, at most pPropertyCount structures will be written, and INCOMPLETE will be returned instead of SUCCESS, to indicate that not all the available cooperative matrix properties were returned.

Valid Usage (Implicit)
  • physicalDevice must be a valid VkPhysicalDevice handle
  • pPropertyCount must be a valid pointer to a uint32_t value
  • If the value referenced by pPropertyCount is not 0, and pProperties is not NULL, pProperties must be a valid pointer to an array of pPropertyCount VkCooperativeMatrixPropertiesKHR structures
Return Codes
On success, this command returns
On failure, this command returns
See Also

VkCooperativeMatrixPropertiesKHR

Parameters
physicalDevice:VkPhysicalDevice

the physical device.

pPropertyCount:IntBuffer

a pointer to an integer related to the number of cooperative matrix properties available or queried.

pProperties:VkCooperativeMatrixPropertiesKHR.Buffer

either NULL or a pointer to an array of VkCooperativeMatrixPropertiesKHR structures.

Annotations
@NativeType:VkResult
vkGetPhysicalDeviceCooperativeMatrixPropertiesKHRback to summary
public static int vkGetPhysicalDeviceCooperativeMatrixPropertiesKHR(VkPhysicalDevice physicalDevice, int[] pPropertyCount, VkCooperativeMatrixPropertiesKHR.Buffer pProperties)

Array version of: GetPhysicalDeviceCooperativeMatrixPropertiesKHR

Annotations
@NativeType:VkResult