On program decomposition and partitioning in data-flow systems