swapped pass 1 and pass 2 - works well
graph generation complete - for now