Home
last modified time | relevance | path

Searched refs:replace (Results 1 – 25 of 105) sorted by relevance

12345

/petsc/lib/petsc/bin/maint/generators/
H A Djava.py19 def replace(enums,senums,structs,aliases,classes,k): function
20 k = k.replace("*","")
21 for l in aliases: k = k.replace(l,aliases[l])
22 k = k.replace("char[]","String").replace("char*","String").replace("char","String");
23 for l in senums: k = k.replace(l,"String")
24 k = k.replace("void","int")
25 k = k.replace("PetscBool","boolean")
26 k = k.replace("*","")
27 k = k.replace("unsigned","")
28 k = k.replace("const","")
[all …]
H A Dd.py66 outfile.write(k.replace("const ","").replace("unsigned long","ulong"))
/petsc/config/
H A Dconfigure.py37 raise ValueError('The option '+name+' should probably be '+name.replace('_', '-'));
41 raise ValueError('The option '+opt+' should probably be '+opt.replace('ifneeded', '1'));
43 if name.find(exc.replace('_','-')) > -1:
44 raise ValueError('The option '+opt+' should be '+opt.replace(exc.replace('_','-'),exc));
70 raise ValueError('The option '+opt+' should probably be '+opt.replace(oldname,newname))
101 name = name.replace(en_dash,'-')
106 name = name.replace('enable-cxx','with-clanguage=C++',1)
110 name = head.replace('enable-cxx','with-clanguage=C',1)
112 name = head.replace('enable-cxx','with-clanguage=C++',1)
117 name = name.replace('disable-cxx','with-clanguage=C',1)
[all …]
H A Dquery_tests.py56 path=path.strip().replace(petscdir,'')
57 path=path.replace('src/','')
59 prefix=os.path.dirname(path).replace("/","_")
64 label=path.replace("/","_").replace('tests_','tests-').replace('tutorials_','tutorials-')
98 llist=labels.replace('|',',').split(',')
100 for field in fields.replace('|',',').split(','):
153 for field in fields.replace('|',',').split(','):
286 suffix = string.replace(pardir,'') # get whatever is left over
289 pathlike = pathlike.replace(os.path.sep.join(('share','petsc','examples'))+'/','')
291 pathlike = pathlike.replace('diff-','')
[all …]
H A Dinstall.py202 self.copies.extend(self.copytree(root, root.replace(src,dst)))
278 line = line.replace('PETSC_CC_INCLUDES_INSTALL', 'PETSC_CC_INCLUDES')
279 line = line.replace('PETSC_FC_INCLUDES_INSTALL', 'PETSC_FC_INCLUDES')
281 line = line.replace('${PETSC_DIR}/${PETSC_ARCH}', self.installDir)
282 line = line.replace('PETSC_ARCH=${PETSC_ARCH}', '')
283 line = line.replace('${PETSC_DIR}', self.installDir)
285 line = line.replace(self.archLibDir,self.installLibDir)
287 line = line.replace(self.rootBinDir,self.destBinDir)
345 contents = contents.replace(self.installDir, '${PETSC_DIR}')
346 contents = contents.replace(self.rootDir, '${PETSC_DIR}')
[all …]
/petsc/config/BuildSystem/config/
H A Dheaders.py24 include = include.replace('\\ ',' ').replace(' ', '\\ ')
25 include = include.replace('\\(','(').replace('(', '\\(')
26 include = include.replace('\\)',')').replace(')', '\\)')
38 include = include.replace('\\ ',' ').replace(' ', '\\ ')
39 include = include.replace('\\(','(').replace('(', '\\(')
40 include = include.replace('\\)',')').replace(')', '\\)')
75 return 'HAVE_'+header.upper().replace('.', '_').replace('/', '_')
H A Dlibraries.py60 …return [library.replace('\\ ',' ').replace(' ', '\\ ').replace('\\(','(').replace('(', '\\(').repl…
64 …s.path.dirname(library).replace('\\ ',' ').replace(' ', '\\ ').replace('\\(','(').replace('(', '\\…
104 …LIB'+self.getLibName(library).upper().replace('-','_').replace('=','_').replace('+','_').replace('…
H A Dtypes.py102 typename = typeName.replace(' ', '-').replace('*', 'p')
130 self.addDefine('SIZEOF_'+typename.replace('-', '_').upper(), str(size))
H A DcompilerOptions.py18 … self.framework.addMakeMacro('MPICC_SHOW',output.strip().replace('\n','\\\\n').replace('"','\\"'))
133 self.framework.addMakeMacro('MPICXX_SHOW',output.strip().replace('\n','\\\\n'))
247 self.framework.addMakeMacro('MPIFC_SHOW',output.strip().replace('\n','\\\\n'))
368 version = version.replace('\r','')
/petsc/lib/petsc/bin/
H A Dtaucc.py58 if line.find('TAU_INSTRUMENT0R:') >= 0: tau_instr = line.replace('TAU_INSTRUMENT0R:','')
59 elif line.find('TAU_DEFS:') >= 0: tau_defs = line.replace('TAU_DEFS:',' ')
60 elif line.find('TAU_INCLUDE:') >= 0: tau_include = line.replace('TAU_INCLUDE:',' ')
61 elif line.find('TAU_LIBS:') >= 0: tau_libs = line.replace('TAU_LIBS:',' ')
62 elif line.find('TAU_MPI_INC:') >= 0: tau_mpi_inc = line.replace('TAU_MPI_INC:',' ')
63 elif line.find('TAU_MPI_LIBS:') >= 0: tau_mpi_libs = line.replace('TAU_MPI_LIBS:',' ')
64 elif line.find('TAU_CXXLIBS:') >= 0: tau_cxxlibs = line.replace('TAU_CXXLIBS:',' ')
112 arg=arg.replace('"','\\"')
H A DgetAPI.py241 line = line.replace('#include <','').replace('>','').strip()
254 file = os.path.basename(filename).replace('types.h','.h')
268 struct = struct.replace("\\","")
269 struct = struct.replace("\n","")
270 struct = struct.replace(";","")
271 struct = struct.replace("typedef enum","")
276 name = name.replace("} ","")
297 file = os.path.basename(filename).replace('types.h','.h')
318 file = os.path.basename(filename).replace('types.h','.h')
338 file = os.path.basename(filename).replace('types.h','.h')
[all …]
H A Dpetscnagfor89 error = error.replace('-rpath ','-Wl,-rpath')
106 i = i.replace(';',' ')
109 i = i.replace(j+' ','-Wl,'+j+',').strip()
111 i = i.replace(' -PIC','').strip()
113 i = i.replace(' -options','').strip()
114 i = i.replace(' -C=',' -options -C=') # note -C=xxx requires options but -C does not
115 i = i.replace(' -O',' -options -O')
116 i = i.replace(' -gline',' -options -gline') # note this is actually not needed
H A Dgeneratefortranbindings.py53 ktypename = k.typename.replace('MPI_', 'MPIU_').replace('MPIU_Fint', 'MPI_Fint')
81 …with open(os.path.join(petscarch, 'include', pkgname, 'finclude', file.replace('.h90', '.h')),'a')…
148 ktypename = k.typename.replace('MPI_', 'MPIU_').replace('MPIU_Fint', 'MPI_Fint')
228 filename = fun.file.replace('.h','.c')
230 dir = os.path.join(petscarch,fun.dir.replace('src/','ftn/'))
237 with open(os.path.join(dir,filename.replace('.c','f.c')),'a') as fd:
242 fd.write('#include <' + pkgname + fun.includefile.replace(pkgname,'') + '>\n')
268 ktypename = k.typename.replace('MPI_', 'MPIU_').replace('MPIU_Fint', 'MPI_Fint')
436 fout.write(fin.read().replace('petscdir.mk','../petscdir.mk'))
438 …print('Fix the manual stub for ' + fun.name + ' in ' + os.path.join(dir,filename.replace('.c','f.c…
[all …]
/petsc/lib/petsc/bin/maint/
H A Dexampleslog.py29 testnm=testname.replace("diff-","")
37 splt[0].replace("_","/"),"examples",tdir)
106 lfile=logfile.replace("examples_","").replace(".log","")
110 fname=os.path.relpath(filename,self.petsc_dir).replace("src/","")
111 testname=test.replace("diff-","") if test.startswith("diff-") else test
235 gitPerson=gp.replace("<","&lt").replace("<","&gt")
253 archstr=[arch.replace(branch+'_','').replace("arch-",'') for arch in arches]
304 gitPerson=testDict[fname]['gitPerson'].replace("<","&lt").replace("<","&gt")
319 archstr=[arch.replace(branch+'_','').replace("arch-",'') for arch in arches]
369 archstr=[arch.replace(branch+'_','').replace("arch-",'') for arch in arches]
[all …]
H A Dpetscdt_create_quadrature_headers.py105 exname = name.replace('compact','expand_baryc')
151 guard = filename.replace('.','_').upper()
166 …"PetscRealConstant({0:e})".format(w) for w in rule['weights']]).replace('[',' ').replace("'","").s…
173 …wide.pformat(["PetscRealConstant({0:e})".format(w) for w in node]).replace('[',' ').replace("'","")
H A Dcheck_header_guard.py73 def replace(self, last_line: str, line: str, ret: list[str]) -> list[str]: member in Replacer
98 def replace(self, prev_line: str, line: str, ret: list[str]) -> list[str]: member in PragmaOnce
119 ret = super().replace(prev_line, line, ret)
200 def replace(self, prev_line: str, line: str, ret: list[str]) -> list[str]: member in VerboseHeaderGuard
226 ret = super().replace(prev_line, line, ret)
336 ret = replacer.replace(prev_line, line, ret)
H A Dbranches.py45 commithash = commithash.replace("\r", "").replace("\n", "")
/petsc/config/PETSc/options/
H A Dlanguages.py31 … self.clanguage = self.framework.argDB['with-clanguage'].upper().replace('+','x').replace('X','x')
43 …icelanguage = self.framework.argDB['with-devicelanguage'].upper().replace('+','x').replace('X','x')
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/
H A Dtest_main.py53 replace: bool = False,
82 if replace:
97 return [] if text is None else [l.replace(str(petsc_dir), '.') for l in text.splitlines(True)]
106 lines[0] = lines[0].replace(out_file, str(new_path))
107 lines[1] = lines[1].replace(out_file, str(new_path))
155 if not replace:
/petsc/lib/petsc/bin/maint/abi-compliance-checker/modules/Internals/Scripts/
H A DSections.js8 header.innerHTML = header.innerHTML.replace(/\[[^0-9 ]\]/gi,"[&minus;]");
14 header.innerHTML = header.innerHTML.replace(/\[[^0-9 ]\]/gi,"[+]");
/petsc/share/petsc/
H A Dchkerrconvert.py43 chkerr_suff = chkerr.replace('CHKERR','')
44 replace = 'PetscCall'
48 replace += 'Void'
50 replace += chkerr_suff.title()
55 replace += 'Throw'
57 replace += chkerr_suff
58 return '{}({})'.format(replace,ierr)
/petsc/config/BuildSystem/config/packages/
H A Dkokkos.py125 args.append('-DCMAKE_CXX_FLAGS="'+cudaFlags.replace('-x cuda', '')+'"')
127 args.append('-DKOKKOS_CUDA_OPTIONS="'+cudaFlags.replace(' ', ';')+'"')
131 args = [a.replace('-Og', '-O1') if a.startswith('-DCMAKE_CXX_FLAG') else a for a in args]
175 args.append('-DKOKKOS_HIP_OPTIONS="'+hipFlags.replace(' ',';')+'"')
/petsc/share/petsc/saws/js/
H A DmatrixTex.js18 var subscript = endtag.replace(/_/g, ",");
51 var subscript = childEndtag.replace(/_/g, ",");
/petsc/doc/
H A Dfix_pydata_margins.py12 …str = str.replace('var(--pst-font-size-h2)}','var(--pst-font-size-h2);margin-bottom:4px;margin-top…
/petsc/config/BuildSystem/
H A Dnargs.py108 argList[l] = name.replace('enable-','with-')
111 argList[l] = name.replace('disable-','with-')
113 elif name.endswith('=1'): argList[l].replace('=1','=0')
115 argList[l] = name.replace('without-','with-')
117 elif name.endswith('=1'): argList[l].replace('=1','=0')
498 value = 'git://https://'+(value[len('git@'):].replace(':','/'))

12345