make Plan::FindWork less o(n^2)