escript  Revision_4925
MKL.h
Go to the documentation of this file.
1 
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2014 by University of Queensland
5 * http://www.uq.edu.au
6 *
7 * Primary Business: Queensland, Australia
8 * Licensed under the Open Software License version 3.0
9 * http://www.opensource.org/licenses/osl-3.0.php
10 *
11 * Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12 * Development 2012-2013 by School of Earth Sciences
13 * Development from 2014 by Centre for Geoscience Computing (GeoComp)
14 *
15 *****************************************************************************/
16 
17 
18 /****************************************************************************/
19 
20 /* Paso: interface to intel MKL sparse solver */
21 
22 /****************************************************************************/
23 
24 /* Copyrights by ACcESS Australia 2006 */
25 /* Author: Lutz Gross, l.gross@uq.edu.au */
26 
27 /****************************************************************************/
28 
29 #ifndef __PASO_MKL_H__
30 #define __PASO_MKL_H__
31 
32 #include "SparseMatrix.h"
33 #include "performance.h"
34 
35 namespace paso {
36 
37 #if defined(_WIN32) || defined(_WIN64)
38 #define PARDISO pardiso
39 #else
40 #define PARDISO pardiso_
41 #endif
42 
43 #ifdef MKL
44 #include "mkl_pardiso.h"
45 #endif
46 
47 
48 #define MKL_ERROR_NO 0
49 #define MKL_MTYPE_SYM -2
50 #define MKL_MTYPE_UNSYM 11
51 
52 #define MKL_REORDERING_MINIMUM_DEGREE 0
53 #define MKL_REORDERING_NESTED_DISSECTION 2
54 #define MKL_PHASE_SYMBOLIC_FACTORIZATION 11
55 #define MKL_PHASE_FACTORIZATION 22
56 #define MKL_PHASE_SOLVE 33
57 #define MKL_PHASE_RELEASE_MEMORY -1
58 
59 /* extern int PARDISO
60 # (void *, int *, int *, int *, int *, int *,
61 # double *, int *, int *, int *, int *, int *,
62 # int *, double *, double *, int *);
63 */
64 
65 
66 void MKL_free(SparseMatrix* A);
67 void MKL_solve(SparseMatrix_ptr A, double* out, double* in, index_t reordering,
68  dim_t numRefinements, bool verbose);
69 
70 } // namespace paso
71 
72 #endif // __PASO_MKL_H__
73 
boost::shared_ptr< SparseMatrix > SparseMatrix_ptr
Definition: SparseMatrix.h:35
void MKL_free(SparseMatrix *A)
Definition: MKL.cpp:34
int index_t
Definition: types.h:25
void MKL_solve(SparseMatrix_ptr A, double *out, double *in, index_t reordering, dim_t numRefinements, bool verbose)
Definition: MKL.cpp:65
int dim_t
Definition: types.h:24