cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

tylerwylie
Journeyman III

OpenCL issues working on CentOS 5.4 x64.

Library woes.

I'm trying to run a few of the samples and get my OpenCL development environment working in CentOS 5.4 x64.  I have run into some issues that prevent it from working as expected.  Errors are shown below:

[tyler@tyler-workstation x86_64]# ldd CLInfo
./CLInfo: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./CLInfo)
        libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003975200000)
        libdl.so.2 => /lib64/libdl.so.2 (0x0000003974e00000)
        libOpenCL.so => /usr/local/ati/lib/x86_64/libOpenCL.so (0x00002ae12115e000)
        libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x0000003985400000)
        libm.so.6 => /lib64/libm.so.6 (0x0000003974a00000)
        libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x0000003982000000)
        libc.so.6 => /lib64/libc.so.6 (0x0000003974600000)
        /lib64/ld-linux-x86-64.so.2 (0x0000003973600000)
        librt.so.1 => /lib64/librt.so.1 (0x0000003975600000)
[tyler@tyler-workstation x86_64]# ./NBody
Error: clGetPlatformIDs failed. Error code : unknown error code

[root@tyler-workstation x86_64]# echo $LD_LIBRARY_PATH
/usr/local/ati/lib/x86_64/:/usr/lib64/:/usr/lib

My stream SDK has been installed to /usr/local/ati/lib/x86_64.

I was able to run make in my the top level directory(/usr/local/ati) and it exited with no errors, it's when I try to run the sample executables that I run into issues.

[root@tyler-workstation ati]# echo $LD_LIBRARY_PATH
/usr/local/ati/lib/x86_64/:/usr/lib64/:/usr/lib

So that said, it seems the issue is with CLInfo wanting a specific GLIBC version(3.4.9).  Is there any workaround?

 

Thanks in advance!

 

0 Likes
9 Replies
genaganna
Journeyman III

Tylerwylie,

      It looks like you are facing ICD issue.

      You must register the OpenCL ICD; otherwise, samples and other applications will fail to
execute if this is not done. To register the ICD:
a. If one does not exist, create a folder /usr/lib/OpenCL/vendors.
b. Create the /usr/lib/OpenCL/vendors folder, if does not already exist.
c. Symlink [INSTALLDIR]/x86/libatiocl32.so into the vendors folder:
sudo ln -sf [INSTALLDIR]/x86/libatiocl32.so /usr/lib/OpenCL/vendors/libatiocl32.so
d. For 64-bit installations, you also must symlink
[INSTALLDIR]/x86_64/libatiocl64.so to the vendors folder:
sudo ln -sf [INSTALLDIR]/x86_64/libatiocl64.so /usr/lib/OpenCL/vendors/libatiocl64.so
Samples and other applications will fail to execute if this is not done.

0 Likes

Originally posted by: genaganna Tylerwylie,

 

      It looks like you are facing ICD issue.

 

      You must register the OpenCL ICD; otherwise, samples and other applications will fail to execute if this is not done. To register the ICD: a. If one does not exist, create a folder /usr/lib/OpenCL/vendors. b. Create the /usr/lib/OpenCL/vendors folder, if does not already exist. c. Symlink [INSTALLDIR]/x86/libatiocl32.so into the vendors folder: sudo ln -sf [INSTALLDIR]/x86/libatiocl32.so /usr/lib/OpenCL/vendors/libatiocl32.so d. For 64-bit installations, you also must symlink [INSTALLDIR]/x86_64/libatiocl64.so to the vendors folder: sudo ln -sf [INSTALLDIR]/x86_64/libatiocl64.so /usr/lib/OpenCL/vendors/libatiocl64.so Samples and other applications will fail to execute if this is not done.

 

I have done this now, updated my LD_LIBRARY_PATH and I am still getting the same issues.

[root@tyler-workstation x86_64]# find /usr/lib* -iname "libatiocl*.so"
/usr/lib/OpenCL/vendors/libatiocl32.so
/usr/lib64/OpenCL/vendors/libatiocl64.so

 


0 Likes

64 bit .so should be at /usr/lib/OpenCL/vendors/libatiocl64.so

 

 

0 Likes

Originally posted by: genaganna 64 bit .so should be at /usr/lib/OpenCL/vendors/libatiocl64.so

 

 

 

 

 

[root@tyler-workstation x86_64]# ln -sf /usr/local/ati/lib/x86_64/libatiocl64.so  /usr/lib/OpenCL/vendors/libatiocl64.so
[root@tyler-workstation x86_64]# ./NBody
Error: clGetPlatformIDs failed. Error code : unknown error code

 

Still getting the same issues, what I posted initially which has this error:
./CLInfo: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./CLInfo)

I think points to the issue, does it require that specific version of GLIBC?  Is there another package I can install that'll fix this, or maybe tricking OpenCL into believing that it's gluibc 3.4.9?

 

Thanks!

0 Likes

Actually your os is not supported officially. I am sure you are facing ICD issue in NBody case.  Incase of CLInfo, You need to upgrade to GLIBCXX_3.4.9.

 

Are you able to run any CAL samples?

0 Likes

Okay, is this known to work on any other platforms?  Or should I get an Ubuntu 9.04 / OpenSUSE 11.0 install up and running?   Ubuntu 9.10 work?  OpenSUSE  11.1 / 11.2?

 

Thanks in advance

 

0 Likes

CAL works fine by the way

0 Likes

OpenSUSE 11.0 and Ubuntu 9.04 are properly tested OS's.

I remember some users are able to use Ubuntu 9.10 with specific kernels. See following link for more information on 9.10.

http://forums.amd.com/forum/messageview.cfm?catid=328&threadid=124182&forumid=9

 

0 Likes
gapon
Journeyman III

I've ran into the very same problem on Red Hat WS 5.3. It turns out that OpenCL SDK 2.0 requires GCC 4.3.2 or higher (4.4). Meanwhile Red Hat 5.3 (and so does CentOS 5.3) comes with GCC 4.1.2. GLIBCXX_3.4.9 is available starting with GCC 4.3.2. Fortunately, Red Hat provides GCC 4.4 via the "Technology Preview" program:

http://rhn.redhat.com/errata/RHBA-2009-1375.html

I'm not sure if this would apply to CentOS users.

By the way, I suspect this was a reason why the production version of OpenCL SDK 2.0 dropped Red Hat from a list of supported systems (it was in the earlier 'beta' version of SDK which only required GCC 4.1.2).

Anyone knows what's special in the recent version of GCC?

 

 

0 Likes