X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fana%2Fheight.c;h=0f5de54c1aa32818a0f7672022cf2e2624fac88f;hb=43eec2cca78f1da7f5f2b43c00c52b88105e5af3;hp=cfda18683ff2451bd25f8dff21093c139e316c6e;hpb=6094bf5ba3971887d1149622daa8a95049a1560c;p=libfirm diff --git a/ir/ana/height.c b/ir/ana/height.c index cfda18683..0f5de54c1 100644 --- a/ir/ana/height.c +++ b/ir/ana/height.c @@ -84,7 +84,7 @@ static void height_dump_cb(void *data, FILE *f, const ir_node *irn) * @param tgt The node we try to reach. * @return 1, one of tgt can be reached from curr, 0 else. */ -static bool search(heights_t *h, const ir_node *curr, const ir_node *tgt) +static bool search(const heights_t *h, const ir_node *curr, const ir_node *tgt) { irn_height_t *h_curr; irn_height_t *h_tgt; @@ -124,9 +124,11 @@ static bool search(heights_t *h, const ir_node *curr, const ir_node *tgt) } /** - * Check, if one node can be reached from another one, according to data dependence. + * Check, if one node can be reached from another one, according to data + * dependence. */ -int heights_reachable_in_block(heights_t *h, const ir_node *n, const ir_node *m) +int heights_reachable_in_block(heights_t *h, const ir_node *n, + const ir_node *m) { int res = 0; irn_height_t *hn = phase_get_irn_data(&h->phase, n); @@ -218,9 +220,9 @@ static void compute_heights_in_block_walker(ir_node *block, void *data) compute_heights_in_block(block, h); } -unsigned get_irn_height(heights_t *heights, const ir_node *irn) +unsigned get_irn_height(const heights_t *heights, const ir_node *irn) { - irn_height_t *h = phase_get_irn_data(&heights->phase, irn); + const irn_height_t *h = phase_get_irn_data(&heights->phase, irn); assert(h && "No height information for node"); return h->height; }