BUG: LLVM: : CommandLine Error: Option 'enable-value-profiling' registered more than once!

O. Hartmann ohartmann at walstatt.org
Mon Dec 25 15:13:41 UTC 2017


I'm not a compiler expert and I have some serious trouble getting port lang/pocl to work
properly. I'm on CURRENT (FreeBSD 12.0-CURRENT #79 r327170: Mon Dec 25 03:35:27 CET 2017
amd64). The problem persits on both LLD_IS_LD set or not.

Whenever lang/pocl in combination with devel/ocl-icd is installed and more than one OpenCL
ICD is installed with lang/pocl, any client (compiled with lang/pocl) or port/package
utilising OpenCL in any way (see graphics/blender PR23879 or devel/clinfo, bails out with:

: CommandLine Error: Option 'enable-value-profiling' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options

Looking at the POCL repo at github gives noch much help about this, they closed an error
report stating it isn't POCL related, but a long-standig LLVM issue, please see
https://github.com/pocl/pocl/issues/474.

Searching the net for this sepcific error reveals this bug at llvm.org's bug report:

[...]
Don't link ObjCARCOpts twice. Fixes PR22543
https://reviews.llvm.org/rL240104

Taken that information, the "bug" is considered solved - but it is lldb related, not
lld or whatever is causing the error for POCL! 

I also found this one, still open:

[...]
Bug 22952 - cl::opt + LLVM_BUILD_LLVM_DYLIB is completely broken 
https://bugs.llvm.org/show_bug.cgi?id=22952

I do not have the experience, brains and resources to look into this matter any deeper,
so I'd appreciate someone with insight into LLVM could take a look at this.

When I look what OpenCL ICDs are installed apart from lang/pocl on my boxes, I see this
installation:

5618138 -rw-r--r--  1 root  wheel  -   33B Dec 25 03:35 intel-beignet.icd
5618040 -rw-r--r--  1 root  wheel  -   19B Dec 17 15:48 mesa.icd
[5617930 -rw-r--r--  1 root  wheel  -   31B Dec 23 11:21 pocl.icd]

Testing with port devel/clinfo and with(!) lang/pocl installed, gives the error I stated
initially. Deleting lang/pocl, devel/clinfo dies any way with this error:

[...]
Unable to find symbol pthread_mutexattr_setkind_np version (null). Aborting.
Abort

or it simply hangs [Ctrl-T]:
load: 0.12  cmd: clinfo 82286 [uwait] 46.78r 0.02u 0.00s 0% 50964k

Something isn't right here.

A far more serious port is graphics/blender. With usage of OpenCL and having lang/pocl
installed, I receive the error initially mentioned. 


I've provided a DIFF to to the (marked broken) lang/pocl version 0.14 (for this sepcific
PR see Bug 223032 - [PATCH] lang/pocl: pkg-static fails due to wrong pkg-plist entries,
look at https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=223032):

POCL 1.0:
Bug 224584 - [PATCH] lang/pocl: fix pkg-plist and update to POCL 1.0
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=224584

Hopefully,someone has the time to have a look into this.

Kind regards,

Oliver

-- 
O. Hartmann

Ich widerspreche der Nutzung oder Übermittlung meiner Daten für
Werbezwecke oder für die Markt- oder Meinungsforschung (§ 28 Abs. 4 BDSG).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 313 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-current/attachments/20171225/11104125/attachment.sig>


More information about the freebsd-current mailing list