This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: c-dump.h


On Fri, 10 Nov 2000, Richard Earnshaw wrote:

> 
> Where's c-dump.h?  c-dump.c needs it, but it wasn't checked in :-(

Until Mark checks in the correct version, here's one I patched together
from bits in his patch.

Bernd


#define dump_child(field, child) \
  queue_and_dump_index (di, field, child, DUMP_NONE)

/* Flags used with queue functions.  */
#define DUMP_NONE     0
#define DUMP_BINFO    1

/* Information about a node to be dumped.  */

typedef struct dump_node_info
{
  /* The index for the node.  */
   unsigned int index;
 /* Nonzero if the node is a binfo.  */
   unsigned int binfo_p : 1;
}
*dump_node_info_p;

/* A dump_queue is a link in the queue of things to be dumped.  */

typedef struct dump_queue
{
   /* The queued tree node.  */
   splay_tree_node node;
  /* The next node in the queue.  */
   struct dump_queue *next;
} *dump_queue_p;
 
/* A dump_info gives information about how we should perform the dump 
  and about the current state of the dump.  */

struct dump_info
{
  /* The stream on which to dump the information.  */
    FILE *stream;
    /* The next unused node index.  */
    unsigned int index;
    /* The next column.  */
    unsigned int column;
    /* The first node in the queue of nodes to be written out.  */
    dump_queue_p queue;
    /* The last node in the queue.  */
    dump_queue_p queue_end;
    /* Free queue nodes.  */
    dump_queue_p free_list;
    /* The tree nodes which we have already written out.  The 
     keys are the addresses of the nodes; the values are the integer
     indices we assigned them.  */
     splay_tree nodes; 
};


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]