Remove obsolete or migrated tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138135 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Christopher 2011-08-19 23:08:41 +00:00
parent 854a7db117
commit 0e71288943
20 changed files with 0 additions and 570 deletions

View File

@ -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
{
}

View File

@ -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 ()}
};

View File

@ -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;
}

View File

@ -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);
}

View File

@ -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);
}

View File

@ -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);
}

View File

@ -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);
}

View File

@ -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);
}

View File

@ -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;
}

View File

@ -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);
}

View File

@ -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);
}

View File

@ -1,12 +0,0 @@
// RUN: %llvmgxx -S %s -o /dev/null
#include <locale>
namespace std
{
codecvt<char, char, mbstate_t>::
codecvt(size_t __refs)
: __codecvt_abstract_base<char, char, mbstate_t>(__refs),
_M_c_locale_codecvt(_S_get_c_locale())
{ }
}

View File

@ -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);
}

View File

@ -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;
}

View File

@ -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 ();
}
}

View File

@ -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 (...) {}
}

View File

@ -1,6 +0,0 @@
// RUN: %llvmgxx -S %s -o - | grep noalias
void foo(int * __restrict myptr1, int * myptr2) {
myptr1[0] = 0;
myptr2[0] = 0;
}

View File

@ -1,6 +0,0 @@
// RUN: %llvmgxx -S %s -o - | grep noalias
void foo(int & __restrict myptr1, int & myptr2) {
myptr1 = 0;
myptr2 = 0;
}

View File

@ -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;
}

View File

@ -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);
}
}