mov: Wrap stsc index and count compare in a separate function