diff options
-rw-r--r-- | gcc/ChangeLog | 9 | ||||
-rw-r--r-- | gcc/gimple-low.c | 2 | ||||
-rw-r--r-- | gcc/tree-inline.c | 1 |
3 files changed, 11 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9ee08dfca07..7eea885e355 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,14 @@ 2011-02-02 Alexandre Oliva <aoliva@redhat.com> + PR debug/47106 + PR debug/47402 + * tree-inline.c (declare_return_variable): Add result decl to + local decls only once. + * gimple-low.c (record_vars_into): Mark newly-created variables + as referenced. + +2011-02-02 Alexandre Oliva <aoliva@redhat.com> + PR debug/47498 PR debug/47501 PR debug/45136 diff --git a/gcc/gimple-low.c b/gcc/gimple-low.c index 2c585e30266..4e492414290 100644 --- a/gcc/gimple-low.c +++ b/gcc/gimple-low.c @@ -907,6 +907,8 @@ record_vars_into (tree vars, tree fn) /* Record the variable. */ add_local_decl (cfun, var); + if (gimple_referenced_vars (cfun)) + add_referenced_var (var); } if (fn != current_function_decl) diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c index 24a6dd02373..0a10df70422 100644 --- a/gcc/tree-inline.c +++ b/gcc/tree-inline.c @@ -2864,7 +2864,6 @@ declare_return_variable (copy_body_data *id, tree return_slot, tree modify_dest, } DECL_SEEN_IN_BIND_EXPR_P (var) = 1; - add_local_decl (DECL_STRUCT_FUNCTION (caller), var); /* Do not have the rest of GCC warn about this variable as it should not be visible to the user. */ |