Skip to content

Commit 3895c0d

Browse files
jgu222sys_zuul
authored andcommitted
vISA will use dispatch simdsize from attribute instead of figuring
out by scanning all instructions. Change-Id: I341c4ebc92c73d95211efceabcb765a5aaa82e69
1 parent f346eaf commit 3895c0d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

visa/FlowGraph.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6140,6 +6140,15 @@ void G4_Kernel::calculateSimdSize()
61406140
return;
61416141
}
61426142

6143+
// First, get simdsize from attribute (0 : not given)
6144+
simdSize = m_kernelAttrs->getIntKernelAttribute(Attributes::ATTR_SimdSize);
6145+
if (simdSize == 8 || simdSize == 16 || simdSize == 32)
6146+
{ // got it from attribute, done.
6147+
return;
6148+
}
6149+
// If not 0|8|16|32, wrong value from attribute.
6150+
assert(simdSize == 0 && "vISA: wrong value for SimdSize attribute");
6151+
61436152
simdSize = 8;
61446153

61456154
for (auto bb : fg)

0 commit comments

Comments
 (0)