This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

V3 PATCH: Explicitly instantiate more stuff



This patch explicitly instantiates a couple more functions, which is
necessary to make the library work on AIX.

I'm working on removing the -fimplicit-templates stuff to avoid this
problem reoccurring.

With this patch, the `make check-g++' output on AIX is starting to
look reasonable.

It's not done yet, but we've run most of the way through g++.law, and
we have:

  FAIL: g++.abi/arraynew.C (test for excess errors)
  FAIL: g++.abi/cxa_vec.C (test for excess errors)
  FAIL: g++.brendan/new3.C  Execution test
  FAIL: g++.ext/instantiate1.C not instantiated (test for errors, line 18)
  FAIL: g++.ext/instantiate1.C not instantiated (test for errors, line 20)
  FAIL: g++.ext/instantiate2.C not instantiated (test for errors, line 16)
  FAIL: g++.ext/instantiate3.C not instantiated (test for errors, line 13)
  FAIL: g++.jason/2371.C (test for excess errors)
  FAIL: g++.jason/template41.C (test for excess errors)
  FAIL: g++.jason/thunk2.C (test for excess errors)
  FAIL: g++.law/code-gen5.C (test for excess errors)
  FAIL: g++.law/ctors12.C (test for excess errors)
  FAIL: g++.law/cvt2.C (test for excess errors)

which, while not great, is also not nearly as bad as it has been for
the last month or two.  Many of the problems appear to be header-file
related; I suspect some additional fixincludes work will be required,
or else some tweaks to some of the tests.

Note that I have not tried to run the V3 tests themselves yet, at all.

The only patch not checked in that I am using on AIX is:

  Index: config/mt-aix43
  ===================================================================
  RCS file: /cvs/gcc/egcs/config/mt-aix43,v
  retrieving revision 1.2
  diff -c -p -r1.2 mt-aix43
  *** mt-aix43	2000/09/26 19:57:08	1.2
  --- mt-aix43	2001/02/05 19:16:24
  ***************
  *** 1,4 ****
    # AIX 4.3 and above requires -X32_64 flag to all ar and nm commands
  ! # to handle both 32-bit and 64-bit objects.
  ! AR_FOR_TARGET=ar -X32_64
  ! NM_FOR_TARGET=nm -B -X32_64
  --- 1,8 ----
    # AIX 4.3 and above requires -X32_64 flag to all ar and nm commands
  ! # to handle both 32-bit and 64-bit objects.  We use absolute paths
  ! # to avoid accidentally using the GNU linker, which does not 
  ! # accept the same flags.  In particular, `nm -C' means do *not* demangle
  ! # C++ symbols in the AIX linker, but means *do* demangle C++ symbols
  ! # in the GNU linker.
  ! AR_FOR_TARGET=/usr/bin/ar -X32_64
  ! NM_FOR_TARGET=/usr/bin/nm -B -X32_64

You need GAS to build V3 because of bugs in the AIX assembler.
However, you must not use GNU nm, or you will not get correct export
lists in V3.  This patch will break cross-compilation, so I'm not
checking it in.  I'll leave that to David, if he thinks that's best.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com

2001-02-05  Mark Mitchell  <mark@codesourcery.com>

	* src/string-inst.cc (string::_M_replace): Explicitly instantiate.
	(string::_S_construct): Likewise.

Index: src/string-inst.cc
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/src/string-inst.cc,v
retrieving revision 1.12
diff -c -p -r1.12 string-inst.cc
*** string-inst.cc	2001/01/04 04:21:42	1.12
--- string-inst.cc	2001/02/05 19:43:27
*************** namespace std 
*** 73,78 ****
--- 73,92 ----
  
    template 
      S::basic_string(S::iterator, S::iterator, const allocator<C>&);
+ 
+   template
+     S&
+     S::_M_replace(S::iterator, S::iterator, C*, C*, forward_iterator_tag);  
+ 
+   template
+     S&
+     S::_M_replace(S::iterator, S::iterator, const C*, const C*, 
o+ 		  forward_iterator_tag);  
+ 
+   template
+     C*
+     S::_S_construct(const C*, const C*, const allocator<C>&, 
+ 		    forward_iterator_tag);
  } // namespace std
  
  

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]