On the performance of distributed algorithms for network optimization problems