Smart autorouting