[llvm] r201838 - This test was failing on non-X86-64 platforms because stackmaps only work on X86-64.
Filip Pizlo
fpizlo at apple.com
Thu Feb 20 19:17:32 PST 2014
Author: fpizlo
Date: Thu Feb 20 21:17:31 2014
New Revision: 201838
URL: http://llvm.org/viewvc/llvm-project?rev=201838&view=rev
Log:
This test was failing on non-X86-64 platforms because stackmaps only work on X86-64.
Disable it on non-X86-64 platforms and add a comment.
Modified:
llvm/trunk/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
Modified: llvm/trunk/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp?rev=201838&r1=201837&r2=201838&view=diff
==============================================================================
--- llvm/trunk/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp (original)
+++ llvm/trunk/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp Thu Feb 20 21:17:31 2014
@@ -363,6 +363,10 @@ TEST_F(MCJITCAPITest, custom_memory_mana
TEST_F(MCJITCAPITest, stackmap_creates_compact_unwind_on_darwin) {
SKIP_UNSUPPORTED_PLATFORM;
+ // This test is also not supported on non-x86 platforms.
+ if (Triple(HostTriple).getArch() != Triple::x86_64)
+ return;
+
buildFunctionThatUsesStackmap();
buildMCJITOptions();
useRoundTripSectionMemoryManager();
@@ -378,6 +382,11 @@ TEST_F(MCJITCAPITest, stackmap_creates_c
EXPECT_EQ(42, functionPointer.usable());
EXPECT_TRUE(didCallAllocateCodeSection);
+ // Up to this point, the test is specific only to X86-64. But this next
+ // expectation is only valid on Darwin because it assumes that unwind
+ // data is made available only through compact_unwind. It would be
+ // worthwhile to extend this to handle non-Darwin platforms, in which
+ // case you'd want to look for an eh_frame or something.
EXPECT_TRUE(
Triple(HostTriple).getOS() != Triple::Darwin ||
didAllocateCompactUnwindSection);
More information about the llvm-commits
mailing list