From 458dabf52c768e020a792299db363b8ee4a52299 Mon Sep 17 00:00:00 2001
From: foreman
Date: Tue, 15 Sep 2015 18:14:23 -0400
Subject: [PATCH] P4 to Git Change 1191016 by
skudchad@skudchad_test_win_opencl2 on 2015/09/15 18:01:18
EPR #425801 - Fix initLite toggle for windows.
Affected files ...
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp#141 edit
[ROCm/clr commit: 507ec058c63707c14c007a5914b9a6ad063b9be5]
---
.../device/gpu/gslbe/src/rt/GSLDevice.cpp | 17 +++++++++++++++--
1 file changed, 15 insertions(+), 2 deletions(-)
diff --git a/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp b/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp
index 3e27b4b876..06c11390c9 100644
--- a/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp
+++ b/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp
@@ -304,7 +304,14 @@ CALGSLDevice::PerformFullInitialization() const
bool
CALGSLDevice::SetupAdapter(int32 &asic_id)
{
- bool initLite = (m_attribs.isWDDM2Enabled) ? true : false;
+ bool initLite = false;
+#ifdef ATI_OS_WIN
+ if(osGetVersion() >= AMD_OS_VERSION_WINDOWS_10)
+ {
+ initLite = true;
+ }
+#endif
+
PerformAdapterInitialization_int(initLite);
if (m_adp == 0)
@@ -383,7 +390,13 @@ CALGSLDevice::SetupAdapter(int32 &asic_id)
bool
CALGSLDevice::SetupContext(int32 &asic_id)
{
- bool initLite = (m_attribs.isWDDM2Enabled) ? true : false;
+ bool initLite = false;
+#ifdef ATI_OS_WIN
+ if(osGetVersion() >= AMD_OS_VERSION_WINDOWS_10)
+ {
+ initLite = true;
+ }
+#endif
gsl::gsCtx* temp_cs = m_adp->createComputeContext(m_computeRing ? (m_isComputeRingIDForced ? m_forcedComputeEngineID :
getFirstAvailableComputeEngineID()) : GSL_ENGINEID_3DCOMPUTE0,
m_canDMA ? GSL_ENGINEID_DRMDMA0 : GSL_ENGINEID_INVALID, initLite);