sorting with bitmap