diff options
Diffstat (limited to 'gcc-4.8.1/gcc/testsuite/g++.dg/abi')
171 files changed, 0 insertions, 3857 deletions
diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/aarch64_guard1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/aarch64_guard1.C deleted file mode 100644 index ca1778b87..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/aarch64_guard1.C +++ /dev/null @@ -1,17 +0,0 @@ -// Check that the initialization guard variable is an 8-byte aligned, -// 8-byte doubleword and that only the least significant bit is used -// for initialization guard variables. -// { dg-do compile { target aarch64*-*-* } } -// { dg-options "-O -fdump-tree-original -fno-section-anchors" } - -int bar(); - -int *foo () -{ - static int x = bar (); - return &x; -} - -// { dg-final { scan-assembler _ZGVZ3foovE1x,8,8 } } -// { dg-final { scan-tree-dump "_ZGVZ3foovE1x & 1" "original" } } -// { dg-final { cleanup-tree-dump "original" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag1.C deleted file mode 100644 index 942929cdd..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag1.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-options "-Wabi-tag" } - -// { dg-final { scan-assembler "_Z1fB3barB3fooi" } } -void f(int) __attribute ((abi_tag ("foo","bar"))); - -struct __attribute ((abi_tag ("bar"))) A { }; - -struct B: A { }; // { dg-warning "bar. abi tag" } -struct D { A* ap; }; // { dg-warning "bar. abi tag" } - -// { dg-final { scan-assembler "_Z1gB3baz1AB3bar" } } -void g(A) __attribute ((abi_tag ("baz"))); -void g(A) __attribute ((abi_tag ("baz"))); - -int main() -{ - f(42); - g(A()); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag2.C deleted file mode 100644 index 0e92dcc1d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag2.C +++ /dev/null @@ -1,5 +0,0 @@ -void f(int); -void f(int) __attribute ((abi_tag ("foo"))); // { dg-error "adds abi tag" } - -struct C; -struct __attribute ((abi_tag ("foo"))) C; // { dg-error "adds abi tag" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag3.C deleted file mode 100644 index 05fd58e94..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag3.C +++ /dev/null @@ -1,36 +0,0 @@ -// An explicit specialization doesn't get the tag from its template unless -// it is specified there, too. - -// { dg-final { scan-assembler "_ZN3FooB5cxx11IcE1fEv" } } -template<typename T> -struct __attribute ((abi_tag("cxx11"))) Foo -{ - int f(); -}; - -// { dg-final { scan-assembler "_ZN3FooB5cxx11IiE1fEv" } } -template<> -struct -__attribute ((abi_tag("cxx11"))) -Foo<int> -{ - int f(); -}; - -// { dg-final { scan-assembler "_ZN3FooIdE1fEv" } } -template<> -struct -Foo<double> -{ - int f(); -}; - -int main() -{ - Foo<int> f; - f.f(); - Foo<char> f1; - f1.f(); - Foo<double> f2; - f2.f(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag4.C deleted file mode 100644 index 3f8d7bfbc..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/abi-tag4.C +++ /dev/null @@ -1,8 +0,0 @@ -// { dg-options "-Wabi-tag" } - -struct __attribute ((abi_tag ("X"))) A { }; - -struct B // { dg-warning "abi tag" } -{ - virtual void f(A); // { dg-message "declared here" } -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/align1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/align1.C deleted file mode 100644 index 2a70bce60..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/align1.C +++ /dev/null @@ -1,27 +0,0 @@ -// This was failuring on powerpc-darwin and powerpc-aix as -// we were taking the embeded type as the first field decl. -// This was PR target/18761. -// { dg-do run } - - -union A { - double d; -}; -union B { - enum E { e }; - double d; -}; -struct AlignA { - char c; - A a; -}; -struct AlignB { - char c; - B b; -}; -extern "C" void abort (); -int main () { - if ( __alignof__ (AlignA) != __alignof__ (AlignB)) - abort (); -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/anon1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/anon1.C deleted file mode 100644 index c45917a1b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/anon1.C +++ /dev/null @@ -1,5 +0,0 @@ -// PR c++/54883 - -namespace { enum E { E1 }; } void f(E e) { } - -// { dg-final { scan-assembler-not "globl" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec1.C deleted file mode 100644 index 4c462d5f3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec1.C +++ /dev/null @@ -1,34 +0,0 @@ -// Check that __cxa_vec_[c]ctor returns a pointer to the array -// { dg-do run { target arm*-*-* } } - -#include <cxxabi.h> - -#ifdef __ARM_EABI__ -using namespace __cxxabiv1; -static __cxa_cdtor_return_type cctor (void * a, void * b) -{ - *(char *) a = *(char *) b; - return a; -} - -int main() -{ - char data; - char data2; - char *p; - - p = (char *) __cxa_vec_ctor (&data, 1, 1, NULL, NULL); - if (p != &data) - return 1; - p = (char *) __cxa_vec_cctor (&data2, &data, 1, 1, cctor, NULL); - if (p != &data2) - return 1; - - return 0; -} -#else -int main() -{ - return 0; -} -#endif diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec2.C deleted file mode 100644 index 76f327aca..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_cxa_vec2.C +++ /dev/null @@ -1,41 +0,0 @@ -// Check that ARM vector delete functions accept NULL pointers as -// inputs. -// { dg-do run { target arm*-*-* } } - -#ifdef __ARM_EABI__ -#include <cxxabi.h> - -typedef void *(dtor_type)(void *); - -extern "C" { - void abort(); - void *__aeabi_vec_dtor_cookie(void *, dtor_type); - void __aeabi_vec_delete(void *, dtor_type); - void __aeabi_vec_delete3(void *, - dtor_type, - void (*)(void *, __SIZE_TYPE__)); - void __aeabi_vec_delete3_nodtor(void *, - void (*)(void *, __SIZE_TYPE__)); -} - -// These functions should never be called. -void* dtor(void *) -{ - abort (); -} - -void dealloc(void *, size_t) { - abort (); -} - -int main () { - if (__aeabi_vec_dtor_cookie (NULL, &dtor) != NULL) - return 1; - // These do not return values, but should not crash. - __aeabi_vec_delete (NULL, &dtor); - __aeabi_vec_delete3 (NULL, &dtor, &dealloc); - __aeabi_vec_delete3_nodtor (NULL, &dealloc); -} -#else -int main () {} -#endif diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_rtti1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_rtti1.C deleted file mode 100644 index a481bdd1f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_rtti1.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do compile { target arm*-*-eabi* arm*-*-symbianelf* } } -// { dg-options "-O2" } -// Check that, even when optimizing, we emit an out-of-line call to -// the type-info comparison function. -// { dg-final { scan-assembler _ZNKSt9type_infoeqERKS_ } } - -#include <typeinfo> - -extern const std::type_info& t1; -extern const std::type_info& t2; - -bool f() { - return t1 == t2; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list.C deleted file mode 100644 index 4f6f3a46d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list.C +++ /dev/null @@ -1,15 +0,0 @@ -// { dg-do compile { target { aarch64*-*-* arm*-*-* } } } -// { dg-options "-Wno-abi" } -// { dg-require-effective-target arm_eabi { target arm*-*-* } } - -// AAPCS \S 7.1.4 requires that va_list be a typedef for "struct -// __va_list". The mangling is as if it were "std::__va_list". -// AAPCS64 \S 7.1.4 has the same requirement for AArch64 targets. -// #include <stdarg.h> -typedef __builtin_va_list va_list; - -// { dg-final { scan-assembler "\n_Z1fPSt9__va_list:" } } -void f(va_list*) {} - -// { dg-final { scan-assembler "\n_Z1gSt9__va_listS_:" } } -void g(va_list, va_list) {} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.C deleted file mode 100644 index f5e4ca43d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.C +++ /dev/null @@ -1,7 +0,0 @@ -// { dg-do compile } -// { dg-options "-Wpsabi" } -// { dg-require-effective-target arm_eabi } - -#include <stdarg.h> -#include "arm_va_list2.h" - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.h b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.h deleted file mode 100644 index ebfb2deac..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/arm_va_list2.h +++ /dev/null @@ -1,4 +0,0 @@ -// The mangling of va_list changed in GCC 4.4. We want to warn about -// that -- but not in a system header. -#pragma GCC system_header -void f(va_list) {} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield1.C deleted file mode 100644 index d5d04bcd7..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield1.C +++ /dev/null @@ -1,34 +0,0 @@ -// { dg-do run } -// { dg-options "-ansi -pedantic-errors -funsigned-bitfields" } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2001 <nathan@codesourcery.com> - -typedef int Int; -typedef signed int SInt; -typedef unsigned int UInt; - -struct A -{ - SInt bitS : 1; // signed - UInt bitU : 1; // unsigned - Int bit : 1; // signedness by -f{signed,unsigned}-bitfields -}; - -int main () -{ - A a; - - a.bitS = 1; // { dg-warning "overflow" } - a.bitU = 1; - a.bit = 1; - - if (a.bitS != -1) - return 1; - if (a.bitU != 1) - return 2; - if (a.bit != 1) - return 3; - - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield10.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield10.C deleted file mode 100644 index df40fa3f2..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield10.C +++ /dev/null @@ -1,5 +0,0 @@ -// { dg-options "-w" } - -struct S { - int i : 64; -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield11.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield11.C deleted file mode 100644 index e78ea121d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield11.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do run } -// { dg-options "-w -fabi-version=0" } - -struct S { - char c : 1024; -}; - -S s; - -int main () { - s.c = 1; - if (*(char *)&s != 1) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield12.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield12.C deleted file mode 100644 index 6cfda5d47..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield12.C +++ /dev/null @@ -1,5 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -struct S { // { dg-warning "ABI" } - char c : 1024; // { dg-warning "width" } -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield2.C deleted file mode 100644 index 452861ec2..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield2.C +++ /dev/null @@ -1,34 +0,0 @@ -// { dg-do run } -// { dg-options "-ansi -pedantic-errors -fsigned-bitfields" } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2001 <nathan@codesourcery.com> - -typedef int Int; -typedef signed int SInt; -typedef unsigned int UInt; - -struct A -{ - SInt bitS : 1; // signed - UInt bitU : 1; // unsigned - Int bit : 1; // signedness by -f{signed,unsigned}-bitfields -}; - -int main () -{ - A a; - - a.bitS = 1; // { dg-warning "overflow" } - a.bitU = 1; - a.bit = 1; // { dg-warning "overflow" } - - if (a.bitS != -1) - return 1; - if (a.bitU != 1) - return 2; - if (a.bit != -1) - return 3; - - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield3.C deleted file mode 100644 index 6908ab6e7..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield3.C +++ /dev/null @@ -1,86 +0,0 @@ -// Test for oversized bitfield alignment in structs on IA-32 -// { dg-do run { target { { i?86-*-* x86_64-*-* } && ia32 } } } -// { dg-options "-O2" } -// Cygwin and mingw default to MASK_ALIGN_DOUBLE. Override to ensure -// 4-byte alignment. -// { dg-additional-options "-mno-align-double" { target i?86-*-cygwin* i?86-*-mingw* } } -// As for mingw target the ms-bitfield switch is activated by default, -// make sure for this test that it is disabled. -// { dg-additional-options "-mno-ms-bitfields" { target i?86-*-mingw* } } - -struct A -{ - char a; - int b : 224; // { dg-warning "exceeds its type" "" } - char c; -} a, a4[4]; - -struct B -{ - char d; - A e; - char f; -} b; - -struct C -{ - char g; - long long h : 64; - char i; -} c, c4[4]; - -struct D -{ - char j; - C k; - char l; -} d; - -struct E -{ - char m; - long long n : 160; // { dg-warning "exceeds its type" "" } - char o; -} e, e4[4]; - -struct F -{ - char p; - E q; - char r; -} f; - -int main (void) -{ - if (&a.c - &a.a != 32) - return 1; - if (sizeof (a) != 36) - return 2; - if (sizeof (a4) != 4 * 36) - return 3; - if (sizeof (b) != 2 * 4 + 36) - return 4; - if (__alignof__ (b.e) != 4) - return 5; - if (&c.i - &c.g != 12) - return 6; - if (sizeof (c) != 16) - return 7; - if (sizeof (c4) != 4 * 16) - return 8; - if (sizeof (d) != 2 * 4 + 16) - return 9; - if (__alignof__ (d.k) != 4) - return 10; - if (&e.o - &e.m != 24) - return 11; - if (sizeof (e) != 28) - return 12; - if (sizeof (e4) != 4 * 28) - return 13; - if (sizeof (f) != 2 * 4 + 28) - return 14; - if (__alignof__ (f.q) != 4) - return 15; - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield4.C deleted file mode 100644 index 5434dd973..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield4.C +++ /dev/null @@ -1,41 +0,0 @@ -/* { dg-do run { target { pcc_bitfield_type_matters || default_packed } } } */ - -/* Check bitfields and non-bitfields are aligned & sized similarly. - - Copyright (C) 2002 Free Software Foundation Inc - Contributed by Nathan Sidwell <nathan@codesourcery.com> -*/ - -#include <limits.h> -#include <stdio.h> - -static int fail; - -#define CHECK1(N, T) do { \ - typedef struct Field_##N { char c; T f; } Field_##N; \ - typedef struct BitField_##N { char c; T f : sizeof (T) * CHAR_BIT; } BitField_##N; \ - if (sizeof (Field_##N) != sizeof (BitField_##N)) { \ - fail = 1; printf ("sizeof %s failed\n", #T); \ - } \ - if (__alignof__ (Field_##N) != __alignof__ (BitField_##N)) { \ - fail = 1; printf ("__alignof__ %s failed\n", #T); \ - } \ -} while (0) - -#define CHECK(N, T) do { \ - CHECK1(N, T); \ - CHECK1 (s##N, signed T); \ - CHECK1 (u##N, unsigned T); \ -} while (0) - -int main () -{ - - CHECK (c, char); - CHECK (s, short); - CHECK (i, int); - CHECK (l, long); - CHECK (ll, long long); - - return fail; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield5.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield5.C deleted file mode 100644 index 531314014..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield5.C +++ /dev/null @@ -1,15 +0,0 @@ -// { dg-do compile } -// { dg-options "-Wabi -fabi-version=1" } -// { dg-options "-Wabi -fabi-version=1 -mno-ms-bitfields" { target i?86-*-* x86_64-*-* } } - -struct A { - virtual void f(); - int f1 : 1; -}; - -struct B : public A { - int f2 : 1; // { dg-warning "ABI" } - int : 0; - int f3 : 4; - int f4 : 3; -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield6.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield6.C deleted file mode 100644 index 50f76ab82..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield6.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do run } -// { dg-options "-w -fabi-version=0" } - -#include <limits> - -union U { - int i: 4096; -}; - -int main () { - if (sizeof (U) * std::numeric_limits<unsigned char>::digits != 4096) - return 1; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield7.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield7.C deleted file mode 100644 index b5b656ffa..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield7.C +++ /dev/null @@ -1,7 +0,0 @@ -// { dg-do compile } -// { dg-options "-Wabi -fabi-version=1" } - -union U { // { dg-warning "ABI" } - int i: 4096; // { dg-warning "exceeds" } -}; - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield8.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield8.C deleted file mode 100644 index 58e74be08..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield8.C +++ /dev/null @@ -1,22 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-options "-fabi-version=0" } -// { dg-require-effective-target ilp32 } - - -struct A { - virtual void f() {} - int f1 : 1; -}; - -struct B : public A { - int f2 : 31; - int f3 : 4; - int f4 : 3; -}; - -int main () -{ - if (sizeof (B) != 16) - return 1; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield9.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield9.C deleted file mode 100644 index 0d3a8bf89..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/bitfield9.C +++ /dev/null @@ -1,12 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options -w } - -struct X { - char : 45; -}; - -int main () { - if (__alignof__ (X) != 4) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie1.C deleted file mode 100644 index defc4887b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie1.C +++ /dev/null @@ -1,15 +0,0 @@ -// { dg-options "-fabi-version=0" } - -void *operator new[](__SIZE_TYPE__, void *); - -struct A { - ~A(){} -}; - -int main() -{ - A * a = (A*) new char[20]; - A * b = new(a) A[3]; - if (a != b) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie2.C deleted file mode 100644 index dc180453b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/cookie2.C +++ /dev/null @@ -1,16 +0,0 @@ -// { dg-options "-fabi-version=1" } - -void *operator new[](__SIZE_TYPE__, void *); - -struct A { - ~A(){} -}; - -int main() -{ - A * a = (A*) new char[20]; - A * b = new(a) A[3]; - // In the 3.2 ABI, a cookie was allocated in this case. - if (a == b) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant1.C deleted file mode 100644 index 97737ddb9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant1.C +++ /dev/null @@ -1,26 +0,0 @@ -// { dg-do compile } -// { dg-options "-w" } - -// If a covariant thunk is overriding a virtual primary base, we have to -// use the vcall offset even though we know it will be 0. - -struct c4 {}; - -struct c6 : c4 { virtual c4* f17(); }; - -c4* c6::f17() { return 0; } - -struct c11 : virtual c6 { int i; }; - -struct c12 : c11 { }; - -struct c14 : - virtual c12, - virtual c11 { virtual void f(); c12* f17(); }; - -void c14::f() { } - -// { dg-final { scan-assembler "_ZTcv0_n12_v0_n16_N3c143f17Ev" { target { ilp32 && { ! { ia64-*-hpux* } } } } } } -// { dg-final { scan-assembler-not "_ZTch0_v0_n16_N3c143f17Ev" } } -// { dg-final { scan-assembler "_ZTcv0_n24_v0_n32_N3c143f17Ev" { target { lp64 || { ia64-*-hpux* } } } } } -// { dg-final { scan-assembler-not "_ZTch0_v0_n32_N3c143f17Ev" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant2.C deleted file mode 100644 index 3231cc4c8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant2.C +++ /dev/null @@ -1,32 +0,0 @@ -// { dg-do compile } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 12 Dec 2003 <nathan@codesourcery.com> -// Origin: grigory@stl.sarov.ru - -// PR c++/12881. ICE in thunk generation - -struct c1 {}; - -struct c3 : virtual c1 -{ - virtual c1* f6() {} - int i; -}; - -struct c6 : virtual c3 { }; - -struct c7 : c3 -{ - virtual c3* f6() {} -}; - -struct c24 : virtual c7 -{ - virtual c6* f6(); -}; - -c6* c24::f6() { return 0; } - -struct c31 : c24 {}; - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant3.C deleted file mode 100644 index 178157c58..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant3.C +++ /dev/null @@ -1,85 +0,0 @@ -// { dg-do run } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 12 Dec 2003 <nathan@codesourcery.com> -// Origin: grigory@stl.sarov.ru - -// PR c++/13118. Missing covariant thunk. - -struct c0 {}; -struct c1 : virtual c0 { - virtual c0* f6(); -}; - -struct c5 { - virtual void foo(); -}; - -struct c10 : virtual c1 { - virtual void foo(); -}; - -struct c1a : c1 {}; // disambiguation - -struct c11 : virtual c10, c1a { - int i; - virtual c1* f6 () = 0; -}; - -struct c18 : c5, virtual c1 { - virtual void bar(); -}; - -struct c28 : virtual c0, virtual c11 { - virtual c18* f6(); -}; - -c0 *c1::f6 () {} -void c5::foo () {} -void c10::foo () {} -void c18::bar () {} - -c18 ret; - -c18 *c28::f6 () -{ - return &ret; -} - -bool check_c1 (c1 *ptr) -{ - c0 *r = ptr->f6 (); - return r != &ret; -} -bool check_c10 (c10 *ptr) -{ - c0 *r = ptr->f6 (); - return r != &ret; -} -bool check_c11 (c11 *ptr) -{ - c1 *r = ptr->f6 (); - return r != &ret; -} -bool check_c28 (c28 *ptr) -{ - c18 *r = ptr->f6 (); - return r != &ret; -} - -int main () -{ - c28 obj; - - if (check_c1 (static_cast<c1a *> (&obj))) - return 1; - if (check_c1 (static_cast<c10 *> (&obj))) - return 2; - if (check_c10 (&obj)) - return 3; - if (check_c11 (&obj)) - return 4; - if (check_c28 (&obj)) - return 5; - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant4.C deleted file mode 100644 index 942b1686e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant4.C +++ /dev/null @@ -1,46 +0,0 @@ -// { dg-do run } - -// Copyright (C) 2005 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 11 Feb 2005 <nathan@codesourcery.com> - -// Origin: bredelin@ucla.edu -// Bug 19891: Incorrect covariant vtables - -struct Model { - bool full_tree; - virtual Model* clone() const =0; - virtual const char *name() const =0; - virtual ~Model() {} -}; - -struct R: virtual public Model { - virtual R* clone() const =0; -}; -struct A: virtual public Model { - virtual A* clone() const=0; -}; -struct RA: public R, public A { - virtual RA* clone() const=0; -}; - -static const char *string = "EQU"; - -struct EQU: public RA { - virtual EQU* clone() const {return new EQU(*this);} - const char *name() const {return string;} -}; - -int main() { - Model* M1 = new EQU(); - Model* M2 = M1->clone(); - Model* M3 = M2->clone(); - - if (M1->name () != string) - return 1; - if (M2->name () != string) - return 2; - if (M3->name () != string) - return 3; - - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant5.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant5.C deleted file mode 100644 index 03e55583d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant5.C +++ /dev/null @@ -1,52 +0,0 @@ -// Copyright (C) 2005 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 4 Apr 2005 <nathan@codesourcery.com> - -// { dg-do run } - -// PR 20746: Covariant return pointer could be null. - -// Origin: yanliu@ca.ibm.com -// nathan@codesourcery.com - -struct A { - virtual void One (); -}; -struct B { - virtual B *Two (); - virtual B &Three (); -}; - -struct C : A, B -{ - virtual C *Two (); - virtual C &Three (); -}; -void A::One () {} -B *B::Two() {return this;} -B &B::Three() {return *this;} -C *C::Two () {return 0;} -C &C::Three () {return *(C *)0;} - -B *Foo (B *b) -{ - return b->Two (); -} - -B &Bar (B *b) -{ - return b->Three (); -} - -int main () -{ - C c; - - /* We should not adjust a null pointer. */ - if (Foo (&c)) - return 1; - /* But we should adjust a (bogus) null reference. */ - if (!&Bar (&c)) - return 2; - - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant6.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant6.C deleted file mode 100644 index 143b4ad36..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/covariant6.C +++ /dev/null @@ -1,34 +0,0 @@ -struct A -{ - virtual A* f(); -}; - -struct B: virtual A -{ - virtual A* f(); -}; - -struct C: B -{ - virtual C* f(); -}; - -C* C::f() { return 0; } - -// When we emit C::f, we should emit both thunks: one for B and one for A. -// { dg-final { scan-assembler "_ZTch0_v0_n16_N1C1fEv" { target { ilp32 && { ! { ia64-*-hpux* } } } } } } -// { dg-final { scan-assembler "_ZTch0_v0_n32_N1C1fEv" { target { lp64 || { ia64-*-hpux* } } } } } -// { dg-final { scan-assembler "_ZTcv0_n12_v0_n16_N1C1fEv" { target { ilp32 && { ! { ia64-*-hpux* } } } } } } -// { dg-final { scan-assembler "_ZTcv0_n24_v0_n32_N1C1fEv" { target { lp64 || { ia64-*-hpux* } } } } } - -struct D: B -{ - virtual void dummy (); - virtual D* f(); -}; - -void D::dummy() { } - -// When we emit the D vtable, it should refer to the thunk for B. -// { dg-final { scan-assembler "_ZTch0_v0_n16_N1D1fEv" { target { ilp32 && { ! { ia64-*-hpux* } } } } } } -// { dg-final { scan-assembler "_ZTch0_v0_n32_N1D1fEv" { target { lp64 || { ia64-*-hpux* } } } } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dcast1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dcast1.C deleted file mode 100644 index 99f678ff3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dcast1.C +++ /dev/null @@ -1,29 +0,0 @@ -// { dg-do compile } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 28 Jan 2003 <nathan@codesourcery.com> - -// PR 9433. segfault at runtime. - -struct A { virtual void f() {} }; -struct B {int b;}; -struct C : A, B { virtual void f() {} int c;}; -struct D : C {int d;}; -struct E : C {int e;}; -struct F : protected D, E {int f;}; -struct H : virtual F {int h;}; -struct I : H {int i;}; -struct J : H {int j;}; -struct K : I, J { virtual void f() {} int k; }; -struct M : K {int m;}; -struct N : M {int n;}; -struct O : M {int o;}; -struct P : N, O { virtual void f() {} int p;}; - -int main() -{ - P obj; - A* a1 = (D *) (&obj); - H* hp = dynamic_cast<H*>(a1); - return hp != 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor1.C deleted file mode 100644 index f9425e013..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor1.C +++ /dev/null @@ -1,23 +0,0 @@ -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0" } - -struct A { - virtual void a (); -}; - -struct B { - virtual ~B (); -}; - -struct C : public A, public B { - virtual void c (); -}; - -struct D : virtual public C { - virtual void d (); -}; - -void D::d () {} - -// { dg-final { scan-assembler _ZTv0_n20_N1DD1Ev } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor2.C deleted file mode 100644 index 6b89cc8ea..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/dtor2.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do compile } -// { dg-options "-Wabi -fabi-version=1" } - -struct A { - virtual void a (); -}; - -struct B { - virtual ~B (); -}; - -struct C : public A, public B { // { dg-warning "virtual" } - virtual void c (); -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty10.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty10.C deleted file mode 100644 index ae992944d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty10.C +++ /dev/null @@ -1,28 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0 -w" } - -struct E {}; -struct E2 : public E {}; - -struct A { - int i; -}; - -struct B { - int j; -}; - -struct C : - public E, - public A, - public E2, - virtual public B { -}; - -C c; - -int main () { - if (((char*)(B*)&c - (char*)&c) != 8) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty11.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty11.C deleted file mode 100644 index b35363f5b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty11.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-do run } -// { dg-options "-w -fabi-version=0" } - -struct E {}; -struct E2 : public E {}; -struct E3 : public E, public E2 {}; -struct E4 : public E, public E2, public E3 { }; -struct E5 : public E, public E2, public E3, public E4 {}; - -struct S : public virtual E5 { - E e; -}; - -S s; - -int main () { - if ((char*)(E4*)&s - (char*)&s == 0) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty4.C deleted file mode 100644 index d20a55cf7..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty4.C +++ /dev/null @@ -1,86 +0,0 @@ -// { dg-do run } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 31 Jul 2001 <nathan@codesourcery.com> - -// Bug 3820. We were bit copying empty bases including the -// padding. Which clobbers whatever they overlay. - -struct Empty {}; - -struct Inter : Empty {}; - -long now = 0; - -struct NonPod -{ - long m; - - NonPod () {m = 0x12345678;} - NonPod (long m_) {m = m_;} - NonPod &operator= (NonPod const &src) {now = m; m = src.m; return *this;} - NonPod (NonPod const &src) {m = src.m;} -}; - -struct A : Inter -{ - A (long c) {m = c;} - - NonPod m; -}; - -struct B -{ - Inter empty; - NonPod m; - - B (long c) {m = c;} -}; - -struct C : NonPod, Inter -{ - C (long c) : NonPod (c), Inter () {} -}; - -int main () -{ - A a (0x12131415); - - long was = a.m.m; - - a = 0x22232425; - - if (was != now) - return 1; // we copied the empty base which clobbered a.m.m's - // original value. - - A b (0x32333435); - *(Inter *)&a = *(Inter *)&b; - - if (a.m.m != 0x22232425) - return 2; // we copied padding, which clobbered a.m.m - - A b2 (0x32333435); - (Inter &)b2 = Inter (); - if (b2.m.m != 0x32333435) - return 2; // we copied padding, which clobbered b2.m.m - - B c (0x12131415); - was = c.m.m; - c = 0x22232425; - if (was != now) - return 3; - - B d (0x32333435); - c.empty = d.empty; - - if (c.m.m != 0x22232425) - return 4; - - C e (0x32333435); - - if (e.m != 0x32333435) - return 2; // we copied padding - - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty5.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty5.C deleted file mode 100644 index c3717727e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty5.C +++ /dev/null @@ -1,17 +0,0 @@ -// { dg-options "-fabi-version=0" } - -struct A {}; - -struct B { - A a; - virtual void f () {} -}; - -struct C : public B, public A {}; - -C c; - -int main () { - if ((void*) (A*) &c != &c) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty6.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty6.C deleted file mode 100644 index 1b14a6d03..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty6.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -struct A {}; - -struct B { - A a; // { dg-warning "empty" "" { xfail mmix-*-* } } - virtual void f () {} -} __attribute__((aligned(2 * sizeof (void *)))); -/* The preceding attribute is necessary on targets with - BIGGEST_ALIGNMENT <= POINTER_SIZE to trigger the warning, as - otherwise the offset of 'a' (i.e. POINTER_SIZE) is split into a - non-zero DECL_FIELD_OFFSET and a zero DECL_FIELD_BIT_OFFSET, - and then there is no discrepancy between DECL_FIELD_OFFSET and - byte_position to warn about. */ diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty7.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty7.C deleted file mode 100644 index 0a665a845..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty7.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0" } - -struct S1 {}; -struct S2 { virtual void f () {} S1 s1[4]; }; -struct S3 : virtual public S2 {}; -struct S4 : virtual public S2 { int i; }; -struct S5 : public S3, virtual public S4 {}; -struct S6 { S5 s5; }; -struct S7 { S1 s1[5]; }; -struct S8 : public S1, public S6, virtual public S7 { }; - -S8 s8; - -int main () { - if ((char *)(S7 *)&s8 - (char *)&s8 != 24) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty8.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty8.C deleted file mode 100644 index a5287b15f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty8.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do run } -// { dg-options "-fabi-version=0" } - -struct E1 {}; -struct E2 : public E1 {}; -struct S1 { int i; }; -struct S2 : public S1, E2 {}; - -S2 s2; - -int main () { - if ((char *)(E2*) &s2 != (char *)&s2) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty9.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty9.C deleted file mode 100644 index 06e616adb..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/empty9.C +++ /dev/null @@ -1,17 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-w -fabi-version=0" } - -struct E1 {}; -struct E2 : public E1 { - virtual void f (); -}; -struct E3 : virtual public E1 { -}; -struct S : public E2, virtual public E3 { -}; - -int main () { - if (sizeof (S) != 12) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/enum1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/enum1.C deleted file mode 100644 index 32e52fe0f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/enum1.C +++ /dev/null @@ -1,16 +0,0 @@ -// { dg-do run } - -#include <cstdlib> - -enum foo -{ - foo1 = 0, - foo2 = 0xffffffffffffffffULL, - foo3 = 0xf0fffffffffffffeULL -}; - -int main () -{ - if (sizeof (enum foo) != sizeof (unsigned long long)) - std::abort (); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/forced.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/forced.C deleted file mode 100644 index 7a9c35964..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/forced.C +++ /dev/null @@ -1,25 +0,0 @@ -// This test only applies to glibc (NPTL) targets. -// { dg-do run { target *-*-linux* } } -// { dg-options "-pthread" } - -#include <pthread.h> -#include <cxxabi.h> -extern "C" int printf (const char *, ...); - -int main() -{ - try - { - pthread_exit (0); - } - catch (abi::__forced_unwind &) - { - printf ("caught forced unwind\n"); - throw; - } - catch (...) - { - printf ("caught ...\n"); - return 1; - } -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard1.C deleted file mode 100644 index 76b43d30f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard1.C +++ /dev/null @@ -1,10 +0,0 @@ -// PR c++/41611 -// { dg-final { scan-assembler-not "_ZGVZN1A1fEvE1i" } } - -struct A { - static int f() - { - static int &i = *new int(); - return i; - } -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard2.C deleted file mode 100644 index 988fd385b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard2.C +++ /dev/null @@ -1,16 +0,0 @@ -// PR c++/41611 -// Test that the guard gets its own COMDAT group. -// { dg-final { scan-assembler "_ZGVZN1A1fEvE1i,comdat" { target *-*-linux* } } } - -struct A { - static int f() - { - static int &i = *new int(); - return i; - } -}; - -int main() -{ - return A::f(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard3.C deleted file mode 100644 index fd9d00e27..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/guard3.C +++ /dev/null @@ -1,14 +0,0 @@ -// PR c++/45603 - -extern "C" int __cxa_guard_acquire(); - -struct A -{ - ~A(); -}; - -A* f() -{ - static A a; - return &a; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/inline1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/inline1.C deleted file mode 100644 index 97082aa73..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/inline1.C +++ /dev/null @@ -1,6 +0,0 @@ -struct S { - S() {} - virtual void g() {} -}; - -// { dg-final { scan-assembler-not "_ZTV1S" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key1.C deleted file mode 100644 index 6c0380926..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key1.C +++ /dev/null @@ -1,26 +0,0 @@ -// On ARM EABI platforms, key methods may never be inline. -// { dg-do compile { target arm*-*-eabi* arm*-*-symbianelf* } } -// { dg-final { scan-assembler-not _ZTV1S } } -// { dg-final { scan-assembler-not _ZTV1T } } -// { dg-final { scan-assembler _ZTV1U } } - -struct S { - virtual void f(); -}; - -inline void S::f() {} - -struct T { - virtual void g(); - virtual void h(); -}; - -inline void T::g() {} - -struct U { - virtual void i(); - virtual void j(); -}; - -inline void U::i() {} -void U::j () {} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key2.C deleted file mode 100644 index 0d1347aaa..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/key2.C +++ /dev/null @@ -1,16 +0,0 @@ -// On Darwin, key methods that are inline result in comdat style things. */ -// PR darwin/25908 - -// { dg-do compile { target *-*-darwin* } } -// { dg-final { scan-assembler ".globl __ZTV1f\\n .weak_definition __ZTV1f(\\n .section __DATA,__const_coal,coalesced)?\\n .align" } } -// { dg-final { scan-assembler ".globl __ZTS1f\\n .weak_definition __ZTS1f\\n .section __TEXT,__const_coal,coalesced" } } -// { dg-final { scan-assembler ".globl __ZTI1f\\n .weak_definition __ZTI1f(\\n .section __DATA,__const_coal,coalesced)?\\n .align" } } - -class f -{ - virtual void g(); - virtual void h(); -} c; -inline void f::g() {} -int sub(void) -{} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout1.C deleted file mode 100644 index 645ed6acf..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout1.C +++ /dev/null @@ -1,31 +0,0 @@ -// Red Hat bugzilla 64535 -// Bug: We are allocationg stuff into the tail padding of POD class "A". -// { dg-do run } - -struct A -{ - int x; - char y; -}; - -struct B : public A { - virtual void f () {} - char z; -}; - -A a = { 21, 42 }; -B b; - -int -main (void) -{ - b.x = 12; - b.y = 24; - b.z = 36; - - A *ap = &b; - - *ap = a; - - return (b.z != 36); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout2.C deleted file mode 100644 index fb4e1e5d9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout2.C +++ /dev/null @@ -1,33 +0,0 @@ -// Red Hat bugzilla 65210 -// { dg-do run } - -struct A { - int a; -}; - -struct B : public virtual A {}; - -struct C { - long double c; -}; - -struct D : public virtual C { - int d; -}; - -struct E : public B, public D { - int e; -}; - -E e; - -/* The layout of E should begin with the B-in-E vtable pointer, followed by - the D-in-E vtable pointer. The bug was that we used to pad out the D - fields for long double alignment. */ - -int main () -{ - D* dp = &e; - unsigned long d_offset = ((char*)dp) - ((char*) &e); - return (d_offset != sizeof(void *)); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout3.C deleted file mode 100644 index a30a85219..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout3.C +++ /dev/null @@ -1,27 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0 -w" } - -struct S { - virtual void f() {} -}; - -struct T : virtual public S { }; - -struct U : public S, virtual public T { - char c[100]; -}; - -struct V : public U, virtual public S {}; - -struct W : public V { - int i; -}; - -int main () { - W w; - - if ((char*) &w.i - (char *) &w != 104) - return 1; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout4.C deleted file mode 100644 index da3c2f5d8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/layout4.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=1" } - -struct C4 -{ - int b:30; - C4(){}; -}; - -struct C1: virtual C4 -{ - int i; -}; - -int main() { - if (sizeof (C1) != 12) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1-a.cc b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1-a.cc deleted file mode 100644 index 638479e74..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1-a.cc +++ /dev/null @@ -1,14 +0,0 @@ -struct B { - virtual void b() {} -}; - -static B* f() { - struct D : public B { - }; - - return new D; -} - -B* g() { - return f(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1.C deleted file mode 100644 index 518193c89..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local1.C +++ /dev/null @@ -1,22 +0,0 @@ -// { dg-do run } -// { dg-additional-sources "local1-a.cc" } - -#include <typeinfo> - -struct B { - virtual void b() {} -}; - -static B* f() { - struct D : public B { - }; - - return new D; -} - -extern B* g(); - -int main () { - if (typeid (*f()) == typeid (*g())) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local2.C deleted file mode 100644 index f56701610..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/local2.C +++ /dev/null @@ -1,17 +0,0 @@ -// PR c++/42010 -// { dg-final { scan-assembler "ZZN1A1fEvE1s" } } - -struct A { - static int f() - { - static struct { - int i; - } s; - return s.i; - } -}; - -int main() -{ - return A::f(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro0.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro0.C deleted file mode 100644 index 6c391e689..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro0.C +++ /dev/null @@ -1,5 +0,0 @@ -// { dg-options "-fabi-version=0" } - -#if __GXX_ABI_VERSION != 999999 -#error "Incorrect value of __GXX_ABI_VERSION" -#endif diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro1.C deleted file mode 100644 index 871208da3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro1.C +++ /dev/null @@ -1,5 +0,0 @@ -// { dg-options "-fabi-version=1" } - -#if __GXX_ABI_VERSION != 102 -#error "Incorrect value of __GXX_ABI_VERSION" -#endif diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro2.C deleted file mode 100644 index 9f0af9cff..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/macro2.C +++ /dev/null @@ -1,5 +0,0 @@ -// { dg-options "-fabi-version=2" } - -#if __GXX_ABI_VERSION != 1002 -#error "Incorrect value of __GXX_ABI_VERSION" -#endif diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon-aarch64.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon-aarch64.C deleted file mode 100644 index 09540e841..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon-aarch64.C +++ /dev/null @@ -1,55 +0,0 @@ -// Test that AArch64 AdvSIMD (NEON) vector types have their names mangled -// correctly. - -// { dg-do compile { target { aarch64*-*-* } } } - -#include <arm_neon.h> - -void f0 (int8x8_t a) {} -void f1 (int16x4_t a) {} -void f2 (int32x2_t a) {} -void f3 (uint8x8_t a) {} -void f4 (uint16x4_t a) {} -void f5 (uint32x2_t a) {} -void f6 (float32x2_t a) {} -void f7 (poly8x8_t a) {} -void f8 (poly16x4_t a) {} - -void f9 (int8x16_t a) {} -void f10 (int16x8_t a) {} -void f11 (int32x4_t a) {} -void f12 (int64x2_t a) {} -void f13 (uint8x16_t a) {} -void f14 (uint16x8_t a) {} -void f15 (uint32x4_t a) {} -void f16 (uint64x2_t a) {} -void f17 (float32x4_t a) {} -void f18 (float64x2_t a) {} -void f19 (poly8x16_t a) {} -void f20 (poly16x8_t a) {} - -void f21 (int8x16_t, int8x16_t) {} - - -// { dg-final { scan-assembler "_Z2f010__Int8x8_t:" } } -// { dg-final { scan-assembler "_Z2f111__Int16x4_t:" } } -// { dg-final { scan-assembler "_Z2f211__Int32x2_t:" } } -// { dg-final { scan-assembler "_Z2f311__Uint8x8_t:" } } -// { dg-final { scan-assembler "_Z2f412__Uint16x4_t:" } } -// { dg-final { scan-assembler "_Z2f512__Uint32x2_t:" } } -// { dg-final { scan-assembler "_Z2f613__Float32x2_t:" } } -// { dg-final { scan-assembler "_Z2f711__Poly8x8_t:" } } -// { dg-final { scan-assembler "_Z2f812__Poly16x4_t:" } } -// { dg-final { scan-assembler "_Z2f911__Int8x16_t:" } } -// { dg-final { scan-assembler "_Z3f1011__Int16x8_t:" } } -// { dg-final { scan-assembler "_Z3f1111__Int32x4_t:" } } -// { dg-final { scan-assembler "_Z3f1211__Int64x2_t:" } } -// { dg-final { scan-assembler "_Z3f1312__Uint8x16_t:" } } -// { dg-final { scan-assembler "_Z3f1412__Uint16x8_t:" } } -// { dg-final { scan-assembler "_Z3f1512__Uint32x4_t:" } } -// { dg-final { scan-assembler "_Z3f1612__Uint64x2_t:" } } -// { dg-final { scan-assembler "_Z3f1713__Float32x4_t:" } } -// { dg-final { scan-assembler "_Z3f1813__Float64x2_t:" } } -// { dg-final { scan-assembler "_Z3f1912__Poly8x16_t:" } } -// { dg-final { scan-assembler "_Z3f2012__Poly16x8_t:" } } -// { dg-final { scan-assembler "_Z3f2111__Int8x16_tS_:" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon.C deleted file mode 100644 index af1fe49f1..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle-neon.C +++ /dev/null @@ -1,49 +0,0 @@ -// Test that ARM NEON vector types have their names mangled correctly. - -// { dg-do compile } -// { dg-require-effective-target arm_neon_ok } -// { dg-add-options arm_neon } - -#include <arm_neon.h> - -void f0 (int8x8_t a) {} -void f1 (int16x4_t a) {} -void f2 (int32x2_t a) {} -void f3 (uint8x8_t a) {} -void f4 (uint16x4_t a) {} -void f5 (uint32x2_t a) {} -void f6 (float32x2_t a) {} -void f7 (poly8x8_t a) {} -void f8 (poly16x4_t a) {} - -void f9 (int8x16_t a) {} -void f10 (int16x8_t a) {} -void f11 (int32x4_t a) {} -void f12 (uint8x16_t a) {} -void f13 (uint16x8_t a) {} -void f14 (uint32x4_t a) {} -void f15 (float32x4_t a) {} -void f16 (poly8x16_t a) {} -void f17 (poly16x8_t a) {} - -void f18 (int8x16_t, int8x16_t) {} - -// { dg-final { scan-assembler "_Z2f015__simd64_int8_t:" } } -// { dg-final { scan-assembler "_Z2f116__simd64_int16_t:" } } -// { dg-final { scan-assembler "_Z2f216__simd64_int32_t:" } } -// { dg-final { scan-assembler "_Z2f316__simd64_uint8_t:" } } -// { dg-final { scan-assembler "_Z2f417__simd64_uint16_t:" } } -// { dg-final { scan-assembler "_Z2f517__simd64_uint32_t:" } } -// { dg-final { scan-assembler "_Z2f618__simd64_float32_t:" } } -// { dg-final { scan-assembler "_Z2f716__simd64_poly8_t:" } } -// { dg-final { scan-assembler "_Z2f817__simd64_poly16_t:" } } -// { dg-final { scan-assembler "_Z2f916__simd128_int8_t:" } } -// { dg-final { scan-assembler "_Z3f1017__simd128_int16_t:" } } -// { dg-final { scan-assembler "_Z3f1117__simd128_int32_t:" } } -// { dg-final { scan-assembler "_Z3f1217__simd128_uint8_t:" } } -// { dg-final { scan-assembler "_Z3f1318__simd128_uint16_t:" } } -// { dg-final { scan-assembler "_Z3f1418__simd128_uint32_t:" } } -// { dg-final { scan-assembler "_Z3f1519__simd128_float32_t:" } } -// { dg-final { scan-assembler "_Z3f1617__simd128_poly8_t:" } } -// { dg-final { scan-assembler "_Z3f1718__simd128_poly16_t:" } } -// { dg-final { scan-assembler "_Z3f1816__simd128_int8_tS_:" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle1.C deleted file mode 100644 index ab377d13b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle1.C +++ /dev/null @@ -1,28 +0,0 @@ -// Test for mangling of simple testcase involving construction vtables. - -// { dg-do compile } -// { dg-options "-fno-inline" } - -struct A { - virtual void f () { } -}; - -struct B: public virtual A { }; -struct C: public B { }; - -C c; - -// { dg-final { scan-assembler "\n_?_ZN1A1fEv\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZN1AC2Ev\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZN1BC2Ev\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZN1CC1Ev\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTC1C0_1B\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTI1A\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTI1B\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTI1C\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTS1A\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTS1B\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTS1C\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTT1C\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTV1A\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_ZTV1C\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle10.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle10.C deleted file mode 100644 index d5782ba6d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle10.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-options "-fabi-version=0" } - -template <template <typename> class Q> -void f (typename Q<int>::X) {} - -template <typename Q> -struct S { - typedef int X; -}; - -template void f<S> (int); - -// { dg-final { scan-assembler _Z1fI1SEvNT_IiE1XE } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle11.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle11.C deleted file mode 100644 index 722d43c85..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle11.C +++ /dev/null @@ -1,10 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -template <typename Q> -void f (typename Q::X) {} // { dg-warning "mangle" } - -struct S { - typedef int X; -}; - -template void f<S> (int); // { dg-message "required" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle12.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle12.C deleted file mode 100644 index 92f49c22f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle12.C +++ /dev/null @@ -1,11 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -template <template <typename> class Q> -void f (typename Q<int>::X) {} // { dg-warning "mangle" } - -template <typename Q> -struct S { - typedef int X; -}; - -template void f<S> (int); // { dg-message "required" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle13.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle13.C deleted file mode 100644 index 716c4c36f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle13.C +++ /dev/null @@ -1,28 +0,0 @@ -// { dg-options "-fabi-version=0" } - -struct A { - template <typename T> int f (); - int operator+(); - operator int (); - template <typename T> - int operator-(); -}; - -typedef int (A::*P)(); - -template <P> struct S {}; - -template <typename T> void g (S<&T::template f<int> >) {} -template <typename T> void g (S<&T::operator+ >) {} -template <typename T> void g (S<&T::operator int>) {} -template <typename T> void g (S<&T::template operator- <double> >) {} - -template void g<A> (S<&A::f<int> >); -template void g<A> (S<&A::operator+>); -template void g<A> (S<&A::operator int>); -template void g<A> (S<&A::operator-<double> >); - -// { dg-final { scan-assembler _Z1gI1AEv1SIXadsrT_1fIiEEE } } -// { dg-final { scan-assembler _Z1gI1AEv1SIXadsrT_plEE } } -// { dg-final { scan-assembler _Z1gI1AEv1SIXadsrT_cviEE } } -// { dg-final { scan-assembler _Z1gI1AEv1SIXadsrT_miIdEEE } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle14.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle14.C deleted file mode 100644 index 2b38255ac..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle14.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-do compile } -// { dg-options "-Wabi -fabi-version=1" } -// { dg-final { scan-assembler "_Z1g1SIXadsr1ANS0_1fIiEEivEE" } } - -struct A { - template <typename T> int f (); -}; - -typedef int (A::*P)(); - -template <P> struct S {}; - -void g (S<&A::f<int> >) {} // { dg-warning "mangle" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle15.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle15.C deleted file mode 100644 index 3c112e263..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle15.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=0" } - -struct A { - template <typename T> int f (); -}; - -typedef int (A::*P)(); - -template <P> struct S {}; - -void g (S<&A::f<int> >) {} - -// { dg-final { scan-assembler _Z1g1SIXadL_ZN1A1fIiEEivEEE } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle16.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle16.C deleted file mode 100644 index 1f3039f86..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle16.C +++ /dev/null @@ -1,18 +0,0 @@ -// { dg-options "-fabi-version=0" } - -enum E { e = 3 }; - -template <int I> struct S {}; - -template <int I> void f (S<e + 1>) {} -template void f<7>(S<e + 1>); - -template <int I> void g (S<e>) {} -template void g<7>(S<e>); - -template <int I> void h (S<I + 1>) {} -template void h<7>(S<7 + 1>); - -// { dg-final { scan-assembler _Z1fILi7EEv1SILi4EE } } -// { dg-final { scan-assembler _Z1gILi7EEv1SILi3EE } } -// { dg-final { scan-assembler _Z1hILi7EEv1SIXplT_Li1EEE } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle17.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle17.C deleted file mode 100644 index f98e2717d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle17.C +++ /dev/null @@ -1,11 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -enum E { e = 3 }; - -template <int I> struct S {}; - -template <int I> void f (S<I + e + int (3.7)>) {} // { dg-warning "mangle" } -template void f<7>(S<7 + e + int (3.7)>); // { dg-message "required" } - -template <int I> void g (S<I + e + int (3.7)>) {} // { dg-warning "mangle" } -template void g<7>(S<7 + e + int (3.7)>); // { dg-message "required" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-1.C deleted file mode 100644 index a1be5e48c..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-1.C +++ /dev/null @@ -1,23 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=2" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 30 Nov 2003 <nathan@codesourcery.com> - -// PR 13241 -// mangled template arguments that are external objects incorrectly - -extern "C" void Foo (); -namespace NMS -{ - extern "C" int V; -} - -template <void (*)()> struct S {}; -template <int *> struct T {}; - -void f (S<Foo>){} -// { dg-final { scan-assembler "\n_?_Z1f1SIXadL_Z3FooEEE\[: \t\n\]" } } - -void g (T<&NMS::V>){} -// { dg-final { scan-assembler "\n_?_Z1g1TIXadL_Z1VEEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-2.C deleted file mode 100644 index a231d495f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle18-2.C +++ /dev/null @@ -1,23 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=1 -Wabi" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 30 Nov 2003 <nathan@codesourcery.com> - -// PR 13241 -// mangled template arguments that are external objects incorrectly - -extern "C" void Foo (); -namespace NMS -{ - extern "C" int V; -} - -template <void (*)()> struct S {}; -template <int *> struct T {}; - -void f (S<Foo>){} // { dg-warning "mangled name" } -// { dg-final { scan-assembler "\n_?_Z1f1SIXadL3FooEEE\[: \t\n\]" } } - -void g (T<&NMS::V>){} // { dg-warning "mangled name" } -// { dg-final { scan-assembler "\n_?_Z1g1TIXadL_ZN3NMS1VEEEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-1.C deleted file mode 100644 index 1463d03f3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-1.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=2 -Wno-abi" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2003 <nathan@codesourcery.com> - -// PR 13242 -// mangled template arguments that are external objects incorrectly - -extern int N; -template <int &> struct S {}; -void n (S<N>) {} -// { dg-final { scan-assembler "\n_?_Z1n1SILZ1NEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-2.C deleted file mode 100644 index f0855e69d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle19-2.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=1 -Wabi" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2003 <nathan@codesourcery.com> - -// PR 13242 -// mangled template arguments that are external objects incorrectly - -extern int N; -template <int &> struct S {}; -void n (S<N>) {} // { dg-warning "mangled name" } -// { dg-final { scan-assembler "\n_?_Z1n1SIXadL_Z1NEEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle2.C deleted file mode 100644 index e8b5f409d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle2.C +++ /dev/null @@ -1,19 +0,0 @@ -// Test that we handle mangling of statics in inlines properly. -// { dg-options -fno-weak } -// { dg-do run } - -inline int f () -{ - static int nested; - nested = 24; - { - static int nested; - nested = 42; - } - return (nested != 24); -} - -int main() -{ - return f (); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-1.C deleted file mode 100644 index 1985fe3c9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-1.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=2" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2003 <nathan@codesourcery.com> - -// PR 9043 -// mangled array types in templates - -template <int I> void f(int (*)[2]) {} -template <int I> void g(int (*)[I+2]) {} - -static const int I=1; -static const int J=2; - -template void f<1>(int (*)[2]); -// { dg-final { scan-assembler "\n_?_Z1fILi1EEvPA2_i\[: \t\n\]" } } -template void g<1>(int (*)[3]); -// { dg-final { scan-assembler "\n_?_Z1gILi1EEvPAplT_Li2E_i\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-2.C deleted file mode 100644 index 5ba6bac03..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle20-2.C +++ /dev/null @@ -1,16 +0,0 @@ -// { dg-do compile } -// { dg-options "-fabi-version=1 -Wabi" } - -// Copyright (C) 2003 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 15 Dec 2003 <nathan@codesourcery.com> - -// PR 9043 -// mangled array types in templates - -template <int I> void f(int (*)[2]) {} // { dg-warning "mangled name" } -template <int I> void g(int (*)[I+2]) {} - -template void f<1>(int (*)[2]); // { dg-message "required" } -// { dg-final { scan-assembler "\n_?_Z1fILi1EEvPALi2E_i\[: \t\n\]" } } -template void g<1>(int (*)[3]); -// { dg-final { scan-assembler "\n_?_Z1gILi1EEvPAplT_Li2E_i\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle21.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle21.C deleted file mode 100644 index f457d600c..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle21.C +++ /dev/null @@ -1,13 +0,0 @@ -// PR c++/14324 -// { dg-do assemble } - -extern "C" { - -void fun1(void) -{ - do { static int xyz __attribute__((unused)) = 1; } while (0); - do { static int xyz __attribute__((unused)) = 2; } while (0); - do { static int xyz __attribute__((unused)) = 3; } while (0); -} - -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle22.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle22.C deleted file mode 100644 index 93ddd1e87..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle22.C +++ /dev/null @@ -1,9 +0,0 @@ -// PR c++/16240 -// { dg-options "-fabi-version=3" } - -void foo(char); -template<void (&)(char)> struct CB {}; - -void g(CB<foo> i) {} - -// { dg-final { scan-assembler "\n_?_Z1g2CBIL_Z3foocEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle23.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle23.C deleted file mode 100644 index f22347a04..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle23.C +++ /dev/null @@ -1,9 +0,0 @@ -// PR c++/16240 -// { dg-options "-fabi-version=2 -Wno-abi" } - -void foo(char); -template<void (&)(char)> struct CB {}; - -void g(CB<foo> i) {} - -// { dg-final { scan-assembler "\n_?_Z1g2CBILZ3foocEE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle24.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle24.C deleted file mode 100644 index 1f5c5c1c3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle24.C +++ /dev/null @@ -1,12 +0,0 @@ -// Test mangling of __float80. -// The C++ ABI document says __float80 is mangled as "e". It -// also says that "long double" is mangled as "e", so these conflict on -// ia64-hpux where "long double" is "e" and __float80 is "u9__float80". -// Origin: Joseph Myers <joseph@codesourcery.com> -// { dg-do compile { target i?86-*-* x86_64-*-* ia64-*-* } } -// { dg-options "" } -// { dg-final { scan-assembler "_Z1fe" { target i?86-*-* x86_64-*-* } } } -// { dg-final { scan-assembler "_Z1fe" { target { ia64-*-* && { ! "ia64-*-hpux*" } } } } } -// { dg-final { scan-assembler "_Z1fu9__float80" { target ia64-*-hpux* } } } - -int f(__float80 x) { return 0; } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle25.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle25.C deleted file mode 100644 index 74397f778..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle25.C +++ /dev/null @@ -1,13 +0,0 @@ -// Test mangling of __float128. -// The C++ ABI document says __float128 is mangled as "g". It -// also says that "long double" is mangled as "e", so these conflict on -// ia64-hpux where "long double" is "e" and __float128 is synonymous with -// "long double". -// Origin: Joseph Myers <joseph@codesourcery.com> -// { dg-do compile { target ia64-*-* i?86-*-* x86_64-*-* } } -// { dg-options "" } -// { dg-final { scan-assembler "_Z1fg" { target i?86-*-* x86_64-*-* } } } -// { dg-final { scan-assembler "_Z1fg" { target { ia64-*-* && { ! "ia64-*-hpux*" } } } } } -// { dg-final { scan-assembler "_Z1fe" { target ia64-*-hpux* } } } - -int f(__float128 x) { return 0; } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle26.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle26.C deleted file mode 100644 index 5d1609596..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle26.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test of std mangling - -// { dg-do compile } -// { dg-options "-fno-inline" } - -namespace std { - struct A { - A() { } - }; -} - -std::A a; - -// { dg-final { scan-assembler "\n_?_ZNSt1AC\[12\]Ev\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle27.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle27.C deleted file mode 100644 index 2d15abbf9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle27.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test of std::basic_iostream<char, std::char_traits<char> > mangling - -// { dg-do compile } -// { dg-options "-fno-inline" } - -namespace std { - template<typename> struct char_traits; - - template<typename, typename> struct basic_iostream { basic_iostream(){} }; -} - -std::basic_iostream<char,std::char_traits<char> > s1; - -// { dg-final { scan-assembler "\n_?_ZNSdC\[12\]Ev\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle28.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle28.C deleted file mode 100644 index bea8ce019..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle28.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test of std::basic_istream<char, std::char_traits<char> > mangling - -// { dg-do compile } -// { dg-options "-fno-inline" } - -namespace std { - template<typename> struct char_traits; - - template<typename, typename> struct basic_istream { basic_istream(){} }; -} - -std::basic_istream<char,std::char_traits<char> > s1; - -// { dg-final { scan-assembler "\n_?_ZNSiC\[12\]Ev\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle29.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle29.C deleted file mode 100644 index aaff2b4eb..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle29.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test of std::basic_ostream<char, std::char_traits<char> > mangling - -// { dg-do compile } -// { dg-options "-fno-inline" } - -namespace std { - template<typename> struct char_traits; - - template<typename, typename> struct basic_ostream { basic_ostream(){} }; -} - -std::basic_ostream<char,std::char_traits<char> > s1; - -// { dg-final { scan-assembler "\n_?_ZNSoC\[12\]Ev\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3-2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3-2.C deleted file mode 100644 index ac85fb045..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3-2.C +++ /dev/null @@ -1,20 +0,0 @@ -// Test mangling of type casts -// { dg-options "-fabi-version=0" } -// { dg-do compile } - -template<int i> class A {}; -template<bool b> class B {}; - -template<int i> void f(A<i> &, B<bool(i)> &) {} -template<int i> void g(A<i> &, B<static_cast<bool>(i)> &) {} - -int main() -{ - A<1> a; - B<true> b; - f(a, b); - g(a, b); -} - -// { dg-final { scan-assembler "\n_?_Z1fILi1EEvR1AIXT_EER1BIXcvbT_EE\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z1gILi1EEvR1AIXT_EER1BIXscbT_EE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3.C deleted file mode 100644 index 5f44f7677..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle3.C +++ /dev/null @@ -1,20 +0,0 @@ -// Test mangling of type casts -// { dg-options "-fabi-version=2" } -// { dg-do compile } - -template<int i> class A {}; -template<bool b> class B {}; - -template<int i> void f(A<i> &, B<bool(i)> &) {} -template<int i> void g(A<i> &, B<static_cast<bool>(i)> &) {} - -int main() -{ - A<1> a; - B<true> b; - f(a, b); - g(a, b); -} - -// { dg-final { scan-assembler "\n_?_Z1fILi1EEvR1AIXT_EER1BIXcvbT_EE\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z1gILi1EEvR1AIXT_EER1BIXcvbT_EE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle30.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle30.C deleted file mode 100644 index f0b83dbe9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle30.C +++ /dev/null @@ -1,22 +0,0 @@ -// Test for mangling of template args in a typename type. - -struct A -{ - template <class T> - struct B - { - typedef T myT; - }; -}; - -struct C {}; - -template <class T> -void f (T t, typename T::template B<C>::myT u, typename T::template B<int>::myT v); - -int main() -{ - f (A(), C(), 1); -} - -// { dg-final { scan-assembler "_Z1fI1AEvT_NS1_1BI1CE3myTENS2_IiE3myTE" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle31.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle31.C deleted file mode 100644 index 4be2e0b03..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle31.C +++ /dev/null @@ -1,35 +0,0 @@ -// PR c++/39095 -// { dg-do compile } - -struct B -{ - int b; -}; - -struct A -{ - B *operator->(); - A (); - B b; -}; - -A::A () -{ -} - -B * -A::operator->() -{ - return &b; -} - -A a; - -int -foo () -{ - return a->b; -} - -// { dg-final { scan-assembler "_ZN1AptEv" } } -// { dg-final { scan-assembler-not "_ZN1AdtEv" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle32.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle32.C deleted file mode 100644 index 244d07490..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle32.C +++ /dev/null @@ -1,44 +0,0 @@ -// Testcase for mangling of unnamed types. - -// namespace-scope unnamed types have no linkage, so we only test that they -// are distinct. - -// { dg-options -std=c++0x } - -typedef struct { } *A; -typedef struct { } *B; - -void f(A) { } -void f(B) { } - -struct C -{ - typedef struct { }* D; - typedef enum { }* E; -}; - -// { dg-final { scan-assembler "_Z2g1PN1CUt_E" } } -void g1(C::D) { } -// { dg-final { scan-assembler "_Z2g2PN1CUt0_E" } } -void g2(C::E) { } - -template <class T> -void h1(T t) { } - -template <class T> -void h2(T t) { } - -inline void j() -{ - typedef enum { }* F; -// { dg-final { scan-assembler "_Z2h1IPZ1jvEUt_EvT_" } } - h1(F()); - typedef struct { }* G; -// { dg-final { scan-assembler "_Z2h2IPZ1jvEUt0_EvT_" } } - h2(G()); -} - -int main() -{ - j(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle33.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle33.C deleted file mode 100644 index f0a4e5012..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle33.C +++ /dev/null @@ -1,19 +0,0 @@ -// Testcase for mangling very long names. - -#define N \ -abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklm - -namespace N { - int i; -} - -#undef N -#define N \ -abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijk - -namespace N { - int j; -} - -// { dg-final { scan-assembler "_ZN4043abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklm1iE" } } -// { dg-final { scan-assembler "_ZN4041abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijk1jE" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle34.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle34.C deleted file mode 100644 index 08c3bc0a1..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle34.C +++ /dev/null @@ -1,41 +0,0 @@ -// Contributed by Dodji Seketeli <dodji@redhat.com> -// Origin PR c++/40808 -// { dg-do compile } -// This tests the mangling of empty template argument list in a template -// id. -// { dg-final { scan-assembler "_ZNK5DummyclI3GenEENT_3SigIE10ResultTypeERKS2_" } } - - -struct Void {}; - -template <class R> struct FunType { - typedef R ResultType; -}; - -struct WrongNumberOfSigArgs {}; - -template <typename R> struct CFunType { - template <class Dummy1=Void, class Dummy2=Void> struct Sig : public -FunType<WrongNumberOfSigArgs> {}; - template <class Dummy> struct Sig<Void,Dummy> : public FunType<R> {}; -}; - -struct Dummy { - template <typename F> typename F::template Sig<>::ResultType operator()(F -const& f) const { - return typename F::template Sig<>::ResultType(0); - } -}; - -struct Gen: public CFunType<int> { - int operator()() const {return 0;} - Gen() {} -}; - -int myfunction() { - return Dummy()(Gen()); -} - -int main() { - myfunction(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle35.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle35.C deleted file mode 100644 index 78d993344..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle35.C +++ /dev/null @@ -1,13 +0,0 @@ -// PR c++/38600 -// { dg-final { scan-assembler "_Z3barIiE1AIX3fooIT_EEEv" } } - -template<void (*)()> struct A {}; - -template<typename> void foo(); - -template<typename T> A<foo<T> > bar(); - -void baz() -{ - bar<int>(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle36.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle36.C deleted file mode 100644 index aaace6570..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle36.C +++ /dev/null @@ -1,9 +0,0 @@ -// PR c++/41959 -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-options "-mavx -fabi-version=4" } -// { dg-final { scan-assembler "_Z1fDv4_f" } } -// { dg-final { scan-assembler "_Z1fDv8_f" } } - -#include <x86intrin.h> -void f(__m128) { } -void f(__m256) { } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle37.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle37.C deleted file mode 100644 index 7270861ac..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle37.C +++ /dev/null @@ -1,35 +0,0 @@ -// Testcase for mangling of expressions involving operator names. -// { dg-options -std=c++0x } -// { dg-final { scan-assembler "_Z1fI1AEDTclonplfp_fp_EET_" } } -// { dg-final { scan-assembler "_Z1gI1AEDTclonplIT_Efp_fp_EES1_" } } -// { dg-final { scan-assembler "_Z1hI1AEDTcldtfp_miEET_" } } -// { dg-final { scan-assembler "_Z1iI1AEDTcldtfp_srT_miEES1_" } } -// { dg-final { scan-assembler "_Z1jI1AEDTcldtfp_cvPT_EES1_" } } - -struct A { - void operator-(); - template <class T> - operator T(); -}; -template <class T> -T operator+(T,T); - -template <class T> -auto f (T t) -> decltype(operator+(t,t)); -template <class T> -auto g (T t) -> decltype(operator+<T>(t,t)); -template <class T> -auto h (T t) -> decltype(t.operator-()); -template <class T> -auto i (T t) -> decltype(t.T::operator-()); -template <class T> -auto j (T t) -> decltype(t.operator T*()); - -int main() -{ - f(A()); - g(A()); - h(A()); - i(A()); - j(A()); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle39.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle39.C deleted file mode 100644 index 289635610..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle39.C +++ /dev/null @@ -1,28 +0,0 @@ -// PR c++/42338 -// { dg-options "-std=c++0x -fabi-version=5" } -// { dg-final { scan-assembler "_Z1fIPiEDTcmppfp_Li0EET_" } } -// { dg-final { scan-assembler "_Z1gIiEvRK1AIT_EDTixfL0p_Li0EE" } } - -template<typename T> -auto f(T t) -> decltype(++t, 0) -{ - ++t; - return 0; -} - -template <class T> -struct A -{ - T operator[](int) const { return 0; } -}; - -template< typename T > -void g(const A<T> &a, decltype(a[0]) t) { } - -int main() -{ - f((int*)0); - - A<int> a; - g(a,1); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle40.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle40.C deleted file mode 100644 index 2b8300bff..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle40.C +++ /dev/null @@ -1,28 +0,0 @@ -// PR c++/12909 -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-require-weak "" } -// { dg-require-alias "" } -// { dg-options "-mavx -Wabi -fabi-version=2" } -// { dg-final { scan-assembler "(weak|glob)\[^\n\]*_Z1fIDv4_fEvT_" } } -// { dg-final { scan-assembler "(weak|glob)\[^\n\]*_Z1fIU8__vectorfEvT_" } } -// { dg-final { scan-assembler "(weak|glob)\[^\n\]*_ZN1AIDv4_fE1tE" } } -// { dg-final { scan-assembler "(weak|glob)\[^\n\]*_ZN1AIU8__vectorfE1tE" } } - -#include <x86intrin.h> - -template <class T> -struct A -{ - static T t; -}; - -template <class T> -T A<T>::t; // { dg-warning "mangled name" } - -template <class T> -void f (T t) { } // { dg-warning "mangled name" } - -int main() -{ - f (A<__m128>::t); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle41.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle41.C deleted file mode 100644 index 4c0d0038e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle41.C +++ /dev/null @@ -1,8 +0,0 @@ -// PR c++/41959 -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-options "-mavx -fabi-version=2" } - -#include <x86intrin.h> -void f(__m128) { } // { dg-message "previous declaration" } -void f(__m256) { } // { dg-error "conflicts" } -// { dg-message "mangling" "" { target *-*-* } 7 } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle42.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle42.C deleted file mode 100644 index b7e3bd561..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle42.C +++ /dev/null @@ -1,15 +0,0 @@ -// Origin: PR c++/43375 -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-options "-msse2 -std=gnu++0x" } -// { dg-require-effective-target sse2 } - -typedef float __v4sf __attribute__ ((__vector_size__ (16))); -typedef int __v4si __attribute__ ((__vector_size__ (16))); -__v4sf my_asin(__v4sf x) -{ - static const __v4si g_Mask{0x7fffffff, - 0x00000000, - 0x7fffffff, - 0x7fffffff }; - return __builtin_ia32_andnps ((__v4sf) g_Mask, x); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle43.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle43.C deleted file mode 100644 index 4dfa425f6..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle43.C +++ /dev/null @@ -1,43 +0,0 @@ -// { dg-do compile { target int128 } } -// { dg-options "" } - -struct S { - S(void) { m_i128 = 0; m_u128 = 0; } - ~S(void) { } - __int128 get1 (void) { return m_i128; } - unsigned __int128 get2 (void) { return m_u128; } - void set1 (__int128 i) { m_i128 = i; } - void set2 (unsigned int i) { m_u128 = 1; } - __int128 m_i128; - unsigned __int128 m_u128; -}; - -struct S glb; - -__int128 fo1 (void) { return glb.get1 (); } -unsigned __int128 fo2 (void) { return glb.get2 (); } -__int128 fo3 (__int128 i) { __int128 v = fo1 (); glb.set1 (i); return v; } -unsigned __int128 fo4 (unsigned __int128 i) -{ - unsigned __int128 v = fo2 (); glb.set2 (i); - return v; -} - -__int128 fo5 (__int128 i) -{ - return fo3 (i); -} - -__int128 fo5 (unsigned __int128 i) -{ - return (__int128) fo4 (i); -} - - -// { dg-final { scan-assembler "\n_?_Z3fo1v\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z3fo2v\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z3fo3n\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z3fo4o\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z3fo5n\[: \t\n\]" } } -// { dg-final { scan-assembler "\n_?_Z3fo5o\[: \t\n\]" } } - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle44.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle44.C deleted file mode 100644 index 845414842..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle44.C +++ /dev/null @@ -1,19 +0,0 @@ -// PR c++/45008 - -template <typename T> -struct A -{ - void fn1 () { - struct Nested { - static void fn2 () { } - }; - Nested::fn2(); - } -}; - -void fn3 () { - A<double> a; - a.fn1(); -} - -// { dg-final { scan-assembler-not "_ZZN1AIT_E3fn1EvEN6Nested3fn2Ev" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle45.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle45.C deleted file mode 100644 index 3ce9abcb0..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle45.C +++ /dev/null @@ -1,25 +0,0 @@ -// Testcase for mangling of parameters used other than in a trailing return type -// { dg-options "-std=c++0x -fabi-version=5" } - -template<class T> void f(T p, decltype(p)) { } // L = 1 -template<class T> void g(T p, decltype(p) (*)()) { } // L = 1 -// G++ incorrectly rejects these currently. -// template<class T> void h(T p, auto (*)()->decltype(p)); // L = 1 -// template<class T> void i(T p, auto (*)(T q)->decltype(q)); // L = 0 -// template<class T> void j(T p, auto (*)(decltype(p))->T); // L = 2 -template<class T> void k(T p, int (*(*)(T* p))[sizeof(p)]) {} // L = 1 - -int garg(); -int (*karg (int*))[sizeof(int)]; -int main() -{ - // { dg-final { scan-assembler "_Z1fIiEvT_DtfL0p_E" } } - f (1,0); - // { dg-final { scan-assembler "_Z1gIiEvT_PFDtfL0p_EvE" } } - g (1,garg); - // h (1,0); - // i (1,0); - // j (1,0); - // { dg-final { scan-assembler "_Z1kIiEvT_PFPAszfL0p__iPS0_E" } } - k (1,karg); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle46.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle46.C deleted file mode 100644 index fddc88d0a..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle46.C +++ /dev/null @@ -1,15 +0,0 @@ -// PR c++/48008 -// { dg-options -fabi-version=5 } -// Test that we retain function-cv-quals in template argument mangling. - -template <class T> -struct A -{ }; - -typedef void cfn(int) const; -typedef void fn(int); - -// { dg-final { scan-assembler "_Z1f1AIFviEE" } } -void f(A<fn>) { } -// { dg-final { scan-assembler "_Z1f1AIKFviEE" } } -void f(A<cfn>) { } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle47.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle47.C deleted file mode 100644 index 2c1b636dc..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle47.C +++ /dev/null @@ -1,11 +0,0 @@ -// PR c++/47132 -// { dg-options -std=c++0x } -// { dg-final { scan-assembler "_Z1fIiEDToRfp_Li1EET_" } } - -template <typename T> -auto f (T t) -> decltype(t |= 1); - -int main() -{ - f(1); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle48.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle48.C deleted file mode 100644 index 6c0e99c8d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle48.C +++ /dev/null @@ -1,29 +0,0 @@ -// Testcase for 'this' mangling -// { dg-options -std=c++0x } - -struct B -{ - template <class U> U f(); -}; - -struct A -{ - B b; - // { dg-final { scan-assembler "_ZN1A1fIiEEDTcldtdtdefpT1b1fIT_EEEv" } } - template <class U> auto f() -> decltype (b.f<U>()); - // { dg-final { scan-assembler "_ZN1A1gIiEEDTcldtptfpT1b1fIT_EEEv" } } - template <class U> auto g() -> decltype (this->b.f<U>()); - // { dg-final { scan-assembler "_ZN1A1hIiEEDTcldtdtdefpT1bsr1B1fIT_EEEv" } } - template <class U> auto h() -> decltype (b.B::f<U>()); - // { dg-final { scan-assembler "_ZN1A1iIiEEDTcldtptfpT1bsr1B1fIT_EEEv" } } - template <class U> auto i() -> decltype (this->b.B::f<U>()); -}; - -int main() -{ - A a; - a.f<int>(); - a.g<int>(); - a.h<int>(); - a.i<int>(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle49.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle49.C deleted file mode 100644 index a258dc2d4..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle49.C +++ /dev/null @@ -1,22 +0,0 @@ -// PR c++/49932 -// { dg-options "-std=c++0x -fabi-version=0" } - -template < typename T > -auto -f1( T x ) // ICE on here - -> typename decltype( x )::type {} - -template < typename T > -typename decltype( T() )::type -f2( T x ) {} // ICE on here - -struct S { typedef void type; }; - -void g() -{ - f1( S() ); - f2( S() ); -} - -// { dg-final { scan-assembler "_Z2f1I1SENDtfp_E4typeET_" } } -// { dg-final { scan-assembler "_Z2f2I1SENDTcvT__EE4typeES1_" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle5.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle5.C deleted file mode 100644 index 99a08730f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle5.C +++ /dev/null @@ -1,6 +0,0 @@ -// Test mangling of pointers to cv-qualified member functions - -struct A; -void f (void (A::*)() const) {} - -// { dg-final { scan-assembler "\n_?_Z1fM1AKFvvE\[: \t\n\]" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle50.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle50.C deleted file mode 100644 index df7afb97e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle50.C +++ /dev/null @@ -1,25 +0,0 @@ -// DR 342, PR c++/48582 -// { dg-options -std=c++0x } - -struct A; -template < void * = nullptr > void f() { } -template < void (A::*)() = nullptr > void g() { } -template < int A::* = nullptr > void h() { } - -int main() -{ - // { dg-final { scan-assembler "_Z1fILPv0EEvv" } } - f(); - f<nullptr>(); - - // { dg-final { scan-assembler "_Z1gILM1AFvvE0EEvv" } } - g(); - g<nullptr>(); - - // { dg-final { scan-assembler "_Z1fILPv0EEvv" } } - h(); - h<nullptr>(); - - constexpr void * ptr = nullptr; - f<ptr>(); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle51.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle51.C deleted file mode 100644 index 4992f1a32..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle51.C +++ /dev/null @@ -1,27 +0,0 @@ -// { dg-options "-std=c++0x -fabi-version=0" } - -void* operator new (__SIZE_TYPE__, void *p) { return p; } -int i; - -template <unsigned int> struct helper {}; -// { dg-final { scan-assembler "_Z6check1IiEvP6helperIXsznw_T_EEE" } } -template <class T> void check1( helper<sizeof(new T)> * ) { } -// { dg-final { scan-assembler "_Z6check2IiEvP6helperIXszgsnw_T_piEEE" } } -template <class T> void check2( helper<sizeof(::new T())> * ) { } -// { dg-final { scan-assembler "_Z6check3IiEvP6helperIXsznwadL_Z1iE_T_piLi1EEEE" } } -template <class T> void check3( helper<sizeof(new (&i) T(1))> * ) { } -// { dg-final { scan-assembler "_Z7check3aIiEvP6helperIXsznw_T_ilLi1EEEE" } } -template <class T> void check3a( helper<sizeof(new T{1})> * ) { } -// { dg-final { scan-assembler "_Z6check4IiEvP6helperIXszna_A1_T_EEE" } } -template <class T> void check4( helper<sizeof(new T[1])> * ) { } -// { dg-final { scan-assembler "_Z6check5IiEvP6helperIXszna_A1_T_piEEE" } } -template <class T> void check5( helper<sizeof(new T[1]())> * ) { } -int main() -{ - check1<int>(0); - check2<int>(0); - check3<int>(0); - check3a<int>(0); - check4<int>(0); - check5<int>(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle52.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle52.C deleted file mode 100644 index 2c463415f..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle52.C +++ /dev/null @@ -1,21 +0,0 @@ -// { dg-options "-fabi-version=0" } - -template <unsigned int> struct helper {}; -// { dg-final { scan-assembler "_Z6check1IiEvP6helperIXszscT_Li1EEE" } } -template <class T> void check1( helper<sizeof(static_cast<T>(1))> * ) { } -// { dg-final { scan-assembler "_Z6check2IiXadL_Z1iEEEvP6helperIXszccPT_T0_EE" } } -template <class T, T* p> void check2( helper<sizeof(const_cast<T*>(p))> * ) { } -// { dg-final { scan-assembler "_Z6check3IiEvP6helperIXszrcPT_Li0EEE" } } -template <class T> void check3( helper<sizeof(reinterpret_cast<T*>(0))> * ) { } -// { dg-final { scan-assembler "_Z6check4I1AXadL_Z1aEEEvP6helperIXszdcPT_T0_EE" } } -template <class T, T* p> void check4( helper<sizeof(dynamic_cast<T*>(p))> * ) { } - -struct A{} a; -int i; -int main() -{ - check1<int>(0); - check2<int,&i>(0); - check3<int>(0); - check4<A,&a>(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle53.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle53.C deleted file mode 100644 index b279182d8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle53.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-options "-std=c++0x" } - -bool b; -// { dg-final { scan-assembler "_Z1fIiEDTquL_Z1bEfp_twLi42EET_" } } -template <class T> auto f (T t) -> decltype(b?t:throw 42) { return 0; } -// { dg-final { scan-assembler "_Z2f2IiEDTquL_Z1bEfp_trET_" } } -template <class T> auto f2 (T t) -> decltype(b?t:throw) { return 0; } - -int main() -{ - f(0); - f2(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle54.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle54.C deleted file mode 100644 index ea98df17d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle54.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-options "-std=c++0x -fabi-version=0" } - -int i; -// { dg-final { scan-assembler "_Z2f1IiEDTppfp_ET_" } } -template <class T> auto f1 (T t) -> decltype(t++) { return i; } -// { dg-final { scan-assembler "_Z2f2IiEDTpp_fp_ET_" } } -template <class T> auto f2 (T t) -> decltype(++t) { return i; } -// { dg-final { scan-assembler "_Z2f3IiEDTmmfp_ET_" } } -template <class T> auto f3 (T t) -> decltype(t--) { return i; } -// { dg-final { scan-assembler "_Z2f4IiEDTmm_fp_ET_" } } -template <class T> auto f4 (T t) -> decltype(--t) { return i; } - -int main() -{ - f1(0); - f2(0); - f3(0); - f4(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle55.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle55.C deleted file mode 100644 index 72caadcc2..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle55.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-options "-std=c++0x" } - -struct A { int i; }; -// { dg-final { scan-assembler "_Z2f1Ii1AEDTdsfp_fp0_ET0_MS2_T_" } } -template <class T, class U> auto f1 (U u, T U::* p) -> decltype(u.*p) { return u.*p; } -// { dg-final { scan-assembler "_Z2f2Ii1AEDTpmfp_fp0_EPT0_MS2_T_" } } -template <class T, class U> auto f2 (U* u, T U::* p) -> decltype(u->*p) { return u->*p; } - -int main() -{ - A a = {}; - f1(a, &A::i); - f2(&a, &A::i); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle56.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle56.C deleted file mode 100644 index 0fd270169..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle56.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-options "-std=c++0x" } - -template <class T> T g(T t1, T t2) { return t2; } -// { dg-final { scan-assembler "_Z2f1IiEDTcl1gfp_ilEEET_" } } -template <class T> auto f1 (T t) -> decltype(g(t,{})) { return g(t,{}); } -// { dg-final { scan-assembler "_Z2f2IiEDTcl1gfp_tlT_EEES0_" } } -template <class T> auto f2 (T t) -> decltype(g(t,T{})) { return g(t,T{}); } - -int main() -{ - f1(0); - f2(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle57.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle57.C deleted file mode 100644 index 3d9d81e55..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle57.C +++ /dev/null @@ -1,16 +0,0 @@ -// { dg-options "-std=c++0x -fabi-version=0" } - -template<typename T> int cmp1(T a, T b); -int cmp2(char a, char b); -template<typename T, int (*cmp)(T, T)> struct A { }; -// { dg-final { scan-assembler "_Z1fIcEvR1AIT_X4cmp1EE" } } -template <typename T> void f (A<T,cmp1> &); -// { dg-final { scan-assembler "_Z1fIcEvR1AIT_L_Z4cmp2ccEE" } } -template <typename T> void f (A<T,cmp2> &); -void g() -{ - A<char,cmp1> a; - f(a); - A<char,cmp2> a2; - f(a2); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle58.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle58.C deleted file mode 100644 index 54b16f256..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle58.C +++ /dev/null @@ -1,25 +0,0 @@ -// { dg-options "-std=c++0x -fabi-version=0" } - -template<typename T, int (*cmp)(T, T)> struct A { }; -struct B { - template<typename T> static int cmp1(T a, T b); - static int cmp2(char a, char b); - // { dg-final { scan-assembler "_ZN1B1fIcEEvR1AIT_X4cmp1EE" } } - template <typename T> static void f (A<T,cmp1> &); - // { dg-final { scan-assembler "_ZN1B1gIcEEvR1AIT_XsrS_4cmp1EE" } } - template <typename T> static void g (A<T,B::cmp1> &); - // { dg-final { scan-assembler "_ZN1B1fIcEEvR1AIT_L_ZNS_4cmp2EccEE" } } - template <typename T> static void f (A<T,cmp2> &); - // { dg-final { scan-assembler "_ZN1B1gIcEEvR1AIT_L_ZNS_4cmp2EccEE" } } - template <typename T> static void g (A<T,B::cmp2> &); -}; - -void g() -{ - A<char,B::cmp1> a; - B::f(a); - B::g(a); - A<char,B::cmp2> a2; - B::f(a2); - B::g(a2); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle59.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle59.C deleted file mode 100644 index 3c88ec874..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle59.C +++ /dev/null @@ -1,19 +0,0 @@ -// { dg-options "-std=c++0x -fabi-version=0" } - -// { dg-final { scan-assembler "_Z1fIiEDTcmdlfp_psfp_EPT_" } } -template <class T> auto f (T* p) -> decltype(delete p, +p) { return p; } -// { dg-final { scan-assembler "_Z1gIiEDTcmgsdlfp_psfp_EPT_" } } -template <class T> auto g (T* p) -> decltype(::delete p, +p) { return p; } -// { dg-final { scan-assembler "_Z1hIiEDTcmdafp_psfp_EPT_" } } -template <class T> auto h (T* p) -> decltype(delete[] p, +p) { return p; } -// { dg-final { scan-assembler "_Z1iIiEDTcmgsdafp_psfp_EPT_" } } -template <class T> auto i (T* p) -> decltype(::delete[] p, +p) { return p; } - -int main() -{ - int x; - f(&x); - g(&x); - h(&x); - i(&x); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle6.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle6.C deleted file mode 100644 index 280fe2499..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle6.C +++ /dev/null @@ -1,23 +0,0 @@ -/* Check that __int128 types are mangled. */ -/* { dg-do compile { target mips*-*-* } } */ - -#ifdef __mips64 -typedef int int128 __attribute__ ((mode(TI))); -typedef unsigned int uint128 __attribute__ ((mode(TI))); - -struct S -{ - int128 i; - int128 func1 (int128) const { return i; } - uint128 func2 (uint128) const { return i; } -}; - -int128 (S::*ptr1) (int128) const = &S::func1; -uint128 (S::*ptr2) (uint128) const = &S::func2; -#else -const char *str1 = "_ZNK1S5func1En"; -const char *str2 = "_ZNK1S5func2Eo"; -#endif - -/* { dg-final { scan-assembler _ZNK1S5func1En } } */ -/* { dg-final { scan-assembler _ZNK1S5func2Eo } } */ diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle60.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle60.C deleted file mode 100644 index f7e893a55..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle60.C +++ /dev/null @@ -1,20 +0,0 @@ -// PR c++/51854 -// { dg-options "" } - -template <unsigned N> struct A; - -template <typename U, typename V> -char foo(U, V); - -// { dg-final { scan-assembler "_Z3barIiEvP1AIXszcl3foocvT__ELCi0_42EEEE" } } -template <typename U> -void bar(A<sizeof(foo(U(), 42i))> *); - -// { dg-final { scan-assembler "_Z3bazIiEvP1AIXszcl3foocvT__ELCf00000000_00000000EEEE" } } -template <typename U> -void baz(A<sizeof(foo(U(), 0.0fj))> *); - -int main() { - bar<int>(0); - baz<int>(0); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle61.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle61.C deleted file mode 100644 index 2ae336e42..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle61.C +++ /dev/null @@ -1,28 +0,0 @@ -// PR c++/56237 -// { dg-do compile } - -void *p[4]; - -void -foo () -{ - static union { } u; - p[0] = &u; - { - static union { } u; - p[1] = &u; - { - static union { } u; - p[2] = &u; - } - } - { - static union { } u; - p[3] = &u; - } -} - -// { dg-final { scan-assembler "_ZZ3foovE1u\[^_\]" } } -// { dg-final { scan-assembler "_ZZ3foovE1u_0" } } -// { dg-final { scan-assembler "_ZZ3foovE1u_1" } } -// { dg-final { scan-assembler "_ZZ3foovE1u_2" } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle7.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle7.C deleted file mode 100644 index af178d3e5..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle7.C +++ /dev/null @@ -1,6 +0,0 @@ -/* { dg-do compile } */ - -typedef void *const t1[2]; -float const f1(t1 (&)[79], ...) {} - -/* { dg-final { scan-assembler _Z2f1RA79_A2_KPvz } } */ diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle8.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle8.C deleted file mode 100644 index 6a073588a..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle8.C +++ /dev/null @@ -1,16 +0,0 @@ -// Red Hat bugzilla 65035 -// Bug: We were encoding the name of the instantiation as 'operator int' -// rather than 'operator T'. -// { dg-do compile } - -struct C { - template <class T> - operator T (); -}; - -template <class T> -C::operator T () { return 0; } - -template C::operator int (); - -// { dg-final { scan-assembler _ZN1CcvT_IiEEv } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle9.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle9.C deleted file mode 100644 index f3ededfb4..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/mangle9.C +++ /dev/null @@ -1,12 +0,0 @@ -// { dg-options "-fabi-version=0" } - -template <typename Q> -void f (typename Q::X) {} - -struct S { - typedef int X; -}; - -template void f<S> (int); - -// { dg-final { scan-assembler _Z1fI1SEvNT_1XE } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn1.C deleted file mode 100644 index 0532cf2f8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn1.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test that attribute noreturn is not part of the mangled name. -// { dg-options -fabi-version=0 } - -void baz (const char *fmt, ...); - -// { dg-final { scan-assembler "_Z3barPFvPKczE" } } -void bar (void (*baz) (const char *fmt, ...) - __attribute__ ((noreturn, format (printf, 1, 2)))); - -void -foo () -{ - bar (&baz); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn2.C deleted file mode 100644 index 72accafe6..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/noreturn2.C +++ /dev/null @@ -1,14 +0,0 @@ -// Test for buggy mangling of attribute noreturn in abi<=4 -// { dg-options -fabi-version=4 } - -void baz (const char *fmt, ...); - -// { dg-final { scan-assembler "_Z3barPVFvPKczE" } } -void bar (void (*baz) (const char *fmt, ...) - __attribute__ ((noreturn, format (printf, 1, 2)))); - -void -foo () -{ - bar (&baz); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/offsetof.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/offsetof.C deleted file mode 100644 index d6a53e6f8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/offsetof.C +++ /dev/null @@ -1,22 +0,0 @@ -// Test that we can refer to the address of a base member of a null pointer -// to get its offset. The standard says that offsetof shall not be used on -// non-POD classes, but there seems to be no such restriction on the common -// implementation thereof. - -// Yes, this is bad, naughty, evil code. But it seems to be well-formed. -// So we'll just warn. - -// { dg-do run } - -struct A { int i; }; - -struct B: public A { - virtual void f (); -}; - -struct C: public B { }; - -int main () -{ - return ((__SIZE_TYPE__) &((C*)0)->i) != sizeof(void*); // { dg-warning "offsetof|invalid" "" } -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/packed1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/packed1.C deleted file mode 100644 index 834537532..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/packed1.C +++ /dev/null @@ -1,24 +0,0 @@ -// PR c++/41788 -// { dg-do run } -// { dg-options "-Wpacked -Wno-attributes" } - -extern "C" void abort (); - -struct INNER { - virtual int foo() const { return 1; } -} __attribute__ ((packed)); - -struct OUTER { - char c; - INNER inner; -} __attribute__ ((packed)); - -int main() -{ - OUTER outer; - int s = sizeof(outer); - int o = (char *)&outer.inner - (char *)&outer; - if (s != sizeof (char) + sizeof (void*) - || o != sizeof (char)) - abort (); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param1.C deleted file mode 100644 index c438a1940..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param1.C +++ /dev/null @@ -1,28 +0,0 @@ -// { dg-do run } -// - -// Failed on powerpc64-linux for structure sizes > 64 and with size not a -// multiple of 8 after padding. -struct object -{ - int i1; - char s1[60]; - int i2; - char s2[64]; -}; - -extern int subr (struct object obj); - -int main () -{ - struct object obj; - - obj.i1 = 1234; - obj.i2 = 5678; - return subr (obj); -} - -int subr (struct object obj) -{ - return obj.i1 != 1234 || obj.i2 != 5678; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param2.C deleted file mode 100644 index d28387ab3..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/param2.C +++ /dev/null @@ -1,19 +0,0 @@ -// PR target/20795 -// Test passing aligned empty aggregate -// { dg-do compile } -// { dg-options "-Wno-psabi" { target { { i?86-*-* x86_64-*-* } && ilp32 } } } - -struct S { union {} a; } __attribute__((aligned)); - -S -foo (S arg) -{ - return arg; -} - -void -bar (void) -{ - S arg; - foo (arg); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1.h b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1.h deleted file mode 100644 index ece67daae..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1.h +++ /dev/null @@ -1,11 +0,0 @@ -inline int -f (int x) -{ - static union - { - int i; - }; - int j = i; - i = x; - return j; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1a.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1a.C deleted file mode 100644 index eb646696d..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1a.C +++ /dev/null @@ -1,12 +0,0 @@ -// PR c++/39188 -// { dg-do run } -// { dg-options "-O2" } -// { dg-additional-sources "pr39188-1b.C" } - -#include "pr39188-1.h" - -int -x (int i) -{ - return f (i); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1b.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1b.C deleted file mode 100644 index 71c992637..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-1b.C +++ /dev/null @@ -1,15 +0,0 @@ -#include "pr39188-1.h" - -extern "C" void abort (); - -extern int x (int); - -int -main (void) -{ - if (x (1) != 0) - abort (); - if (f (1) != 1) - abort (); - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2.h b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2.h deleted file mode 100644 index 6ff5f49db..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2.h +++ /dev/null @@ -1,12 +0,0 @@ -template<typename T> -T -f (T x) -{ - static union - { - T i; - }; - T j = i; - i = x; - return j; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2a.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2a.C deleted file mode 100644 index 071b585f4..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2a.C +++ /dev/null @@ -1,12 +0,0 @@ -// PR c++/39188 -// { dg-do run } -// { dg-options "-O2" } -// { dg-additional-sources "pr39188-2b.C" } - -#include "pr39188-2.h" - -int -x (int i) -{ - return f<int> (i); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2b.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2b.C deleted file mode 100644 index f91367ba2..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-2b.C +++ /dev/null @@ -1,15 +0,0 @@ -#include "pr39188-2.h" - -extern "C" void abort (); - -extern int x (int); - -int -main (void) -{ - if (x (1) != 0) - abort (); - if (f<int> (1) != 1) - abort (); - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3.h b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3.h deleted file mode 100644 index e0c9f619c..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3.h +++ /dev/null @@ -1,11 +0,0 @@ -static int -f (int x) -{ - static union - { - int i; - }; - int j = i; - i = x; - return j; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3a.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3a.C deleted file mode 100644 index 5596d1241..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3a.C +++ /dev/null @@ -1,12 +0,0 @@ -// PR c++/39188 -// { dg-do run } -// { dg-options "-O2" } -// { dg-additional-sources "pr39188-3b.C" } - -#include "pr39188-3.h" - -int -x (int i) -{ - return f (i); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3b.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3b.C deleted file mode 100644 index 84db157a7..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pr39188-3b.C +++ /dev/null @@ -1,15 +0,0 @@ -#include "pr39188-3.h" - -extern "C" void abort (); - -extern int x (int); - -int -main (void) -{ - if (x (1) != 0) - abort (); - if (f (1) != 0) - abort (); - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pragma-pack1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pragma-pack1.C deleted file mode 100644 index 9b76071c9..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/pragma-pack1.C +++ /dev/null @@ -1,37 +0,0 @@ -// PR c++/7046 - -extern "C" int printf (const char *, ...); - -#pragma pack(4) - -template <typename X > -struct T -{ - char x1; /* Usually 3 padding bytes are added after x1 member. */ - int x2; -}; - -template <class T> -int f() -{ - struct A { char i1; int i2; }; - return sizeof (A); -} - -#pragma pack(1) -template struct T<int>; /* T<int> is instantiated here */ -template int f<int>(); - -#pragma pack(4) -template struct T<float>; /* T<float> is required here */ -template int f<double>(); - -int main() -{ - printf("sizeof T<int> = %d\n", sizeof(T<int>)); - printf("sizeof T<float> = %d\n", sizeof(T<float>)); - printf("f<int>() = %d\n", f<int>()); - printf("f<float>() = %d\n", f<float>()); - return (sizeof(T<int>) != sizeof(T<float>) - || f<int>() != f<float>()); -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/regparm1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/regparm1.C deleted file mode 100644 index 42a54a0e0..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/regparm1.C +++ /dev/null @@ -1,51 +0,0 @@ -// PR c++/29911 (9381) -// { dg-options -std=c++0x } -// { dg-do run { target i?86-*-* x86_64-*-* } } - -extern "C" int printf(const char *, ...); - -void *save_this; -int *save_addr1, *save_addr2; - -int fail; - -struct Base -{ - __attribute((regparm(3))) void - set(int *addr1, int *addr2) - { - if (this != save_this) - { - ++fail; - printf("error! this == %p, should be %p\n", this, save_this); - } - if (addr1 != save_addr1) - { - ++fail; - printf("error! addr1 == %p, should be %p\n", addr1, save_addr1); - } - if (addr2 != save_addr2) - { - ++fail; - printf("error! addr2 == %p, should be %p\n", addr2, save_addr1); - } - } -}; - -int main() -{ - void (__attribute((regparm(3))) Base::* pfm)(int *, int *) = &Base::set; - __typeof (&Base::set) pfm2 = &Base::set; - decltype (&Base::set) pfm3 = &Base::set; - auto pfm4 = &Base::set; - - Base obj; save_this = &obj; - int x, y; save_addr1 = &x; save_addr2 = &y; - - (obj.* pfm) (&x, &y); - (obj.* pfm2) (&x, &y); - (obj.* pfm3) (&x, &y); - (obj.* pfm4) (&x, &y); - - return fail; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti1.C deleted file mode 100644 index f17d88aad..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti1.C +++ /dev/null @@ -1,13 +0,0 @@ -// Test that we don't emit the type_info for a polymorphic class other than -// with the vtable. - -struct A { - virtual ~A(); -}; - -void f () -{ - throw A(); -} - -// { dg-final { scan-assembler-dem-not {\ntypeinfo for A[: \t\n]} } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti2.C deleted file mode 100644 index eece8724a..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti2.C +++ /dev/null @@ -1,12 +0,0 @@ -// { dg-do run } - -#include <cxxabi.h> -#include <typeinfo> - -int main () { - const std::type_info& ti = typeid (const int (*)[3]); - const abi::__pointer_type_info& pti - = static_cast<const abi::__pointer_type_info&>(ti); - if ((pti.__flags & pti.__const_mask) == 0) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti3.C deleted file mode 100644 index c03e4611c..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/rtti3.C +++ /dev/null @@ -1,16 +0,0 @@ -// PR 20647, we must emit the typeinfo's string as weak, but not the -// necessarily the type info object - -// { dg-require-weak "" } -// { dg-skip-if "Linkonce not weak" { *-*-mingw* *-*-cygwin } { "*" } { "" } } -// { dg-final { scan-assembler ".weak\[ \t\]_?_ZTSPP1A" { target { ! { *-*-darwin* } } } } } -// { dg-final { scan-assembler-not ".weak\[ \t\]_?_ZTIPP1A" { target { ! { *-*-darwin* } } } } } -// { dg-final { scan-assembler ".weak_definition\[ \t\]_?_ZTSPP1A" { target { *-*-darwin* } } } } -// { dg-final { scan-assembler-not ".weak_definition\[ \t\]_?_ZTIPP1A" { target { *-*-darwin* } } } } - -struct A; - -void Foo () -{ - throw (A **)0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/structret1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/structret1.C deleted file mode 100644 index e9d4fd0ff..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/structret1.C +++ /dev/null @@ -1,31 +0,0 @@ -// { dg-do run { target ia64-*-* } } -// { dg-options "-fabi-version=0" } - -extern "C" void abort (); - -struct ConstructedObject { - ConstructedObject() {}; - ~ConstructedObject() {}; - ConstructedObject(const ConstructedObject &from) {}; -}; - -struct FrameworkObject { - ConstructedObject action(); -}; - -ConstructedObject FrameworkObject::action() { - void *r32, *r33; - - asm("mov %0 = r32\nmov %1 = r33" : "=r"(r32), "=r"(r33) : ); - if (this != r33) { - abort (); - } -} - -int main() -{ - FrameworkObject slawa; - slawa.action(); - return 0; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk1.C deleted file mode 100644 index 343a2aa6e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk1.C +++ /dev/null @@ -1,24 +0,0 @@ -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } - - -struct A { - virtual void f (); -}; - -struct B : public virtual A { - virtual void f (); -}; - -struct C { - virtual void g (); -}; - -struct D : public C, public B { - virtual void f (); -}; - -void D::f () {} - -// { dg-final { scan-assembler _ZThn4_N1D1fEv } } -// { dg-final { scan-assembler _ZTv0_n12_N1D1fEv } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk2.C deleted file mode 100644 index e6b2924cf..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk2.C +++ /dev/null @@ -1,27 +0,0 @@ -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options -w } - -struct A { - virtual void f2 (); - virtual void f3 (); -}; - -struct B : virtual public A { - virtual void f3 (); -}; - -struct C : public A, public B { - virtual void f4 (); -}; - -struct D : virtual public B, virtual public C, virtual public A -{ - virtual void f5 (); - virtual void f6 (); - virtual void f3 (); -}; - -void D::f3 () {} - -// { dg-final { scan-assembler _ZTvn4_n20_N1D2f3Ev } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk3.C deleted file mode 100644 index f2347f79e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk3.C +++ /dev/null @@ -1,22 +0,0 @@ -// { dg-require-weak "" } -// { dg-final { scan-assembler-not ".weak\[\t \]_?_ZThn._N7Derived3FooEv" { target { ! { *-*-darwin* } } } } } -// { dg-final { scan-assembler-not ".weak_definition\[\t \]_?_ZThn._N7Derived3FooEv" { target { *-*-darwin* } } } } - -struct Base -{ - virtual void Foo (); -}; - -struct Filler -{ - virtual void Baz (); -}; - -struct Derived : Filler, Base -{ - virtual void Foo (); -}; - -void Derived::Foo () -{ -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk4.C deleted file mode 100644 index fa5fbd432..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk4.C +++ /dev/null @@ -1,25 +0,0 @@ -// { dg-require-weak "" } -// { dg-skip-if "Linkonce not weak" { *-*-mingw* *-*-cygwin } { "*" } { "" } } -// { dg-final { scan-assembler ".weak\[ \t\]_?_ZThn._N7Derived3FooEv" { target { ! { *-*-darwin* } } } } } -// { dg-final { scan-assembler ".weak_definition\[ \t\]_?_ZThn._N7Derived3FooEv" { target { *-*-darwin* } } } } - -struct Base -{ - virtual void Foo (); -}; - -struct Filler -{ - virtual void Baz (); -}; - -struct Derived : Filler, Base -{ - virtual void Foo (); -}; - -inline void Derived::Foo () -{ -} - -Derived f; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk5.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk5.C deleted file mode 100644 index 15526bf9e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/thunk5.C +++ /dev/null @@ -1,13 +0,0 @@ -// PR c++/35067 -// The thunks should be weak even on targets without one-only support. -// { dg-require-weak "" } -// { dg-final { scan-assembler "weak.*ZTv" } } - -struct A -{ - virtual ~A() { } -}; - -struct B: virtual A { }; - -B b; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vague1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vague1.C deleted file mode 100644 index 02feee9e2..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vague1.C +++ /dev/null @@ -1,17 +0,0 @@ -// Test that we don't emit unneeded copies of static data member template -// instantiations. - -// Disable debug info so we don't get confused by the symbol name there. -// { dg-options "-g0" } - -template <class T> struct A { - static const T t = 0; -}; - -template <class T> const T A<T>::t; - -int i; -int main () -{ - i = A<int>::t; // Should just use the value -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase1.C deleted file mode 100644 index 39d8b8102..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase1.C +++ /dev/null @@ -1,60 +0,0 @@ -// { dg-do compile } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 5 Sept 2001 <nathan@codesourcery.com> - -// Bug 3986. Another indirect primary base problem. - -struct Consts -{ -}; - -struct MathLib : - virtual Consts -{ -}; - -struct Parallel : - virtual Consts -{ -}; - -struct Particles : - virtual MathLib, - virtual Parallel -{ -}; - -struct Ring : - virtual Particles -{ -}; - -struct Injection : - virtual Particles, - virtual Ring -{ -}; - -struct LSpaceCharge : - virtual Ring, - virtual Injection -{ -}; - -struct Bump : - virtual Consts -{ -}; - -struct Output : - virtual Injection, - virtual Bump -{ -}; - -struct Plots : - virtual LSpaceCharge, - virtual Output -{ -}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase10.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase10.C deleted file mode 100644 index b6e7f88fc..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase10.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do compile } -// -fpack-struct is necessary because the code below assumes the initial -// packing is larger than 1, which cannot ge guaranteed for all targets. -// { dg-options "-Wabi -fabi-version=1 -fpack-struct=8" } -// On ARM processors, the alignment of B will be 4 even though it -// contains only a single "char". That would avoids the situation -// that the warning below is designed to catch. We therefore -// explicitly set the default structure alignment to 1. -// { dg-options "-Wabi -fabi-version=1 -mstructure-size-boundary=8" { target arm*-*-* } } - -struct A { virtual void f(); char c1; }; -struct B { B(); char c2; }; -struct C : public A, public virtual B {}; // { dg-warning "ABI" } - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase11.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase11.C deleted file mode 100644 index 8c854b9c1..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase11.C +++ /dev/null @@ -1,13 +0,0 @@ -// { dg-do run { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0" } - -struct A { virtual void f(); char c1; }; -struct B { B(); char c2; }; -struct C : public A, public virtual B { }; - -int main () { - if (sizeof (C) != 8) - return 1; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase12.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase12.C deleted file mode 100644 index 98b9054f0..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase12.C +++ /dev/null @@ -1,14 +0,0 @@ -// { dg-do run } -// { dg-options "-fabi-version=0" } - -struct A {}; -struct B { A a; virtual void f () {} }; -struct C : public B, virtual public A {}; -struct D : public C, virtual public A {}; - -D d; - -int main () { - if (((char*)(A*)&d - (char*)&d) != 0) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase13.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase13.C deleted file mode 100644 index 6a0bff484..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase13.C +++ /dev/null @@ -1,17 +0,0 @@ -// { dg-do run } -// { dg-options "-fabi-version=0 -w" } - -struct E1 {}; -struct E2 : public E1 {}; -struct E : public E1, public E2 {}; -struct N : public E { virtual void f () {} }; - -struct X : virtual public N { -}; - -int main () { - X x; - /* N should not be the primary base of X; it is not nearly empty. */ - if ((void*)&x == (void*)(N*)&x) - return 1; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase14.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase14.C deleted file mode 100644 index 320d5ba77..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase14.C +++ /dev/null @@ -1,6 +0,0 @@ -// { dg-options "-Wabi -fabi-version=1" } - -struct E1 {}; -struct E2 : public E1 {}; // { dg-warning "layout" } -struct E : public E1, public E2 {}; // { dg-warning "layout|ambiguity" } -struct N : public E { virtual void f () {} }; // { dg-warning "nearly" } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase15.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase15.C deleted file mode 100644 index a0908f40e..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase15.C +++ /dev/null @@ -1,30 +0,0 @@ - // { dg-do run } - -struct Spec - -{ - virtual int id () const = 0; -}; -class D1_1_Spec : public virtual Spec { }; -class D1_2_Spec : public virtual Spec { }; -class D1_3_Spec : public virtual Spec { }; -class D2_1_Spec : public D1_1_Spec, public D1_2_Spec { }; -class D2_Spec : public virtual D2_1_Spec, public virtual D1_3_Spec { }; - -struct D3_Spec : public D2_Spec -{ - virtual int id () const { return 3; } - -}; - -__attribute__((noinline)) void foo(D3_Spec* spec) -{ - spec->id(); -} - -int main() -{ - D3_Spec spec; - foo(&spec); - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-10.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-10.C deleted file mode 100644 index 81896ed64..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-10.C +++ /dev/null @@ -1,75 +0,0 @@ -// { dg-options -w } -// { dg-do run } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 26 Jul 2001 <nathan@codesourcery.com> - -// Origin stefan@space.twc.de -// Bug 3145 case 10. Horribly complicated class hierarchy - -class C0 -{}; -class C1 - : public C0 -{}; -class C2 - : public C1 - , virtual public C0 -{}; -class C3 - : public C1 - , public C2 - , virtual public C0 -{}; -class C4 - : virtual public C1 - , virtual public C0 - , virtual public C3 - , public C2 -{}; -class C5 - : public C3 - , virtual public C0 - , virtual public C2 -{}; -class C6 - : public C1 - , public C2 - , virtual public C5 - , virtual public C3 - , virtual public C0 -{}; -class C7 - : public C1 - , virtual public C5 - , virtual public C4 - , virtual public C2 - , virtual public C0 - , virtual public C6 -{}; -class C8 - : virtual public C4 - , public C3 - , public C0 - , virtual public C7 - , virtual public C6 -{}; -class C9 - : virtual public C0 - , public C4 - , public C8 - , public C1 - , public C6 -{}; -main() { - C0 c0; - C1 c1; - C2 c2; - C3 c3; - C4 c4; - C5 c5; - C6 c6; - C7 c7; - C8 c8; - C9 c9; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-21.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-21.C deleted file mode 100644 index 0da644625..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-21.C +++ /dev/null @@ -1,75 +0,0 @@ -// { dg-options -w } -// { dg-do run } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 26 Jul 2001 <nathan@codesourcery.com> - -// Origin stefan@space.twc.de -// Bug 3145 case 10. Horribly complicated class hierarchy - -class C0 -{}; -class C1 - : virtual public C0 -{}; -class C2 - : virtual public C1 - , virtual public C0 -{}; -class C3 - : virtual public C2 - , virtual public C1 -{}; -class C4 - : virtual public C2 - , public C0 - , public C1 -{}; -class C5 - : virtual public C0 - , public C2 - , virtual public C1 - , virtual public C3 - , virtual public C4 -{}; -class C6 - : virtual public C1 - , virtual public C3 - , public C0 - , public C2 - , virtual public C4 -{}; -class C7 - : virtual public C5 - , public C2 - , public C6 - , virtual public C0 - , public C3 -{}; -class C8 - : virtual public C5 - , public C7 - , virtual public C0 - , virtual public C2 - , virtual public C6 -{}; -class C9 - : virtual public C2 - , virtual public C4 - , public C1 - , virtual public C0 - , public C7 - , public C5 -{}; -main() { - C0 c0; - C1 c1; - C2 c2; - C3 c3; - C4 c4; - C5 c5; - C6 c6; - C7 c7; - C8 c8; - C9 c9; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-22.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-22.C deleted file mode 100644 index 4edb2b47a..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-22.C +++ /dev/null @@ -1,80 +0,0 @@ -// { dg-options -w } -// { dg-do run } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 27 Jul 2001 <nathan@codesourcery.com> - -// Origin stefan@space.twc.de -// Bug 3145 case 22. Horribly complicated class hierarchy - -class C0 -{}; -class C1 - : public C0 -{}; -class C2 - : public C1 - , virtual public C0 -{}; -class C3 - : virtual public C0 - , virtual public C2 - , virtual public C1 -{}; -class C4 - : virtual public C2 - , public C1 - , virtual public C3 - , public C0 -{}; -class C5 - : virtual public C0 - , virtual public C4 - , public C1 - , virtual public C2 - , virtual public C3 -{}; -class C6 - : public C0 - , virtual public C1 - , public C5 - , public C2 - , virtual public C3 - , virtual public C4 -{}; -class C7 - : virtual public C1 - , public C5 - , virtual public C6 - , virtual public C4 - , virtual public C3 - , virtual public C0 -{}; -class C8 - : virtual public C6 - , virtual public C1 - , virtual public C2 - , public C3 - , virtual public C4 -{}; -class C9 - : public C4 - , virtual public C2 - , virtual public C8 - , public C3 - , public C1 - , public C6 - , public C5 -{}; -main() { - C0 c0; - C1 c1; - C2 c2; - C3 c3; - C4 c4; - C5 c5; - C6 c6; - C7 c7; - C8 c8; - C9 c9; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-4.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-4.C deleted file mode 100644 index 2e816f6a8..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase8-4.C +++ /dev/null @@ -1,78 +0,0 @@ -// { dg-options -w } -// { dg-do run } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 20 Nov 2001 <nathan@codesourcery.com> - -// Origin stefan@space.twc.de -// Bug 3145 case 4. Horribly complicated class hierarchy - -class C0 -{}; -class C1 - : virtual public C0 -{}; -class C2 - : public C0 - , public C1 -{}; -class C3 - : virtual public C0 - , public C1 - , public C2 -{}; -class C4 - : public C2 - , public C3 - , virtual public C1 - , virtual public C0 -{}; -class C5 - : virtual public C2 - , public C1 - , public C0 -{}; -class C6 - : virtual public C0 - , virtual public C5 - , public C1 - , public C3 - , public C4 -{}; -class C7 - : public C6 - , virtual public C0 - , public C1 - , public C2 - , virtual public C4 -{}; -class C8 - : public C2 - , virtual public C6 - , virtual public C7 - , public C5 - , public C3 - , virtual public C4 -{}; -class C9 - : public C5 - , virtual public C3 - , virtual public C8 - , public C0 - , public C2 - , public C7 - , public C6 - , public C4 -{}; -main() { - C0 c0; - C1 c1; - C2 c2; - C3 c3; - C4 c4; - C5 c5; - C6 c6; - C7 c7; - C8 c8; - C9 c9; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase9.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase9.C deleted file mode 100644 index 4a0540d06..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vbase9.C +++ /dev/null @@ -1,29 +0,0 @@ -// { dg-do compile } - -// Copyright (C) 2002 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 17 Mar 2002 <nathan@codesourcery.com> -// Origin: Jakub Jelinek <jakub@redhat.com> - -// PR 5681. ICE in build_secondary_vtable - -struct A { - virtual int f1 (); -}; - -struct B : virtual A {}; - -struct C { - virtual int f2 (); -}; - -struct E : A {}; - -struct D : E, B {}; - -struct F : virtual D {}; - -struct G : virtual F, C {}; - -struct H : virtual F {}; - -struct I : G, H {}; diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vcall1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vcall1.C deleted file mode 100644 index 00830cd23..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vcall1.C +++ /dev/null @@ -1,36 +0,0 @@ -// { dg-do run } -// { dg-options "-w" } - -extern "C" void abort (); - -struct B; - -B* b; - -struct A { - virtual void f () {} -}; - -struct B : virtual public A { - B () { - b = this; - ((A*) this)->f (); - } - - virtual void f () { - if (this != b) - abort (); - } -}; - -struct C : public B { -}; - -struct D : public C, public B { - virtual void f () {} -}; - -int main () { - D d; -} - diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk1.C deleted file mode 100644 index 73a0b13f6..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk1.C +++ /dev/null @@ -1,45 +0,0 @@ -// { dg-do link } - -// Copyright (C) 2001 Free Software Foundation, Inc. -// Contributed by Nathan Sidwell 29 Jul 2001 <nathan@codesourcery.com> - -// Origin snyder@fnal.gov -// Bug 3631. We mis-calculated the non-virtual part of a virtual -// thunk. Leading to a link failure, in this case. - -struct A { virtual ~A () {} }; - -struct B : virtual public A -{ - virtual void destroy() {} -}; - -class C : virtual public B {}; -class D : virtual public C {}; -class E : public virtual A {}; - -struct F : virtual public B, virtual public E -{ - virtual void destroy() = 0; -}; - -struct G : public virtual F -{ - virtual void destroy() {} -}; - -class H : virtual public C, virtual public F {}; -class I : virtual public D, virtual public H {}; -class J : public virtual G, public virtual H {}; - -class K : public virtual I, public virtual J -{ - public: - virtual ~K(); -}; -K::~K() {} - -int main () -{ - return 0; -} diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk2.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk2.C deleted file mode 100644 index 9b6f14c50..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk2.C +++ /dev/null @@ -1,17 +0,0 @@ -// { dg-do compile { target i?86-*-* x86_64-*-*} } -// { dg-require-effective-target ilp32 } - -struct c0 { - virtual void f (); -}; - -struct c1 : virtual public c0 { -}; - -struct c2 : virtual public c0, public c1 { - virtual void f (); -}; - -void c2::f () {} - -// { dg-final { scan-assembler _ZTv0_n12_N2c21fEv } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk3.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk3.C deleted file mode 100644 index 59fbbdc4b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vthunk3.C +++ /dev/null @@ -1,27 +0,0 @@ -// { dg-do compile { target i?86-*-* x86_64-*-* } } -// { dg-require-effective-target ilp32 } -// { dg-options "-fabi-version=0" } - -struct A { - virtual void a (); -}; - -struct B : virtual public A { - virtual void b (); - virtual void a (); -}; - -struct C { - virtual void c (); -}; - -struct D : public C, public B { -}; - -struct E : virtual public D { - void b (); -}; - -void E::b () {} - -// { dg-final { scan-assembler _ZTvn4_n20_N1E1bEv } } diff --git a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vtt1.C b/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vtt1.C deleted file mode 100644 index 8235c460b..000000000 --- a/gcc-4.8.1/gcc/testsuite/g++.dg/abi/vtt1.C +++ /dev/null @@ -1,11 +0,0 @@ -// { dg-do compile } - -struct A { -}; - -struct B : virtual public A { -}; - -B b; - -// { dg-final { scan-assembler _ZTT1B } } |