Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1960955

Summary: Mesa OpenCL (Clover) fails to compile kernels due to bogus path /usr//usr/lib64/clc/
Product: [Fedora] Fedora Reporter: Tomáš Trnka <tomastrnka>
Component: libclcAssignee: Tom Stellard <tstellar>
Status: NEW --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 34CC: fabian.deutsch, ian.hilt, igor.raits, kartochka378, lavauxg, tstellar
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tomáš Trnka 2021-05-16 19:06:18 UTC
Description of problem:
Upgrading to F34 broke Mesa OpenCL for me because all kernels fail to compile with "fatal error: cannot open file '/usr//usr/lib64/clc/kaveri-amdgcn-mesa-mesa3d.bc': No such file or directory".

Obviously some path prefixing must have gone wrong there, as there's no "usr" in /usr. Creating such a symlink (/usr/usr → /usr) makes everything work again.

Version-Release number of selected component (if applicable):
libclc-11.0.0-1.fc34.x86_64
mesa-libOpenCL-21.0.3-2.fc34.x86_64

(I have no idea if this is a bug in libclc, Mesa or elsewhere. Assigning to libclc for now because it owns the directory in question.)

How reproducible:
At will

Steps to Reproduce:
1. run "clinfo"

Actual results:
=== CL_PROGRAM_BUILD_LOG ===
fatal error: cannot open file '/usr//usr/lib64/clc/kaveri-amdgcn-mesa-mesa3d.bc': No such file or directory
  Preferred work group size multiple (kernel)     <getWGsizes:1504: create kernel : error -46>

Expected results:
  Preferred work group size multiple (kernel)     64

Comment 1 kartochka378 2021-05-31 09:44:32 UTC
same here, clover unusable for me

fatal error: cannot open file '/usr//usr/lib64/clc/polaris10-amdgcn-mesa-mesa3d.bc': No such file or directory
  Preferred work group size multiple (kernel)     <getWGsizes:1504: create kernel : error -46>

Comment 2 Guilhem Lavaux 2021-06-29 21:00:45 UTC
I confirm that the bug is still present with mesa-libOpenCL-21.1.3-1.fc34.x86_64. 

Running clinfo leads to (all the time):
=== CL_PROGRAM_BUILD_LOG ===
fatal error: cannot open file '/usr//usr/lib64/clc/polaris10-amdgcn-mesa-mesa3d.bc': No such file or directory


Checking strings in the libMesaOpenCL.so.1.0.0 shows:
strings /usr/lib64/libMesaOpenCL.so.1.0.0|grep clc
clc/clc.L
/usr//usr/lib64/clc/

which indicates the string is statically compiled in the binary.