tsan: fix compiler warnings
authorDmitry Vyukov <dvyukov@google.com>
Mon, 28 May 2012 17:33:08 +0000 (17:33 +0000)
committerDmitry Vyukov <dvyukov@google.com>
Mon, 28 May 2012 17:33:08 +0000 (17:33 +0000)
llvm-svn: 157585

compiler-rt/lib/tsan/output_tests/simple_stack2.cc

index 354d103..811bc6d 100644 (file)
@@ -9,16 +9,16 @@ void __attribute__((noinline)) foo1() {
 }
 
 void __attribute__((noinline)) bar1() {
-  volatile int tmp = 42; (void)tmp;
+  volatile int tmp = 42; int tmp2 = tmp; (void)tmp2;
   foo1();
 }
 
 void __attribute__((noinline)) foo2() {
-  volatile int v = Global; (void)v;
+  volatile int tmp = Global; int tmp2 = tmp; (void)tmp2;
 }
 
 void __attribute__((noinline)) bar2() {
-  volatile int tmp = 42; (void)tmp;
+  volatile int tmp = 42; int tmp2 = tmp; (void)tmp2;
   foo2();
 }