diff -Nrc3pad gcc-3.0/gcc/testsuite/ChangeLog gcc-3.0.1/gcc/testsuite/ChangeLog *** gcc-3.0/gcc/testsuite/ChangeLog Sun Jun 17 12:40:19 2001 --- gcc-3.0.1/gcc/testsuite/ChangeLog Sun Aug 19 14:08:22 2001 *************** *** 1,3 **** --- 1,139 ---- + 2001-08-19 Release Manager + + * GCC 3.0.1 Released. + + 2001-08-19 Release Manager + + * GCC 3.0.1 Released. + + 2001-08-07 Nathan Sidwell + + * g++.old-deja/g++.abi/empty4.C: New test. + + 2001-08-06 Franz Sirl + + * gcc.c-torture/compile/20010408-1.c: New test. + * gcc.c-torture/execute/ieee/ieee.exp: Only use -ffloat-store on + i[34567]86-*-*. + Delete handling of ieee_multilib_flags. + Pass -mieee for alpha*-*-* and sh-*-*. + * gcc.c-torture/execute/20010114-2.c: Move into ieee subdir. + * gcc.c-torture/execute/20010114-2.x: Remove. + + 2001-08-03 Zack Weinberg + + * gcc.dg/bconstp-1.c: New test. + + 2001-08-02 Nathan Sidwell + + Remove -fhonor-std. + * g++.old-deja/g++.ns/ns14.C: Remove special options. + * g++.old-deja/g++.other/std1.C: Likewise. + * g++.old-deja/g++.robertl/eb133.C: Likewise. Add using directive. + + 2001-07-31 Nathan Sidwell + + * g++.old-deja/g++.abi/vthunk1.C: New test. + + 2001-07-31 Nathan Sidwell + + * g++.old-deja/g++.abi/vbase8-22.C: New test. + + 2001-07-30 Janis Johnson + + * gcc.misc-tests/gcov-3.c: New test. + + 2001-07-27 Peter Schmid + + Copied from mainline by ljrittle (to go along with 2001-07-26 + libstdc++-v3 header staging configuration patch). + * g++.old-deja/g++.robertl/eb130.C: Include the correct header file. + + 2001-07-27 Nathan Sidwell + + * g++.old-deja/g++.abi/vbase8-21.C: New test. + + 2001-07-27 Nathan Sidwell + + * g++.old-deja/g++.abi/vbase8-10.C: New test. + + 2001-07-27 Rainer Orth + + * lib/g++.exp (g++_set_ld_library_path): Renamed to + ${tool}_set_ld_library_path. + Changed caller. + * lib/objc.exp (${tool}_set_ld_library_path): New, copied from + g++.exp. + + 2001-07-26 Nathan Sidwell + + * g++.old-deja/g++.other/lineno5.C: New test. + + 2001-07-26 Nathan Sidwell + + * g++.old-deja/g++.pt/crash68.C: New test. + + 2001-07-26 Nathan Sidwell + + * g++.old-deja/g++.other/crash42.C: New test. + + 2001-07-25 Rainer Orth + + * gcc.c-torture/execute/20010724-1.c: New file. + * gcc.c-torture/execute/20010724-1.x: New file. + + 2001-07-25 Nathan Sidwell + + * g++.old-deja/g++.other/cond7.C: New test. + + 2001-07-25 Jason Merrill + + Copied from mainline. + * g++.old-deja/g++.mike/p2846.C: Check correct copy ctor called. + + 2001-07-25 Nathan Sidwell + + * g++.old-deja/g++.other/optimize4.C: New test. + + 2001-07-25 Nathan Sidwell + + * g++.old-deja/g++.abi/vbase8-5.C: New test. + + 2001-07-19 Rainer Orth + + * g++.old-deja/g++.pt/static3.C: Removed alpha*-*-osf* XFAIL. + g++.old-deja/g++.pt/static6.C: Likewise. + * lib/target-supports.exp (check_weak_available): alpha*-*-osf* + supports weak symbols. + + 2001-07-16 Rainer Orth + + * gcc.c-torture/execute/20001229-1.c: Include for + UAC_SIGBUS, UAC_NOPRINT definitions. + + Mon Jul 16 12:21:56 2001 Nicola Pero + + * objc/execute/object_is_class.m: New test. + * objc/execute/object_is_meta_class.m: New test. + + 2000-09-10 Michael Chamberlain + + * gcc.misc-tests/mg.exp (compiler_output): Support tcl 8.3.1. + + 2001-06-29 Rainer Orth + + * lib/objc.exp (objc_target_compile): Declare rootme. Append to + ld_library_path. + + 2001-06-28 Rainer Orth + + * lib/objc.exp (objc_target_compile): Don't need -lposix4 on any + Solaris 2.[678] system. + + 2001-06-22 Joseph S. Myers + + * gcc.dg/20010622-1.c: New test. + 20010617 Release Manager * GCC 3.0 Released. diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/empty4.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/empty4.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/empty4.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/empty4.C Tue Aug 7 06:06:44 2001 *************** *** 0 **** --- 1,84 ---- + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 31 Jul 2001 + + // Bug 3820. We were bit copying empty bases including the + // padding. Which clobbers whatever they overlay. + + struct Empty {}; + + struct Inter : Empty {}; + + int now = 0; + + struct NonPod + { + int m; + + NonPod () {m = 0x12345678;} + NonPod (int m_) {m = m_;} + NonPod &operator= (NonPod const &src) {now = m; m = src.m;} + NonPod (NonPod const &src) {m = src.m;} + }; + + struct A : Inter + { + A (int c) {m = c;} + + NonPod m; + }; + + struct B + { + Inter empty; + NonPod m; + + B (int c) {m = c;} + }; + + struct C : NonPod, Inter + { + C (int c) : NonPod (c), Inter () {} + }; + + int main () + { + A a (0x12131415); + + int 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-10.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-10.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-10.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-10.C Fri Jul 27 08:11:24 2001 *************** *** 0 **** --- 1,74 ---- + // Special g++ Options: -w + + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 26 Jul 2001 + + // 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-21.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-21.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-21.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-21.C Fri Jul 27 08:15:30 2001 *************** *** 0 **** --- 1,74 ---- + // Special g++ Options: -w + + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 26 Jul 2001 + + // Origin stefan@space.twc.de + // Bug 3145 case 21. 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-22.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-22.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-22.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-22.C Tue Jul 31 01:49:25 2001 *************** *** 0 **** --- 1,79 ---- + // Special g++ Options: -w + + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 27 Jul 2001 + + // 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-5.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-5.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vbase8-5.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vbase8-5.C Wed Jul 25 01:56:42 2001 *************** *** 0 **** --- 1,79 ---- + // Special g++ Options: -w + + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 24 Jul 2001 + + // Origin stefan@space.twc.de + // Bug 3145 case 5. Horribly complicated class hierarchy + + class C0 + {}; + class C1 + : virtual public C0 + {}; + class C2 + : public C0 + , virtual public C1 + {}; + class C3 + : virtual public C0 + , virtual public C2 + , public C1 + {}; + class C4 + : virtual public C0 + , virtual public C2 + , virtual public C1 + , virtual public C3 + {}; + class C5 + : virtual public C3 + , virtual public C2 + , virtual public C0 + , public C4 + , virtual public C1 + {}; + class C6 + : public C0 + , virtual public C3 + , public C4 + , virtual public C5 + , public C1 + {}; + class C7 + : virtual public C3 + , public C5 + , public C2 + , virtual public C4 + , public C6 + , public C0 + {}; + class C8 + : virtual public C2 + , public C5 + , public C7 + , public C1 + , public C0 + , public C4 + , public C3 + {}; + class C9 + : public C3 + , public C2 + , virtual public C6 + , public C8 + , virtual 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vthunk1.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vthunk1.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.abi/vthunk1.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.abi/vthunk1.C Tue Jul 31 01:57:08 2001 *************** *** 0 **** --- 1,45 ---- + // Build don't run: + + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 29 Jul 2001 + + // 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 -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.mike/p2846.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.mike/p2846.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.mike/p2846.C Wed Dec 16 13:46:56 1998 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.mike/p2846.C Wed Jul 25 02:32:49 2001 *************** extern "C" void exit(int); *** 6,11 **** --- 6,13 ---- class A; class B; + int c; + class A { public: *************** public: *** 30,35 **** --- 32,38 ---- virtual ~B(void){} void print(void) const { + ++c; printf("B::print\n"); } *************** int main () *** 50,55 **** { A titi; A toto = titi.compute(); ! printf("PASS\n"); ! return 0; } --- 53,66 ---- { A titi; A toto = titi.compute(); ! if (c != 1) ! { ! printf ("FAIL\n"); ! return 1; ! } ! else ! { ! printf("PASS\n"); ! return 0; ! } } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.ns/ns14.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.ns/ns14.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.ns/ns14.C Wed Dec 16 13:50:45 1998 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.ns/ns14.C Thu Aug 2 07:23:15 2001 *************** *** 1,4 **** ! //Special g++ Options: -fhonor-std namespace std{ int f(){ return 0; --- 1,4 ---- ! namespace std{ int f(){ return 0; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.ns/template18.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.ns/template18.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.ns/template18.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.ns/template18.C Tue Jul 10 23:13:26 2001 *************** *** 0 **** --- 1,24 ---- + // Build don't run: + // Origin: Andrey Slepuhin + + namespace A + { + int j; + + template + struct X + { + inline X () + { + extern int j; + i = j; + } + + int i; + }; + } + + int main () + { + A::X x; + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog Sun Jun 17 12:40:24 2001 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog Sun Aug 19 14:08:24 2001 *************** *** 1,3 **** --- 1,11 ---- + 2001-08-19 Release Manager + + * GCC 3.0.1 Released. + + 2001-08-19 Release Manager + + * GCC 3.0.1 Released. + 20010617 Release Manager * GCC 3.0 Released. diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/array5.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/array5.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/array5.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/array5.C Sun Jul 1 13:48:02 2001 *************** *** 0 **** --- 1,20 ---- + // Special g++ Options: -O1 + + int count = 0; + + double foo () { + count++; + return 0; + }; + + double bar () { + const double x[1] = { foo() }; + return x[0]; + }; + + int main () + { + bar(); + if (count != 1) + return 1; + }; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/asm2.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/asm2.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/asm2.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/asm2.C Wed Jul 11 09:57:24 2001 *************** *** 0 **** --- 1,11 ---- + // Build don't link: + // Skip if not target: i?86-*-* + // Special g++ Options: -O2 + + typedef unsigned long long uint64; + uint64 fstps(void) + { + uint64 ret; + asm volatile("fstps %0" : "=m" (ret)); + return ret; + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/cond7.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/cond7.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/cond7.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/cond7.C Wed Jul 25 02:37:28 2001 *************** *** 0 **** --- 1,26 ---- + // Build don't link: + // + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 24 Jul 2001 + + // Bug 3416. We left some unchecked overloaded functions lying around. + + struct X + { + void operator << (int); + void operator << (float); + }; + + void OVL1 (int); + void OVL1 (float); + + void OVL2 (int); + void OVL2 (float); + + X x; + + void foo (bool a) + { + x << (a ? OVL1 : OVL2); // ERROR - incomplete type + a ? OVL1 : OVL2; // ERROR - incomplete type + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/crash42.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/crash42.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/crash42.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/crash42.C Thu Jul 26 01:07:28 2001 *************** *** 0 **** --- 1,17 ---- + // Build don't link: + // Special g++ Options: -g + // + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 25 Jul 2001 + + // Bug 3152. Using a typedef to declare a function used an unset + // global variable, last_function_parms. + + struct actor + { + typedef bool (operation)(); + + operation a; + operation b; + operation c; + }; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/empty2.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/empty2.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/empty2.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/empty2.C Mon Aug 13 13:54:15 2001 *************** *** 0 **** --- 1,10 ---- + // Build don't link: + // Origin: Mark Mitchell + + struct E {}; + + void f () { + E e1, e2; + e1 = e2; // We should not warn about this statement, even though no + // code is generated for it. + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/lineno5.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/lineno5.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/lineno5.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/lineno5.C Thu Jul 26 01:16:56 2001 *************** *** 0 **** --- 1,19 ---- + // Build don't link: + // + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 25 Jul 2001 + + // Origin: johanb@DoCS.UU.SE + // Bug 3621. At the end of saved input, we'd set the lineno to + // zero. This would confusing things no end, if there was a subsequent + // error. + + namespace tmp { + typedef int B; + B b; + } + + class A { + public: + int kaka(tmp::B = b); // ERROR - no b in scope + }; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/optimize4.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/optimize4.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/optimize4.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/optimize4.C Wed Jul 25 02:01:33 2001 *************** *** 0 **** --- 1,31 ---- + // Build don't link: + // + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 24 Jul 2001 + + // Bug 3543. We forgot to resolve an OFFSET_REF + + + struct Writeable { + bool blocking_mode; + }; + + + struct Pipe : Writeable { + void ewrite(); + + void set_write_blocking () + { + if (Writeable::blocking_mode); + } + }; + + void Pipe::ewrite() + { + set_write_blocking(); + } + + void ewrite(Pipe &p) + { + p.set_write_blocking(); + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/override2.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/override2.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/override2.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/override2.C Mon Jun 18 03:35:30 2001 *************** *** 0 **** --- 1,9 ---- + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Jason Merrill 14 Jun 2001 + + // Test for diagnosis of missing final overrider. + + struct A { virtual void f (); }; + struct B1: virtual A { virtual void f (); }; + struct B2: virtual A { virtual void f (); }; + struct C: public B1, public B2 {}; // ERROR - no final overrider diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/std1.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/std1.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.other/std1.C Thu Oct 19 10:57:48 2000 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.other/std1.C Thu Aug 2 07:23:15 2001 *************** *** 1,5 **** // Build don't link: - // Special g++ Options: -fhonor-std // Origin: Mark Mitchell extern "C" int memcmp (const void * __s1, --- 1,4 ---- diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/crash68.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/crash68.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/crash68.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/crash68.C Thu Jul 26 01:12:58 2001 *************** *** 0 **** --- 1,70 ---- + // Build don't link: + // + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Nathan Sidwell 25 Jul 2001 + + // Origin: gustavo@geneura.ugr.es + // Bug 3624. Template instantiation of a reference type was not + // converted from reference when doing a call. + + #include + + using namespace std; + + template class eo: public A + { + public: + eo() + { + cout << this->x << " " << this->y << " " + << c(*this) << " " + << ((d)?"true":"false") << endl; + } + + private: + B b; + }; + + struct XY + { + float x, y; + + XY(): x(1), y(0.1) {} + }; + + float fitness(const XY& a) + { + return a.x + a.y; + } + + struct fitness2 + { + float operator()(const XY& a) + { + return a.x - a.y; + } + + float f(const XY& a) + { + return a.x - a.y; + } + }; + + struct fitness3 + { + float operator()(const XY& a) + { + return a.x / a.y; + } + }; + + fitness2 f2; + fitness3 f3; + + int main() + { + eo eo2; + eo eo3; + + return 0; + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/deduct7.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/deduct7.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/deduct7.C Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/deduct7.C Mon Jun 18 03:35:31 2001 *************** *** 0 **** --- 1,14 ---- + // Copyright (C) 2001 Free Software Foundation, Inc. + // Contributed by Jason Merrill 14 Jun 2001 + + // Test that deduction can add cv-quals to a pointer-to-member type. + + struct A; + int A::* pi; + + template void f (const T A::*) {} + + int main () + { + f (pi); + } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/ptrmem2.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/ptrmem2.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/ptrmem2.C Wed Dec 16 13:59:36 1998 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/ptrmem2.C Mon Jun 18 03:34:41 2001 *************** S* S::g() *** 31,36 **** --- 31,41 ---- return this; } + S* S::h() + { + return this; + } + int main() { S s; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/static3.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/static3.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/static3.C Mon Jun 12 16:48:12 2000 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/static3.C Thu Jul 19 11:01:31 2001 *************** *** 1,6 **** // On targets that don't support weak symbols, we require an explicit // instantiation of arr. ! // excess errors test - XFAIL *-*-aout *-*-coff *-*-hpux* alpha*-dec-osf* *-*-hms template struct A { --- 1,6 ---- // On targets that don't support weak symbols, we require an explicit // instantiation of arr. ! // excess errors test - XFAIL *-*-aout *-*-coff *-*-hpux* *-*-hms template struct A { diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/static6.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/static6.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/static6.C Wed Jun 14 17:14:08 2000 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/static6.C Thu Jul 19 11:01:31 2001 *************** *** 1,5 **** // Build don't run: ! // excess errors test - XFAIL *-*-aout *-*-coff *-*-hpux* alpha*-dec-osf* *-*-hms // Simplified from testcase by Erez Louidor Lior --- 1,5 ---- // Build don't run: ! // excess errors test - XFAIL *-*-aout *-*-coff *-*-hpux* *-*-hms // Simplified from testcase by Erez Louidor Lior diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/unify8.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/unify8.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.pt/unify8.C Thu Jan 18 01:56:46 2001 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.pt/unify8.C Mon Jun 18 03:35:31 2001 *************** *** 9,18 **** --- 9,20 ---- template void Foo (T const **); + template void Bar (T const * const *); void Foo (int); // ERROR - candidate void Foo (float); // ERROR - candidate void baz (int **p1) { Foo (p1); // ERROR - no such function + Bar (p1); // OK } diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.robertl/eb130.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.robertl/eb130.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.robertl/eb130.C Wed Dec 16 14:03:23 1998 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.robertl/eb130.C Fri Jul 27 15:32:54 2001 *************** *** 6,11 **** // From: Klaus-Georg Adams ! #include std::hash_set foo; --- 6,11 ---- // From: Klaus-Georg Adams ! #include std::hash_set foo; diff -Nrc3pad gcc-3.0/gcc/testsuite/g++.old-deja/g++.robertl/eb133.C gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.robertl/eb133.C *** gcc-3.0/gcc/testsuite/g++.old-deja/g++.robertl/eb133.C Mon Jun 12 16:48:13 2000 --- gcc-3.0.1/gcc/testsuite/g++.old-deja/g++.robertl/eb133.C Thu Aug 2 07:23:15 2001 *************** *** 1,8 **** // Build don't link: - // Special g++ Options: -fno-honor-std // Gives ICE 109 // From: Klaus-Georg Adams // Reported against EGCS snaps 98/06/28. int main() { --- 1,9 ---- // Build don't link: // Gives ICE 109 // From: Klaus-Georg Adams // Reported against EGCS snaps 98/06/28. + + using namespace std; int main() { diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20001229-1.c gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20001229-1.c *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20001229-1.c Fri Dec 29 03:57:30 2000 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20001229-1.c Mon Jul 16 10:19:12 2001 *************** setsysinfo(unsigned long op, void *buffe *** 21,26 **** --- 21,27 ---- #else #include + #include #endif static void __attribute__((constructor)) diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010114-2.c gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010114-2.c *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010114-2.c Sun Jan 14 16:29:53 2001 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010114-2.c Wed Dec 31 16:00:00 1969 *************** *** 1,31 **** - extern void exit (int); - extern void abort (void); - - float - rintf (float x) - { - static const float TWO23 = 8388608.0; - - if (__builtin_fabs (x) < TWO23) - { - if (x > 0.0) - { - x += TWO23; - x -= TWO23; - } - else if (x < 0.0) - { - x = TWO23 - x; - x = -(x - TWO23); - } - } - - return x; - } - - int main (void) - { - if (rintf (-1.5) != -2.0) - abort (); - exit (0); - } --- 0 ---- diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010114-2.x gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010114-2.x *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010114-2.x Mon Apr 30 07:43:00 2001 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010114-2.x Wed Dec 31 16:00:00 1969 *************** *** 1,2 **** - set torture_execute_xfail "*-*-*" - return 0 --- 0 ---- diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010724-1.c gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010724-1.c *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010724-1.c Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010724-1.c Wed Jul 25 04:29:34 2001 *************** *** 0 **** --- 1,59 ---- + /* Verify that the workarounds in config/mips/irix6-libc-compat.c are still + needed. */ + + /* IRIX 6, unlike other Unix systems, defines union semun in . + Inhibit this definition to be able to run this test on other platforms. */ + #define _XOPEN_SOURCE + + #include + #include + #include + #include + #include + + union semun { + int val; + struct semid_ds *buf; + ushort_t *array; + }; + + int + main (void) + { + struct in_addr ia; + int semid; + union semun su; + + ia.s_addr = INADDR_BROADCAST; + + if (strcmp (inet_ntoa (ia), "255.255.255.255") != 0) + abort (); + + ia.s_addr = INADDR_LOOPBACK; + + if (inet_lnaof (ia) != 1) + abort (); + + if (inet_netof (ia) != IN_LOOPBACKNET) + abort (); + + ia = inet_makeaddr (IN_LOOPBACKNET, 1); + if (ia.s_addr != INADDR_LOOPBACK) + abort (); + + if ((semid = semget (IPC_PRIVATE, 1, IPC_CREAT | IPC_EXCL | SEM_R | SEM_A)) < 0) + abort (); + + su.val = 10; + + if (semctl (semid, 0, SETVAL, su) != 0) + abort (); + + if (semctl (semid, 0, GETVAL) != 10) + abort (); + + if (semctl (semid, 0, IPC_RMID) != 0) + abort (); + + return 0; + } diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010724-1.x gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010724-1.x *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/20010724-1.x Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/20010724-1.x Wed Jul 25 04:29:34 2001 *************** *** 0 **** --- 1,3 ---- + # This test is only needed on IRIX 6 + if { ! [istarget "mips*-sgi-irix6*"] } { return 1 } + return 0 diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/ieee/20010114-2.c gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/ieee/20010114-2.c *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/ieee/20010114-2.c Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/ieee/20010114-2.c Mon Aug 6 14:12:39 2001 *************** *** 0 **** --- 1,31 ---- + extern void exit (int); + extern void abort (void); + + float + rintf (float x) + { + static const float TWO23 = 8388608.0; + + if (__builtin_fabs (x) < TWO23) + { + if (x > 0.0) + { + x += TWO23; + x -= TWO23; + } + else if (x < 0.0) + { + x = TWO23 - x; + x = -(x - TWO23); + } + } + + return x; + } + + int main (void) + { + if (rintf (-1.5) != -2.0) + abort (); + exit (0); + } diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.c-torture/execute/ieee/ieee.exp gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/ieee/ieee.exp *** gcc-3.0/gcc/testsuite/gcc.c-torture/execute/ieee/ieee.exp Fri May 11 08:38:56 2001 --- gcc-3.0.1/gcc/testsuite/gcc.c-torture/execute/ieee/ieee.exp Mon Aug 6 14:12:39 2001 *************** if $tracelevel then { *** 31,45 **** strace $tracelevel } ! if [target_info exists ieee_multilib_flags] { ! set additional_flags [target_info ieee_multilib_flags]; ! } else { ! set additional_flags ""; } ! # We must use -ffloat-store to ensure that excess precision on some machines ! # does not cause problems ! lappend additional_flags "-ffloat-store" # load support procs load_lib c-torture.exp --- 31,48 ---- strace $tracelevel } ! set additional_flags ""; ! ! # We must use -ffloat-store/-mieee to ensure that excess precision on some ! # machines does not cause problems ! if [istarget "i\[34567\]86-*-*"] then { ! lappend additional_flags "-ffloat-store" } ! if { [istarget "alpha*-*-*"] ! || [istarget "sh-*-*"] } then { ! lappend additional_flags "-mieee" ! } # load support procs load_lib c-torture.exp diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.dg/20010622-1.c gcc-3.0.1/gcc/testsuite/gcc.dg/20010622-1.c *** gcc-3.0/gcc/testsuite/gcc.dg/20010622-1.c Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.dg/20010622-1.c Fri Jun 22 12:23:27 2001 *************** *** 0 **** --- 1,11 ---- + /* Test for segfault doing -Wsequence-point processing on an empty + statement expression. */ + /* Origin: PR c/3259 from . */ + /* { dg-do compile } */ + /* { dg-options "-Wall" } */ + + void + f (void) + { + ({ }); + } diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.dg/bconstp-1.c gcc-3.0.1/gcc/testsuite/gcc.dg/bconstp-1.c *** gcc-3.0/gcc/testsuite/gcc.dg/bconstp-1.c Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.dg/bconstp-1.c Fri Aug 3 17:24:14 2001 *************** *** 0 **** --- 1,25 ---- + /* { dg-do compile } */ + + /* This test checks that builtin_constant_p can be used safely in + initializers for static data. The macro X() defined below should + be an acceptable initializer expression no matter how complex its + argument is. */ + + extern int a; + extern int b; + + extern int foo(void); + extern int bar(void); + + #define X(exp) (__builtin_constant_p(exp) ? (exp) : -1) + + const short tests[] = { + X(0), + X(a), + X(0 && a), + X(a && b), + X(foo()), + X(0 && foo()), + X(a && foo()), + X(foo() && bar()) + }; diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.misc-tests/gcov-3.c gcc-3.0.1/gcc/testsuite/gcc.misc-tests/gcov-3.c *** gcc-3.0/gcc/testsuite/gcc.misc-tests/gcov-3.c Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/gcc.misc-tests/gcov-3.c Mon Jul 30 14:16:19 2001 *************** *** 0 **** --- 1,45 ---- + /* Test Gcov with computed gotos. + This is the same as test gcc.c-torture/execute/980526-1.c */ + + /* { dg-options "-fprofile-arcs -ftest-coverage" } */ + /* { dg-do run { target native } } */ + + int expect_do1 = 1, expect_do2 = 2; + + static int doit(int x){ + __label__ lbl1; + __label__ lbl2; + static int jtab_init = 0; + static void *jtab[2]; + + if(!jtab_init) { + jtab[0] = &&lbl1; + jtab[1] = &&lbl2; + jtab_init = 1; + } + goto *jtab[x]; + lbl1: + return 1; + lbl2: + return 2; + } + + static void do1(void) { + if (doit(0) != expect_do1) + abort (); + } + + static void do2(void){ + if (doit(1) != expect_do2) + abort (); + } + + int main(void){ /* count(1) */ + #ifndef NO_LABEL_VALUES + do1(); + do2(); + #endif + exit(0); /* count(1) */ + } + + /* { dg-final { run-gcov gcov-3.c } } */ diff -Nrc3pad gcc-3.0/gcc/testsuite/gcc.misc-tests/mg.exp gcc-3.0.1/gcc/testsuite/gcc.misc-tests/mg.exp *** gcc-3.0/gcc/testsuite/gcc.misc-tests/mg.exp Wed Feb 7 18:29:38 2001 --- gcc-3.0.1/gcc/testsuite/gcc.misc-tests/mg.exp Sun Jul 1 12:36:33 2001 *************** load_lib mike-gcc.exp *** 20,24 **** prebase set actions none-of-the-above ! set compiler_output "mg.o ?: .*mg.c \[ \\\n\]*nonexist.h" postbase mg.c "" "" "-MM -MG" --- 20,24 ---- prebase set actions none-of-the-above ! set compiler_output "mg.o ?: .*mg.c \[ \\\\\n\]*nonexist.h" postbase mg.c "" "" "-MM -MG" diff -Nrc3pad gcc-3.0/gcc/testsuite/lib/g++.exp gcc-3.0.1/gcc/testsuite/lib/g++.exp *** gcc-3.0/gcc/testsuite/lib/g++.exp Mon Jun 4 08:24:39 2001 --- gcc-3.0.1/gcc/testsuite/lib/g++.exp Fri Jul 27 05:17:05 2001 *************** if { [info procs prune_warnings] == "" } *** 303,314 **** # proper, so we do it here, by trickery. We really only need to do # this on IRIX, but it shouldn't hurt to do it anywhere else. ! proc g++_set_ld_library_path { name element op } { setenv LD_LIBRARYN32_PATH [getenv LD_LIBRARY_PATH] setenv LD_LIBRARY64_PATH [getenv LD_LIBRARY_PATH] } ! trace variable env(LD_LIBRARY_PATH) w g++_set_ld_library_path # Utility used by mike-g++.exp and old-dejagnu.exp. # Check the compiler(/assembler/linker) output for text indicating that --- 303,314 ---- # proper, so we do it here, by trickery. We really only need to do # this on IRIX, but it shouldn't hurt to do it anywhere else. ! proc ${tool}_set_ld_library_path { name element op } { setenv LD_LIBRARYN32_PATH [getenv LD_LIBRARY_PATH] setenv LD_LIBRARY64_PATH [getenv LD_LIBRARY_PATH] } ! trace variable env(LD_LIBRARY_PATH) w ${tool}_set_ld_library_path # Utility used by mike-g++.exp and old-dejagnu.exp. # Check the compiler(/assembler/linker) output for text indicating that diff -Nrc3pad gcc-3.0/gcc/testsuite/lib/objc.exp gcc-3.0.1/gcc/testsuite/lib/objc.exp *** gcc-3.0/gcc/testsuite/lib/objc.exp Thu Jun 7 10:10:00 2001 --- gcc-3.0.1/gcc/testsuite/lib/objc.exp Fri Jul 27 05:17:05 2001 *************** proc objc_init { args } { *** 113,133 **** } proc objc_target_compile { source dest type options } { global tmpdir; global gluefile wrap_flags; global OBJC_UNDER_TEST global TOOL_OPTIONS global ld_library_path ! set ld_library_path "." lappend options "libs=-lobjc" - # On Solaris 2.x, we need to include libposix4 in order to get - # sched_get_priority_max and such. - if [istarget {sparc*-sun-solaris2.[678]} ] { - lappend options "libs=-lposix4" - } - if { [target_info needs_status_wrapper]!="" && [info exists gluefile] } { lappend options "libs=${gluefile}" lappend options "ldflags=$wrap_flags" --- 113,128 ---- } proc objc_target_compile { source dest type options } { + global rootme; global tmpdir; global gluefile wrap_flags; global OBJC_UNDER_TEST global TOOL_OPTIONS global ld_library_path ! set ld_library_path ".:${rootme}" lappend options "libs=-lobjc" if { [target_info needs_status_wrapper]!="" && [info exists gluefile] } { lappend options "libs=${gluefile}" lappend options "ldflags=$wrap_flags" *************** if { [info procs prune_warnings] == "" } *** 240,245 **** --- 235,254 ---- return $text } } + + # On IRIX 6, we have to set variables akin to LD_LIBRARY_PATH, but + # called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH + # (for the 64-bit ABI). The right way to do this would be to modify + # unix.exp -- but that's not an option since it's part of DejaGNU + # proper, so we do it here, by trickery. We really only need to do + # this on IRIX, but it shouldn't hurt to do it anywhere else. + + proc ${tool}_set_ld_library_path { name element op } { + setenv LD_LIBRARYN32_PATH [getenv LD_LIBRARY_PATH] + setenv LD_LIBRARY64_PATH [getenv LD_LIBRARY_PATH] + } + + trace variable env(LD_LIBRARY_PATH) w ${tool}_set_ld_library_path # Utility used by mike-gcc.exp and c-torture.exp. # Check the compiler(/assembler/linker) output for text indicating that diff -Nrc3pad gcc-3.0/gcc/testsuite/lib/target-supports.exp gcc-3.0.1/gcc/testsuite/lib/target-supports.exp *** gcc-3.0/gcc/testsuite/lib/target-supports.exp Wed Jan 3 10:22:23 2001 --- gcc-3.0.1/gcc/testsuite/lib/target-supports.exp Thu Jul 19 11:01:31 2001 *************** *** 27,38 **** --- 27,45 ---- # this proc returns 1 if they're supported, 0 if they're not, or -1 if unsure proc check_weak_available { } { + global target_triplet global target_cpu # All mips targets should support it if { [ string first "mips" $target_cpu ] >= 0 } { return 1 + } + + # DEC OSF/1/Digital UNIX/Tru64 UNIX supports it + + if { [regexp "alpha.*osf.*" $target_triplet] } { + return 1 } # ELF and ECOFF support it. a.out does with gas/gld but may also with diff -Nrc3pad gcc-3.0/gcc/testsuite/objc/execute/object_is_class.m gcc-3.0.1/gcc/testsuite/objc/execute/object_is_class.m *** gcc-3.0/gcc/testsuite/objc/execute/object_is_class.m Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/objc/execute/object_is_class.m Mon Jul 16 04:33:39 2001 *************** *** 0 **** --- 1,42 ---- + /* Contributed by Nicola Pero - Tue Jul 3 10:55:21 BST 2001 */ + #include + #include + #include + + /* This test demonstrate a failure in object_is_class which was fixed */ + + /* Create a class whose instance variables mirror the struct used for + Class structures in the runtime ... yes we're feeling evil today */ + @interface EvilClass : Object + { + Class super_class; + const char* name; + long version; + unsigned long info; + } + @end + + @implementation EvilClass + - (id) init + { + self = [super init]; + /* The following one is used in the runtime to mark classes */ + info = 0x1L; + return self; + } + @end + + int main (void) + { + /* Create an object of our EvilClass */ + EvilClass *evilObject = [EvilClass new]; + + /* Now check that the object is not a class object */ + if (object_is_class (evilObject)) + { + printf ("object_is_class failed\n"); + abort (); + } + + return 0; + } diff -Nrc3pad gcc-3.0/gcc/testsuite/objc/execute/object_is_meta_class.m gcc-3.0.1/gcc/testsuite/objc/execute/object_is_meta_class.m *** gcc-3.0/gcc/testsuite/objc/execute/object_is_meta_class.m Wed Dec 31 16:00:00 1969 --- gcc-3.0.1/gcc/testsuite/objc/execute/object_is_meta_class.m Mon Jul 16 04:33:39 2001 *************** *** 0 **** --- 1,41 ---- + /* Contributed by Nicola Pero - Tue Jul 3 10:55:21 BST 2001 */ + #include + #include + #include + + /* This test demonstrate a failure in object_is_meta_class which was fixed */ + + @interface EvilClass : Object + { + Class super_class; + const char* name; + long version; + unsigned long info; + } + @end + + @implementation EvilClass + - (id) init + { + self = [super init]; + /* The following one is used in the runtime to mark meta classes */ + info = 0x2L; + return self; + } + @end + + int main (void) + { + /* Create an object of our EvilClass */ + EvilClass *evilObject = [EvilClass new]; + + /* Now check that the object is not a meta class object */ + if (object_is_meta_class (evilObject)) + { + printf ("object_is_meta_class failed\n"); + abort (); + } + + return 0; + } +