3 * @file loop_unrolling.c
6 * File name: ir/opt/loop_unrolling.c
7 * Purpose: Make loop unrolling.
8 * Author: Beyhan Veliev
12 * Copyright: (c) 2004 Universität Karlsruhe
13 * Licence: This file protected by GPL - GNU GENERAL PUBLIC LICENSE.
17 # include "loop_unrolling.h"
20 # include "irnode_t.h"
21 # include "irloop_t.h"
23 static void do_loop_unroll(ir_node *n, void *env){
32 /* Performs loop unrolling for the passed graph. */
33 void optimize_loop_unrolling(ir_graph *irg) {
35 if (!get_optimize() || !get_opt_loop_unrolling()) return;
37 /* -- Search expressions that can be optimized -- */
38 irg_walk_graph(irg, NULL, do_loop_unroll, NULL);