projects
/
libfirm
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c84df20
)
Added iteration macro
author
Sebastian Hack
<hack@ipd.info.uni-karlsruhe.de>
Thu, 13 Jan 2005 14:43:54 +0000
(14:43 +0000)
committer
Sebastian Hack
<hack@ipd.info.uni-karlsruhe.de>
Thu, 13 Jan 2005 14:43:54 +0000
(14:43 +0000)
[r4892]
ir/ana/irdom.h
patch
|
blob
|
history
diff --git
a/ir/ana/irdom.h
b/ir/ana/irdom.h
index
fadfe75
..
3ff3037
100644
(file)
--- a/
ir/ana/irdom.h
+++ b/
ir/ana/irdom.h
@@
-88,6
+88,16
@@
ir_node *get_Block_dominated_first(const ir_node *bl);
*/
ir_node *get_Block_dominated_next(const ir_node *dom);
+/**
+ * Iterate over all nodes which are immediately dominated by a given
+ * node.
+ * @param bl The block whose dominated blocks shall be iterated on.
+ * @param curr An iterator variable of type ir_node*
+ */
+#define dominates_for_each(bl,curr) \
+ for(curr = get_Block_dominated_first(bl); curr; \
+ curr = get_Block_dominated_next(curr))
+
/**
* Check, if a block dominates another block.
* @param a The first block.