Skip to content

Commit 681c917

Browse files
juanrod2gfxbot
authored andcommitted
Found a simple assert in BoolToInt which did not support 8-bit types for destination and in the case fof simd8, there is a scenario where we need this support to ignore upper bits
Change-Id: Idc247baafd09fb8791a9f18accd71111845a6fa7
1 parent 9283af1 commit 681c917

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

IGC/Compiler/CISACodeGen/CISABuilder.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4541,7 +4541,11 @@ void CEncoder::Copy(CVariable* dst, CVariable* src)
45414541
void CEncoder::BoolToInt(CVariable* dst, CVariable* src)
45424542
{
45434543
assert(src->GetType() == ISA_TYPE_BOOL);
4544-
assert((dst->GetType() == ISA_TYPE_UD) || (dst->GetType() == ISA_TYPE_D));
4544+
4545+
VISA_Type dstType = dst->GetType();
4546+
assert((dstType == ISA_TYPE_UD) || (dstType == ISA_TYPE_D) ||
4547+
(dstType == ISA_TYPE_UB) ||(dstType == ISA_TYPE_B) ||
4548+
(dstType == ISA_TYPE_UW) || (dstType == ISA_TYPE_W));
45454549

45464550
// undef value are not copied
45474551
if(!src->IsUndef() || IGC_IS_FLAG_ENABLED(InitializeUndefValueEnable)) {

0 commit comments

Comments
 (0)