Improve memory usage for the config compiler