Optimize scheduler again