[llvm] r310660 - Disable some IR death tests when SEH is available
Reid Kleckner via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 10 14:14:07 PDT 2017
Author: rnk
Date: Thu Aug 10 14:14:07 2017
New Revision: 310660
URL: http://llvm.org/viewvc/llvm-project?rev=310660&view=rev
Log:
Disable some IR death tests when SEH is available
They hang for me locally. I suspect that there is a use-after-free when
attempting to destroy an LLVMContext after asserting from the middle of
metadata tracking. It doesn't seem worth debugging it further.
Modified:
llvm/trunk/unittests/IR/MetadataTest.cpp
Modified: llvm/trunk/unittests/IR/MetadataTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/IR/MetadataTest.cpp?rev=310660&r1=310659&r2=310660&view=diff
==============================================================================
--- llvm/trunk/unittests/IR/MetadataTest.cpp (original)
+++ llvm/trunk/unittests/IR/MetadataTest.cpp Thu Aug 10 14:14:07 2017
@@ -2466,8 +2466,12 @@ TEST_F(DistinctMDOperandPlaceholderTest,
DistinctMDOperandPlaceholder(7).replaceUseWith(MDTuple::get(Context, None));
}
-#ifndef NDEBUG
-#ifdef GTEST_HAS_DEATH_TEST
+// Test various assertions in metadata tracking. Don't run these tests if gtest
+// will use SEH to recover from them. Two of these tests get halfway through
+// inserting metadata into DenseMaps for tracking purposes, and then they
+// assert, and we attempt to destroy an LLVMContext with broken invariants,
+// leading to infinite loops.
+#if defined(GTEST_HAS_DEATH_TEST) && !defined(NDEBUG) && !defined(GTEST_HAS_SEH)
TEST_F(DistinctMDOperandPlaceholderTest, MetadataAsValue) {
// This shouldn't crash.
DistinctMDOperandPlaceholder PH(7);
@@ -2509,6 +2513,5 @@ TEST_F(DistinctMDOperandPlaceholderTest,
}
}
#endif
-#endif
} // end namespace
More information about the llvm-commits
mailing list