Track peak memory usage