[compiler-rt] r229388 - [Msan] Make unit tests that use mempcpy() passing on FreeBSD
Viktor Kutuzov
vkutuzov at accesssoftek.com
Mon Feb 16 05:26:32 PST 2015
Author: vkutuzov
Date: Mon Feb 16 07:26:32 2015
New Revision: 229388
URL: http://llvm.org/viewvc/llvm-project?rev=229388&view=rev
Log:
[Msan] Make unit tests that use mempcpy() passing on FreeBSD
Differential Revision: http://reviews.llvm.org/D7588
Modified:
compiler-rt/trunk/lib/msan/tests/msan_test.cc
Modified: compiler-rt/trunk/lib/msan/tests/msan_test.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/msan/tests/msan_test.cc?rev=229388&r1=229387&r2=229388&view=diff
==============================================================================
--- compiler-rt/trunk/lib/msan/tests/msan_test.cc (original)
+++ compiler-rt/trunk/lib/msan/tests/msan_test.cc Mon Feb 16 07:26:32 2015
@@ -80,6 +80,12 @@ int shmdt(const void *);
# include <net/ethernet.h>
# define f_namelen f_namemax // FreeBSD names this statfs field so.
# define cpu_set_t cpuset_t
+extern "C" {
+// FreeBSD's <ssp/string.h> defines mempcpy() to be a macro expanding into
+// a __builtin___mempcpy_chk() call, but since Msan RTL defines it as an
+// ordinary function, we can declare it here to complete the tests.
+void *mempcpy(void *dest, const void *src, size_t n);
+}
#endif
#if defined(__i386__) || defined(__x86_64__)
More information about the llvm-commits
mailing list