This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

target/9681: powerpc64 -frepo fails to instantiate some templates


>Number:         9681
>Category:       target
>Synopsis:       powerpc64 -frepo fails to instantiate some templates
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Feb 12 23:46:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Janis Johnson
>Release:        3.3 20030210 (prerelease)
>Organization:
>Environment:
powerpc64-linux; SuSE SLES8
>Description:
Five tests in g++.old-deja/g++.pt (instantiate[46].C and
repo[124].C) fail because some templates are not
instantiated with -frepo.  This affects powerpc64-linux,
both cross compilers and native 64-bit compilers, for
mainline, 3.3-branch, and 3.2-branch.

Here's what happens with test repo1.C:

  % g++ -c -frepo repo1.C
  % g++ -frepo repo1.o
  repo1.o: In function `.main':
  repo1.o(.text+0x18): undefined reference to `.void g<int>(int)'
  collect2: ld returned 1 exit status

That test:

template <class T> struct A {
  virtual ~A () { }
};
template <class T> void g (T t) { }
template class A<int>;
int main ()
{
  g (42);
}

>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


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