Tpetra Matrix/Vector Services Version of the Day
Tpetra_VbrMatrix.cpp
00001 /*
00002 // @HEADER
00003 // ***********************************************************************
00004 // 
00005 //          Tpetra: Templated Linear Algebra Services Package
00006 //                 Copyright (2008) Sandia Corporation
00007 // 
00008 // Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00009 // the U.S. Government retains certain rights in this software.
00010 // 
00011 // Redistribution and use in source and binary forms, with or without
00012 // modification, are permitted provided that the following conditions are
00013 // met:
00014 //
00015 // 1. Redistributions of source code must retain the above copyright
00016 // notice, this list of conditions and the following disclaimer.
00017 //
00018 // 2. Redistributions in binary form must reproduce the above copyright
00019 // notice, this list of conditions and the following disclaimer in the
00020 // documentation and/or other materials provided with the distribution.
00021 //
00022 // 3. Neither the name of the Corporation nor the names of the
00023 // contributors may be used to endorse or promote products derived from
00024 // this software without specific prior written permission.
00025 //
00026 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
00027 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00028 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00029 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
00030 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00031 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00032 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
00033 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
00034 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
00035 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
00036 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00037 //
00038 // Questions? Contact Michael A. Heroux (maherou@sandia.gov) 
00039 // 
00040 // ************************************************************************
00041 // @HEADER
00042 */
00043 
00044 #include "Tpetra_VbrMatrix.hpp"
00045 
00046 #ifdef HAVE_TPETRA_EXPLICIT_INSTANTIATION
00047 
00048 #include "Tpetra_VbrMatrix_def.hpp"
00049 
00050 #include <Kokkos_SerialNode.hpp>
00051 #if defined(HAVE_KOKKOS_TBB)
00052 #  include <Kokkos_TBBNode.hpp>
00053 #endif
00054 #if defined(HAVE_KOKKOS_THREADPOOL)
00055 #  include <Kokkos_TPINode.hpp>
00056 #endif
00057 #if defined(HAVE_KOKKOS_OPENMP)
00058 #  include <Kokkos_OpenMPNode.hpp>
00059 #endif
00060 #if defined(HAVE_KOKKOS_THRUST)
00061 #  include <Kokkos_ThrustGPUNode.hpp>
00062 #endif
00063 
00064 namespace Tpetra {
00065 
00066 
00067 #if defined(HAVE_TPETRA_INST_DOUBLE)
00068   TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::SerialNode)
00069 #if defined(HAVE_KOKKOS_TBB)
00070   TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::TBBNode)
00071 #endif
00072 #if defined(HAVE_KOKKOS_THREADPOOL)
00073     TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::TPINode)
00074 #endif
00075 #if defined(HAVE_KOKKOS_OPENMP)
00076     TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::OpenMPNode)
00077 #endif
00078 #if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00079     TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::ThrustGPUNode)
00080 #endif
00081 #endif // double
00082 #if defined(HAVE_TPETRA_INST_FLOAT)
00083   TPETRA_VBRMATRIX_INSTANT(float,int,int,Kokkos::SerialNode)
00084 #if defined(HAVE_KOKKOS_TBB)
00085   TPETRA_VBRMATRIX_INSTANT(float,int,int,Kokkos::TBBNode)
00086 #endif
00087 #if defined(HAVE_KOKKOS_THREADPOOL)
00088     TPETRA_VBRMATRIX_INSTANT(float,int,int,Kokkos::TPINode)
00089 #endif
00090 #if defined(HAVE_KOKKOS_OPENMP)
00091     TPETRA_VBRMATRIX_INSTANT(float,int,int,Kokkos::OpenMPNode)
00092 #endif
00093 #if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_FLOAT)
00094     TPETRA_VBRMATRIX_INSTANT(float,int,int,Kokkos::ThrustGPUNode)
00095 #endif
00096 #endif // float
00097 #if defined(HAVE_TPETRA_INST_COMPLEX_DOUBLE)
00098   TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,int,Kokkos::SerialNode)
00099 #if defined(HAVE_KOKKOS_TBB)
00100   TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,int,Kokkos::TBBNode)
00101 #endif
00102 #if defined(HAVE_KOKKOS_THREADPOOL)
00103     TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,int,Kokkos::TPINode)
00104 #endif
00105 #if defined(HAVE_KOKKOS_OPENMP)
00106     TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,int,Kokkos::OpenMPNode)
00107 #endif
00108 // no complex on GPU support for now
00109 //#if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00110 //    TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::ThrustGPUNode)
00111 //#endif
00112 #endif // complex double
00113 #if defined(HAVE_TPETRA_INST_COMPLEX_FLOAT)
00114   TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,int,Kokkos::SerialNode)
00115 #if defined(HAVE_KOKKOS_TBB)
00116   TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,int,Kokkos::TBBNode)
00117 #endif
00118 #if defined(HAVE_KOKKOS_THREADPOOL)
00119     TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,int,Kokkos::TPINode)
00120 #endif
00121 #if defined(HAVE_KOKKOS_OPENMP)
00122     TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,int,Kokkos::OpenMPNode)
00123 #endif
00124 // no complex on GPU support for now
00125 //#if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00126 //    TPETRA_VBRMATRIX_INSTANT(double,int,int,Kokkos::ThrustGPUNode)
00127 //#endif
00128 #endif // complex float 
00129 
00130 
00131 #ifdef HAVE_TPETRA_INST_INT_LONG
00132 #if defined(HAVE_TPETRA_INST_DOUBLE)
00133   TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::SerialNode)
00134 #if defined(HAVE_KOKKOS_TBB)
00135   TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::TBBNode)
00136 #endif
00137 #if defined(HAVE_KOKKOS_THREADPOOL)
00138     TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::TPINode)
00139 #endif
00140 #if defined(HAVE_KOKKOS_OPENMP)
00141     TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::OpenMPNode)
00142 #endif
00143 #if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00144     TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::ThrustGPUNode)
00145 #endif
00146 #endif // double
00147 #if defined(HAVE_TPETRA_INST_FLOAT)
00148   TPETRA_VBRMATRIX_INSTANT(float,int,long,Kokkos::SerialNode)
00149 #if defined(HAVE_KOKKOS_TBB)
00150   TPETRA_VBRMATRIX_INSTANT(float,int,long,Kokkos::TBBNode)
00151 #endif
00152 #if defined(HAVE_KOKKOS_THREADPOOL)
00153     TPETRA_VBRMATRIX_INSTANT(float,int,long,Kokkos::TPINode)
00154 #endif
00155 #if defined(HAVE_KOKKOS_OPENMP)
00156     TPETRA_VBRMATRIX_INSTANT(float,int,long,Kokkos::OpenMPNode)
00157 #endif
00158 #if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_FLOAT)
00159     TPETRA_VBRMATRIX_INSTANT(float,int,long,Kokkos::ThrustGPUNode)
00160 #endif
00161 #endif // float
00162 #if defined(HAVE_TPETRA_INST_COMPLEX_DOUBLE)
00163   TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,long,Kokkos::SerialNode)
00164 #if defined(HAVE_KOKKOS_TBB)
00165   TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,long,Kokkos::TBBNode)
00166 #endif
00167 #if defined(HAVE_KOKKOS_THREADPOOL)
00168     TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,long,Kokkos::TPINode)
00169 #endif
00170 #if defined(HAVE_KOKKOS_OPENMP)
00171     TPETRA_VBRMATRIX_INSTANT(std::complex<double>,int,long,Kokkos::OpenMPNode)
00172 #endif
00173 // no complex on GPU support for now
00174 //#if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00175 //    TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::ThrustGPUNode)
00176 //#endif
00177 #endif // complex double
00178 #if defined(HAVE_TPETRA_INST_COMPLEX_FLOAT)
00179   TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,long,Kokkos::SerialNode)
00180 #if defined(HAVE_KOKKOS_TBB)
00181   TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,long,Kokkos::TBBNode)
00182 #endif
00183 #if defined(HAVE_KOKKOS_THREADPOOL)
00184     TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,long,Kokkos::TPINode)
00185 #endif
00186 #if defined(HAVE_KOKKOS_OPENMP)
00187     TPETRA_VBRMATRIX_INSTANT(std::complex<float>,int,long,Kokkos::OpenMPNode)
00188 #endif
00189 // no complex on GPU support for now
00190 //#if defined(HAVE_KOKKOS_THRUST) && defined(HAVE_KOKKOS_CUDA_DOUBLE)
00191 //    TPETRA_VBRMATRIX_INSTANT(double,int,long,Kokkos::ThrustGPUNode)
00192 //#endif
00193 #endif // complex float 
00194 #endif // <int,long>
00195 
00196 
00197 } // namespace Tpetra
00198 
00199 #endif // HAVE_TPETRA_EXPLICIT_INSTANTIATION
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines