return;
/* Do nothing for global register variables. */
- if (DECL_RTL_SET_P (decl) && GET_CODE (DECL_RTL (decl)) == REG)
+ if (DECL_RTL_SET_P (decl) && REG_P (DECL_RTL (decl)))
{
TREE_ASM_WRITTEN (decl) = 1;
return;
ASM_OUTPUT_LABEL (asm_out_file, name);
}
-/* Set the symbol_referenced flag for ID and notify callgraph code. */
+/* Set the symbol_referenced flag for ID. */
void
mark_referenced (tree id)
{
- if (!TREE_SYMBOL_REFERENCED (id))
- {
- struct cgraph_node *node;
- struct cgraph_varpool_node *vnode;
-
- if (!cgraph_global_info_ready)
- {
- node = cgraph_node_for_identifier (id);
- if (node)
- cgraph_mark_needed_node (node);
- }
-
- vnode = cgraph_varpool_node_for_identifier (id);
- if (vnode)
- cgraph_varpool_mark_needed_node (vnode);
- }
TREE_SYMBOL_REFERENCED (id) = 1;
}
+/* Set the symbol_referenced flag for DECL and notify callgraph. */
+void
+mark_decl_referenced (tree decl)
+{
+ if (TREE_CODE (decl) == FUNCTION_DECL)
+ cgraph_mark_needed_node (cgraph_node (decl));
+ else if (TREE_CODE (decl) == VAR_DECL)
+ cgraph_varpool_mark_needed_node (cgraph_varpool_node (decl));
+ /* else do nothing - we can get various sorts of CST nodes here,
+ which do not need to be marked. */
+}
+
/* Output to FILE a reference to the assembler name of a C-level name NAME.
If NAME starts with a *, the rest of NAME is output verbatim.
Otherwise NAME is transformed in an implementation-defined way
desc = ggc_alloc (sizeof (*desc));
desc->value = copy_constant (exp);
- /* Propagate marked-ness to copied constant. */
+ /* Propagate marked-ness to copied constant. */
if (flag_mudflap && mf_marked_p (exp))
mf_mark (desc->value);
}
/* Now output the underlying data. If we've handling the padding, return.
- Otherwise, break and ensure THISSIZE is the size written. */
+ Otherwise, break and ensure SIZE is the size written. */
switch (code)
{
case CHAR_TYPE:
case OFFSET_TYPE:
if (! assemble_integer (expand_expr (exp, NULL_RTX, VOIDmode,
EXPAND_INITIALIZER),
- size, align, 0))
+ MIN (size, thissize), align, 0))
error ("initializer for integer value is too complicated");
break;
/* Default function to output a label for unwind information. The
default is to do nothing. A target that needs nonlocal labels for
- unwind information must provide its own function to do this. */
+ unwind information must provide its own function to do this. */
void
default_emit_unwind_label (FILE * stream ATTRIBUTE_UNUSED,
tree decl ATTRIBUTE_UNUSED,
+ int for_eh ATTRIBUTE_UNUSED,
int empty ATTRIBUTE_UNUSED)
{
}