aboutsummaryrefslogtreecommitdiff
path: root/gcc/doc/tm.texi
diff options
context:
space:
mode:
authorMatt Austern <austern@apple.com>2004-06-03 23:15:01 +0000
committerMatt Austern <austern@gcc.gnu.org>2004-06-03 23:15:01 +0000
commit0524c91d1eee6dc2f1629160ed309a5441fb3bdd (patch)
tree4dfc88aeb614a38019098dbdc178d9f2bfbb2b83 /gcc/doc/tm.texi
parentc073ab616f5692283e12bc93b82a14aad88adf9e (diff)
downloadgcc-0524c91d1eee6dc2f1629160ed309a5441fb3bdd.zip
gcc-0524c91d1eee6dc2f1629160ed309a5441fb3bdd.tar.gz
gcc-0524c91d1eee6dc2f1629160ed309a5441fb3bdd.tar.bz2
re PR c++/15428 (vtables shouldn't always be weak on Darwin)
PR c++/15428 * default.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New name for TARGET_EXPLICIT_INSTANTIATIONS_ONE_ONLY, with reversed sense. * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): Likewise. * doc/tm.texi (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): Rewrite documentation to reflect the new macro name and to clarify its meaning. * cp/decl2.c (maybe_emit_vtables): If TARGET_WEAK_NOT_IN_ARCHIVE_TOC is nonzero, and if we see a noninline definition of a key method, make the vtables nonweak. From-SVN: r82610
Diffstat (limited to 'gcc/doc/tm.texi')
-rw-r--r--gcc/doc/tm.texi22
1 files changed, 16 insertions, 6 deletions
diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi
index aee7ba8..082de59 100644
--- a/gcc/doc/tm.texi
+++ b/gcc/doc/tm.texi
@@ -6753,13 +6753,23 @@ commands that will make the symbol(s) associated with @var{decl} have
hidden, protected or internal visibility as specified by @var{visibility}.
@end deftypefn
-@defmac TARGET_EXPLICIT_INSTANTIATIONS_ONE_ONLY
+@defmac TARGET_WEAK_NOT_IN_ARCHIVE_TOC
A C expression that evaluates to true if the target's linker expects
-explicit template specializations, as well as implicit, to be given
-linkonce semantics. The default is @code{1}. The C++ ABI requires
-this macro to be nonzero. Define this macro for targets where full
-C++ ABI compliance is impossible and where explicit and implicit
-template specialization must be treated differently.
+that weak symbols do not appear in a static archive's table of contents.
+The default is @code{0}.
+
+Leaving weak symbols out of an archive's table of contents means that,
+if a symbol will only have a definition in one translation unit and
+will have undefined references from other translation units, that
+symbol should not be weak. Defining this macro to be nonzero will
+thus have the effect that certain symbols that would normally be weak
+(explicit template instantiations, and vtables for polymorphic classes
+with noninline key methods) will instead be nonweak.
+
+The C++ ABI requires this macro to be zero. Define this macro for
+targets where full C++ ABI compliance is impossible and where linker
+restrictions require weak symbols to be left out of a static archive's
+table of contents.
@end defmac
@defmac TARGET_SUPPORTS_HIDDEN