Commit fcc207bf by Andrew Pinski Committed by Andrew Pinski

re PR c/24644 (gcc-4.1 compiled ppc64 kernels do not boot)

2005-11-09  Andrew Pinski  <pinskia@physics.uc.edu>

        PR c/24644
        * dwarf2-out.c (add_name_and_src_coords_attributes): Don't add
        a linkage name for a variable if it a register variable.
        * c-decl.c (grokdeclarator): Global register variables
        should be set as PUBLIC.

From-SVN: r106693
parent 3a64e860
2005-11-09 Andrew Pinski <pinskia@physics.uc.edu>
PR c/24644
* dwarf2-out.c (add_name_and_src_coords_attributes): Don't add
a linkage name for a variable if it a register variable.
* c-decl.c (grokdeclarator): Global register variables
should be set as PUBLIC.
2005-11-09 Andreas Krebbel <krebbel1@de.ibm.com>
PR 24624
......
......@@ -4694,11 +4694,10 @@ grokdeclarator (const struct c_declarator *declarator,
/* At file scope, the presence of a `static' or `register' storage
class specifier, or the absence of all storage class specifiers
makes this declaration a definition (perhaps tentative). Also,
the absence of both `static' and `register' makes it public. */
the absence of `static' makes it public. */
if (current_scope == file_scope)
{
TREE_PUBLIC (decl) = !(storage_class == csc_static
|| storage_class == csc_register);
TREE_PUBLIC (decl) = storage_class != csc_static;
TREE_STATIC (decl) = !extern_ref;
}
/* Not at file scope, only `static' makes a static definition. */
......
......@@ -10809,7 +10809,8 @@ add_name_and_src_coords_attributes (dw_die_ref die, tree decl)
if ((TREE_CODE (decl) == FUNCTION_DECL || TREE_CODE (decl) == VAR_DECL)
&& TREE_PUBLIC (decl)
&& DECL_ASSEMBLER_NAME (decl) != DECL_NAME (decl)
&& !DECL_ABSTRACT (decl))
&& !DECL_ABSTRACT (decl)
&& !(TREE_CODE (decl) == VAR_DECL && DECL_REGISTER (decl)))
add_AT_string (die, DW_AT_MIPS_linkage_name,
IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment