I'm debugging a ScheduleDAG problem. Somehow a load appearing before a call in the source gets scheduled after the call. Since the callee modifies the location loaded from, wrong answers result. Looking at the dag with -view-sched-dags, I don't see an edge from the load to depend on the call. How is this supposed to be handled by ScheduleDAG? -Dave
On Thursday 03 September 2009 11:48, David Greene wrote:> I'm debugging a ScheduleDAG problem. Somehow a load appearing > before a call in the source gets scheduled after the call. > Since the callee modifies the location loaded from, wrong answers result. > > Looking at the dag with -view-sched-dags, I don't see an edge from the > load to depend on the call.-view-sunit-dags seems to indicate such an edge does exist. Any pointers on how to efficiently debug this? -Dave
On Thu, Sep 3, 2009 at 9:48 AM, David Greene<dag at cray.com> wrote:> I'm debugging a ScheduleDAG problem. Somehow a load appearing > before a call in the source gets scheduled after the call. > Since the callee modifies the location loaded from, wrong answers result. > > Looking at the dag with -view-sched-dags, I don't see an edge from the > load to depend on the call. > > How is this supposed to be handled by ScheduleDAG?My first step would be to make sure there's an appropriate edge in the selection DAG... there's a possibility something could get messed up by legalization or the dagcombiner. Since scheduling and selection is mostly within a block, hopefully it wouldn't be too hard to come up with a testcase? -Eli
On Thursday 03 September 2009 16:04, Eli Friedman wrote:> My first step would be to make sure there's an appropriate edge in the > selection DAG... there's a possibility something could get messed up > by legalization or the dagcombiner.I turned off dagcombine and it didn't help.> Since scheduling and selection is mostly within a block, hopefully it > wouldn't be too hard to come up with a testcase?Yep, I've got a much reduced testcase now (and converted from Fortran to C which makes things much easier to work with). I'm going to test against TOT and see if I see the same problem. -Dave