projects
/
libfirm
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
switch scalar replacement to new style debug output
[libfirm]
/
ir
/
opt
/
cfopt.c
diff --git
a/ir/opt/cfopt.c
b/ir/opt/cfopt.c
index
945767a
..
be03bfa
100644
(file)
--- a/
ir/opt/cfopt.c
+++ b/
ir/opt/cfopt.c
@@
-1,5
+1,5
@@
/*
/*
- * Copyright (C) 1995-200
7
University of Karlsruhe. All right reserved.
+ * Copyright (C) 1995-200
8
University of Karlsruhe. All right reserved.
*
* This file is part of libFirm.
*
*
* This file is part of libFirm.
*
@@
-187,7
+187,6
@@
static void merge_blocks(ir_node *node, void *ctx) {
}
}
}
}
-
/**
* Block walker removing control flow from dead block by
* inspecting dominance info.
/**
* Block walker removing control flow from dead block by
* inspecting dominance info.
@@
-229,10
+228,10
@@
static void collect_nodes(ir_node *n, void *ctx) {
merge_env *env = ctx;
if (op == op_Block) {
merge_env *env = ctx;
if (op == op_Block) {
-
/* mark the block as non-empty if it is label
led */
- if (has_Block_label(n))
- mark_Block_block_visited(n);
- } else {
+
/* mark the block as non-empty if it is labe
led */
+
if (has_Block_label(n))
+
mark_Block_block_visited(n);
+
} else {
ir_node *b = get_nodes_block(n);
if (op == op_Phi && get_irn_arity(n) > 0) {
ir_node *b = get_nodes_block(n);
if (op == op_Phi && get_irn_arity(n) > 0) {
@@
-314,7
+313,7
@@
static int test_whether_dispensable(ir_node *b, int pos) {
}
/* Seems to be empty. At least we detected this in collect_nodes. */
}
/* Seems to be empty. At least we detected this in collect_nodes. */
- if (
!get_irn_link(b)
) {
+ if (
get_irn_link(b) == NULL
) {
/* There are no Phi nodes ==> all predecessors are dispensable. */
n_preds = get_Block_n_cfgpreds(pred);
} else {
/* There are no Phi nodes ==> all predecessors are dispensable. */
n_preds = get_Block_n_cfgpreds(pred);
} else {
@@
-778,7
+777,7
@@
void optimize_cf(ir_graph *irg) {
/* in rare cases a node may be kept alive more than once, use the visited flag to detect this */
inc_irg_visited(irg);
/* in rare cases a node may be kept alive more than once, use the visited flag to detect this */
inc_irg_visited(irg);
- set_using_visited(irg);
+ set_using_
irn_
visited(irg);
/* fix the keep alive */
for (i = j = 0; i < n; i++) {
/* fix the keep alive */
for (i = j = 0; i < n; i++) {
@@
-811,7
+810,7
@@
void optimize_cf(ir_graph *irg) {
env.changed = 1;
}
env.changed = 1;
}
- clear_using_visited(irg);
+ clear_using_
irn_
visited(irg);
if (env.phis_moved) {
/* Bad: when we moved Phi's, we might produce dead Phi nodes
if (env.phis_moved) {
/* Bad: when we moved Phi's, we might produce dead Phi nodes