PetscOptionsPushCreateViewerOff#

sets if PetscOptionsCreateViewer(), PetscOptionsViewer(), and PetscOptionsCreateViewers() return viewers.

Synopsis#

Logically Collective

Input Parameter#

Options Database Key#

  • -viewfromoptions (on|off) - Enable or disable PetscOptionsCreateViewer() and XXXViewFromOptions() calls, for applications with many small solves turn this off

Note#

Calling XXXViewFromOptions in an inner loop can be expensive. This can appear, for example, when using many small subsolves. Call this function to control viewer creation in PetscOptionsCreateViewer(), thus removing the expensive XXXViewFromOptions calls.

Developer Notes#

Instead of using this approach, the calls to PetscOptionsCreateViewer() can be moved into XXXSetFromOptions()

See Also#

Viewers: Looking at PETSc Objects, PetscOptionsCreateViewer(), PetscOptionsPopCreateViewerOff()

Level#

developer

Location#

src/sys/classes/viewer/interface/viewreg.c


Index of all Viewer routines
Table of Contents for all manual pages
Index of all manual pages