Make XS sort routines work again