GNU bug report logs - #49096
[PATCH] gnu: petsc: Link against OpenBLAS rather than LAPACK.

Previous Next

Package: guix-patches;

Reported by: Ludovic Courtès <ludo <at> gnu.org>

Date: Fri, 18 Jun 2021 16:13:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludovic.courtes <at> inria.fr>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 49096 in the body.
You can then email your comments to 49096 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to florent.pruvost <at> inria.fr, emmanuel.agullo <at> inria.fr, guix-patches <at> gnu.org:
bug#49096; Package guix-patches. (Fri, 18 Jun 2021 16:13:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Ludovic Courtès <ludo <at> gnu.org>:
New bug report received and forwarded. Copy sent to florent.pruvost <at> inria.fr, emmanuel.agullo <at> inria.fr, guix-patches <at> gnu.org. (Fri, 18 Jun 2021 16:13:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: guix-patches <at> gnu.org
Cc: Ludovic Courtès <ludovic.courtes <at> inria.fr>
Subject: [PATCH] gnu: petsc: Link against OpenBLAS rather than LAPACK.
Date: Fri, 18 Jun 2021 18:12:04 +0200
From: Ludovic Courtès <ludovic.courtes <at> inria.fr>

OpenBLAS performs better than LAPACK, the reference implementation.
This is also consistent with the choice of BLAS/LAPACK implementations
made in most other packages.

* gnu/packages/maths.scm (petsc)[inputs]: Replace LAPACK by OPENBLAS.
[arguments]: Pass "--with-openmp=1".
---
 gnu/packages/maths.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Hi!

Usually there’s no reason to depend on the reference (“Netlib”) BLAS/LAPACK
implementations because they perform poorly.  This change is one way to
bring consistency here.

Thoughts?

Ludo’.

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index a79d546abd..8d47f91310 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -2417,7 +2417,7 @@ September 2004}")
      `(("python" ,python-2)))
     (inputs
      `(("gfortran" ,gfortran)
-       ("lapack" ,lapack)
+       ("openblas" ,openblas)
        ("superlu" ,superlu)
        ;; leaving out hdf5 and fftw, as petsc expects them to be built with mpi
        ;; leaving out opengl, as configuration seems to only be for mac
@@ -2428,6 +2428,7 @@ September 2004}")
        #:configure-flags
        `("--with-mpi=0"
          "--with-openmp=1"
+         "--with-openblas=1"
          "--with-superlu=1")
        #:make-flags
        ;; Honor (parallel-job-count) for build.  Do not use --with-make-np,
-- 
2.32.0





Information forwarded to guix-patches <at> gnu.org:
bug#49096; Package guix-patches. (Mon, 21 Jun 2021 13:02:01 GMT) Full text and rfc822 format available.

Message #8 received at 49096 <at> debbugs.gnu.org (full text, mbox):

From: Efraim Flashner <efraim <at> flashner.co.il>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: Florent Pruvost <florent.pruvost <at> inria.fr>,
 Emmanuel Agullo <emmanuel.agullo <at> inria.fr>,
 Ludovic Courtès <ludovic.courtes <at> inria.fr>,
 49096 <at> debbugs.gnu.org
Subject: Re: [bug#49096] [PATCH] gnu: petsc: Link against OpenBLAS rather
 than LAPACK.
Date: Mon, 21 Jun 2021 16:00:43 +0300
[Message part 1 (text/plain, inline)]
On Fri, Jun 18, 2021 at 06:12:04PM +0200, Ludovic Courtès wrote:
> From: Ludovic Courtès <ludovic.courtes <at> inria.fr>
> 
> OpenBLAS performs better than LAPACK, the reference implementation.
> This is also consistent with the choice of BLAS/LAPACK implementations
> made in most other packages.
> 
> * gnu/packages/maths.scm (petsc)[inputs]: Replace LAPACK by OPENBLAS.
> [arguments]: Pass "--with-openmp=1".
> ---
>  gnu/packages/maths.scm | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> Hi!
> 
> Usually there’s no reason to depend on the reference (“Netlib”) BLAS/LAPACK
> implementations because they perform poorly.  This change is one way to
> bring consistency here.
> 
> Thoughts?
> 
> Ludo’.

It sounds reasonable to me.

As long as you're open to thoughts, perhaps we want to have a discussion
(in a new thread) about renaming the input labels for lapack/openblas so
it's easier to do 'guix build foo
--with-inputs=blas=openblas-tuned-for-my-machine'

> 
> diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
> index a79d546abd..8d47f91310 100644
> --- a/gnu/packages/maths.scm
> +++ b/gnu/packages/maths.scm
> @@ -2417,7 +2417,7 @@ September 2004}")
>       `(("python" ,python-2)))
>      (inputs
>       `(("gfortran" ,gfortran)
> -       ("lapack" ,lapack)
> +       ("openblas" ,openblas)
>         ("superlu" ,superlu)
>         ;; leaving out hdf5 and fftw, as petsc expects them to be built with mpi
>         ;; leaving out opengl, as configuration seems to only be for mac
> @@ -2428,6 +2428,7 @@ September 2004}")
>         #:configure-flags
>         `("--with-mpi=0"
>           "--with-openmp=1"
> +         "--with-openblas=1"
>           "--with-superlu=1")
>         #:make-flags
>         ;; Honor (parallel-job-count) for build.  Do not use --with-make-np,
> -- 
> 2.32.0
> 
> 
> 
> 

-- 
Efraim Flashner   <efraim <at> flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#49096; Package guix-patches. (Tue, 22 Jun 2021 07:31:01 GMT) Full text and rfc822 format available.

Message #11 received at 49096 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Efraim Flashner <efraim <at> flashner.co.il>
Cc: Florent Pruvost <florent.pruvost <at> inria.fr>,
 Emmanuel Agullo <emmanuel.agullo <at> inria.fr>, 49096 <at> debbugs.gnu.org
Subject: Re: [bug#49096] [PATCH] gnu: petsc: Link against OpenBLAS rather
 than LAPACK.
Date: Tue, 22 Jun 2021 09:29:56 +0200
Hi,

Efraim Flashner <efraim <at> flashner.co.il> skribis:

> On Fri, Jun 18, 2021 at 06:12:04PM +0200, Ludovic Courtès wrote:

[...]

>> Usually there’s no reason to depend on the reference (“Netlib”) BLAS/LAPACK
>> implementations because they perform poorly.  This change is one way to
>> bring consistency here.
>> 
>> Thoughts?
>> 
>> Ludo’.
>
> It sounds reasonable to me.

Cool, thanks for taking a look.

> As long as you're open to thoughts, perhaps we want to have a discussion
> (in a new thread) about renaming the input labels for lapack/openblas so
> it's easier to do 'guix build foo
> --with-inputs=blas=openblas-tuned-for-my-machine'

We’ve very much interested in that.  However, input labels don’t have a
role here since ‘--with-input’ matches packages by name.

So most likely, we’d (1) use OpenBLAS by default everywhere instead of
netlib blas/lapack, and (2) you’d use:

  --with-input=openblas=openblas-tuned

WDYT?

Ludo’.




Reply sent to Ludovic Courtès <ludovic.courtes <at> inria.fr>:
You have taken responsibility. (Tue, 22 Jun 2021 15:58:02 GMT) Full text and rfc822 format available.

Notification sent to Ludovic Courtès <ludo <at> gnu.org>:
bug acknowledged by developer. (Tue, 22 Jun 2021 15:58:02 GMT) Full text and rfc822 format available.

Message #16 received at 49096-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludovic.courtes <at> inria.fr>
To: Efraim Flashner <efraim <at> flashner.co.il>
Cc: Florent Pruvost <florent.pruvost <at> inria.fr>,
 Emmanuel Agullo <emmanuel.agullo <at> inria.fr>, 49096-done <at> debbugs.gnu.org
Subject: Re: bug#49096: [PATCH] gnu: petsc: Link against OpenBLAS rather
 than LAPACK.
Date: Tue, 22 Jun 2021 17:57:06 +0200
Efraim Flashner <efraim <at> flashner.co.il> skribis:

> On Fri, Jun 18, 2021 at 06:12:04PM +0200, Ludovic Courtès wrote:
>> From: Ludovic Courtès <ludovic.courtes <at> inria.fr>
>> 
>> OpenBLAS performs better than LAPACK, the reference implementation.
>> This is also consistent with the choice of BLAS/LAPACK implementations
>> made in most other packages.
>> 
>> * gnu/packages/maths.scm (petsc)[inputs]: Replace LAPACK by OPENBLAS.
>> [arguments]: Pass "--with-openmp=1".

[...]

> It sounds reasonable to me.

Pushed as c7a5c3e0bba2ac3d197b219d21527863308b75dd.

Ludo'.




Information forwarded to guix-patches <at> gnu.org:
bug#49096; Package guix-patches. (Wed, 23 Jun 2021 12:36:02 GMT) Full text and rfc822 format available.

Message #19 received at 49096 <at> debbugs.gnu.org (full text, mbox):

From: zimoun <zimon.toutoune <at> gmail.com>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: Florent Pruvost <florent.pruvost <at> inria.fr>,
 Emmanuel Agullo <emmanuel.agullo <at> inria.fr>,
 Efraim Flashner <efraim <at> flashner.co.il>, 49096 <at> debbugs.gnu.org
Subject: Re: [bug#49096] [PATCH] gnu: petsc: Link against OpenBLAS rather than
 LAPACK.
Date: Wed, 23 Jun 2021 14:34:51 +0200
Hi,

On Tue, 22 Jun 2021 at 09:31, Ludovic Courtès <ludo <at> gnu.org> wrote:
> Efraim Flashner <efraim <at> flashner.co.il> skribis:
> > On Fri, Jun 18, 2021 at 06:12:04PM +0200, Ludovic Courtès wrote:
>
> [...]
>
> >> Usually there’s no reason to depend on the reference (“Netlib”) BLAS/LAPACK
> >> implementations because they perform poorly.  This change is one way to
> >> bring consistency here.
> >>
> >> Thoughts?
> >>
> >> Ludo’.
> >
> > It sounds reasonable to me.
>
> Cool, thanks for taking a look.

LGTM.


> > As long as you're open to thoughts, perhaps we want to have a discussion
> > (in a new thread) about renaming the input labels for lapack/openblas so
> > it's easier to do 'guix build foo
> > --with-inputs=blas=openblas-tuned-for-my-machine'
>
> We’ve very much interested in that.  However, input labels don’t have a
> role here since ‘--with-input’ matches packages by name.
>
> So most likely, we’d (1) use OpenBLAS by default everywhere instead of
> netlib blas/lapack, and (2) you’d use:
>
>   --with-input=openblas=openblas-tuned

Yeah, it make sense. :-)

Cheers,
simon




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 22 Jul 2021 11:24:09 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 279 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.