public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
@ 2003-06-20 21:24 ` geoffk at gcc dot gnu dot org
  2003-06-20 21:38 ` bangerth at ices dot utexas dot edu
                   ` (11 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: geoffk at gcc dot gnu dot org @ 2003-06-20 21:24 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=10591



------- Additional Comments From geoffk at gcc dot gnu dot org  2003-06-20 21:24 -------
What we want to do with this is to stop giving anonymous namespace members
globally-visible names, and then we don't need to make their names unique.


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
  2003-06-20 21:24 ` [Bug pch/10591] Members of anonymous namespaces get name mangled with header name geoffk at gcc dot gnu dot org
@ 2003-06-20 21:38 ` bangerth at ices dot utexas dot edu
  2003-06-20 23:02 ` geoffk at geoffk dot org
                   ` (10 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: bangerth at ices dot utexas dot edu @ 2003-06-20 21:38 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=10591



------- Additional Comments From bangerth at ices dot utexas dot edu  2003-06-20 21:38 -------
Subject: Re:  Members of anonymous namespaces get name mangled with header name

> What we want to do with this is to stop giving anonymous
> namespace members globally-visible names, and then we don't need to make
> their names unique.

Yes, except for the open question of how this would interfere with "export". 
Not that I care about this at the moment, but should be considered before a 
fix.

On the other hand, I care very much about this particular PR, since one cannot 
use PCH with BOOST at present :-( I am mostly neutral whether this is fixed 
by munging names of giving them internal linkage, as long as it's being 
fixed...

W.

-------------------------------------------------------------------------
Wolfgang Bangerth              email:            bangerth@ices.utexas.edu
                               www: http://www.ices.utexas.edu/~bangerth/


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
  2003-06-20 21:24 ` [Bug pch/10591] Members of anonymous namespaces get name mangled with header name geoffk at gcc dot gnu dot org
  2003-06-20 21:38 ` bangerth at ices dot utexas dot edu
@ 2003-06-20 23:02 ` geoffk at geoffk dot org
  2003-06-20 23:12 ` bangerth at ices dot utexas dot edu
                   ` (9 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: geoffk at geoffk dot org @ 2003-06-20 23:02 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=10591



------- Additional Comments From geoffk at geoffk dot org  2003-06-20 23:02 -------
Subject: Re:  Members of anonymous namespaces get name mangled with header name

> From: Wolfgang Bangerth <bangerth@ices.utexas.edu>
> Date: Fri, 20 Jun 2003 16:37:39 -0500

> > What we want to do with this is to stop giving anonymous
> > namespace members globally-visible names, and then we don't need to make
> > their names unique.
> 
> Yes, except for the open question of how this would interfere with "export". 
> Not that I care about this at the moment, but should be considered before a 
> fix.

I don't see how it could possibly interfere with the current export
non-implementation.  If export gets implemented in future, it'll
require some way to communicate information between translation units,
and while it's doing that it can also ensure that names are unique
(which will surely be one of the smallest problems that need to be
solved).


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (2 preceding siblings ...)
  2003-06-20 23:02 ` geoffk at geoffk dot org
@ 2003-06-20 23:12 ` bangerth at ices dot utexas dot edu
  2003-07-14 18:18 ` pinskia at physics dot uc dot edu
                   ` (8 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: bangerth at ices dot utexas dot edu @ 2003-06-20 23:12 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=10591



------- Additional Comments From bangerth at ices dot utexas dot edu  2003-06-20 23:08 -------
Subject: Re:  Members of anonymous namespaces get name mangled with header name


> I don't see how it could possibly interfere with the current export
> non-implementation.  If export gets implemented in future, it'll
> require some way to communicate information between translation units,
> and while it's doing that it can also ensure that names are unique
> (which will surely be one of the smallest problems that need to be
> solved).

I totally agree. I don't see a problem there either. That was just one of the 
reasons I heard a while back when this topic was brought up before. (No, 
don't ask me when and where this was.) I'd favor going the way with internal 
linkage now, and think about the interaction with export when that is 
imminent. AFAIK, nobody ever even uttered he'd be interested in implementing 
export...

W.

-------------------------------------------------------------------------
Wolfgang Bangerth              email:            bangerth@ices.utexas.edu
                               www: http://www.ices.utexas.edu/~bangerth/


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (3 preceding siblings ...)
  2003-06-20 23:12 ` bangerth at ices dot utexas dot edu
@ 2003-07-14 18:18 ` pinskia at physics dot uc dot edu
  2003-12-19 10:11 ` pinskia at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: pinskia at physics dot uc dot edu @ 2003-07-14 18:18 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=10591


pinskia at physics dot uc dot edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |3.4


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (4 preceding siblings ...)
  2003-07-14 18:18 ` pinskia at physics dot uc dot edu
@ 2003-12-19 10:11 ` pinskia at gcc dot gnu dot org
  2004-02-03 19:14 ` kevina at gnu dot org
                   ` (6 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-12-19 10:11 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|3.4.0                       |---
            Version|unknown                     |3.4.0


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


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (5 preceding siblings ...)
  2003-12-19 10:11 ` pinskia at gcc dot gnu dot org
@ 2004-02-03 19:14 ` kevina at gnu dot org
  2004-08-18 16:05 ` larsbj at gullik dot net
                   ` (5 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: kevina at gnu dot org @ 2004-02-03 19:14 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From kevina at gnu dot org  2004-02-03 19:14 -------
A similar issue was brought up in the thread "Anonymous Namespaces" found
here http://gcc.gnu.org/ml/gcc/2004-01/msg02323.html and
http://gcc.gnu.org/ml/gcc/2004-02/msg00001.html .

The new unit-at-a-time optimizer is unable to optimize functions inside
anonymous namespaces namespace becuase they technically have external linkage.

The solution seams to be "to make the C++ front end not use (TREE_PUBLIC(x) ==
false) to mean a symbol with internal linkage.  Instead, a language-specific
decl flag ought to be allocated to mean exactly 'internal linkage',
and all local symbols ought to get TREE_PUBLIC false." according to Zack Weinberg.

I hope this will get fixed in time for Gcc 3.4.  I know nothing of Gcc internals
so I can't do it myself so I am hoping someone else will.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kevina at gnu dot org


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


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (6 preceding siblings ...)
  2004-02-03 19:14 ` kevina at gnu dot org
@ 2004-08-18 16:05 ` larsbj at gullik dot net
  2005-04-23 15:31 ` pinskia at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: larsbj at gullik dot net @ 2004-08-18 16:05 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From larsbj at gullik dot net  2004-08-18 16:05 -------
Are there any plans to fix this for 3.5. f.ex.?

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |larsbj at gullik dot net


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


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

* [Bug pch/10591] Members of anonymous namespaces get name mangled with header name
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (7 preceding siblings ...)
  2004-08-18 16:05 ` larsbj at gullik dot net
@ 2005-04-23 15:31 ` pinskia at gcc dot gnu dot org
  2005-08-01  2:24 ` [Bug pch/10591] Members of anonymous namespaces should be 'static' cpence at gmail dot com
                   ` (3 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-04-23 15:31 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-04-23 15:31 -------
*** Bug 21179 has been marked as a duplicate of this bug. ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hans at jukesan dot de


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


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

* [Bug pch/10591] Members of anonymous namespaces should be 'static'
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (8 preceding siblings ...)
  2005-04-23 15:31 ` pinskia at gcc dot gnu dot org
@ 2005-08-01  2:24 ` cpence at gmail dot com
  2005-08-01  4:31 ` geoffk at geoffk dot org
                   ` (2 subsequent siblings)
  12 siblings, 0 replies; 13+ messages in thread
From: cpence at gmail dot com @ 2005-08-01  2:24 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cpence at gmail dot com  2005-08-01 02:24 -------
Three months later, any movement on this bug?  How is the PCH code in the 4.0
branch?  PCH support would be a godsend to people supporting large C++ projects
on GCC.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |cpence at gmail dot com


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


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

* [Bug pch/10591] Members of anonymous namespaces should be 'static'
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (9 preceding siblings ...)
  2005-08-01  2:24 ` [Bug pch/10591] Members of anonymous namespaces should be 'static' cpence at gmail dot com
@ 2005-08-01  4:31 ` geoffk at geoffk dot org
  2005-09-04 18:34 ` geoffk at gcc dot gnu dot org
  2005-09-13  2:46 ` [Bug pch/10591] Members of anonymous namespaces should not be TREE_PUBLIC bkoz at gcc dot gnu dot org
  12 siblings, 0 replies; 13+ messages in thread
From: geoffk at geoffk dot org @ 2005-08-01  4:31 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From geoffk at geoffk dot org  2005-08-01 04:31 -------
Subject: Re:  Members of anonymous namespaces should be 'static'


On 31/07/2005, at 7:24 PM, cpence at gmail dot com wrote:

> Three months later, any movement on this bug?  How is the PCH code  
> in the 4.0
> branch?  PCH support would be a godsend to people supporting large C 
> ++ projects
> on GCC.

There aren't any particular plans I know of to work on this bug,  
although I'd be happy to hear of some.  As far as I know PCH works  
fine in the 4.0 branch (but this bug isn't fixed).


-- 


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


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

* [Bug pch/10591] Members of anonymous namespaces should be 'static'
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (10 preceding siblings ...)
  2005-08-01  4:31 ` geoffk at geoffk dot org
@ 2005-09-04 18:34 ` geoffk at gcc dot gnu dot org
  2005-09-13  2:46 ` [Bug pch/10591] Members of anonymous namespaces should not be TREE_PUBLIC bkoz at gcc dot gnu dot org
  12 siblings, 0 replies; 13+ messages in thread
From: geoffk at gcc dot gnu dot org @ 2005-09-04 18:34 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From geoffk at gcc dot gnu dot org  2005-09-04 18:34 -------
Although members of anonymous namespaces can be made 'static' on every target, they can all be given 
the same name on targets with weak symbol support, since on other targets the typeinfo is compared by 
name so different types must be given different names.

-- 


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


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

* [Bug pch/10591] Members of anonymous namespaces should not be TREE_PUBLIC
       [not found] <20030501232600.10591.bangerth@dealii.org>
                   ` (11 preceding siblings ...)
  2005-09-04 18:34 ` geoffk at gcc dot gnu dot org
@ 2005-09-13  2:46 ` bkoz at gcc dot gnu dot org
  12 siblings, 0 replies; 13+ messages in thread
From: bkoz at gcc dot gnu dot org @ 2005-09-13  2:46 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bkoz at gcc dot gnu dot org  2005-09-13 02:46 -------


See:

http://gcc.gnu.org/ml/gcc-patches/2005-09/msg00772.html

This is a great idea. It would allow anonymous namespaces to be useful, and more
designs (at least g++ designs) could use them.

-benjamin

-- 


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


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

end of thread, other threads:[~2005-09-13  2:46 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20030501232600.10591.bangerth@dealii.org>
2003-06-20 21:24 ` [Bug pch/10591] Members of anonymous namespaces get name mangled with header name geoffk at gcc dot gnu dot org
2003-06-20 21:38 ` bangerth at ices dot utexas dot edu
2003-06-20 23:02 ` geoffk at geoffk dot org
2003-06-20 23:12 ` bangerth at ices dot utexas dot edu
2003-07-14 18:18 ` pinskia at physics dot uc dot edu
2003-12-19 10:11 ` pinskia at gcc dot gnu dot org
2004-02-03 19:14 ` kevina at gnu dot org
2004-08-18 16:05 ` larsbj at gullik dot net
2005-04-23 15:31 ` pinskia at gcc dot gnu dot org
2005-08-01  2:24 ` [Bug pch/10591] Members of anonymous namespaces should be 'static' cpence at gmail dot com
2005-08-01  4:31 ` geoffk at geoffk dot org
2005-09-04 18:34 ` geoffk at gcc dot gnu dot org
2005-09-13  2:46 ` [Bug pch/10591] Members of anonymous namespaces should not be TREE_PUBLIC bkoz 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).