[compiler-rt] r272498 - [libprofile] Define an expansion `%clang_profgen=`

Sean Silva via llvm-commits llvm-commits at lists.llvm.org
Sat Jun 11 21:17:58 PDT 2016


Author: silvas
Date: Sat Jun 11 23:17:57 2016
New Revision: 272498

URL: http://llvm.org/viewvc/llvm-project?rev=272498&view=rev
Log:
[libprofile] Define an expansion `%clang_profgen=`

Modified:
    compiler-rt/trunk/test/profile/Linux/instrprof-set-filename-shared.test
    compiler-rt/trunk/test/profile/instrprof-basic.c
    compiler-rt/trunk/test/profile/instrprof-set-filename.c
    compiler-rt/trunk/test/profile/lit.cfg

Modified: compiler-rt/trunk/test/profile/Linux/instrprof-set-filename-shared.test
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/Linux/instrprof-set-filename-shared.test?rev=272498&r1=272497&r2=272498&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/Linux/instrprof-set-filename-shared.test (original)
+++ compiler-rt/trunk/test/profile/Linux/instrprof-set-filename-shared.test Sat Jun 11 23:17:57 2016
@@ -1,6 +1,6 @@
 # Test that __llvm_profile_set_filename is honored by shared libary too.
 RUN: mkdir -p %t.d
-RUN: %clang -fprofile-instr-generate=%t.shared.profraw -fPIC -shared -o %t.d/t.shared %S/../Inputs/instrprof-dlopen-func.c
+RUN: %clang_profgen=%t.shared.profraw -fPIC -shared -o %t.d/t.shared %S/../Inputs/instrprof-dlopen-func.c
 RUN: %clang_profgen -DCALL_SHARED -o %t.m -O3 -rpath %t.d %t.d/t.shared %S/../instrprof-set-filename.c 
 RUN: %run %t.m %t.main.profraw
 RUN: llvm-profdata show %t.main.profraw | FileCheck --check-prefix=SHARED %s

Modified: compiler-rt/trunk/test/profile/instrprof-basic.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/instrprof-basic.c?rev=272498&r1=272497&r2=272498&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/instrprof-basic.c (original)
+++ compiler-rt/trunk/test/profile/instrprof-basic.c Sat Jun 11 23:17:57 2016
@@ -10,7 +10,7 @@
 // RUN: llvm-profdata merge -o %t.em.profdata %t.profraw_e_*
 // RUN: %clang_profuse=%t.em.profdata -o - -S -emit-llvm %s | FileCheck %s --check-prefix=COMMON --check-prefix=MERGE
 //
-// RUN: %clang -o %t.merge -fprofile-instr-generate=%t.%m.profraw -O3 %s
+// RUN: %clang_profgen=%t.%m.profraw -o %t.merge -O3 %s
 // RUN: rm -f %t.*.profraw*
 // RUN: %run %t.merge
 // RUN: %run %t.merge

Modified: compiler-rt/trunk/test/profile/instrprof-set-filename.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/instrprof-set-filename.c?rev=272498&r1=272497&r2=272498&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/instrprof-set-filename.c (original)
+++ compiler-rt/trunk/test/profile/instrprof-set-filename.c Sat Jun 11 23:17:57 2016
@@ -15,14 +15,14 @@
 // RUN: rm %t.profdata
 // 3. Test that __llvm_profile_set_filename has higher precedence than
 //    the command line.
-// RUN: %clang -fprofile-instr-generate=%t.cmd.profraw -o %t.cmd -O3 %s
+// RUN: %clang_profgen=%t.cmd.profraw -o %t.cmd -O3 %s
 // RUN: %run %t.cmd %t.profraw
 // RUN: llvm-profdata merge -o %t.profdata %t.profraw
 // RUN: %clang_profuse=%t.profdata -o - -S -emit-llvm %s | FileCheck %s
 // RUN: rm %t.profraw
 // RUN: rm %t.profdata
 // 4. Test that command line has high precedence than the default path
-// RUN: %clang -fprofile-instr-generate=%t.cmd.profraw -DNO_API -o %t.cmd -O3 %s
+// RUN: %clang_profgen=%t.cmd.profraw -DNO_API -o %t.cmd -O3 %s
 // RUN: %run %t.cmd %t.profraw
 // RUN: llvm-profdata merge -o %t.cmd.profdata %t.cmd.profraw
 // RUN: %clang_profuse=%t.cmd.profdata -o - -S -emit-llvm %s | FileCheck %s

Modified: compiler-rt/trunk/test/profile/lit.cfg
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/lit.cfg?rev=272498&r1=272497&r2=272498&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/lit.cfg (original)
+++ compiler-rt/trunk/test/profile/lit.cfg Sat Jun 11 23:17:57 2016
@@ -56,6 +56,7 @@ def build_invocation(compile_flags):
 config.substitutions.append( ("%clang ", build_invocation(clang_cflags)) )
 config.substitutions.append( ("%clangxx ", build_invocation(clang_cxxflags)) )
 config.substitutions.append( ("%clang_profgen ", build_invocation(clang_cflags) + " -fprofile-instr-generate ") )
+config.substitutions.append( ("%clang_profgen=", build_invocation(clang_cflags) + " -fprofile-instr-generate=") )
 config.substitutions.append( ("%clang_profuse=", build_invocation(clang_cflags) + " -fprofile-instr-use=") )
 config.substitutions.append( ("%clangxx_profgen ", build_invocation(clang_cxxflags) + " -fprofile-instr-generate ") )
 config.substitutions.append( ("%clangxx_profuse=", build_invocation(clang_cxxflags) + " -fprofile-instr-use=") )




More information about the llvm-commits mailing list