Skip to content

Commit e1ecf7b

Browse files
krystian-andrzejewskiigcbot
authored andcommitted
Remove redundant conditions for merging uniform loads in ConstantCoalescing
This change is to remove redundant conditions for merging uniform loads in ConstantCoalescing.
1 parent 9758af9 commit e1ecf7b

File tree

1 file changed

+9
-15
lines changed

1 file changed

+9
-15
lines changed

IGC/Compiler/CISACodeGen/ConstantCoalescing.cpp

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -401,9 +401,6 @@ void ConstantCoalescing::ProcessBlock(
401401
std::vector<BufChunk*> & indcb_owloads,
402402
std::vector<BufChunk*> & indcb_gathers)
403403
{
404-
bool isCPS = false;
405-
406-
bool skipLdrawOpt = isCPS;
407404
// get work-item analysis, need to update uniformness information
408405
for (BasicBlock::iterator BBI = blk->begin(), BBE = blk->end();
409406
BBI != BBE; ++BBI)
@@ -450,18 +447,15 @@ void ConstantCoalescing::ProcessBlock(
450447
uint addrSpace = ldRaw->getResourceValue()->getType()->getPointerAddressSpace();
451448
if (wiAns->isUniform(ldRaw))
452449
{
453-
if (!skipLdrawOpt || (bufType != BINDLESS))
454-
{
455-
MergeUniformLoad(
456-
ldRaw,
457-
ldRaw->getResourceValue(),
458-
addrSpace,
459-
baseOffsetInBytes,
460-
offsetInBytes,
461-
maxEltPlus,
462-
Extension,
463-
baseOffsetInBytes ? indcb_owloads : dircb_owloads);
464-
}
450+
MergeUniformLoad(
451+
ldRaw,
452+
ldRaw->getResourceValue(),
453+
addrSpace,
454+
baseOffsetInBytes,
455+
offsetInBytes,
456+
maxEltPlus,
457+
Extension,
458+
baseOffsetInBytes ? indcb_owloads : dircb_owloads);
465459
}
466460
else if (bufType == BINDLESS_CONSTANT_BUFFER
467461
|| bufType == SSH_BINDLESS_CONSTANT_BUFFER

0 commit comments

Comments
 (0)