Flush performance improvement

Change-Id: I02a62de09fe68f58c5f439a35bda0154d5292bbb