Subject: Bug#775235: Bug#776911: gnome-shell: fails to start on i386 when [Mesa was] built with llvm-3.5

From: Simon McVittie <[email-masked]>
Date: Fri, 13 Mar 2015 17:35:15 +0000

On Fri, 13 Mar 2015 at 13:01:13 +0000, Simon McVittie wrote:
> Control: unmerge 775235
...
> On 09/03/15 20:57, Julien Cristau wrote:
> > On Thu, Feb 26, 2015 at 08:54:10 +0000, Simon McVittie wrote:
> >> Context for Mesa maintainers: #775235 is that gnome-shell crashes in
> >> an i386 VM with its default choice of emulated CPU, with
> >> "LLVM ERROR: Do not know how to split the result of this operator!".
> 
> I think this should go to Mesa. There are two potential patches,
> both tested by Bernhard Übelacker, with 

Sorry, that should have said: with verification from Tails developers
for the second one.

> go back to llvm-3.4:
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=775235#15
> 
> or apply an unmerged patch:
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=775235#32

    S

---

From: Michael Gilbert <[email-masked]>
Date: Wed, 15 Apr 2015 23:08:11 -0400

control: severity -1 wishlist
control: forwarded -1 https://freedesktop.org/patch/34445
control: retitle -1 mesa: use llvm's getCPUTargetFeatures() instead of
getHostCPUName()

It turns out that mesa uses llvm's getHostCPUName(), and qemu i386 by
default (correctly) reports itself as pentium2, which is assumed
non-sse2. gnome-shell uses a mesa feature that requires sse2, so it
fails at startup on qemu i386.

On llvm trunk they've implemented getCPUTargetFeatures(), which can be
used to check for specific cpu features like sse2, and that is the
long term solution to the problem:
https://llvm.org/bugs/show_bug.cgi?id=23201

In the meantime, the problem can be worked around by using a
non-default qemu cpu options.  Some examples:

$ qemu -cpu pentium3 test.img
$ kvm -cpu host test.img

Since there workarounds are straightforward I am reducing the severity.

Best wishes,
Mike