From 0e7128894337202ae4f368c0b14ce5909dddb84d Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Fri, 19 Aug 2011 23:08:41 +0000 Subject: [PATCH] Remove obsolete or migrated tests. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138135 91177308-0d34-0410-b5e6-96231b3b80d8 --- .../2007-01-06-ELF-Thunk-Sections.cpp | 49 ----------- test/FrontendC++/2007-01-06-PtrMethodInit.cpp | 75 ---------------- .../2007-03-27-FunctionVarRename.cpp | 17 ---- .../2007-04-05-PackedBitFields-1.cpp | 23 ----- .../2007-04-05-PackedBitFieldsOverlap-2.cpp | 24 ----- .../2007-04-05-PackedBitFieldsOverlap.cpp | 24 ----- .../2007-04-05-PackedBitFieldsSmall.cpp | 27 ------ .../2007-04-05-StructPackedFieldUnpacked.cpp | 25 ------ test/FrontendC++/2007-04-10-PackedUnion.cpp | 41 --------- .../2007-04-11-InlineStorageClassC++.cpp | 44 ---------- test/FrontendC++/2007-04-14-FNoBuiltin.cpp | 7 -- test/FrontendC++/2007-04-31-TryCatch.cpp | 12 --- test/FrontendC++/2007-05-03-VectorInit.cpp | 17 ---- .../2007-05-16-ReverseBitFieldCrash.cpp | 24 ----- test/FrontendC++/2007-05-23-TryFinally.cpp | 16 ---- test/FrontendC++/2007-07-04-NestedCatches.cpp | 32 ------- .../FrontendC++/2007-07-29-RestrictPtrArg.cpp | 6 -- .../FrontendC++/2007-07-29-RestrictRefArg.cpp | 6 -- .../FrontendC++/2007-08-01-RestrictMethod.cpp | 13 --- .../2007-09-10-RecursiveTypeResolution.cpp | 88 ------------------- 20 files changed, 570 deletions(-) delete mode 100644 test/FrontendC++/2007-01-06-ELF-Thunk-Sections.cpp delete mode 100644 test/FrontendC++/2007-01-06-PtrMethodInit.cpp delete mode 100644 test/FrontendC++/2007-03-27-FunctionVarRename.cpp delete mode 100644 test/FrontendC++/2007-04-05-PackedBitFields-1.cpp delete mode 100644 test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp delete mode 100644 test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp delete mode 100644 test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp delete mode 100644 test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp delete mode 100644 test/FrontendC++/2007-04-10-PackedUnion.cpp delete mode 100644 test/FrontendC++/2007-04-11-InlineStorageClassC++.cpp delete mode 100644 test/FrontendC++/2007-04-14-FNoBuiltin.cpp delete mode 100644 test/FrontendC++/2007-04-31-TryCatch.cpp delete mode 100644 test/FrontendC++/2007-05-03-VectorInit.cpp delete mode 100644 test/FrontendC++/2007-05-16-ReverseBitFieldCrash.cpp delete mode 100644 test/FrontendC++/2007-05-23-TryFinally.cpp delete mode 100644 test/FrontendC++/2007-07-04-NestedCatches.cpp delete mode 100644 test/FrontendC++/2007-07-29-RestrictPtrArg.cpp delete mode 100644 test/FrontendC++/2007-07-29-RestrictRefArg.cpp delete mode 100644 test/FrontendC++/2007-08-01-RestrictMethod.cpp delete mode 100644 test/FrontendC++/2007-09-10-RecursiveTypeResolution.cpp diff --git a/test/FrontendC++/2007-01-06-ELF-Thunk-Sections.cpp b/test/FrontendC++/2007-01-06-ELF-Thunk-Sections.cpp deleted file mode 100644 index 5206640be10..00000000000 --- a/test/FrontendC++/2007-01-06-ELF-Thunk-Sections.cpp +++ /dev/null @@ -1,49 +0,0 @@ -// RUN: %llvmgxx %s -S -o - | not grep gnu.linkonce. -// PR1085 - -class -__attribute__((visibility("default"))) QGenericArgument -{ - public:inline QGenericArgument(const char *aName = 0, const void *aData = 0):_data(aData), _name(aName) { - } - private:const void *_data; - const char *_name; -}; -struct __attribute__ (( - visibility("default"))) QMetaObject -{ - struct { - } - d; -}; -class -__attribute__((visibility("default"))) QObject -{ - virtual const QMetaObject *metaObject() const; -}; -class -__attribute__((visibility("default"))) QPaintDevice -{ - public:enum PaintDeviceMetric { - PdmWidth = 1, PdmHeight, PdmWidthMM, PdmHeightMM, PdmNumColors, PdmDepth, PdmDpiX, PdmDpiY, PdmPhysicalDpiX, PdmPhysicalDpiY - }; - virtual ~ QPaintDevice(); - union { - } - ct; -}; -class -__attribute__((visibility("default"))) QWidget:public QObject, public QPaintDevice -{ -}; -class -__attribute__((visibility("default"))) QDialog:public QWidget -{ -}; -class TopicChooser:public QDialog { - virtual const QMetaObject *metaObject() const; -}; -const QMetaObject *TopicChooser:: -metaObject() const -{ -} diff --git a/test/FrontendC++/2007-01-06-PtrMethodInit.cpp b/test/FrontendC++/2007-01-06-PtrMethodInit.cpp deleted file mode 100644 index beb79457b55..00000000000 --- a/test/FrontendC++/2007-01-06-PtrMethodInit.cpp +++ /dev/null @@ -1,75 +0,0 @@ -// RUN: %llvmgxx %s -S -o - -// PR1084 - -extern "C" -{ - typedef unsigned char PRUint8; - typedef unsigned int PRUint32; -} -typedef PRUint32 nsresult; -struct nsID -{ -}; -typedef nsID nsIID; -class nsISupports -{ -}; -extern "C++" -{ - template < class T > struct nsCOMTypeInfo - { - static const nsIID & GetIID () - { - } - }; -} - -class nsIDOMEvent:public nsISupports -{ -}; -class nsIDOMEventListener:public nsISupports -{ -public:static const nsIID & GetIID () - { - } - virtual nsresult - __attribute__ ((regparm (0), cdecl)) HandleEvent (nsIDOMEvent * event) = - 0; -}; -class nsIDOMMouseListener:public nsIDOMEventListener -{ -public:static const nsIID & GetIID () - { - static const nsIID iid = { - }; - } - virtual nsresult - __attribute__ ((regparm (0), - cdecl)) MouseDown (nsIDOMEvent * aMouseEvent) = 0; -}; -typedef -typeof (&nsIDOMEventListener::HandleEvent) - GenericHandler; - struct EventDispatchData - { - PRUint32 message; - GenericHandler method; - PRUint8 bits; - }; - struct EventTypeData - { - const EventDispatchData *events; - int numEvents; - const nsIID *iid; - }; - static const EventDispatchData sMouseEvents[] = { - { - (300 + 2), - reinterpret_cast < GenericHandler > (&nsIDOMMouseListener::MouseDown), - 0x01} - }; -static const EventTypeData sEventTypes[] = { - { - sMouseEvents, (sizeof (sMouseEvents) / sizeof (sMouseEvents[0])), - &nsCOMTypeInfo < nsIDOMMouseListener >::GetIID ()} -}; diff --git a/test/FrontendC++/2007-03-27-FunctionVarRename.cpp b/test/FrontendC++/2007-03-27-FunctionVarRename.cpp deleted file mode 100644 index 6ff1284ddb4..00000000000 --- a/test/FrontendC++/2007-03-27-FunctionVarRename.cpp +++ /dev/null @@ -1,17 +0,0 @@ -// RUN: %llvmgxx %s -S -o - | not grep eprintf1 -// RUN: %llvmgxx %s -S -o - | grep eprintf - -// Only one eprintf should exist in the output - -extern "C" -void __eprintf(); - -void foo() { - - __eprintf(); -} - -void *bar() { - extern void *__eprintf; - return &__eprintf; -} diff --git a/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp b/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp deleted file mode 100644 index 174dddf6ab6..00000000000 --- a/test/FrontendC++/2007-04-05-PackedBitFields-1.cpp +++ /dev/null @@ -1,23 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null - -#ifdef PACKED -#define P __attribute__((packed)) -#else -#define P -#endif - -struct P M_Packed { - unsigned int l_Packed; - unsigned short k_Packed : 6, - i_Packed : 15, - j_Packed : 11; - -}; - -struct M_Packed sM_Packed; - -int testM_Packed (void) { - struct M_Packed x; - return (x.i_Packed != 0); -} - diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp deleted file mode 100644 index 55da1a6ab40..00000000000 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap-2.cpp +++ /dev/null @@ -1,24 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null - -#ifdef PACKED -#define P __attribute__((packed)) -#else -#define P -#endif - -struct P M_Packed { - unsigned long sorted : 1; - unsigned long from_array : 1; - unsigned long mixed_encoding : 1; - unsigned long encoding : 8; - unsigned long count : 21; - -}; - -struct M_Packed sM_Packed; - -int testM_Packed (void) { - struct M_Packed x; - return (x.count != 0); -} - diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp deleted file mode 100644 index 46a89491ee2..00000000000 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsOverlap.cpp +++ /dev/null @@ -1,24 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null - - -#ifdef PACKED -#define P __attribute__((packed)) -#else -#define P -#endif - -struct P M_Packed { - unsigned int l_Packed; - unsigned short k_Packed : 6, - i_Packed : 15; - char c; - -}; - -struct M_Packed sM_Packed; - -int testM_Packed (void) { - struct M_Packed x; - return (x.i_Packed != 0); -} - diff --git a/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp b/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp deleted file mode 100644 index 7377b8292d5..00000000000 --- a/test/FrontendC++/2007-04-05-PackedBitFieldsSmall.cpp +++ /dev/null @@ -1,27 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null - - -#ifdef PACKED -// This is an example where size of Packed struct is smaller then -// the size of bit field type. -#define P __attribute__((packed)) -#else -#define P -#endif - -struct P M_Packed { - unsigned long long X:50; - unsigned Y:2; -}; - -struct M_Packed sM_Packed; - -int testM_Packed (void) { - struct M_Packed x; - return (0 != x.Y); -} - -int testM_Packed2 (void) { - struct M_Packed x; - return (0 != x.X); -} diff --git a/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp b/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp deleted file mode 100644 index b550b5fdb01..00000000000 --- a/test/FrontendC++/2007-04-05-StructPackedFieldUnpacked.cpp +++ /dev/null @@ -1,25 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | llvm-as -o /dev/null - -#ifdef PACKED -#define P __attribute__((packed)) -#else -#define P -#endif - -struct UnPacked { - int X; - int Y; -}; - -struct P M_Packed { - unsigned char A; - struct UnPacked B; -}; - -struct M_Packed sM_Packed; - -int testM_Packed (void) { - struct M_Packed x; - return (x.B.Y != 0); -} - diff --git a/test/FrontendC++/2007-04-10-PackedUnion.cpp b/test/FrontendC++/2007-04-10-PackedUnion.cpp deleted file mode 100644 index b4b8894ae2c..00000000000 --- a/test/FrontendC++/2007-04-10-PackedUnion.cpp +++ /dev/null @@ -1,41 +0,0 @@ -// RUN: %llvmgxx -S %s -o /dev/null -extern "C" { - -#pragma pack(push, 2) - typedef struct ABC* abc; - - struct ABCS { - float red; - float green; - float blue; - float alpha; - }; - - typedef void (*XYZ)(); -#pragma pack(pop) -} - - -union ABCU { - ABCS color; - XYZ bg; -}; - -struct AData { - ABCU data; -}; - -class L { - public: - L() {} - L(const L& other); - - private: - AData fdata; -}; - - -L::L(const L& other) -{ - fdata = other.fdata; -} diff --git a/test/FrontendC++/2007-04-11-InlineStorageClassC++.cpp b/test/FrontendC++/2007-04-11-InlineStorageClassC++.cpp deleted file mode 100644 index 4c2aad397c8..00000000000 --- a/test/FrontendC++/2007-04-11-InlineStorageClassC++.cpp +++ /dev/null @@ -1,44 +0,0 @@ -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xglobWeak | grep linkonce | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xextWeak | grep linkonce | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xWeaknoinline | grep weak | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xWeakextnoinline | grep weak | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xglobnoWeak | grep linkonce | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xstatnoWeak | grep internal | count 1 -// RUN: %llvmgxx %s -S -O0 -o - | grep define | \ -// RUN: grep xextnoWeak | grep linkonce | count 1 -inline int xglobWeak(int) __attribute__((weak)); -inline int xglobWeak (int i) { - return i*2; -} -inline int xextWeak(int) __attribute__((weak)); -extern inline int xextWeak (int i) { - return i*4; -} -int xWeaknoinline(int) __attribute__((weak)); -int xWeaknoinline(int i) { - return i*8; -} -int xWeakextnoinline(int) __attribute__((weak)); -extern int xWeakextnoinline(int i) { - return i*16; -} -inline int xglobnoWeak (int i) { - return i*32; -} -static inline int xstatnoWeak (int i) { - return i*64; -} -extern inline int xextnoWeak (int i) { - return i*128; -} -int j(int y) { - return xglobnoWeak(y)+xstatnoWeak(y)+xextnoWeak(y)+ - xglobWeak(y)+xextWeak(y)+ - xWeakextnoinline(y)+xWeaknoinline(y); -} diff --git a/test/FrontendC++/2007-04-14-FNoBuiltin.cpp b/test/FrontendC++/2007-04-14-FNoBuiltin.cpp deleted file mode 100644 index 31e4528754e..00000000000 --- a/test/FrontendC++/2007-04-14-FNoBuiltin.cpp +++ /dev/null @@ -1,7 +0,0 @@ -// RUN: %llvmgcc -S %s -O2 -fno-builtin -o - | grep call.*printf -// Check that -fno-builtin is honored. - -extern "C" int printf(const char*, ...); -void foo(const char *msg) { - printf("%s\n",msg); -} diff --git a/test/FrontendC++/2007-04-31-TryCatch.cpp b/test/FrontendC++/2007-04-31-TryCatch.cpp deleted file mode 100644 index 8b8254d76e7..00000000000 --- a/test/FrontendC++/2007-04-31-TryCatch.cpp +++ /dev/null @@ -1,12 +0,0 @@ -// RUN: %llvmgxx -S %s -o /dev/null - -#include - -namespace std -{ - codecvt:: - codecvt(size_t __refs) - : __codecvt_abstract_base(__refs), - _M_c_locale_codecvt(_S_get_c_locale()) - { } -} diff --git a/test/FrontendC++/2007-05-03-VectorInit.cpp b/test/FrontendC++/2007-05-03-VectorInit.cpp deleted file mode 100644 index af56d3a08a8..00000000000 --- a/test/FrontendC++/2007-05-03-VectorInit.cpp +++ /dev/null @@ -1,17 +0,0 @@ -// RUN: %llvmgxx %s -S -O0 -o - -// PR1378 - -typedef float v4sf __attribute__((vector_size(16))); - -typedef v4sf float4; - -static float4 splat4(float a) -{ - float4 tmp = {a,a,a,a}; - return tmp; -} - -float4 foo(float a) -{ - return splat4(a); -} diff --git a/test/FrontendC++/2007-05-16-ReverseBitFieldCrash.cpp b/test/FrontendC++/2007-05-16-ReverseBitFieldCrash.cpp deleted file mode 100644 index 42342fc9486..00000000000 --- a/test/FrontendC++/2007-05-16-ReverseBitFieldCrash.cpp +++ /dev/null @@ -1,24 +0,0 @@ -// RUN: %llvmgxx %s -S -o - - -#pragma reverse_bitfields on -typedef unsigned long UINT32; - -extern void abort(void); - -typedef struct TestStruct -{ - long first: 15, - second: 17; -} TestStruct; - -int main (int argc, char * const argv[]) { - - TestStruct testStruct = {1, 0}; - - UINT32 dw = *(UINT32 *)(&testStruct); - - if(!(dw & 0xFFFF)) - abort (); - - return 0; -} diff --git a/test/FrontendC++/2007-05-23-TryFinally.cpp b/test/FrontendC++/2007-05-23-TryFinally.cpp deleted file mode 100644 index c7971820ec7..00000000000 --- a/test/FrontendC++/2007-05-23-TryFinally.cpp +++ /dev/null @@ -1,16 +0,0 @@ -// RUN: %llvmgxx %s -S -O2 -o - | ignore grep _Unwind_Resume | \ -// RUN: wc -l | grep {\[23\]} - -struct One { }; -struct Two { }; - -void handle_unexpected () { - try - { - throw; - } - catch (One &) - { - throw Two (); - } -} diff --git a/test/FrontendC++/2007-07-04-NestedCatches.cpp b/test/FrontendC++/2007-07-04-NestedCatches.cpp deleted file mode 100644 index b10a5db754b..00000000000 --- a/test/FrontendC++/2007-07-04-NestedCatches.cpp +++ /dev/null @@ -1,32 +0,0 @@ -// RUN: %llvmgxx %s -S -O2 -o - | \ -// RUN: ignore grep {eh\.selector.*One.*Two.*Three.*Four.*Five.*Six.*null} | \ -// RUN: wc -l | grep {\[01\]} - -extern void X(void); - -struct One {}; -struct Two {}; -struct Three {}; -struct Four {}; -struct Five {}; -struct Six {}; - -static void A(void) throw () -{ - X(); -} - -static void B(void) throw (Two) -{ - try { A(); } catch (One) {} -} - -static void C(void) throw (Six, Five) -{ - try { B(); } catch (Three) {} catch (Four) {} -} - -int main () -{ - try { C(); } catch (...) {} -} diff --git a/test/FrontendC++/2007-07-29-RestrictPtrArg.cpp b/test/FrontendC++/2007-07-29-RestrictPtrArg.cpp deleted file mode 100644 index 2e85abdf25e..00000000000 --- a/test/FrontendC++/2007-07-29-RestrictPtrArg.cpp +++ /dev/null @@ -1,6 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | grep noalias - -void foo(int * __restrict myptr1, int * myptr2) { - myptr1[0] = 0; - myptr2[0] = 0; -} diff --git a/test/FrontendC++/2007-07-29-RestrictRefArg.cpp b/test/FrontendC++/2007-07-29-RestrictRefArg.cpp deleted file mode 100644 index 128ddb3ab59..00000000000 --- a/test/FrontendC++/2007-07-29-RestrictRefArg.cpp +++ /dev/null @@ -1,6 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | grep noalias - -void foo(int & __restrict myptr1, int & myptr2) { - myptr1 = 0; - myptr2 = 0; -} diff --git a/test/FrontendC++/2007-08-01-RestrictMethod.cpp b/test/FrontendC++/2007-08-01-RestrictMethod.cpp deleted file mode 100644 index feefaa1759c..00000000000 --- a/test/FrontendC++/2007-08-01-RestrictMethod.cpp +++ /dev/null @@ -1,13 +0,0 @@ -// RUN: %llvmgxx -S %s -o - | grep noalias - - -class foo { - int member[4]; - - void bar(int * a); - -}; - -void foo::bar(int * a) __restrict { - member[3] = *a; -} diff --git a/test/FrontendC++/2007-09-10-RecursiveTypeResolution.cpp b/test/FrontendC++/2007-09-10-RecursiveTypeResolution.cpp deleted file mode 100644 index 1fcf15f0d9d..00000000000 --- a/test/FrontendC++/2007-09-10-RecursiveTypeResolution.cpp +++ /dev/null @@ -1,88 +0,0 @@ -// RUN: %llvmgxx -S %s -o - -// PR1634 - -namespace Manta -{ - class CallbackHandle - { - protected:virtual ~ CallbackHandle (void) - { - } - }; -template < typename Data1 > class CallbackBase_1Data:public CallbackHandle - { - }; -} - -namespace __gnu_cxx -{ - template < typename _Iterator, typename _Container > - class __normal_iterator - { - _Iterator _M_current; - }; -} - -namespace std -{ - template < typename _Tp > struct allocator - { - typedef _Tp *pointer; - }; - template < typename _InputIterator, - typename _Tp > inline void find (_InputIterator __last, - const _Tp & __val) - { - }; -} - -namespace Manta -{ - template < typename _Tp, typename _Alloc> struct _Vector_base - { - struct _Vector_impl - { - _Tp *_M_start; - }; - public: - _Vector_impl _M_impl; - }; - template < typename _Tp, typename _Alloc = std::allocator < _Tp > > - class vector:protected _Vector_base < _Tp,_Alloc > - { - public: - typedef __gnu_cxx::__normal_iterator < typename _Alloc::pointer, - vector < _Tp, _Alloc > > iterator; - iterator end () - { - } - }; - class MantaInterface - { - }; - class RTRT - { - virtual CallbackHandle *registerTerminationCallback (CallbackBase_1Data < - MantaInterface * >*); - virtual void unregisterCallback (CallbackHandle *); - typedef vector < CallbackBase_1Data < int >*>PRCallbackMapType; - PRCallbackMapType parallelPreRenderCallbacks; - }; -} -using namespace Manta; -CallbackHandle * -RTRT::registerTerminationCallback (CallbackBase_1Data < MantaInterface * >*cb) -{ - return cb; -} - -void -RTRT::unregisterCallback (CallbackHandle * callback) -{ - { - typedef CallbackBase_1Data < int > callback_t; - callback_t *cb = static_cast < callback_t * >(callback); - find (parallelPreRenderCallbacks.end (), cb); - } -} - -- 2.34.1