/*
- * Copyright (C) 1995-2008 University of Karlsruhe. All right reserved.
- *
* This file is part of libFirm.
- *
- * This file may be distributed and/or modified under the terms of the
- * GNU General Public License version 2 as published by the Free Software
- * Foundation and appearing in the file LICENSE.GPL included in the
- * packaging of this file.
- *
- * Licensees holding valid libFirm Professional Edition licenses may use
- * this file in accordance with the libFirm Commercial License.
- * Agreement provided with the Software.
- *
- * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
- * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE.
+ * Copyright (C) 2012 University of Karlsruhe.
*/
/**
static void insert_perms(ir_node *block, void *data)
{
be_chordal_env_t *env = (be_chordal_env_t*)data;
- ir_node *irn;
- for (irn = sched_first(block); !sched_is_end(irn);) {
- ir_node *const next = sched_next(irn);
- be_insn_t * insn = be_scan_insn(env, irn);
+ sched_foreach_safe(block, irn) {
+ be_insn_t *insn = be_scan_insn(env, irn);
if (insn)
pre_process_constraints(env, &insn);
-
- irn = next;
}
}
/* dump graph after inserting perms */
if (env->opts->dump_flags & BE_CH_DUMP_CONSTR) {
char buf[256];
- snprintf(buf, sizeof(buf), "-%s-constr", cls->name);
+ snprintf(buf, sizeof(buf), "%s-constr", cls->name);
dump_ir_graph(irg, buf);
}