Skip to content

Commit

Permalink
Merge Pull Request #4719 from jjellio/Trilinos/jje/muelu-matvecdriver…
Browse files Browse the repository at this point in the history
…-magma

Automatically Merged using Trilinos Pull Request AutoTester
PR Title: MueLu: Add MagmaSparse support to matvec driver
PR Author: jjellio
  • Loading branch information
trilinos-autotester authored Mar 27, 2019
2 parents 75eec6e + 1b2ab3e commit c044193
Show file tree
Hide file tree
Showing 6 changed files with 292 additions and 98 deletions.
1 change: 1 addition & 0 deletions TPLsList.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@ TRIBITS_REPOSITORY_DEFINE_TPLS(
ViennaCL "cmake/TPLs/" EX
Avatar "cmake/TPLs/" EX
pebbl "cmake/TPLs/" EX
MAGMASparse "cmake/TPLs/" EX
)

# NOTES:
Expand Down
61 changes: 61 additions & 0 deletions cmake/TPLs/FindTPLMAGMASparse.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# @HEADER
# ************************************************************************
#
# Trilinos: An Object-Oriented Solver Framework
# Copyright (2001) Sandia Corporation
#
#
# Copyright (2001) Sandia Corporation. Under the terms of Contract
# DE-AC04-94AL85000, there is a non-exclusive license for use of this
# work by or on behalf of the U.S. Government. Export of this program
# may require a license from the United States Government.
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
#
# 3. Neither the name of the Corporation nor the names of the
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
# PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
# LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# NOTICE: The United States Government is granted for itself and others
# acting on its behalf a paid-up, nonexclusive, irrevocable worldwide
# license in this data to reproduce, prepare derivative works, and
# perform publicly and display publicly. Beginning five (5) years from
# July 25, 2001, the United States Government is granted for itself and
# others acting on its behalf a paid-up, nonexclusive, irrevocable
# worldwide license in this data to reproduce, prepare derivative works,
# distribute copies to the public, perform publicly and display
# publicly, and to permit others to do so.
#
# NEITHER THE UNITED STATES GOVERNMENT, NOR THE UNITED STATES DEPARTMENT
# OF ENERGY, NOR SANDIA CORPORATION, NOR ANY OF THEIR EMPLOYEES, MAKES
# ANY WARRANTY, EXPRESS OR IMPLIED, OR ASSUMES ANY LEGAL LIABILITY OR
# RESPONSIBILITY FOR THE ACCURACY, COMPLETENESS, OR USEFULNESS OF ANY
# INFORMATION, APPARATUS, PRODUCT, OR PROCESS DISCLOSED, OR REPRESENTS
# THAT ITS USE WOULD NOT INFRINGE PRIVATELY OWNED RIGHTS.
#
# ************************************************************************
# @HEADER


TRIBITS_TPL_FIND_INCLUDE_DIRS_AND_LIBRARIES( MAGMASparse
REQUIRED_HEADERS magmasparse.h
REQUIRED_LIBS_NAMES magma_sparse magma
)

2 changes: 1 addition & 1 deletion packages/muelu/cmake/Dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ SET(LIB_OPTIONAL_DEP_PACKAGES Amesos Amesos2 Epetra EpetraExt Teko
SET(TEST_REQUIRED_DEP_PACKAGES )
SET(TEST_OPTIONAL_DEP_PACKAGES AztecOO Galeri Belos Pamgen)
SET(LIB_REQUIRED_DEP_TPLS BLAS LAPACK)
SET(LIB_OPTIONAL_DEP_TPLS Boost MATLAB AmgX CGAL ViennaCL MKL Avatar CUSPARSE)
SET(LIB_OPTIONAL_DEP_TPLS Boost MATLAB AmgX CGAL ViennaCL MKL Avatar CUSPARSE MAGMASparse)
SET(TEST_REQUIRED_DEP_TPLS)
SET(TEST_OPTIONAL_DEP_TPLS)
2 changes: 2 additions & 0 deletions packages/muelu/cmake/MueLu_config.hpp.in
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@

#cmakedefine HAVE_MUELU_CUSPARSE

#cmakedefine HAVE_MUELU_MAGMASPARSE

/* Flags for active Tpetra nodes if Tpetra is enabled */
#cmakedefine HAVE_MUELU_SERIAL
#cmakedefine HAVE_MUELU_PTHREAD
Expand Down
23 changes: 9 additions & 14 deletions packages/muelu/test/scaling/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -415,22 +415,17 @@ IF (${PACKAGE_NAME}_ENABLE_Experimental AND ${PACKAGE_NAME}_ENABLE_Tpetra)
COMM serial mpi
)

TRIBITS_ADD_EXECUTABLE(
MatvecKernelDriver
SOURCES MatvecKernelDriver.cpp
COMM serial mpi
)


TRIBITS_ADD_TEST(
MatvecKernelDriver
NAME "MatvecKernelDriver"
ARGS "--linAlgebra=Tpetra"
NUM_MPI_PROCS 1
COMM serial mpi
)
ENDIF()
ENDIF()


# remove this from Experimental it requires Galeri + Tpetra
IF (${PACKAGE_NAME}_ENABLE_Tpetra)
TRIBITS_ADD_EXECUTABLE(
MatvecKernelDriver
SOURCES MatvecKernelDriver.cpp
COMM serial mpi
)
ENDIF()

ENDIF() # Galeri
Loading

0 comments on commit c044193

Please sign in to comment.