Improve config compiler's memory usage