commit before optimization