161 global _outputdir, _reqnumber
162 print "Commands received running perfsuite for these jobs:"
175 topdir = os.path.join(_outputdir,
"request_" + str(_reqnumber))
176 exists = os.path.exists(topdir)
181 curperfdir = os.path.abspath(os.path.join(topdir,str(cmd_num)))
182 if not os.path.exists(curperfdir):
184 logfile = os.path.join(curperfdir,
"cmsPerfSuite.log")
185 if os.path.exists(logfile):
186 logfile = logfile + str(cmd_num)
188 if cmd.has_key(
'cpus'):
189 if cmd[
'cpus'] ==
"All":
190 print "Running performance suite on all CPUS!\n"
193 cmd[
"cpus"]=cmd[
"cpus"]+str(cpu)+
","
194 cmd[
"cpus"]=cmd[
"cpus"][:-1]
195 print "I.e. on cpus %s\n"%cmd[
"cpus"]
200 cmdwdefs[
"perfsuitedir" ] = curperfdir
201 cmdwdefs[
"TimeSizeEvents" ] =
getCPSkeyword(
"TimeSizeEvents" , cmd)
202 cmdwdefs[
"TimeSizeCandles" ] =
getCPSkeyword(
"TimeSizeCandles" , cmd)
203 cmdwdefs[
"TimeSizePUCandles" ] =
getCPSkeyword(
"TimeSizePUCandles" , cmd)
204 cmdwdefs[
"IgProfEvents" ] =
getCPSkeyword(
"IgProfEvents" , cmd)
205 cmdwdefs[
"IgProfCandles" ] =
getCPSkeyword(
"IgProfCandles" , cmd)
206 cmdwdefs[
"IgProfPUCandles" ] =
getCPSkeyword(
"IgProfPUCandles" , cmd)
207 cmdwdefs[
"CallgrindEvents" ] =
getCPSkeyword(
"CallgrindEvents" , cmd)
208 cmdwdefs[
"CallgrindCandles"] =
getCPSkeyword(
"CallgrindCandles" , cmd)
209 cmdwdefs[
"CallgrindPUCandles"] =
getCPSkeyword(
"CallgrindPUCandles" , cmd)
210 cmdwdefs[
"MemcheckEvents" ] =
getCPSkeyword(
"MemcheckEvents" , cmd)
211 cmdwdefs[
"MemcheckCandles" ] =
getCPSkeyword(
"MemcheckCandles" , cmd)
212 cmdwdefs[
"MemcheckPUCandles" ] =
getCPSkeyword(
"MemcheckPUCandles" , cmd)
214 cmdwdefs[
"cmsScimarkLarge" ] =
getCPSkeyword(
"cmsScimarkLarge" , cmd)
215 cmdwdefs[
"cmsdriverOptions"] =
getCPSkeyword(
"cmsdriverOptions", cmd)
216 cmdwdefs[
"stepOptions" ] =
getCPSkeyword(
"stepOptions" , cmd)
226 cmdwdefs[
"logfile" ] = logfile
227 logh = open(logfile,
"w")
228 logh.write(
"This perfsuite run was configured with the following options:\n")
230 for key
in cmdwdefs.keys():
231 logh.write(key +
"\t" +str(cmdwdefs[key])+
"\n")
233 print "Calling cmsPerfSuite.main() function\n"
236 "-t",cmdwdefs[
"TimeSizeEvents" ],
237 "--RunTimeSize",cmdwdefs[
"TimeSizeCandles"],
238 "-o",cmdwdefs[
"perfsuitedir" ],
245 "--cmsScimark",cmdwdefs[
"cmsScimark" ],
246 "--cmsScimarkLarge",cmdwdefs[
"cmsScimarkLarge" ],
247 "--cmsdriver",cmdwdefs[
"cmsdriverOptions"],
248 "--step",cmdwdefs[
"stepOptions" ],
251 "--cpu",cmdwdefs[
"cpus" ],
252 "--cores",cmdwdefs[
"cores" ],
260 cps.main(cpsInputArgs)
261 print "Running of the Performance Suite is done!"
267 outs.append((cmdwdefs,cph.harvest(curperfdir)))
273 except exceptions.Exception, detail:
275 logh = open(os.path.join(os.getcwd(),
"error.log"),
"a")
276 logh.write(str(detail) +
"\n")