projects
/
libfirm
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Treat conversions between the same size as downconv to get rid of unnecessary convers...
[libfirm]
/
ir
/
opt
/
condeval.c
diff --git
a/ir/opt/condeval.c
b/ir/opt/condeval.c
index
3b0029a
..
87ee0e1
100644
(file)
--- a/
ir/opt/condeval.c
+++ b/
ir/opt/condeval.c
@@
-31,7
+31,7
@@
#include "iroptimize.h"
#include <assert.h>
#include "iroptimize.h"
#include <assert.h>
-#include "array.h"
+#include "array
_t
.h"
#include "debug.h"
#include "ircons.h"
#include "irgmod.h"
#include "debug.h"
#include "ircons.h"
#include "irgmod.h"
@@
-202,7
+202,7
@@
typedef struct condeval_env_t {
pn_Cmp pnc; /**< The Compare mode of the Compare node. */
ir_node *cnst;
tarval *tv;
pn_Cmp pnc; /**< The Compare mode of the Compare node. */
ir_node *cnst;
tarval *tv;
-
unsigned long
visited_nr;
+
ir_visited_t
visited_nr;
ir_node *cnst_pred; /**< the block before the constant */
int cnst_pos; /**< the pos to the constant block (needed to
ir_node *cnst_pred; /**< the block before the constant */
int cnst_pos; /**< the pos to the constant block (needed to
@@
-710,8
+710,7
@@
void opt_cond_eval(ir_graph* irg)
normalize_proj_nodes(irg);
edges_assure(irg);
normalize_proj_nodes(irg);
edges_assure(irg);
- set_using_irn_link(irg);
- set_using_irn_visited(irg);
+ ir_reserve_resources(irg, IR_RESOURCE_IRN_LINK | IR_RESOURCE_IRN_VISITED);
changed = 0;
do {
changed = 0;
do {
@@
-720,8
+719,7
@@
void opt_cond_eval(ir_graph* irg)
changed |= rerun;
} while (rerun);
changed |= rerun;
} while (rerun);
- clear_using_irn_visited(irg);
- clear_using_irn_link(irg);
+ ir_free_resources(irg, IR_RESOURCE_IRN_LINK | IR_RESOURCE_IRN_VISITED);
if (changed) {
/* control flow changed, some blocks may become dead */
if (changed) {
/* control flow changed, some blocks may become dead */