Commit 5f901333 authored by Matthias Braun's avatar Matthias Braun
Browse files

no unnecessary and cryptic abreviations: rename vrfy to verify

[r27836]
parent d9828055
......@@ -49,7 +49,7 @@ libfirminclude_HEADERS = \
irprog.h \
irsimpletype.h \
irtypeinfo.h \
irvrfy.h \
irverify.h \
lowering.h \
rta.h \
seqnumbers.h \
......
......@@ -104,7 +104,7 @@
#include "irprog.h"
#include "irsimpletype.h"
#include "irtypeinfo.h"
#include "irvrfy.h"
#include "irverify.h"
#include "lowering.h"
#include "rta.h"
#include "seqnumbers.h"
......
......@@ -404,7 +404,7 @@
* --------------------------------------------
*
* Creates a new Block with the given list of predecessors. This block
* is mature. As other constructors calls optimization and vrfy for the
* is mature. As other constructors calls optimization and verify for the
* block. If one of the predecessors is Unknown (as it has to be filled in
* later) optimizations are skipped. This is necessary to
* construct Blocks in loops.
......
......@@ -23,8 +23,8 @@
* @author Christian Schaefer, Goetz Lindenmaier, Till Riedel
* @version $Id$
*/
#ifndef FIRM_IR_IRVRFY_H
#define FIRM_IR_IRVRFY_H
#ifndef FIRM_IR_IRVERIFY_H
#define FIRM_IR_IRVERIFY_H
#include "firm_types.h"
#include "begin.h"
......@@ -33,53 +33,44 @@
* Tests the modes of checknode and its predecessors.
* checknode must be in current_ir_graph.
*
* @return
* NON-zero on success
* @return NON-zero on success
*/
FIRM_API int irn_vrfy(ir_node *checknode);
FIRM_API int irn_verify(ir_node *checknode);
/**
* Tests the modes of checknode and its predecessors.
* checknode must be in given ir_graph.
*
* @return
* NON-zero on success
* @return NON-zero on success
*/
FIRM_API int irn_vrfy_irg(ir_node *checknode, ir_graph *irg);
FIRM_API int irn_verify_irg(ir_node *checknode, ir_graph *irg);
/**
* Same as irn_vrfy_irg, but temporary sets verification mode to
* Same as irn_verify_irg, but temporary sets verification mode to
* NODE_VERIFICATION_ERROR_ONLY.
* @return
* NON-zero on success
* @return NON-zero on success
*/
FIRM_API int irn_vrfy_irg_dump(ir_node *checknode, ir_graph *irg, const char **bad_string);
FIRM_API int irn_verify_irg_dump(ir_node *checknode, ir_graph *irg, const char **bad_string);
/**
* Flags for irg_verify().
*/
typedef enum _irg_verify_flags_t {
VRFY_NORMAL = 0, /**< check SSA property only if dominance information is available */
VRFY_ENFORCE_SSA = 1 /**< check SSA property by enforcing the dominance information recalculation */
VERIFY_NORMAL = 0, /**< check SSA property only if dominance information is available */
VERIFY_ENFORCE_SSA = 1 /**< check SSA property by enforcing the dominance information recalculation */
} irg_verify_flags_t;
/**
* Calls irn_vrfy() for each node in irg.
* Calls irn_verify() for each node in irg.
* Graph must be in state "op_pin_state_pinned".
*
* @param irg the IR-graph t check
* @param flags one of irg_verify_flags_t
*
* @return
* NON-zero on success.
* @return NON-zero on success.
*/
FIRM_API int irg_verify(ir_graph *irg, unsigned flags);
/**
* Compatibility macro. Deprecated soon.
*/
#define irg_vrfy(irg) irg_verify(irg, 0)
/**
* Creates an ir_graph pass for irg_verify().
*
......@@ -91,7 +82,7 @@ FIRM_API int irg_verify(ir_graph *irg, unsigned flags);
FIRM_API ir_graph_pass_t *irg_verify_pass(const char *name, unsigned flags);
/**
* Possible flags for irg_vrfy_bads().
* Possible flags for irg_verify_bads().
*/
enum verify_bad_flags_t {
BAD_CF = 1, /**< Bad nodes are allowed as predecessors of Blocks and Phis. */
......@@ -108,14 +99,14 @@ enum verify_bad_flags_t {
* which Bads are allowed
* @returns a value combined of verify_bad_flags_t indicating the problems found.
*/
FIRM_API int irg_vrfy_bads(ir_graph *irg, int flags);
FIRM_API int irg_verify_bads(ir_graph *irg, int flags);
/**
* Enable/disable verification of Load/Store nodes with
* its entities. If disabled, Store(SymConst(array)) will be allowed
* (C-frontend builds this :-)
*/
FIRM_API void vrfy_enable_entity_tests(int enable);
FIRM_API void verify_enable_entity_tests(int enable);
#include "end.h"
......
......@@ -1019,9 +1019,9 @@ FIRM_API ir_class_cast_state get_irp_class_cast_state(void);
FIRM_API void verify_irg_class_cast_state(ir_graph *irg);
/**
* possible trvrfy() error codes
* possible trverify() error codes
*/
enum trvrfy_error_codes {
enum trverify_error_codes {
no_error = 0, /**< no error */
error_ent_not_cont, /**< overwritten entity not in superclass */
error_null_mem, /**< compound contains NULL member */
......@@ -1048,7 +1048,7 @@ FIRM_API int check_type(ir_type *tp);
*
* @return
* 0 if no error encountered
* != 0 a trvrfy_error_codes code
* != 0 a trverify_error_codes code
*/
FIRM_API int check_entity(ir_entity *ent);
......@@ -1064,7 +1064,7 @@ FIRM_API int check_entity(ir_entity *ent);
* 0 if graph is correct
* else error code.
*/
FIRM_API int tr_vrfy(void);
FIRM_API int tr_verify(void);
/**
* @page type representation of types
......
......@@ -38,7 +38,7 @@
#include "pset_new.h"
#include "irgwalk.h"
#include "irgmod.h"
#include "irvrfy.h"
#include "irverify.h"
#include "irprintf.h"
#include "debug.h"
#include "error.h"
......@@ -313,9 +313,9 @@ void rta_init(void)
{
int i;
for (i = get_irp_n_irgs() - 1; i >= 0; --i) {
irg_vrfy(get_irp_irg(i));
irg_verify(get_irp_irg(i), 0);
}
tr_vrfy();
tr_verify();
}
# endif /* defined DEBUG_libfirm */
......@@ -332,9 +332,9 @@ void rta_init(void)
int i;
for (i = get_irp_n_irgs() - 1; i >= 0; --i) {
irg_vrfy(get_irp_irg(i));
irg_verify(get_irp_irg(i), 0);
}
tr_vrfy();
tr_verify();
}
# endif /* defined DEBUG_libfirm */
}
......@@ -402,9 +402,9 @@ void rta_cleanup(void)
# ifdef DEBUG_libfirm
int i;
for (i = get_irp_n_irgs() - 1; i >= 0; --i) {
irg_vrfy(get_irp_irg(i));
irg_verify(get_irp_irg(i), 0);
}
tr_vrfy();
tr_verify();
# endif /* defined DEBUG_libfirm */
if (_live_classes != NULL) {
......
......@@ -35,7 +35,6 @@
#include "ircons_t.h"
#include "iropt_t.h"
#include "irop.h"
#include "irvrfy_t.h"
#include "irprintf.h"
#include "xmalloc.h"
......@@ -53,7 +52,7 @@
*/
static void TEMPLATE_dump_node(FILE *F, ir_node *n, dump_reason_t reason)
{
ir_mode *mode = NULL;
ir_mode *mode = NULL;
switch (reason) {
case dump_node_opcode_txt:
......
......@@ -29,7 +29,6 @@
#include "irmode_t.h"
#include "irgmod.h"
#include "iredges.h"
#include "irvrfy.h"
#include "ircons.h"
#include "iropt_t.h"
#include "debug.h"
......
......@@ -35,7 +35,6 @@
#include "ircons_t.h"
#include "iropt_t.h"
#include "irop.h"
#include "irvrfy_t.h"
#include "irprintf.h"
#include "xmalloc.h"
......
......@@ -29,7 +29,6 @@
#include "irmode_t.h"
#include "irgmod.h"
#include "iredges.h"
#include "irvrfy.h"
#include "ircons.h"
#include "iropt_t.h"
#include "error.h"
......
......@@ -37,7 +37,6 @@
#include "ircons_t.h"
#include "iropt_t.h"
#include "irop.h"
#include "irvrfy_t.h"
#include "irprintf.h"
#include "xmalloc.h"
......
......@@ -30,7 +30,6 @@
#include "irmode_t.h"
#include "irgmod.h"
#include "iredges.h"
#include "irvrfy.h"
#include "ircons.h"
#include "irprintf.h"
#include "dbginfo.h"
......
......@@ -53,9 +53,9 @@ enum {
};
enum {
BE_VRFY_OFF,
BE_VRFY_WARN,
BE_VRFY_ASSERT
BE_VERIFY_OFF,
BE_VERIFY_WARN,
BE_VERIFY_ASSERT
};
enum {
......@@ -72,7 +72,7 @@ struct be_options_t {
int omit_leaf_fp; /**< try to omit the frame pointer in leaf routines */
int pic; /**< create position independent code */
int gprof; /**< create gprof compatible profiling code */
int vrfy_option; /**< backend verify option */
int verify_option; /**< backend verify option */
int scheduler; /**< the scheduler */
char target_os[128]; /**< target operating system name */
char ilp_server[128]; /**< the ilp server name */
......
......@@ -43,7 +43,7 @@
#include "iredges_t.h"
#include "irloop_t.h"
#include "irtools.h"
#include "irvrfy.h"
#include "irverify.h"
#include "irprintf.h"
#include "iroptimize.h"
#include "firmstat.h"
......@@ -88,7 +88,7 @@ static be_options_t be_options = {
0, /* try to omit leaf frame pointer */
0, /* create PIC code */
0, /* create gprof compatible profiling code */
BE_VRFY_WARN, /* verification level: warn */
BE_VERIFY_WARN, /* verification level: warn */
BE_SCHED_LIST, /* scheduler: list scheduler */
"linux", /* target OS name */
"i44pc52.info.uni-karlsruhe.de", /* ilp server */
......@@ -118,10 +118,10 @@ static const lc_opt_enum_mask_items_t dump_items[] = {
};
/* verify options. */
static const lc_opt_enum_int_items_t vrfy_items[] = {
{ "off", BE_VRFY_OFF },
{ "warn", BE_VRFY_WARN },
{ "assert", BE_VRFY_ASSERT },
static const lc_opt_enum_int_items_t verify_items[] = {
{ "off", BE_VERIFY_OFF },
{ "warn", BE_VERIFY_WARN },
{ "assert", BE_VERIFY_ASSERT },
{ NULL, 0 }
};
......@@ -138,8 +138,8 @@ static lc_opt_enum_mask_var_t dump_var = {
&be_options.dump_flags, dump_items
};
static lc_opt_enum_int_var_t vrfy_var = {
&be_options.vrfy_option, vrfy_items
static lc_opt_enum_int_var_t verify_var = {
&be_options.verify_option, verify_items
};
static lc_opt_enum_int_var_t sched_var = {
......@@ -153,7 +153,7 @@ static const lc_opt_table_entry_t be_main_options[] = {
LC_OPT_ENT_BOOL ("omitleaffp", "omit frame pointer in leaf routines", &be_options.omit_leaf_fp),
LC_OPT_ENT_BOOL ("pic", "create PIC code", &be_options.pic),
LC_OPT_ENT_BOOL ("gprof", "create gprof profiling code", &be_options.gprof),
LC_OPT_ENT_ENUM_PTR ("verify", "verify the backend irg", &vrfy_var),
LC_OPT_ENT_ENUM_PTR ("verify", "verify the backend irg", &verify_var),
LC_OPT_ENT_BOOL ("time", "get backend timing statistics", &be_options.timing),
LC_OPT_ENT_BOOL ("profile", "instrument the code for execution count profiling", &be_options.opt_profile),
LC_OPT_ENT_ENUM_PTR ("sched", "select a scheduler", &sched_var),
......@@ -355,11 +355,11 @@ static const backend_params be_params = {
};
/* Perform schedule verification if requested. */
static void be_sched_vrfy(ir_graph *irg, int vrfy_opt)
static void be_sched_verify(ir_graph *irg, int verify_opt)
{
if (vrfy_opt == BE_VRFY_WARN) {
if (verify_opt == BE_VERIFY_WARN) {
be_verify_schedule(irg);
} else if (vrfy_opt == BE_VRFY_ASSERT) {
} else if (verify_opt == BE_VERIFY_ASSERT) {
assert(be_verify_schedule(irg) && "Schedule verification failed.");
}
}
......@@ -616,11 +616,11 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
/* Verify the initial graph */
be_timer_push(T_VERIFY);
if (be_options.vrfy_option == BE_VRFY_WARN) {
irg_verify(irg, VRFY_ENFORCE_SSA);
if (be_options.verify_option == BE_VERIFY_WARN) {
irg_verify(irg, VERIFY_ENFORCE_SSA);
be_check_dominance(irg);
} else if (be_options.vrfy_option == BE_VRFY_ASSERT) {
assert(irg_verify(irg, VRFY_ENFORCE_SSA) && "irg verification failed");
} else if (be_options.verify_option == BE_VERIFY_ASSERT) {
assert(irg_verify(irg, VERIFY_ENFORCE_SSA) && "irg verification failed");
assert(be_check_dominance(irg) && "Dominance verification failed");
}
be_timer_pop(T_VERIFY);
......@@ -659,9 +659,9 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
dump(DUMP_PREPARED, irg, "before-code-selection");
if (be_options.vrfy_option == BE_VRFY_WARN) {
if (be_options.verify_option == BE_VERIFY_WARN) {
be_check_dominance(irg);
} else if (be_options.vrfy_option == BE_VRFY_ASSERT) {
} else if (be_options.verify_option == BE_VERIFY_ASSERT) {
assert(be_check_dominance(irg) && "Dominance verification failed");
}
......@@ -670,9 +670,9 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
arch_code_generator_prepare_graph(birg->cg);
be_timer_pop(T_CODEGEN);
if (be_options.vrfy_option == BE_VRFY_WARN) {
if (be_options.verify_option == BE_VERIFY_WARN) {
be_check_dominance(irg);
} else if (be_options.vrfy_option == BE_VRFY_ASSERT) {
} else if (be_options.verify_option == BE_VERIFY_ASSERT) {
assert(be_check_dominance(irg) && "Dominance verification failed");
}
......@@ -714,7 +714,7 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
/* check schedule */
be_timer_push(T_VERIFY);
be_sched_vrfy(irg, be_options.vrfy_option);
be_sched_verify(irg, be_options.verify_option);
be_timer_pop(T_VERIFY);
/* introduce patterns to assure constraints */
......@@ -746,7 +746,7 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
/* check schedule */
be_timer_push(T_VERIFY);
be_sched_vrfy(irg, be_options.vrfy_option);
be_sched_verify(irg, be_options.verify_option);
be_timer_pop(T_VERIFY);
stat_ev_if {
......@@ -792,13 +792,13 @@ static void be_main_loop(FILE *file_handle, const char *cup_name)
/* check schedule and register allocation */
be_timer_push(T_VERIFY);
if (be_options.vrfy_option == BE_VRFY_WARN) {
irg_verify(irg, VRFY_ENFORCE_SSA);
if (be_options.verify_option == BE_VERIFY_WARN) {
irg_verify(irg, VERIFY_ENFORCE_SSA);
be_check_dominance(irg);
be_verify_schedule(irg);
be_verify_register_allocation(irg);
} else if (be_options.vrfy_option == BE_VRFY_ASSERT) {
assert(irg_verify(irg, VRFY_ENFORCE_SSA) && "irg verification failed");
} else if (be_options.verify_option == BE_VERIFY_ASSERT) {
assert(irg_verify(irg, VERIFY_ENFORCE_SSA) && "irg verification failed");
assert(be_check_dominance(irg) && "Dominance verification failed");
assert(be_verify_schedule(irg) && "Schedule verification failed");
assert(be_verify_register_allocation(irg)
......
......@@ -1985,10 +1985,10 @@ static void be_pref_alloc(ir_graph *new_irg)
/* verify schedule and register pressure */
be_timer_push(T_VERIFY);
if (be_get_irg_options(irg)->vrfy_option == BE_VRFY_WARN) {
if (be_get_irg_options(irg)->verify_option == BE_VERIFY_WARN) {
be_verify_schedule(irg);
be_verify_register_pressure(irg, cls);
} else if (be_get_irg_options(irg)->vrfy_option == BE_VRFY_ASSERT) {
} else if (be_get_irg_options(irg)->verify_option == BE_VERIFY_ASSERT) {
assert(be_verify_schedule(irg) && "Schedule verification failed");
assert(be_verify_register_pressure(irg, cls)
&& "Register pressure verification failed");
......@@ -2013,9 +2013,9 @@ static void be_pref_alloc(ir_graph *new_irg)
be_timer_pop(T_RA_SPILL_APPLY);
be_timer_push(T_VERIFY);
if (be_get_irg_options(irg)->vrfy_option == BE_VRFY_WARN) {
if (be_get_irg_options(irg)->verify_option == BE_VERIFY_WARN) {
be_verify_register_allocation(irg);
} else if (be_get_irg_options(irg)->vrfy_option == BE_VRFY_ASSERT) {
} else if (be_get_irg_options(irg)->verify_option == BE_VERIFY_ASSERT) {
assert(be_verify_register_allocation(irg)
&& "Register allocation invalid");
}
......
......@@ -38,7 +38,7 @@
#include "ircons_t.h"
#include "iropt_t.h"
#include "irop.h"
#include "irvrfy_t.h"
#include "irverify_t.h"
#include "irprintf.h"
#include "iredges.h"
#include "error.h"
......
......@@ -38,7 +38,6 @@
#include "irprog_t.h"
#include "iredges_t.h"
#include "irgmod.h"
#include "irvrfy.h"
#include "ircons.h"
#include "irgwalk.h"
#include "irprintf.h"
......
......@@ -465,7 +465,7 @@ EOF
$temp .= <<EOF;
/* optimize node */
res = optimize_node(res);
irn_vrfy_irg(res, current_ir_graph);
irn_verify_irg(res, current_ir_graph);
return res;
EOF
......@@ -704,7 +704,9 @@ push(@obst_enum_op, "\n} $arch\_opcodes;\n\n");
open(OUT, ">$target_c") || die("Fatal error: Could not open $target_c, reason: $!\n");
print OUT "#include \"gen_$arch\_regalloc_if.h\"\n\n";
print OUT "#include \"gen_$arch\_regalloc_if.h\"\n";
print OUT "#include \"irverify_t.h\"\n";
print OUT "\n";
print OUT @obst_cmp_attr;
print OUT "\n";
print OUT @obst_opvar;
......
......@@ -35,7 +35,6 @@
#include "ircons_t.h"
#include "iropt_t.h"
#include "irop.h"
#include "irvrfy_t.h"
#include "irprintf.h"
#include "xmalloc.h"
......
......@@ -29,7 +29,6 @@
#include "irmode_t.h"
#include "irgmod.h"
#include "iredges.h"
#include "irvrfy.h"
#include "ircons.h"
#include "irprintf.h"
#include "dbginfo.h"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment