[Bug 747333] New: LLVM crashes in Mesa triggered by Wine games
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c0 Summary: LLVM crashes in Mesa triggered by Wine games Classification: openSUSE Product: openSUSE 12.1 Version: Final Platform: Other OS/Version: Other Status: NEW Severity: Normal Priority: P5 - None Component: X.Org AssignedTo: bnc-team-xorg-bugs@forge.provo.novell.com ReportedBy: meissner@suse.com QAContact: xorg-maintainer-bugs@forge.provo.novell.com Found By: --- Blocker: --- Hi, https://bugs.freedesktop.org/show_bug.cgi?id=41791 is one occurence where a game in Wine crashes within openSUSE / Mesa code in LLVM. The Wine 3D developers made me aware that there are various of such reports, mostly on openSUSE. Are you aware of such problems and perhaps a fix? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c1 Stefan Dirsch <sndirsch@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P5 - None |P3 - Medium Status|NEW |ASSIGNED AssignedTo|bnc-team-xorg-bugs@forge.pr |xorg-maintainer-bugs@forge. |ovo.novell.com |provo.novell.com --- Comment #1 from Stefan Dirsch <sndirsch@suse.com> 2012-02-16 11:44:35 UTC ---
Are you aware of such problems and perhaps a fix?
2x no. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c2 --- Comment #2 from Marcus Meissner <meissner@suse.com> 2012-02-16 12:51:45 UTC --- seems mostly happening on r600g (whatever card this exactly is ;) and according to wine 3d guys likely visible by simple 3d apps already. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c3 --- Comment #3 from Marcus Meissner <meissner@suse.com> 2012-02-16 12:55:24 UTC --- relevant is perhaps also that we do 32bit code on 64bit... so installing glxgears 32bit and trying might trigger this better than glxgears 64bit. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c4 Rafał Miłecki <zajec5@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |zajec5@gmail.com --- Comment #4 from Rafał Miłecki <zajec5@gmail.com> 2012-02-24 16:35:40 UTC --- I'm experiencing similar problems: 1) Crash of Diablo II when using "gdi" renderer. Workaround is to use windowed mode (-w game parameter) or (important!) DRAW_USE_LLVM=0 Details: http://bugs.winehq.org/show_bug.cgi?id=14348 2) White/black screen when using "opengl" renderer. Again, using DRAW_USE_LLVM=0 workarounds this issue. Details: http://bugs.winehq.org/show_bug.cgi?id=29786 I suspect there is something wrong with the Mesa provided in openSUSE 12.1. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c5 --- Comment #5 from Rafał Miłecki <zajec5@gmail.com> 2012-02-24 16:37:20 UTC --- Note: I'm using 32bit openSUSE, so it's not about 32bit vs. 64bit conflict. I wanted to compile Mesa on my own and I've hit following problem. Maybe there is something wrong with the llvm provided in openSUSE 12.1? g++ -g -O2 -Wall -std=c99 -Werror=implicit-function-declaration -Werror=missing-prototypes -fno-strict-aliasing -fno-builtin-memcmp -g -O2 -fPIC -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LIBUDEV -DHAVE_XCB_DRI2 -DXCB_DRI2_CONNECT_DEVICE_NAME_BROKEN -D__STDC_CONSTANT_MACROS -DHAVE_LLVM=0x0300 -fvisibility=hidden -o r600_dri.so.test ./../../../src/mesa/drivers/dri/common/dri_test.o r600_dri.so.tmp -L../../../../lib -Wl,-R/usr/lib/dri -ldricore -lglsl -ldrm -lexpat -lm -lpthread -ldl -ldrm_radeon -L/usr/lib -ldl -lpthread; r600_dri.so.tmp: undefined reference to `llvm::MCAsmBackend::MCAsmBackend()' r600_dri.so.tmp: undefined reference to `LLVMStructCreateNamed' r600_dri.so.tmp: undefined reference to `llvm::createELFStreamer(llvm::MCContext&, llvm::MCAsmBackend&, llvm::raw_ostream&, llvm::MCCodeEmitter*, bool, bool)' r600_dri.so.tmp: undefined reference to `llvm::MCAsmBackend::getFixupKindInfo(llvm::MCFixupKind) const' r600_dri.so.tmp: undefined reference to `vtable for llvm::MCInstrAnalysis' r600_dri.so.tmp: undefined reference to `llvm::createWinCOFFStreamer(llvm::MCContext&, llvm::MCAsmBackend&, llvm::MCCodeEmitter&, llvm::raw_ostream&, bool)' r600_dri.so.tmp: undefined reference to `llvm::StackAlignmentOverride' r600_dri.so.tmp: undefined reference to `llvm::MCSubtargetInfo::InitMCSubtargetInfo(llvm::StringRef, llvm::StringRef, llvm::StringRef, llvm::SubtargetFeatureKV const*, llvm::SubtargetFeatureKV const*, llvm::SubtargetInfoKV const*, llvm::InstrStage const*, unsigned int const*, unsigned int const*, unsigned int, unsigned int)' r600_dri.so.tmp: undefined reference to `llvm::MCCodeGenInfo::InitMCCodeGenInfo(llvm::Reloc::Model, llvm::CodeModel::Model)' r600_dri.so.tmp: undefined reference to `LLVMStructSetBody' r600_dri.so.tmp: undefined reference to `llvm::X86ATTInstPrinter::X86ATTInstPrinter(llvm::MCAsmInfo const&)' r600_dri.so.tmp: undefined reference to `llvm::MCAsmBackend::~MCAsmBackend()' r600_dri.so.tmp: undefined reference to `llvm::createMachOStreamer(llvm::MCContext&, llvm::MCAsmBackend&, llvm::raw_ostream&, llvm::MCCodeEmitter*, bool)' collect2: ld returned 1 exit status AFAICS in Marcus's bug report, his crash is llvm related! -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c6 --- Comment #6 from Rafał Miłecki <zajec5@gmail.com> 2012-02-26 09:40:02 UTC --- I was not able to compile mesa on my own, because of having libllvm installed (2.9.99.git20110601.1955-1.pm.1.1 - it was packman version, dropped from their repository now). What I did was: zypper rm libllvm zypper in --force llvm llvm-clang llvm-clang-devel llvm-devel That didn't help my wine. It still crashes unless I set DRAW_USE_LLVM=0. However removing & reinstalling that packages let me compile Mesa on my own. I've compiled version from git and installed it. I'm quite sure installation went fine because now I get (from glxinfo): OpenGL vendor string: X.Org OpenGL renderer string: Gallium 0.4 on AMD RV620 OpenGL version string: 2.1 Mesa 8.1-devel (git-a0a9e56) Unfortunately using self-compiled Mesa doesn't resolve that wine issue. My games still crash unless I set DRAW_USE_LLVM=0. So I think there is nothing wrong with Mesa provided by openSUSE 12.1. What else can be wrong? What else I can try? Any tips? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c7 --- Comment #7 from Rafał Miłecki <zajec5@gmail.com> 2012-02-26 11:09:57 UTC --- I've decided to downgrade llvm. I've downloaded sources of version 2.8 (instead of 3.0) and compiled and installed it. I think everything went fine, now I get:
llvm-config --version 2.8
and mesa's config displays: llvm: yes llvm-config: /usr/bin/llvm-config llvm-version: 2.8 After downgrading llvm, I've recompiled Mesa (same version and same config as earlier). I installed it and wine started to work! I can finally play Diablo II without DRAW_USE_LLVM=0. I guess we should bisect llvm, unfortunately this project doesn't use git (no "git bisect") and recompiling whole llvm and mesa can take a lot of time. But at least we have something to start with. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c8 --- Comment #8 from Marcus Meissner <meissner@suse.com> 2012-02-26 11:33:40 UTC --- mesa uses llvm on buildtime, just swapping llvm out in the system is not going to work ... So you need to rebuild Mesa. So Rafal, you got the 12.1 Mesa compiled with LLVM 2.8? and this helped? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c9 --- Comment #9 from Rafał Miłecki <zajec5@gmail.com> 2012-02-26 12:06:03 UTC --- (In reply to comment #8)
mesa uses llvm on buildtime, just swapping llvm out in the system is not going to work ... So you need to rebuild Mesa.
So Rafal, you got the 12.1 Mesa compiled with LLVM 2.8? and this helped?
Yes, I'm recompiling whole mesa: make clean; make distclean; make realclean /autogen.sh --prefix=/usr --with-gallium-drivers=r600 --with-dri-drivers= make -j 4 sudo make install every time I change (upgrade/downgrade) llvm. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c10 vincent lejeune <vljn@ovi.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |vljn@ovi.com --- Comment #10 from vincent lejeune <vljn@ovi.com> 2012-02-27 06:29:34 UTC --- Do you have the bug with Mesa 8.0.1 ? Yast 1 Click install http://software.opensuse.org/ymp/X11:XOrg/openSUSE_12.1/Mesa-libGL1.ymp?base... -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c11 --- Comment #11 from Rafał Miłecki <zajec5@gmail.com> 2012-02-28 09:05:24 UTC --- Do you have the bug with Mesa 8.0.1 ?(In reply to comment #10)
Do you have the bug with Mesa 8.0.1 ?
Please take a look at comment #6 - I'm using Mesa git. I'm quite sure git master contains every patch that landed in 8.0.1. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c12 --- Comment #12 from vincent lejeune <vljn@ovi.com> 2012-02-28 19:39:48 UTC --- I have issues installing Steam - in fact it quietly crashes when trying to login -on a 64 bits system. Did you do something special to get it working ? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c13 --- Comment #13 from Marcus Meissner <meissner@suse.com> 2012-02-28 23:07:18 UTC --- @vincent: if you have unrelated problems, PLEASE open new bugreports. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c14 --- Comment #14 from vincent lejeune <vljn@ovi.com> 2012-02-28 23:40:32 UTC --- Sorry for unrelated message. I have reproduced the bug with Diablo 2 demo with llvmp, Mesa 8.0.1, and Opensuse 32 bits. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c15 --- Comment #15 from Rafał Miłecki <zajec5@gmail.com> 2012-02-29 06:05:29 UTC --- vincent: as I said, the workaround is to: 1) Install LLVM 2.9 stable (because 3.0 contains bug/issue) 2) Recompile Mesa on your own I don't really recommend doing that as you can break your system consistency. I suggest you waiting few days, I hopefully will find the breaking commit and we will be able to really fix this issue (with the help of LLVM/Mesa team). I've spent last day compiling LLVM from git looking for a single bad commit. Without a success. Then I realized compiling from git/svn doesn't set "--enable-optimized" by default. Today I'm testing git commits again, right now I've 11'000 revisions left to bisect. It's a little problematic as API changed many times between 2.9 and 3.0 and sometimes I've to fix Mesa build on my own. But hopefully today/tomorrow I'll finish the process. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c16 --- Comment #16 from vincent lejeune <vljn@ovi.com> 2012-03-01 15:44:28 UTC --- I rebuilt LLVM removing stage 2 and stage 3 steps, and the bug disappears. With stage 2 however, the crash still occurs. Apparently this is a bug inside clang (stage 1 build llvm using gcc, stage 2 build llvm using newly compiled clang). -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c17 --- Comment #17 from Rafał Miłecki <zajec5@gmail.com> 2012-03-01 16:26:16 UTC --- (In reply to comment #16)
I rebuilt LLVM removing stage 2 and stage 3 steps, and the bug disappears With stage 2 however, the crash still occurs.
Apparently this is a bug inside clang (stage 1 build llvm using gcc, stage 2 build llvm using newly compiled clang).
Nice, I didn't have any idea about "stages" in LLVM. I was just bisecting whole LLVM builds. This led me to the first bad commit: commit 42634836e999dfcb59f1f5ea50dfd33442be4b9a Author: Eric Christopher <echristo@apple.com> Date: Fri Sep 16 20:36:16 2011 +0000 Have the llvm configure process look for clang, then llvm-gcc, and then gcc on all platforms. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@139934 91177308-0d34-0410-b5e6-96231b3b80d8 I believe it matches what you say. It's some clang related issue. Let's see what Mesa and LLVM guys will say. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c18 --- Comment #18 from vincent lejeune <vljn@ovi.com> 2012-03-01 16:52:43 UTC --- What happens if you cherry pick this commit on top of LLVM 2.8 (or LLVM 2.9 if it predates this commit) ? It would be interesting if the issue was already there, just hidden by the fact that llvm was built with gcc instead of clang. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c19 --- Comment #19 from Rafał Miłecki <zajec5@gmail.com> 2012-03-01 19:17:43 UTC --- LLVM 2.8 with 42634836e999dfcb59f1f5ea50dfd33442be4b9a cherry-picked didn't compile for me: llvm[3]: Building X86.td assembly matcher with tblgen 0 tblgen 0x081b9d3b Stack dump: 0. Program arguments: /home/zajec/x/llvm-2.8/Release/bin/tblgen -I /home/zajec/x/llvm-2.8/lib/Target/X86 -I /home/zajec/x/llvm-2.8/include -I /home/zajec/x/llvm-2.8/include -I /home/zajec/x/llvm-2.8/lib/Target -gen-asm-matcher -o /home/zajec/x/llvm-2.8/lib/Target/X86/Release/X86GenAsmMatcher.inc.tmp X86.td make[3]: *** [/home/zajec/x/llvm-2.8/lib/Target/X86/Release/X86GenAsmMatcher.inc.tmp] Segmentation fault LLVM 2.9 with 42634836e999dfcb59f1f5ea50dfd33442be4b9a compiled without any problems, however Mesa compiled with that LLVM still crashes. So this bug was present already in 2.9, 42634836e999dfcb59f1f5ea50dfd33442be4b9a commit just exposed it. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c20 Ismail Donmez <idonmez@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |idonmez@suse.com AssignedTo|xorg-maintainer-bugs@forge. |idonmez@suse.com |provo.novell.com | Severity|Normal |Major --- Comment #20 from Ismail Donmez <idonmez@suse.com> 2012-03-03 12:24:24 UTC --- Disabling 3-stage bootstrap will just hide a clang bug, I would prefer a testcase so we could get this fixed. I'll see what I can do. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c Johannes Obermayr <johannesobermayr@gmx.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |johannesobermayr@gmx.de See Also| |http://bugs.winehq.org/show | |_bug.cgi?id=30052, | |https://bugs.freedesktop.or | |g/show_bug.cgi?id=41791, | |https://bugs.freedesktop.or | |g/show_bug.cgi?id=44466, | |http://llvm.org/bugs/show_b | |ug.cgi?id=12151 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c21 --- Comment #21 from Marcus Meissner <meissner@suse.com> 2012-04-10 15:03:01 UTC --- we released a llvm 3.0 and Mesa update for 12.1 can anybody check if it is still a problem? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c22 Ronny Peine <ronnypeine@gmx.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ronnypeine@gmx.de --- Comment #22 from Ronny Peine <ronnypeine@gmx.de> 2012-08-18 08:51:46 UTC --- (In reply to comment #21)
we released a llvm 3.0 and Mesa update for 12.1
can anybody check if it is still a problem?
Hi, the bug is still present on openSUSE 12.1. Tested with various 3D applications. Versions: Mesa-7.11-11.4.2 llvm-3.0-1.8.1 Kind regards. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c23 Johannes Obermayr <johannesobermayr@gmx.de> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.freedesktop.or | |g/show_bug.cgi?id=48351 --- Comment #23 from Johannes Obermayr <johannesobermayr@gmx.de> 2012-08-24 11:30:56 UTC --- I assume the reason is here: https://bugs.freedesktop.org/show_bug.cgi?id=48351 But my skills lacks to get known what fpme->current_variant->jit_func does or should do ... -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=747333 https://bugzilla.novell.com/show_bug.cgi?id=747333#c24 Johannes Obermayr <johannesobermayr@gmx.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |CLOSED Resolution| |UPSTREAM --- Comment #24 from Johannes Obermayr <johannesobermayr@gmx.de> 2012-10-31 18:43:56 UTC --- Fixed upstream. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com