hypre/seq_ls/SetIFMode.c
falgout e3181f26b1 Added 64 bit feature using HYPRE_Int (see tracker [issue489] for details).
Changed MPI routines to hypre_MPI routines.
Added hypre_printf, etc. routines.
Added AUTOTEST tests to look for 'int' and 'MPI_' calls.
Added a new approach for the Fortran interface (not implemented everywhere yet).
2010-12-20 19:27:44 +00:00

49 lines
1.4 KiB
C

#include "general.h"
#include "incfact_data.h"
/*--------------------------------------------------------------------------
* SetINCFACTMode
*--------------------------------------------------------------------------*/
/*--------------------------------------------------------------------------
* Purpose: Communicate to factorization and solver routines choice of
* mode that routines should be used, in the context mainly
* of memory usage.
* Author: Andy Cleary
* Centre for Applied Scientific Computing
* Lawrence Livermore Labs
* Revision History:
* 5-22-97: AJC. Original Version.
*--------------------------------------------------------------------------*/
HYPRE_Int SetINCFACTMode( void * data, HYPRE_Int mode )
/* Mode =1: a copy of the input matrix will be made and into the
factorization routine because the
original should not be overwritten.
At the end of incfact_setup,
the copy will be discarded.
For eaither mode=1 or mode=2, the original matrix should not be
discarded or modified between incfact_setup and incfact_solve.
Mode =2: the original
input matrix can be overwritten.
*/
{
INCFACTData *incfact_data;
incfact_data = (INCFACTData *) data;
if( (mode != 1) && (mode != 2) )
{
return(-1);
}
INCFACTDataMode(incfact_data) = mode;
return(0);
}