From 8a92c1831786712b6f26fdc9f8b8bd5463545b19 Mon Sep 17 00:00:00 2001 From: =?utf8?q?G=C3=B6tz=20Lindenmaier?= Date: Fri, 5 Sep 2003 13:57:11 +0000 Subject: [PATCH] comment more verbose infor for retrun node -- new test reference [r1804] --- ir/ir/irdump.c | 8 ++++++++ ir/ir/irnode.h | 13 +++++++++++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/ir/ir/irdump.c b/ir/ir/irdump.c index b4767f1d1..d32e0118f 100644 --- a/ir/ir/irdump.c +++ b/ir/ir/irdump.c @@ -308,6 +308,14 @@ dump_node_info (ir_node *n) { for (i = 0; i < get_method_n_ress(tp); ++i) fprintf(F, " resul %d type: %s \n", i, get_type_name(get_method_res_type(tp, i))); } break; + case iro_Return: { + if (!interprocedural_view) { + type *tp = get_entity_type(get_irg_ent(current_ir_graph)); + fprintf(F, "return in method of type %s \n", get_type_name(tp)); + for (i = 0; i < get_method_n_ress(tp); ++i) + fprintf(F, " res %d type: %s \n", i, get_type_name(get_method_res_type(tp, i))); + } + } break; case iro_Const: { type *tp = get_Const_type(n); assert(tp != none_type); diff --git a/ir/ir/irnode.h b/ir/ir/irnode.h index 7d6d8791b..7850bd264 100644 --- a/ir/ir/irnode.h +++ b/ir/ir/irnode.h @@ -179,8 +179,11 @@ new_ir_node (dbg_info *db, * */ -/* this works for all except Block */ +/* This works for all except Block. To express the difference to + * access routines that work for all nodes we use infix "nodes". */ +#define get_nodes_block get_nodes_Block INLINE ir_node *get_nodes_Block (ir_node *node); +#define set_nodes_block set_nodes_Block INLINE void set_nodes_Block (ir_node *node, ir_node *block); /** Projection numbers for result of Start node: use for Proj nodes! */ @@ -190,7 +193,7 @@ typedef enum { pns_global_store, /**< Projection on the global store */ pns_frame_base, /**< Projection on the frame base */ pns_globals, /**< Projection on the pointer to the data segment - containing _all_ global entities. */ + containing _all_ global entities. */ pns_args, /**< Projection on all arguments */ pns_value_arg_base /**< Pointer to region of compound value arguments as defined by type of this method. */ @@ -489,6 +492,12 @@ INLINE void set_Rot_right (ir_node *node, ir_node *right); INLINE ir_node *get_Conv_op (ir_node *node); INLINE void set_Conv_op (ir_node *node, ir_node *op); +/* Does Cast need a mem operator? + * Cast should only depend on the type, not on the state of an + * entity. But: we initialzie various fields after Alloc, that + * are accessed in the cast. This required some precaution, to + * get the right memory into the Loads generated from the cast. + */ INLINE ir_node *get_Cast_op (ir_node *node); INLINE void set_Cast_op (ir_node *node, ir_node *op); INLINE type *get_Cast_type (ir_node *node); -- 2.20.1