[PATCH] D29945: [compiler-rt][asan|win] Fix flaky unittest due to large allocations
Etienne Bergeron via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 14 08:23:30 PST 2017
etienneb created this revision.
Herald added subscribers: dberris, kubamracek.
Coverage is using large arrays which requires large allocations.
These allocations are flaky and often failing on win64.
We are using the 32-bits size until this gets a better fix.
https://reviews.llvm.org/D29945
Files:
lib/sanitizer_common/sanitizer_coverage_libcdep.cc
Index: lib/sanitizer_common/sanitizer_coverage_libcdep.cc
===================================================================
--- lib/sanitizer_common/sanitizer_coverage_libcdep.cc
+++ lib/sanitizer_common/sanitizer_coverage_libcdep.cc
@@ -171,7 +171,14 @@
// - not thread-safe;
// - does not support long traces;
// - not tuned for performance.
+#if SANITIZER_WINDOWS
+ // On windows, large allocations are often failing which is making unittests
+ // flaky. TODO(etienneb): Find a way to support coverage of larger executable
+ // in 64-bits.
+ static const uptr kTrEventArrayMaxSize = 1 << 22;
+#else
static const uptr kTrEventArrayMaxSize = FIRST_32_SECOND_64(1 << 22, 1 << 30);
+#endif
u32 *tr_event_array;
uptr tr_event_array_size;
u32 *tr_event_pointer;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D29945.88380.patch
Type: text/x-patch
Size: 792 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170214/4250d40a/attachment.bin>
More information about the llvm-commits
mailing list