Skip to content

Commit

Permalink
Revert veccopy change.
Browse files Browse the repository at this point in the history
Revert due to perf regression.
  • Loading branch information
jgu222 authored and igcbot committed Jun 26, 2023
1 parent 61f7144 commit f1777b5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
7 changes: 5 additions & 2 deletions IGC/Compiler/CISACodeGen/EmitVISAPass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18352,17 +18352,20 @@ void EmitPass::emitUniformVectorCopy(CVariable* Dst, CVariable* Src, uint32_t nE
return true;
};

// True, allow simd32/simd16; otherwise, no simd32/simd16.
const bool allowLargerSIMDSize = false;

// Start with the max execution size that is legal for the vector element
// and is no greater than the current simdsize.
uint32_t maxNumElts = (2 * getGRFSize()) / Dst->GetElemSize();
uint32_t maxSimd = std::min(width, (uint32_t)PowerOf2Floor(maxNumElts));
if (maxSimd == 32 && IGC_IS_FLAG_ENABLED(EnableTestVecCopy)) {
if (maxSimd == 32 && allowLargerSIMDSize) {
while (partialCopy(SIMDMode::SIMD32))
;
partialCopy(SIMDMode::SIMD16);
partialCopy(SIMDMode::SIMD8);
}
else if (maxSimd == 16 && IGC_IS_FLAG_ENABLED(EnableTestVecCopy)) {
else if (maxSimd == 16 && allowLargerSIMDSize) {
while (partialCopy(SIMDMode::SIMD16))
;
partialCopy(SIMDMode::SIMD8);
Expand Down
1 change: 0 additions & 1 deletion IGC/common/igc_flags.h
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,6 @@ DECLARE_IGC_REGKEY(bool, PrintDebugSettings, false, "Prints all non-d
DECLARE_IGC_REGKEY(bool, UseMTInLLD, false, "Use multi-threading when linking multiple elf files", true)
DECLARE_IGC_REGKEY(bool, NoCatchAllDebugLine, false, "Don't emit special placeholder instruction to map VISA orphan instructions", false)
DECLARE_IGC_REGKEY(bool, EnableTestSplitI64, false, "Test legalization that split i64 store unnecessarily, to be deleted once test is done[temp]", true)
DECLARE_IGC_REGKEY(bool, EnableTestVecCopy, true, "Test uniform vector copy that starts from simd32, to be deleted once test is done[temp]", true)
DECLARE_IGC_REGKEY(bool, ShaderDumpTranslationOnly, false, "Dump LLVM IR right after translation from SPIRV to stderr and ignore all passes", false)
DECLARE_IGC_REGKEY(bool, UseVMaskPredicate, false, "Use VMask as predicate for subspan usage", false)
DECLARE_IGC_REGKEY(DWORD, VMaskPredDebug, 2, "Debug only; 0 - No VMaskPred; 1 - createVMaskPred; 2 - createVMaskPred and UseVMaskPred", false)
Expand Down

0 comments on commit f1777b5

Please sign in to comment.