Correct typo

Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
Kamil Kopryk
2022-07-14 01:12:22 +00:00
committed by Compute-Runtime-Automation
parent 0866f235c7
commit 7c538b956a
15 changed files with 28 additions and 28 deletions

View File

@@ -1457,7 +1457,7 @@ cl_int Kernel::setArgBuffer(uint32_t argIndex,
auto allocationForCacheFlush = graphicsAllocation;
//if we make object uncacheable for surface state and there are not stateless accessess , then ther is no need to flush caches
// if we make object uncacheable for surface state and there are only stateful accesses, then don't flush caches
if (buffer->isMemObjUncacheableForSurfaceState() && argAsPtr.isPureStateful()) {
allocationForCacheFlush = nullptr;
}

View File

@@ -86,12 +86,12 @@ std::string Program::getInternalOptions() const {
CompilerOptions::concatenateAppend(internalOptions, CompilerOptions::bindlessMode);
}
auto enableStatelessToStatefullWithOffset = HwHelper::get(pClDevice->getHardwareInfo().platform.eRenderCoreFamily).isStatelesToStatefullWithOffsetSupported();
auto enableStatelessToStatefulWithOffset = HwHelper::get(pClDevice->getHardwareInfo().platform.eRenderCoreFamily).isStatelessToStatefulWithOffsetSupported();
if (DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.get() != -1) {
enableStatelessToStatefullWithOffset = DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.get() != 0;
enableStatelessToStatefulWithOffset = DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.get() != 0;
}
if (enableStatelessToStatefullWithOffset) {
if (enableStatelessToStatefulWithOffset) {
CompilerOptions::concatenateAppend(internalOptions, CompilerOptions::hasBufferOffsetArg);
}

View File

@@ -207,7 +207,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, clMemLocallyUncachedResourceFixture, givenBuffersTha
EXPECT_EQ(mocsCacheable, cmdQueueMocs<FamilyType>(pCmdQ));
}
HWCMDTEST_F(IGFX_GEN8_CORE, clMemLocallyUncachedResourceFixture, givenBuffersThatAreUncachedButKernelDoesntHaveAnyStatelessAccessessThenSurfacesAreNotRecordedAsUncacheable) {
HWCMDTEST_F(IGFX_GEN8_CORE, clMemLocallyUncachedResourceFixture, givenBuffersThatAreUncachedButKernelDoesntHaveAnyStatelessAccessesThenSurfacesAreNotRecordedAsUncacheable) {
cl_int retVal = CL_SUCCESS;
MockKernelWithInternals mockKernel(*this->pClDevice, context, true);

View File

@@ -117,7 +117,7 @@ struct CommandQueueStateful : public CommandQueueHw<FamilyType> {
auto kernel = dispatchInfo.begin()->getKernel();
EXPECT_FALSE(kernel->getKernelInfo().kernelDescriptor.kernelAttributes.supportsBuffersBiggerThan4Gb());
if (HwHelperHw<FamilyType>::get().isStatelesToStatefullWithOffsetSupported()) {
if (HwHelperHw<FamilyType>::get().isStatelessToStatefulWithOffsetSupported()) {
EXPECT_TRUE(kernel->allBufferArgsStateful);
}
}

View File

@@ -562,9 +562,9 @@ HWTEST_F(EnqueueFillBufferStatelessTest, givenBuffersWhenFillingBufferStatelessT
ASSERT_EQ(CL_SUCCESS, retVal);
}
using EnqueueFillBufferStatefullTest = EnqueueFillBufferHw;
using EnqueueFillBufferStatefulTest = EnqueueFillBufferHw;
HWTEST_F(EnqueueFillBufferStatefullTest, givenBuffersWhenFillingBufferStatefullThenSuccessIsReturned) {
HWTEST_F(EnqueueFillBufferStatefulTest, givenBuffersWhenFillingBufferStatefulThenSuccessIsReturned) {
auto pCmdQ = std::make_unique<CommandQueueStateful<FamilyType>>(context.get(), device.get());
dstBuffer.size = static_cast<size_t>(smallSize);
auto retVal = pCmdQ->enqueueFillBuffer(

View File

@@ -19,7 +19,7 @@ namespace NEO {
using MockOfflineCompilerSklTests = ::testing::Test;
SKLTEST_F(MockOfflineCompilerSklTests, GivenSklWhenParseDebugSettingsThenStatelessToStatefullOptimizationIsEnabled) {
SKLTEST_F(MockOfflineCompilerSklTests, GivenSklWhenParseDebugSettingsThenStatelessToStatefulOptimizationIsEnabled) {
MockOfflineCompiler mockOfflineCompiler;
mockOfflineCompiler.deviceName = "skl";
mockOfflineCompiler.initHardwareInfo(mockOfflineCompiler.deviceName);
@@ -29,13 +29,13 @@ SKLTEST_F(MockOfflineCompilerSklTests, GivenSklWhenParseDebugSettingsThenStatele
EXPECT_NE(std::string::npos, found);
}
SKLTEST_F(MockOfflineCompilerSklTests, GivenSklAndDisabledViaDebugThenStatelessToStatefullOptimizationDisabled) {
SKLTEST_F(MockOfflineCompilerSklTests, GivenSklAndDisabledViaDebugThenStatelessToStatefulOptimizationDisabled) {
DebugManagerStateRestore stateRestore;
MockOfflineCompiler mockOfflineCompiler;
mockOfflineCompiler.deviceName = "skl";
DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.set(0);
mockOfflineCompiler.initHardwareInfo(mockOfflineCompiler.deviceName);
mockOfflineCompiler.setStatelessToStatefullBufferOffsetFlag();
mockOfflineCompiler.setStatelessToStatefulBufferOffsetFlag();
std::string internalOptions = mockOfflineCompiler.internalOptions;
size_t found = internalOptions.find(NEO::CompilerOptions::hasBufferOffsetArg.data());
EXPECT_EQ(std::string::npos, found);

View File

@@ -53,7 +53,7 @@ class MockOfflineCompiler : public OfflineCompiler {
using OfflineCompiler::parseCommandLine;
using OfflineCompiler::parseDebugSettings;
using OfflineCompiler::revisionId;
using OfflineCompiler::setStatelessToStatefullBufferOffsetFlag;
using OfflineCompiler::setStatelessToStatefulBufferOffsetFlag;
using OfflineCompiler::sourceCode;
using OfflineCompiler::storeBinary;
using OfflineCompiler::updateBuildLog;

View File

@@ -1966,7 +1966,7 @@ TEST(OfflineCompilerTest, GivenUnsupportedDeviceConfigWhenInitHardwareInfoThenIn
EXPECT_STREQ(output.c_str(), resString.str().c_str());
}
TEST(OfflineCompilerTest, givenStatelessToStatefullOptimizationEnabledWhenDebugSettingsAreParsedThenOptimizationStringIsPresent) {
TEST(OfflineCompilerTest, givenStatelessToStatefulOptimizationEnabledWhenDebugSettingsAreParsedThenOptimizationStringIsPresent) {
DebugManagerStateRestore stateRestore;
MockOfflineCompiler mockOfflineCompiler;
DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.set(1);
@@ -3161,13 +3161,13 @@ TEST(OclocCompile, givenFormatFlagWithUnknownFormatPassedThenPrintWarning) {
EXPECT_EQ(expectedOutput, output);
}
TEST(OfflineCompilerTest, GivenDebugFlagWhenSetStatelessToStatefullBufferOffsetFlagThenStatelessToStatefullOptimizationIsSetCorrectly) {
TEST(OfflineCompilerTest, GivenDebugFlagWhenSetStatelessToStatefulBufferOffsetFlagThenStatelessToStatefullOptimizationIsSetCorrectly) {
DebugManagerStateRestore stateRestore;
MockOfflineCompiler mockOfflineCompiler;
{
DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.set(0);
mockOfflineCompiler.initHardwareInfo(gEnvironment->devicePrefix.c_str());
mockOfflineCompiler.setStatelessToStatefullBufferOffsetFlag();
mockOfflineCompiler.setStatelessToStatefulBufferOffsetFlag();
std::string internalOptions = mockOfflineCompiler.internalOptions;
size_t found = internalOptions.find(NEO::CompilerOptions::hasBufferOffsetArg.data());
EXPECT_EQ(std::string::npos, found);
@@ -3175,7 +3175,7 @@ TEST(OfflineCompilerTest, GivenDebugFlagWhenSetStatelessToStatefullBufferOffsetF
{
DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.set(1);
mockOfflineCompiler.initHardwareInfo(gEnvironment->devicePrefix.c_str());
mockOfflineCompiler.setStatelessToStatefullBufferOffsetFlag();
mockOfflineCompiler.setStatelessToStatefulBufferOffsetFlag();
std::string internalOptions = mockOfflineCompiler.internalOptions;
size_t found = internalOptions.find(NEO::CompilerOptions::hasBufferOffsetArg.data());
EXPECT_NE(std::string::npos, found);

View File

@@ -1951,7 +1951,7 @@ TEST_F(ProgramTests, GivenStatelessToStatefulBufferOffsetOptimizationWhenProgram
EXPECT_TRUE(CompilerOptions::contains(internalOptions, CompilerOptions::hasBufferOffsetArg)) << internalOptions;
}
TEST_F(ProgramTests, givenStatelessToStatefullOptimizationOffWHenProgramIsCreatedThenOptimizationStringIsNotPresent) {
TEST_F(ProgramTests, givenStatelessToStatefulOptimizationOffWHenProgramIsCreatedThenOptimizationStringIsNotPresent) {
DebugManagerStateRestore dbgRestorer;
DebugManager.flags.EnableStatelessToStatefulBufferOffsetOpt.set(0);
cl_int errorCode = CL_SUCCESS;
@@ -2318,7 +2318,7 @@ HWTEST_F(ProgramTests, givenNewProgramThenStatelessToStatefulBufferOffsetOptimiz
MockProgram program(pContext, false, toClDeviceVector(*pClDevice));
auto internalOptions = program.getInternalOptions();
if (HwHelperHw<FamilyType>::get().isStatelesToStatefullWithOffsetSupported()) {
if (HwHelperHw<FamilyType>::get().isStatelessToStatefulWithOffsetSupported()) {
EXPECT_TRUE(CompilerOptions::contains(internalOptions, CompilerOptions::hasBufferOffsetArg));
} else {
EXPECT_FALSE(CompilerOptions::contains(internalOptions, CompilerOptions::hasBufferOffsetArg));

View File

@@ -42,7 +42,7 @@ HWTEST_EXCLUDE_PRODUCT(EnqueueReadBufferRectStatefulTest, WhenReadingBufferRectS
HWTEST_EXCLUDE_PRODUCT(EnqueueCopyBufferRectStateful, GivenValidParametersWhenCopyingBufferRectStatefulThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueSvmMemCopyHwTest, givenEnqueueSVMMemCopyWhenUsingCopyBufferToBufferStatefulBuilderThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueSvmMemFillHwTest, givenEnqueueSVMMemFillWhenUsingCopyBufferToBufferStatefulBuilderThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueFillBufferStatefullTest, givenBuffersWhenFillingBufferStatefullThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueFillBufferStatefulTest, givenBuffersWhenFillingBufferStatefulThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueCopyBufferStatefulTest, givenBuffersWhenCopyingBufferStatefulThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueWriteBufferStatefulTest, WhenWritingBufferStatefulThenSuccessIsReturned, IGFX_XE_HPC_CORE);
HWTEST_EXCLUDE_PRODUCT(EnqueueReadBufferStatefulTest, WhenReadingBufferStatefulThenSuccessIsReturned, IGFX_XE_HPC_CORE);

View File

@@ -756,7 +756,7 @@ void OfflineCompiler::unifyExcludeIrFlags() {
}
}
void OfflineCompiler::setStatelessToStatefullBufferOffsetFlag() {
void OfflineCompiler::setStatelessToStatefulBufferOffsetFlag() {
bool isStatelessToStatefulBufferOffsetSupported = true;
if (!deviceName.empty()) {
const auto &compilerHwInfoConfig = *CompilerHwInfoConfig::get(hwInfo.platform.eProductFamily);
@@ -782,7 +782,7 @@ void OfflineCompiler::appendExtraInternalOptions(std::string &internalOptions) {
}
void OfflineCompiler::parseDebugSettings() {
setStatelessToStatefullBufferOffsetFlag();
setStatelessToStatefulBufferOffsetFlag();
}
std::string OfflineCompiler::parseBinAsCharArray(uint8_t *binary, size_t size, std::string &fileName) {

View File

@@ -105,7 +105,7 @@ All supported acronyms: %s.
std::string getStringWithinDelimiters(const std::string &src);
int initialize(size_t numArgs, const std::vector<std::string> &allArgs, bool dumpFiles);
int parseCommandLine(size_t numArgs, const std::vector<std::string> &allArgs);
void setStatelessToStatefullBufferOffsetFlag();
void setStatelessToStatefulBufferOffsetFlag();
void appendExtraInternalOptions(std::string &internalOptions);
void parseDebugSettings();
void storeBinary(char *&pDst, size_t &dstSize, const void *pSrc, const size_t srcSize);

View File

@@ -54,7 +54,7 @@ uint64_t HwHelperHw<Family>::getMaxMemAllocSize() const {
}
template <>
bool HwHelperHw<Family>::isStatelesToStatefullWithOffsetSupported() const {
bool HwHelperHw<Family>::isStatelessToStatefulWithOffsetSupported() const {
return false;
}

View File

@@ -149,7 +149,7 @@ class HwHelper {
virtual size_t getMax3dImageWidthOrHeight() const = 0;
virtual uint64_t getMaxMemAllocSize() const = 0;
virtual uint64_t getPatIndex(CacheRegion cacheRegion, CachePolicy cachePolicy) const = 0;
virtual bool isStatelesToStatefullWithOffsetSupported() const = 0;
virtual bool isStatelessToStatefulWithOffsetSupported() const = 0;
virtual void encodeBufferSurfaceState(EncodeSurfaceStateArgs &args) = 0;
virtual bool disableL3CacheForDebug(const HardwareInfo &hwInfo) const = 0;
virtual bool isRevisionSpecificBinaryBuiltinRequired() const = 0;
@@ -390,7 +390,7 @@ class HwHelperHw : public HwHelper {
size_t getMax3dImageWidthOrHeight() const override;
uint64_t getMaxMemAllocSize() const override;
uint64_t getPatIndex(CacheRegion cacheRegion, CachePolicy cachePolicy) const override;
bool isStatelesToStatefullWithOffsetSupported() const override;
bool isStatelessToStatefulWithOffsetSupported() const override;
void encodeBufferSurfaceState(EncodeSurfaceStateArgs &args) override;
bool disableL3CacheForDebug(const HardwareInfo &hwInfo) const override;
bool isRevisionSpecificBinaryBuiltinRequired() const override;

View File

@@ -44,13 +44,13 @@ size_t HwHelperHw<Family>::getMax3dImageWidthOrHeight() const {
template <typename Family>
uint64_t HwHelperHw<Family>::getMaxMemAllocSize() const {
//With statefull messages we have an allocation cap of 4GB
//Reason to subtract 8KB is that driver may pad the buffer with addition pages for over fetching..
// With stateful messages we have an allocation cap of 4GB
// Reason to subtract 8KB is that driver may pad the buffer with addition pages for over fetching
return (4ULL * MemoryConstants::gigaByte) - (8ULL * MemoryConstants::kiloByte);
}
template <typename Family>
bool HwHelperHw<Family>::isStatelesToStatefullWithOffsetSupported() const {
bool HwHelperHw<Family>::isStatelessToStatefulWithOffsetSupported() const {
return true;
}