1: /*$Id: gmpre.c,v 1.29 2001/04/10 19:36:32 bsmith Exp $*/ 3: #include src/sles/ksp/impls/gmres/gmresp.h 5: #undef __FUNCT__ 7: /*@ 8: KSPGMRESSetPreAllocateVectors - Causes GMRES and FGMRES to preallocate all its 9: needed work vectors at initial setup rather than the default, which 10: is to allocate them in chunks when needed. 12: Collective on KSP 14: Input Parameter: 15: . ksp - iterative context obtained from KSPCreate 17: Options Database Key: 18: . -ksp_gmres_preallocate - Activates KSPGmresSetPreAllocateVectors() 20: Level: intermediate 22: .keywords: GMRES, preallocate, vectors 24: .seealso: KSPGMRESSetRestart(), KSPGMRESSetOrthogonalization() 25: @*/ 26: int KSPGMRESSetPreAllocateVectors(KSP ksp) 27: { 28: int ierr,(*f)(KSP); 31: PetscObjectQueryFunction((PetscObject)ksp,"KSPGMRESSetPreAllocateVectors_C",(void (**)(void))&f); 32: if (f) { 33: (*f)(ksp); 34: } 35: return(0); 36: }