[petsc-users] [EXTERNAL] Re: Using MAGMA subroutines instead of LAPACK in SLEPc
Satish Balay
balay at mcs.anl.gov
Thu Jun 20 15:59:59 CDT 2013
check include/petscblaslapack*.h
You might have to add a new one [or modify one of the relavent one for
your compiler] - similar to stuff in petscblaslapack_stdcall.h
Satish
On Thu, 20 Jun 2013, Harshad Sahasrabudhe wrote:
> Hi,
>
> Yes, MAGMA's API is not exactly the same. There are a few additional arguments
> in the functions related to number of GPU etc. So it cannot be directly linked
> instead of LAPACK.
>
> Hacking SLEPc/PETSc code seems to be the easier way to go. But I can't find
> the exact place where the LAPACK functions are called.
>
> Thanks,
> Harshad
>
> On 06/20/2013 04:49 PM, Teranishi, Keita wrote:
> > Hi,
> >
> > As far as I know, Magma's API us not exactly the same as the original
> > LAPACK. You may need to hack either Magma's Fortran API or internal
> > SLEPC/PETSc source.
> >
> > Thanks,
> > ---------------------------------------------
> > Keita Teranishi
> > R&D Principal Staff Member
> > Sandia National Laboratories
> > Livermore, CA 94551
> >
> > From: Matthew Knepley <knepley at gmail.com <mailto:knepley at gmail.com>>
> > Date: Thursday, June 20, 2013 1:42 PM
> > To: Harshad Sahasrabudhe <hsahasra at purdue.edu <mailto:hsahasra at purdue.edu>>
> > Cc: "petsc-users at mcs.anl.gov <mailto:petsc-users at mcs.anl.gov>"
> > <petsc-users at mcs.anl.gov <mailto:petsc-users at mcs.anl.gov>>
> > Subject: [EXTERNAL] Re: [petsc-users] Using MAGMA subroutines instead of
> > LAPACK in SLEPc
> >
> > On Thu, Jun 20, 2013 at 10:24 PM, Harshad Sahasrabudhe <hsahasra at purdue.edu
> > <mailto:hsahasra at purdue.edu>> wrote:
> >
> > Hi,
> >
> > I'm trying to run the SLEPc Eigensolver on a machine with CPUs &
> > GPUs. I found that a package called MAGMA implements LAPACK
> > functions on heterogeneous systems (CPU + GPU). MAGMA has
> > functions very similar to LAPACK so that we can go and replace a
> > call to a LAPACK function with a call to a MAGMA function.
> >
> > Now my question is, where can I apply such a hack inside
> > SLEPc/PETSc so that the Eigensolver in SLEPc actually uses MAGMA
> > functions instead of LAPACK functions? I'm using the PETSc 3.3-p6
> > and SLEPc 3.3-p3 versions.
> >
> > Any help would be greatly appreciated!
> >
> >
> > You need to do this in PETSc configure. Use --with-f-blas-lapack-lib=[<MAGMA
> > libs>]. We have never tried this, so I don't
> > know if they obey the entire interface.
> >
> > Thanks
> >
> > Thanks and Regards,
> > Harshad
> >
> >
> >
> >
> > --
> > What most experimenters take for granted before they begin their experiments
> > is infinitely more interesting than any results to which their experiments
> > lead.
> > -- Norbert Wiener
>
>
More information about the petsc-users
mailing list