wip: rebasing @tknopp's threading branch

Got it. That makes sense.