Remove unnecessary MOVs

Unnecessary MOVs were removed from ASM.
This commit is contained in:
Bzowski, Adam
2024-09-25 13:16:41 +00:00
committed by igcbot
parent a720c93094
commit 45f7f0067a
3 changed files with 69 additions and 24 deletions

View File

@ -1168,7 +1168,12 @@ void VariableReuseAnalysis::InsertElementAliasing(Function* F)
// =0x2: subvec aliasing for both isolated and non-isolated value)
const auto control = (m_pCtx->getVectorCoalescingControl() & 0x3);
// To avoid increasing GRF pressure, skip if F is too large or not an entry
const int32_t NumBBThreshold = (int)IGC_GET_FLAG_VALUE(VectorAliasBBThreshold);
// We remove the threshold when the code comes from CUTLASS,
// which often generates a large number of basic blocks.
const int32_t NumBBThreshold =
F->getName().str().substr(0, 2) == "_Z" && F->getName().str().find("cutlass") != std::string::npos
? std::numeric_limits<int32_t>::max()
: static_cast<int32_t>(IGC_GET_FLAG_VALUE(VectorAliasBBThreshold));
MetaDataUtils* pMdUtils = getAnalysis<MetaDataUtilsWrapper>().getMetaDataUtils();
if (control == 0 || !isEntryFunc(pMdUtils, F) || getNumBBs(F) > NumBBThreshold) {
return;