Fixed the problem in Scheduler.cpp. Cleaned-up the pass files too.