/*
- * Copyright (C) 1995-2008 University of Karlsruhe. All right reserved.
- *
* This file is part of libFirm.
- *
- * This file may be distributed and/or modified under the terms of the
- * GNU General Public License version 2 as published by the Free Software
- * Foundation and appearing in the file LICENSE.GPL included in the
- * packaging of this file.
- *
- * Licensees holding valid libFirm Professional Edition licenses may use
- * this file in accordance with the libFirm Commercial License.
- * Agreement provided with the Software.
- *
- * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
- * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE.
+ * Copyright (C) 2012 University of Karlsruhe.
*/
/**
* @file
* @brief Statistics for Firm. Dumping patterns.
* @author Michael Beck
- * @version $Id$
*/
#include "config.h"
" port_sharing: no\n"
" orientation: bottom_to_top\n"
);
-} /* vcg_dump_start */
+}
/**
* Ends a new VCG graph.
fprintf(priv->f, "}\n");
fclose(priv->f);
-} /* vcg_dump_end */
+}
/**
* Starts a new pattern.
" node: {title: \"c%u\" label: \"cnt: %u\" color:red }\n",
++nr, cnt_to_uint(cnt)
);
-} /* vcg_dump_new_pattern */
+}
/**
* Finish the current pattern.
priv->pattern_id - 1);
++priv->pattern_id;
-} /* vcg_dump_finish_pattern */
+}
/**
* Dumps a node.
{
vcg_private_t *priv = (vcg_private_t*)self->data;
ir_op *op = stat_get_op_from_opcode(op_code);
- ir_mode *mode = get_irp_mode(mode_code);
+ ir_mode *mode = ir_get_mode(mode_code);
long l = attr ? *(long *)attr : 0;
if (priv->pattern_id > priv->max_pattern)
} else {
fprintf(priv->f, " node: {title: \"n%u_%u\" label: \"%s%s n%u\" }\n",
priv->pattern_id, id, get_id_str(op->name), mode ? get_mode_name(mode) : "", id);
- } /* if */
-} /* vcg_dump_node */
+ }
+}
/**
* Dumps an edge.
priv->pattern_id, tgt,
pos
);
-} /* vcg_dump_edge */
+}
/**
* The VCG dumper.
FILE *f = (FILE*)self->data;
fprintf(f, "%8u ", cnt_to_uint(cnt));
-} /* stdout_dump_new_pattern */
+}
/**
FILE *f = (FILE*)self->data;
fprintf(f, "\n");
-} /* stdout_dump_finish_pattern */
+}
/**
* Dumps a node.
{
FILE *f = (FILE*)self->data;
ir_op *op = stat_get_op_from_opcode(op_code);
- ir_mode *mode = get_irp_mode(mode_code);
+ ir_mode *mode = ir_get_mode(mode_code);
(void) attr;
/* if (env->options & OPT_ENC_GRAPH) */
if (mode)
fprintf(f, "%s", get_mode_name(mode));
-} /* stdout_dump_node */
+}
/**
* Dump a ref
FILE *f = (FILE*)self->data;
fprintf(f, "REF:%u", id);
-} /* stdout_dump_ref */
+}
/**
* Dump an edge.
if (pos > 0)
fprintf(f, ", ");
-} /* stdout_dump_edge */
+}
/**
* Start the children dumper.
(void) id;
fprintf(f, "(");
-} /* stdout_start_children */
+}
/**
* Finish the children dumper.
(void) id;
fprintf(f, ")");
-} /* stdout_finish_children */
+}
/**
* The stdout dumper.
{
if (self->dump_new_pattern)
self->dump_new_pattern(self, cnt);
-} /* pattern_dump_new_pattern */
+}
/*
{
if (self->dump_finish_pattern)
self->dump_finish_pattern(self);
-} /* pattern_dump_finish_pattern */
+}
/*
{
if (self->dump_node)
self->dump_node(self, id, op_code, mode_code, attr);
-} /* pattern_dump_node */
+}
/*
* Dump a ref.
{
if (self->dump_ref)
self->dump_ref(self, id);
-} /* pattern_dump_ref */
+}
/*
* Dump an edge.
{
if (self->dump_edge)
self->dump_edge(self, tgt, src, pos, mode_code);
-} /* pattern_dump_edge */
+}
/*
* Start the children dumper.
{
if (self->dump_start_children)
self->dump_start_children(self, id);
-} /* pattern_start_children */
+}
/*
* Finish the the children dumper.
{
if (self->dump_finish_children)
self->dump_finish_children(self, id);
-} /* pattern_finish_children */
+}
/*
* Finish the the dumper.
self->dump_end(self);
free(self);
-} /* pattern_end */
+}
/**
* pattern dumper factory for text dumper
if (res->dump_start)
res->dump_start(res);
return res;
-} /* new_text_dumper */
+}
/**
* pattern dumper factory for vcg dumper
if (res->dump_start)
res->dump_start(res);
- } /* if */
+ }
return res;
-} /* new_vcg_dumper */
+}