[compiler-rt] r238622 - profile: Fix link errors in this test on darwin

Justin Bogner mail at justinbogner.com
Fri May 29 15:41:25 PDT 2015


Author: bogner
Date: Fri May 29 17:41:25 2015
New Revision: 238622

URL: http://llvm.org/viewvc/llvm-project?rev=238622&view=rev
Log:
profile: Fix link errors in this test on darwin

Modified:
    compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-a.cpp
    compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-b.cpp
    compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-header.h
    compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-main.cpp

Modified: compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-a.cpp
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-a.cpp?rev=238622&r1=238621&r2=238622&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-a.cpp (original)
+++ compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-a.cpp Fri May 29 17:41:25 2015
@@ -1,7 +1,7 @@
 #include "instrprof-dynamic-header.h"
 void a() {
   if (true) {
-    bar<void>();
-    bar<char>();
+    bar<void>(1);
+    bar<char>(1);
   }
 }

Modified: compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-b.cpp
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-b.cpp?rev=238622&r1=238621&r2=238622&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-b.cpp (original)
+++ compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-b.cpp Fri May 29 17:41:25 2015
@@ -1,7 +1,7 @@
 #include "instrprof-dynamic-header.h"
 void b() {
   if (true) {
-    bar<void>();
-    bar<int>();
+    bar<void>(1);
+    bar<int>(1);
   }
 }

Modified: compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-header.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-header.h?rev=238622&r1=238621&r2=238622&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-header.h (original)
+++ compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-header.h Fri May 29 17:41:25 2015
@@ -1,5 +1,4 @@
-extern int X;
-template <class T> void bar() {
+template <class T> void bar(int X) {
   if (X) {
     X *= 4;
   }

Modified: compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-main.cpp
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-main.cpp?rev=238622&r1=238621&r2=238622&view=diff
==============================================================================
--- compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-main.cpp (original)
+++ compiler-rt/trunk/test/profile/Inputs/instrprof-dynamic-main.cpp Fri May 29 17:41:25 2015
@@ -1,10 +1,8 @@
 #include "instrprof-dynamic-header.h"
-int X = 0;
 void foo(int K) { if (K) {} }
 int main(int argc, char *argv[]) {
   foo(5);
-  X++;
-  bar<void>();
+  bar<void>(1);
   a();
   b();
   return 0;





More information about the llvm-commits mailing list