Commit 01ddc5c0 authored by Matthias Braun's avatar Matthias Braun
Browse files

replace is_no_Block() with !is_Block()

[r27833]
parent 604fda63
......@@ -1005,8 +1005,6 @@ FIRM_API int is_Id(const ir_node *node);
FIRM_API int is_Tuple(const ir_node *node);
/** Returns true if node is a Bound node. */
FIRM_API int is_Bound(const ir_node *node);
/** Returns true if the node is not a Block */
FIRM_API int is_no_Block(const ir_node *node);
/** Returns true if the node is a Block */
FIRM_API int is_Block(const ir_node *node);
/** Returns true if node is an Unknown node. */
......
......@@ -713,7 +713,7 @@ void compute_doms(ir_graph *irg)
ir_node *pred = get_irn_n(end, j);
tmp_dom_info *u;
if (is_no_Block(pred) || get_Block_dom_pre_num(pred) == -1)
if (!is_Block(pred) || get_Block_dom_pre_num(pred) == -1)
continue; /* control-dead */
u = dom_eval (&tdi_list[get_Block_dom_pre_num(pred)]);
......
......@@ -113,7 +113,7 @@ void set_block_region(ir_node *block, ir_region *reg)
*/
ir_region *get_irn_region(ir_node *n)
{
if (is_no_Block(n))
if (!is_Block(n))
n = get_nodes_block(n);
return get_block_region(n);
}
......
......@@ -159,7 +159,7 @@ static int firm_emit(lc_appendable_t *app,
case k_ir_node:
switch (occ->conversion) {
case 'B':
block = is_no_Block(X) ? get_nodes_block(X) : X;
block = !is_Block(X) ? get_nodes_block(X) : X;
snprintf(buf, sizeof(buf), "%s%s %s", A("irn"),
get_irn_opname(block), get_mode_name(get_irn_mode(block)));
snprintf(add, sizeof(add), "[%ld]", get_irn_node_nr(block));
......
......@@ -1344,7 +1344,7 @@ static void dump_node(FILE *F, ir_node *n)
static void dump_ir_block_edge(FILE *F, ir_node *n)
{
if (get_opt_dump_const_local() && is_constlike_node(n)) return;
if (is_no_Block(n)) {
if (!is_Block(n)) {
ir_node *block = get_nodes_block(n);
if (get_opt_dump_const_local() && is_constlike_node(block)) {
......
......@@ -324,7 +324,7 @@ static void collect_walk(ir_node *node, blk_collect_data_t *env)
collect_walk(pred, env);
/* BEWARE: predecessors of End nodes might be blocks */
if (is_no_Block(pred)) {
if (!is_Block(pred)) {
ir_node *blk = get_nodes_block(pred);
/*
......@@ -362,7 +362,7 @@ static void collect_blks_lists(ir_node *node, ir_node *block,
ir_node *pred = _get_walk_irn_n(env, node, i);
/* BEWARE: predecessors of End nodes might be blocks */
if (is_no_Block(pred)) {
if (!is_Block(pred)) {
ir_node *blk = get_nodes_block(pred);
if (!irn_visited(pred)) {
......
......@@ -1703,11 +1703,6 @@ int (is_strictConv)(const ir_node *node)
return _is_strictConv(node);
}
int (is_no_Block)(const ir_node *node)
{
return _is_no_Block(node);
}
/* Returns true if node is a SymConst node with kind symconst_addr_ent. */
int (is_SymConst_addr_ent)(const ir_node *node)
{
......
......@@ -364,12 +364,6 @@ static inline int _is_SymConst_addr_ent(const ir_node *node)
return is_SymConst(node) && get_SymConst_kind(node) == symconst_addr_ent;
}
static inline int _is_no_Block(const ir_node *node)
{
assert(node && _is_ir_node(node));
return (_get_irn_op(node) != op_Block);
}
static inline int _get_Block_n_cfgpreds(const ir_node *node)
{
assert(_is_Block(node));
......@@ -640,7 +634,6 @@ void init_irnode(void);
#define is_Phi(node) _is_Phi(node)
#define is_strictConv(node) _is_strictConv(node)
#define is_SymConst_addr_ent(node) _is_SymConst_addr_ent(node)
#define is_no_Block(node) _is_no_Block(node)
#define get_Block_n_cfgpreds(node) _get_Block_n_cfgpreds(node)
#define get_Block_cfgpred(node, pos) _get_Block_cfgpred(node, pos)
#define get_Block_cfgpred_block(node, pos) _get_Block_cfgpred_block(node, pos)
......
......@@ -6544,7 +6544,7 @@ static inline ir_node *identify_cons(pset *value_table, ir_node *n)
/* Add a node to the identities value table. */
void add_identities(pset *value_table, ir_node *node)
{
if (get_opt_cse() && is_no_Block(node))
if (get_opt_cse() && !is_Block(node))
identify_remember(value_table, node);
} /* add_identities */
......
......@@ -78,7 +78,7 @@ static void place_floats_early(ir_node *n, waitq *worklist)
int depth = 0;
ir_node *b = NULL; /* The block to place this node in */
assert(is_no_Block(n));
assert(!is_Block(n));
if (is_irn_start_block_placed(n)) {
/* These nodes will not be placed by the loop below. */
......
......@@ -2600,7 +2600,7 @@ static void compute(node_t *node)
return;
#endif
if (is_no_Block(irn)) {
if (!is_Block(irn)) {
/* for pinned nodes, check its control input */
if (get_irn_pinned(skip_Proj(irn)) == op_pin_state_pinned) {
node_t *block = get_irn_node(get_nodes_block(irn));
......
......@@ -719,7 +719,7 @@ static void eliminate(ir_node *irn, void *ctx)
{
pre_env *env = ctx;
if (is_no_Block(irn)) {
if (!is_Block(irn)) {
ir_node *block = get_nodes_block(irn);
block_info *bl = get_block_info(block);
ir_node *value = lookup(irn);
......
......@@ -471,7 +471,7 @@ static void collect_phis(ir_node *node, void *env)
add_Block_phi(block, node);
} else {
if (is_no_Block(node) && get_irn_pinned(node) == op_pin_state_pinned) {
if (!is_Block(node) && get_irn_pinned(node) == op_pin_state_pinned) {
/*
* Ignore control flow nodes (except Raise), these will be removed.
*/
......
......@@ -589,7 +589,7 @@ static void wq_walker(ir_node *n, void *env)
walker_t *wenv = env;
set_irn_link(n, NULL);
if (is_no_Block(n)) {
if (!is_Block(n)) {
ir_node *blk = get_nodes_block(n);
if (is_Block_dead(blk) || get_Block_dom_depth(blk) < 0) {
......
......@@ -843,7 +843,7 @@ static void stat_update_call(ir_node *call, graph_entry_t *graph)
for (; curr != block && get_Block_dom_depth(curr) > depth;) {
curr = get_Block_idom(curr);
if (! curr || is_no_Block(curr))
if (! curr || !is_Block(curr))
break;
} /* for */
......
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