-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
loops in task graph #7
Comments
This seems to happen when a variable is redefined. A simpler example:
|
Yep, we touched on this when we talked yesterday. In some ways, that is a new variable x. |
The immediate use case I have in mind is looking at possibilities for parallel computation within the script through a use-define chain, so I'm interested in the dependencies only among expressions.
But you're right, that is a "new" |
Yes and x1, x2, etc. is essentially SSA - Single Static Assignment. You can talk to Nick about that. |
Great I'll work on a patch for this tomorrow. |
A few ways to do this:
I'm favoring the last one, because I'd also like to remove edges that aren't constraints on the computation. Ie. edges This should be simple to implement for a single expression of class
|
Turns out I do want something nuanced and slightly different- a graph representing constraints on the order in which the code runs. So I'll work on that and hold off on making changes here. |
This paper might be relevant if you want go the SSA route: http://dl.acm.org/citation.cfm?doid=268946.268956 I'm thinking of adding array SSA to the ast package because I need something similar for type inference on list elements. |
If tasks are top level expressions in a script then they shouldn't refer to themselves with a loop. It's ok for variable graphs and call graphs though.
In this code I would expect a single edge from node 1 to 2.
But the task graph includes an additional edge from node 2 to itself.
The text was updated successfully, but these errors were encountered: