Almost 20,000 deals worth $2.2 trillion have been announced in the first half of this year.