+ if (!tasksInitialized) {
+ errorBelch("newBoundTask: RTS is not initialised; call hs_init() first");
+ stg_exit(EXIT_FAILURE);
+ }
+
+ // ToDo: get rid of this lock in the common case. We could store
+ // a free Task in thread-local storage, for example. That would
+ // leave just one lock on the path into the RTS: cap->lock when
+ // acquiring the Capability.
+ ACQUIRE_LOCK(&sched_mutex);
+