reorder and reflow redundant sections