diff options
Diffstat (limited to 'test/FrontendC++')
47 files changed, 195 insertions, 42 deletions
diff --git a/test/FrontendC++/2003-08-20-ExceptionFail.cpp b/test/FrontendC++/2003-08-20-ExceptionFail.cpp index fd1c6ad..f071c3c 100644 --- a/test/FrontendC++/2003-08-20-ExceptionFail.cpp +++ b/test/FrontendC++/2003-08-20-ExceptionFail.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null void foo(); diff --git a/test/FrontendC++/2003-08-21-EmptyClass.cpp b/test/FrontendC++/2003-08-21-EmptyClass.cpp index 2f90b3a..5dbfa33 100644 --- a/test/FrontendC++/2003-08-21-EmptyClass.cpp +++ b/test/FrontendC++/2003-08-21-EmptyClass.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // This tests compilation of EMPTY_CLASS_EXPR's diff --git a/test/FrontendC++/2003-08-27-TypeNamespaces.cpp b/test/FrontendC++/2003-08-27-TypeNamespaces.cpp index cd7247e..dec9718 100644 --- a/test/FrontendC++/2003-08-27-TypeNamespaces.cpp +++ b/test/FrontendC++/2003-08-27-TypeNamespaces.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null namespace foo { diff --git a/test/FrontendC++/2003-08-28-ForwardType.cpp b/test/FrontendC++/2003-08-28-ForwardType.cpp index 38c4e2d..9330e94 100644 --- a/test/FrontendC++/2003-08-28-ForwardType.cpp +++ b/test/FrontendC++/2003-08-28-ForwardType.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // Default placement versions of operator new. #include <new> diff --git a/test/FrontendC++/2003-08-28-SaveExprBug.cpp b/test/FrontendC++/2003-08-28-SaveExprBug.cpp index 2be35d8..98c5f5d 100644 --- a/test/FrontendC++/2003-08-28-SaveExprBug.cpp +++ b/test/FrontendC++/2003-08-28-SaveExprBug.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null char* eback(); diff --git a/test/FrontendC++/2003-08-31-StructLayout.cpp b/test/FrontendC++/2003-08-31-StructLayout.cpp index 99d6682..a45ad03 100644 --- a/test/FrontendC++/2003-08-31-StructLayout.cpp +++ b/test/FrontendC++/2003-08-31-StructLayout.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // There is a HOLE in the derived2 object due to not wanting to place the two // baseclass instances at the same offset! diff --git a/test/FrontendC++/2003-09-22-CompositeExprValue.cpp b/test/FrontendC++/2003-09-22-CompositeExprValue.cpp index a8208ad..3bd707e 100644 --- a/test/FrontendC++/2003-09-22-CompositeExprValue.cpp +++ b/test/FrontendC++/2003-09-22-CompositeExprValue.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct duration { duration operator/=(int c) { diff --git a/test/FrontendC++/2003-09-29-ArgumentNumberMismatch.cpp b/test/FrontendC++/2003-09-29-ArgumentNumberMismatch.cpp index 4873123..72997c5 100644 --- a/test/FrontendC++/2003-09-29-ArgumentNumberMismatch.cpp +++ b/test/FrontendC++/2003-09-29-ArgumentNumberMismatch.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // Non-POD classes cannot be passed into a function by component, because their // dtors must be run. Instead, pass them in by reference. The C++ front-end diff --git a/test/FrontendC++/2003-09-30-CommaExprBug.cpp b/test/FrontendC++/2003-09-30-CommaExprBug.cpp index afe470c..365795d 100644 --- a/test/FrontendC++/2003-09-30-CommaExprBug.cpp +++ b/test/FrontendC++/2003-09-30-CommaExprBug.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null class Empty {}; diff --git a/test/FrontendC++/2003-09-30-ForIncrementExprBug.cpp b/test/FrontendC++/2003-09-30-ForIncrementExprBug.cpp index 40c9c87..63f62f2 100644 --- a/test/FrontendC++/2003-09-30-ForIncrementExprBug.cpp +++ b/test/FrontendC++/2003-09-30-ForIncrementExprBug.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct C {}; diff --git a/test/FrontendC++/2003-09-30-ForIncrementExprBug2.cpp b/test/FrontendC++/2003-09-30-ForIncrementExprBug2.cpp index e07eb42..a1eee71 100644 --- a/test/FrontendC++/2003-09-30-ForIncrementExprBug2.cpp +++ b/test/FrontendC++/2003-09-30-ForIncrementExprBug2.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // Test with an opaque type diff --git a/test/FrontendC++/2003-09-30-NestedFunctionDecl.cpp b/test/FrontendC++/2003-09-30-NestedFunctionDecl.cpp index b1c54b8..94c1199 100644 --- a/test/FrontendC++/2003-09-30-NestedFunctionDecl.cpp +++ b/test/FrontendC++/2003-09-30-NestedFunctionDecl.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // The C++ front-end thinks the two foo's are different, the LLVM emitter // thinks they are the same. The disconnect causes problems. diff --git a/test/FrontendC++/2003-10-17-BoolBitfields.cpp b/test/FrontendC++/2003-10-17-BoolBitfields.cpp index 547a367..103945d 100644 --- a/test/FrontendC++/2003-10-17-BoolBitfields.cpp +++ b/test/FrontendC++/2003-10-17-BoolBitfields.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct test { bool A : 1; diff --git a/test/FrontendC++/2003-10-27-VirtualBaseClassCrash.cpp b/test/FrontendC++/2003-10-27-VirtualBaseClassCrash.cpp index f9fc80e..abda017 100644 --- a/test/FrontendC++/2003-10-27-VirtualBaseClassCrash.cpp +++ b/test/FrontendC++/2003-10-27-VirtualBaseClassCrash.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null template<class T> diff --git a/test/FrontendC++/2003-11-04-ArrayConstructors.cpp b/test/FrontendC++/2003-11-04-ArrayConstructors.cpp index 4df4f9b..4ab3398 100644 --- a/test/FrontendC++/2003-11-04-ArrayConstructors.cpp +++ b/test/FrontendC++/2003-11-04-ArrayConstructors.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct Foo { diff --git a/test/FrontendC++/2003-11-04-CatchLabelName.cpp b/test/FrontendC++/2003-11-04-CatchLabelName.cpp index 8acf88d..7dbe788 100644 --- a/test/FrontendC++/2003-11-04-CatchLabelName.cpp +++ b/test/FrontendC++/2003-11-04-CatchLabelName.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #include <string> diff --git a/test/FrontendC++/2003-11-18-EnumArray.cpp b/test/FrontendC++/2003-11-18-EnumArray.cpp index 6eaf9d6..bb1b3bf 100644 --- a/test/FrontendC++/2003-11-18-EnumArray.cpp +++ b/test/FrontendC++/2003-11-18-EnumArray.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null enum TchkType { tchkNum, tchkString, tchkSCN, tchkNone diff --git a/test/FrontendC++/2003-11-18-PtrMemConstantInitializer.cpp b/test/FrontendC++/2003-11-18-PtrMemConstantInitializer.cpp index ae76a6c..72609e7 100644 --- a/test/FrontendC++/2003-11-18-PtrMemConstantInitializer.cpp +++ b/test/FrontendC++/2003-11-18-PtrMemConstantInitializer.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct Gfx { void opMoveSetShowText(); diff --git a/test/FrontendC++/2003-11-25-ReturningOpaqueByValue.cpp b/test/FrontendC++/2003-11-25-ReturningOpaqueByValue.cpp index 83fe1b3..5ea0a2c 100644 --- a/test/FrontendC++/2003-11-25-ReturningOpaqueByValue.cpp +++ b/test/FrontendC++/2003-11-25-ReturningOpaqueByValue.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #include <vector> std::vector<int> my_method (); diff --git a/test/FrontendC++/2003-11-27-MultipleInheritanceThunk.cpp b/test/FrontendC++/2003-11-27-MultipleInheritanceThunk.cpp index 16026c3..99cfc8d 100644 --- a/test/FrontendC++/2003-11-27-MultipleInheritanceThunk.cpp +++ b/test/FrontendC++/2003-11-27-MultipleInheritanceThunk.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct CallSite { diff --git a/test/FrontendC++/2003-11-29-DuplicatedCleanupTest.cpp b/test/FrontendC++/2003-11-29-DuplicatedCleanupTest.cpp index 8131baa..8df95cb 100644 --- a/test/FrontendC++/2003-11-29-DuplicatedCleanupTest.cpp +++ b/test/FrontendC++/2003-11-29-DuplicatedCleanupTest.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null void doesntThrow() throw(); diff --git a/test/FrontendC++/2003-12-08-ArrayOfPtrToMemberFunc.cpp b/test/FrontendC++/2003-12-08-ArrayOfPtrToMemberFunc.cpp index d512234..b87e786 100644 --- a/test/FrontendC++/2003-12-08-ArrayOfPtrToMemberFunc.cpp +++ b/test/FrontendC++/2003-12-08-ArrayOfPtrToMemberFunc.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct Evil { void fun (); diff --git a/test/FrontendC++/2004-03-08-ReinterpretCastCopy.cpp b/test/FrontendC++/2004-03-08-ReinterpretCastCopy.cpp index 755d7c7..35880ab 100644 --- a/test/FrontendC++/2004-03-08-ReinterpretCastCopy.cpp +++ b/test/FrontendC++/2004-03-08-ReinterpretCastCopy.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct A { virtual void Method() = 0; diff --git a/test/FrontendC++/2004-03-15-CleanupsAndGotos.cpp b/test/FrontendC++/2004-03-15-CleanupsAndGotos.cpp index 9bc70c8..c2e52f6 100644 --- a/test/FrontendC++/2004-03-15-CleanupsAndGotos.cpp +++ b/test/FrontendC++/2004-03-15-CleanupsAndGotos.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null // Testcase from Bug 291 diff --git a/test/FrontendC++/2004-06-08-LateTemplateInstantiation.cpp b/test/FrontendC++/2004-06-08-LateTemplateInstantiation.cpp index 16d8e5e..4ad4c7d 100644 --- a/test/FrontendC++/2004-06-08-LateTemplateInstantiation.cpp +++ b/test/FrontendC++/2004-06-08-LateTemplateInstantiation.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null diff --git a/test/FrontendC++/2004-09-27-CompilerCrash.cpp b/test/FrontendC++/2004-09-27-CompilerCrash.cpp index f507c23..f52baaf 100644 --- a/test/FrontendC++/2004-09-27-CompilerCrash.cpp +++ b/test/FrontendC++/2004-09-27-CompilerCrash.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null struct Pass {} ; template<typename PassName> diff --git a/test/FrontendC++/2006-11-06-StackTrace.cpp b/test/FrontendC++/2006-11-06-StackTrace.cpp index f6a4428..bbb9af1 100644 --- a/test/FrontendC++/2006-11-06-StackTrace.cpp +++ b/test/FrontendC++/2006-11-06-StackTrace.cpp @@ -1,7 +1,7 @@ // This is a regression test on debug info to make sure that we can get a // meaningful stack trace from a C++ program. // RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ -// RUN: llc --disable-fp-elim -o %t.s -f -O0 -relocation-model=pic +// RUN: llc --disable-fp-elim -o %t.s -O0 -relocation-model=pic // RUN: %compile_c %t.s -o %t.o // RUN: %link %t.o -o %t.exe // RUN: echo {break DeepStack::deepest\nrun 17\nwhere\n} > %t.in @@ -10,8 +10,9 @@ // RUN: gdb -q -batch -n -x %t.in %t.exe | \ // RUN: grep {#7 0x.* in main.*(argc=\[12\],.*argv=.*)} -// Only works on ppc, x86 and x86_64. Should generalize? -// XFAIL: alpha|ia64|arm +// Only works on ppc (but not apple-darwin9), x86 and x86_64. Should +// generalize? +// XFAIL: alpha|arm|powerpc-apple-darwin9 #include <stdlib.h> diff --git a/test/FrontendC++/2006-11-30-NoCompileUnit.cpp b/test/FrontendC++/2006-11-30-NoCompileUnit.cpp index 70fc642..3522c67 100644 --- a/test/FrontendC++/2006-11-30-NoCompileUnit.cpp +++ b/test/FrontendC++/2006-11-30-NoCompileUnit.cpp @@ -1,13 +1,13 @@ // This is a regression test on debug info to make sure we don't hit a compile // unit size issue with gdb. // RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ -// RUN: llc --disable-fp-elim -o NoCompileUnit.s -f +// RUN: llc --disable-fp-elim -o NoCompileUnit.s // RUN: %compile_c NoCompileUnit.s -o NoCompileUnit.o // RUN: %link NoCompileUnit.o -o NoCompileUnit.exe // RUN: echo {break main\nrun\np NoCompileUnit::pubname} > %t2 // RUN: gdb -q -batch -n -x %t2 NoCompileUnit.exe | \ // RUN: tee NoCompileUnit.out | not grep {"low == high"} -// XFAIL: alpha|ia64|arm +// XFAIL: alpha|arm // XFAIL: * // See PR2454 diff --git a/test/FrontendC++/2006-11-30-Pubnames.cpp b/test/FrontendC++/2006-11-30-Pubnames.cpp index 8102713..b44566a 100644 --- a/test/FrontendC++/2006-11-30-Pubnames.cpp +++ b/test/FrontendC++/2006-11-30-Pubnames.cpp @@ -1,13 +1,13 @@ // This is a regression test on debug info to make sure that we can access // qualified global names. // RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ -// RUN: llc --disable-fp-elim -o %t.s -f -O0 +// RUN: llc --disable-fp-elim -o %t.s -O0 // RUN: %compile_c %t.s -o %t.o // RUN: %link %t.o -o %t.exe // RUN: %llvmdsymutil %t.exe // RUN: echo {break main\nrun\np Pubnames::pubname} > %t.in // RUN: gdb -q -batch -n -x %t.in %t.exe | tee %t.out | grep {\$1 = 10} -// XFAIL: alpha|ia64|arm +// XFAIL: alpha|arm struct Pubnames { static int pubname; }; diff --git a/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp b/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp index 4797baf..174dddf 100644 --- a/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp +++ b/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #ifdef PACKED #define P __attribute__((packed)) diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp index 3ba5d7b..55da1a6 100644 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp +++ b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #ifdef PACKED #define P __attribute__((packed)) diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp index ad272c9..46a8949 100644 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp +++ b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #ifdef PACKED diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp index e7517dd..7377b82 100644 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp +++ b/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #ifdef PACKED diff --git a/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp b/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp index 52e2471..b550b5f 100644 --- a/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp +++ b/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -f -o /dev/null +// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null #ifdef PACKED #define P __attribute__((packed)) diff --git a/test/FrontendC++/2009-04-21-DtorNames-dbg.cpp b/test/FrontendC++/2009-04-21-DtorNames-dbg.cpp index dfc607e..997c3f7 100644 --- a/test/FrontendC++/2009-04-21-DtorNames-dbg.cpp +++ b/test/FrontendC++/2009-04-21-DtorNames-dbg.cpp @@ -1,4 +1,4 @@ -// RUN: %llvmgcc -c -g %s -o - | llc -O0 -f -o %t.s +// RUN: %llvmgcc -c -g %s -o - | llc -O0 -o %t.s // RUN: %compile_c %t.s -o %t.o // PR4025 diff --git a/test/FrontendC++/2009-06-20-DarwinPPCLayout.cpp b/test/FrontendC++/2009-06-20-DarwinPPCLayout.cpp index eef0e86..dcb2f16 100644 --- a/test/FrontendC++/2009-06-20-DarwinPPCLayout.cpp +++ b/test/FrontendC++/2009-06-20-DarwinPPCLayout.cpp @@ -3,8 +3,7 @@ // RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep quux | grep global | grep {struct.bar} // RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep foo | grep global | grep {struct.SRCFilter::FilterEntry} // RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep {struct.bar} | grep {1 x i32} -// RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep {struct.CC} | grep {struct.bar} -// RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep {struct.bar} | grep {1 x i32} +// RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep {struct.CC} | grep {struct.payre<KBFP,float*} | grep {.base.32} | grep {1 x i32} // RUN: %llvmgxx -S -m32 -emit-llvm %s -o - | grep {struct.SRCFilter::FilterEntry} | not grep {1 x i32} // XFAIL: * // XTARGET: powerpc-apple-darwin @@ -30,3 +29,4 @@ class CC ccc; struct bar { KBFP x; float* y;}; // 16 bytes struct bar quux; + diff --git a/test/FrontendC++/2009-06-30-ByrefBlock.cpp b/test/FrontendC++/2009-06-30-ByrefBlock.cpp index 6f8869c..be9c94f 100644 --- a/test/FrontendC++/2009-06-30-ByrefBlock.cpp +++ b/test/FrontendC++/2009-06-30-ByrefBlock.cpp @@ -1,6 +1,9 @@ -// Insure __block_holder_tmp is allocated on the stack. +// Insure __block_holder_tmp is allocated on the stack. Darwin only. // RUN: %llvmgxx %s -S -O2 -o - | egrep {__block_holder_tmp.*alloca} +// XFAIL: * +// XTARGET: darwin // <rdar://problem/5865221> +// END. extern void fubar_dispatch_sync(void (^PP)(void)); void fubar() { __block void *voodoo; diff --git a/test/FrontendC++/2009-07-15-LineNumbers.cpp b/test/FrontendC++/2009-07-15-LineNumbers.cpp new file mode 100644 index 0000000..54624a3 --- /dev/null +++ b/test/FrontendC++/2009-07-15-LineNumbers.cpp @@ -0,0 +1,28 @@ +// This is a regression test on debug info to make sure that we can +// print line numbers in asm. +// RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ +// RUN: llc --disable-fp-elim -O0 -relocation-model=pic | grep {# SrcLine 25} +// XFAIL: * + +#include <stdlib.h> + +class DeepStack { + int seedVal; +public: + DeepStack(int seed) : seedVal(seed) {} + + int shallowest( int x ) { return shallower(x + 1); } + int shallower ( int x ) { return shallow(x + 2); } + int shallow ( int x ) { return deep(x + 3); } + int deep ( int x ) { return deeper(x + 4); } + int deeper ( int x ) { return deepest(x + 6); } + int deepest ( int x ) { return x + 7; } + + int runit() { return shallowest(seedVal); } +}; + +int main ( int argc, char** argv) { + + DeepStack DS9( (argc > 1 ? atoi(argv[1]) : 0) ); + return DS9.runit(); +} diff --git a/test/FrontendC++/2009-07-16-PrivateCopyConstructor.cpp b/test/FrontendC++/2009-07-16-PrivateCopyConstructor.cpp new file mode 100644 index 0000000..96e85b2 --- /dev/null +++ b/test/FrontendC++/2009-07-16-PrivateCopyConstructor.cpp @@ -0,0 +1,15 @@ +// RUN: %llvmgxx %s -S +// XFAIL: darwin + +#include <set> + +class A { +public: + A(); +private: + A(const A&); +}; +void B() +{ + std::set<void *, A> foo; +} diff --git a/test/FrontendC++/2009-07-16-Using.cpp b/test/FrontendC++/2009-07-16-Using.cpp new file mode 100644 index 0000000..1acadf6 --- /dev/null +++ b/test/FrontendC++/2009-07-16-Using.cpp @@ -0,0 +1,8 @@ +// RUN: %llvmgxx %s -S + +namespace A { + typedef int B; +} +struct B { +}; +using ::A::B; diff --git a/test/FrontendC++/2009-08-03-Varargs.cpp b/test/FrontendC++/2009-08-03-Varargs.cpp new file mode 100644 index 0000000..cea3894 --- /dev/null +++ b/test/FrontendC++/2009-08-03-Varargs.cpp @@ -0,0 +1,5 @@ +// RUN: %llvmgxx %s -S -emit-llvm -o - | grep _Z1az\(\.\.\.\) +// XFAIL: * +// PR4678 +void a(...) { +} diff --git a/test/FrontendC++/2009-08-05-ZeroInitWidth.cpp b/test/FrontendC++/2009-08-05-ZeroInitWidth.cpp new file mode 100644 index 0000000..bc862e7 --- /dev/null +++ b/test/FrontendC++/2009-08-05-ZeroInitWidth.cpp @@ -0,0 +1,12 @@ +// RUN: %llvmgxx -c -emit-llvm %s -o - +// rdar://7114564 +struct A { + unsigned long long : (sizeof(unsigned long long) * 8) - 16; +}; +struct B { + A a; +}; +struct B b = { + {} +}; + diff --git a/test/FrontendC++/2009-08-11-VectorRetTy.cpp b/test/FrontendC++/2009-08-11-VectorRetTy.cpp new file mode 100644 index 0000000..b2c3ba1 --- /dev/null +++ b/test/FrontendC++/2009-08-11-VectorRetTy.cpp @@ -0,0 +1,13 @@ +// RUN: %llvmgxx %s -c -o /dev/null +// <rdar://problem/7096460> +typedef void (*Func) (); +typedef long long m64 __attribute__((__vector_size__(8), __may_alias__)); +static inline m64 __attribute__((__always_inline__, __nodebug__)) _mm_set1_pi16() {} +template <class MM> +static void Bork() { + const m64 mmx_0x00ff = _mm_set1_pi16(); +} +struct A {}; +Func arr[] = { + Bork<A> +}; diff --git a/test/FrontendC++/2009-09-04-modify-crash.cpp b/test/FrontendC++/2009-09-04-modify-crash.cpp new file mode 100644 index 0000000..ac16f8c --- /dev/null +++ b/test/FrontendC++/2009-09-04-modify-crash.cpp @@ -0,0 +1,7 @@ +// RUN: %llvmgxx %s -emit-llvm -fapple-kext -S -o - +// The extra check in 71555 caused this to crash on Darwin X86 +// in an assert build. +class foo { + virtual ~foo (); +}; +foo::~foo(){} diff --git a/test/FrontendC++/2009-09-09-packed-layout.cpp b/test/FrontendC++/2009-09-09-packed-layout.cpp new file mode 100644 index 0000000..a569f9f --- /dev/null +++ b/test/FrontendC++/2009-09-09-packed-layout.cpp @@ -0,0 +1,18 @@ +// RUN: %llvmgxx -S -m32 -emit-llvm %s -o /dev/null +class X { + public: + virtual ~X(); + short y; +}; +#pragma pack(push, 1) +class Z : public X { + public: enum { foo = ('x') }; + virtual int y() const; +}; +#pragma pack(pop) +class Y : public X { +public: enum { foo = ('y'), bar = 0 }; +}; +X x; +Y y; +Z z; diff --git a/test/FrontendC++/member-alignment.cpp b/test/FrontendC++/member-alignment.cpp new file mode 100644 index 0000000..01c90ca --- /dev/null +++ b/test/FrontendC++/member-alignment.cpp @@ -0,0 +1,20 @@ +// RUN: %llvmgxx -S -emit-llvm %s -o - | FileCheck %s +// XFAIL: arm + +// rdar://7268289 + +class t { +public: + virtual void foo(void); + void bar(void); +}; + +void +t::bar(void) { +// CHECK: _ZN1t3barEv{{.*}} align 2 +} + +void +t::foo(void) { +// CHECK: _ZN1t3fooEv{{.*}} align 2 +} diff --git a/test/FrontendC++/msasm.cpp b/test/FrontendC++/msasm.cpp new file mode 100644 index 0000000..d8d1f37 --- /dev/null +++ b/test/FrontendC++/msasm.cpp @@ -0,0 +1,23 @@ +// RUN: %llvmgxx %s -fasm-blocks -S -o - | FileCheck %s +// Complicated expression as jump target +// XFAIL: * +// XTARGET: x86,i386,i686 + +void Method3() +{ +// CHECK: Method3 +// CHECK-NOT: msasm + asm("foo:"); +// CHECK: return +} + +void Method4() +{ +// CHECK: Method4 +// CHECK: msasm + asm { + bar: + } +// CHECK: return +} + |