Move ThreadPoolScheduler into src/core/.

The JVM-specific bits are conditionally compiled for JVM now.
Add Semaphore and ThreadPoolScheduler to Moar.