[dsymutil] Split some logic into a helper function. NFC