From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon@freedesktop.org Subject: [Bug 100105] Make Theano OpenCL support work on Clover and RadeonSI Date: Tue, 07 Mar 2017 18:35:38 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0865968931==" Return-path: Received: from culpepper.freedesktop.org (culpepper.freedesktop.org [IPv6:2610:10:20:722:a800:ff:fe98:4b55]) by gabe.freedesktop.org (Postfix) with ESMTP id 82DA46E212 for ; Tue, 7 Mar 2017 18:35:38 +0000 (UTC) List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============0865968931== Content-Type: multipart/alternative; boundary="14889117380.ac2D38dc2.32536"; charset="UTF-8" --14889117380.ac2D38dc2.32536 Date: Tue, 7 Mar 2017 18:35:38 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated https://bugs.freedesktop.org/show_bug.cgi?id=3D100105 Bug ID: 100105 Summary: Make Theano OpenCL support work on Clover and RadeonSI Product: Mesa Version: git Hardware: Other OS: All Status: NEW Severity: major Priority: medium Component: Drivers/Gallium/radeonsi Assignee: dri-devel@lists.freedesktop.org Reporter: vedran@miletic.net QA Contact: dri-devel@lists.freedesktop.org $ DEVICE=3D"opencl0:0" python -c "import pygpu;pygpu.test()" pygpu is installed in /usr/lib64/python2.7/site-packages/pygpu-0.6.2-py2.7-linux-x86_64.egg/pygpu NumPy version 1.11.2 NumPy relaxed strides checking option: False NumPy is installed in /usr/lib64/python2.7/site-packages/numpy Python version 2.7.13 (default, Jan 12 2017, 17:59:37) [GCC 6.3.1 20161221 = (Red Hat 6.3.1-1)] nose version 1.3.7 *** Testing for AMD FIJI (DRM 3.8.0 / 4.9.13-200.fc25.x86_64, LLVM 5.0.0) =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D AN INTERNAL KERNEL BUILD ERROR OCCURRED! device name =3D AMD FIJI (DRM 3.8.0 / 4.9.13-200.fc25.x86_64, LLVM 5.0.0) error =3D -43 memory pattern =3D Register accumulation based swap, computing kernel gener= ator Subproblem dimensions: dims[0].itemY =3D 32, dims[0].itemX =3D 32, dims[0].= y =3D 32, dims[0].x =3D 32, dims[0].bwidth =3D 64; ; dims[1].itemY =3D 4, dims[1].ite= mX =3D 4, dims[1].y =3D 4, dims[1].x =3D 4, dims[1].bwidth =3D 8; ;=20 Parallelism granularity: pgran->wgDim =3D 1, pgran->wgSize[0] =3D 64, pgran->wgSize[1] =3D 1, pgran->wfSize =3D 64 Kernel extra flags: 369130144 Source: #ifdef DOUBLE_PRECISION #ifdef cl_khr_fp64 #pragma OPENCL EXTENSION cl_khr_fp64 : enable #else #pragma OPENCL EXTENSION cl_amd_fp64 : enable #endif #endif __kernel void Sdot_kernel( __global float *_X, __global float *_Y, __global float *scratchBuff, uint N, uint offx, int incx, uint o= ffy, int incy, int doConj ) { __global float *X =3D _X + offx; __global float *Y =3D _Y + offy; float dotP =3D (float) 0.0; if ( incx < 0 ) { X =3D X + (N - 1) * abs(incx); } if ( incy < 0 ) { Y =3D Y + (N - 1) * abs(incy); } int gOffset; for( gOffset=3D(get_global_id(0) * 4); (gOffset + 4 - 1)
Bug ID 100105
Summary Make Theano OpenCL support work on Clover and RadeonSI
Product Mesa
Version git
Hardware Other
OS All
Status NEW
Severity major
Priority medium
Component Drivers/Gallium/radeonsi
Assignee dri-devel@lists.freedesktop.org
Reporter vedran@miletic.net
QA Contact dri-devel@lists.freedesktop.org

$ DEVICE=3D"opencl0:0" python -c "import pygpu;=
pygpu.test()"
pygpu is installed in
/usr/lib64/python2.7/site-packages/pygpu-0.6.2-py2.7-linux-x86_64.egg/pygpu
NumPy version 1.11.2
NumPy relaxed strides checking option: False
NumPy is installed in /usr/lib64/python2.7/site-packages/numpy
Python version 2.7.13 (default, Jan 12 2017, 17:59:37) [GCC 6.3.1 20161221 =
(Red
Hat 6.3.1-1)]
nose version 1.3.7
*** Testing for AMD FIJI (DRM 3.8.0 / 4.9.13-200.fc25.x86_64, LLVM 5.0.0)

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D

AN INTERNAL KERNEL BUILD ERROR OCCURRED!
device name =3D AMD FIJI (DRM 3.8.0 / 4.9.13-200.fc25.x86_64, LLVM 5.0.0)
error =3D -43
memory pattern =3D Register accumulation based swap, computing kernel gener=
ator
Subproblem dimensions: dims[0].itemY =3D 32, dims[0].itemX =3D 32, dims[0].=
y =3D 32,
dims[0].x =3D 32, dims[0].bwidth =3D 64; ; dims[1].itemY =3D 4, dims[1].ite=
mX =3D 4,
dims[1].y =3D 4, dims[1].x =3D 4, dims[1].bwidth =3D 8; ;=20
Parallelism granularity: pgran->wgDim =3D 1, pgran->wgSize[0] =3D 64,
pgran->wgSize[1] =3D 1, pgran->wfSize =3D 64
Kernel extra flags: 369130144
Source:

#ifdef DOUBLE_PRECISION
    #ifdef cl_khr_fp64
    #pragma OPENCL EXTENSION cl_khr_fp64 : enable
    #else
    #pragma OPENCL EXTENSION cl_amd_fp64 : enable
    #endif
#endif

__kernel void Sdot_kernel( __global float *_X, __global float *_Y, __global
float *scratchBuff,
                                        uint N, uint offx, int incx, uint o=
ffy,
int incy, int doConj )
{
    __global float *X =3D _X + offx;
    __global float *Y =3D _Y + offy;
    float dotP =3D (float) 0.0;

    if ( incx < 0 ) {
        X =3D X + (N - 1) * abs(incx);
    }
    if ( incy < 0 ) {
        Y =3D Y + (N - 1) * abs(incy);
    }

    int gOffset;
    for( gOffset=3D(get_global_id(0) * 4); (gOffset + 4 - 1)<N; gOffset+=
=3D(
get_global_size(0) * 4 ) )
    {
        float4 vReg1, vReg2, res;

        #ifdef INCX_NONUNITY
             vReg1 =3D (float4)(  (X + (gOffset*incx))[0 + ( incx * 0)],  (=
X +
(gOffset*incx))[0 + ( incx * 1)],  (X + (gOffset*incx))[0 + ( incx * 2)],  =
(X +
(gOffset*incx))[0 + ( incx * 3)]);
        #else
            vReg1 =3D vload4(  0, (__global float *) (X + gOffset) );
        #endif

        #ifdef INCY_NONUNITY
             vReg2 =3D (float4)(  (Y + (gOffset*incy))[0 + ( incy * 0)],  (=
Y +
(gOffset*incy))[0 + ( incy * 1)],  (Y + (gOffset*incy))[0 + ( incy * 2)],  =
(Y +
(gOffset*incy))[0 + ( incy * 3)]);
        #else
            vReg2 =3D vload4(  0, (__global float *) (Y + gOffset) );
        #endif

        ;
         res =3D  vReg1 *  vReg2 ;
        dotP +=3D  res .S0 +  res .S1 +  res .S2 +  res .S3;
;          // Add-up elements in the vector to give a scalar
    }

    // Loop for the last thread to handle the tail part of the vector
    // Using the same gOffset used above
    for( ; gOffset<N; gOffset++ )
    {
        float sReg1, sReg2, res;
        sReg1 =3D X[gOffset * incx];
        sReg2 =3D Y[gOffset * incy];

        ;
             res =3D  sReg1 *  sReg2 ;
             dotP =3D  dotP +  res ;
        }

    // Note: this has to be called outside any if-conditions- because REDUC=
TION
uses barrier
    // dotP of work-item 0 will have the final reduced item of the work-gro=
up
    __local float viraW [ 64 ];
        uint kFbwL =3D get_local_id(0);
         viraW [ kFbwL ] =3D  dotP ;
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL < 32 ) {
                 viraW [ kFbwL ] =3D viraW [ kFbwL ] + viraW [ kFbwL + 32 ];
        }
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL < 16 ) {
                 viraW [ kFbwL ] =3D viraW [ kFbwL ] + viraW [ kFbwL + 16 ];
        }
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL < 8 ) {
                 viraW [ kFbwL ] =3D viraW [ kFbwL ] + viraW [ kFbwL + 8 ];
        }
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL < 4 ) {
                 viraW [ kFbwL ] =3D viraW [ kFbwL ] + viraW [ kFbwL + 4 ];
        }
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL < 2 ) {
                 viraW [ kFbwL ] =3D viraW [ kFbwL ] + viraW [ kFbwL + 2 ];
        }
        barrier(CLK_LOCAL_MEM_FENCE);

        if( kFbwL =3D=3D 0 ) {
         dotP  =3D viraW [0] + viraW [1];
        }

    if( (get_local_id(0)) =3D=3D 0 ) {
        scratchBuff[ get_group_id(0) ] =3D dotP;
    }
}



--------------------------------------------------------

Build log:


=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D

Segmentation fault (core dumped)


You are receiving this mail because:
  • You are the assignee for the bug.
= --14889117380.ac2D38dc2.32536-- --===============0865968931== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVs IG1haWxpbmcgbGlzdApkcmktZGV2ZWxAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlz dHMuZnJlZWRlc2t0b3Aub3JnL21haWxtYW4vbGlzdGluZm8vZHJpLWRldmVsCg== --===============0865968931==--