- assert(pset_count(ready_set) > 0);
-
- for(irn = pset_first(ready_set); irn; irn = pset_next(ready_set)) {
- int costs = reg_pr_costs(env, irn);
- if(costs <= curr_cost) {
- res = irn;
- curr_cost = costs;
+ assert(nodeset_count(ready_set) > 0);
+
+ for (irn = nodeset_first(ready_set); irn; irn = nodeset_next(ready_set)) {
+ /*
+ Ignore branch instructions for the time being.
+ They should only be scheduled if there is nothing else.
+ */
+ if (arch_irn_classify(env->main_env->arch_env, irn) != arch_irn_class_branch) {
+ int costs = reg_pr_costs(env, irn);
+ if (costs <= curr_cost) {
+ res = irn;
+ curr_cost = costs;
+ }