Bug 91828 - R600 LLVM Assertion in Instructions.cpp:1499
Summary: R600 LLVM Assertion in Instructions.cpp:1499
Status: RESOLVED WONTFIX
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/Gallium/r600 (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: Default DRI bug account
QA Contact: Default DRI bug account
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-08-31 20:23 UTC by iive
Modified: 2015-09-09 08:52 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Log of running Xonotic with R600_DEBUG=llvm,ps,vs. The last shader causes assertion. (352.05 KB, text/plain)
2015-08-31 20:23 UTC, iive
Details

Description iive 2015-08-31 20:23:15 UTC
Created attachment 118020 [details]
Log of running Xonotic with R600_DEBUG=llvm,ps,vs. The last shader causes assertion.

This bug happen with wide variety of games. I managed to reproduce it with the free Xonotic v0.8.1. The exact command is
`R600_DEBUG=llvm,ps,vs ./xonotic-linux32-glx`.
(Then start the first single player map. Crash happens at first in-game frame.)

The error I get is:
---
xonotic-linux32-glx: Instructions.cpp:1499: llvm::InsertElementInst::InsertElementInst(llvm::Value *, llvm::Value *, llvm::Value *, const llvm::Twine &, llvm::Instruction *): Assertion `isValidOperands(Vec, Elt, Index) && "Invalid insertelement instruction operands!"' failed.
---

I've obtained that error by compiling debug versions of LLVM 3.6.2 and current git of Mesa. Unfortunately the backtrace doesn't produce any relevant info.

I'm reporting the bug here, because the error happens during the phase where TGSI code is translated into the intrinsics that LLVM understand. I do not see llvm intrinsics code for the last TGSI shader, so I cannot reproduce the crash with `llc`. I think it is quite likely that the problem is caused by some LLVM API change, that have not been reflected in Mesa.

I know that R600 LLVM is not under active development. However at the moment that code is crashing on regular basis. Mesa should be able to work with any recent LLVM release and 3.6.2 is the latest current release. If you do not intend to maintain it, then you might consider removing it.

I would prefer the bug(s) to be fixed. Nine exposes quite a number of SB bugs and having other options is always good for testing.
Comment 1 Michel Dänzer 2015-09-09 08:52:18 UTC
(In reply to iive from comment #0)
> I know that R600 LLVM is not under active development. However at the moment
> that code is crashing on regular basis. Mesa should be able to work with any
> recent LLVM release and 3.6.2 is the latest current release. If you do not
> intend to maintain it, then you might consider removing it.

It's why it's disabled by default both at build time and at runtime. At this point, it should only be enabled by someone who wants to work on fixing it.


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.