Limit AUB SSH size to 64KB.

Change-Id: I1a23aa2a253a93ed9633ab7fda0a6180050add83
This commit is contained in:
Mrozek, Michal 2018-12-06 16:06:51 +01:00 committed by sys_ocldev
parent 3d35bf4291
commit 3719c7a767
3 changed files with 8 additions and 0 deletions

View File

@ -87,6 +87,7 @@ AUBCommandStreamReceiverHw<GfxFamily>::AUBCommandStreamReceiverHw(const Hardware
this->aubDeviceId = debugDeviceId == -1
? hwInfoIn.capabilityTable.aubDeviceId
: static_cast<uint32_t>(debugDeviceId);
this->defaultSshSize = 64 * KB;
}
template <typename GfxFamily>

View File

@ -842,3 +842,8 @@ HWTEST_F(AubCommandStreamReceiverTests, givenAubCommandStreamReceiverWhenObtaini
auto aubCsr = std::make_unique<AUBCommandStreamReceiverHw<FamilyType>>(**platformDevices, "", true, *pDevice->executionEnvironment);
EXPECT_EQ(1u, aubCsr->getPreferredTagPoolSize());
}
HWTEST_F(AubCommandStreamReceiverTests, givenAubCommandStreamReceiverWhenSshSizeIsObtainedItEqualsTo64KB) {
auto aubCsr = std::make_unique<MockAubCsr<FamilyType>>(**platformDevices, "", true, *pDevice->executionEnvironment);
EXPECT_EQ(64 * KB, aubCsr->defaultSshSize);
}

View File

@ -53,6 +53,8 @@ struct MockAubCsr : public AUBCommandStreamReceiverHw<GfxFamily> {
MockAubCsr(const HardwareInfo &hwInfoIn, const std::string &fileName, bool standalone, ExecutionEnvironment &executionEnvironment)
: AUBCommandStreamReceiverHw<GfxFamily>(hwInfoIn, fileName, standalone, executionEnvironment){};
using CommandStreamReceiverHw<GfxFamily>::defaultSshSize;
DispatchMode peekDispatchMode() const {
return this->dispatchMode;
}