3232namespace LinAlg {
3333
3434using hlsl::DXIL::ComponentType;
35+ using hlsl::DXIL::LinalgMatrixLayout;
3536using hlsl::DXIL::MatrixScope;
3637using hlsl::DXIL::MatrixUse;
3738
38- enum class MatrixLayout : uint32_t { RowMajor = 0 , ColumnMajor = 1 };
39-
4039// / Return the byte size of a single element for the given component type.
4140static int elemSize (ComponentType CT) {
4241 switch (CT) {
@@ -187,13 +186,13 @@ struct MatrixParams {
187186 int N;
188187 MatrixUse Use;
189188 MatrixScope Scope;
190- MatrixLayout Layout;
189+ LinalgMatrixLayout Layout;
191190 int NumThreads;
192191 bool Enable16Bit;
193192
194193 int strideBytes () const {
195194 int ES = elemSize (CompType);
196- if (Layout == MatrixLayout ::RowMajor)
195+ if (Layout == LinalgMatrixLayout ::RowMajor)
197196 return N * ES;
198197 return M * ES;
199198 }
@@ -459,7 +458,7 @@ void DxilConf_SM610_LinAlg::LoadStoreRoundtrip_Wave_F32() {
459458 Params.N = 8 ;
460459 Params.Use = MatrixUse::A;
461460 Params.Scope = MatrixScope::Wave;
462- Params.Layout = MatrixLayout ::RowMajor;
461+ Params.Layout = LinalgMatrixLayout ::RowMajor;
463462 Params.NumThreads = 64 ;
464463 Params.Enable16Bit = false ;
465464 runLoadStoreRoundtrip (D3DDevice, DxcSupport, Params, VerboseLogging);
@@ -472,7 +471,7 @@ void DxilConf_SM610_LinAlg::LoadStoreRoundtrip_Wave_I32() {
472471 Params.N = 8 ;
473472 Params.Use = MatrixUse::A;
474473 Params.Scope = MatrixScope::Wave;
475- Params.Layout = MatrixLayout ::RowMajor;
474+ Params.Layout = LinalgMatrixLayout ::RowMajor;
476475 Params.NumThreads = 64 ;
477476 Params.Enable16Bit = false ;
478477 runLoadStoreRoundtrip (D3DDevice, DxcSupport, Params, VerboseLogging);
@@ -563,7 +562,7 @@ void DxilConf_SM610_LinAlg::SplatStore_Wave_F32() {
563562 Params.N = 8 ;
564563 Params.Use = MatrixUse::Accumulator;
565564 Params.Scope = MatrixScope::Wave;
566- Params.Layout = MatrixLayout ::RowMajor;
565+ Params.Layout = LinalgMatrixLayout ::RowMajor;
567566 Params.NumThreads = 64 ;
568567 Params.Enable16Bit = false ;
569568 runSplatStore (D3DDevice, DxcSupport, Params, 42 .0f , VerboseLogging);
@@ -576,7 +575,7 @@ void DxilConf_SM610_LinAlg::SplatStore_Wave_I32() {
576575 Params.N = 8 ;
577576 Params.Use = MatrixUse::Accumulator;
578577 Params.Scope = MatrixScope::Wave;
579- Params.Layout = MatrixLayout ::RowMajor;
578+ Params.Layout = LinalgMatrixLayout ::RowMajor;
580579 Params.NumThreads = 64 ;
581580 Params.Enable16Bit = false ;
582581 runSplatStore (D3DDevice, DxcSupport, Params, 7 .0f , VerboseLogging);
0 commit comments