Make perf.py changes work as part of alloy.py
This commit is contained in:
1
alloy.py
1
alloy.py
@@ -495,6 +495,7 @@ def validation_run(only, only_targets, reference_branch, number, notify, update,
|
|||||||
performance.ref = "ispc_ref"
|
performance.ref = "ispc_ref"
|
||||||
if current_OS == "Windows":
|
if current_OS == "Windows":
|
||||||
performance.ref = "ispc_ref.exe"
|
performance.ref = "ispc_ref.exe"
|
||||||
|
performance.perf_target = ""
|
||||||
performance.in_file = "." + os.sep + f_date + os.sep + "performance.log"
|
performance.in_file = "." + os.sep + f_date + os.sep + "performance.log"
|
||||||
# prepare LLVM 3.3 as newest LLVM
|
# prepare LLVM 3.3 as newest LLVM
|
||||||
need_LLVM = check_LLVM(["3.3"])
|
need_LLVM = check_LLVM(["3.3"])
|
||||||
|
|||||||
9
perf.py
9
perf.py
@@ -392,7 +392,8 @@ def perf(options1, args):
|
|||||||
|
|
||||||
print_debug("Okey go go go!\n\n", s, perf_log)
|
print_debug("Okey go go go!\n\n", s, perf_log)
|
||||||
# report command line
|
# report command line
|
||||||
print_debug("Command line: %s\n" % " ".join(map(str, sys.argv)), s, perf_log)
|
if __name__ == "__main__":
|
||||||
|
print_debug("Command line: %s\n" % " ".join(map(str, sys.argv)), s, perf_log)
|
||||||
# report used ispc
|
# report used ispc
|
||||||
print_debug("Testing ispc: " + ispc_test + "\n", s, perf_log)
|
print_debug("Testing ispc: " + ispc_test + "\n", s, perf_log)
|
||||||
|
|
||||||
@@ -424,8 +425,8 @@ def perf(options1, args):
|
|||||||
command = command[:-1]
|
command = command[:-1]
|
||||||
# handle conditional target argument
|
# handle conditional target argument
|
||||||
target_str = ""
|
target_str = ""
|
||||||
if options.target != "":
|
if options.perf_target != "":
|
||||||
target_str = " ISPC_IA_TARGETS="+options.target
|
target_str = " ISPC_IA_TARGETS="+options.perf_target
|
||||||
if is_windows == False:
|
if is_windows == False:
|
||||||
ex_command_ref = "./ref " + command + " >> " + perf_temp + "_ref"
|
ex_command_ref = "./ref " + command + " >> " + perf_temp + "_ref"
|
||||||
ex_command = "./test " + command + " >> " + perf_temp + "_test"
|
ex_command = "./test " + command + " >> " + perf_temp + "_test"
|
||||||
@@ -510,7 +511,7 @@ if __name__ == "__main__":
|
|||||||
help='set reference compiler for compare', default="")
|
help='set reference compiler for compare', default="")
|
||||||
parser.add_option('-f', '--file', dest='in_file',
|
parser.add_option('-f', '--file', dest='in_file',
|
||||||
help='file to save perf output', default="")
|
help='file to save perf output', default="")
|
||||||
parser.add_option('-t', '--target', dest='target',
|
parser.add_option('-t', '--target', dest='perf_target',
|
||||||
help='set ispc target for building benchmarks (both test and ref)', default="")
|
help='set ispc target for building benchmarks (both test and ref)', default="")
|
||||||
(options, args) = parser.parse_args()
|
(options, args) = parser.parse_args()
|
||||||
perf(options, args)
|
perf(options, args)
|
||||||
|
|||||||
Reference in New Issue
Block a user