Hello, When determining the scheduling window of a node all types of edges are taken into account. Currently when a node has both predecessors and successors it will be set close to it's predecessors. In fact it can be that a node has only one successor with true dep edge but it will be scheduled close to it's allegedly predecessor; because of the anti-dep edge between the two nodes. Trying to avoid this confusion and reduce the life range of registers we choose to set the scheduled node close to it's predecessors or close to it's successors based on true deps edges only. This change makes SMS succeed on the attached testcase with -funroll-loops on SPU. The testcase was provided by Vladimir. Bootstrapped and tested together with the follow on patch (2/2) on ppc, SPU and x86 with no new regressions. :ADDPATCH modulo-sched: OK for mainline? Thanks, Revital 2007-11-20 Ayal Zaks Revital Eres * modulo-sched.c (get_sched_window): Fix the direction of the scheduling window and add dump info. testsuite: 2007-11-20 Vladimir Yanovsky * gcc.dg/sms-3.c: New testcase. (See attached file: patch_win_dir_again.txt)(See attached file: sms-3.c.txt)