Flush before generating