Commits

Matt Knepley  committed 08fe5ca Merge

Merge branch 'knepley/remove-cxx-logging' into knepley/pylith

* knepley/remove-cxx-logging: (129 commits)
need to remove the include of petsclog.hh also
Logging: Removed C++ wrappers for logging
need to caste to idx_t * from PetscInt * for Parmetis
fix incorrect caste to superlu_dist int_t type when using 64 bit indices
Builder: More portable hosts option for mpiexec
DMPlex ex1F90: Added test of DMLabel bindings
DMLabel: Moved custom bindings to zplexlabel.c - Added DMPlexGetLabel() binding - Added DMLabelGet/Set/ClearValue() bindings
Doc: Fixed configure doc
Nightly summary: Added configure section.
Should not use strncmp() directly in PETSc code, use PetscStrncmp()
TSSetErrorIfStepFails: fix __FUNCT__
TS: fix for TSGetRHSMats_Private() in the creation of the Arhs and Brhs matrices
protect logging of objects (which uses global variables) with PETSC_USE_LOG
error handler API had been previously changed but this example was not updated to new API.
bugfix of MatCreateSeqAIJFromTriple() contributed by Nicolas Marsic <nicolas.marsic@montefiore.ulg.ac.be>
completed removing server code that was not removed in previous commit
removed PETSc webserver and configure package files that supported it
fix outdated PetscOptionsList
Fix for multiple definitions in mat/color/interface/ custom fortran bindings
manually remove old AMS code that got sucked in from master
...

  • Participants
  • Parent commits 93914fd, 58a20f3
  • Branches knepley/pylith

Comments (0)

Files changed (257)

File bin/saws/SAWs.py

+#!/usr/bin/env python
+import os, sys
+import json
+try:
+  import requests
+except:
+  raise RuntimeError('Run "sudo easy_install requests" before running this script')
+
+
+#
+#  If requests does not exist use sudo easy_install requests to install it.
+#
+host = os.getenv('SAWS_HOST')
+if not host:
+  host = 'localhost'
+port = os.getenv('SAWS_PORT')
+if not port:
+  port = '8080'
+url = 'http://'+host+':'+port+'/SAWs'
+
+
+r = requests.get(url)
+j = json.loads(r.content)
+
+#  Example that access the functions in the stack
+j = j['directories']['SAWs_ROOT_DIRECTORY']['directories']['PETSc']['directories']['Stack']['variables']['functions']['data']
+
+print j
+
+

File bin/saws/getSAWs.bash

+#!/bin/bash
+#
+#  getSAWs.bash [dir1[/dir2[/variablename]]]
+#
+#
+if [ "${SAWS_HOST}foo" == "foo" ]; then export SAWS_HOST=localhost; fi
+if [ "${SAWS_PORT}foo" == "foo" ]; then export SAWS_PORT=8080; fi
+if [ $# == 1 ]; then
+  export mem=$1;
+else 
+  export mem="*";
+fi
+
+curl --silent --show-error "${SAWS_HOST}:${SAWS_PORT}/SAWs/${mem}"

File bin/saws/getStack.bash

+#!/bin/bash
+#
+#  Returns the SAWS published PETSc stack one function per line
+#
+which jshon > /dev/null
+if [ $? != 0 ] ; then
+  echo "You must install jshon before using this app"
+  exit 1
+fi
+
+${PETSC_DIR}/bin/saws/getSAWs.bash PETSc/Stack | jshon -e directories -e Stack -e variables -e functions -e data 
+#
+
+
 testexamples_SPAI: ${TESTEXAMPLES_SPAI}
 testexamples_ADIFOR: ${TESTEXAMPLES_ADIFOR}
 testexamples_FFTW: ${TESTEXAMPLES_FFTW}
-testexamples_AMS: ${TESTEXAMPLES_AMS}
+testexamples_SAWS: ${TESTEXAMPLES_SAWS}
 testexamples_VALGRIND: ${TESTEXAMPLES_VALGRIND}
 testexamples_MATLAB: ${TESTEXAMPLES_MATLAB}
 testexamples_MUMPS: ${TESTEXAMPLES_MUMPS}
 	-@${OMAKE} testexamples_ADIFOR TESTEXAMPLES_ADIFOR=`echo ${TESTEXAMPLES_ADIFOR} | sed s/runex[0-9]*[a-z0-9_]*//g`
 buildexamples_FFTW:
 	-@${OMAKE} testexamples_FFTW TESTEXAMPLES_FFTW=`echo ${TESTEXAMPLES_FFTW} | sed s/runex[0-9]*[a-z0-9_]*//g`
-buildexamples_AMS:
-	-@${OMAKE} testexamples_AMS TESTEXAMPLES_AMS=`echo ${TESTEXAMPLES_AMS} | sed s/runex[0-9]*[a-z0-9_]*//g`
+buildexamples_SAWS:
+	-@${OMAKE} testexamples_SAWS TESTEXAMPLES_SAWS=`echo ${TESTEXAMPLES_SAWS} | sed s/runex[0-9]*[a-z0-9_]*//g`
 buildexamples_VALGRIND:
 	-@${OMAKE} testexamples_VALGRIND TESTEXAMPLES_VALGRIND=`echo ${TESTEXAMPLES_VALGRIND} | sed s/runex[0-9]*[a-z0-9_]*//g`
 buildexamples_MATLAB:

File config/BuildSystem/config/framework.py

 Notice that passing self for the last arguments means that the MPI module will
 run before the HYPRE module. Furthermore, we save the resulting object as
 self.mpi so that we may interogate it later. HYPRE can initially test whether
-MPI was indeed found using self.mpi.foundMPI. When HYPRE requires the list of
+MPI was indeed found using self.mpi.found. When HYPRE requires the list of
 MPI libraries in order to link a test object, the module can use self.mpi.lib.
 '''
 import user

File config/PETSc/packages/ams.py

-import PETSc.package
-import os
-
-class Configure(PETSc.package.NewPackage):
-  def __init__(self, framework):
-    PETSc.package.NewPackage.__init__(self, framework)
-    self.gitcommit = '3c24ac8df967279c3ceafa5c39fc230af30c63c4'
-    self.giturls   = ['https://bitbucket.org/petsc/ams.git']
-    self.download  = ['https://bitbucket.org/petsc/ams/get/master.tar.gz',
-                      'http://ftp.mcs.anl.gov/pub/petsc/externalpackages/ams-dev.tar.gz']
-    self.functions = ['AMS_Memory_create']
-    self.includes  = ['ams.h']
-    self.liblist   = [['libamspub.a']]
-    return
-
-  def setupDependencies(self, framework):
-    PETSc.package.NewPackage.setupDependencies(self, framework)
-    self.java       = framework.require('PETSc.packages.java',self)
-    self.deps       = [self.mpi]
-    return
-
-  def Install(self):
-    import os
-
-    g = open(os.path.join(self.packageDir,'makeinc'),'w')
-    g.write('AR           = '+self.setCompilers.AR+' '+self.setCompilers.AR_FLAGS+'\n')
-    g.write('RANLIB       = '+self.setCompilers.RANLIB+'\n')
-    # should use the BuildSystem defined RM, MV
-    g.write('RM           = rm -f\n')
-    g.write('MV           = mv -f\n')
-    self.setCompilers.pushLanguage('C')
-    g.write('CC           = '+self.setCompilers.getCompiler()+' '+self.setCompilers.getCompilerFlags()+'\n')
-    g.write('CLINKER      = ${CC}\n')
-    if self.setCompilers.isDarwin():
-      g.write('LINKSHARED   = ${CC} -dynamiclib -single_module -multiply_defined suppress -undefined dynamic_lookup\n')
-    else:
-      g.write('LINKSHARED   = ${CC} -dynamiclib\n')
-    if hasattr(self.java,'javac'):
-      if self.setCompilers.isDarwin():
-        g.write('JAVA_INCLUDES   =  -I/System/Library/Frameworks/JavaVM.framework/Headers/../../CurrentJDK/Headers\n')
-      else:
-        g.write('JAVA_INCLUDES   =  \n')
-      g.write('JAVAC           = '+getattr(self.java, 'javac'))
-    g.close()
-    self.setCompilers.popLanguage()
-
-    if self.installNeeded('makeinc'):
-      try:
-        self.logPrintBox('Compiling ams; this may take several minutes')
-        if not os.path.isdir(os.path.join(self.installDir,'java')):
-          os.mkdir(os.path.join(self.installDir,'java'))
-        output,err,ret = PETSc.package.NewPackage.executeShellCommand('cd '+self.packageDir+' &&  make all && cp lib/* '+os.path.join(self.installDir,'lib')+' && cp -r java/gov '+os.path.join(self.installDir,'java')+' &&  cp -f include/*.h '+os.path.join(self.installDir,self.includedir)+'/.', timeout=2500, log = self.framework.log)
-      except RuntimeError, e:
-        raise RuntimeError('Error running make on ams: '+str(e))
-      self.postInstall(output+err,'makeinc')
-    return self.installDir
-
-
-  def configureLibrary(self):
-    PETSc.package.NewPackage.configureLibrary(self)
-    self.addDefine('AMS_DIR', '"'+os.path.dirname(self.include[0])+'"')
-    self.addMakeMacro('AMS_DIR', '"'+os.path.dirname(self.include[0])+'"')

File config/PETSc/packages/saws.py

+import PETSc.package
+import os
+
+class Configure(PETSc.package.NewPackage):
+  def __init__(self, framework):
+    PETSc.package.NewPackage.__init__(self, framework)
+#    self.gitcommit = '3c24ac8df967279c3ceafa5c39fc230af30c63c4'
+    self.giturls   = ['https://bitbucket.org/saws/saws.git']
+    self.download  = ['https://bitbucket.org/saws/saws/get/master.tar.gz']
+    self.functions = ['SAWs_Register']
+    self.includes  = ['SAWs.h']
+    self.liblist   = [['libSAWs.a']]
+    self.libdir           = 'lib' # location of libraries in the package directory tree
+    self.includedir       = 'include' # location of includes in the package directory tree    return
+    self.needsMath        = 1;
+
+  def setupDependencies(self, framework):
+    PETSc.package.NewPackage.setupDependencies(self, framework)
+    return
+
+  def Install(self):
+    import os
+
+    g = open(os.path.join(self.packageDir,'makeinc'),'w')
+    g.write('AR           = '+self.setCompilers.AR+' '+self.setCompilers.AR_FLAGS+'\n')
+    g.write('RANLIB       = '+self.setCompilers.RANLIB+'\n')
+    # should use the BuildSystem defined RM, MV
+    g.write('RM           = rm -f\n')
+    g.write('MV           = mv -f\n')
+    self.setCompilers.pushLanguage('C')
+    g.write('CC           = '+self.setCompilers.getCompiler()+' '+self.setCompilers.getCompilerFlags()+'\n')
+    g.write('CLINKER      = ${CC}\n')
+    if self.setCompilers.isDarwin():
+      g.write('LINKSHARED   = ${CC} -dynamiclib -single_module -multiply_defined suppress -undefined dynamic_lookup\n')
+    else:
+      g.write('LINKSHARED   = ${CC} -dynamiclib\n')
+    g.close()
+    self.setCompilers.popLanguage()
+
+    if self.installNeeded('makeinc'):
+      try:
+        self.logPrintBox('Compiling SAWs; this may take several minutes')
+        output,err,ret = PETSc.package.NewPackage.executeShellCommand('cd '+self.packageDir+' &&  make all && cp lib/* '+os.path.join(self.installDir,'lib')+' && cp -r java/gov '+os.path.join(self.installDir,'java')+' &&  cp -f include/*.h '+os.path.join(self.installDir,self.includedir)+'/.', timeout=2500, log = self.framework.log)
+      except RuntimeError, e:
+        raise RuntimeError('Error running make on SAWs: '+str(e))
+      self.postInstall(output+err,'makeinc')
+    return self.installDir
+
+  def configureLibrary(self):
+    PETSc.package.NewPackage.configureLibrary(self)
+

File config/PETSc/packages/server.py

-import PETSc.package
-import os
-
-class Configure(PETSc.package.NewPackage):
-  def __init__(self, framework):
-    PETSc.package.NewPackage.__init__(self, framework)
-    self.lookforbydefault  = 0
-    self.functions         = 0
-    self.includes          = 0
-    self.liblist           = 0
-    self.complex           = 1
-    return
-
-  def setupDependencies(self, framework):
-    PETSc.package.NewPackage.setupDependencies(self, framework)
-    self.pthread = framework.require('PETSc.packages.pthread',self)
-    self.yaml    = framework.require('PETSc.packages.yaml',self)
-    self.ams     = framework.require('PETSc.packages.ams',self)
-    self.deps    = []
-    return
-
-  def configureLibrary(self):
-    if self.pthread.found:
-        self.addDefine('USE_PTHREAD',1)
-        self.addDefine('USE_SERVER',1)
-

File config/builder.py

                                                                   -max_cone_time 2.1e-8 -max_closure_time 1.5e-7 -max_vec_closure_time 4.7e-7'},
                                                                  {'numProcs': 1, 'args': '-interpolate -num_dof 1,0,0 -iterations 10000 \
                                                                   -max_cone_time 1.1e-8 -max_closure_time 6.5e-7 -max_vec_closure_time 1.0e-6'},
-                                                                 {'numProcs': 1, 'args': '-interpolate -refinement_limit 1.0e-5 -num_dof 1,0,0 -iterations 2 \
+                                                                 {'numProcs': 1, 'args': '-interpolate -refinement_limit 1.0e-4 -num_dof 1,0,0 -iterations 2 \
                                                                   -max_cone_time 2.1e-8 -max_closure_time 6.5e-7 -max_vec_closure_time 1.0e-6'},
                                                                  {'numProcs': 1, 'args': '-interpolate -num_fields 1 -num_components 1 -num_dof 1,0,0 -iterations 10000 \
                                                                   -max_cone_time 1.1e-8 -max_closure_time 6.5e-7 -max_vec_closure_time 1.1e-6'},
-                                                                 {'numProcs': 1, 'args': '-interpolate -refinement_limit 1.0e-5 -num_fields 1 -num_components 1 -num_dof 1,0,0 -iterations 2 \
+                                                                 {'numProcs': 1, 'args': '-interpolate -refinement_limit 1.0e-4 -num_fields 1 -num_components 1 -num_dof 1,0,0 -iterations 2 \
                                                                   -max_cone_time 2.1e-8 -max_closure_time 6.5e-7 -max_vec_closure_time 1.2e-6'},
                                                                  # 2D Simplex P_1 vector tests
                                                                  # 2D Simplex P_2 scalar tests
                                                                {'numProcs': 5, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 1 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -snes_converged_reason -snes_view', 'parser': 'Solver'},
                                                                {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view', 'parser': 'Solver'},
                                                                {'numProcs': 2, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view', 'parser': 'Solver'},
-                                                               {'numProcs': 3, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -snes_converged_reason -snes_view', 'parser': 'Solver'},
-                                                               {'numProcs': 5, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -snes_converged_reason -snes_view', 'parser': 'Solver'},
+                                                               {'numProcs': 3, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view', 'parser': 'Solver'},
+                                                               {'numProcs': 5, 'args': '-run_type full -refinement_limit 0.0625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view', 'parser': 'Solver'},
                                                                # Stokes preconditioners 30-36
                                                                #   Jacobi
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_gmres_restart 100 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_gmres_restart 100 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Block diagonal \begin{pmatrix} A & 0 \\ 0 & I \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type additive -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type additive -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Block triangular \begin{pmatrix} A & B \\ 0 & I \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type multiplicative -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type multiplicative -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Diagonal Schur complement \begin{pmatrix} A & 0 \\ 0 & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type diag -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type diag -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Upper triangular Schur complement \begin{pmatrix} A & B \\ 0 & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type upper -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type upper -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Lower triangular Schur complement \begin{pmatrix} A & B \\ 0 & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type lower -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type lower -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Full Schur complement \begin{pmatrix} I & 0 \\ B^T A^{-1} & I \end{pmatrix} \begin{pmatrix} A & 0 \\ 0 & S \end{pmatrix} \begin{pmatrix} I & A^{-1} B \\ 0 & I \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  SIMPLE \begin{pmatrix} I & 0 \\ B^T A^{-1} & I \end{pmatrix} \begin{pmatrix} A & 0 \\ 0 & B^T diag(A)^{-1} B \end{pmatrix} \begin{pmatrix} I & diag(A)^{-1} B \\ 0 & I \end{pmatrix}
-                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -fieldsplit_pressure_inner_ksp_type preonly -fieldsplit_pressure_inner_pc_type jacobi -fieldsplit_pressure_upper_ksp_type preonly -fieldsplit_pressure_upper_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -fieldsplit_pressure_inner_ksp_type preonly -fieldsplit_pressure_inner_pc_type jacobi -fieldsplit_pressure_upper_ksp_type preonly -fieldsplit_pressure_upper_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  SIMPLEC \begin{pmatrix} I & 0 \\ B^T A^{-1} & I \end{pmatrix} \begin{pmatrix} A & 0 \\ 0 & B^T rowsum(A)^{-1} B \end{pmatrix} \begin{pmatrix} I & rowsum(A)^{-1} B \\ 0 & I \end{pmatrix}
-                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -fieldsplit_pressure_inner_ksp_type preonly -fieldsplit_pressure_inner_pc_type jacobi -fieldsplit_pressure_inner_pc_jacobi_rowsum -fieldsplit_pressure_upper_ksp_type preonly -fieldsplit_pressure_upper_pc_type jacobi -fieldsplit_pressure_upper_pc_jacobi_rowsum -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -fieldsplit_pressure_inner_ksp_type preonly -fieldsplit_pressure_inner_pc_type jacobi -fieldsplit_pressure_inner_pc_jacobi_rowsum -fieldsplit_pressure_upper_ksp_type preonly -fieldsplit_pressure_upper_pc_type jacobi -fieldsplit_pressure_upper_pc_jacobi_rowsum -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                # Stokes preconditioners with MF Jacobian action 37-42
                                                                #   Jacobi
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_gmres_restart 100 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_gmres_restart 100 -pc_type jacobi -ksp_rtol 1.0e-9 -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Block diagonal \begin{pmatrix} A & 0 \\ 0 & I \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type additive -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type additive -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Block triangular \begin{pmatrix} A & B \\ 0 & I \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type multiplicative -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type multiplicative -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Diagonal Schur complement \begin{pmatrix} A & 0 \\ 0 & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type diag -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type diag -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Upper triangular Schur complement \begin{pmatrix} A & B \\ 0 & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type upper -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type upper -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Lower triangular Schur complement \begin{pmatrix} A & B \\ 0 & S \end{pmatrix}
-                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type lower -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
+                                                               #{'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type lower -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
                                                                #  Full Schur complement \begin{pmatrix} A & B \\ B^T & S \end{pmatrix}
-                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
-                                                               # 3D serial P1 tests 43-45
+                                                               {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -bc_type dirichlet -interpolate 1 -vel_petscspace_order 2 -pres_petscspace_order 1 -jacobian_mf -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_type schur -pc_fieldsplit_schur_factorization_type full -fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_velocity_ksp_type gmres -fieldsplit_velocity_pc_type lu -fieldsplit_pressure_pc_type jacobi -snes_monitor_short -ksp_monitor_short -snes_converged_reason -ksp_converged_reason -snes_view -show_solution 0', 'parser': 'Solver'},
+                                                               # 3D serial P1 tests 43-46
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type dirichlet -interpolate 0 -vel_petscspace_order 1 -pres_petscspace_order 1 -show_initial -dm_plex_print_fem 1'},
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type dirichlet -interpolate 1 -vel_petscspace_order 1 -pres_petscspace_order 1 -show_initial -dm_plex_print_fem 1'},
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0125 -bc_type dirichlet -interpolate 0 -vel_petscspace_order 1 -pres_petscspace_order 1 -show_initial -dm_plex_print_fem 1'},
     return
 
   def addResidual(self, n, res):
-    if not len(self.res) == n: raise RuntimeError('Invalid KSP residual at iterate '+str(n))
+    if not len(self.res) == n: raise RuntimeError('Invalid KSP residual '+str(res)+' at iterate '+str(n))
     self.res.append(res)
     return
 
   def __str__(self):
     return 'SNES:\n'+str(self.res)
 
+class Error(object):
+  def __init__(self, atol = 1.0e-12, rtol = 1.0e-8):
+    self.res  = 0.0
+    self.atol = atol
+    self.rtol = rtol
+    return
+
+  def setNorm(self, res):
+    self.res = res
+    return
+
+  def __eq__(self, s):
+    return all([abs(a-b) < self.atol or abs((a-b)/a) < self.rtol for a, b in [(self.res, s.res)]])
+
+  def __str__(self):
+    return 'L_2 Error:\n'+str(self.res)
+
 class SolverParser(object):
   def __init__(self, atol = 1.0e-12):
     import re
 
-    self.atol   = atol
-    self.reSNES = re.compile(r'\s*(?P<it>\d+) SNES Function norm (?P<norm>\d+\.\d+(e(\+|-)\d+)?)')
-    self.reKSP  = re.compile(r'\s*(?P<it>\d+) KSP Residual norm (?P<norm>\d+\.\d+(e(\+|-)\d+)?)')
+    self.atol    = atol
+    self.reSNES  = re.compile(r'\s*(?P<it>\d+) SNES Function norm (?P<norm>\d+\.\d+(e(\+|-)\d+)?)')
+    self.reKSP   = re.compile(r'\s*(?P<it>\d+) KSP Residual norm (?P<norm>\d+\.\d+(e(\+|-)\d+)?)')
+    self.reError = re.compile(r'L_2 Error: (?P<norm>\d+\.\d+(e(\+|-)\d+)?)')
     return
 
   def parse(self, text):
     stack  = []
     excess = []
     for line in lines:
-      mSNES = self.reSNES.match(line)
-      mKSP  = self.reKSP.match(line)
+      mSNES  = self.reSNES.match(line)
+      mKSP   = self.reKSP.match(line)
+      mError = self.reError.match(line)
       if mSNES:
         it = int(mSNES.group('it'))
         if it == 0: stack.append(SNES(atol = self.atol))
         it = int(mKSP.group('it'))
         if it == 0: stack.append(KSP(atol = self.atol))
         stack[-1].addResidual(it, float(mKSP.group('norm')))
+      elif mError:
+        o = Error(atol = self.atol)
+        o.setNorm(float(mError.group('norm')))
+        objs.append(o)
       elif line.strip().startswith('Nonlinear solve converged'):
         objs.append(stack.pop())
       elif line.strip().startswith('Linear solve converged'):
    except ValueError:
      args   = params.get('args', '')
    hosts    = ','.join(['localhost']*int(numProcs))
-   return ' '.join([self.configInfo.mpi.mpiexec, '-hosts', hosts, '-n', str(numProcs), os.path.abspath(executable), args])
+   return ' '.join([self.configInfo.mpi.mpiexec, '-host', hosts, '-n', str(numProcs), os.path.abspath(executable), args])
 
  def runTest(self, testDir, executable, testNum, replace, **params):
    '''testNum can be any string'''

File include/finclude/petscmatdef.h

 #define Mat PetscFortranAddr
 #define MatNullSpace PetscFortranAddr
 #define MatFDColoring PetscFortranAddr
+#define MatColoring PetscFortranAddr
 #endif
 #define MatPartitioning PetscFortranAddr
 #define MatCoarsen PetscFortranAddr
 #define MATCOARSEN_MIS 'mis'
 
 #define MATCOLORINGNATURAL 'natural'
-#define MATCOLORINGSL 'sl'
-#define MATCOLORINGLF 'lf'
-#define MATCOLORINGID 'id'
+#define MATCOLORINGSL  'sl'
+#define MATCOLORINGLF  'lf'
+#define MATCOLORINGID  'id'
+#define MATCOLORINGMIS 'mis'
+#define MATCOLORINGJP  'jp'
 
 #define MATORDERINGNATURAL 'natural'
 #define MATORDERINGND 'nd'

File include/finclude/petscviewerdef.h

 #define PETSCVIEWERHDF5 'hdf5'
 #define PETSCVIEWERVTK 'vtk'
 #define PETSCVIEWERMATLAB 'matlab'
-#define PETSCVIEWERAMS 'ams'
+#define PETSCVIEWERSAWS 'saws'
 
 #endif

File include/mpiuni/mpi.h

 /* In order to handle datatypes, we make them into "sizeof(raw-type)";
     this allows us to do the MPIUNI_Memcpy's easily */
 #define MPI_Datatype         int
-#define MPI_FLOAT            sizeof(float)
-#define MPI_DOUBLE           sizeof(double)
-#define MPI_LONG_DOUBLE      sizeof(long double)
-#define MPI_CHAR             sizeof(char)
-#define MPI_BYTE             sizeof(char)
-#define MPI_INT              sizeof(int)
-#define MPI_LONG             sizeof(long)
-#define MPI_LONG_LONG_INT    sizeof(long long)
-#define MPI_SHORT            sizeof(short)
-#define MPI_UNSIGNED_SHORT   sizeof(unsigned short)
-#define MPI_UNSIGNED         sizeof(unsigned)
-#define MPI_UNSIGNED_CHAR    sizeof(unsigned char)
-#define MPI_UNSIGNED_LONG    sizeof(unsigned long)
-#define MPI_UNSIGNED_LONG_LONG sizeof(unsigned long long)
-#define MPI_COMPLEX          2*sizeof(float)
-#define MPI_C_COMPLEX        2*sizeof(float)
-#define MPI_C_DOUBLE_COMPLEX 2*sizeof(double)
-#define MPI_FLOAT_INT        (sizeof(float) + sizeof(int))
-#define MPI_DOUBLE_INT       (sizeof(double) + sizeof(int))
-#define MPI_LONG_INT         (sizeof(long) + sizeof(int))
-#define MPI_SHORT_INT        (sizeof(short) + sizeof(int))
-#define MPI_2INT             (2* sizeof(int))
+#define MPI_FLOAT            (1 << 16 | sizeof(float))
+#define MPI_DOUBLE           (1 << 16 | sizeof(double))
+#define MPI_LONG_DOUBLE      (1 << 16 | sizeof(long double))
+
+#define MPI_COMPLEX          (2 << 16 | 2*sizeof(float))
+#define MPI_C_COMPLEX        (2 << 16 | 2*sizeof(float))
+#define MPI_C_DOUBLE_COMPLEX (2 << 16 | 2*sizeof(double))
+
+#define MPI_CHAR             (3 << 16 | sizeof(char))
+#define MPI_BYTE             (3 << 16 | sizeof(char))
+#define MPI_UNSIGNED_CHAR    (3 << 16 | sizeof(unsigned char))
+
+#define MPI_INT              (4 << 16 | sizeof(int))
+#define MPI_LONG             (4 << 16 | sizeof(long))
+#define MPI_LONG_LONG_INT    (4 << 16 | sizeof(long long))
+#define MPI_SHORT            (4 << 16 | sizeof(short))
+
+#define MPI_UNSIGNED_SHORT   (5 << 16 | sizeof(unsigned short))
+#define MPI_UNSIGNED         (5 << 16 | sizeof(unsigned))
+#define MPI_UNSIGNED_LONG    (5 << 16 | sizeof(unsigned long))
+#define MPI_UNSIGNED_LONG_LONG (5 << 16 | sizeof(unsigned long long))
+
+#define MPI_FLOAT_INT        (10 << 16 | (sizeof(float) + sizeof(int)))
+#define MPI_DOUBLE_INT       (11 << 16 | (sizeof(double) + sizeof(int)))
+#define MPI_LONG_INT         (12 << 16 | (sizeof(long) + sizeof(int)))
+#define MPI_SHORT_INT        (13 << 16 | (sizeof(short) + sizeof(int)))
+#define MPI_2INT             (14 << 16 | (2* sizeof(int)))
 
 #if defined(PETSC_USE_REAL___FLOAT128)
 extern MPI_Datatype MPIU___FLOAT128;
-#define MPI_sizeof(datatype) ((datatype == MPIU___FLOAT128) ? 2*sizeof(double) : datatype)
+#define MPI_sizeof(datatype) ((datatype == MPIU___FLOAT128) ? 2*sizeof(double) : (datatype) & 0xff)
 #else
-#define MPI_sizeof(datatype) (datatype)
+#define MPI_sizeof(datatype) ((datatype) & 0xff)
 #endif
 extern int MPIUNI_Memcpy(void*,const void*,int);
 
 #define MPI_MODE_WRONLY   0
 #define MPI_MODE_CREATE   0
 
-#define MPI_SUM           0
-#define MPI_MAX           0
-#define MPI_MIN           0
-#define MPI_REPLACE       0
+#define MPI_SUM           1
+#define MPI_MAX           2
+#define MPI_MIN           3
+#define MPI_REPLACE       4
+#define MPI_PROD          5
+#define MPI_LAND          6
+#define MPI_BAND          7
+#define MPI_LOR           8
+#define MPI_BOR           9
+#define MPI_LXOR          10
+#define MPI_BXOR          11
 #define MPI_ANY_TAG     (-1)
 #define MPI_DATATYPE_NULL 0
 #define MPI_PACKED        0
 #define MPI_Address(location,address) \
      (*(address) = (MPIUNI_INTPTR)(char *)(location),MPI_SUCCESS)
 #define MPI_Type_extent(datatype,extent) *(extent) = datatype
-#define MPI_Type_size(datatype,size) *(size) = datatype
+#define MPI_Type_size(datatype,size) (*(size) = (datatype) & 0xff, MPI_SUCCESS)
 #define MPI_Type_lb(datatype,displacement) \
      MPI_Abort(MPI_COMM_WORLD,0)
 #define MPI_Type_ub(datatype,displacement) \

File include/petsc-private/drawimpl.h

   PetscInt        savefilecount;
   PetscBool       savefilemovie;
   PetscBool       saveonflush;       /* save a new image for every PetscDrawFlush() called */
+  PetscBool       savesinglefile;
   void            *data;
 };
 

File include/petsc-private/kspimpl.h

   PetscErrorCode ierr;
 
   PetscFunctionBegin;
-  ierr = PetscObjectAMSTakeAccess((PetscObject)ksp);CHKERRQ(ierr);
+  ierr = PetscObjectSAWsTakeAccess((PetscObject)ksp);CHKERRQ(ierr);
   if (ksp->res_hist && ksp->res_hist_max > ksp->res_hist_len) {
     ksp->res_hist[ksp->res_hist_len++] = norm;
   }
-  ierr = PetscObjectAMSGrantAccess((PetscObject)ksp);CHKERRQ(ierr);
+  ierr = PetscObjectSAWsGrantAccess((PetscObject)ksp);CHKERRQ(ierr);
   PetscFunctionReturn(0);
 }
 

File include/petsc-private/matimpl.h

   void           *ftn_func_pointer,*ftn_func_cntx; /* serve the same purpose as *fortran_func_pointers in PETSc objects */
 };
 
+typedef struct _MatColoringOps *MatColoringOps;
+struct _MatColoringOps {
+  PetscErrorCode (*destroy)(MatColoring);
+  PetscErrorCode (*setfromoptions)(MatColoring);
+  PetscErrorCode (*view)(MatColoring,PetscViewer);
+  PetscErrorCode (*apply)(MatColoring,ISColoring*);
+};
+
+struct _p_MatColoring {
+  PETSCHEADER(struct _MatColoringOps);
+  Mat        mat;
+  PetscInt   dist;      /* distance of the coloring */
+  PetscInt   maxcolors; /* the maximum number of colors returned, maxcolors=1 for MIS */
+  void       *data;     /* inner context */
+  PetscBool  valid;     /* check to see if what is produced is a valid coloring */
+};
+
 struct  _p_MatTransposeColoring{
   PETSCHEADER(int);
   PetscInt       M,N,m;            /* total rows, columns; local rows */
 PETSC_EXTERN PetscLogEvent MAT_CUSPCopyToGPU, MAT_CUSPARSECopyToGPU, MAT_SetValuesBatch, MAT_SetValuesBatchI, MAT_SetValuesBatchII, MAT_SetValuesBatchIII, MAT_SetValuesBatchIV;
 PETSC_EXTERN PetscLogEvent MAT_ViennaCLCopyToGPU;
 PETSC_EXTERN PetscLogEvent MAT_Merge,MAT_Residual;
+PETSC_EXTERN PetscLogEvent Mat_Coloring_Apply,Mat_Coloring_Comm,Mat_Coloring_Local,Mat_Coloring_ISCreate,Mat_Coloring_SetUp;
 
 #endif

File include/petsc-private/petscimpl.h

   void                 *optionctx[PETSC_MAX_OPTIONS_HANDLER];
   PetscPrecision       precision;
   PetscBool            optionsprinted;
-#if defined(PETSC_HAVE_AMS)
-  PetscInt             amsmem;
-  PetscBool            amspublishblock; /* if PETSC_TRUE and publishing objects then will block at PetscObjectAMSBlock() */
-  PetscBool            amsblock;
+#if defined(PETSC_HAVE_SAWS)
+  PetscBool            amsmem;          /* if PETSC_TRUE then this object is registered with SAWs and visible to clients */
+  PetscBool            amspublishblock; /* if PETSC_TRUE and publishing objects then will block at PetscObjectSAWsBlock() */
 #endif
 } _p_PetscObject;
 

File include/petsc-private/snesimpl.h

   PetscErrorCode ierr;
 
   PetscFunctionBegin;
-  ierr = PetscObjectAMSTakeAccess((PetscObject)snes);CHKERRQ(ierr);
+  ierr = PetscObjectSAWsTakeAccess((PetscObject)snes);CHKERRQ(ierr);
   if (snes->conv_hist && snes->conv_hist_max > snes->conv_hist_len) {
     if (snes->conv_hist)     snes->conv_hist[snes->conv_hist_len]     = res;
     if (snes->conv_hist_its) snes->conv_hist_its[snes->conv_hist_len] = its;
     snes->conv_hist_len++;
   }
-  ierr = PetscObjectAMSGrantAccess((PetscObject)snes);CHKERRQ(ierr);
+  ierr = PetscObjectSAWsGrantAccess((PetscObject)snes);CHKERRQ(ierr);
   PetscFunctionReturn(0);
 }
 

File include/petscdraw.h

 PETSC_EXTERN PetscErrorCode PetscDrawCreate(MPI_Comm,const char[],const char[],int,int,int,int,PetscDraw*);
 PETSC_EXTERN PetscErrorCode PetscDrawSetFromOptions(PetscDraw);
 PETSC_EXTERN PetscErrorCode PetscDrawSetSave(PetscDraw,const char*,PetscBool);
+PETSC_EXTERN PetscErrorCode PetscDrawView(PetscDraw,PetscViewer);
 
 /*
    Number of basic colors in the draw routines, the others are used

File include/petscerror.h

 #define PetscStackPushNoCheck(funct,petsc_routine,hot)                        \
   do {                                                                        \
     PetscStack* petscstackp;                                                  \
-    PetscStackAMSTakeAccess();                                                \
+    PetscStackSAWsTakeAccess();                                                \
     petscstackp = (PetscStack*)PetscThreadLocalGetValue(petscstack);          \
     if (petscstackp && (petscstackp->currentsize < PETSCSTACKSIZE)) {         \
       petscstackp->function[petscstackp->currentsize]  = funct;               \
     if (petscstackp) {                                                        \
       petscstackp->hotdepth += (hot || petscstackp->hotdepth);                \
     }                                                                         \
-    PetscStackAMSGrantAccess();                                               \
+    PetscStackSAWsGrantAccess();                                               \
   } while (0)
 
 #define PetscStackPopNoCheck                                            \
   do {PetscStack* petscstackp;                                          \
-    PetscStackAMSTakeAccess();                                          \
+    PetscStackSAWsTakeAccess();                                          \
     petscstackp = (PetscStack*)PetscThreadLocalGetValue(petscstack);    \
     if (petscstackp && petscstackp->currentsize > 0) {                  \
       petscstackp->currentsize--;                                       \
     if (petscstackp) {                                                  \
       petscstackp->hotdepth = PetscMax(petscstackp->hotdepth-1,0);      \
     }                                                                   \
-    PetscStackAMSGrantAccess();                                         \
+    PetscStackSAWsGrantAccess();                                         \
   } while (0)
 
 /*MC

File include/petscksp.h

 PETSC_EXTERN PetscErrorCode KSPMonitorTrueResidualMaxNorm(KSP,PetscInt,PetscReal,void *);
 PETSC_EXTERN PetscErrorCode KSPMonitorDefaultShort(KSP,PetscInt,PetscReal,void *);
 PETSC_EXTERN PetscErrorCode KSPMonitorSolution(KSP,PetscInt,PetscReal,void *);
-PETSC_EXTERN PetscErrorCode KSPMonitorAMS(KSP,PetscInt,PetscReal,void*);
-PETSC_EXTERN PetscErrorCode KSPMonitorAMSCreate(KSP,const char*,void**);
-PETSC_EXTERN PetscErrorCode KSPMonitorAMSDestroy(void**);
+PETSC_EXTERN PetscErrorCode KSPMonitorSAWs(KSP,PetscInt,PetscReal,void*);
+PETSC_EXTERN PetscErrorCode KSPMonitorSAWsCreate(KSP,void**);
+PETSC_EXTERN PetscErrorCode KSPMonitorSAWsDestroy(void**);
 PETSC_EXTERN PetscErrorCode KSPGMRESMonitorKrylov(KSP,PetscInt,PetscReal,void *);
 
 PETSC_EXTERN PetscErrorCode KSPUnwindPreconditioner(KSP,Vec,Vec);

File include/petsclog.h

 PETSC_EXTERN PetscErrorCode PetscIntStackTop(PetscIntStack, int *);
 PETSC_EXTERN PetscErrorCode PetscIntStackEmpty(PetscIntStack, PetscBool  *);
 
-/* Special support for C++ */
-#if defined(PETSC_CLANGUAGE_CXX) && defined(__cplusplus)
-#include <petsclog.hh>
-#endif
-
 #define PetscPreLoadBegin(flag,name) \
 do {\
   PetscBool      PetscPreLoading = flag;\

File include/petsclog.hh

-#if !defined(__PETSCLOG_HH)
-#define __PETSCLOG_HH
-
-#if defined(PETSC_CLANGUAGE_CXX) && defined(__cplusplus)
-#include <map>
-#include <string>
-
-namespace PETSc {
-  class LogStage {
-  protected:
-    std::string   name;
-    PetscLogEvent id;
-  public:
-    LogStage() : name(), id() {};
-    LogStage(const std::string& name, PetscLogStage id) : name(name), id(id) {};
-    LogStage(const LogStage& stage) : name(stage.name), id(stage.id) {};
-    void push() {
-      PetscErrorCode ierr = PetscLogStagePush(this->id);CHKERRXX(ierr);
-    };
-    void pop() {
-      PetscErrorCode ierr = PetscLogStagePop();CHKERRXX(ierr);
-    };
-    PetscLogEvent getId() {return this->id;};
-  };
-
-  class LogEvent {
-  protected:
-    std::string   name;
-    PetscLogEvent id;
-  public:
-    LogEvent() : name(), id() {};
-    LogEvent(const std::string& name, PetscLogEvent id) : name(name), id(id) {};
-    LogEvent(const LogEvent& event) : name(event.name), id(event.id) {};
-    void begin(PetscObject o1 = NULL, PetscObject o2 = NULL, PetscObject o3 = NULL, PetscObject o4 = NULL) {
-      PetscErrorCode ierr = PetscLogEventBegin(this->id, o1, o2, o3, o4);CHKERRXX(ierr);
-    };
-    void end(PetscObject o1 = NULL, PetscObject o2 = NULL, PetscObject o3 = NULL, PetscObject o4 = NULL) {
-      PetscErrorCode ierr = PetscLogEventEnd(this->id, o1, o2, o3, o4);CHKERRXX(ierr);
-    };
-    void barrierBegin(PetscObject o1 = NULL, PetscObject o2 = NULL, PetscObject o3 = NULL, PetscObject o4 = NULL, MPI_Comm comm = MPI_COMM_NULL) {
-      if (comm == MPI_COMM_NULL) comm = PETSC_COMM_WORLD;
-      PetscErrorCode ierr = PetscLogEventBarrierBegin(this->id, o1, o2, o3, o4, comm);CHKERRXX(ierr);
-    };
-    void barrierEnd(PetscObject o1 = NULL, PetscObject o2 = NULL, PetscObject o3 = NULL, PetscObject o4 = NULL, MPI_Comm comm = MPI_COMM_NULL) {
-      if (comm == MPI_COMM_NULL) comm = PETSC_COMM_WORLD;
-      PetscErrorCode ierr = PetscLogEventBarrierEnd(this->id, o1, o2, o3, o4, comm);CHKERRXX(ierr);
-    };
-    PetscLogEvent getId() {return this->id;};
-    PetscLogDouble time() {
-      PetscInt       stage = 0;
-      PetscStageLog       stageLog;
-      PetscEventPerfLog   eventLog;
-      PetscErrorCode ierr;
-
-      ierr = PetscLogGetStageLog(&stageLog);CHKERRXX(ierr);
-      ierr = PetscStageLogGetEventPerfLog(stageLog, stage, &eventLog);CHKERRXX(ierr);
-      PetscEventPerfInfo eventInfo = eventLog->eventInfo[this->id];
-
-      return eventInfo.time;
-    };
-  };
-
-  class Log {
-  public:
-    static std::map<std::string,LogEvent> event_registry;
-    static std::map<std::string,LogStage> stage_registry;
-
-    static LogEvent& Event(const std::string& name, PetscClassId classid = PETSC_OBJECT_CLASSID) {
-      if (event_registry.find(name) == event_registry.end()) {
-        PetscLogEvent  id;
-        PetscErrorCode ierr;
-
-        /* Should check for already registered events */
-        ierr = PetscLogEventRegister(name.c_str(), classid, &id);CHKERRXX(ierr);
-        event_registry[name] = LogEvent(name, id);
-      }
-      return event_registry[name];
-    };
-
-    static LogStage& Stage(const std::string& name) {
-      if (stage_registry.find(name) == stage_registry.end()) {
-        PetscLogStage  id;
-        PetscErrorCode ierr;
-
-        /* Should check for already registered stages */
-        ierr = PetscLogStageRegister(name.c_str(), &id);CHKERRXX(ierr);
-        stage_registry[name] = LogStage(name, id);
-      }
-      return stage_registry[name];
-    };
-  };
-}
-#endif /* PETSC_CLANGUAGE_CXX */
-
-/* Reset __FUNCT__ in case the user does not define it themselves */
-#undef __FUNCT__
-#define __FUNCT__ "User provided function"
-
-#endif /* __PETSCLOG_HH */

File include/petscmat.h

 /* Logging support */
 #define    MAT_FILE_CLASSID 1211216    /* used to indicate matrices in binary files */
 PETSC_EXTERN PetscClassId MAT_CLASSID;
+PETSC_EXTERN PetscClassId MAT_COLORING_CLASSID;
 PETSC_EXTERN PetscClassId MAT_FDCOLORING_CLASSID;
 PETSC_EXTERN PetscClassId MAT_TRANSPOSECOLORING_CLASSID;
 PETSC_EXTERN PetscClassId MAT_PARTITIONING_CLASSID;
     These routines are for efficiently computing Jacobians via finite differences.
 */
 
+/*S
+     MatColoring - Object for managing the coloring of matrices.
+
+   Level: beginner
+
+  Concepts: matrix, coloring
+
+.seealso:  MatFDColoringCreate() ISColoring MatFDColoring
+S*/
+typedef struct _p_MatColoring* MatColoring;
 /*J
     MatColoringType - String with the name of a PETSc matrix coloring
 
    Level: beginner
 
-.seealso: MatGetColoring(), MatColoring
+.seealso: MatColoringSetType(), MatColoring
 J*/
-typedef const char* MatColoringType;
+
+typedef const  char*           MatColoringType;
+#define MATCOLORINGJP      "jp"
+#define MATCOLORINGMIS     "mis"
 #define MATCOLORINGNATURAL "natural"
 #define MATCOLORINGSL      "sl"
 #define MATCOLORINGLF      "lf"
 #define MATCOLORINGID      "id"
 
-PETSC_EXTERN PetscErrorCode MatGetColoring(Mat,MatColoringType,ISColoring*);
-PETSC_EXTERN PetscErrorCode MatColoringRegister(const char[],PetscErrorCode(*)(Mat,MatColoringType,ISColoring *));
-
-PETSC_EXTERN PetscBool MatColoringRegisterAllCalled;
-
+PETSC_EXTERN PetscErrorCode MatColoringCreate(Mat,MatColoring*);
+PETSC_EXTERN PetscErrorCode MatColoringDestroy(MatColoring*);
+PETSC_EXTERN PetscErrorCode MatColoringView(MatColoring,PetscViewer);
+PETSC_EXTERN PetscErrorCode MatColoringSetType(MatColoring,MatColoringType);
+PETSC_EXTERN PetscErrorCode MatColoringSetFromOptions(MatColoring);
+PETSC_EXTERN PetscErrorCode MatColoringSetDistance(MatColoring,PetscInt);
+PETSC_EXTERN PetscErrorCode MatColoringGetDistance(MatColoring,PetscInt*);
+PETSC_EXTERN PetscErrorCode MatColoringSetMaxColors(MatColoring,PetscInt);
+PETSC_EXTERN PetscErrorCode MatColoringGetMaxColors(MatColoring,PetscInt*);
+PETSC_EXTERN PetscErrorCode MatColoringApply(MatColoring,ISColoring*);
 PETSC_EXTERN PetscErrorCode MatColoringRegisterAll(void);
+PETSC_EXTERN PetscErrorCode MatColoringRegister(const char[],PetscErrorCode(*)(MatColoring));
+PETSC_EXTERN PetscBool MatColoringRegisterAllCalled;
 PETSC_EXTERN PetscErrorCode MatColoringPatch(Mat,PetscInt,PetscInt,ISColoringValue[],ISColoring*);
 
 /*S

File include/petscoptions.h

   Notes: Needs to be ended by a call the PetscOptionsEnd()
          Can add subheadings with PetscOptionsHead()
 
-  Developer notes: PetscOptionsPublish is set in PetscOptionsCheckInitial_Private() with -options_gui. When PetscOptionsPublish is set the
+  Developer notes: PetscOptionsPublish is set in PetscOptionsCheckInitial_Private() with -saws_options. When PetscOptionsPublish is set the
 $             loop between PetscOptionsBegin() and PetscOptionsEnd() is run THREE times with PetscOptionsPublishCount of values -1,0,1 otherwise
 $             the loop is run ONCE with a PetscOptionsPublishCount of 1.
 $             = -1 : The PetscOptionsInt() etc just call the PetscOptionsGetInt() etc
           PetscOptionsName(), PetscOptionsBegin(), PetscOptionsEnd(), PetscOptionsHead(),
           PetscOptionsStringArray(),PetscOptionsRealArray(), PetscOptionsScalar(),
           PetscOptionsBoolGroupBegin(), PetscOptionsBoolGroup(), PetscOptionsBoolGroupEnd(),
-          PetscOptionsList(), PetscOptionsEList(), PetscObjectOptionsBegin()
+          PetscOptionsFList(), PetscOptionsEList(), PetscObjectOptionsBegin()
 
 M*/
 #define    PetscOptionsBegin(comm,prefix,mess,sec) 0; do {\
           PetscOptionsName(), PetscOptionsBegin(), PetscOptionsEnd(), PetscOptionsHead(),
           PetscOptionsStringArray(),PetscOptionsRealArray(), PetscOptionsScalar(),
           PetscOptionsBoolGroupBegin(), PetscOptionsBoolGroup(), PetscOptionsBoolGroupEnd(),
-          PetscOptionsList(), PetscOptionsEList()
+          PetscOptionsFList(), PetscOptionsEList()
 
 M*/
 #define PetscObjectOptionsBegin(obj) 0; do {                            \
           PetscOptionsName(), PetscOptionsBegin(), PetscOptionsEnd(), PetscOptionsHead(),
           PetscOptionsStringArray(),PetscOptionsRealArray(), PetscOptionsScalar(),
           PetscOptionsBoolGroupBegin(), PetscOptionsBoolGroup(), PetscOptionsBoolGroupEnd(),
-          PetscOptionsList(), PetscOptionsEList(), PetscObjectOptionsBegin()
+          PetscOptionsFList(), PetscOptionsEList(), PetscObjectOptionsBegin()
 
 M*/
 #define    PetscOptionsEnd() _5_ierr = PetscOptionsEnd_Private();CHKERRQ(_5_ierr);}} while (0)
           PetscOptionsName(), PetscOptionsBegin(), PetscOptionsEnd(), PetscOptionsHead(),
           PetscOptionsStringArray(),PetscOptionsRealArray(), PetscOptionsScalar(),
           PetscOptionsBoolGroupBegin(), PetscOptionsBoolGroup(), PetscOptionsBoolGroupEnd(),
-          PetscOptionsList(), PetscOptionsEList(), PetscOptionsEnum()
+          PetscOptionsFList(), PetscOptionsEList(), PetscOptionsEnum()
 M*/
 #define    PetscOptionsTail() 0; {if (PetscOptionsPublishCount != 1) PetscFunctionReturn(0);}
 
 PETSC_EXTERN PetscErrorCode PetscOptionsBoolGroupBegin(const char[],const char[],const char[],PetscBool *);
 PETSC_EXTERN PetscErrorCode PetscOptionsBoolGroup(const char[],const char[],const char[],PetscBool *);
 PETSC_EXTERN PetscErrorCode PetscOptionsBoolGroupEnd(const char[],const char[],const char[],PetscBool *);
-PETSC_EXTERN PetscErrorCode PetscOptionsList(const char[],const char[],const char[],PetscFunctionList,const char[],char[],size_t,PetscBool *);
+PETSC_EXTERN PetscErrorCode PetscOptionsFList(const char[],const char[],const char[],PetscFunctionList,const char[],char[],size_t,PetscBool *);
 PETSC_EXTERN PetscErrorCode PetscOptionsEList(const char[],const char[],const char[],const char*const*,PetscInt,const char[],PetscInt*,PetscBool *);
 PETSC_EXTERN PetscErrorCode PetscOptionsRealArray(const char[],const char[],const char[],PetscReal[],PetscInt*,PetscBool *);
 PETSC_EXTERN PetscErrorCode PetscOptionsIntArray(const char[],const char[],const char[],PetscInt[],PetscInt*,PetscBool *);
 
 
 PETSC_EXTERN PetscErrorCode PetscOptionsSetFromOptions(void);
-PETSC_EXTERN PetscErrorCode PetscOptionsAMSDestroy(void);
+PETSC_EXTERN PetscErrorCode PetscOptionsSAWsDestroy(void);
 
 /*
     See manual page for PetscOptionsBegin()
 */
-typedef enum {OPTION_INT,OPTION_LOGICAL,OPTION_REAL,OPTION_LIST,OPTION_STRING,OPTION_REAL_ARRAY,OPTION_HEAD,OPTION_INT_ARRAY,OPTION_ELIST,OPTION_LOGICAL_ARRAY,OPTION_STRING_ARRAY} PetscOptionType;
+typedef enum {OPTION_INT,OPTION_BOOL,OPTION_REAL,OPTION_FLIST,OPTION_STRING,OPTION_REAL_ARRAY,OPTION_HEAD,OPTION_INT_ARRAY,OPTION_ELIST,OPTION_BOOL_ARRAY,OPTION_STRING_ARRAY} PetscOptionType;
 typedef struct _n_PetscOptions* PetscOptions;
 struct _n_PetscOptions {
   char              *option;
   char              *text;
   void              *data;         /* used to hold the default value and then any value it is changed to by GUI */
-  PetscFunctionList flist;         /* used for available values for PetscOptionsList() */
+  PetscFunctionList flist;         /* used for available values for PetscOptionsFList() */
   const char *const *list;        /* used for available values for PetscOptionsEList() */
   char              nlist;         /* number of entries in list */
   char              *man;
   size_t            arraylength;   /* number of entries in data in the case that it is an array (of PetscInt etc) */
-  PetscBool         set;           /* the user has changed this value in the GUI */
+  int               set;           /* the user has changed this value in the GUI */
   PetscOptionType   type;
   PetscOptions      next;
   char              *pman;

File include/petscsnes.h

 PETSC_EXTERN PetscErrorCode SNESMonitor(SNES,PetscInt,PetscReal);
 PETSC_EXTERN PetscErrorCode SNESMonitorSet(SNES,PetscErrorCode(*)(SNES,PetscInt,PetscReal,void*),void *,PetscErrorCode (*)(void**));
 PETSC_EXTERN PetscErrorCode SNESMonitorCancel(SNES);
+PETSC_EXTERN PetscErrorCode SNESMonitorSAWs(SNES,PetscInt,PetscReal,void*);
+PETSC_EXTERN PetscErrorCode SNESMonitorSAWsCreate(SNES,void**);
+PETSC_EXTERN PetscErrorCode SNESMonitorSAWsDestroy(void**);
 PETSC_EXTERN PetscErrorCode SNESSetConvergenceHistory(SNES,PetscReal[],PetscInt[],PetscInt,PetscBool );
 PETSC_EXTERN PetscErrorCode SNESGetConvergenceHistory(SNES,PetscReal*[],PetscInt *[],PetscInt *);
 PETSC_EXTERN PetscErrorCode SNESSetUp(SNES);

File include/petscsnesfas.h

 
    Values:
 +  SNES_FAS_MULTIPLICATIVE (default) - traditional V or W cycle as determined by SNESFASSetCycles()
--  SNES_FAS_ADDITIVE - the additive multigrid preconditioner where all levels are
-
+.  SNES_FAS_ADDITIVE                 - additive FAS cycle
+.  SNES_FAS_FULL                     - full FAS cycle
+-  SNES_FAS_KASKADE                  - Kaskade FAS cycle
 .seealso: PCMGSetType(), PCMGType
 
 E*/
-typedef enum { SNES_FAS_MULTIPLICATIVE, SNES_FAS_ADDITIVE } SNESFASType;
+typedef enum { SNES_FAS_MULTIPLICATIVE, SNES_FAS_ADDITIVE, SNES_FAS_FULL, SNES_FAS_KASKADE } SNESFASType;
 PETSC_EXTERN const char *const  SNESFASTypes[];
 
 /* called on the finest level FAS instance*/
 PETSC_EXTERN PetscErrorCode SNESFASGetSmootherDown(SNES, PetscInt, SNES*);
 PETSC_EXTERN PetscErrorCode SNESFASGetCoarseSolve(SNES, SNES*);
 
+/* parameters for full FAS */
+PETSC_EXTERN PetscErrorCode SNESFASFullSetDownSweep(SNES,PetscBool);
 PETSC_EXTERN PetscErrorCode SNESFASCreateCoarseVec(SNES,Vec*);
 PETSC_EXTERN PetscErrorCode SNESFASRestrict(SNES,Vec,Vec);
 

File include/petscsys.h

 PETSC_EXTERN PetscErrorCode PetscRegisterFinalize(PetscErrorCode (*)(void));
 PETSC_EXTERN PetscErrorCode PetscRegisterFinalizeAll(void);
 
-#if defined(PETSC_HAVE_AMS)
-PETSC_EXTERN PetscErrorCode PetscObjectAMSViewOff(PetscObject);
-PETSC_EXTERN PetscErrorCode PetscObjectAMSSetBlock(PetscObject,PetscBool);
-PETSC_EXTERN PetscErrorCode PetscObjectAMSBlock(PetscObject);
-PETSC_EXTERN PetscErrorCode PetscObjectAMSGrantAccess(PetscObject);
-PETSC_EXTERN PetscErrorCode PetscObjectAMSTakeAccess(PetscObject);
-PETSC_EXTERN void           PetscStackAMSGrantAccess(void);
-PETSC_EXTERN void           PetscStackAMSTakeAccess(void);
-PETSC_EXTERN PetscErrorCode PetscStackViewAMS(void);
-PETSC_EXTERN PetscErrorCode PetscStackAMSViewOff(void);
+#if defined(PETSC_HAVE_SAWS)
+PETSC_EXTERN PetscErrorCode PetscSAWsBlock(void);
+PETSC_EXTERN PetscErrorCode PetscObjectSAWsViewOff(PetscObject);
+PETSC_EXTERN PetscErrorCode PetscObjectSAWsSetBlock(PetscObject,PetscBool);
+PETSC_EXTERN PetscErrorCode PetscObjectSAWsBlock(PetscObject);
+PETSC_EXTERN PetscErrorCode PetscObjectSAWsGrantAccess(PetscObject);
+PETSC_EXTERN PetscErrorCode PetscObjectSAWsTakeAccess(PetscObject);
+PETSC_EXTERN void           PetscStackSAWsGrantAccess(void);
+PETSC_EXTERN void           PetscStackSAWsTakeAccess(void);
+PETSC_EXTERN PetscErrorCode PetscStackViewSAWs(void);
+PETSC_EXTERN PetscErrorCode PetscStackSAWsViewOff(void);
 
 #else
-#define PetscObjectAMSViewOff(obj)             0
-#define PetscObjectAMSSetBlock(obj,flg)        0
-#define PetscObjectAMSBlock(obj)               0
-#define PetscObjectAMSGrantAccess(obj)         0
-#define PetscObjectAMSTakeAccess(obj)          0
-#define PetscStackViewAMS()                    0
-#define PetscStackAMSViewOff()                 0
-#define PetscStackAMSTakeAccess()
-#define PetscStackAMSGrantAccess()
+#define PetscSAWsBlock()                        0
+#define PetscObjectSAWsViewOff(obj)             0
+#define PetscObjectSAWsSetBlock(obj,flg)        0
+#define PetscObjectSAWsBlock(obj)               0
+#define PetscObjectSAWsGrantAccess(obj)         0
+#define PetscObjectSAWsTakeAccess(obj)          0
+#define PetscStackViewSAWs()                    0
+#define PetscStackSAWsViewOff()                 0
+#define PetscStackSAWsTakeAccess()
+#define PetscStackSAWsGrantAccess()
 
 #endif
 

File include/petscviewer.h

 #define PETSCVIEWERHDF5         "hdf5"
 #define PETSCVIEWERVTK          "vtk"
 #define PETSCVIEWERMATLAB       "matlab"
-#define PETSCVIEWERAMS          "ams"
+#define PETSCVIEWERSAWS          "saws"
 
 PETSC_EXTERN PetscFunctionList PetscViewerList;
 PETSC_EXTERN PetscErrorCode PetscViewerRegisterAll(void);
 PETSC_EXTERN PetscErrorCode PetscViewerMatlabGetArray(PetscViewer,int,int,PetscScalar*,const char*);
 PETSC_EXTERN PetscErrorCode PetscViewerMatlabPutVariable(PetscViewer,const char*,void*);
 
-#if defined(PETSC_HAVE_AMS)
-PETSC_EXTERN PetscErrorCode PetscObjectViewAMS(PetscObject,PetscViewer);
+#if defined(PETSC_HAVE_SAWS)
+PETSC_EXTERN PetscErrorCode PetscObjectViewSAWs(PetscObject,PetscViewer);
 #endif
 
 /*S

File include/petscviewerams.h

-
-#if !defined(__PETSCVIEWERAMS_H)
-#define __PETSCVIEWERAMS_H
-
-#include <petscviewer.h>
-#include <ams.h>
-PETSC_EXTERN PetscErrorCode PetscViewerAMSSetCommName(PetscViewer,const char[]);
-PETSC_EXTERN PetscErrorCode PetscViewerAMSGetAMSComm(PetscViewer,AMS_Comm *);
-PETSC_EXTERN PetscErrorCode PetscViewerAMSOpen(MPI_Comm,const char[],PetscViewer*);
-PETSC_EXTERN PetscViewer    PETSC_VIEWER_AMS_(MPI_Comm);
-PETSC_EXTERN PetscErrorCode PETSC_VIEWER_AMS_Destroy(MPI_Comm);
-#define PETSC_VIEWER_AMS_WORLD PETSC_VIEWER_AMS_(PETSC_COMM_WORLD)
-#define PETSC_VIEWER_AMS_SELF  PETSC_VIEWER_AMS_(PETSC_COMM_SELF)
-
-#define PetscStackCallAMS(func,args) do {PetscErrorCode _ierr; char* err; \
-    PetscStackPush(#func);_ierr = func args;PetscStackPop; if (_ierr) {AMS_Explain_error(_ierr,&err); SETERRQ2(PETSC_COMM_SELF,PETSC_ERR_LIB,"Error in %s() %s",#func,err);} \
-} while (0)
-
-#endif

File include/petscviewersaws.h

+
+#if !defined(__PETSCVIEWERSAWS_H)
+#define __PETSCVIEWERSAWS_H
+
+#include <petscviewer.h>
+#include <SAWs.h>
+PETSC_EXTERN PetscErrorCode PetscViewerSAWsOpen(MPI_Comm,PetscViewer*);
+PETSC_EXTERN PetscViewer    PETSC_VIEWER_SAWS_(MPI_Comm);
+PETSC_EXTERN PetscErrorCode PETSC_VIEWER_SAWS_Destroy(MPI_Comm);
+#define PETSC_VIEWER_SAWS_WORLD PETSC_VIEWER_SAWS_(PETSC_COMM_WORLD)
+#define PETSC_VIEWER_SAWS_SELF  PETSC_VIEWER_SAWS_(PETSC_COMM_SELF)
+
+#define PetscStackCallSAWs(func,args) do {PetscErrorCode _ierr; \
+    PetscStackPush(#func);_ierr = func args;PetscStackPop; if (_ierr) {SETERRQ2(PETSC_COMM_SELF,PETSC_ERR_LIB,"Error in %s() %d",#func,_ierr);} \
+} while (0)
+
+#endif

File src/contrib/fun3d/incomp/flow.c

   user.grid  = &f_pntr;
   user.tsCtx = &tsCtx;
 
-  /* AMS Stuff */
+  /* SAWs Stuff */
 
   /*
     Preload the executable to get accurate timings. This runs the following chunk of

File src/contrib/nightlysummary/runhtml.sh

   echo "</table></center>" >> $OUTFILE
 }
 
+generate_configure_section()
+{
+  echo "<h3>Configure</h3>" >> $OUTFILE
+  echo "<center><table>" >> $OUTFILE
+  echo "<tr><th>Configuration</th><th>Status</th></tr>" >> $OUTFILE
+
+  for f in `ls $LOGDIR/configure*.log`
+  do
+    echo "Processing file $f..."
+    echo "<tr><td class=\"desc\">" >> $OUTFILE
+    echo "<a href=\"${f#$LOGDIR/}\">${f#$LOGDIR/}</a>" >> $OUTFILE
 
+    # Check for "Configure stage complete" string
+    stagecomplete=`grep "Configure stage complete" $f | wc -l`
+    if [ "$stagecomplete" -gt "0" ]
+    then
+	  echo "</td><td class=\"green\">Success</td>" >> $OUTFILE
+    else
+	  echo "</td><td class=\"red\">Fail</td>" >> $OUTFILE
+    fi
+  done
+  echo "</table></center>" >> $OUTFILE
+
+}
 
 ############ Part 1: Build ####################
 #generate_section Configure configure  #Note: Current grep-driven extraction is not suitable for configure*.log files
+generate_configure_section
 generate_section Build     build
 generate_section Examples  examples
 generate_section Make      make

File src/dm/dt/interface/dtfe.c

   if (!PetscSpaceRegisterAllCalled) {ierr = PetscSpaceRegisterAll();CHKERRQ(ierr);}
 
   ierr = PetscObjectOptionsBegin((PetscObject) sp);CHKERRQ(ierr);
-  ierr = PetscOptionsList("-petscspace_type", "Linear space", "PetscSpaceSetType", PetscSpaceList, defaultType, name, 256, &flg);CHKERRQ(ierr);
+  ierr = PetscOptionsFList("-petscspace_type", "Linear space", "PetscSpaceSetType", PetscSpaceList, defaultType, name, 256, &flg);CHKERRQ(ierr);
   if (flg) {
     ierr = PetscSpaceSetType(sp, name);CHKERRQ(ierr);
   } else if (!((PetscObject) sp)->type_name) {
 
   if (--((PetscObject)(*sp))->refct > 0) {*sp = 0; PetscFunctionReturn(0);}
   ((PetscObject) (*sp))->refct = 0;
-  /* if memory was published with AMS then destroy it */
-  ierr = PetscObjectAMSViewOff((PetscObject) *sp);CHKERRQ(ierr);
-
   ierr = DMDestroy(&(*sp)->dm);CHKERRQ(ierr);
 
   ierr = (*(*sp)->ops->destroy)(*sp);CHKERRQ(ierr);
   if (!PetscSpaceRegisterAllCalled) {ierr = PetscSpaceRegisterAll();CHKERRQ(ierr);}
 
   ierr = PetscObjectOptionsBegin((PetscObject) sp);CHKERRQ(ierr);
-  ierr = PetscOptionsList("-petscdualspace_type", "Dual space", "PetscDualSpaceSetType", PetscDualSpaceList, defaultType, name, 256, &flg);CHKERRQ(ierr);
+  ierr = PetscOptionsFList("-petscdualspace_type", "Dual space", "PetscDualSpaceSetType", PetscDualSpaceList, defaultType, name, 256, &flg);CHKERRQ(ierr);
   if (flg) {
     ierr = PetscDualSpaceSetType(sp, name);CHKERRQ(ierr);
   } else if (!((PetscObject) sp)->type_name) {
 
   if (--((PetscObject)(*sp))->refct > 0) {*sp = 0; PetscFunctionReturn(0);}
   ((PetscObject) (*sp))->refct = 0;
-  /* if memory was published with AMS then destroy it */
-  ierr = PetscObjectAMSViewOff((PetscObject) *sp);CHKERRQ(ierr);
 
   ierr = PetscDualSpaceGetDimension(*sp, &dim);CHKERRQ(ierr);
   for (f = 0; f < dim; ++f) {
   if (!PetscFERegisterAllCalled) {ierr = PetscFERegisterAll();CHKERRQ(ierr);}
 
   ierr = PetscObjectOptionsBegin((PetscObject) fem);CHKERRQ(ierr);
-  ierr = PetscOptionsList("-petscfe_type", "Finite element space", "PetscFESetType", PetscFEList, defaultType, name, 256, &flg);CHKERRQ(ierr);
+  ierr = PetscOptionsFList("-petscfe_type", "Finite element space", "PetscFESetType", PetscFEList, defaultType, name, 256, &flg);CHKERRQ(ierr);
   if (flg) {
     ierr = PetscFESetType(fem, name);CHKERRQ(ierr);
   } else if (!((PetscObject) fem)->type_name) {
 
   if (--((PetscObject)(*fem))->refct > 0) {*fem = 0; PetscFunctionReturn(0);}
   ((PetscObject) (*fem))->refct = 0;
-  /* if memory was published with AMS then destroy it */
-  ierr = PetscObjectAMSViewOff((PetscObject) *fem);CHKERRQ(ierr);
 
   ierr = PetscFree((*fem)->numDof);CHKERRQ(ierr);
   ierr = PetscFERestoreTabulation((*fem), 0, NULL, &(*fem)->B, &(*fem)->D, NULL /*&(*fem)->H*/);CHKERRQ(ierr);

File src/dm/impls/da/dacreate.c

 {
   PetscErrorCode ierr;
   DM_DA          *dd         = (DM_DA*)da->data;
-  PetscInt       refine      = 0,maxnlevels = 100,*refx,*refy,*refz,n,i;
+  PetscInt       refine      = 0,maxnlevels = 100,refx[100],refy[100],refz[100],n,i;
   PetscBool      negativeMNP = PETSC_FALSE,bM = PETSC_FALSE,bN = PETSC_FALSE, bP = PETSC_FALSE,flg;
 
   PetscFunctionBegin;
   dd->coarsen_x = dd->refine_x; dd->coarsen_y = dd->refine_y; dd->coarsen_z = dd->refine_z;
 
   /* Get refinement factors, defaults taken from the coarse DMDA */
-  ierr = PetscMalloc3(maxnlevels,PetscInt,&refx,maxnlevels,PetscInt,&refy,maxnlevels,PetscInt,&refz);CHKERRQ(ierr);
   ierr = DMDAGetRefinementFactor(da,&refx[0],&refy[0],&refz[0]);CHKERRQ(ierr);
   for (i=1; i<maxnlevels; i++) {
     refx[i] = refx[0];
       dd->coarsen_z = refz[da->levelup - da->leveldown - 1];
     }
   }
-  ierr = PetscFree3(refx,refy,refz);CHKERRQ(ierr);
   PetscFunctionReturn(0);
 }
 

File src/dm/impls/plex/examples/tests/ex10.c

   ierr = DMPlexPermute(dm, perm, &pdm);CHKERRQ(ierr);
   ierr = DMSetFromOptions(pdm);CHKERRQ(ierr);
   ierr = ISDestroy(&perm);CHKERRQ(ierr);
-  ierr = DMCreateMatrix(dm, MATAIJ, &A);CHKERRQ(ierr);
-  ierr = DMCreateMatrix(pdm, MATAIJ, &pA);CHKERRQ(ierr);
+  ierr = DMCreateMatrix(dm, &A);CHKERRQ(ierr);
+  ierr = DMCreateMatrix(pdm, &pA);CHKERRQ(ierr);
   ierr = MatComputeBandwidth(A, 0.0, &bw);CHKERRQ(ierr);
   ierr = MatComputeBandwidth(pA, 0.0, &pbw);CHKERRQ(ierr);
   ierr = MatDestroy(&A);CHKERRQ(ierr);

File src/dm/impls/plex/examples/tests/ex9.c

   ierr = PetscLogStagePush(stage);CHKERRQ(ierr);
   ierr = DMPlexCreateSection(dm, user->dim, user->numFields, user->numComponents, user->numDof, 0, NULL, NULL, &s);CHKERRQ(ierr);
   ierr = DMSetDefaultSection(dm, s);CHKERRQ(ierr);
+  ierr = PetscSectionDestroy(&s);CHKERRQ(ierr);
   ierr = DMPlexGetHeightStratum(dm, 0, &cStart, &cEnd);CHKERRQ(ierr);
   ierr = DMGetLocalVector(dm, &v);CHKERRQ(ierr);
   ierr = PetscLogEventBegin(event,0,0,0,0);CHKERRQ(ierr);
   ierr = TestCone(dm, &user);CHKERRQ(ierr);
   ierr = TestTransitiveClosure(dm, &user);CHKERRQ(ierr);
   ierr = TestVecClosure(dm, &user);CHKERRQ(ierr);
+  ierr = DMDestroy(&dm);CHKERRQ(ierr);
   ierr = CleanupContext(&user);CHKERRQ(ierr);
   ierr = PetscFinalize();
   return 0;

File src/dm/impls/plex/examples/tests/output/ex10_7.out

+Ordering method rcm reduced bandwidth from 87 to 47

File src/dm/impls/plex/examples/tests/output/ex4_24.out

+Mesh 'Hybrid Mesh':
+Max sizes cone: 4 support: 6
+orientation is missing
+cap --> base:
+[0]: 20 ----> 38
+[0]: 20 ----> 43
+[0]: 20 ----> 47
+[0]: 21 ----> 39
+[0]: 21 ----> 40
+[0]: 21 ----> 70
+[0]: 22 ----> 41
+[0]: 22 ----> 42
+[0]: 22 ----> 44
+[0]: 22 ----> 71
+[0]: 23 ----> 45
+[0]: 23 ----> 46
+[0]: 23 ----> 72
+[0]: 24 ----> 49
+[0]: 24 ----> 50
+[0]: 24 ----> 52
+[0]: 25 ----> 54
+[0]: 25 ----> 48
+[0]: 25 ----> 70
+[0]: 26 ----> 55
+[0]: 26 ----> 56
+[0]: 26 ----> 51
+[0]: 26 ----> 71
+[0]: 27 ----> 57
+[0]: 27 ----> 53
+[0]: 27 ----> 72
+[0]: 28 ----> 38
+[0]: 28 ----> 39
+[0]: 28 ----> 60
+[0]: 28 ----> 58
+[0]: 29 ----> 40
+[0]: 29 ----> 41
+[0]: 29 ----> 58
+[0]: 29 ----> 59
+[0]: 29 ----> 73
+[0]: 30 ----> 42
+[0]: 30 ----> 43
+[0]: 30 ----> 59
+[0]: 30 ----> 60
+[0]: 30 ----> 62
+[0]: 30 ----> 63
+[0]: 31 ----> 44
+[0]: 31 ----> 45
+[0]: 31 ----> 63
+[0]: 31 ----> 61
+[0]: 31 ----> 74
+[0]: 32 ----> 46
+[0]: 32 ----> 47
+[0]: 32 ----> 61
+[0]: 32 ----> 62
+[0]: 33 ----> 48
+[0]: 33 ----> 49
+[0]: 33 ----> 64
+[0]: 33 ----> 65
+[0]: 34 ----> 50
+[0]: 34 ----> 51
+[0]: 34 ----> 65
+[0]: 34 ----> 66
+[0]: 34 ----> 69
+[0]: 34 ----> 67
+[0]: 35 ----> 52
+[0]: 35 ----> 53
+[0]: 35 ----> 67
+[0]: 35 ----> 68
+[0]: 36 ----> 54
+[0]: 36 ----> 55
+[0]: 36 ----> 73
+[0]: 36 ----> 66
+[0]: 36 ----> 64
+[0]: 37 ----> 56
+[0]: 37 ----> 57
+[0]: 37 ----> 74
+[0]: 37 ----> 68
+[0]: 37 ----> 69
+[0]: 38 ----> 0
+[0]: 39 ----> 1
+[0]: 40 ----> 1
+[0]: 40 ----> 16
+[0]: 41 ----> 2
+[0]: 41 ----> 17
+[0]: 42 ----> 2
+[0]: 42 ----> 4
+[0]: 43 ----> 0
+[0]: 43 ----> 6
+[0]: 44 ----> 4
+[0]: 44 ----> 18
+[0]: 45 ----> 5
+[0]: 45 ----> 19
+[0]: 46 ----> 5
+[0]: 47 ----> 6
+[0]: 48 ----> 9
+[0]: 49 ----> 10
+[0]: 50 ----> 10
+[0]: 50 ----> 13
+[0]: 51 ----> 8
+[0]: 51 ----> 12
+[0]: 52 ----> 13
+[0]: 53 ----> 14
+[0]: 54 ----> 16
+[0]: 54 ----> 9
+[0]: 55 ----> 17
+[0]: 55 ----> 8
+[0]: 56 ----> 18
+[0]: 56 ----> 12
+[0]: 57 ----> 19
+[0]: 57 ----> 14
+[0]: 58 ----> 1
+[0]: 58 ----> 3
+[0]: 59 ----> 2
+[0]: 59 ----> 3
+[0]: 60 ----> 0
+[0]: 60 ----> 3
+[0]: 61 ----> 5
+[0]: 61 ----> 7
+[0]: 62 ----> 6
+[0]: 62 ----> 7
+[0]: 63 ----> 4
+[0]: 63 ----> 7
+[0]: 64 ----> 9
+[0]: 64 ----> 11
+[0]: 65 ----> 10
+[0]: 65 ----> 11
+[0]: 66 ----> 8
+[0]: 66 ----> 11
+[0]: 67 ----> 13
+[0]: 67 ----> 15
+[0]: 68 ----> 14
+[0]: 68 ----> 15
+[0]: 69 ----> 12
+[0]: 69 ----> 15
+[0]: 70 ----> 16
+[0]: 71 ----> 17
+[0]: 71 ----> 18
+[0]: 72 ----> 19
+[0]: 73 ----> 16
+[0]: 73 ----> 17
+[0]: 74 ----> 18
+[0]: 74 ----> 19
+base <-- cap:
+[0]: 0 <---- 38 (0)
+[0]: 0 <---- 60 (-2)
+[0]: 0 <---- 43 (0)
+[0]: 1 <---- 39 (0)
+[0]: 1 <---- 40 (0)
+[0]: 1 <---- 58 (-2)
+[0]: 2 <---- 59 (-2)
+[0]: 2 <---- 41 (0)
+[0]: 2 <---- 42 (0)
+[0]: 3 <---- 58 (0)
+[0]: 3 <---- 59 (0)
+[0]: 3 <---- 60 (0)
+[0]: 4 <---- 44 (0)
+[0]: 4 <---- 63 (-2)
+[0]: 4 <---- 42 (-2)
+[0]: 5 <---- 45 (0)
+[0]: 5 <---- 46 (0)
+[0]: 5 <---- 61 (-2)
+[0]: 6 <---- 62 (-2)
+[0]: 6 <---- 47 (0)
+[0]: 6 <---- 43 (-2)
+[0]: 7 <---- 61 (0)
+[0]: 7 <---- 62 (0)
+[0]: 7 <---- 63 (0)
+[0]: 8 <---- 55 (-2)
+[0]: 8 <---- 66 (-2)
+[0]: 8 <---- 51 (0)
+[0]: 9 <---- 54 (-2)
+[0]: 9 <---- 48 (0)
+[0]: 9 <---- 64 (-2)
+[0]: 10 <---- 65 (-2)
+[0]: 10 <---- 49 (0)
+[0]: 10 <---- 50 (0)
+[0]: 11 <---- 64 (0)
+[0]: 11 <---- 65 (0)
+[0]: 11 <---- 66 (0)
+[0]: 12 <---- 51 (-2)
+[0]: 12 <---- 69 (-2)
+[0]: 12 <---- 56 (-2)
+[0]: 13 <---- 50 (-2)
+[0]: 13 <---- 52 (0)
+[0]: 13 <---- 67 (-2)
+[0]: 14 <---- 68 (-2)
+[0]: 14 <---- 53 (0)
+[0]: 14 <---- 57 (-2)
+[0]: 15 <---- 67 (0)
+[0]: 15 <---- 68 (0)
+[0]: 15 <---- 69 (0)
+[0]: 16 <---- 40 (0)
+[0]: 16 <---- 54 (0)
+[0]: 16 <---- 70 (0)
+[0]: 16 <---- 73 (0)
+[0]: 17 <---- 41 (0)
+[0]: 17 <---- 55 (0)
+[0]: 17 <---- 73 (0)
+[0]: 17 <---- 71 (0)
+[0]: 18 <---- 44 (0)
+[0]: 18 <---- 56 (0)
+[0]: 18 <---- 71 (0)
+[0]: 18 <---- 74 (0)
+[0]: 19 <---- 45 (0)
+[0]: 19 <---- 57 (0)
+[0]: 19 <---- 74 (0)
+[0]: 19 <---- 72 (0)
+[0]: 38 <---- 20 (0)
+[0]: 38 <---- 28 (0)
+[0]: 39 <---- 28 (0)
+[0]: 39 <---- 21 (0)
+[0]: 40 <---- 21 (0)
+[0]: 40 <---- 29 (0)
+[0]: 41 <---- 29 (0)
+[0]: 41 <---- 22 (0)
+[0]: 42 <---- 22 (0)
+[0]: 42 <---- 30 (0)
+[0]: 43 <---- 30 (0)
+[0]: 43 <---- 20 (0)
+[0]: 44 <---- 22 (0)
+[0]: 44 <---- 31 (0)
+[0]: 45 <---- 31 (0)
+[0]: 45 <---- 23 (0)
+[0]: 46 <---- 23 (0)
+[0]: 46 <---- 32 (0)
+[0]: 47 <---- 32 (0)
+[0]: 47 <---- 20 (0)
+[0]: 48 <---- 25 (0)
+[0]: 48 <---- 33 (0)
+[0]: 49 <---- 33 (0)
+[0]: 49 <---- 24 (0)
+[0]: 50 <---- 24 (0)
+[0]: 50 <---- 34 (0)
+[0]: 51 <---- 34 (0)
+[0]: 51 <---- 26 (0)
+[0]: 52 <---- 24 (0)
+[0]: 52 <---- 35 (0)
+[0]: 53 <---- 35 (0)
+[0]: 53 <---- 27 (0)
+[0]: 54 <---- 25 (0)
+[0]: 54 <---- 36 (0)
+[0]: 55 <---- 36 (0)
+[0]: 55 <---- 26 (0)
+[0]: 56 <---- 26 (0)
+[0]: 56 <---- 37 (0)
+[0]: 57 <---- 37 (0)
+[0]: 57 <---- 27 (0)
+[0]: 58 <---- 28 (0)
+[0]: 58 <---- 29 (0)
+[0]: 59 <---- 29 (0)
+[0]: 59 <---- 30 (0)
+[0]: 60 <---- 30 (0)
+[0]: 60 <---- 28 (0)
+[0]: 61 <---- 31 (0)
+[0]: 61 <---- 32 (0)
+[0]: 62 <---- 32 (0)
+[0]: 62 <---- 30 (0)
+[0]: 63 <---- 30 (0)
+[0]: 63 <---- 31 (0)
+[0]: 64 <---- 36 (0)
+[0]: 64 <---- 33 (0)
+[0]: 65 <---- 33 (0)
+[0]: 65 <---- 34 (0)
+[0]: 66 <---- 34 (0)
+[0]: 66 <---- 36 (0)
+[0]: 67 <---- 34 (0)
+[0]: 67 <---- 35 (0)
+[0]: 68 <---- 35 (0)
+[0]: 68 <---- 37 (0)
+[0]: 69 <---- 37 (0)
+[0]: 69 <---- 34 (0)
+[0]: 70 <---- 21 (0)
+[0]: 70 <---- 25 (0)
+[0]: 71 <---- 22 (0)
+[0]: 71 <---- 26 (0)
+[0]: 72 <---- 23 (0)
+[0]: 72 <---- 27 (0)
+[0]: 73 <---- 29 (0)
+[0]: 73 <---- 36 (0)
+[0]: 74 <---- 31 (0)
+[0]: 74 <---- 37 (0)
+coordinates with 1 fields
+  field 0 with 2 components
+Process 0:
+  (  20) dim  2 offset   0 -1 0
+  (  21) dim  2 offset   2 0 -1
+  (  22) dim  2 offset   4 0 0
+  (  23) dim  2 offset   6 0 1
+  (  24) dim  2 offset   8 1 0
+  (  25) dim  2 offset  10 0 -1
+  (  26) dim  2 offset  12 0 0
+  (  27) dim  2 offset  14 0 1
+  (  28) dim  2 offset  16 -0.5 -0.5
+  (  29) dim  2 offset  18 0 -0.5
+  (  30) dim  2 offset  20 -0.5 0
+  (  31) dim  2 offset  22 0 0.5
+  (  32) dim  2 offset  24 -0.5 0.5
+  (  33) dim  2 offset  26 0.5 -0.5
+  (  34) dim  2 offset  28 0.5 0
+  (  35) dim  2 offset  30 0.5 0.5
+  (  36) dim  2 offset  32 0 -0.5
+  (  37) dim  2 offset  34 0 0.5

File src/dm/impls/plex/examples/tutorials/ex1f90.F

       implicit none
 #include "finclude/petsc.h90"
       DM :: dm
+      DMLabel :: label
       Vec :: u
       PetscViewer :: viewer
       PetscSection :: section
-      PetscInt :: dim,numFields,numBC,i
+      PetscInt :: dim,numFields,numBC,i,val
       PetscInt, target, dimension(3) ::                                 &
      &     numComp
       PetscInt, pointer :: pNumComp(:)
       pNumDof => numDof
 !     Setup boundary conditions
       numBC = 1
+!     Test label retrieval
+      call DM