[msan] Remove leftover MSanDR bits in tests.
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>
Tue, 25 Nov 2014 15:00:23 +0000 (15:00 +0000)
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>
Tue, 25 Nov 2014 15:00:23 +0000 (15:00 +0000)
llvm-svn: 222762

compiler-rt/lib/msan/tests/CMakeLists.txt
compiler-rt/lib/msan/tests/msan_test.cc
compiler-rt/lib/msan/tests/msandr_test_so.cc [deleted file]
compiler-rt/lib/msan/tests/msandr_test_so.h [deleted file]

index f3c11ba..53e1b54 100644 (file)
@@ -15,10 +15,8 @@ set(MSAN_UNITTEST_SOURCES msan_test.cc msan_test_main.cc)
 set(MSAN_LOADABLE_SOURCE msan_loadable.cc)
 set(MSAN_UNITTEST_HEADERS
   msan_test_config.h
-  msandr_test_so.h
   ../../../include/sanitizer/msan_interface.h
 )
-set(MSANDR_UNITTEST_SOURCE msandr_test_so.cc)
 set(MSAN_UNITTEST_COMMON_CFLAGS
   -I${COMPILER_RT_LIBCXX_PATH}/include
   ${COMPILER_RT_GTEST_CFLAGS}
@@ -113,25 +111,13 @@ macro(add_msan_tests_for_arch arch kind)
   msan_compile(MSAN_INST_LOADABLE_OBJECTS ${MSAN_LOADABLE_SOURCE} ${arch} "${kind}"
                ${MSAN_UNITTEST_INSTRUMENTED_CFLAGS} ${ARGN})
 
-  # Uninstrumented shared object for MSanDR tests.
-  set(MSANDR_TEST_OBJECTS)
-  msan_compile(MSANDR_TEST_OBJECTS ${MSANDR_UNITTEST_SOURCE} ${arch} "${kind}"
-               ${MSAN_UNITTEST_COMMON_CFLAGS})
-
   # Instrumented loadable library tests.
   set(MSAN_LOADABLE_SO)
   msan_link_shared(MSAN_LOADABLE_SO "libmsan_loadable" ${arch} "${kind}"
                    OBJECTS ${MSAN_INST_LOADABLE_OBJECTS}
                    DEPS ${MSAN_INST_LOADABLE_OBJECTS})
 
-  # Uninstrumented shared library tests.
-  set(MSANDR_TEST_SO)
-  msan_link_shared(MSANDR_TEST_SO "libmsandr_test" ${arch} "${kind}"
-                   OBJECTS ${MSANDR_TEST_OBJECTS}
-                   DEPS ${MSANDR_TEST_OBJECTS})
-
-  set(MSAN_TEST_OBJECTS ${MSAN_INST_TEST_OBJECTS} ${MSAN_INST_GTEST}
-                        ${MSANDR_TEST_SO})
+  set(MSAN_TEST_OBJECTS ${MSAN_INST_TEST_OBJECTS} ${MSAN_INST_GTEST})
   set(MSAN_TEST_DEPS ${MSAN_TEST_OBJECTS} libcxx_msan${kind}
                      ${MSAN_LOADABLE_SO})
   if(NOT COMPILER_RT_STANDALONE_BUILD)
index 84fa962..697cfb8 100644 (file)
@@ -20,7 +20,6 @@
 
 #include "sanitizer/allocator_interface.h"
 #include "sanitizer/msan_interface.h"
-#include "msandr_test_so.h"
 
 #include <inttypes.h>
 #include <stdlib.h>
diff --git a/compiler-rt/lib/msan/tests/msandr_test_so.cc b/compiler-rt/lib/msan/tests/msandr_test_so.cc
deleted file mode 100644 (file)
index eb605d4..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-//===-- msandr_test_so.cc  ------------------------------------------------===//
-//
-//                     The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-//
-// This file is a part of MemorySanitizer.
-//
-// MemorySanitizer unit tests.
-//===----------------------------------------------------------------------===//
-
-#include "msandr_test_so.h"
-
-void dso_memfill(char* s, unsigned n) {
-  for (unsigned i = 0; i < n; ++i)
-    s[i] = i;
-}
-
-int dso_callfn(int (*fn)(void)) {
-  volatile int x = fn();
-  return x;
-}
-
-int dso_callfn1(int (*fn)(long long, long long, long long)) {  //NOLINT
-  volatile int x = fn(1, 2, 3);
-  return x;
-}
-
-int dso_stack_store(void (*fn)(int*, int*), int x) {
-  int y = x + 1;
-  fn(&x, &y);
-  return y;
-}
-
-void break_optimization(void *x) {}
diff --git a/compiler-rt/lib/msan/tests/msandr_test_so.h b/compiler-rt/lib/msan/tests/msandr_test_so.h
deleted file mode 100644 (file)
index cd75ff3..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-//===-- msandr_test_so.h ----------------------------------------*- C++ -*-===//
-//
-//                     The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-//
-// This file is a part of MemorySanitizer.
-//
-// MemorySanitizer unit tests.
-//===----------------------------------------------------------------------===//
-
-#ifndef MSANDR_MSANDR_TEST_SO_H
-#define MSANDR_MSANDR_TEST_SO_H
-
-void dso_memfill(char* s, unsigned n);
-int dso_callfn(int (*fn)(void));
-int dso_callfn1(int (*fn)(long long, long long, long long));  //NOLINT
-int dso_stack_store(void (*fn)(int*, int*), int x);
-void break_optimization(void *x);
-
-#endif