CVS:
[libfirm] / ir / ir / ircons.h
index 5c14644..b00434f 100644 (file)
                       - size
                      - linkage_ptr_info
       If the attr.i.num is type_tag or size, the node contains an attribute
-    attr.i.*type     A pointer to a type_class.
+    attr.i.*type,    a pointer to a type_class.  The mode of the node is mode_i.
       if it is linkage_ptr_info it contains
-    attr.i.*ptrinfo  An ident holding information for the linker.
+    attr.i.*ptrinfo,  an ident holding information for the linker.  The mode
+      of the node is mode_p.
 
   THE SELECT NODE
   ---------------
   Parameters:
   *store        The current memory.
   *addr         A pointer to the variable to be read in this memory.
-  *mode         The mode of the loaded value.
 
   Inputs:
     The memory and a pointer to a variable in this memory.
 # include "entity.h"
 # include "tv.h"
 # include "type.h"
-# include "pdeq.h"
-
-#if USE_EXPICIT_PHI_IN_STACK
-/* A stack needed for the automatic Phi node construction in constructor
-   Phi_in. */
-typedef struct Phi_in_stack Phi_in_stack;
-#endif
 
 /***************************************************************************/
 /* The raw interface                                                       */
+/***************************************************************************/
 
+/* Constructs a Block with a fixed number of predecessors.
+   Does not set current_block.  Can not be used with automatic
+   Phi node construction. */
 ir_node *new_r_Block  (ir_graph *irg,  int arity, ir_node **in);
 ir_node *new_r_Start  (ir_graph *irg, ir_node *block);
 ir_node *new_r_End    (ir_graph *irg, ir_node *block);
@@ -1179,20 +1176,16 @@ ir_node *new_r_Bad    ();
 
 /*************************************************************************/
 /* The block oriented interface                                          */
+/*************************************************************************/
 
 /* Sets the current block in which the following constructors place the
    nodes they construct. */
 void switch_block (ir_node *target);
 
-/* Chris: please rename the Block constructor:
-   new_Block to new_immBlock
-   and add a new one so dass das dann so aussieht:
-   passe die Beispeilprogramme an! */
-#if 0
-ir_node *new_Block(int arity, ir_node **in);     /* creates mature Block */
-#else
-ir_node *new_Block  (void);
-#endif
+/* Constructs a Block with a fixed number of predecessors.
+   Does set current_block.  Can be used with automatic Phi
+   node construction. */
+ir_node *new_Block(int arity, ir_node **in);
 ir_node *new_Start  (void);
 ir_node *new_End    (void);
 ir_node *new_Jmp    (void);
@@ -1243,6 +1236,7 @@ ir_node *new_Bad    (void);
 /* Supports automatic Phi node construction.                           */
 /* All routines of the block oriented interface except new_Block are   */
 /* needed also.                                                        */
+/***********************************************************************/
 
 /** Block construction **/
 /* immature Block without predecessors */
@@ -1252,16 +1246,17 @@ ir_node *new_immBlock (void);
 void add_in_edge (ir_node *immblock, ir_node *jmp);
 
 /* fixes the number of predecessors of a block. */
-void     mature_block (ir_node *block);
+void mature_block (ir_node *block);
 
 /** Parameter administration **/
 /* Read a value from the array with the local variables.  Use this
    function to obtain the last definition of the value associated with
-   pos. */
+   pos.  Pos may not exceed the value passed as n_loc to new_ir_graph. */
 ir_node *get_value (int pos, ir_mode *mode);
 
 /* Write a value in the array with the local variables. Use this function
-   to remember a new definition of the value associated with pos. */
+   to remember a new definition of the value associated with pos. Pos may
+   not exceed the value passed as n_loc to new_ir_graph. */
 void set_value (int pos, ir_node *value);
 
 /* Read a store.
@@ -1272,15 +1267,9 @@ ir_node *get_store (void);
 /* Write a store. */
 void set_store (ir_node *store);
 
-/* This function is for internal use only.  It is visible as it is needed
-   in irgraph.c to create the stack that is needed for automatic Phi
-   construction. */
-#if USE_EXPICIT_PHI_IN_STACK
-Phi_in_stack *new_Phi_in_stack();
-#endif
-
-/**************************************************************************/
-/* initialize ir construction                                             */
+/***********************************************************************/
+/* initialize ir construction                                          */
+/***********************************************************************/
 void init_cons (void);