From 7b35af8cd47b748811968e239ec3d538f0919313 Mon Sep 17 00:00:00 2001 From: foreman Date: Wed, 10 Jun 2015 16:23:26 -0400 Subject: [PATCH] P4 to Git Change 1159996 by weizhang@weizhang-lnx-opencl-tmp on 2015/06/10 16:03:37 EPR #410989 - [Project Brahma] - CL-GL Support At present, multi-gpu is not supported on Brahma stack. Thus, glxGetContextMVPUINFOAMD hasn't been implemented by OGL. Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp#24 edit --- .../runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp b/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp index bf78c1f09c..884f4a99fe 100644 --- a/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp +++ b/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp @@ -521,7 +521,11 @@ CALGSLDevice::initGLInteropPrivateExt(CALvoid* GLplatformContext, CALvoid* GLdev } if (!glXBeginCLInteropAMD || !glXEndCLInteropAMD || !glXResourceAttachAMD || - !glXResourceDetachAMD || !glXGetContextMVPUInfoAMD) + !glXResourceDetachAMD +#ifndef BRAHMA + || !glXGetContextMVPUInfoAMD +#endif + ) { return false; } @@ -586,9 +590,13 @@ CALGSLDevice::glCanInterop(CALvoid* GLplatformContext, CALvoid* GLdeviceContext) } } #elif defined (ATI_OS_LINUX) +#ifdef BRAHMA + canInteroperate = true; +#else GLuint glDeviceId = 0 ; GLuint glChainMask = 0 ; GLXContext ctx = (GLXContext)GLplatformContext; + if (glXGetContextMVPUInfoAMD(ctx,&glDeviceId,&glChainMask)){ GLuint deviceId = 0 ; GLuint chainMask = 0 ; @@ -602,6 +610,7 @@ CALGSLDevice::glCanInterop(CALvoid* GLplatformContext, CALvoid* GLdeviceContext) } } } +#endif #endif return canInteroperate; }