I actually have a card supported by the radeonsi driver, but, probably due to the error reported here, hardware-supported 3D is not available under X. I think the error here would also apply to radeonsi if Mesa attempted to load it. When I run glxinfo, I get: name of display: :0 libGL: screen 0 does not appear to be DRI2 capable libGL: OpenDriver: trying /opt/xorg/lib/dri/tls/swrast_dri.so libGL: OpenDriver: trying /opt/xorg/lib/dri/swrast_dri.so libGL error: dlopen /opt/xorg/lib/dri/swrast_dri.so failed (/opt/xorg/lib/dri/swrast_dri.so: undefined symbol: _ZTIN4llvm11raw_ostreamE) libGL error: unable to load driver: swrast_dri.so libGL error: failed to load driver: swrast X Error of failed request: 0 Major opcode of failed request: 153 (GLX) Minor opcode of failed request: 26 (X_GLXMakeContextCurrent) Serial number of failed request: 33 Current serial number in output stream: 33 The demangled name of "_ZTIN4llvm11raw_ostreamE" is "typeinfo for llvm::raw_ostream". LLVM is compiled without RTTI. Mesa has a class that inherits llvm::raw_ostream and is compiled without -fno-rtti. That might be the code that triggers the problem: src/gallium/auxiliary/gallivm/lp_bld_debug.cpp: class raw_debug_ostream : public llvm::raw_ostream { I experimentally patched Mesa like so: mesa$ git diff diff --git a/src/gallium/auxiliary/Makefile.am b/src/gallium/auxiliary/Makefile.am index 2d2d8d4..d961243 100644 --- a/src/gallium/auxiliary/Makefile.am +++ b/src/gallium/auxiliary/Makefile.am @@ -10,7 +10,7 @@ AM_CFLAGS = \ $(GALLIUM_CFLAGS) \ $(VISIBILITY_CFLAGS) -AM_CXXFLAGS = $(VISIBILITY_CXXFLAGS) +AM_CXXFLAGS = $(VISIBILITY_CXXFLAGS) -fno-rtti libgallium_la_SOURCES = \ $(C_SOURCES) \ @@ -23,7 +23,7 @@ AM_CFLAGS += \ AM_CXXFLAGS += \ $(GALLIUM_CFLAGS) \ - $(LLVM_CXXFLAGS) + $(LLVM_CXXFLAGS) -fno-rtti libgallium_la_SOURCES += \ $(GALLIVM_SOURCES) \ and recompiled. That seemed to fix the problem for me: $ glxinfo name of display: :0 libGL: screen 0 does not appear to be DRI2 capable libGL: OpenDriver: trying /opt/xorg/lib/dri/tls/swrast_dri.so libGL: OpenDriver: trying /opt/xorg/lib/dri/swrast_dri.so libGL: Can't open configuration file /home/horst/.drirc: No such file or directory. libGL: Can't open configuration file /home/horst/.drirc: No such file or directory. display: :0 screen: 0 direct rendering: Yes server glx vendor string: SGI server glx version string: 1.4 server glx extensions: GLX_ARB_multisample, GLX_EXT_import_context, GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info, GLX_EXT_visual_rating, GLX_MESA_copy_sub_buffer, GLX_OML_swap_method, GLX_SGIS_multisample, GLX_SGIX_fbconfig, GLX_SGIX_pbuffer, GLX_SGI_make_current_read client glx vendor string: Mesa Project and SGI client glx version string: 1.4 (...) My configure invocation, extracted from config.status, is: './configure' '--prefix=/opt/xorg' '--with-egl-platforms=x11,drm' '--enable-gbm' '--enable-shared-glapi' '--enable-glx-tls' '--enable-gles1' '--enable-gles2' '-disable-xvmc' '--with-gallium-drivers=r300,r600,svga,swrast,radeonsi' 'PKG_CONFIG_PATH=/opt/xorg/share/pkgconfig:/opt/xorg/lib/pkgconfig:/opt/kde4/lib/x86_64-linux-gnu/pkgconfig:/opt/kde4/lib/pkgconfig' Both LLVM and Mesa versions are very current, maybe two hours old at the time of this writing.
Similar thing here: (EE) AIGLX error: dlopen of /usr/lib64/dri/r600_dri.so failed (/usr/lib64/dri/r600_dri.so: undefined symbol: _ZTIN4llvm18format_object_baseE) (EE) AIGLX error: dlopen of /usr/lib64/dri/swrast_dri.so failed (/usr/lib64/dri/swrast_dri.so: undefined symbol: _ZTIN4llvm18format_object_baseE) % c++filt _ZTIN4llvm18format_object_baseE typeinfo for llvm::format_object_base Your patch to src/gallium/auxiliary/Makefile.am fixes the issue. Please note that: % llvm-config --cxxflags -I/usr/local/include -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wnon-virtual-dtor -O3 -DNDEBUG -pipe -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS doesn't include -fno-rtti for llvm 3.4 even when llvm was build without run-time type information (the default).
did you use cmake to compile llvm?
(In reply to comment #2) > did you use cmake to compile llvm? check this patch: http://www.mail-archive.com/mesa-dev@lists.freedesktop.org/msg45916.html
The LLVM patch does the trick for me. With the patch, llvm-config --cxxflags output contains -fno-rtti (at the very end) and Mesa drivers radeonsi and swrast can be loaded.
For completeness because I forgot to say it explicitly: Yes, I'm using cmake. Also hello LLVM, if anybody sees this... that patch is important.
Marking this as a duplicate of 81785 which has a lot more information + including a link to the actual llvm/cmake fix. Now all we need is to convince the llvm people to actually push it (or equivalent fix of course) :P *** This bug has been marked as a duplicate of bug 81785 ***
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.