Cleaned sources and enhanced memory management