public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/11702] New: Failure to emit code for inlined function in space
@ 2003-07-29  5:33 gcc-bugzilla at gcc dot gnu dot org
  2003-07-29 11:54 ` [Bug c++/11702] [3.4 Regression] [unit-at-a-time] " pinskia at physics dot uc dot edu
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: gcc-bugzilla at gcc dot gnu dot org @ 2003-07-29  5:33 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11702

           Summary: Failure to emit code for inlined function in space
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: snyder at fnal dot gov
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


Thanks for the fix for c++/11530.
That patch fixed the test case i had earlier.
However, with that patch, i see a new failure, as shown in the example
below.  Here, we don't get code emitted for the right() function
when we compile with -O3.
Note that it works ok if right() is at global scope, rather than
in namespace NS.

$ g++ -o x -O3 x.cc
/tmp/cc4Tsvn2.o: In function `main':
/tmp/cc4Tsvn2.o(.text+0x1a): undefined reference to `NS::right()'
collect2: ld returned 1 exit status
$

Environment:
System: Linux karma 2.4.19-emp_2419p5a829i #1 Tue Sep 3 17:42:17 EST 2002 i686 i686 i386 GNU/Linux
Architecture: i686

	<machine, os, target, libraries (multiple lines)>
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../gcc/configure --prefix=/usr/local/gcc --enable-threads=posix --enable-long-long --enable-languages=c,c++,f77

How-To-Repeat:

Compile and link:

--------------------------
namespace NS
{
  inline int right() {}
}
int foo (int (*pf) ()) { return pf(); }

int main()
{
  return foo (NS::right);
}
--------------------------
------- Additional Comments From snyder at fnal dot gov  2003-07-29 05:32 -------
Fix:
	<how to correct or work around the problem, if known (multiple lines)>


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2003-08-17  8:17 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-29  5:33 [Bug c++/11702] New: Failure to emit code for inlined function in space gcc-bugzilla at gcc dot gnu dot org
2003-07-29 11:54 ` [Bug c++/11702] [3.4 Regression] [unit-at-a-time] " pinskia at physics dot uc dot edu
2003-07-31  4:52 ` pinskia at physics dot uc dot edu
2003-07-31  5:24 ` pinskia at physics dot uc dot edu
2003-07-31  5:28 ` pinskia at physics dot uc dot edu
2003-08-04  1:09 ` pinskia at physics dot uc dot edu
2003-08-12  0:15 ` pinskia at gcc dot gnu dot org
2003-08-17  8:07 ` cvs-commit at gcc dot gnu dot org
2003-08-17  8:17 ` hubicka at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).