Allow Device creating multiple CSRs [3/n]

Add CSR from Device to CommandQueue

Change-Id: Iaccf3c73d25e357242837677777d0513e81f520e
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:
Dunajski, Bartosz
2018-11-22 13:57:10 +01:00
committed by sys_ocldev
parent fbf0d44fff
commit 3ad33bf1b8
72 changed files with 239 additions and 242 deletions

View File

@@ -155,21 +155,21 @@ GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueNonVmeKernelAfterVmeKernelThe
}
GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToFalse) {
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pDevice->getCommandStreamReceiver());
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pCmdQ->getCommandStreamReceiver());
csr->lastVmeSubslicesConfig = true;
enqueueVmeKernel<FamilyType>();
EXPECT_TRUE(csr->lastVmeSubslicesConfig);
}
GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToTrue) {
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pDevice->getCommandStreamReceiver());
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pCmdQ->getCommandStreamReceiver());
csr->lastVmeSubslicesConfig = false;
enqueueVmeKernel<FamilyType>();
EXPECT_FALSE(csr->lastVmeSubslicesConfig);
}
GEN9TEST_F(MediaKernelTest, gen9CmdSizeForMediaSampler) {
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pDevice->getCommandStreamReceiver());
auto csr = static_cast<UltCommandStreamReceiver<FamilyType> *>(&pCmdQ->getCommandStreamReceiver());
csr->lastVmeSubslicesConfig = false;
EXPECT_EQ(0u, csr->getCmdSizeForMediaSampler(false));