summaryrefslogtreecommitdiff
path: root/gcc/except.c
diff options
context:
space:
mode:
authornathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-03-29 08:22:21 +0000
committernathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-03-29 08:22:21 +0000
commitde46d199a6a6cfa39cad4303cc1dd349d9dbebfb (patch)
tree223207314f829c7e3af1daa12a5580da548c52d4 /gcc/except.c
parentf0b4894020d46abdf729f2779f318d2d6b8f201f (diff)
downloadgcc-de46d199a6a6cfa39cad4303cc1dd349d9dbebfb.tar.gz
gcc:
* except.c (add_eh_table_entry): Mark type_info's as referenced. gcc/cp: * rtti.c (get_tinfo_decl): Mark used. (emit_tinfo_decl): Don't optimize polymorphic type_info. Only mark as dealt with, if we output it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32799 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/except.c')
-rw-r--r--gcc/except.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/except.c b/gcc/except.c
index 2d7114ae11b..67bbc40c272 100644
--- a/gcc/except.c
+++ b/gcc/except.c
@@ -2162,6 +2162,24 @@ add_eh_table_entry (n)
}
}
eh_table[eh_table_size++] = n;
+
+ if (flag_new_exceptions)
+ {
+ /* We will output the exception table late in the compilation. That
+ references type_info objects which should have already been output
+ by that time. We explicitly mark those objects as being
+ referenced now so we know to emit them. */
+ struct handler_info *handler = get_first_handler (n);
+
+ for (; handler; handler = handler->next)
+ if (handler->type_info && handler->type_info != CATCH_ALL_TYPE)
+ {
+ tree tinfo = (tree)handler->type_info;
+
+ tinfo = TREE_OPERAND (tinfo, 0);
+ TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (tinfo)) = 1;
+ }
+ }
#endif
}