From d129e33b51ecaba7793aa744c3467f9c20e03704 Mon Sep 17 00:00:00 2001 From: Dmitry Babokin Date: Thu, 10 Oct 2013 16:11:15 +0400 Subject: [PATCH] Enable clang as default C++ compiler used by run_tests.py and perf.py --- perf.py | 7 +++++-- run_tests.py | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/perf.py b/perf.py index 0d4926e0..2b5c6edd 100755 --- a/perf.py +++ b/perf.py @@ -326,8 +326,8 @@ def perf(options1, args): ref_compiler_exists = False if is_windows == False: ispc_test = "ispc" - ref_compiler = "g++" - refc_compiler = "gcc" + ref_compiler = "clang++" + refc_compiler = "clang" if options.compiler != "": if options.compiler == "clang" or options.compiler == "clang++": ref_compiler = "clang++" @@ -335,6 +335,9 @@ def perf(options1, args): if options.compiler == "icc" or options.compiler == "icpc": ref_compiler = "icpc" refc_compiler = "icc" + if options.compiler == "gcc" or options.compiler == "g++": + ref_compiler = "g++" + refc_compiler = "gcc" else: ispc_test = "ispc.exe" ref_compiler = "cl.exe" diff --git a/run_tests.py b/run_tests.py index bf1b4a2b..803410b8 100755 --- a/run_tests.py +++ b/run_tests.py @@ -446,7 +446,7 @@ def verify(): f = open(test_states, 'r') f_lines = f.readlines() f.close() - check = [["g++", "clang", "cl"],["-O0", "-O2"],["x86","x86-64"], + check = [["g++", "clang++", "cl"],["-O0", "-O2"],["x86","x86-64"], ["Linux","Windows","Mac"],["LLVM 3.1","LLVM 3.2","LLVM 3.3","LLVM head"], ["sse2-i32x4", "sse2-i32x8", "sse4-i32x4", "sse4-i32x8", "sse4-i16x8", "sse4-i8x16", "avx1-i32x8", "avx1-i32x16", "avx1-i64x4", "avx1.1-i32x8", "avx1.1-i32x16", @@ -550,7 +550,7 @@ def run_tests(options1, args, print_version): if is_windows: options.compiler_exe = "cl.exe" else: - options.compiler_exe = "g++" + options.compiler_exe = "clang++" # checks the required compiler otherwise prints an error message PATH_dir = string.split(os.getenv("PATH"), os.pathsep)