Deleted Added
sdiff udiff text old ( 50617 ) new ( 52521 )
full compact
1/* Prints out tree in human readable form - GNU C-compiler
2 Copyright (C) 1990, 91, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
3
4This file is part of GNU CC.
5
6GNU CC is free software; you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
8the Free Software Foundation; either version 2, or (at your option)
9any later version.
10
11GNU CC is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with GNU CC; see the file COPYING. If not, write to
18the Free Software Foundation, 59 Temple Place - Suite 330,
19Boston, MA 02111-1307, USA. */
20
21
22#include "config.h"
23#include "system.h"
24#include "tree.h"
25
26extern char *mode_name[];
27
28void print_node ();
29void indent_to ();

--- 29 unchanged lines hidden (view full) ---

59 fprintf (stderr, "\n");
60}
61
62/* Print a node in brief fashion, with just the code, address and name. */
63
64void
65print_node_brief (file, prefix, node, indent)
66 FILE *file;
67 char *prefix;
68 tree node;
69 int indent;
70{
71 char class;
72
73 if (node == 0)
74 return;
75

--- 95 unchanged lines hidden (view full) ---

171}
172
173/* Print the node NODE in full on file FILE, preceded by PREFIX,
174 starting in column INDENT. */
175
176void
177print_node (file, prefix, node, indent)
178 FILE *file;
179 char *prefix;
180 tree node;
181 int indent;
182{
183 int hash;
184 struct bucket *b;
185 enum machine_mode mode;
186 char class;
187 int len;

--- 211 unchanged lines hidden (view full) ---

399 if (TREE_CODE (node) != FUNCTION_DECL)
400 fprintf (file, " align %d", DECL_ALIGN (node));
401 else if (DECL_INLINE (node))
402 fprintf (file, " frame_size %d", DECL_FRAME_SIZE (node));
403 else if (DECL_BUILT_IN (node))
404 fprintf (file, " built-in code %d", DECL_FUNCTION_CODE (node));
405 if (TREE_CODE (node) == FIELD_DECL)
406 print_node (file, "bitpos", DECL_FIELD_BITPOS (node), indent + 4);
407 print_node_brief (file, "context", DECL_CONTEXT (node), indent + 4);
408 print_node_brief (file, "machine_attributes", DECL_MACHINE_ATTRIBUTES (node), indent + 4);
409 print_node_brief (file, "abstract_origin",
410 DECL_ABSTRACT_ORIGIN (node), indent + 4);
411
412 print_node (file, "arguments", DECL_ARGUMENTS (node), indent + 4);
413 print_node (file, "result", DECL_RESULT (node), indent + 4);
414 print_node_brief (file, "initial", DECL_INITIAL (node), indent + 4);

--- 112 unchanged lines hidden (view full) ---

527 case 'b':
528 print_node (file, "vars", BLOCK_VARS (node), indent + 4);
529 print_node (file, "tags", BLOCK_TYPE_TAGS (node), indent + 4);
530 print_node (file, "supercontext", BLOCK_SUPERCONTEXT (node), indent + 4);
531 print_node (file, "subblocks", BLOCK_SUBBLOCKS (node), indent + 4);
532 print_node (file, "chain", BLOCK_CHAIN (node), indent + 4);
533 print_node (file, "abstract_origin",
534 BLOCK_ABSTRACT_ORIGIN (node), indent + 4);
535 return;
536
537 case 'e':
538 case '<':
539 case '1':
540 case '2':
541 case 'r':
542 case 's':
543 if (TREE_CODE (node) == BIND_EXPR)
544 {
545 print_node (file, "vars", TREE_OPERAND (node, 0), indent + 4);
546 print_node (file, "body", TREE_OPERAND (node, 1), indent + 4);
547 print_node (file, "block", TREE_OPERAND (node, 2), indent + 4);
548 return;
549 }
550
551 len = tree_code_length[(int) TREE_CODE (node)];
552 /* Some nodes contain rtx's, not trees,
553 after a certain point. Print the rtx's as rtx's. */
554 first_rtl = first_rtl_op (TREE_CODE (node));
555 for (i = 0; i < len; i++)
556 {

--- 138 unchanged lines hidden ---