do you mean representing the entire DAG as a priority queue instead of a list of edges, i am not sure if that is doable