+ /* ToDo: propagate real SchedulerStatus back to caller */
+ scheduleThread(END_TSO_QUEUE);
+ return Success;
+}
+#endif
+
+/* Convenience function for decoding the returned status. */
+
+void
+rts_checkSchedStatus ( char* site, SchedulerStatus rc )
+{
+ switch (rc) {
+ case Success:
+ return;
+ case Killed:
+ barf("%s: uncaught exception",site);
+ case Interrupted:
+ barf("%s: interrupted", site);
+ case Deadlock:
+ barf("%s: no threads to run: infinite loop or deadlock?", site);
+ default:
+ barf("%s: Return code (%d) not ok",(site),(rc));
+ }