ext: data-sort: added second pass note
ext: moved common operations behind clean API
ext: write extension only if offset is zero