Segfault in clcompile

Open discussion for MAGMA library (Matrix Algebra on GPU and Multicore Architectures)
Post Reply
mikesalin
Posts: 4
Joined: Fri Mar 14, 2014 4:37 am

Segfault in clcompile

Post by mikesalin » Mon Sep 07, 2015 11:09 am

I've got Segmentation fault while 'make' was trying to do: '../interface_opencl/clcompile -a -o ../lib/clmagma_kernels.co clag2z.co empty.co zcaxpycp.co ...' And was going to provide more details, but the forum's spamfilter had blocked my message :(

mikesalin
Posts: 4
Joined: Fri Mar 14, 2014 4:37 am

Re: Segfault in clcompile

Post by mikesalin » Mon Sep 07, 2015 11:10 am

Well, here are the details:
Hello, I am trying to build and run clMAgma on under a Virtual Box. Guest system is x64-based Linux (Linux mint debian edition 2). I am using Pocl as an OpenCL driver, which compiles kernels with Clang and runs them on CPU. clMagma version is 1.3.
When I was building Magma, I reached this:

Code: Select all

make[1]: Entering directory '/home/michael/stuff/clmagma-1.3.0/clmagmablas'
../interface_opencl/clcompile -a -o ../lib/clmagma_kernels.co clag2z.co empty.co zcaxpycp.co zlacpy.co zlag2c.co zlanhe.co zlaset.co zlaswp.co zlat2c.co zswap.co ztranspose.co ztranspose_inplace.co dznrm2.co zgemm_reduce.co zlacpy_cnjg.co zlarfbx.co zlarfgx-v2.co zlarfx.co zlascl_2x2.co clacpy.co clanhe.co claset.co claswp.co cswap.co ctranspose.co ctranspose_inplace.co scnrm2.co cgemm_reduce.co clacpy_cnjg.co clarfbx.co clarfgx-v2.co clarfx.co clascl_2x2.co slag2d.co dsaxpycp.co dlacpy.co dlag2s.co dlansy.co dlaset.co dlaswp.co dlat2s.co dswap.co dtranspose.co dtranspose_inplace.co dnrm2.co dgemm_reduce.co dlacpy_cnjg.co dlarfbx.co dlarfgx-v2.co dlarfx.co dlascl_2x2.co slacpy.co slansy.co slaset.co slaswp.co sswap.co stranspose.co stranspose_inplace.co snrm2.co sgemm_reduce.co slacpy_cnjg.co slarfbx.co slarfgx-v2.co slarfx.co slascl_2x2.co
Using platform: The pocl project Portable Computing Language
Makefile:102: recipe for target '../lib/clmagma_kernels.co' failed
make[1]: *** [../lib/clmagma_kernels.co] Segmentation fault
Before that I changed 'CL_DEVICE_TYPE_GPU' to 'CL_DEVICE_TYPE_ALL' in clmagma_runtime.cpp, line 125 in order to make clcompile work.
How can I debug that? Any help is greatly appreciated.

mikesalin
Posts: 4
Joined: Fri Mar 14, 2014 4:37 am

Re: Segfault in clcompile

Post by mikesalin » Tue Sep 08, 2015 7:55 am

More details: crush is at clmagma_runtime.cpp:325, function save_programs

Code: Select all

err = clGetProgramInfo( programs[i], CL_PROGRAM_BINARY_SIZES, m_num_devices*sizeof(binary_sizes[0]), &binary_sizes[0], NULL );

mgates3
Posts: 918
Joined: Fri Jan 06, 2012 2:13 pm

Re: Segfault in clcompile

Post by mgates3 » Fri Sep 11, 2015 3:18 am

You might try the latest that's in the clMAGMA repository on bitbucket.
https://bitbucket.org/icl/clmagma

clcompile was redone so the clGetProgramInfo call no longer exists. There were some OpenCL 1.2 features that we no longer rely on.

-mark

Post Reply