Correct previous patch to not mark terminate as LEAF.
* class.c (build_vtbl_initializer): Drop LEAF * decl.c (cxx_init_decl_processing): Likewise. (push_throw_library_fn): Likewise. * except.c (init_exception_processing): Likewise. (do_begin_catch): Likewise. (do_end_catch): Likewise. (do_allocate_exception): Likewise. From-SVN: r202100
This commit is contained in:
parent
fafa0521c9
commit
8595a07d8d
4 changed files with 21 additions and 15 deletions
|
@ -1,3 +1,14 @@
|
|||
2013-08-29 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
Correct previous patch to not mark terminate as LEAF.
|
||||
* class.c (build_vtbl_initializer): Drop LEAF
|
||||
* decl.c (cxx_init_decl_processing): Likewise.
|
||||
(push_throw_library_fn): Likewise.
|
||||
* except.c (init_exception_processing): Likewise.
|
||||
(do_begin_catch): Likewise.
|
||||
(do_end_catch): Likewise.
|
||||
(do_allocate_exception): Likewise.
|
||||
|
||||
2013-08-29 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* class.c (build_vtbl_initializer): Make __cxa_deleted_virtual
|
||||
|
|
|
@ -8873,7 +8873,7 @@ build_vtbl_initializer (tree binfo,
|
|||
if (!get_global_value_if_present (fn, &fn))
|
||||
fn = push_library_fn (fn, (build_function_type_list
|
||||
(void_type_node, NULL_TREE)),
|
||||
NULL_TREE, ECF_NORETURN | ECF_LEAF);
|
||||
NULL_TREE, ECF_NORETURN);
|
||||
if (!TARGET_VTABLE_USES_DESCRIPTORS)
|
||||
init = fold_convert (vfunc_ptr_type_node,
|
||||
build_fold_addr_expr (fn));
|
||||
|
|
|
@ -3816,7 +3816,7 @@ cxx_init_decl_processing (void)
|
|||
|
||||
abort_fndecl
|
||||
= build_library_fn_ptr ("__cxa_pure_virtual", void_ftype,
|
||||
ECF_NORETURN | ECF_NOTHROW | ECF_LEAF);
|
||||
ECF_NORETURN | ECF_NOTHROW);
|
||||
|
||||
/* Perform other language dependent initializations. */
|
||||
init_class_processing ();
|
||||
|
@ -4104,7 +4104,7 @@ push_void_library_fn (tree name, tree parmtypes, int ecf_flags)
|
|||
tree
|
||||
push_throw_library_fn (tree name, tree type)
|
||||
{
|
||||
tree fn = push_library_fn (name, type, NULL_TREE, ECF_NORETURN | ECF_LEAF);
|
||||
tree fn = push_library_fn (name, type, NULL_TREE, ECF_NORETURN);
|
||||
return fn;
|
||||
}
|
||||
|
||||
|
|
|
@ -58,8 +58,7 @@ init_exception_processing (void)
|
|||
push_namespace (std_identifier);
|
||||
tmp = build_function_type_list (void_type_node, NULL_TREE);
|
||||
terminate_node = build_cp_library_fn_ptr ("terminate", tmp,
|
||||
ECF_NOTHROW | ECF_NORETURN
|
||||
| ECF_LEAF);
|
||||
ECF_NOTHROW | ECF_NORETURN);
|
||||
TREE_THIS_VOLATILE (terminate_node) = 1;
|
||||
TREE_NOTHROW (terminate_node) = 1;
|
||||
pop_namespace ();
|
||||
|
@ -192,8 +191,7 @@ do_begin_catch (void)
|
|||
if (!get_global_value_if_present (fn, &fn))
|
||||
{
|
||||
/* Declare void* __cxa_begin_catch (void *) throw(). */
|
||||
fn = declare_library_fn (fn, ptr_type_node, ptr_type_node,
|
||||
ECF_NOTHROW | ECF_LEAF);
|
||||
fn = declare_library_fn (fn, ptr_type_node, ptr_type_node, ECF_NOTHROW);
|
||||
|
||||
/* Create its transactional-memory equivalent. */
|
||||
if (flag_tm)
|
||||
|
@ -201,8 +199,7 @@ do_begin_catch (void)
|
|||
tree fn2 = get_identifier ("_ITM_cxa_begin_catch");
|
||||
if (!get_global_value_if_present (fn2, &fn2))
|
||||
fn2 = declare_library_fn (fn2, ptr_type_node,
|
||||
ptr_type_node,
|
||||
ECF_NOTHROW | ECF_TM_PURE | ECF_LEAF);
|
||||
ptr_type_node, ECF_NOTHROW | ECF_TM_PURE);
|
||||
record_tm_replacement (fn, fn2);
|
||||
}
|
||||
}
|
||||
|
@ -242,15 +239,14 @@ do_end_catch (tree type)
|
|||
{
|
||||
/* Declare void __cxa_end_catch ().
|
||||
This can throw if the destructor for the exception throws. */
|
||||
fn = push_void_library_fn (fn, void_list_node, ECF_LEAF);
|
||||
fn = push_void_library_fn (fn, void_list_node, 0);
|
||||
|
||||
/* Create its transactional-memory equivalent. */
|
||||
if (flag_tm)
|
||||
{
|
||||
tree fn2 = get_identifier ("_ITM_cxa_end_catch");
|
||||
if (!get_global_value_if_present (fn2, &fn2))
|
||||
fn2 = push_void_library_fn (fn2, void_list_node,
|
||||
ECF_TM_PURE | ECF_LEAF);
|
||||
fn2 = push_void_library_fn (fn2, void_list_node, ECF_TM_PURE);
|
||||
record_tm_replacement (fn, fn2);
|
||||
}
|
||||
}
|
||||
|
@ -630,7 +626,7 @@ do_allocate_exception (tree type)
|
|||
{
|
||||
/* Declare void *__cxa_allocate_exception(size_t) throw(). */
|
||||
fn = declare_library_fn (fn, ptr_type_node, size_type_node,
|
||||
ECF_NOTHROW | ECF_MALLOC | ECF_LEAF);
|
||||
ECF_NOTHROW | ECF_MALLOC);
|
||||
|
||||
if (flag_tm)
|
||||
{
|
||||
|
@ -638,8 +634,7 @@ do_allocate_exception (tree type)
|
|||
if (!get_global_value_if_present (fn2, &fn2))
|
||||
fn2 = declare_library_fn (fn2, ptr_type_node,
|
||||
size_type_node,
|
||||
ECF_NOTHROW | ECF_MALLOC | ECF_TM_PURE
|
||||
| ECF_LEAF);
|
||||
ECF_NOTHROW | ECF_MALLOC | ECF_TM_PURE);
|
||||
record_tm_replacement (fn, fn2);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue