generic split and combine