162 global _outputdir, _reqnumber
163 print(
"Commands received running perfsuite for these jobs:")
176 topdir = os.path.join(_outputdir,
"request_" +
str(_reqnumber))
177 exists = os.path.exists(topdir)
182 curperfdir = os.path.abspath(os.path.join(topdir,
str(cmd_num)))
183 if not os.path.exists(curperfdir):
185 logfile = os.path.join(curperfdir,
"cmsPerfSuite.log")
186 if os.path.exists(logfile):
187 logfile = logfile +
str(cmd_num)
190 if cmd[
'cpus'] ==
"All":
191 print(
"Running performance suite on all CPUS!\n")
194 cmd[
"cpus"]=cmd[
"cpus"]+
str(cpu)+
"," 195 cmd[
"cpus"]=cmd[
"cpus"][:-1]
196 print(
"I.e. on cpus %s\n"%cmd[
"cpus"])
201 cmdwdefs[
"perfsuitedir" ] = curperfdir
202 cmdwdefs[
"TimeSizeEvents" ] =
getCPSkeyword(
"TimeSizeEvents" , cmd)
203 cmdwdefs[
"TimeSizeCandles" ] =
getCPSkeyword(
"TimeSizeCandles" , cmd)
204 cmdwdefs[
"TimeSizePUCandles" ] =
getCPSkeyword(
"TimeSizePUCandles" , cmd)
205 cmdwdefs[
"IgProfEvents" ] =
getCPSkeyword(
"IgProfEvents" , cmd)
206 cmdwdefs[
"IgProfCandles" ] =
getCPSkeyword(
"IgProfCandles" , cmd)
207 cmdwdefs[
"IgProfPUCandles" ] =
getCPSkeyword(
"IgProfPUCandles" , cmd)
208 cmdwdefs[
"CallgrindEvents" ] =
getCPSkeyword(
"CallgrindEvents" , cmd)
209 cmdwdefs[
"CallgrindCandles"] =
getCPSkeyword(
"CallgrindCandles" , cmd)
210 cmdwdefs[
"CallgrindPUCandles"] =
getCPSkeyword(
"CallgrindPUCandles" , cmd)
211 cmdwdefs[
"MemcheckEvents" ] =
getCPSkeyword(
"MemcheckEvents" , cmd)
212 cmdwdefs[
"MemcheckCandles" ] =
getCPSkeyword(
"MemcheckCandles" , cmd)
213 cmdwdefs[
"MemcheckPUCandles" ] =
getCPSkeyword(
"MemcheckPUCandles" , cmd)
215 cmdwdefs[
"cmsScimarkLarge" ] =
getCPSkeyword(
"cmsScimarkLarge" , cmd)
216 cmdwdefs[
"cmsdriverOptions"] =
getCPSkeyword(
"cmsdriverOptions", cmd)
217 cmdwdefs[
"stepOptions" ] =
getCPSkeyword(
"stepOptions" , cmd)
227 cmdwdefs[
"logfile" ] = logfile
228 logh = open(logfile,
"w")
229 logh.write(
"This perfsuite run was configured with the following options:\n")
231 for key
in cmdwdefs.keys():
232 logh.write(key +
"\t" +
str(cmdwdefs[key])+
"\n")
234 print(
"Calling cmsPerfSuite.main() function\n")
237 "-t",cmdwdefs[
"TimeSizeEvents" ],
238 "--RunTimeSize",cmdwdefs[
"TimeSizeCandles"],
239 "-o",cmdwdefs[
"perfsuitedir" ],
246 "--cmsScimark",cmdwdefs[
"cmsScimark" ],
247 "--cmsScimarkLarge",cmdwdefs[
"cmsScimarkLarge" ],
248 "--cmsdriver",cmdwdefs[
"cmsdriverOptions"],
249 "--step",cmdwdefs[
"stepOptions" ],
252 "--cpu",cmdwdefs[
"cpus" ],
253 "--cores",cmdwdefs[
"cores" ],
261 cps.main(cpsInputArgs)
262 print(
"Running of the Performance Suite is done!")
268 outs.append((cmdwdefs,cph.harvest(curperfdir)))
274 except exceptions.Exception
as detail:
276 logh = open(os.path.join(os.getcwd(),
"error.log"),
"a")
277 logh.write(
str(detail) +
"\n")
S & print(S &os, JobReport::InputFile const &f)
def request_benchmark(cmds)
def getCPSkeyword(key, dict)