[LLVMdev] Segfault when using llvm-3.6 and OpenGL at the same time on Linux (with mesa, which uses llvm-3.4)

Joerg Sonnenberger joerg at britannica.bec.de
Tue Feb 17 11:59:06 PST 2015


On Tue, Feb 17, 2015 at 08:19:02PM +0100, Daniel Albuschat wrote:
> 2015-02-16 23:20 GMT+01:00 Joerg Sonnenberger <joerg at britannica.bec.de>:
> 
> > On Mon, Feb 16, 2015 at 10:38:52PM +0100, Daniel Albuschat wrote:
> > > tl;dr:
> > > Is it a known behaviour that using llvm-3.4 and llvm-3.6 at the same time
> > > in the same process (while llvm-3.6 is used from a linked shared library
> > > and llvm-3.4 is dlopen'ed - with a strange detail: Especially if
> > -rdynamic
> > > is used when linking the program).
> >
> > Are you using builds with or without exceptions? There is a known
> > "feature" in libstdc++ that exceptions are unified by class name, not by
> > object. That breaks dlopen even if all users have RTLD_LOCAL.
> >
> 
> llvm-3.4 is from the official Ubuntu 14.04 repo. llvm-3.6 is from
> http://llvm.org/apt.
> How do I know / find out, whether they are compiled with or without
> exceptions?

nm -DC $lib | grep "typeinfo for" would be a start (RTTI, not
exceptions).

> My guess is that they are compiled without exceptions, since it is the
> default.
> My app however, does use exceptions. Is this even possible?

If exceptions don't cross library boundaries, yes.

> > The second question would be whether any of the DSOs involved for
> > LLVM/Clang have different sonames for the different versions.
> >
> 
> Clang is not involved here. I am compiling with g++ and does only use llvm,
> not Clang.
> llvm does use some common libraries like pthreads, dl and ncurses. Are
> those related, or do you mean libraries actually involved in code
> generation?

No, only the LLVM libraries. System libraries don't count.

Joerg



More information about the llvm-dev mailing list