diff options
Diffstat (limited to 'test/exception_object_alignment.sh.cpp')
-rw-r--r-- | test/exception_object_alignment.sh.cpp | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/test/exception_object_alignment.sh.cpp b/test/exception_object_alignment.sh.cpp deleted file mode 100644 index 5f4aea2..0000000 --- a/test/exception_object_alignment.sh.cpp +++ /dev/null @@ -1,48 +0,0 @@ -//===---------------- exception_object_alignment.sh.cpp -------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -// UNSUPPORTED: libcxxabi-no-exceptions - -// RUN: %build -O1 -// RUN: %run - -// This test used to fail on Darwin because field unwindHeader of struct -// __cxa_exception and the exception object that immediately followed were not -// 16B aligned. It would segfault in class derived's constructor when a movaps -// tried to write to a memory operand that was not 16B aligned. - -namespace { - -struct S { - int a; - int __attribute__((aligned(16))) b; -}; - -class base1 { -protected: - virtual ~base1() throw() {} -}; - -class derived: public base1 { -public: - derived() : member() {} -private: - S member; -}; - -} - -int main() { - try { - throw derived(); - } - catch(...) { - } - return 0; -} |