mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-22 10:17:01 +08:00
Move CompilerInterface to ExecutionEnvironment
Change-Id: I14afdd8fc41ecd4ac8c8fcbeecda2539bc847288 Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
931b462ee1
commit
d2759a0629
@@ -58,10 +58,10 @@ class CompilerInterfaceTest : public DeviceFixture,
|
||||
retVal = CL_SUCCESS;
|
||||
|
||||
// create the compiler interface
|
||||
pCompilerInterface.reset(new MockCompilerInterface());
|
||||
ASSERT_NE(nullptr, pCompilerInterface);
|
||||
this->pCompilerInterface = new MockCompilerInterface();
|
||||
bool initRet = pCompilerInterface->initialize();
|
||||
ASSERT_TRUE(initRet);
|
||||
pDevice->getExecutionEnvironment()->compilerInterface.reset(pCompilerInterface);
|
||||
|
||||
std::string testFile;
|
||||
|
||||
@@ -94,12 +94,11 @@ class CompilerInterfaceTest : public DeviceFixture,
|
||||
delete pContext;
|
||||
|
||||
deleteDataReadFromFile(pSource);
|
||||
pCompilerInterface.reset();
|
||||
|
||||
DeviceFixture::TearDown();
|
||||
}
|
||||
|
||||
std::unique_ptr<MockCompilerInterface> pCompilerInterface = nullptr;
|
||||
MockCompilerInterface *pCompilerInterface;
|
||||
TranslationArgs inputArgs;
|
||||
Program *pProgram = nullptr;
|
||||
MockContext *pContext = nullptr;
|
||||
@@ -205,12 +204,6 @@ TEST_F(CompilerInterfaceTest, BuildWithDebugData) {
|
||||
delete cip;
|
||||
}
|
||||
|
||||
TEST_F(CompilerInterfaceTest, GetInstance_Shutdown) {
|
||||
auto *pCompilerInterface = CompilerInterface::getInstance();
|
||||
EXPECT_NE(nullptr, pCompilerInterface);
|
||||
CompilerInterface::shutdown();
|
||||
}
|
||||
|
||||
TEST_F(CompilerInterfaceTest, CompileClToIsa) {
|
||||
// build from .cl to gen ISA
|
||||
retVal = pCompilerInterface->build(*pProgram, inputArgs, false);
|
||||
|
||||
Reference in New Issue
Block a user