all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#25953: [Mesa] Very low Gallium performance compared to Trisquel
@ 2017-03-03  8:04 Matthew Brooks
  2017-03-03 17:53 ` Leo Famulari
  0 siblings, 1 reply; 15+ messages in thread
From: Matthew Brooks @ 2017-03-03  8:04 UTC (permalink / raw)
  To: 25953

This came up in a help-guix thread, and Ricardo Wurmus asked me to
post here requesting that Mesa be built with LLVM to improve Gallium's
performance.

The original post is here:
https://lists.gnu.org/archive/html/help-guix/2017-02/msg00141.html
but in short, when running GuixSD on my system, Gnome is unusably
slow, and while LXDE is usable, trying to play even 480p videos
results in a slideshow rather than a video.
On Trisquel though, even though it's also blobless and using Gallium,
the performance is vastly better, and even HD videos play fine.

I'm not really familiar with stuff this deep into the system, so if
there's any extra info you all need then just let me know and I'll be
happy to provide it.


Anyway, thanks for your time, and all the work you all are doing.

Matthew F. Brooks

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [Mesa] Very low Gallium performance compared to Trisquel
  2017-03-03  8:04 bug#25953: [Mesa] Very low Gallium performance compared to Trisquel Matthew Brooks
@ 2017-03-03 17:53 ` Leo Famulari
  2017-03-03 18:15   ` Marius Bakke
  0 siblings, 1 reply; 15+ messages in thread
From: Leo Famulari @ 2017-03-03 17:53 UTC (permalink / raw)
  To: Matthew Brooks; +Cc: 25953

On Fri, Mar 03, 2017 at 02:04:14AM -0600, Matthew Brooks wrote:
> This came up in a help-guix thread, and Ricardo Wurmus asked me to
> post here requesting that Mesa be built with LLVM to improve Gallium's
> performance.
> 
> The original post is here:
> https://lists.gnu.org/archive/html/help-guix/2017-02/msg00141.html
> but in short, when running GuixSD on my system, Gnome is unusably
> slow, and while LXDE is usable, trying to play even 480p videos
> results in a slideshow rather than a video.
> On Trisquel though, even though it's also blobless and using Gallium,
> the performance is vastly better, and even HD videos play fine.
> 
> I'm not really familiar with stuff this deep into the system, so if
> there's any extra info you all need then just let me know and I'll be
> happy to provide it.

I used to use GuixSD's GNOME on my Thinkpad x200s but, at some point, it
started to have the problem you describe. I decided to stop using GNOME
instead of investigating the bug because I had no idea where to start
looking.

But if I can help change some packages and test the changes, please let
me know how.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [Mesa] Very low Gallium performance compared to Trisquel
  2017-03-03 17:53 ` Leo Famulari
@ 2017-03-03 18:15   ` Marius Bakke
       [not found]     ` <CAPi-ftoekP+QWmy=BRyKJr5YWpkwK0eFu0KmCHfxwZC78sJTjA@mail.gmail.com>
  2017-03-06 14:35     ` bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers Ricardo Wurmus
  0 siblings, 2 replies; 15+ messages in thread
From: Marius Bakke @ 2017-03-03 18:15 UTC (permalink / raw)
  To: Leo Famulari, Matthew Brooks; +Cc: 25953

[-- Attachment #1: Type: text/plain, Size: 1426 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Fri, Mar 03, 2017 at 02:04:14AM -0600, Matthew Brooks wrote:
>> This came up in a help-guix thread, and Ricardo Wurmus asked me to
>> post here requesting that Mesa be built with LLVM to improve Gallium's
>> performance.
>> 
>> The original post is here:
>> https://lists.gnu.org/archive/html/help-guix/2017-02/msg00141.html
>> but in short, when running GuixSD on my system, Gnome is unusably
>> slow, and while LXDE is usable, trying to play even 480p videos
>> results in a slideshow rather than a video.
>> On Trisquel though, even though it's also blobless and using Gallium,
>> the performance is vastly better, and even HD videos play fine.
>> 
>> I'm not really familiar with stuff this deep into the system, so if
>> there's any extra info you all need then just let me know and I'll be
>> happy to provide it.
>
> I used to use GuixSD's GNOME on my Thinkpad x200s but, at some point, it
> started to have the problem you describe. I decided to stop using GNOME
> instead of investigating the bug because I had no idea where to start
> looking.
>
> But if I can help change some packages and test the changes, please let
> me know how.

What are your hardware specs?

For testing, you could try building "mesa" with "--enable-gallium-llvm"
and maybe "--enable-llvm-shared-libs".

It could be interesting to see how Trisquel builds mesa.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: Fwd: bug#25953: [Mesa] Very low Gallium performance compared to Trisquel
       [not found]     ` <CAPi-ftoekP+QWmy=BRyKJr5YWpkwK0eFu0KmCHfxwZC78sJTjA@mail.gmail.com>
@ 2017-03-03 22:22       ` Matthew Brooks
  0 siblings, 0 replies; 15+ messages in thread
From: Matthew Brooks @ 2017-03-03 22:22 UTC (permalink / raw)
  To: 25953

Forgot to CC this when sending.


---------- Forwarded message ----------
From: Matthew Brooks <matthewfbrooks@gmail.com>
Date: Fri, Mar 3, 2017 at 4:11 PM
Subject: Re: bug#25953: [Mesa] Very low Gallium performance compared to Trisquel
To: Marius Bakke <mbakke@fastmail.com>


> What are your hardware specs?

I'm using an AMD Phenom II X6 1100T (~3GHz, 6 cores). I've got 16 GB
of RAM. My graphics card is an Nvidia Geforce 1060 with 6GB of VRAM.
The screen is a 1920x1080 monitor from Asus.

> For testing, you could try building "mesa" with "--enable-gallium-llvm"
> and maybe "--enable-llvm-shared-libs".

How would I do that? I tried making a copy of gl.scm (which contains
the definition for the standard mesa package), and stripping out the
non-mesa packages and adding those compile flags, but when I did "guix
package --install-from-file=./gl.scm", it didn't actually seem to do
anything.
Before that I also tried "guix package --install mesa
--enable-gallium-llvm --enable-llvm-shared-libs", but it (predictably,
in hindsight) gave an "unrecognized option" error.

Anyway, thanks for your help, and have a nice day!

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-03 18:15   ` Marius Bakke
       [not found]     ` <CAPi-ftoekP+QWmy=BRyKJr5YWpkwK0eFu0KmCHfxwZC78sJTjA@mail.gmail.com>
@ 2017-03-06 14:35     ` Ricardo Wurmus
  2017-03-06 14:58       ` Thompson, David
  2017-03-07  7:04       ` Mark H Weaver
  1 sibling, 2 replies; 15+ messages in thread
From: Ricardo Wurmus @ 2017-03-06 14:35 UTC (permalink / raw)
  To: 25953

Fixes <https://bugs.gnu.org/25953>.

* gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
[arguments]: Build LLVM Gallium drivers.
---
 gnu/packages/gl.scm | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm
index a3862f1ec..fff0e9ab3 100644
--- a/gnu/packages/gl.scm
+++ b/gnu/packages/gl.scm
@@ -4,7 +4,7 @@
 ;;; Copyright © 2014, 2016 David Thompson <davet@gnu.org>
 ;;; Copyright © 2014, 2015, 2016, 2017 Mark H Weaver <mhw@netris.org>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
-;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2016 David Thompson <davet@gnu.org>
 ;;;
 ;;; This file is part of GNU Guix.
@@ -33,6 +33,7 @@
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages llvm)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
   #:use-module (gnu packages video)
@@ -230,14 +231,15 @@ also known as DXTn or DXTC) for Mesa.")
         ("makedepend" ,makedepend)
         ("presentproto" ,presentproto)
         ("s2tc" ,s2tc)
+        ("llvm" ,llvm)
         ("wayland" ,wayland)))
     (native-inputs
       `(("pkg-config" ,pkg-config)
         ("python" ,python-2)))
     (arguments
      `(#:configure-flags
-       '(;; drop r300 from default gallium drivers, as it requires llvm
-         "--with-gallium-drivers=r600,svga,swrast,nouveau,virgl"
+       '("--with-gallium-drivers=i915,r300,r600,svga,swrast,nouveau,virgl"
+         "--enable-gallium-llvm"
          ;; Enable various optional features.  TODO: opencl requires libclc,
          ;; omx requires libomxil-bellagio
          "--with-egl-platforms=x11,drm,wayland"
-- 
2.12.0

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-06 14:35     ` bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers Ricardo Wurmus
@ 2017-03-06 14:58       ` Thompson, David
  2017-03-06 16:46         ` Danny Milosavljevic
  2017-03-06 18:55         ` Leo Famulari
  2017-03-07  7:04       ` Mark H Weaver
  1 sibling, 2 replies; 15+ messages in thread
From: Thompson, David @ 2017-03-06 14:58 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 25953

On Mon, Mar 6, 2017 at 9:35 AM, Ricardo Wurmus <rekado@elephly.net> wrote:
> Fixes <https://bugs.gnu.org/25953>.
>
> * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
> [arguments]: Build LLVM Gallium drivers.

LGTM. I think this patch would need to be applied somewhere other than
master to avoid mass rebuilds.

- Dave

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-06 14:58       ` Thompson, David
@ 2017-03-06 16:46         ` Danny Milosavljevic
  2017-03-06 18:55         ` Leo Famulari
  1 sibling, 0 replies; 15+ messages in thread
From: Danny Milosavljevic @ 2017-03-06 16:46 UTC (permalink / raw)
  To: Thompson, David; +Cc: 25953

Also, there's a newer Mesa version available (and the Mesa version numbers are now year-based). So if we change it anyway we might want to update it.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-06 14:58       ` Thompson, David
  2017-03-06 16:46         ` Danny Milosavljevic
@ 2017-03-06 18:55         ` Leo Famulari
  2017-03-06 21:37           ` Ricardo Wurmus
  1 sibling, 1 reply; 15+ messages in thread
From: Leo Famulari @ 2017-03-06 18:55 UTC (permalink / raw)
  To: Thompson, David; +Cc: 25953

On Mon, Mar 06, 2017 at 09:58:04AM -0500, Thompson, David wrote:
> On Mon, Mar 6, 2017 at 9:35 AM, Ricardo Wurmus <rekado@elephly.net> wrote:
> > Fixes <https://bugs.gnu.org/25953>.
> >
> > * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
> > [arguments]: Build LLVM Gallium drivers.
> 
> LGTM. I think this patch would need to be applied somewhere other than
> master to avoid mass rebuilds.

Since core-updates is (still) in the early stages, we could put it
there.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-06 18:55         ` Leo Famulari
@ 2017-03-06 21:37           ` Ricardo Wurmus
  0 siblings, 0 replies; 15+ messages in thread
From: Ricardo Wurmus @ 2017-03-06 21:37 UTC (permalink / raw)
  To: Leo Famulari; +Cc: 25953


Leo Famulari <leo@famulari.name> writes:

> On Mon, Mar 06, 2017 at 09:58:04AM -0500, Thompson, David wrote:
>> On Mon, Mar 6, 2017 at 9:35 AM, Ricardo Wurmus <rekado@elephly.net> wrote:
>> > Fixes <https://bugs.gnu.org/25953>.
>> >
>> > * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
>> > [arguments]: Build LLVM Gallium drivers.
>> 
>> LGTM. I think this patch would need to be applied somewhere other than
>> master to avoid mass rebuilds.
>
> Since core-updates is (still) in the early stages, we could put it
> there.

Done.  It’s now on core-updates (093c6f8bc).  I hope this really does
fix the performance problems.

-- 
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-06 14:35     ` bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers Ricardo Wurmus
  2017-03-06 14:58       ` Thompson, David
@ 2017-03-07  7:04       ` Mark H Weaver
  2017-03-07 13:29         ` Ricardo Wurmus
  1 sibling, 1 reply; 15+ messages in thread
From: Mark H Weaver @ 2017-03-07  7:04 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 25953

Ricardo Wurmus <rekado@elephly.net> writes:

> Fixes <https://bugs.gnu.org/25953>.
>
> * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
> [arguments]: Build LLVM Gallium drivers.

I'm uncomfortable adding llvm as a requirement for our most minimal X11
system, for several reasons.  Can we find a way to make this optional?

      Mark

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-07  7:04       ` Mark H Weaver
@ 2017-03-07 13:29         ` Ricardo Wurmus
  2017-03-11  1:45           ` Mark H Weaver
  0 siblings, 1 reply; 15+ messages in thread
From: Ricardo Wurmus @ 2017-03-07 13:29 UTC (permalink / raw)
  To: Mark H Weaver; +Cc: 25953


Mark H Weaver <mhw@netris.org> writes:

> Ricardo Wurmus <rekado@elephly.net> writes:
>
>> Fixes <https://bugs.gnu.org/25953>.
>>
>> * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
>> [arguments]: Build LLVM Gallium drivers.
>
> I'm uncomfortable adding llvm as a requirement for our most minimal X11
> system, for several reasons.  Can we find a way to make this optional?

Would it make sense to add a “mesa-minimal” package and a minimal
variant of xorg-server where any mesa package is rewritten to be
mesa-minimal?

--
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-07 13:29         ` Ricardo Wurmus
@ 2017-03-11  1:45           ` Mark H Weaver
  2017-03-11 10:58             ` Ludovic Courtès
       [not found]             ` <CAPi-ftq3D390s1vV1Oqagf5ut=XGeAEdrU6a_T5Q973wzMniPA@mail.gmail.com>
  0 siblings, 2 replies; 15+ messages in thread
From: Mark H Weaver @ 2017-03-11  1:45 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 25953

Ricardo Wurmus <rekado@elephly.net> writes:

> Mark H Weaver <mhw@netris.org> writes:
>
>> Ricardo Wurmus <rekado@elephly.net> writes:
>>
>>> Fixes <https://bugs.gnu.org/25953>.
>>>
>>> * gnu/packages/gl.scm (mesa)[inputs]: Add llvm.
>>> [arguments]: Build LLVM Gallium drivers.
>>
>> I'm uncomfortable adding llvm as a requirement for our most minimal X11
>> system, for several reasons.  Can we find a way to make this optional?
>
> Would it make sense to add a “mesa-minimal” package and a minimal
> variant of xorg-server where any mesa package is rewritten to be
> mesa-minimal?

Judging by the number of packages that include 'mesa' as an input, it
won't be so easy.  Search for ",mesa" in gnu/packages/*.scm, and see the
output of "guix refresh -l mesa".  The xf86-video-* packages include
'mesa' as input, and many other packages as well.

I won't block this, but I will take this opportunity to mention that for
those of us who wish to build GuixSD from source code on our own
machines, life is becoming increasingly uncomfortable as more and more
optional features are added to our core packages.  We are on a
trajectory to leave that set of users behind, as we cater primarily to
the majority who use the latest Intel machines and don't worry about the
security of either the Intel Management Engine or our build farm.

       Mark

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-11  1:45           ` Mark H Weaver
@ 2017-03-11 10:58             ` Ludovic Courtès
       [not found]             ` <CAPi-ftq3D390s1vV1Oqagf5ut=XGeAEdrU6a_T5Q973wzMniPA@mail.gmail.com>
  1 sibling, 0 replies; 15+ messages in thread
From: Ludovic Courtès @ 2017-03-11 10:58 UTC (permalink / raw)
  To: Mark H Weaver; +Cc: 25953

Mark H Weaver <mhw@netris.org> skribis:

> > Would it make sense to add a “mesa-minimal” package and a minimal
> > variant of xorg-server where any mesa package is rewritten to be
> > mesa-minimal?
>
> Judging by the number of packages that include 'mesa' as an input, it
> won't be so easy.  Search for ",mesa" in gnu/packages/*.scm, and see the
> output of "guix refresh -l mesa".  The xf86-video-* packages include
> 'mesa' as input, and many other packages as well.

We could somehow provide a way (maybe an xorg-service option) to rewrite
the package graph so that it uses mesa-minimal.  WDYT?

> I won't block this, but I will take this opportunity to mention that for
> those of us who wish to build GuixSD from source code on our own
> machines, life is becoming increasingly uncomfortable as more and more
> optional features are added to our core packages.

This is true, but it’s a problem that concerns GNU/Linux in general;
I don’t think Guix is really special in this regard.

I mean, in the good ol’ GCC 2.95 and GTK+ 2.x days, when D-Bus and its
friends didn’t exist, there was much less to build, right?  :-)

Ludo’.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
       [not found]             ` <CAPi-ftq3D390s1vV1Oqagf5ut=XGeAEdrU6a_T5Q973wzMniPA@mail.gmail.com>
@ 2017-03-15  8:58               ` Matthew Brooks
  2017-03-15 11:58                 ` Ricardo Wurmus
  0 siblings, 1 reply; 15+ messages in thread
From: Matthew Brooks @ 2017-03-15  8:58 UTC (permalink / raw)
  To: 25953

Forgot to CC the list again. :/

> life is becoming increasingly uncomfortable as more and more
> optional features are added to our core packages.  We are on a
> trajectory to leave that set of users behind, as we cater primarily to
> the majority who use the latest Intel machines and don't worry about the
> security of either the Intel Management Engine or our build farm.

I definitely wouldn't want to push GuixSD in a less libre direction,
and I can just stick with XFCE on my desktop and just watch videos on
my laptop (which has more libre friendly hardware).
I also have a flash drive running a different distro for if I ever
really want to do anything particularly hardware intensive on my
desktop, so it's no problem for me to just reboot into that on
occasion if I need to.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers.
  2017-03-15  8:58               ` Matthew Brooks
@ 2017-03-15 11:58                 ` Ricardo Wurmus
  0 siblings, 0 replies; 15+ messages in thread
From: Ricardo Wurmus @ 2017-03-15 11:58 UTC (permalink / raw)
  To: Matthew Brooks; +Cc: 25953

It looks like the latest status here (according to discussions on IRC)
is that we’ll add LLVM as a dependency to mesa only when building on
x86_64 or i686.  The LLVM Gallium drivers do not seem to be supported on
other architectures anyway.

--
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2017-03-15 11:59 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-03  8:04 bug#25953: [Mesa] Very low Gallium performance compared to Trisquel Matthew Brooks
2017-03-03 17:53 ` Leo Famulari
2017-03-03 18:15   ` Marius Bakke
     [not found]     ` <CAPi-ftoekP+QWmy=BRyKJr5YWpkwK0eFu0KmCHfxwZC78sJTjA@mail.gmail.com>
2017-03-03 22:22       ` bug#25953: Fwd: " Matthew Brooks
2017-03-06 14:35     ` bug#25953: [PATCH] gnu: mesa: Build LLVM Gallium drivers Ricardo Wurmus
2017-03-06 14:58       ` Thompson, David
2017-03-06 16:46         ` Danny Milosavljevic
2017-03-06 18:55         ` Leo Famulari
2017-03-06 21:37           ` Ricardo Wurmus
2017-03-07  7:04       ` Mark H Weaver
2017-03-07 13:29         ` Ricardo Wurmus
2017-03-11  1:45           ` Mark H Weaver
2017-03-11 10:58             ` Ludovic Courtès
     [not found]             ` <CAPi-ftq3D390s1vV1Oqagf5ut=XGeAEdrU6a_T5Q973wzMniPA@mail.gmail.com>
2017-03-15  8:58               ` Matthew Brooks
2017-03-15 11:58                 ` Ricardo Wurmus

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.