GPUs are no longer used only for rendering images and processing graphics. Modern GPUs also perform machine learning inference, image processing, neural rendering, and other workloads that involve large numbers of mathematical operations.
Matrix multiplication is one of the most important operations in these workloads. It is used in neural networks, image transformations, scientific computing, and many real-time graphics techniques.
Traditionally, developers implemented matrix calculations in HLSL using vectors, arrays, shared memory, and manually optimized compute shaders. Although these approaches work, getting the best performance from specialized matrix hardware often requires hardware-specific techniques.
Shader Model 6.10 introduces LinAlg Matrix, a new HLSL API that provides a common programming interface for hardware-accelerated matrix operations across supported GPU vendors.
With DirectX Agility SDK 1.621 and DXC 1.10.2611, released in December 2026, LinAlg Matrix is generally available for production development.
This article explains how HLSL matrix operations work, what Shader Model 6.10 introduces, how to perform matrix multiplication in a compute shader, and how developers can use the new API for machine learning and graphics workloads.
What Is Shader Model 6.10?
Shader Model defines the programming capabilities available to HLSL shaders. It determines which language features, instructions, and GPU operations developers can use when compiling shaders.
Shader Model 6.10 introduces several improvements to HLSL and Direct3D 12.
The most important addition for matrix-based GPU computing is LinAlg Matrix.
Other features include:
Linear algebra operations through the new Matrix API.
DebugBreak support for shader debugging.
Group wave index information.
Variable groupshared memory limits.
Additional ray tracing intrinsics.
Improved support for workloads that require larger shared-memory allocations.
These features are available through the DirectX Agility SDK 1.621 release and its accompanying DirectX Shader Compiler.
Why Matrix Operations Matter
Many graphics and machine learning workloads repeatedly perform matrix multiplication.
For example, a neural network layer may calculate:
[
Y = W \times X + B
]
Where:
A neural network may execute this operation across several layers, with thousands or millions of mathematical operations.
GPUs are particularly suitable for this type of parallel processing because they can execute many operations simultaneously.
Modern graphics hardware also includes specialized matrix-processing units. These units can perform matrix operations more efficiently than executing every multiplication and addition as an independent shader instruction.
Shader Model 6.10 provides a common HLSL interface for accessing these capabilities.
Understanding LinAlg Matrix in HLSL
LinAlg Matrix is a linear algebra API introduced with Shader Model 6.10.
It provides a Matrix type and a collection of operations for working with matrices and vectors.
The API is available through the HLSL header:
#include <dx/linalg.h>
The main namespace is:
using namespace dx::linalg;
The Matrix type is defined using several template parameters.
A simplified declaration looks like this:
using MatrixType = Matrix<
ComponentType::F16,
16,
16,
MatrixUse::A,
MatrixScope::Wave
>;
Each parameter controls an important part of the matrix.
Parameter | Meaning |
|---|
ComponentType | Data type used by matrix elements |
First dimension | Number of matrix rows |
Second dimension | Number of matrix columns |
MatrixUse | How the matrix participates in an operation |
MatrixScope | Execution scope in which the matrix is used |
For example, the declaration above represents a 16-by-16 matrix using 16-bit floating-point values. It is an input matrix of type A and uses wave-level execution.
This type information helps the compiler validate which operations are allowed.
Understanding Component Types
LinAlg Matrix supports multiple component formats.
Some important types include:
Component type | Description |
|---|
F16 | 16-bit floating-point |
F32 | 32-bit floating-point |
F64 | 64-bit floating-point |
BFloat16 | Brain floating-point 16-bit format |
I8 | 8-bit signed integer |
U8 | 8-bit unsigned integer |
I16 | 16-bit signed integer |
U16 | 16-bit unsigned integer |
I32 | 32-bit signed integer |
U32 | 32-bit unsigned integer |
F8_E4M3FN | 8-bit floating-point format |
F8_E5M2 | 8-bit floating-point format |
The available formats and operations depend on the matrix scope and hardware support.
For example, 16-bit floating-point inputs with 32-bit accumulation can be useful for neural network calculations. Smaller input formats can reduce memory requirements and improve throughput, but developers must consider numerical accuracy.
Understanding the Three Matrix Scopes
One of the important design decisions in LinAlg Matrix is selecting the correct MatrixScope.
Shader Model 6.10 provides three scopes:
Each scope is designed for a different type of matrix workload.
Thread Scope
Thread-scope matrices operate within an individual shader thread.
They are useful when a shader thread needs to perform matrix-vector operations as part of its own processing.
For example, a graphics shader may execute a small neural network to calculate lighting for a surface.
A thread-scope matrix can perform the required matrix-vector multiplication without requiring the developer to organize the operation manually across an entire wave.
Consider this example:
#include <dx/linalg.h>
using namespace dx::linalg;
ByteAddressBuffer InputBuffer : register(t0);
[numthreads(8, 1, 1)]
void main()
{
using MatrixType = Matrix<
ComponentType::F16,
16,
16,
MatrixUse::A,
MatrixScope::Thread
>;
vector<float16_t, 16> input =
(vector<float16_t, 16>)0;
vector<float16_t, 16> bias =
(vector<float16_t, 16>)0;
MatrixType weights = MatrixType::Load(
InputBuffer,
0,
16 * sizeof(float16_t),
MatrixLayout::RowMajor
);
vector<float16_t, 16> output =
MultiplyAdd<float16_t>(
weights,
input,
bias
);
}
The shader loads a 16-by-16 matrix from a byte-address buffer and performs a matrix-vector multiplication with an additional bias vector.
The result is a 16-element vector.
This is a useful pattern for small neural network calculations that are performed independently by shader threads.
The example initializes the input and bias vectors to zero to demonstrate the API. A real application would load meaningful values from buffers or calculate them earlier in the shader.
Wave Scope
Wave-scope matrices are designed for matrix-matrix operations that use wave-level parallelism.
A GPU wave is a group of shader threads that execute together. The exact wave width depends on the hardware and execution environment.
Wave scope exposes specialized matrix operations that can map to dedicated GPU matrix hardware.
It is useful for:
Neural network matrix multiplication.
Image processing.
Machine learning inference.
Matrix multiplication with large datasets.
GPU workloads that use tiled matrix operations.
A wave-scope matrix can be used with operations such as Multiply and MultiplyAccumulate.
Developers can organize a larger matrix into smaller tiles. Each wave processes a tile of the output matrix.
This approach provides more control over how work is distributed.
ThreadGroup Scope
ThreadGroup scope operates at the thread-group level.
It is designed for larger matrix operations where manually dividing the data into hardware-specific tiles can become difficult.
For example, an application may need to multiply two large matrices containing thousands of rows and columns.
With wave scope, developers generally need to divide the matrices into smaller tiles themselves.
ThreadGroup scope allows the driver to handle the internal tiling based on the hardware.
This can make the shader implementation easier to maintain across different GPU architectures.
Matrix scope | Main purpose | Typical workload |
|---|
Thread | Matrix-vector operations within an individual thread | Neural rendering and small inference workloads |
Wave | Matrix-matrix operations using wave-level parallelism | Tiled matrix multiplication and image processing |
ThreadGroup | Larger matrix operations across a thread group | Large machine learning and matrix workloads |
The right scope depends on the size of the matrices, the type of operation, and how the application distributes work across GPU threads.
Performing Matrix Multiplication With HLSL
Matrix multiplication is one of the most common operations in GPU computing.
Suppose we have two matrices:
[
A_{M \times K}
]
and
[
B_{K \times N}
]
Their multiplication produces:
[
C_{M \times N} = A \times B
]
The number of columns in matrix A must match the number of rows in matrix B.
For example, multiplying a 16-by-16 matrix by another 16-by-16 matrix produces a 16-by-16 result.
LinAlg Matrix provides the Multiply operation for supported matrix scopes.
Creating Matrix Types
For a wave-level multiplication, define the input and output matrix types:
using MatrixATy = Matrix<
ComponentType::F16,
16,
16,
MatrixUse::A,
MatrixScope::Wave
>;
using MatrixBTy = Matrix<
ComponentType::F16,
16,
16,
MatrixUse::B,
MatrixScope::Wave
>;
using MatrixResultTy = Matrix<
ComponentType::F32,
16,
16,
MatrixUse::Accumulator,
MatrixScope::Wave
>;
The A and B matrices use 16-bit floating-point values.
The accumulator uses 32-bit floating-point values.
Using a wider accumulator can improve numerical accuracy compared with accumulating every result in the lower-precision input format.
Loading Matrix Data
LinAlg Matrix supports loading matrices from byte-address buffers and groupshared memory.
For example:
MatrixATy matrixA = MatrixATy::Load(
MatrixABuffer,
0,
16 * sizeof(float16_t),
MatrixLayout::RowMajor
);
The arguments identify:
The buffer containing the matrix.
The starting byte offset.
The row stride in bytes.
The matrix memory layout.
The row stride is important because it describes how far apart consecutive rows are in memory.
Do not assume that the physical storage layout is always identical to the logical matrix layout.
For high-performance workloads, matrix layout can affect how efficiently the GPU loads and processes data.
Multiplying Matrices
Once the input matrices are loaded, the Multiply operation can calculate their product.
MatrixResultTy result =
Multiply<ComponentType::F32>(
matrixA,
matrixB
);
The result is an accumulator matrix containing the multiplication output.
The output type is specified explicitly so that the calculation can use the desired result format.
For a larger workload, the matrices can be divided into smaller tiles and processed through multiple operations.
Building a Matrix Multiplication Compute Shader
Let's look at a more complete example using wave-scope matrix multiplication.
The objective is to calculate:
[
C = \alpha(A \times B) + \beta C
]
This is a common general matrix multiplication operation, also known as GEMM.
Assume that A, B, and C are 1024-by-1024 matrices.
The shader divides the output into 16-by-16 tiles. Each thread group processes one output tile, with one wave responsible for that tile.
#include <dx/linalg.h>
using namespace dx::linalg;
ByteAddressBuffer MatrixA : register(t0);
ByteAddressBuffer MatrixB : register(t1);
RWByteAddressBuffer MatrixC : register(u0);
cbuffer GemmConstants : register(b0)
{
float Alpha;
float Beta;
}
#define M 1024
#define N 1024
#define K 1024
#define TILE_SIZE 16
[numthreads(32, 1, 1)]
void main(uint3 groupId : SV_GroupID)
{
using MatrixATy = Matrix<
ComponentType::F16,
TILE_SIZE,
TILE_SIZE,
MatrixUse::A,
MatrixScope::Wave
>;
using MatrixBTy = Matrix<
ComponentType::F16,
TILE_SIZE,
TILE_SIZE,
MatrixUse::B,
MatrixScope::Wave
>;
using MatrixResultTy = Matrix<
ComponentType::F32,
TILE_SIZE,
TILE_SIZE,
MatrixUse::Accumulator,
MatrixScope::Wave
>;
uint tileRow = groupId.y;
uint tileCol = groupId.x;
MatrixResultTy result =
MatrixResultTy::Splat(0.0f);
for (uint k = 0; k < K; k += TILE_SIZE)
{
uint offsetA =
((tileRow * TILE_SIZE) * K + k)
* sizeof(float16_t);
uint offsetB =
(k * N + tileCol * TILE_SIZE)
* sizeof(float16_t);
MatrixATy aTile = MatrixATy::Load(
MatrixA,
offsetA,
K * sizeof(float16_t),
MatrixLayout::RowMajor
);
MatrixBTy bTile = MatrixBTy::Load(
MatrixB,
offsetB,
N * sizeof(float16_t),
MatrixLayout::RowMajor
);
result.MultiplyAccumulate(
aTile,
bTile
);
}
uint outputOffset =
((tileRow * TILE_SIZE) * N
+ tileCol * TILE_SIZE)
* sizeof(float);
MatrixResultTy existing = MatrixResultTy::Load(
MatrixC,
outputOffset,
N * sizeof(float),
MatrixLayout::RowMajor
);
for (uint i = 0; i < result.Length(); i++)
{
float product = result.Get(i);
float previous = existing.Get(i);
result.Set(
i,
Alpha * product + Beta * previous
);
}
result.Store(
MatrixC,
outputOffset,
N * sizeof(float),
MatrixLayout::RowMajor
);
}
This example demonstrates the main structure of a tiled matrix multiplication shader using the released LinAlg Matrix API.
It is an instructional kernel rather than a complete production GEMM implementation. The example assumes correctly allocated buffers, valid resource bindings, compatible matrix layouts, and a dispatch configuration that covers the complete output matrix.
Understanding the Main Operations
The first part declares the input and output matrix types.
The input matrices use F16, while the accumulator uses F32. This is a mixed-precision approach that can provide a useful balance between data size and numerical accuracy.
The shader then calculates the output tile coordinates using SV_GroupID.
For every position along the shared K dimension, it loads a tile from matrix A and another tile from matrix B.
The MultiplyAccumulate operation performs multiplication and adds the result to the existing accumulator.
After the loop completes, the shader loads the existing output tile and applies the Alpha and Beta scaling factors.
Finally, it stores the updated tile in the output buffer.
Important Dispatch Considerations
For a 1024-by-1024 output matrix with 16-by-16 tiles, the application needs:
[
\frac{1024}{16} \times \frac{1024}{16}
= 64 \times 64
]
Therefore, the compute dispatch must cover 64 tiles in each dimension.
A corresponding dispatch is:
commandList->Dispatch(64, 64, 1);
The shader uses 32 threads per group so that the group can execute one wave on hardware with a 32-lane wave.
Do not assume every GPU uses the same wave width. Validate the execution assumptions against the target hardware and compiler requirements.
Also, the example uses fixed matrix dimensions. Production implementations should handle dimensions that are not evenly divisible by the tile size, using padding, smaller edge tiles, or another suitable strategy.
Understanding Matrix Layouts
Matrix layout determines how matrix elements are arranged in memory.
Two common layouts are row-major and column-major.
Row-Major Layout
In row-major storage, elements from the same row are stored next to each other.
For example, a 3-by-3 matrix:
[
\begin{bmatrix}
1 & 2 & 3 \
4 & 5 & 6 \
7 & 8 & 9
\end{bmatrix}
]
is stored as:
1, 2, 3, 4, 5, 6, 7, 8, 9
This layout is common in many application data structures.
Column-Major Layout
In column-major storage, elements from the same column are stored together.
The same matrix is stored as:
1, 4, 7, 2, 5, 8, 3, 6, 9
Using the wrong layout can produce incorrect results or inefficient memory access.
LinAlg Matrix provides layout options including:
The optimal layouts are intended for specific operations and hardware execution paths.
For example, a matrix layout optimized for multiplication may differ from the layout used for an outer-product operation.
Developers should prepare data in the layout expected by the operation rather than repeatedly converting it inside performance-critical shaders.
Using Variable Groupshared Memory With Shader Model 6.10
Another important improvement in Shader Model 6.10 is variable groupshared memory.
Groupshared memory is a fast memory region shared by threads within a thread group.
It is commonly used in compute shaders for:
Earlier shader models imposed fixed groupshared memory limits of 32 KB for compute, node, and amplification shaders, and 28 KB for mesh shaders.
Shader Model 6.10 removes these fixed limits and allows applications to use the hardware's reported capacity.
Developers can declare the required maximum using the GroupSharedLimit attribute.
Conceptually:
[GroupSharedLimit(65536)]
[numthreads(256, 1, 1)]
void main(uint3 groupId : SV_GroupID)
{
// Shared-memory workload
}
This example declares a 64-KiB requirement. It is valid only when the device supports that amount for the relevant shader stage.
The application must query the device's maximum supported groupshared memory and configure its shader accordingly.
The attribute is a declaration of the shader's resource requirement, not a command that increases the hardware's physical memory.
For matrix workloads, larger shared-memory allocations can be useful when multiple data tiles need to remain available during computation.
Using LinAlg Matrix for Machine Learning
One of the main use cases for LinAlg Matrix is machine learning inference inside graphics workloads.
Neural networks repeatedly perform matrix-vector and matrix-matrix operations.
Traditional graphics applications may use separate compute frameworks or external inference systems for these calculations.
LinAlg Matrix allows developers to perform supported matrix operations directly from HLSL.
This creates opportunities for neural rendering techniques.
Neural Radiance Caching
Neural Radiance Caching uses a neural network to estimate lighting information.
Instead of calculating every lighting contribution through traditional rendering operations, a neural network can predict some of the required results.
The network performs matrix calculations using learned weights and input features.
Thread-scope matrix operations can help execute small inference workloads within individual shader threads.
Microsoft has highlighted Neural Radiance Caching as an example of how LinAlg Matrix can bring machine learning calculations directly into the rendering pipeline.
Image Denoising
Real-time rendering can produce noisy images, especially when using ray tracing with limited samples.
A neural network can process image features and estimate a cleaner result.
Matrix operations are part of the network's inference process.
Using dedicated GPU matrix hardware can help reduce the computational cost of these operations, although the overall result also depends on memory movement, model size, and the rendering workload.
Image Upscaling
Image upscaling techniques use information from lower-resolution images to produce higher-resolution output.
Machine learning-based upscalers may perform many matrix operations while reconstructing image details.
LinAlg Matrix provides another way to implement such neural calculations within the DirectX shader pipeline.
The actual quality and performance depend on the model, input data, GPU architecture, and complete rendering implementation.
Hardware Support and Compatibility
Shader Model 6.10 support does not mean that every GPU automatically supports every LinAlg Matrix operation.
The feature requires a compatible DirectX runtime, compiler, driver, and GPU implementation.
The December 2026 Agility SDK 1.621 release provides the retail version of Shader Model 6.10.
The current published LinAlg support includes:
GPU vendor | Published support |
|---|
AMD | Radeon RX 9000 series |
Intel | Arc B-Series Graphics and selected Core Ultra and Core processor families |
NVIDIA | RTX GPUs with the required developer driver |
Qualcomm | Planned in a future driver |
The exact supported hardware and driver requirements can change as vendors release updates.
Developers should check the latest driver information rather than assuming that a GPU supporting Direct3D 12 supports LinAlg Matrix.
Checking Device Support
Direct3D 12 provides a feature query for linear algebra support.
The application can query the device before selecting the LinAlg implementation.
A simplified example is:
D3D12_FEATURE_DATA_LINEAR_ALGEBRA_SUPPORT support = {};
HRESULT hr = device->CheckFeatureSupport(
D3D12_FEATURE_LINEAR_ALGEBRA_SUPPORT,
&support,
sizeof(support)
);
if (SUCCEEDED(hr) &&
support.LinearAlgebraTier >=
D3D12_LINEAR_ALGEBRA_TIER_1)
{
// Use the supported LinAlg implementation.
}
else
{
// Select an alternative compute path.
}
This example checks whether the device reports at least Tier 1 support.
The application should also inspect the relevant capability information for the matrix formats and operations it intends to use. A successful basic support query does not mean every possible matrix configuration is supported.
A fallback compute shader remains useful for systems that do not support the required feature.
Compiling HLSL With Shader Model 6.10
To use LinAlg Matrix, developers need a DirectX Shader Compiler version that supports Shader Model 6.10.
The retail release includes DXC 1.10.2611.
A typical compute shader compilation command looks like this:
dxc.exe `
-T cs_6_10 `
-E main `
-enable-16bit-types `
-I include/hlsl `
matrix-multiply.hlsl `
-Fo matrix-multiply.dxil
The important options are:
Option | Purpose |
|---|
-T cs_6_10 | Targets compute Shader Model 6.10 |
-E main | Selects the shader entry point |
-enable-16bit-types | Enables native 16-bit types used by the example |
-I | Specifies the directory containing HLSL headers |
-Fo | Specifies the output DXIL file |
The include path must point to the DXC HLSL header directory containing dx/linalg.h.
For production development, also make sure that the application uses the appropriate Agility SDK runtime and that the target GPU has a compatible driver.
The shader compiler, runtime, and GPU driver must work together. Updating only the compiler is not enough to guarantee that the feature will execute on the target machine.
Performance Considerations
Using LinAlg Matrix does not automatically make every matrix calculation faster.
Performance depends on how the application organizes the data and uses the supported hardware.
Consider these factors when optimizing a matrix workload.
Choose the Right Matrix Scope
Thread scope is suitable for smaller matrix-vector workloads.
Wave scope provides more direct control over matrix multiplication using wave-level parallelism.
ThreadGroup scope is useful for larger operations where the driver can handle internal tiling.
Selecting an unsuitable scope can increase overhead or limit the operations available to the shader.
Use Appropriate Precision
Lower-precision data formats can reduce memory usage and improve throughput on supported hardware.
However, precision affects numerical accuracy.
For example, using F16 inputs with F32 accumulation can provide a useful compromise for some machine learning workloads.
Always compare the output against an appropriate reference implementation.
Avoid Unnecessary Data Conversion
Matrix layout conversions can add overhead.
Prepare matrix data in a suitable layout during asset or model preparation when possible.
If the same weights are used repeatedly, converting them once and reusing the converted data may be more efficient than converting them for every dispatch.
Consider GPU Memory Usage
Large matrix operations require memory for inputs, outputs, and intermediate results.
The new groupshared memory capabilities can help with larger workloads, but they do not remove the need to manage GPU memory carefully.
Measure memory consumption and make sure the selected configuration is supported by the device.
Benchmark Against Existing Compute Shaders
A traditional HLSL implementation may perform better for small workloads where the overhead of matrix setup is greater than the computation itself.
Compare the new API against your existing implementation using realistic matrix dimensions and data formats.
Measure the complete operation rather than only the multiplication instruction.
LinAlg Matrix Compared With Traditional HLSL Matrix Operations
HLSL already supports matrix types and standard mathematical operations.
For example, developers can declare a matrix and multiply it by a vector:
float4x4 transformMatrix;
float4 position = float4(
1.0f,
2.0f,
3.0f,
1.0f
);
float4 transformed =
mul(transformMatrix, position);
This remains a valid and useful approach for graphics transformations.
LinAlg Matrix addresses a different requirement: accessing specialized matrix hardware through a higher-level API.
Area | Traditional HLSL matrices | LinAlg Matrix |
|---|
Main purpose | General shader mathematics | Hardware-accelerated linear algebra |
Typical operations | Transformations and vector calculations | Matrix-vector and matrix-matrix workloads |
Programming model | Standard HLSL types and operators | Matrix type with scope and usage parameters |
Hardware specialization | Depends on compiler and GPU | Designed to expose dedicated matrix hardware |
Machine learning | Possible through manual shader implementation | Designed for matrix-heavy inference workloads |
Data handling | Standard HLSL resource operations | Matrix-specific loading, storing, and layout support |
Developers should not replace every float4x4 or mul() operation with LinAlg Matrix.
Traditional matrix types remain appropriate for transformations, camera calculations, skeletal animation, and other standard graphics operations.
LinAlg Matrix is most valuable when the workload benefits from specialized matrix-processing hardware.
Common Mistakes When Using Shader Model 6.10
Assuming Every GPU Supports LinAlg Matrix
Shader Model 6.10 introduces the API, but hardware support depends on the GPU and driver.
Always query device capabilities before creating a pipeline that requires LinAlg Matrix.
Using the Wrong Matrix Scope
Different scopes support different operation categories.
For example, a thread-scope matrix is designed for matrix-vector operations, while wave and thread-group scopes support matrix-matrix operations.
Choose the scope according to the workload.
Ignoring Matrix Dimensions
Matrix multiplication requires compatible dimensions.
If A is an M-by-K matrix and B is a K-by-N matrix, the result must be M-by-N.
Incorrect dimensions can cause shader compilation errors or invalid calculations.
Using an Incorrect Memory Layout
A matrix loaded as row-major data must match the actual memory representation.
If the application stores the data in a different layout, the shader may read incorrect values.
Check row stride, offsets, alignment, and layout before debugging the mathematical operation.
Assuming F16 Is Always Accurate Enough
Lower-precision formats can improve performance, but they may introduce numerical errors.
Use an appropriate accumulation type and validate the output against reference calculations.
Ignoring Hardware-Specific Limits
Matrix dimensions, supported component formats, and available operations depend on the device's linear algebra capabilities.
A shader that works on one GPU may not have the same support on another.
Use capability queries and provide alternative implementations where necessary.
Best Practices for Production GPU Development
When using Shader Model 6.10 in a real application, consider these practices:
Use DXC 1.10.2611 or a compatible newer compiler.
Include the released dx/linalg.h header.
Target the correct shader model.
Query device linear algebra support before using the feature.
Select Thread, Wave, or ThreadGroup scope according to the workload.
Choose matrix dimensions and data formats based on supported capabilities.
Keep input and output layouts consistent.
Use mixed precision only after validating numerical accuracy.
Benchmark against existing HLSL compute implementations.
Test on multiple GPU vendors and driver versions.
Provide a fallback path for unsupported hardware.
Use PIX to inspect shader execution and debug supported matrix workloads.
PIX 2612.02 provides initial debugging support for LinAlg. Inspection of LinAlg matrix variables in the Shader Debugger was scheduled for a later PIX update in December 2026, so developers should check the latest PIX release notes for the available debugging features.
Advantages and Limitations of LinAlg Matrix
LinAlg Matrix gives developers a common HLSL interface for hardware-accelerated matrix operations.
Its main advantages include:
Access to specialized GPU matrix hardware.
A common API across supported GPU vendors.
Support for neural rendering and machine learning workloads.
Matrix-vector and matrix-matrix operations.
Multiple execution scopes for different workloads.
Support for several numeric component formats.
Integration with Direct3D 12 compute and graphics pipelines.
There are also limitations.
Hardware and driver support is still evolving across GPU vendors. Not every matrix format or operation is available on every device. Developers must also manage matrix dimensions, memory layouts, precision, and resource usage carefully.
For small calculations, traditional HLSL operations may remain simpler and more efficient.
Summary
Shader Model 6.10 introduces LinAlg Matrix, a new HLSL API for hardware-accelerated linear algebra operations.
With DirectX Agility SDK 1.621 and DXC 1.10.2611, the feature is generally available for production development on supported hardware.
The API provides three matrix scopes: Thread, Wave, and ThreadGroup. These support different workloads, ranging from small matrix-vector calculations to large matrix-matrix operations.
For developers working on machine learning, neural rendering, image processing, and GPU computing, LinAlg Matrix provides a useful way to access specialized matrix hardware through HLSL.
The best results come from selecting the right matrix scope, using appropriate precision, preparing data in suitable layouts, and checking device capabilities before execution.
Traditional HLSL matrix operations remain useful for ordinary graphics calculations. LinAlg Matrix should be introduced where the workload can benefit from specialized matrix processing rather than replacing existing shader code without measurement.
Join the conversation! Your thoughts help the community grow.