/* Prints out tree in human readable form - GCC
- Copyright (C) 1990-2013 Free Software Foundation, Inc.
+ Copyright (C) 1990-2014 Free Software Foundation, Inc.
This file is part of GCC.
#include "tree-cfg.h"
#include "tree-dump.h"
#include "dumpfile.h"
+#include "wide-int-print.h"
/* Define the hash table of nodes already seen.
Such nodes are not repeated; brief cross-references are used. */
fprintf (file, " overflow");
fprintf (file, " ");
- if (TREE_INT_CST_HIGH (node) == 0)
- fprintf (file, HOST_WIDE_INT_PRINT_UNSIGNED, TREE_INT_CST_LOW (node));
- else if (TREE_INT_CST_HIGH (node) == -1
- && TREE_INT_CST_LOW (node) != 0)
- fprintf (file, "-" HOST_WIDE_INT_PRINT_UNSIGNED,
- -TREE_INT_CST_LOW (node));
- else
- fprintf (file, HOST_WIDE_INT_PRINT_DOUBLE_HEX,
- (unsigned HOST_WIDE_INT) TREE_INT_CST_HIGH (node),
- (unsigned HOST_WIDE_INT) TREE_INT_CST_LOW (node));
+ print_dec (node, file, TYPE_SIGN (TREE_TYPE (node)));
}
if (TREE_CODE (node) == REAL_CST)
{
if (TREE_VISITED (node))
fputs (" visited", file);
- if (code != TREE_VEC && code != SSA_NAME)
+ if (code != TREE_VEC && code != INTEGER_CST && code != SSA_NAME)
{
if (TREE_LANG_FLAG_0 (node))
fputs (" tree_0", file);
fputs (" common", file);
if (code == VAR_DECL && DECL_THREAD_LOCAL_P (node))
{
- enum tls_model kind = DECL_TLS_MODEL (node);
- switch (kind)
- {
- case TLS_MODEL_GLOBAL_DYNAMIC:
- fputs (" tls-global-dynamic", file);
- break;
- case TLS_MODEL_LOCAL_DYNAMIC:
- fputs (" tls-local-dynamic", file);
- break;
- case TLS_MODEL_INITIAL_EXEC:
- fputs (" tls-initial-exec", file);
- break;
- case TLS_MODEL_LOCAL_EXEC:
- fputs (" tls-local-exec", file);
- break;
- default:
- gcc_unreachable ();
- }
+ fputs (" ", file);
+ fputs (tls_model_names[DECL_TLS_MODEL (node)], file);
}
if (CODE_CONTAINS_STRUCT (code, TS_DECL_COMMON))
}
if (CODE_CONTAINS_STRUCT (code, TS_DECL_NON_COMMON))
{
- print_node (file, "arguments", DECL_ARGUMENT_FLD (node), indent + 4);
print_node (file, "result", DECL_RESULT_FLD (node), indent + 4);
}
else if (code == FUNCTION_DECL
&& DECL_STRUCT_FUNCTION (node) != 0)
{
+ print_node (file, "arguments", DECL_ARGUMENTS (node), indent + 4);
indent_to (file, indent + 4);
dump_addr (file, "struct-function ", DECL_STRUCT_FUNCTION (node));
}
fprintf (file, " overflow");
fprintf (file, " ");
- if (TREE_INT_CST_HIGH (node) == 0)
- fprintf (file, HOST_WIDE_INT_PRINT_UNSIGNED,
- TREE_INT_CST_LOW (node));
- else if (TREE_INT_CST_HIGH (node) == -1
- && TREE_INT_CST_LOW (node) != 0)
- fprintf (file, "-" HOST_WIDE_INT_PRINT_UNSIGNED,
- -TREE_INT_CST_LOW (node));
- else
- fprintf (file, HOST_WIDE_INT_PRINT_DOUBLE_HEX,
- (unsigned HOST_WIDE_INT) TREE_INT_CST_HIGH (node),
- (unsigned HOST_WIDE_INT) TREE_INT_CST_LOW (node));
+ print_dec (node, file, TYPE_SIGN (TREE_TYPE (node)));
break;
case REAL_CST: