Bug 223879 - graphics/blender: runtime error: LLVM ERROR: inconsistency in registered CommandLine options
Summary: graphics/blender: runtime error: LLVM ERROR: inconsistency in registered Comm...
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: freebsd-ports-bugs mailing list
URL:
Keywords:
: 223844 (view as bug list)
Depends on: 233495
Blocks:
  Show dependency treegraph
 
Reported: 2017-11-26 08:52 UTC by O. Hartmann
Modified: 2018-11-25 09:45 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (FreeBSD)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description O. Hartmann 2017-11-26 08:52:09 UTC
On a couple of software where OpenCL is enabled, I run recently into a serious problem (also on lang/pocl). The OpenCL code quits execution immediately with the error similar to that shown below.

Searching the net for this error reveals bug reports reaching as far as early 2016 and the problem is considered to be a LLVM bug. I have no clue how to fix this or work around, so I report this here.

From POCL's github, I got this report with no satisfying result:
https://github.com/pocl/pocl/issues/474

[...]
X server found. dri2 connection failed! 
Device open failed, aborting...
: CommandLine Error: Option 'enable-value-profiling' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options
Nothing to output !
[...]

As far as I can understand, the problem is caused by LLVM in case several ICDs register to the very same LLVM backend.
Comment 1 Shane 2017-11-27 10:18:24 UTC
While I haven't had any opencl build issues, I have had no success getting any opencl code to work, even non-blender.

I left the opencl option available in graphics/opensubdiv but deliberatly disabled cycles opensubdiv support from using opencl as it naively assumes opensubdiv has opencl support.

Are you building opensubdiv with opencl enabled? Blender can use opencl within the compositor as well as in cycles rendering and opensubdiv, could those multiple options be the cause of the clash?

Not sure I can offer any help here, but will accept any changes needed to make opencl work.
Comment 2 O. Hartmann 2017-12-25 12:46:35 UTC
*** Bug 223844 has been marked as a duplicate of this bug. ***
Comment 3 Nikolai Lifanov freebsd_committer 2018-02-21 20:19:42 UTC
Can you re-test this with the last patch in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=224584 please? This one uses LLVM 5.0 and I'm not experiencing this issue.
Comment 4 O. Hartmann 2018-11-25 09:45:06 UTC
The problem is still present with LLVM 7.0 as for its predecessors.

I files a PR (PR 233495) to gather all the issues and relate them to one spot.

The issue seems to spread more and more as OpenCL platforms with LLVM backends become consistently linked against the same LLVM backend.