1. petsc
  2. PETSc
  3. petsc

Commits

Matt Knepley  committed 9c5a1e1 Merge with conflicts

Merge branch 'master' into knepley/feature-plex-gmsh

* master: (163 commits)
do not use C99 struct initialization code in PETSc
Nightly Summary: Added time taken to each of the tests in the dashboard.
ASCII printing of floating point numbers must cast to (double) to support quad precision
configure: check fortranDatatypes only when fortran is enabled [this fixes configure crash with --with-fc=0]
don't use non-portable and also dependent on floating point precision system level math constants
picky compilers
fix a couple compiler warnings/errors (depending on compiler) for Matlab engine code
DMPlex: More fixup from bad rebase, moved to DMGet/SetCoordinateSection()
DM: Added DMGet/SetCoordinateSection()
Fuckup: Fix for merge that is still untangling bad rebase from Oct. 17th 2013 - Fixed const in declarations - Fixed merge from PetscFE - Fixed 2 mallocs
replace all echo in test/tutorial makefiles with printf since echo behaves differently on different systems
DMDA: Missing header - Damn rebase
DMPlex ex3: Added 2D Q_1 and 3D P_2 tests
DMDA: Added DMDAProjectFunction() and DMDAComputeL2Diff()
DMDA: Fixed 2D geometry - Should reuse DMPlex routines
DMDA: Fix bug in 2D closure operation for cells
DMDA: Make closure operations also return the size
DMDA: Changed DMDACreateSection() to emulate DMPlexCreateSection()
DMDA: Added functions which emulate DMPlex functionality
DMDA: Now DMDAGetNumCells() returns the cells in each direction as well
...

Conflicts:
config/builder.py

  • Participants
  • Parent commits 6228fc9, 8deb41e
  • Branches master

Comments (0)

Files changed (798)

File bin/maint/getinterfaces.py

View file
  • Ignore whitespace
   classes['PetscBinary'] = {}
   classes['PetscOptions'] = {}
   classes['PetscMalloc'] = {}
-  classes['PetscHMPI'] = {}
   classes['PetscToken'] = {}
   for i in args:
     getclasses(i)

File conf/rules

View file
  • Ignore whitespace
           grep -v "IPO Error: unresolved" | \
 	  grep -v "is being replaced by a real definition" | \
           grep -v "may result in errors or" | \
+          grep -v "clang: warning: treating 'c' input as 'c++' when in C++ mode, this behavior is deprecated" | \
 	  egrep -i '(Error|warning|Can|Unresolved)' >> /dev/null;\
 	  if [ "$$?" != 1 ]; then \
           printf ${PETSC_TEXT_HILIGHT}"*******************Error detected during compile or link!*******************\n";\

File conf/test

View file
  • Ignore whitespace
 testexamples_C_NoComplex: ${TESTEXAMPLES_C_NOCOMPLEX}
 testexamples_DATAFILESPATH: ${TESTEXAMPLES_DATAFILESPATH}
 
+testexamples_F90_DataTypes: ${TESTEXAMPLES_F90_DATATYPES}
 testexamples_Fortran_NoComplex: ${TESTEXAMPLES_FORTRAN_NOCOMPLEX}
 testexamples_Fortran_MPIUni: ${TESTEXAMPLES_FORTRAN_MPIUNI}
 testexamples_Fortran_Complex: ${TESTEXAMPLES_FORTRAN_COMPLEX}
 buildexamples_DATAFILESPATH:
 	-@${OMAKE} testexamples_DATAFILESPATH TESTEXAMPLES_DATAFILESPATH=`echo ${TESTEXAMPLES_DATAFILESPATH} | sed s/runex[0-9]*[a-z0-9_]*//g`
 
+buildexamples_F90_DataTypes:
+	-@${OMAKE} testexamples_F90_DataTypes TESTEXAMPLES_F90_DATATYPES=`echo ${TESTEXAMPLES_F90_DATATYPES} | sed s/runex[0-9]*[a-z0-9_]*//g`
 buildexamples_Fortran_NoComplex:
 	-@${OMAKE} testexamples_Fortran_NoComplex TESTEXAMPLES_FORTRAN_NOCOMPLEX=`echo ${TESTEXAMPLES_FORTRAN_NOCOMPLEX} | sed s/runex[0-9]*[a-z0-9_]*//g`
 buildexamples_Fortran_MPIUni:

File config/BuildSystem/config/package.py

View file
  • Ignore whitespace
         raise RuntimeError('Cannot use '+self.name+' without Fortran, make sure you do NOT have --with-fc=0')
       if self.noMPIUni and self.mpi.usingMPIUni:
         raise RuntimeError('Cannot use '+self.name+' with MPIUNI, you need a real MPI')
-      if not self.worksonWindows and self.setCompilers.isWindows(self.setCompilers.CC):
+      if not self.worksonWindows and (self.setCompilers.CC.find('win32fe') >= 0):
         raise RuntimeError('External package '+self.name+' does not work with Microsoft compilers')
-      if self.download and self.framework.argDB.get('download-'+self.downloadname.lower()) and not self.downloadonWindows and self.setCompilers.isWindows(self.setCompilers.CC):
+      if self.download and self.framework.argDB.get('download-'+self.downloadname.lower()) and not self.downloadonWindows and (self.setCompilers.CC.find('win32fe') >= 0):
         raise RuntimeError('External package '+self.name+' does not support --download-'+self.downloadname.lower()+' with Microsoft compilers')
     if not self.download and self.framework.argDB.has_key('download-'+self.downloadname.lower()) and self.framework.argDB['download-'+self.downloadname.lower()]:
       raise RuntimeError('External package '+self.name+' does not support --download-'+self.downloadname.lower())

File config/BuildSystem/retrieval.py

View file
  • Ignore whitespace
         tf  = tarfile.open(os.path.join(root, localFile))
       except tarfile.ReadError, e:
         raise RuntimeError(str(e)+'\n'+failureMessage)
-      # some tarfiles list packagename/ but some list packagename/filename in the first entry
       if not tf: raise RuntimeError(failureMessage)
-      if not tf.firstmember: raise RuntimeError(failureMessage)
-      if tf.firstmember.isdir():
-        dirname = tf.firstmember.name
+      #git puts 'pax_global_header' as the first entry and some tar utils process this as a file
+      firstname = tf.getnames()[0]
+      if firstname == 'pax_global_header':
+        firstmember = tf.getmembers()[1]
+      else:
+        firstmember = tf.getmembers()[0]
+      # some tarfiles list packagename/ but some list packagename/filename in the first entry
+      if firstmember.isdir():
+        dirname = firstmember.name
       else:
-        dirname = os.path.dirname(tf.firstmember.name)
+        dirname = os.path.dirname(firstmember.name)
       if hasattr(tf,'extractall'): #python 2.5+
         tf.extractall(root)
       else:
 
     # fix file permissions for the untared tarballs.
     try:
-      config.base.Configure.executeShellCommand('cd '+root+'; chmod -R a+r '+dirname+';find  '+dirname + ' -type d -name "*" -exec chmod a+rx {} \;', log = self.log)
+      # check if 'dirname' is set'
+      if dirname:
+        config.base.Configure.executeShellCommand('cd '+root+'; chmod -R a+r '+dirname+';find  '+dirname + ' -type d -name "*" -exec chmod a+rx {} \;', log = self.log)
+      else:
+        self.logPrintBox('WARNING: Could not determine dirname extracted by '+localFile+' to fix file permissions')
     except RuntimeError, e:
       raise RuntimeError('Error changing permissions for '+dirname+' obtained from '+localFile+ ' : '+str(e))
     os.unlink(localFile)

File config/PETSc/Configure.py

View file
  • Ignore whitespace
     config.base.Configure.setupDependencies(self, framework)
     self.setCompilers  = framework.require('config.setCompilers',       self)
     self.arch          = framework.require('PETSc.utilities.arch',      self.setCompilers)
-    self.petscdir      = framework.require('PETSc.utilities.petscdir',  self.setCompilers)
+    self.petscdir      = framework.require('PETSc.utilities.petscdir',  self.arch)
     self.installdir    = framework.require('PETSc.utilities.installDir',self)
     self.languages     = framework.require('PETSc.utilities.languages', self.setCompilers)
     self.debugging     = framework.require('PETSc.utilities.debugging', self.setCompilers)
       self.addDefine('DIR_SEPARATOR','\'\\\\\'')
       self.addDefine('REPLACE_DIR_SEPARATOR','\'/\'')
       self.addDefine('CANNOT_START_DEBUGGER',1)
+      (petscdir,error,status) = self.executeShellCommand('cygpath -w '+self.petscdir.dir)
+      self.addDefine('DIR','"'+petscdir.replace('\\','\\\\')+'"')
     else:
       self.addDefine('PATH_SEPARATOR','\':\'')
       self.addDefine('REPLACE_DIR_SEPARATOR','\'\\\\\'')
       self.addDefine('DIR_SEPARATOR','\'/\'')
+      self.addDefine('DIR', '"'+self.petscdir.dir+'"')
 
     return
 

File config/PETSc/package.py

View file
  • Ignore whitespace
     self.scalartypes    = framework.require('PETSc.utilities.scalarTypes',self)
     self.libraryOptions = framework.require('PETSc.utilities.libraryOptions', self)
     self.petscdir       = framework.require('PETSc.utilities.petscdir', self.setCompilers)
+    self.petscclone     = framework.require('PETSc.utilities.petscclone',self.setCompilers)
     return
 
   def consistencyChecks(self):

File config/PETSc/packages/c2html.py

View file
  • Ignore whitespace
       self.framework.logPrint("Not checking c2html on user request\n")
       return
 
-    if self.petscdir.isClone:
+    if self.petscclone.isClone:
       self.framework.logPrint('PETSc clone, checking for c2html\n')
       self.getExecutable('c2html', getFullPath = 1)
 

File config/PETSc/packages/cmake.py

View file
  • Ignore whitespace
         raise RuntimeError('Error running configure on cmake: '+str(e))
       try:
         self.logPrintBox('Compiling CMake; this may take several minutes')
-        output,err,ret  = PETSc.package.NewPackage.executeShellCommand('cd '+self.packageDir+' && make && make install && make clean', timeout=2500, log = self.framework.log)
+        output,err,ret  = PETSc.package.NewPackage.executeShellCommand('cd '+self.packageDir+' && '+self.make.make_jnp+' && '+self.make.make+' install && '+self.make.make+' clean', timeout=2500, log = self.framework.log)
       except RuntimeError, e:
         raise RuntimeError('Error running make; make install on cmake: '+str(e))
       self.postInstall(output+err,'cmake.args')

File config/PETSc/packages/ctetgen.py

View file
  • Ignore whitespace
 class Configure(PETSc.package.NewPackage):
   def __init__(self, framework):
     PETSc.package.NewPackage.__init__(self, framework)
-    self.gitcommit         = 'fdecceecbcd917ed36bbdab98210e7a37bf7e613'
+    self.gitcommit         = '6952da917114e8c3788a9f22df1b7aaa21335a13'
     self.giturls           = ['https://bitbucket.org/petsc/ctetgen.git']
     self.download          = ['http://ftp.mcs.anl.gov/pub/petsc/externalpackages/ctetgen-0.1.tar.gz']
     self.functions         = []

File config/PETSc/packages/lgrind.py

View file
  • Ignore whitespace
   def configure(self):
     import os
     '''Determine whether the Lgrind exist or not'''
-    if self.petscdir.isClone:
+    if self.petscclone.isClone:
       if self.framework.argDB['with-lgrind']:
         self.framework.logPrint('PETSc clone, checking for Lgrind\n')
         self.installDir  = os.path.join(self.petscdir.dir,self.arch)

File config/PETSc/packages/sowing.py

View file
  • Ignore whitespace
     # If download option is specified always build sowing
     if self.framework.argDB['download-sowing']:
       PETSc.package.NewPackage.configure(self)
-      if self.petscdir.isClone:
+      if self.petscclone.isClone:
         self.framework.logPrint('PETSc clone, Building FortranStubs [with download-sowing=1]\n')
         self.buildFortranStubs()
       else:
       return
 
     # autodetect if sowing/bfort is required
-    if self.petscdir.isClone:
+    if self.petscclone.isClone:
       self.framework.logPrint('PETSc clone, checking for Sowing or if it is needed\n')
 
       self.getExecutable('bfort', getFullPath = 1)

File config/PETSc/packages/spai.py

View file
  • Ignore whitespace
 class Configure(PETSc.package.NewPackage):
   def __init__(self, framework):
     PETSc.package.NewPackage.__init__(self, framework)
-    self.download  = ['http://ftp.mcs.anl.gov/pub/petsc/externalpackages/spai_3.0-mar-06.tar.gz']
+    self.download  = ['http://ftp.mcs.anl.gov/pub/petsc/externalpackages/spai-3.0-p1.tar.gz']
     self.functions = ['bspai']
     self.includes  = ['spai.h']
     self.liblist   = [['libspai.a']]
     elif self.blasLapack.mangling == 'caps': FTNOPT = ''
     else:                                          FTNOPT = '-DSP2'
 
-    args = 'CC = '+self.framework.getCompiler()+'\nCFLAGS = -DMPI '+FTNOPT+' '+self.framework.getCompilerFlags()+' '+self.headers.toString(self.mpi.include)+'\n'
+    args = 'CC = '+self.framework.getCompiler()+'\nCFLAGS = -DSPAI_USE_MPI '+FTNOPT+' '+self.framework.getCompilerFlags()+' '+self.headers.toString(self.mpi.include)+'\n'
     args = args+'AR         = '+self.setCompilers.AR+'\n'
     args = args+'ARFLAGS    = '+self.setCompilers.AR_FLAGS+'\n'
 

File config/PETSc/utilities/Regression.py

View file
  • Ignore whitespace
     self.compilers     = framework.require('config.compilers', self)
     self.mpi           = framework.require('config.packages.MPI', self)
     self.x             = framework.require('PETSc.packages.X', self)
+    self.fortrancpp    = framework.require('PETSc.utilities.fortranCPP', self)
     return
 
   def configureRegression(self):
       jobs.append('C')
       if self.x.found:
         jobs.append('C_X')
-      if hasattr(self.compilers, 'FC'):
+      if hasattr(self.compilers, 'FC') and self.fortrancpp.fortranDatatypes:
+        jobs.append('F90_DataTypes')
+      elif hasattr(self.compilers, 'FC'):
         jobs.append('Fortran')
         if self.compilers.fortranIsF90:
           rjobs.append('F90')

File config/PETSc/utilities/arch.py

View file
  • Ignore whitespace
     help.addArgument('PETSc', '-with-petsc-arch=<string>',nargs.Arg(None, None, 'The configuration name'))
     return
 
-  def setupDependencies(self, framework):
-    config.base.Configure.setupDependencies(self, framework)
-    self.petscdir = framework.require('PETSc.utilities.petscdir', self)
-    self.languages = framework.require('PETSc.utilities.languages', self)
-    self.compilerFlags = framework.require('config.compilerFlags', self)
-    return
-
   def configureArchitecture(self):
     '''Checks PETSC_ARCH and sets if not set'''
 
       else:
         import sys
         self.arch = 'arch-' + sys.platform.replace('cygwin','mswin')
-        # use opt/debug, c/c++ tags.
-        self.arch+= '-'+self.languages.clanguage.lower()
-        if self.compilerFlags.debugging:
+        # use opt/debug, c/c++ tags.s
+        self.arch+= '-'+self.framework.argDB['with-clanguage'].lower().replace('+','x')
+        if self.framework.argDB['with-debugging']:
           self.arch += '-debug'
         else:
           self.arch += '-opt'

File config/PETSc/utilities/petscclone.py

View file
  • Ignore whitespace
+import config.base
+import os
+import re
+
+class Configure(config.base.Configure):
+  def __init__(self, framework):
+    config.base.Configure.__init__(self, framework)
+    return
+
+  def setupDependencies(self, framework):
+    self.sourceControl = framework.require('config.sourceControl',self)
+    self.petscdir = framework.require('PETSc.utilities.petscdir', self)
+    return
+
+  def configureInstallationMethod(self):
+    if os.path.exists(os.path.join(self.petscdir.dir,'bin','maint')):
+      self.logPrint('bin/maint exists. This appears to be a repository clone')
+      self.isClone = 1
+      if os.path.exists(os.path.join(self.petscdir.dir, '.git')):
+        if hasattr(self.sourceControl,'git'):
+          self.addDefine('VERSION_GIT','"'+os.popen("cd "+self.petscdir.dir+" && "+self.sourceControl.git+" log -1 --pretty=format:%H").read()+'"')
+          self.addDefine('VERSION_DATE_GIT','"'+os.popen("cd "+self.petscdir.dir+" && "+self.sourceControl.git+" log -1 --pretty=format:%ci").read()+'"')
+        else:
+          self.logPrintBox('\n*****WARNING: PETSC_DIR appears to be a Git clone - but git is not found in PATH********\n')
+      elif os.path.exists(os.path.join(self.petscdir.dir, '.hg')):
+        if hasattr(self.sourceControl,'hg'):
+          self.addDefine('VERSION_HG','"'+os.popen(self.sourceControl.hg +" -R"+self.petscdir.dir+" tip --template '{node}'").read()+'"')
+          self.addDefine('VERSION_DATE_HG','"'+os.popen(self.sourceControl.hg +" -R"+self.petscdir.dir+" tip --template '{date|date}'").read()+'"')
+        else:
+          self.logPrintBox('\n*****WARNING: PETSC_DIR appears to be a mercurial clone - but hg is not found in PATH********\n')
+      else:
+        self.logPrint('This repository clone is obtained as a tarball as neither .hg nor .git dirs exist!')
+    else:
+      if os.path.exists(os.path.join(self.petscdir.dir, '.git')) or os.path.exists(os.path.join(self.petscdir.dir, '.hg')):
+        raise RuntimeError('Your petsc-dev directory is broken, remove the entire directory and start all over again')
+      else:
+        self.logPrint('This is a tarball installation')
+        self.isClone = 0
+    return
+
+  def configure(self):
+    self.executeTest(self.configureInstallationMethod)
+    return

File config/PETSc/utilities/petscdir.py

View file
  • Ignore whitespace
     help.addArgument('PETSc', '-PETSC_DIR=<root-dir>',                        nargs.Arg(None, None, 'The root directory of the PETSc installation'))
     return
 
-  def setupDependencies(self, framework):
-    self.sourceControl = framework.require('config.sourceControl',self)
-    self.programs      = framework.require('config.programs',self)
-    return
-
   def configureDirectories(self):
     '''Checks PETSC_DIR and sets if not set'''
     if 'PETSC_DIR' in self.framework.argDB:
       self.dir = os.getcwd()
     if self.isPetsc and not os.path.realpath(self.dir) == os.path.realpath(os.getcwd()):
       raise RuntimeError('The environmental variable PETSC_DIR '+self.dir+' MUST be the current directory '+os.getcwd())
-    if self.dir[1] == ':':
-      try:
-        dir = self.dir.replace('\\','/')
-        (dir, error, status) = self.executeShellCommand('cygpath -au '+dir)
-        self.dir = dir.replace('\n','')
-      except RuntimeError:
-        pass
     self.version  = 'Unknown'
     versionHeader = os.path.join(self.dir, 'include', 'petscversion.h')
     versionInfo = []
     for line in versionInfo:
       self.logPrint(line)
     self.addMakeMacro('DIR', self.dir)
-    self.addDefine('DIR', '"'+self.dir+'"')
     self.framework.argDB['search-dirs'].append(os.path.join(self.dir, 'bin', 'win32fe'))
 
     return
 
-  def configureInstallationMethod(self):
-    if os.path.exists(os.path.join(self.dir,'bin','maint')):
-      self.logPrint('bin/maint exists. This appears to be a repository clone')
-      self.isClone = 1
-      if os.path.exists(os.path.join(self.dir, '.git')):
-        if hasattr(self.sourceControl,'git'):
-          self.addDefine('VERSION_GIT','"'+os.popen("cd "+self.dir+" && "+self.sourceControl.git+" log -1 --pretty=format:%H").read()+'"')
-          self.addDefine('VERSION_DATE_GIT','"'+os.popen("cd "+self.dir+" && "+self.sourceControl.git+" log -1 --pretty=format:%ci").read()+'"')
-        else:
-          self.logPrintBox('\n*****WARNING: PETSC_DIR appears to be a Git clone - but git is not found in PATH********\n')
-      elif os.path.exists(os.path.join(self.dir, '.hg')):
-        if hasattr(self.sourceControl,'hg'):
-          self.addDefine('VERSION_HG','"'+os.popen(self.sourceControl.hg +" -R"+self.dir+" tip --template '{node}'").read()+'"')
-          self.addDefine('VERSION_DATE_HG','"'+os.popen(self.sourceControl.hg +" -R"+self.dir+" tip --template '{date|date}'").read()+'"')
-        else:
-          self.logPrintBox('\n*****WARNING: PETSC_DIR appears to be a mercurial clone - but hg is not found in PATH********\n')
-      else:
-        self.logPrint('This repository clone is obtained as a tarball as neither .hg nor .git dirs exist!')
-    else:
-      if os.path.exists(os.path.join(self.dir, '.git')) or os.path.exists(os.path.join(self.dir, '.hg')):
-        raise RuntimeError('Your petsc-dev directory is broken, remove the entire directory and start all over again')
-      else:
-        self.logPrint('This is a tarball installation')
-        self.isClone = 0
-    return
-
   def configure(self):
     self.executeTest(self.configureDirectories)
-    self.executeTest(self.configureInstallationMethod)
     return

File config/builder.py

View file
  • Ignore whitespace
                                                                  {'numProcs': 1, 'args': '-filename %(meshes)s/StaticMixer.cgns -interpolate 1 -dm_view', 'requires': ['CGNS']},
                                                                  # CGNS tests 12-
                                                                  {'numProcs': 1, 'args': '-filename %(meshes)s/doublet-tet.msh -interpolate 1 -dm_view'}],
-                        'src/dm/impls/plex/examples/tests/ex3': [{'numProcs': 1, 'args': '-petscspace_order 1 -num_comp 2 -qorder 1'},
+                        'src/dm/impls/plex/examples/tests/ex3': [# 0-2 2D P_1 on a triangle
+                                                                 {'numProcs': 1, 'args': '-petscspace_order 1 -num_comp 2 -qorder 1'},
                                                                  {'numProcs': 1, 'args': '-petscspace_order 1 -num_comp 2 -qorder 1 -porder 1'},
                                                                  {'numProcs': 1, 'args': '-petscspace_order 1 -num_comp 2 -qorder 1 -porder 2'},
+                                                                 # 3-5 3D P_1 on a tetrahedron
                                                                  {'numProcs': 1, 'args': '-dim 3 -petscspace_order 1 -num_comp 3 -qorder 1'},
                                                                  {'numProcs': 1, 'args': '-dim 3 -petscspace_order 1 -num_comp 3 -qorder 1 -porder 1'},
                                                                  {'numProcs': 1, 'args': '-dim 3 -petscspace_order 1 -num_comp 3 -qorder 1 -porder 2'},
+                                                                 # 6-8 2D P_2 on a triangle
                                                                  {'numProcs': 1, 'args': '-interpolate 1 -petscspace_order 2 -num_comp 2 -qorder 2'},
                                                                  {'numProcs': 1, 'args': '-interpolate 1 -petscspace_order 2 -num_comp 2 -qorder 2 -porder 1'},
-                                                                 {'numProcs': 1, 'args': '-interpolate 1 -petscspace_order 2 -num_comp 2 -qorder 2 -porder 2'}],
+                                                                 {'numProcs': 1, 'args': '-interpolate 1 -petscspace_order 2 -num_comp 2 -qorder 2 -porder 2'},
+                                                                 # 9-11 3D P_2 on a tetrahedron
+                                                                 {'numProcs': 1, 'args': '-dim 3 -interpolate 1 -petscspace_order 2 -num_comp 3 -qorder 2'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -interpolate 1 -petscspace_order 2 -num_comp 3 -qorder 2 -porder 1'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -interpolate 1 -petscspace_order 2 -num_comp 3 -qorder 2 -porder 2'},
+                                                                 # 12-14 2D P_1 on a quadrilaterial
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -num_comp 2 -qorder 1', 'requires': 'Broken'},
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -num_comp 2 -qorder 1 -porder 1', 'requires': 'Broken'},
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -num_comp 2 -qorder 1 -porder 2', 'requires': 'Broken'},
+                                                                 # 15-17 2D Q_1 on a quadrilaterial
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -petscspace_poly_tensor -num_comp 2 -qorder 1'},
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -petscspace_poly_tensor -num_comp 2 -qorder 1 -porder 1'},
+                                                                 {'numProcs': 1, 'args': '-simplex 0 -petscspace_order 1 -petscspace_poly_tensor -num_comp 2 -qorder 1 -porder 2'}],
                         'src/dm/impls/plex/examples/tests/ex4': [# 2D Simplex 0-3
                                                                  {'numProcs': 1, 'args': '-dim 2 -cell_hybrid 0 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
                                                                  {'numProcs': 2, 'args': '-dim 2 -cell_hybrid 0 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 2 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 2, 'args': '-dim 2 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
                                                                  # 2D Hybrid Simplex 4-7
-                                                                 {'numProcs': 1, 'args': '-dim 2 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 1, 'args': '-dim 2 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 2 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 2 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 2 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 1, 'args': '-dim 2 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 2 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 2 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
                                                                  # 3D Simplex 8-11
-                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_hybrid 0 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_hybrid 0 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_hybrid 0 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_hybrid 0 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail'},
                                                                  # 2D Quad 12-13
-                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_simplex 0 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 2 -cell_simplex 0 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_simplex 0 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 2, 'args': '-dim 2 -cell_simplex 0 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
                                                                  # 3D Hex 14-15
-                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -cell_hybrid 0 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -cell_hybrid 0 -num_refinements 1 -dm_view ::ascii_info_detail'},
                                                                  # 3D Hybrid Simplex 16-19
-                                                                 {'numProcs': 1, 'args': '-dim 3 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 1, 'args': '-dim 3 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
                                                                  # 3D Hybrid Hex 20-23
-                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -refinement_uniform 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -refinement_uniform 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
-                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
-                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
-                                                                 # 2D Hybrid Simplex 24-
-                                                                 {'numProcs': 1, 'args': '-dim 2 -test_num 1 -refinement_uniform 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 # 2D Hybrid Simplex 24-24
+                                                                 {'numProcs': 1, 'args': '-dim 2 -test_num 1 -num_refinements 1 -dm_view ::ascii_info_detail', 'requires': 'Broken'},
+                                                                 # 3D Multiple Refinement 25-26
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_hybrid 0 -test_num 2 -num_refinements 2 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -cell_hybrid 0 -test_num 1 -num_refinements 2 -dm_view ::ascii_info_detail'},
 ],
                         'src/dm/impls/plex/examples/tests/ex5': [# 2D Simplex 0-1
                                                                  {'numProcs': 1, 'args': '-dim 2 -dm_view ::ascii_info_detail'},
                                                                  # 3D Hex 6-7
                                                                  {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -dm_view ::ascii_info_detail'},
                                                                  {'numProcs': 2, 'args': '-dim 3 -cell_simplex 0 -dm_view ::ascii_info_detail'},
-                                                                 # Examples from PyLith 8-11
+                                                                 # Examples from PyLith 8-12
                                                                  {'numProcs': 1, 'args': '-dim 2 -test_num 1 -dm_view ::ascii_info_detail'},
                                                                  {'numProcs': 1, 'args': '-dim 3 -test_num 1 -dm_view ::ascii_info_detail'},
                                                                  {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -test_num 1 -dm_view ::ascii_info_detail'},
-                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_simplex 0 -test_num 1 -dm_view ::ascii_info_detail'},],
+                                                                 {'numProcs': 1, 'args': '-dim 2 -cell_simplex 0 -test_num 1 -dm_view ::ascii_info_detail'},
+                                                                 {'numProcs': 1, 'args': '-dim 3 -cell_simplex 0 -test_num 2 -dm_view ::ascii_info_detail'},],
                         'src/dm/impls/plex/examples/tests/ex6': [{'numProcs': 1, 'args': '-malloc_dump'},
                                                                  {'numProcs': 1, 'args': '-malloc_dump -pend 10000'},
                                                                  {'numProcs': 1, 'args': '-malloc_dump -pend 10000 -fill 0.05'},
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type dirichlet -interpolate 0 -petscspace_order 1 -show_initial -dm_plex_print_fem 1 -dm_view'},
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type dirichlet -interpolate 1 -petscspace_order 1 -show_initial -dm_plex_print_fem 1 -dm_view'},
                                                                {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0125 -bc_type dirichlet -interpolate 1 -petscspace_order 1 -show_initial -dm_plex_print_fem 1 -dm_view'},
-                                                               {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type neumann   -interpolate 1 -petscspace_order 1 -bd_petscspace_order 1 -snes_fd -show_initial -dm_plex_print_fem 1 -dm_view',
-                                                                'requires': ['Broken']},
+                                                               {'numProcs': 1, 'args': '-run_type test -dim 3 -refinement_limit 0.0    -bc_type neumann   -interpolate 1 -petscspace_order 1 -bd_petscspace_order 1 -snes_fd -show_initial -dm_plex_print_fem 1 -dm_view'},
                                                                # Analytic variable coefficient 13-20
                                                                {'numProcs': 1, 'args': '-run_type test -refinement_limit 0.0    -variable_coefficient analytic -interpolate 1 -petscspace_order 1 -show_initial -dm_plex_print_fem 1'},
                                                                {'numProcs': 1, 'args': '-run_type test -refinement_limit 0.0625 -variable_coefficient analytic -interpolate 1 -petscspace_order 1 -show_initial -dm_plex_print_fem 1'},
                                                                {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.0     -forcing_type cubic    -bc_type freeslip  -interpolate 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_0_fields 0,1 -pc_fieldsplit_1_fields 2 -pc_fieldsplit_type additive -fieldsplit_0_ksp_type fgmres -fieldsplit_0_pc_type fieldsplit -fieldsplit_0_pc_fieldsplit_type schur -fieldsplit_0_pc_fieldsplit_schur_factorization_type full -fieldsplit_0_fieldsplit_velocity_ksp_type preonly -fieldsplit_0_fieldsplit_velocity_pc_type lu -fieldsplit_0_fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_0_fieldsplit_pressure_pc_type jacobi -fieldsplit_temperature_ksp_type preonly -fieldsplit_temperature_pc_type lu -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'},
                                                                {'numProcs': 1, 'args': '-run_type full -refinement_limit 0.00625 -forcing_type cubic    -bc_type freeslip  -interpolate 1 -ksp_type fgmres -ksp_gmres_restart 100 -ksp_rtol 1.0e-9 -pc_type fieldsplit -pc_fieldsplit_0_fields 0,1 -pc_fieldsplit_1_fields 2 -pc_fieldsplit_type additive -fieldsplit_0_ksp_type fgmres -fieldsplit_0_pc_type fieldsplit -fieldsplit_0_pc_fieldsplit_type schur -fieldsplit_0_pc_fieldsplit_schur_factorization_type full -fieldsplit_0_fieldsplit_velocity_ksp_type preonly -fieldsplit_0_fieldsplit_velocity_pc_type lu -fieldsplit_0_fieldsplit_pressure_ksp_rtol 1e-10 -fieldsplit_0_fieldsplit_pressure_pc_type jacobi -fieldsplit_temperature_ksp_type preonly -fieldsplit_temperature_pc_type lu -snes_monitor_short -ksp_monitor_short -snes_converged_reason -snes_view -show_solution 0'}],
                         'src/snes/examples/tutorials/ex33':   [{'numProcs': 1, 'args': '-snes_converged_reason -snes_monitor_short'}],
+                        'src/snes/examples/tutorials/ex36':   [# 2D serial P2/P1 tests 0-1
+                                                               {'numProcs': 1, 'args': ''}],
                         'src/snes/examples/tutorials/ex52':   [# 2D Laplacian 0-3
                                                                {'numProcs': 1, 'args': '-dm_view -refinement_limit 0.0 -petscspace_order 1 -compute_function',
                                                                 'setup': './bin/pythonscripts/PetscGenerateFEMQuadrature.py 2 1 1 1 laplacian src/snes/examples/tutorials/ex52.h',

File config/cmakeboot.py

View file
  • Ignore whitespace
    import re
    m = re.match(r'cmake version (.+)$', output)
    if not m:
-       self.logPrintBox('Could not parse CMake version: %s, falling back to legacy build' % output)
+       self.logPrint('Could not parse CMake version: %s, disabling cmake build option' % output)
        return False
    from distutils.version import LooseVersion
    version = LooseVersion(m.groups()[0])
    if version < LooseVersion('2.6.2'):
-       self.logPrintBox('CMake version %s < 2.6.2, falling back to legacy build' % version.vstring)
+       self.logPrint('CMake version %s < 2.6.2, disabling cmake build option' % version.vstring)
        return False
    if self.languages.clanguage == 'Cxx' and version < LooseVersion('2.8'):
-       self.logPrintBox('Cannot use --with-clanguage=C++ with CMake version %s < 2.8, falling back to legacy build' % version.vstring)
+       self.logPrint('Cannot use --with-clanguage=C++ with CMake version %s < 2.8, disabling cmake build option' % version.vstring)
        return False # no support for: set_source_files_properties(${file} PROPERTIES LANGUAGE CXX)
 
    langlist = [('C','C')]
    log.write('Invoking: %s\n' % cmd)
    output,error,retcode = self.executeShellCommand(cmd, checkCommand = noCheck, log=log, cwd=archdir,timeout=300)
    if retcode:
-     self.logPrintBox('CMake setup incomplete (status %d), falling back to legacy build' % (retcode,))
+     self.logPrint('CMake setup incomplete (status %d), disabling cmake build option' % (retcode,))
      self.logPrint('Output: '+output+'\nError: '+error)
      cachetxt = os.path.join(archdir, 'CMakeCache.txt')
      try:

File config/examples/arch-linux-pkgs-dbg-ftn-interfaces.py

View file
  • Ignore whitespace
 #!/usr/bin/env python
 
 configure_options = [
+  '--with-cc=clang',
+  '--with-cxx=clang++',
+  '--with-fc=gfortran',
   '--with-debugging=1',
   '--with-fortran-interfaces=1',
   '--download-mpich=1',

File include/finclude/ftn-custom/petscdmda.h90

View file
  • Ignore whitespace
           PetscErrorCode ierr
           DM_HIDE   v
         End Subroutine
+        Subroutine DMDARestoreGlobalIndicesF90(v,n,array,ierr)
+          USE_DM_HIDE
+          PetscInt, pointer :: array(:)
+          PetscInt  n
+          PetscErrorCode ierr
+          DM_HIDE   v
+        End Subroutine
       End Interface
 
 

File include/finclude/petscpcdef.h

View file
  • Ignore whitespace
 #define PCML 'ml'
 #define PCGALERKIN 'galerkin'
 #define PCEXOTIC 'exotic'
-#define PCHMPI 'hmpi'
 #define PCSUPPORTGRAPH 'supportgraph'
 #define PCASA 'asa'
 #define PCCP 'cp'

File include/petsc-private/dmdaimpl.h

View file
  • Ignore whitespace
   PetscInt              xs,xe,ys,ye,zs,ze;     /* range of local values */
   PetscInt              Xs,Xe,Ys,Ye,Zs,Ze;     /* range including ghost values
                                                    values above already scaled by w */
-  PetscInt              *idx,Nl;               /* local to global map */
   PetscInt              base;                  /* global number of 1st local node, includes the * w term */
   DMDABoundaryType      bx,by,bz;              /* indicates type of ghost nodes at boundary */
   VecScatter            gtol,ltog,ltol;        /* scatters, see below for details */

File include/petsc-private/fortranimpl.h

View file
  • Ignore whitespace
 
 PETSC_EXTERN PetscErrorCode PetscScalarAddressToFortran(PetscObject,PetscInt,PetscScalar*,PetscScalar*,PetscInt,size_t*);
 PETSC_EXTERN PetscErrorCode PetscScalarAddressFromFortran(PetscObject,PetscScalar*,size_t,PetscInt,PetscScalar **);
-PETSC_EXTERN size_t         PetscIntAddressToFortran(PetscInt*,PetscInt*);
-PETSC_EXTERN PetscInt        *PetscIntAddressFromFortran(PetscInt*,size_t);
+PETSC_EXTERN size_t         PetscIntAddressToFortran(const PetscInt*,const PetscInt*);
+PETSC_EXTERN PetscInt        *PetscIntAddressFromFortran(const PetscInt*,size_t);
 PETSC_EXTERN char   *PETSC_NULL_CHARACTER_Fortran;
 PETSC_EXTERN void    *PETSC_NULL_INTEGER_Fortran;
 PETSC_EXTERN void    *PETSC_NULL_SCALAR_Fortran;

File include/petsc-private/matimpl.h

View file
  • Ignore whitespace
 #endif
   void                   *spptr;          /* pointer for special library like SuperLU */
   MatSolverPackage       solvertype;
-  PetscViewer            viewonassembly;         /* the following are set in MatSetFromOptions() and used in MatAssemblyEnd() */
-  PetscViewerFormat      viewformatonassembly;
   PetscBool              checksymmetryonassembly,checknullspaceonassembly;
   PetscReal              checksymmetrytol;
   };
     lnk_empty - flg indicating the list is empty
 */
 #define PetscLLCreate(idx_start,lnk_max,nlnk,lnk,bt) \
-  (PetscMalloc(nlnk*sizeof(PetscInt),&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk[idx_start] = lnk_max,0))
+  (PetscMalloc1(nlnk,&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk[idx_start] = lnk_max,0))
 
 #define PetscLLCreate_new(idx_start,lnk_max,nlnk,lnk,bt,lnk_empty)\
-  (PetscMalloc(nlnk*sizeof(PetscInt),&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk_empty = PETSC_TRUE,0) ||(lnk[idx_start] = lnk_max,0))
+  (PetscMalloc1(nlnk,&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk_empty = PETSC_TRUE,0) ||(lnk[idx_start] = lnk_max,0))
 
 /*
   Add an index set into a sorted linked list
     bt        - PetscBT (bitarray) with all bits set to false
 */
 #define PetscIncompleteLLCreate(idx_start,lnk_max,nlnk,lnk,lnk_lvl,bt)\
-  (PetscMalloc(2*nlnk*sizeof(PetscInt),&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk[idx_start] = lnk_max,lnk_lvl = lnk + nlnk,0))
+  (PetscMalloc1(2*nlnk,&lnk) || PetscBTCreate(nlnk,&(bt)) || (lnk[idx_start] = lnk_max,lnk_lvl = lnk + nlnk,0))
 
 /*
   Initialize a sorted linked list used for ILU and ICC
   PetscInt       *llnk;
 
   PetscFunctionBegin;
-  ierr = PetscMalloc(2*(nlnk_max+2)*sizeof(PetscInt),lnk);CHKERRQ(ierr);
+  ierr = PetscMalloc1(2*(nlnk_max+2),lnk);CHKERRQ(ierr);
   ierr = PetscBTCreate(lnk_max,bt);CHKERRQ(ierr);
   llnk = *lnk;
   llnk[0] = 0;         /* number of entries on the list */
   PetscInt       *llnk;
 
   PetscFunctionBegin;
-  ierr = PetscMalloc(2*(nlnk_max+2)*sizeof(PetscInt),lnk);CHKERRQ(ierr);
+  ierr = PetscMalloc1(2*(nlnk_max+2),lnk);CHKERRQ(ierr);
   llnk = *lnk;
   llnk[0] = 0;               /* number of entries on the list */
   llnk[2] = PETSC_MAX_INT;   /* value in the head node */
   PetscInt       *llnk;
 
   PetscFunctionBegin;
-  ierr = PetscMalloc(3*(nlnk_max+3)*sizeof(PetscInt),lnk);CHKERRQ(ierr);
+  ierr = PetscMalloc1(3*(nlnk_max+3),lnk);CHKERRQ(ierr);
   llnk = *lnk;
   llnk[0] = 0;   /* nlnk: number of entries on the list */
   llnk[1] = 0;          /* number of integer entries represented in list */

File include/petsc-private/pcimpl.h

View file
  • Ignore whitespace
   Mat            mat,pmat;
   Vec            diagonalscaleright,diagonalscaleleft; /* used for time integration scaling */
   PetscBool      diagonalscale;
-  PetscBool      nonzero_guess; /* used by PCKSP, PCREDUNDANT and PCHMPI */
+  PetscBool      nonzero_guess; /* used by PCKSP, PCREDUNDANT */
   PetscBool      useAmat; /* used by several PC that including applying the operator inside the preconditioner */
   PetscErrorCode (*modifysubmatrices)(PC,PetscInt,const IS[],const IS[],Mat[],void*); /* user provided routine */
   void           *modifysubmatricesP; /* context for user routine */

File include/petsc-private/petscfeimpl.h

View file
  • Ignore whitespace
 typedef struct {
   PetscInt   numVariables; /* The number of variables in the space, e.g. x and y */
   PetscBool  symmetric;    /* Use only symmetric polynomials */
+  PetscBool  tensor;       /* Flag for tensor product */
   PetscInt  *degrees;      /* Degrees of single variable which we need to compute */
 } PetscSpace_Poly;
 
 };
 
 typedef struct {
-  PetscInt  cellType;
   PetscInt *numDof;
+  PetscBool simplex;
 } PetscDualSpace_Lag;
 
 typedef struct _PetscFEOps *PetscFEOps;
   PetscInt cellType;
 } PetscFE_Basic;
 
+typedef struct {
+  PetscInt dummy;
+} PetscFE_Nonaffine;
+
 #ifdef PETSC_HAVE_OPENCL
 
 #ifdef __APPLE__

File include/petsc-private/petscimpl.h

View file
  • Ignore whitespace
 
 @*/
 #define PetscHeaderCreate(h,tp,pops,classid,class_name,descr,mansec,com,des,vie) \
-  (PetscNew(struct tp,&(h)) ||                                                  \
-   PetscNew(PetscOps,&(((PetscObject)(h))->bops)) ||                            \
-   PetscNew(pops,&((h)->ops)) ||                                                \
+  (PetscNew(&(h)) ||                                                  \
+   PetscNew(&(((PetscObject)(h))->bops)) ||                            \
+   PetscNew(&((h)->ops)) ||                                                \
    PetscHeaderCreate_Private((PetscObject)h,classid,class_name,descr,mansec,com,(PetscObjectFunction)des,(PetscObjectViewerFunction)vie) || \
    PetscLogObjectCreate(h) ||                                                   \
    PetscLogObjectMemory((PetscObject)h, sizeof(struct tp) + sizeof(PetscOps) + sizeof(pops)))

File include/petsc-private/vecimpl.h

View file
  • Ignore whitespace
   PetscBool              array_gotten;
   VecStash               stash,bstash; /* used for storing off-proc values during assembly */
   PetscBool              petscnative;  /* means the ->data starts with VECHEADER and can use VecGetArrayFast()*/
-  PetscViewer            viewonassembly;   /* if -vec_view is set in VecSetFromOptions() then these variables are used to implement it */
-  PetscViewerFormat      viewformatonassembly;
 #if defined(PETSC_HAVE_CUSP)
   PetscCUSPFlag          valid_GPU_array;    /* indicates where the most recently modified vector data is (GPU or CPU) */
   void                   *spptr; /* if we're using CUSP, then this is the special pointer to the array on the GPU */

File include/petscao.h

View file
  • Ignore whitespace
 PETSC_EXTERN PetscErrorCode AOCreateMappingIS(IS,IS,AO*);
 
 PETSC_EXTERN PetscErrorCode AOView(AO,PetscViewer);
-PETSC_EXTERN PetscErrorCode AOViewFromOptions(AO,const char*,const char*);
+PETSC_STATIC_INLINE PetscErrorCode AOViewFromOptions(AO A,const char prefix[],const char name[]) {return PetscObjectViewFromOptions((PetscObject)A,prefix,name);}
 PETSC_EXTERN PetscErrorCode AODestroy(AO*);
 
 /* Dynamic creation and loading functions */

File include/petscdm.h

View file
  • Ignore whitespace
 PETSC_EXTERN PetscErrorCode DMRestrict(DM,Mat,Vec,Mat,DM);
 PETSC_EXTERN PetscErrorCode DMInterpolate(DM,Mat,DM);
 PETSC_EXTERN PetscErrorCode DMSetFromOptions(DM);
-PETSC_EXTERN PetscErrorCode DMViewFromOptions(DM,const char[], const char[]);
+PETSC_STATIC_INLINE PetscErrorCode DMViewFromOptions(DM A,const char prefix[],const char name[]) {return PetscObjectViewFromOptions((PetscObject)A,prefix,name);}
 
 PETSC_EXTERN PetscErrorCode DMSetUp(DM);
 PETSC_EXTERN PetscErrorCode DMCreateInterpolationScale(DM,DM,Mat,Vec*);
 
 PETSC_EXTERN PetscErrorCode DMGetCoordinateDM(DM,DM*);
 PETSC_EXTERN PetscErrorCode DMSetCoordinateDM(DM,DM);
+PETSC_EXTERN PetscErrorCode DMGetCoordinateSection(DM,PetscSection*);