def get_run_spec(self, bmkinput): x = bmk2.RunSpec(self, bmkinput) x.set_binary(self.props._cwd, 'test') x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) x.set_checker(bmk2.REChecker('^valid_coloring: yes$')) x.set_perf(bmk2.PerfRE(PERF_RE)) return x
def get_run_spec(self, bmkinput): x = bmk2.RunSpec(self, bmkinput) x.set_binary(self.props._cwd, 'test') x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) x.set_arg('-o') x.set_arg('@output', bmk2.AT_TEMPORARY_OUTPUT) x.set_checker( bmk2.ExternalChecker(get_mis_checker(bmkinput.props.file))) x.set_perf(bmk2.PerfRE(PERF_RE)) return x
def get_run_spec(self, bmkinput): x = bmk2.RunSpec(self, bmkinput) x.set_binary(self.props._cwd, 'test') x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) x.set_arg('-d') x.set_arg(bmkinput.props.nf_delta) x.set_arg('-o') x.set_arg('@output', bmk2.AT_TEMPORARY_OUTPUT) x.set_checker(bmk2.DiffChecker('@output', bmkinput.props.sssp_output)) x.set_perf(bmk2.PerfRE(PERF_RE)) return x
def get_default_run_specs(self, bmkinput, config): """Creates default run specifications with common arguments for all shared memory benchmarks and returns them. They can be modified later according to the benchmark that you want to run. """ assert config != None # config should be passed through test2.py listOfRunSpecs = [] for numThreads in range(self.startThread, self.endThread + 1, self.step): if numThreads == 0 and self.step != 1: numThreads = 1 elif numThreads == 0: continue x = bmk2.RunSpec(self, bmkinput) x.set_binary( "", os.path.expandvars( os.path.join(config.get_var("pathToApps"), self.relativeAppPath))) x.set_arg("-t=%d" % numThreads) nameToAppend = bmkinput.name if bmkinput.props.format == "nothing": nameToAppend = "gen" pass elif bmkinput.props.format != "mesh": x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) else: # mesh # don't specify with input file flag as it doesn't exist (mesh # loads multiple files, so the file specified in the inputdb # isn't an actual file x.set_arg(bmkinput.props.file) x.set_arg("-statFile=" + os.path.expandvars( os.path.join(config.get_var("logOutputDirectory"), self.getUniqueStatFile(numThreads, nameToAppend))) ) listOfRunSpecs.append(x) x.set_checker(bmk2.PassChecker()) x.set_perf(bmk2.ZeroPerf()) return listOfRunSpecs
def get_run_spec(self, bmkinput): x = bmk2.RunSpec(self, bmkinput) k, ec = get_ktruss_checker(bmkinput, self.config['k']) t = int(self.config['t']) x.set_binary(self.props._cwd, 'k-truss') x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) assert self.algo is not None x.set_arg('-algo=%s' % (self.algo, ), bmk2.AT_OPAQUE) x.set_arg('-trussNum=%d' % (k, ), bmk2.AT_OPAQUE) x.set_arg("-t=%d" % (t, ), bmk2.AT_OPAQUE) x.set_arg('-o=@output', bmk2.AT_TEMPORARY_OUTPUT) x.set_checker(bmk2.ExternalChecker(ec)) x.set_perf(bmk2.PerfRE(r"^\(NULL\),.*, Time,0,0,(?P<time_ms>[0-9]+)$")) return x
def get_run_spec(self, bmkinput): x = bmk2.RunSpec(self, bmkinput) x.set_binary(self.props._cwd, 'KokkosGraph_color.exe') x.set_arg('--amtx') x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) x.set_arg('--algorithm') x.set_arg(self.alg) x.set_arg('--cuda') x.set_arg('--repeat') x.set_arg('1') x.set_arg('-o') x.set_arg('@output', bmk2.AT_TEMPORARY_OUTPUT) chkinput = bmkinput.get_alt_format('bin/galois') x.set_checker( bmk2.ExternalChecker( get_gc_checker(chkinput.props.file, path=self.props._cwd))) #x.set_checker(bmk2.PassChecker()) x.set_perf(bmk2.PerfRE(PERF_RE)) return x
def get_default_run_specs(self, bmkinput, config): """Creates default run specifications with common arguments for all dist apps and returns them. They can be modified later according to the benchmark that you want to run. """ assert config != None # config should be passed through test2.py listOfRunSpecs = [] # TODO add cuts in as well.... for numThreads in range(self.startThread, self.endThread + 1, self.step): if numThreads == 0 and self.step != 1: numThreads = 1 elif numThreads == 0: continue for numHosts in self.testHosts: # TODO no cut if 1 host for currentCut in self.cutsToTest: # TODO figure out how to get mpirun hooked up to this x = bmk2.RunSpec(self, bmkinput) # mpirun setup x.set_binary( "", os.path.expandvars( os.path.join(config.get_var("pathToMPIRun")))) x.set_arg("-n=%d" % numHosts) # TODO set this in config instead? x.set_arg("-hosts=peltier,gilbert,oersted") # app setup x.set_arg( os.path.expandvars( os.path.join(config.get_var("pathToApps"), self.relativeAppPath))) x.set_arg("-t=%d" % numThreads) # set transpose or symm graph flag if not (bmkinput.props.file).endswith(".sgr"): x.set_arg("-graphTranspose=%s" % bmkinput.props.transpose) else: x.set_arg("-symmetricGraph") nameToAppend = bmkinput.name # partition setup if numHosts != 1: x.set_arg("-partition=%s" % currentCut) else: currentCut = "single" x.set_arg(bmkinput.props.file, bmk2.AT_INPUT_FILE) x.set_arg("-statFile=" + os.path.expandvars( os.path.join( config.get_var("logOutputDirectory"), self.getUniqueStatFile(numThreads, numHosts, currentCut, nameToAppend)))) listOfRunSpecs.append(x) # null checkers/perf checkers x.set_checker(bmk2.PassChecker()) x.set_perf(bmk2.ZeroPerf()) # escape partition loop if only in a single host if (currentCut == "single"): break return listOfRunSpecs