A high-performance VLSI array reconfiguration scheme based on network flow under row and column rerouting