Add counting of merges and splits.