Use igc interface to get max param size

IGC will be queried for max parameter size at the end of initializing
device caps.

Related-To: NEO-4851

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
This commit is contained in:
Dominik Dabek
2021-12-27 12:44:57 +00:00
committed by Compute-Runtime-Automation
parent 3c6f5cd757
commit 300a971af3
8 changed files with 42 additions and 1 deletions

View File

@@ -1087,6 +1087,12 @@ TEST_F(CompilerInterfaceTest, whenCompilerIsNotAvailableThenGetSpecializationCon
EXPECT_EQ(TranslationOutput::ErrorCode::CompilerNotAvailable, err);
}
TEST_F(CompilerInterfaceTest, givenCompilerInterfacewhenGettingIgcFeaturesAndWorkaroundsThenValidPointerIsReturned) {
auto igcFeaturesAndWorkarounds = pCompilerInterface->getIgcFeaturesAndWorkarounds(*pDevice);
EXPECT_NE(igcFeaturesAndWorkarounds, nullptr);
EXPECT_EQ(igcFeaturesAndWorkarounds->GetMaxOCLParamSize(), 0u);
}
TEST_F(CompilerInterfaceTest, GivenRequestForNewFclTranslationCtxWhenInterfaceVersionAbove4ThenPopulatePlatformInfo) {
auto device = this->pDevice;

View File

@@ -78,3 +78,11 @@ TEST_F(DeviceTest, whenGetRTDispatchGlobalsIsCalledWithZeroSizeAndMockAllocatorT
pDevice->initializeRayTracing(5);
EXPECT_NE(nullptr, pDevice->getRTDispatchGlobals(0));
}
using DeviceGetCapsTest = Test<DeviceFixture>;
TEST_F(DeviceGetCapsTest, givenNonZeroMaxParameterSizeFromIGCwhenDeviceIsCreatedThenMaxParameterSizeIsSetCorrectly) {
pDevice->maxParameterSizeFromIGC = 1u;
pDevice->initializeCaps();
EXPECT_EQ(pDevice->getDeviceInfo().maxParameterSize, 1u);
}