Rename tile_sets kernel, add support for comparator

Renamed the tile_sets kernel to balanced_path for consistency with
merge_path. Also added support for giving a custom comparator.