Moved main memory to its own file.