Global economy accelerated in July before oil topped $100 a barrel