From: Rainer Orth Date: Fri, 3 Dec 2010 12:51:59 +0000 (+0000) Subject: backport: rtti3.C: Scan for .weakext on alpha*-dec-osf*. X-Git-Tag: releases/gcc-4.5.2~78 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eaaa45179c8633b90897231f9509c2fa591b4d5a;p=thirdparty%2Fgcc.git backport: rtti3.C: Scan for .weakext on alpha*-dec-osf*. Backport from mainline: 2010-11-10 Rainer Orth * g++.dg/abi/rtti3.C: Scan for .weakext on alpha*-dec-osf*. * g++.dg/abi/thunk4.C: Likewise. * g++.dg/other/anon5.C: Skip on alpha*-dec-osf*. * g++.dg/warn/pr31246.C: XFAIL on alpha*-dec-osf*. * g++.dg/warn/weak1.C: Skip on alpha*-dec-osf*. * g++.old-deja/g++.eh/badalloc1.C [!STACK_SIZE && __osf__]: Use large arena_size. * gcc.dg/attr-weakref-1.c: Skip on alpha*-dec-osf*. * gcc.dg/intmax_t-1.c: Likewise. From-SVN: r167423 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 0d0928bc690b..3e6a47e60cce 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,18 @@ +2010-12-03 Rainer Orth + + Backport from mainline: + 2010-11-10 Rainer Orth + + * g++.dg/abi/rtti3.C: Scan for .weakext on alpha*-dec-osf*. + * g++.dg/abi/thunk4.C: Likewise. + * g++.dg/other/anon5.C: Skip on alpha*-dec-osf*. + * g++.dg/warn/pr31246.C: XFAIL on alpha*-dec-osf*. + * g++.dg/warn/weak1.C: Skip on alpha*-dec-osf*. + * g++.old-deja/g++.eh/badalloc1.C [!STACK_SIZE && __osf__]: Use + large arena_size. + * gcc.dg/attr-weakref-1.c: Skip on alpha*-dec-osf*. + * gcc.dg/intmax_t-1.c: Likewise. + 2010-12-03 Rainer Orth Backport from mainline: diff --git a/gcc/testsuite/g++.dg/abi/rtti3.C b/gcc/testsuite/g++.dg/abi/rtti3.C index c03e4611c0b4..60dc9b8d628c 100644 --- a/gcc/testsuite/g++.dg/abi/rtti3.C +++ b/gcc/testsuite/g++.dg/abi/rtti3.C @@ -3,10 +3,12 @@ // { 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\[ \t\]_?_ZTSPP1A" { target { ! { *-*-darwin* alpha*-dec-osf* } } } } } +// { dg-final { scan-assembler-not ".weak\[ \t\]_?_ZTIPP1A" { target { ! { *-*-darwin* alpha*-dec-osf* } } } } } // { dg-final { scan-assembler ".weak_definition\[ \t\]_?_ZTSPP1A" { target { *-*-darwin* } } } } // { dg-final { scan-assembler-not ".weak_definition\[ \t\]_?_ZTIPP1A" { target { *-*-darwin* } } } } +// { dg-final { scan-assembler ".weakext\[ \t\]_?_ZTSPP1A" { target { alpha*-dec-osf* } } } } +// { dg-final { scan-assembler-not ".weakext\[ \t\]_?_ZTIPP1A" { target { alpha*-dec-osf* } } } } struct A; diff --git a/gcc/testsuite/g++.dg/abi/thunk4.C b/gcc/testsuite/g++.dg/abi/thunk4.C index fa5fbd432771..cd9eac3ea103 100644 --- a/gcc/testsuite/g++.dg/abi/thunk4.C +++ b/gcc/testsuite/g++.dg/abi/thunk4.C @@ -1,7 +1,8 @@ // { 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\[ \t\]_?_ZThn._N7Derived3FooEv" { target { ! { *-*-darwin* alpha*-dec-osf* } } } } } // { dg-final { scan-assembler ".weak_definition\[ \t\]_?_ZThn._N7Derived3FooEv" { target { *-*-darwin* } } } } +// { dg-final { scan-assembler ".weakext\[ \t\]_?_ZThn._N7Derived3FooEv" { target { alpha*-dec-osf* } } } } struct Base { diff --git a/gcc/testsuite/g++.dg/other/anon5.C b/gcc/testsuite/g++.dg/other/anon5.C index 12f0900f5f7e..3f50db14036c 100644 --- a/gcc/testsuite/g++.dg/other/anon5.C +++ b/gcc/testsuite/g++.dg/other/anon5.C @@ -1,5 +1,5 @@ // PR c++/34094 -// { dg-do link { target { ! { *-*-darwin* *-*-hpux* *-*-solaris2.* } } } } +// { dg-do link { target { ! { *-*-darwin* *-*-hpux* *-*-solaris2.* alpha*-dec-osf* } } } } // { dg-options "-g" } namespace { diff --git a/gcc/testsuite/g++.dg/warn/pr31246.C b/gcc/testsuite/g++.dg/warn/pr31246.C index f3603af47877..a96dc96c1971 100644 --- a/gcc/testsuite/g++.dg/warn/pr31246.C +++ b/gcc/testsuite/g++.dg/warn/pr31246.C @@ -1,6 +1,7 @@ // PR 31246 // { dg-do compile } // { dg-options "-Wunreachable-code -D_GLIBCXX_DEBUG" } +// { dg-xfail-if "lack of weak symbols" { alpha*-dec-osf* } } #include int main() diff --git a/gcc/testsuite/g++.dg/warn/weak1.C b/gcc/testsuite/g++.dg/warn/weak1.C index efce90a2bcf0..8a50030bc9d3 100644 --- a/gcc/testsuite/g++.dg/warn/weak1.C +++ b/gcc/testsuite/g++.dg/warn/weak1.C @@ -1,7 +1,8 @@ // { dg-do run } // { dg-require-weak "" } -// The PA HP-UX dynamic loader doesn't support unsatisfied weak symbols. -// { dg-skip-if "No unsat" { hppa*-*-hpux* } { "*" } { "" } } +// The PA HP-UX and Tru64 UNIX dynamic loaders don't support unsatisfied +// weak symbols. +// { dg-skip-if "No unsat" { alpha*-dec-osf* hppa*-*-hpux* } { "*" } { "" } } // The darwin loader does, but they do need to exist at link time. // { dg-skip-if "No link unsat" { *-*-darwin* } { "*" } { "" } } // For kernel modules and static RTPs, the loader treats undefined weak diff --git a/gcc/testsuite/g++.old-deja/g++.eh/badalloc1.C b/gcc/testsuite/g++.old-deja/g++.eh/badalloc1.C index 28eb36c89857..cd902fbc3c04 100644 --- a/gcc/testsuite/g++.old-deja/g++.eh/badalloc1.C +++ b/gcc/testsuite/g++.old-deja/g++.eh/badalloc1.C @@ -3,7 +3,7 @@ // itself call malloc(), and will fail if there is no more // memory available. // { dg-do run { xfail { { xstormy16-*-* *-*-darwin[3-7]* } || vxworks_rtp } } } -// Copyright (C) 2000, 2002, 2003 Free Software Foundation, Inc. +// Copyright (C) 2000, 2002, 2003, 2010 Free Software Foundation, Inc. // Contributed by Nathan Sidwell 6 June 2000 // Check we can throw a bad_alloc exception when malloc dies. @@ -18,8 +18,8 @@ extern "C" void *memcpy(void *, const void *, size_t); #ifdef STACK_SIZE const int arena_size = 256; #else -#if defined(__FreeBSD__) || defined(__sun__) || defined(__hpux__) -// FreeBSD, Solaris and HP-UX with threads require even more +#if defined(__FreeBSD__) || defined(__sun__) || defined(__hpux__) || defined(__osf__) +// FreeBSD, Solaris, HP-UX and Tru64 UNIX with threads require even more // space at initialization time. FreeBSD 5 now requires over 131072 bytes. const int arena_size = 262144; #else diff --git a/gcc/testsuite/gcc.dg/attr-weakref-1.c b/gcc/testsuite/gcc.dg/attr-weakref-1.c index 898bc4169a03..31d5379e47c7 100644 --- a/gcc/testsuite/gcc.dg/attr-weakref-1.c +++ b/gcc/testsuite/gcc.dg/attr-weakref-1.c @@ -2,9 +2,10 @@ // { dg-require-weak "" } // On darwin, we use attr-weakref-1-darwin.c. // This test requires support for undefined weak symbols. This support -// is not available on hppa*-*-hpux*. The test is skipped rather than -// xfailed to suppress the warning that would otherwise arise. -// { dg-skip-if "" { "*-*-darwin*" "hppa*-*-hpux*" } "*" { "" } } +// is not available on alpha*-dec-osf* and hppa*-*-hpux*. The test is +// skipped rather than xfailed to suppress the warning that would otherwise +// arise. +// { dg-skip-if "" { "alpha*-dec-osf*" "*-*-darwin*" "hppa*-*-hpux*" } "*" { "" } } // For kernel modules and static RTPs, the loader treats undefined weak // symbols in the same way as undefined strong symbols. The test // therefore fails to load, so skip it. diff --git a/gcc/testsuite/gcc.dg/intmax_t-1.c b/gcc/testsuite/gcc.dg/intmax_t-1.c index 00b503c25090..2f21c63f0297 100644 --- a/gcc/testsuite/gcc.dg/intmax_t-1.c +++ b/gcc/testsuite/gcc.dg/intmax_t-1.c @@ -1,6 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-Wall" } */ /* { dg-error "" "" { target { { *arm*-*-*elf* xtensa*-*-elf* } || vxworks_kernel } } 0 } */ +/* { dg-skip-if "No *intmax_t in " { alpha*-dec-osf* } } */ /* Compile with -Wall to get a warning if built-in and system intmax_t don't match. */