Maximizing memory usage