Update performance and memory usage after refactoring