Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions projects/hipblaslt/tensilelite/Tensile/Components/Signature.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,20 +221,19 @@ def __call__(self, writer) -> SignatureBase:
if kernel["ProblemType"]["UseScaleAB"]:
signature.addArg("AddressScaleA", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
signature.addArg("AddressScaleB", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
userArgumentsInfo.scaleASize += 8
userArgumentsInfo.scaleBSize += 8
userArgumentsInfo.scaleASize += 8
userArgumentsInfo.scaleBSize += 8
if kernel["ProblemType"]["UseScaleCD"]:
signature.addArg("AddressScaleC", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
signature.addArg("AddressScaleD", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
userArgumentsInfo.scaleCSize += 8
userArgumentsInfo.scaleDSize += 8
userArgumentsInfo.scaleCSize += 8
userArgumentsInfo.scaleDSize += 8

if kernel["ProblemType"]["UseScaleAlphaVec"]:
signature.addArg("AddressScaleAlphaVec", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
if kernel["ProblemType"]["UseScaleAlphaVec"] == 3:
userArgumentsInfo.factorDimSize =4

userArgumentsInfo.scaleAlphaVecSize += 8
userArgumentsInfo.scaleAlphaVecSize += 8

if writer.states.useBias != DataDirection.NONE:
signature.addArg("bias", SVK.SIG_GLOBALBUFFER, biasValueType, "generic") # Note: We append the data in ws_d
Expand All @@ -243,7 +242,7 @@ def __call__(self, writer) -> SignatureBase:
signature.addArg("StrideBias", SVK.SIG_VALUE, "u32")
if kernel["ProblemType"]["UseBias"] == 3:
userArgumentsInfo.factorDimSize = 4
userArgumentsInfo.biasSize += (8 + 4 + 4)
userArgumentsInfo.biasSize += (8 + 4 + 4)

if userArgumentsInfo.factorDimSize == 4:
signature.addArg("factorDim", SVK.SIG_VALUE, "u32")
Expand All @@ -252,9 +251,9 @@ def __call__(self, writer) -> SignatureBase:
signature.addArg( "E", SVK.SIG_GLOBALBUFFER, cptValueType, "generic")
for i in range(0, writer.states.e.numSgprStrides):
signature.addArg("StrideE%u"%i, SVK.SIG_VALUE, "u32")
userArgumentsInfo.eSize += 8
for i in range(0, writer.states.e.numSgprStrides):
userArgumentsInfo.eSize += 4
userArgumentsInfo.eSize += 8
for i in range(0, writer.states.e.numSgprStrides):
userArgumentsInfo.eSize += 4

if ((kernel["ProblemType"]["ActivationType"] != 'none') and kernel["ActivationFused"]):
if kernel["ProblemType"]["ActivationComputeDataType"].isHalf():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1709,7 +1709,10 @@ namespace TensileLite
or i == ContractionProblemGemm::TENSOR::METADATA)
continue;

if(useMXGenerator && (i == ContractionProblemGemm::TENSOR::A || i == ContractionProblemGemm::TENSOR::B))
if(useMXGenerator && (i == ContractionProblemGemm::TENSOR::A
|| i == ContractionProblemGemm::TENSOR::B
|| i == ContractionProblemGemm::TENSOR::MXSA
|| i == ContractionProblemGemm::TENSOR::MXSB))
continue;

if(m_problemDependentData)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -809,8 +809,7 @@ namespace TensileLite

// NOTE: an assumption here is A & B must be both MX data types or non-MX data types.
// Mixing is not supported.
if(!problemType.useScaleAB.empty() or
(problemType.mxBlockA != 0 && problemType.mxBlockB != 0)) //kernel input data
if(!problemType.useScaleAB.empty())
{
args.template append<void const*>("scaleA", inputs.scaleA);
args.template append<void const*>("scaleB", inputs.scaleB);
Expand Down
Loading