Add incremental inliner

<del>**Do not merge this PR yet**, it is obviously in a very rough state.</del><ins>Now good to merge if LG.</ins>

But now the algorithm should be complete enough that things won't change much anymore, except cleanups. So I'm posting it for the eager interested reader.