Files
compute-runtime/opencl/source/os_interface/windows/platform_teardown_win.cpp
Mateusz Jablonski 48c084ca32 Create platformsImpl when needed
Change-Id: Ie89356761fc39910c765066d40cd363c93002692
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2020-09-07 16:36:40 +02:00

21 lines
450 B
C++

/*
* Copyright (C) 2020 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#include "opencl/source/platform/platform.h"
using namespace NEO;
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
if (fdwReason == DLL_PROCESS_DETACH) {
delete platformsImpl;
}
if (fdwReason == DLL_PROCESS_ATTACH) {
platformsImpl = new std::vector<std::unique_ptr<Platform>>;
}
return TRUE;
}