diff --git a/proposals/0029-cooperative-vector.md b/proposals/0029-cooperative-vector.md index 94ce7ded..5bad05c1 100644 --- a/proposals/0029-cooperative-vector.md +++ b/proposals/0029-cooperative-vector.md @@ -84,10 +84,10 @@ this should give a sense of how these new operations can be used. > NOTE: see proposal [0031] for full details on the HLSL API. ```c++ -ByteAddressBuffer inputMatrix0; -ByteAddressBuffer inputMatrix1; -ByteAddressBuffer biasVector0; -ByteAddressBuffer biasVector1; +ByteAddressBuffer inputMatrix0; // note read-only buffer +ByteAddressBuffer inputMatrix1; // note read-only buffer +ByteAddressBuffer biasVector0; // note read-only buffer +ByteAddressBuffer biasVector1; // note read-only buffer void ps_main(args) // args: texture, normal, position { @@ -229,9 +229,11 @@ an unsigned integer. ##### Matrix -The matrix is loaded from a raw-buffer, **matrix resource**, starting at -**matrix offset**. The **matrix interpretation** argument specifies the element -type of the matrix (see [Type Interpretations]), no conversion is performed. +The matrix is loaded from a read-only raw-buffer, **matrix resource**, starting +at **matrix offset**. The **matrix interpretation** argument specifies the +element type of the matrix (see [Type Interpretations]), no conversion is +performed. + The **matrix M dimension** and **matrix K dimension** arguments specify the dimensions of the matrix. The **matrix layout** argument specifies the layout of the matrix (see [Matrix Layouts]). If the **matrix transpose** is non-zero @@ -255,10 +257,10 @@ the matrix load is out of bounds then the entire operation is undefined. ##### Bias Vector -The bias vector is loaded from the raw-buffer, **bias vector resource**, -starting at **bias vector offset**. The **bias vector interpretation** argument -specifies the element type of the bias vector (see [Type Interpretations]), no -conversion is performed. +The bias vector is loaded from the read-only raw-buffer, **bias vector +resource**, starting at **bias vector offset**. The **bias vector +interpretation** argument specifies the element type of the bias vector (see +[Type Interpretations]), no conversion is performed. Only non-packed interpretations are valid for bias vectors. diff --git a/proposals/0031-hlsl-vector-matrix-operations.md b/proposals/0031-hlsl-vector-matrix-operations.md index 630a2693..928def34 100644 --- a/proposals/0031-hlsl-vector-matrix-operations.md +++ b/proposals/0031-hlsl-vector-matrix-operations.md @@ -459,7 +459,10 @@ InterpretedVector MakeInterpretedVector(vector Vec) { ### Function: Mul The `dx::linalg::Mul` function performs a matrix-vector multiplication. The -matrix is stored in memory, while the vector comes from a variable. +matrix is stored in memory, while the vector comes from a variable. The Mul +function expects the memory backing the matrix object to be read-only +(for efficient loads and hardware optimizations) and, therefore, the matrix +must be of MatrixRef type (and not RWMatrixRef type). > TODO: add an example for packed types, and make sure they work correctly @@ -530,7 +533,9 @@ Mul(MatrixRefImpl